101 011 010 000 000 100 010 342 Converted to 32 Bit Single Precision IEEE 754 Binary Floating Point Representation Standard

Convert decimal 101 011 010 000 000 100 010 342(10) to 32 bit single precision IEEE 754 binary floating point representation standard (1 bit for sign, 8 bits for exponent, 23 bits for mantissa)

What are the steps to convert decimal number
101 011 010 000 000 100 010 342(10) to 32 bit single precision IEEE 754 binary floating point representation (1 bit for sign, 8 bits for exponent, 23 bits for mantissa)

1. 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;
  • 101 011 010 000 000 100 010 342 ÷ 2 = 50 505 505 000 000 050 005 171 + 0;
  • 50 505 505 000 000 050 005 171 ÷ 2 = 25 252 752 500 000 025 002 585 + 1;
  • 25 252 752 500 000 025 002 585 ÷ 2 = 12 626 376 250 000 012 501 292 + 1;
  • 12 626 376 250 000 012 501 292 ÷ 2 = 6 313 188 125 000 006 250 646 + 0;
  • 6 313 188 125 000 006 250 646 ÷ 2 = 3 156 594 062 500 003 125 323 + 0;
  • 3 156 594 062 500 003 125 323 ÷ 2 = 1 578 297 031 250 001 562 661 + 1;
  • 1 578 297 031 250 001 562 661 ÷ 2 = 789 148 515 625 000 781 330 + 1;
  • 789 148 515 625 000 781 330 ÷ 2 = 394 574 257 812 500 390 665 + 0;
  • 394 574 257 812 500 390 665 ÷ 2 = 197 287 128 906 250 195 332 + 1;
  • 197 287 128 906 250 195 332 ÷ 2 = 98 643 564 453 125 097 666 + 0;
  • 98 643 564 453 125 097 666 ÷ 2 = 49 321 782 226 562 548 833 + 0;
  • 49 321 782 226 562 548 833 ÷ 2 = 24 660 891 113 281 274 416 + 1;
  • 24 660 891 113 281 274 416 ÷ 2 = 12 330 445 556 640 637 208 + 0;
  • 12 330 445 556 640 637 208 ÷ 2 = 6 165 222 778 320 318 604 + 0;
  • 6 165 222 778 320 318 604 ÷ 2 = 3 082 611 389 160 159 302 + 0;
  • 3 082 611 389 160 159 302 ÷ 2 = 1 541 305 694 580 079 651 + 0;
  • 1 541 305 694 580 079 651 ÷ 2 = 770 652 847 290 039 825 + 1;
  • 770 652 847 290 039 825 ÷ 2 = 385 326 423 645 019 912 + 1;
  • 385 326 423 645 019 912 ÷ 2 = 192 663 211 822 509 956 + 0;
  • 192 663 211 822 509 956 ÷ 2 = 96 331 605 911 254 978 + 0;
  • 96 331 605 911 254 978 ÷ 2 = 48 165 802 955 627 489 + 0;
  • 48 165 802 955 627 489 ÷ 2 = 24 082 901 477 813 744 + 1;
  • 24 082 901 477 813 744 ÷ 2 = 12 041 450 738 906 872 + 0;
  • 12 041 450 738 906 872 ÷ 2 = 6 020 725 369 453 436 + 0;
  • 6 020 725 369 453 436 ÷ 2 = 3 010 362 684 726 718 + 0;
  • 3 010 362 684 726 718 ÷ 2 = 1 505 181 342 363 359 + 0;
  • 1 505 181 342 363 359 ÷ 2 = 752 590 671 181 679 + 1;
  • 752 590 671 181 679 ÷ 2 = 376 295 335 590 839 + 1;
  • 376 295 335 590 839 ÷ 2 = 188 147 667 795 419 + 1;
  • 188 147 667 795 419 ÷ 2 = 94 073 833 897 709 + 1;
  • 94 073 833 897 709 ÷ 2 = 47 036 916 948 854 + 1;
  • 47 036 916 948 854 ÷ 2 = 23 518 458 474 427 + 0;
  • 23 518 458 474 427 ÷ 2 = 11 759 229 237 213 + 1;
  • 11 759 229 237 213 ÷ 2 = 5 879 614 618 606 + 1;
  • 5 879 614 618 606 ÷ 2 = 2 939 807 309 303 + 0;
  • 2 939 807 309 303 ÷ 2 = 1 469 903 654 651 + 1;
  • 1 469 903 654 651 ÷ 2 = 734 951 827 325 + 1;
  • 734 951 827 325 ÷ 2 = 367 475 913 662 + 1;
  • 367 475 913 662 ÷ 2 = 183 737 956 831 + 0;
  • 183 737 956 831 ÷ 2 = 91 868 978 415 + 1;
  • 91 868 978 415 ÷ 2 = 45 934 489 207 + 1;
  • 45 934 489 207 ÷ 2 = 22 967 244 603 + 1;
  • 22 967 244 603 ÷ 2 = 11 483 622 301 + 1;
  • 11 483 622 301 ÷ 2 = 5 741 811 150 + 1;
  • 5 741 811 150 ÷ 2 = 2 870 905 575 + 0;
  • 2 870 905 575 ÷ 2 = 1 435 452 787 + 1;
  • 1 435 452 787 ÷ 2 = 717 726 393 + 1;
  • 717 726 393 ÷ 2 = 358 863 196 + 1;
  • 358 863 196 ÷ 2 = 179 431 598 + 0;
  • 179 431 598 ÷ 2 = 89 715 799 + 0;
  • 89 715 799 ÷ 2 = 44 857 899 + 1;
  • 44 857 899 ÷ 2 = 22 428 949 + 1;
  • 22 428 949 ÷ 2 = 11 214 474 + 1;
  • 11 214 474 ÷ 2 = 5 607 237 + 0;
  • 5 607 237 ÷ 2 = 2 803 618 + 1;
  • 2 803 618 ÷ 2 = 1 401 809 + 0;
  • 1 401 809 ÷ 2 = 700 904 + 1;
  • 700 904 ÷ 2 = 350 452 + 0;
  • 350 452 ÷ 2 = 175 226 + 0;
  • 175 226 ÷ 2 = 87 613 + 0;
  • 87 613 ÷ 2 = 43 806 + 1;
  • 43 806 ÷ 2 = 21 903 + 0;
  • 21 903 ÷ 2 = 10 951 + 1;
  • 10 951 ÷ 2 = 5 475 + 1;
  • 5 475 ÷ 2 = 2 737 + 1;
  • 2 737 ÷ 2 = 1 368 + 1;
  • 1 368 ÷ 2 = 684 + 0;
  • 684 ÷ 2 = 342 + 0;
  • 342 ÷ 2 = 171 + 0;
  • 171 ÷ 2 = 85 + 1;
  • 85 ÷ 2 = 42 + 1;
  • 42 ÷ 2 = 21 + 0;
  • 21 ÷ 2 = 10 + 1;
  • 10 ÷ 2 = 5 + 0;
  • 5 ÷ 2 = 2 + 1;
  • 2 ÷ 2 = 1 + 0;
  • 1 ÷ 2 = 0 + 1;

2. Construct the base 2 representation of the positive number.

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

101 011 010 000 000 100 010 342(10) =


1 0101 0110 0011 1101 0001 0101 1100 1110 1111 1011 1011 0111 1100 0010 0011 0000 1001 0110 0110(2)


3. Normalize the binary representation of the number.

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


101 011 010 000 000 100 010 342(10) =


1 0101 0110 0011 1101 0001 0101 1100 1110 1111 1011 1011 0111 1100 0010 0011 0000 1001 0110 0110(2) =


1 0101 0110 0011 1101 0001 0101 1100 1110 1111 1011 1011 0111 1100 0010 0011 0000 1001 0110 0110(2) × 20 =


1.0101 0110 0011 1101 0001 0101 1100 1110 1111 1011 1011 0111 1100 0010 0011 0000 1001 0110 0110(2) × 276


4. 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): 76


Mantissa (not normalized):
1.0101 0110 0011 1101 0001 0101 1100 1110 1111 1011 1011 0111 1100 0010 0011 0000 1001 0110 0110


5. Adjust the exponent.

Use the 8 bit excess/bias notation:


Exponent (adjusted) =


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


76 + 2(8-1) - 1 =


(76 + 127)(10) =


203(10)


6. 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;
  • 203 ÷ 2 = 101 + 1;
  • 101 ÷ 2 = 50 + 1;
  • 50 ÷ 2 = 25 + 0;
  • 25 ÷ 2 = 12 + 1;
  • 12 ÷ 2 = 6 + 0;
  • 6 ÷ 2 = 3 + 0;
  • 3 ÷ 2 = 1 + 1;
  • 1 ÷ 2 = 0 + 1;

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

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


Exponent (adjusted) =


203(10) =


1100 1011(2)


8. 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, by removing the excess bits, from the right (if any of the excess bits is set on 1, we are losing precision...).


Mantissa (normalized) =


1. 010 1011 0001 1110 1000 1010 1 1100 1110 1111 1011 1011 0111 1100 0010 0011 0000 1001 0110 0110 =


010 1011 0001 1110 1000 1010


9. 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) =
1100 1011


Mantissa (23 bits) =
010 1011 0001 1110 1000 1010


Decimal number 101 011 010 000 000 100 010 342 converted to 32 bit single precision IEEE 754 binary floating point representation:

0 - 1100 1011 - 010 1011 0001 1110 1000 1010


How to convert decimal numbers from base ten to 32 bit single precision IEEE 754 binary floating point standard

Follow the steps below to convert a base 10 decimal number to 32 bit single precision IEEE 754 binary floating point:

  • 1. If the number to be converted is negative, start with its the positive version.
  • 2. First convert the integer part. Divide repeatedly by 2 the base ten positive representation of the integer number that is to be converted to binary, until we get a quotient that is equal to zero, keeping track of each remainder.
  • 3. Construct the base 2 representation of the positive integer part of the number, by taking all the remainders of the previous dividing operations, starting from the bottom of the list constructed above. Thus, the last remainder of the divisions becomes the first symbol (the leftmost) of the base two number, while the first remainder becomes the last symbol (the rightmost).
  • 4. Then convert the fractional part. Multiply the number repeatedly by 2, until we get a fractional part that is equal to zero, keeping track of each integer part of the results.
  • 5. Construct the base 2 representation of the fractional part of the number by taking all the integer parts of the previous multiplying operations, starting from the top of the constructed list above (they should appear in the binary representation, from left to right, in the order they have been calculated).
  • 6. Normalize the binary representation of the number, by shifting the decimal point (or if you prefer, the decimal mark) "n" positions either to the left or to the right, so that only one non zero digit remains to the left of the decimal point.
  • 7. Adjust the exponent in 8 bit excess/bias notation and then convert it from decimal (base 10) to 8 bit binary, by using the same technique of repeatedly dividing by 2, as shown above:
    Exponent (adjusted) = Exponent (unadjusted) + 2(8-1) - 1
  • 8. Normalize mantissa, remove the leading (leftmost) bit, since it's allways '1' (and the decimal sign if the case) and adjust its length to 23 bits, either by removing the excess bits from the right (losing precision...) or by adding extra '0' bits to the right.
  • 9. Sign (it takes 1 bit) is either 1 for a negative or 0 for a positive number.

Example: convert the negative number -25.347 from decimal system (base ten) to 32 bit single precision IEEE 754 binary floating point:

  • 1. Start with the positive version of the number:

    |-25.347| = 25.347

  • 2. First convert the integer part, 25. Divide it repeatedly by 2, keeping track of each remainder, until we get a quotient that is equal to zero:
    • division = quotient + remainder;
    • 25 ÷ 2 = 12 + 1;
    • 12 ÷ 2 = 6 + 0;
    • 6 ÷ 2 = 3 + 0;
    • 3 ÷ 2 = 1 + 1;
    • 1 ÷ 2 = 0 + 1;
    • We have encountered a quotient that is ZERO => FULL STOP
  • 3. Construct the base 2 representation of the integer part of the number by taking all the remainders of the previous dividing operations, starting from the bottom of the list constructed above:

    25(10) = 1 1001(2)

  • 4. Then convert the fractional part, 0.347. Multiply repeatedly by 2, keeping track of each integer part of the results, until we get a fractional part that is equal to zero:
    • #) multiplying = integer + fractional part;
    • 1) 0.347 × 2 = 0 + 0.694;
    • 2) 0.694 × 2 = 1 + 0.388;
    • 3) 0.388 × 2 = 0 + 0.776;
    • 4) 0.776 × 2 = 1 + 0.552;
    • 5) 0.552 × 2 = 1 + 0.104;
    • 6) 0.104 × 2 = 0 + 0.208;
    • 7) 0.208 × 2 = 0 + 0.416;
    • 8) 0.416 × 2 = 0 + 0.832;
    • 9) 0.832 × 2 = 1 + 0.664;
    • 10) 0.664 × 2 = 1 + 0.328;
    • 11) 0.328 × 2 = 0 + 0.656;
    • 12) 0.656 × 2 = 1 + 0.312;
    • 13) 0.312 × 2 = 0 + 0.624;
    • 14) 0.624 × 2 = 1 + 0.248;
    • 15) 0.248 × 2 = 0 + 0.496;
    • 16) 0.496 × 2 = 0 + 0.992;
    • 17) 0.992 × 2 = 1 + 0.984;
    • 18) 0.984 × 2 = 1 + 0.968;
    • 19) 0.968 × 2 = 1 + 0.936;
    • 20) 0.936 × 2 = 1 + 0.872;
    • 21) 0.872 × 2 = 1 + 0.744;
    • 22) 0.744 × 2 = 1 + 0.488;
    • 23) 0.488 × 2 = 0 + 0.976;
    • 24) 0.976 × 2 = 1 + 0.952;
    • We didn't get any fractional part that was equal to zero. But we had enough iterations (over Mantissa limit = 23) and at least one integer part that was different from zero => FULL STOP (losing precision...).
  • 5. Construct the base 2 representation of the fractional part of the number, by taking all the integer parts of the previous multiplying operations, starting from the top of the constructed list above:

    0.347(10) = 0.0101 1000 1101 0100 1111 1101(2)

  • 6. Summarizing - the positive number before normalization:

    25.347(10) = 1 1001.0101 1000 1101 0100 1111 1101(2)

  • 7. Normalize the binary representation of the number, shifting the decimal point 4 positions to the left so that only one non-zero digit stays to the left of the decimal point:

    25.347(10) =
    1 1001.0101 1000 1101 0100 1111 1101(2) =
    1 1001.0101 1000 1101 0100 1111 1101(2) × 20 =
    1.1001 0101 1000 1101 0100 1111 1101(2) × 24

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

    Sign: 1 (a negative number)

    Exponent (unadjusted): 4

    Mantissa (not-normalized): 1.1001 0101 1000 1101 0100 1111 1101

  • 9. Adjust the exponent in 8 bit excess/bias notation and then convert it from decimal (base 10) to 8 bit binary (base 2), by using the same technique of repeatedly dividing it by 2, as already demonstrated above:

    Exponent (adjusted) = Exponent (unadjusted) + 2(8-1) - 1 = (4 + 127)(10) = 131(10) =
    1000 0011(2)

  • 10. Normalize the mantissa, remove the leading (leftmost) bit, since it's allways '1' (and the decimal point) and adjust its length to 23 bits, by removing the excess bits from the right (losing precision...):

    Mantissa (not-normalized): 1.1001 0101 1000 1101 0100 1111 1101

    Mantissa (normalized): 100 1010 1100 0110 1010 0111

  • Conclusion:

    Sign (1 bit) = 1 (a negative number)

    Exponent (8 bits) = 1000 0011

    Mantissa (23 bits) = 100 1010 1100 0110 1010 0111

  • Number -25.347, converted from the decimal system (base 10) to 32 bit single precision IEEE 754 binary floating point =
    1 - 1000 0011 - 100 1010 1100 0110 1010 0111