In: Computer Science
Using 64-bit IEEE 754 DOUBLE precision floating point with one(1) sign bit, eleven (11) exponent bits and fifty-two (52) mantissa bits, what is the decimal value of: 0xBFE4000000000000

Hexadecimal Binary
0 0000
1 0001
2 0010
3 0011
4 0100
5 0101
6 0110
7 0111
8 1000
9 1001
A 1010
B 1011
C 1100
D 1101
E 1110
F 1111
Use this table to convert from hexadecimal to binary
Converting BFE4000000000000 to binary
B => 1011
F => 1111
E => 1110
4 => 0100
0 => 0000
0 => 0000
0 => 0000
0 => 0000
0 => 0000
0 => 0000
0 => 0000
0 => 0000
0 => 0000
0 => 0000
0 => 0000
0 => 0000
So, in binary BFE4000000000000 is 1011111111100100000000000000000000000000000000000000000000000000
1011111111100100000000000000000000000000000000000000000000000000
1 01111111110 0100000000000000000000000000000000000000000000000000
sign bit is 1(-ve)
exp bits are 01111111110
=> 01111111110
=> 0x2^10+1x2^9+1x2^8+1x2^7+1x2^6+1x2^5+1x2^4+1x2^3+1x2^2+1x2^1+0x2^0
=> 0x1024+1x512+1x256+1x128+1x64+1x32+1x16+1x8+1x4+1x2+0x1
=> 0+512+256+128+64+32+16+8+4+2+0
=> 1022
in decimal it is 1022
so, exponent/bias is 1022-1023 = -1
frac bits are 01
IEEE-754 Decimal value is 1.frac * 2^exponent
IEEE-754 Decimal value is 1.01 * 2^-1
1.01 in decimal is 1.25
=> 1.01
=> 1x2^0+0x2^-1+1x2^-2
=> 1x1+0x0.5+1x0.25
=> 1+0.0+0.25
=> 1.25
so, 1.25 * 2^-1 in decimal is 0.625
so, 0xBFE4000000000000 in IEEE-754 double precision format is -0.625
Answer: -0.625