cs302 Asignment
cs302 Asignment
STUDENT ID BC230408896
Assignment No 1
Question: In the following task, convert a 32- bit binary floating-point number to decimal
Floating-Point number
11000100110110101011010111000111
Solution:
The given binary number is:
11000100110110101011010111000111
Sign bit: The first bit is 1, and this means that the number is negative
Exponent: The next eight bits are 10001001. This is the biased exponent where the bias equals to 127.
Fraction: The following twenty three bits are 10110101011010111000111. This denotes the fractional part,
the fraction becomes;
F = 1.10110101011010111000111₂
F ≈ 1.7109375
We have determined the sign, exponent, and the fraction, now using the three we shall evaluate the integer
using the equation of floating point number given as:
S F
(−1) XF X 2
Substituting the values:
1 10
(−1) X 1.7109375 X 2
−1 X 1.7109375 X 1024
= -1757.8125
The decimal equivalent of the binary floating-point number 11000100110110101011010111000111 is -
1757.8125.