0% found this document useful (0 votes)
6 views1 page

cs302 Asignment

Uploaded by

Ameer Hamza
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
6 views1 page

cs302 Asignment

Uploaded by

Ameer Hamza
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 1

CS302 - Digital Logic Design (CS302)

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.

Therefore, the exponent value is;

E = 100010010_2 = 137 (in decimal representation)

The unbiased exponent reads as;

unbiased = E - 127 = 137 - 127 = 10

Fraction: The following twenty three bits are 10110101011010111000111. This denotes the fractional part,
the fraction becomes;

F = 1.10110101011010111000111₂

Now, we take the fraction 1.10110101011010111000111₂ and convert it to decimal.

F = 1 + (1/2) + (1/8) + (1/16) + (1/32) + (1/64) + (1/128)

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.

You might also like