Answer:
floating point Decimal Number = -78.1025390625
Step-by-step explanation:
Hex Value =0xC29C3480
Convert this hex value into binary number, Use only C29C3480 as hexadecimal number. Each digit in hexadecimal will convert into 4 bits of binary. To convert this number into decimal we use hexadecimal to binary table. The conversion is as below:
1100 0010 1001 1100 0011 0100 1000 0000
Now this is a 32 bit number in binary, the bits are arranged as follows
1 10000101 00111000011010010000000
(Sign bit) (Exponent bits) (Fraction bits)
In this 32 bit number, 32nd bit is sign bit,number is positive if the bit is 0 other wise number is negative. From 31st to 23rd bits 8 bits that are known as exponent bits, while from 22nd to 0 total 23 bits that are called fraction bit.
- As the 32 bit is 1, so given number is negative.
- Now convert the Exponent bits into decimal values as
10000101 = 1x2⁷+0x2⁶+0x2⁵+0x2⁴+0x2³+1x2²+0x2¹+1x2⁰
= 1x2⁷ + 1x2² + 1x2⁰
= 128 + 4 + 1 = 133
3. Now we calculate the exponent bias, that will be calculated through, the formula.
exponent bias = 2ⁿ⁻¹ - 1
there n is total number of bits in exponent value of 32 bit number, Now in this question n=8, because there are total 8 bits in exponent.
so, exponent bias = 2⁸⁻¹ - 1 = 2⁷-1= 128-1= 127
e = decimal value of exponent - exponent bias
= 133 - 127 = 6
4. Now, we calculate the decimal value of fraction part of the number, which is called mantissa.
Mantissa=0x2⁻¹+0x2⁻²+1x2⁻³+1x2⁻⁴+1x2⁻⁵+0x2⁻⁶+0x2⁻⁷+0x2⁻⁸+0x2⁻⁹+1x2⁻¹⁰+1x2⁻¹¹+0x2⁻¹²+1x2⁻¹³+0x2⁻¹⁴+0x2⁻¹⁵+1x2⁻¹⁶+0x2⁻¹⁷+0x2⁻¹⁸+0x2⁻¹⁹+0x2⁻²⁰+0x2⁻²¹+0x2⁻²²+0x2⁻²³
= 1x2⁻³+1x2⁻⁴+1x2⁻⁵+1x2⁻¹⁰+1x2⁻¹¹+1x2⁻¹³+1x2⁻¹⁶
= 0.125 + 0.0625 + 0.03125 + 0.0009765625 + 0.00048828125 + 0.00012207031 + 0.00001525878
Mantissa = 0.22035217284
Now the formula to calculate the decimal number is given below:
decimal number = (-1)^s x (1+Mantissa) x 2^e
there s is the sign bit which is 1. and e =6.
so,
decimal number = (-1)^1 x (1+0.22035217284 ) x 2⁶
= -1 x 1.22035217284 x 64
= -78.1025390625