Below is a tutorial I'm trying to follow.
When attempting to convert the number back to its binary representation I get it wrong. Could someone tell me what I'm doing incorrectly?
-0.21875
binary representation:
.00111 = 1.11 * 2^-3
since..
0.5^3 + 0.5^4 + 0.5^5 = 0.21875
with an exponent of..
-3 + 127 = 124
therefore the binary representation should be:
s eeeeeeee mmmmmmmmmmmmmm
1 01111100 11100000000000
But why do I get the right answer converting 639.6875 the same way?:
Representation of integer value:
1001111111
Representation of decimal value:
1011
Combining and normalizing:
1001111111.1011 = 1.0011111111011 * 2^9
When normalizing, we place the radix directly to the right of the first 1 right? biasing with 127 to the exponent, 127+9 = 136:
10001000
binary representation:
s eeeeeeee mmmmmmmmmmmmmm
0 10001000 10011111111011