32bit IEEE 754: Decimal ↗ Single Precision Floating Point Binary: 0.174 316 8 Convert the Number to 32 Bit Single Precision IEEE 754 Binary Floating Point Representation Standard, From a Base 10 Decimal System Number

Number 0.174 316 8(10) converted and written in 32 bit single precision IEEE 754 binary floating point representation (1 bit for sign, 8 bits for exponent, 23 bits for mantissa)

1. First, convert to binary (in base 2) the integer part: 0.
Divide the number repeatedly by 2.

Keep track of each remainder.

We stop when we get a quotient that is equal to zero.


  • division = quotient + remainder;
  • 0 ÷ 2 = 0 + 0;

2. Construct the base 2 representation of the integer part of the number.

Take all the remainders starting from the bottom of the list constructed above.


0(10) =


0(2)


3. Convert to binary (base 2) the fractional part: 0.174 316 8.

Multiply it repeatedly by 2.


Keep track of each integer part of the results.


Stop when we get a fractional part that is equal to zero.


  • #) multiplying = integer + fractional part;
  • 1) 0.174 316 8 × 2 = 0 + 0.348 633 6;
  • 2) 0.348 633 6 × 2 = 0 + 0.697 267 2;
  • 3) 0.697 267 2 × 2 = 1 + 0.394 534 4;
  • 4) 0.394 534 4 × 2 = 0 + 0.789 068 8;
  • 5) 0.789 068 8 × 2 = 1 + 0.578 137 6;
  • 6) 0.578 137 6 × 2 = 1 + 0.156 275 2;
  • 7) 0.156 275 2 × 2 = 0 + 0.312 550 4;
  • 8) 0.312 550 4 × 2 = 0 + 0.625 100 8;
  • 9) 0.625 100 8 × 2 = 1 + 0.250 201 6;
  • 10) 0.250 201 6 × 2 = 0 + 0.500 403 2;
  • 11) 0.500 403 2 × 2 = 1 + 0.000 806 4;
  • 12) 0.000 806 4 × 2 = 0 + 0.001 612 8;
  • 13) 0.001 612 8 × 2 = 0 + 0.003 225 6;
  • 14) 0.003 225 6 × 2 = 0 + 0.006 451 2;
  • 15) 0.006 451 2 × 2 = 0 + 0.012 902 4;
  • 16) 0.012 902 4 × 2 = 0 + 0.025 804 8;
  • 17) 0.025 804 8 × 2 = 0 + 0.051 609 6;
  • 18) 0.051 609 6 × 2 = 0 + 0.103 219 2;
  • 19) 0.103 219 2 × 2 = 0 + 0.206 438 4;
  • 20) 0.206 438 4 × 2 = 0 + 0.412 876 8;
  • 21) 0.412 876 8 × 2 = 0 + 0.825 753 6;
  • 22) 0.825 753 6 × 2 = 1 + 0.651 507 2;
  • 23) 0.651 507 2 × 2 = 1 + 0.303 014 4;
  • 24) 0.303 014 4 × 2 = 0 + 0.606 028 8;
  • 25) 0.606 028 8 × 2 = 1 + 0.212 057 6;
  • 26) 0.212 057 6 × 2 = 0 + 0.424 115 2;

We didn't get any fractional part that was equal to zero. But we had enough iterations (over Mantissa limit) and at least one integer that was different from zero => FULL STOP (losing precision...)


4. Construct the base 2 representation of the fractional part of the number.

Take all the integer parts of the multiplying operations, starting from the top of the constructed list above:


0.174 316 8(10) =


0.0010 1100 1010 0000 0000 0110 10(2)


5. Positive number before normalization:

0.174 316 8(10) =


0.0010 1100 1010 0000 0000 0110 10(2)

6. Normalize the binary representation of the number.

Shift the decimal mark 3 positions to the right, so that only one non zero digit remains to the left of it:


0.174 316 8(10) =


0.0010 1100 1010 0000 0000 0110 10(2) =


0.0010 1100 1010 0000 0000 0110 10(2) × 20 =


1.0110 0101 0000 0000 0011 010(2) × 2-3


7. Up to this moment, there are the following elements that would feed into the 32 bit single precision IEEE 754 binary floating point representation:

Sign 0 (a positive number)


Exponent (unadjusted): -3


Mantissa (not normalized):
1.0110 0101 0000 0000 0011 010


8. Adjust the exponent.

Use the 8 bit excess/bias notation:


Exponent (adjusted) =


Exponent (unadjusted) + 2(8-1) - 1 =


-3 + 2(8-1) - 1 =


(-3 + 127)(10) =


124(10)


9. Convert the adjusted exponent from the decimal (base 10) to 8 bit binary.

Use the same technique of repeatedly dividing by 2:


  • division = quotient + remainder;
  • 124 ÷ 2 = 62 + 0;
  • 62 ÷ 2 = 31 + 0;
  • 31 ÷ 2 = 15 + 1;
  • 15 ÷ 2 = 7 + 1;
  • 7 ÷ 2 = 3 + 1;
  • 3 ÷ 2 = 1 + 1;
  • 1 ÷ 2 = 0 + 1;

10. Construct the base 2 representation of the adjusted exponent.

Take all the remainders starting from the bottom of the list constructed above.


Exponent (adjusted) =


124(10) =


0111 1100(2)


11. Normalize the mantissa.

a) Remove the leading (the leftmost) bit, since it's allways 1, and the decimal point, if the case.


b) Adjust its length to 23 bits, only if necessary (not the case here).


Mantissa (normalized) =


1. 011 0010 1000 0000 0001 1010 =


011 0010 1000 0000 0001 1010


12. The three elements that make up the number's 32 bit single precision IEEE 754 binary floating point representation:

Sign (1 bit) =
0 (a positive number)


Exponent (8 bits) =
0111 1100


Mantissa (23 bits) =
011 0010 1000 0000 0001 1010


The base ten decimal number 0.174 316 8 converted and written in 32 bit single precision IEEE 754 binary floating point representation:
0 - 0111 1100 - 011 0010 1000 0000 0001 1010

The latest decimal numbers converted from base ten to 32 bit single precision IEEE 754 floating point binary standard representation