algorithm - Exponent out of range: convert positive decimal number into floating point 3 bits exponent 5 bits mantissa format -


i have convert decimal 21 floating point 3 bits exponent 5 bits mantissa format, exponent must in two's complement code.

i did according algorithm presented here: http://sandbox.mc.edu/~bennet/cs110/flt/dtof.html

i normalize value: 21 decimal = 10101 x 2^0 = 1.0101 x 2^4 5 bits mantissa is: 01010

according point e. in given article bias 3 bits exponent field 2^(3-1)-1 = 3 add bias exponent 4 + 3 = 7 0111 in two's complement code on 4 bits exponent have 3 bits.

i have been told exponent field example should 001 don't know why.

question: why exponent field should 001?


Comments