answersLogoWhite

0

To convert 11000001111111100000000000000000 from IEEE 754-1985 to its decimal equivalent, proceed as follows:

The most significant bit, bit 31, represents the sign, where 0 denotes positive and 1 denotes negative. So this number is clearly negative.

The next 8 bits, from bit 23 to bit 30, represent the exponent. Here we have the value 10000011 which is 131 decimal. However, exponents are biased by 127, thus 131 really means 131-127=3. Thus the exponent is 3. In scientific notation, the exponent tells us how many decimal places to move the decimal point and in what direction. This is no different in binary except we use a binary point instead of a decimal point. Thus an exponent of 3 tells us to move the binary point 3 positions to the right (if it were -3, we'd move three position to the left instead).

The remaining 23 bits, from bit 0 to bit 22, represent the mantissa, the fractional component. Here we have 11111100000000000000000. However, a leading 1 bit is always implied so the mantissa is really 24 bits long, with a value of 111111100000000000000000. The binary point is placed to the right of the (implied) leading digit, thus this mantissa has a binary value of 1.11111100000000000000000.

Note that the leading 1 bit can always be implied because the digit to the left of the binary point must always be non-zero and the only non-zero digit in binary is 1.

The exponent, 3, tells us to move the binary point 3 positions to the right, so we now have 1111.11100000000000000000. We can ignore the trailing zeroes so we now have a binary fraction of 1111.111.

Converting floating point binary values to decimal values is no different to converting integer values where every bit position represents some power of 2. Those to the left of the binary point represent increasing powers of 2 starting with 2^0, just as they do in integer conversions. Those to the right represent decreasing powers of 2, starting with 2^-1 (which is 0.5 in decimal). Thus, working from left to right we have:

1 x 2^3 = 8

1 x 2^2 = 4

1 x 2^1 = 2

1 x 2^0 = 1

binary point

1 x 2^-1 = 0.5

1 x 2^-2 = 0.25

1 x 2^-3 = 0.125

Adding these up we get the decimal value 15.857. However, the sign bit indicated the value was negative, so the value is -15.857.

Thus 11000001111111100000000000000000 in IEEE 754-185 represents -15.857 in decimal.

User Avatar

Wiki User

9y ago

What else can I help you with?