Question

In: Computer Science

Convert 1.8125 to IEEE-754 representation. Show all your work.

Convert 1.8125 to IEEE-754 representation. Show all your work.

Solutions

Expert Solution



1.8125 in IEEE-754 single precision binary format is 00111111111010000000000000000000

sign bit:   0
exponent bits:  01111111
mantissa bits:  11010000000000000000000

Explanation:
-------------
1.8125
Converting 1.8125 to binary
   Convert decimal part first, then the fractional part
   > 1 in binary is 1, simple!
   > Now, Convert 0.81250000 to binary
      > Multiply 0.81250000 with 2.  Since 1.62500000 is >= 1. then add 1 to result
      > Multiply 0.62500000 with 2.  Since 1.25000000 is >= 1. then add 1 to result
      > Multiply 0.25000000 with 2.  Since 0.50000000 is < 1. then add 0 to result
      > Multiply 0.50000000 with 2.  Since 1.00000000 is >= 1. then add 1 to result
      > This is equal to 1, so, stop calculating
   0.8125 of decimal is .1101 in binary
   so, 1.8125 in binary is 1.1101
1.8125 in simple binary => 1.1101
so, 1.8125 in normal binary is 1.1101 => 1.1101 * 2^0
=>  1(.1101 this is the fractional part) * 2^(127+0 this is the exponent bits)

single precision:
--------------------
sign bit is 0(+ve)
exponent bits are (127+0=127) => 01111111
   Divide 127 successively by 2 until the quotient is 0
      > 127/2 = 63, remainder is 1
      > 63/2 = 31, remainder is 1
      > 31/2 = 15, remainder is 1
      > 15/2 = 7, remainder is 1
      > 7/2 = 3, remainder is 1
      > 3/2 = 1, remainder is 1
      > 1/2 = 0, remainder is 1
   Read remainders from the bottom to top as 1111111
   So, 127 of decimal is 1111111 in binary
frac/significant bits are 11010000000000000000000

so, 1.8125 in single-precision format is 0 01111111 11010000000000000000000

Related Solutions

Convert 1.8125 to IEEE-754 representation. Show all your work.
Convert 1.8125 to IEEE-754 representation. Show all your work.
Convert 11001001100101101011010011010111 from IEEE 754 to decimal show work
Convert 11001001100101101011010011010111 from IEEE 754 to decimal show work
Convert the following number into 32bit IEEE 754 floating point representation. 0.000101
Convert the following number into 32bit IEEE 754 floating point representation. 0.000101
1. Convert 5.5 to hexadecimal notation using IEEE 754 single precision. Please show your work and...
1. Convert 5.5 to hexadecimal notation using IEEE 754 single precision. Please show your work and answer must be in hexadecimal notation. 2. (4 points) Convert -7.875 to hexadecimal notation using IEEE 754 single precision. Please show your work and answer must be in hexadecimal notation.
Convert −98765.4321 to IEEE 745 (show your work)
Convert −98765.4321 to IEEE 745 (show your work)
convert 0x41BA8000 to IEEE-754 floating-point value
convert 0x41BA8000 to IEEE-754 floating-point value
convert 0x41BA8000 to IEEE-754 floating-point value
convert 0x41BA8000 to IEEE-754 floating-point value
convert 0x41BA8000 to IEEE-754 floating-point value
convert 0x41BA8000 to IEEE-754 floating-point value
Binary conversion: Convert 1234.5869 × 103 to IEEE 745 (show your work)
Binary conversion: Convert 1234.5869 × 103 to IEEE 745 (show your work)
Show the IEEE 754 binary representation of the number -0.25(subscript)ten in single and double precision. List...
Show the IEEE 754 binary representation of the number -0.25(subscript)ten in single and double precision. List all the steps required to get the single and double precision.
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT