0
$\begingroup$

Convert 0.625 to IEEE754 32-bit binary number.

0.625 x 2 = 1.250
0.250 x 2 = 0.500
0.500 x 2 = 1.000

So,

0.625 = 0.101  
=> 0.625 = 1.01 x 2^(-1)

So,

S = 0
E = -1+127 = 126 => 01111110
M = 01 => 0100000 00000000 00000000 

I am confused with the mantissa part.

Would it be

M = 01 => 0100000 00000000 00000000

Or,

M = 01 => 0000000 00000000 00000001

?

$\endgroup$
  • $\begingroup$ 0.625 = 1.01 * 2^(-1). 5 = 1.01 * 2^2. And the exponent is biased. $\endgroup$ – gnasher729 Mar 18 at 23:15
  • $\begingroup$ You wrote 0.625 = 1.01 * 2^2, when really 5 = 1.01 * 2^2. And your correction is still wrong: 0.625 = 1.01 * 2^(-1), not 1.01 * 2^(-2). $\endgroup$ – gnasher729 Mar 18 at 23:31
  • $\begingroup$ @gnasher729, is it correct now? $\endgroup$ – user366312 Mar 18 at 23:41

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.