In: Computer Science
Convert the following binary floating point to decimal
IEEE 32-bit floating point format.
0 1000 0101 000 0100 1101 0000 0000 0000
0 10000101 00001001101000000000000 sign bit is 0(+ve) exp bits are 10000101 => 10000101 => 1x2^7+0x2^6+0x2^5+0x2^4+0x2^3+1x2^2+0x2^1+1x2^0 => 1x128+0x64+0x32+0x16+0x8+1x4+0x2+1x1 => 128+0+0+0+0+4+0+1 => 133 in decimal it is 133 so, exponent/bias is 133-127 = 6 frac bits are 00001001101 IEEE-754 Decimal value is 1.frac * 2^exponent IEEE-754 Decimal value is 1.00001001101 * 2^6 1.00001001101 in decimal is 1.03759765625 => 1.00001001101 => 1x2^0+0x2^-1+0x2^-2+0x2^-3+0x2^-4+1x2^-5+0x2^-6+0x2^-7+1x2^-8+1x2^-9+0x2^-10+1x2^-11 => 1x1+0x0.5+0x0.25+0x0.125+0x0.0625+1x0.03125+0x0.015625+0x0.0078125+1x0.00390625+1x0.001953125+0x0.0009765625+1x0.00048828125 => 1+0.0+0.0+0.0+0.0+0.03125+0.0+0.0+0.00390625+0.001953125+0.0+0.00048828125 => 1.03759765625 so, 1.03759765625 * 2^6 in decimal is 66.40625 so, 01000010100001001101000000000000 in IEEE-754 single precision format is 66.40625 Answer: 66.40625