In: Computer Science
6 – Assuming single precision IEEE 754 format, what decimal number is represent by the following 32-bit binary word?
1 10001000 10010000000000000000000
1 10001000 10010000000000000000000
sign bit is 1(-ve)
exp bits are 10001000
Converting 10001000 to decimal
10001000
=>
1x2^7+0x2^6+0x2^5+0x2^4+1x2^3+0x2^2+0x2^1+0x2^0
=> 1x128+0x64+0x32+0x16+1x8+0x4+0x2+0x1
=> 128+0+0+0+8+0+0+0
=> 136
in decimal it is 136
so, exponent/bias is 136-127 = 9
frac bits are 1001
IEEE-754 Decimal value is 1.frac * 2^exponent
IEEE-754 Decimal value is 1.1001 * 2^9
1.1001 in decimal is 1.5625
=> 1.1001
=> 1x2^0+1x2^-1+0x2^-2+0x2^-3+1x2^-4
=> 1x1+1x0.5+0x0.25+0x0.125+1x0.0625
=> 1+0.5+0.0+0.0+0.0625
=> 1.5625
so, 1.5625 * 2^9 in decimal is 800.0
so, 11000100010010000000000000000000 in IEEE-754 single precision
format is -800.0
Answer: -800.0