1 100 011 110 001 010 001 001 100 999 987 Converted to 32 Bit Single Precision IEEE 754 Binary Floating Point Representation Standard

Convert decimal 1 100 011 110 001 010 001 001 100 999 987(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
1 100 011 110 001 010 001 001 100 999 987(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;
  • 1 100 011 110 001 010 001 001 100 999 987 ÷ 2 = 550 005 555 000 505 000 500 550 499 993 + 1;
  • 550 005 555 000 505 000 500 550 499 993 ÷ 2 = 275 002 777 500 252 500 250 275 249 996 + 1;
  • 275 002 777 500 252 500 250 275 249 996 ÷ 2 = 137 501 388 750 126 250 125 137 624 998 + 0;
  • 137 501 388 750 126 250 125 137 624 998 ÷ 2 = 68 750 694 375 063 125 062 568 812 499 + 0;
  • 68 750 694 375 063 125 062 568 812 499 ÷ 2 = 34 375 347 187 531 562 531 284 406 249 + 1;
  • 34 375 347 187 531 562 531 284 406 249 ÷ 2 = 17 187 673 593 765 781 265 642 203 124 + 1;
  • 17 187 673 593 765 781 265 642 203 124 ÷ 2 = 8 593 836 796 882 890 632 821 101 562 + 0;
  • 8 593 836 796 882 890 632 821 101 562 ÷ 2 = 4 296 918 398 441 445 316 410 550 781 + 0;
  • 4 296 918 398 441 445 316 410 550 781 ÷ 2 = 2 148 459 199 220 722 658 205 275 390 + 1;
  • 2 148 459 199 220 722 658 205 275 390 ÷ 2 = 1 074 229 599 610 361 329 102 637 695 + 0;
  • 1 074 229 599 610 361 329 102 637 695 ÷ 2 = 537 114 799 805 180 664 551 318 847 + 1;
  • 537 114 799 805 180 664 551 318 847 ÷ 2 = 268 557 399 902 590 332 275 659 423 + 1;
  • 268 557 399 902 590 332 275 659 423 ÷ 2 = 134 278 699 951 295 166 137 829 711 + 1;
  • 134 278 699 951 295 166 137 829 711 ÷ 2 = 67 139 349 975 647 583 068 914 855 + 1;
  • 67 139 349 975 647 583 068 914 855 ÷ 2 = 33 569 674 987 823 791 534 457 427 + 1;
  • 33 569 674 987 823 791 534 457 427 ÷ 2 = 16 784 837 493 911 895 767 228 713 + 1;
  • 16 784 837 493 911 895 767 228 713 ÷ 2 = 8 392 418 746 955 947 883 614 356 + 1;
  • 8 392 418 746 955 947 883 614 356 ÷ 2 = 4 196 209 373 477 973 941 807 178 + 0;
  • 4 196 209 373 477 973 941 807 178 ÷ 2 = 2 098 104 686 738 986 970 903 589 + 0;
  • 2 098 104 686 738 986 970 903 589 ÷ 2 = 1 049 052 343 369 493 485 451 794 + 1;
  • 1 049 052 343 369 493 485 451 794 ÷ 2 = 524 526 171 684 746 742 725 897 + 0;
  • 524 526 171 684 746 742 725 897 ÷ 2 = 262 263 085 842 373 371 362 948 + 1;
  • 262 263 085 842 373 371 362 948 ÷ 2 = 131 131 542 921 186 685 681 474 + 0;
  • 131 131 542 921 186 685 681 474 ÷ 2 = 65 565 771 460 593 342 840 737 + 0;
  • 65 565 771 460 593 342 840 737 ÷ 2 = 32 782 885 730 296 671 420 368 + 1;
  • 32 782 885 730 296 671 420 368 ÷ 2 = 16 391 442 865 148 335 710 184 + 0;
  • 16 391 442 865 148 335 710 184 ÷ 2 = 8 195 721 432 574 167 855 092 + 0;
  • 8 195 721 432 574 167 855 092 ÷ 2 = 4 097 860 716 287 083 927 546 + 0;
  • 4 097 860 716 287 083 927 546 ÷ 2 = 2 048 930 358 143 541 963 773 + 0;
  • 2 048 930 358 143 541 963 773 ÷ 2 = 1 024 465 179 071 770 981 886 + 1;
  • 1 024 465 179 071 770 981 886 ÷ 2 = 512 232 589 535 885 490 943 + 0;
  • 512 232 589 535 885 490 943 ÷ 2 = 256 116 294 767 942 745 471 + 1;
  • 256 116 294 767 942 745 471 ÷ 2 = 128 058 147 383 971 372 735 + 1;
  • 128 058 147 383 971 372 735 ÷ 2 = 64 029 073 691 985 686 367 + 1;
  • 64 029 073 691 985 686 367 ÷ 2 = 32 014 536 845 992 843 183 + 1;
  • 32 014 536 845 992 843 183 ÷ 2 = 16 007 268 422 996 421 591 + 1;
  • 16 007 268 422 996 421 591 ÷ 2 = 8 003 634 211 498 210 795 + 1;
  • 8 003 634 211 498 210 795 ÷ 2 = 4 001 817 105 749 105 397 + 1;
  • 4 001 817 105 749 105 397 ÷ 2 = 2 000 908 552 874 552 698 + 1;
  • 2 000 908 552 874 552 698 ÷ 2 = 1 000 454 276 437 276 349 + 0;
  • 1 000 454 276 437 276 349 ÷ 2 = 500 227 138 218 638 174 + 1;
  • 500 227 138 218 638 174 ÷ 2 = 250 113 569 109 319 087 + 0;
  • 250 113 569 109 319 087 ÷ 2 = 125 056 784 554 659 543 + 1;
  • 125 056 784 554 659 543 ÷ 2 = 62 528 392 277 329 771 + 1;
  • 62 528 392 277 329 771 ÷ 2 = 31 264 196 138 664 885 + 1;
  • 31 264 196 138 664 885 ÷ 2 = 15 632 098 069 332 442 + 1;
  • 15 632 098 069 332 442 ÷ 2 = 7 816 049 034 666 221 + 0;
  • 7 816 049 034 666 221 ÷ 2 = 3 908 024 517 333 110 + 1;
  • 3 908 024 517 333 110 ÷ 2 = 1 954 012 258 666 555 + 0;
  • 1 954 012 258 666 555 ÷ 2 = 977 006 129 333 277 + 1;
  • 977 006 129 333 277 ÷ 2 = 488 503 064 666 638 + 1;
  • 488 503 064 666 638 ÷ 2 = 244 251 532 333 319 + 0;
  • 244 251 532 333 319 ÷ 2 = 122 125 766 166 659 + 1;
  • 122 125 766 166 659 ÷ 2 = 61 062 883 083 329 + 1;
  • 61 062 883 083 329 ÷ 2 = 30 531 441 541 664 + 1;
  • 30 531 441 541 664 ÷ 2 = 15 265 720 770 832 + 0;
  • 15 265 720 770 832 ÷ 2 = 7 632 860 385 416 + 0;
  • 7 632 860 385 416 ÷ 2 = 3 816 430 192 708 + 0;
  • 3 816 430 192 708 ÷ 2 = 1 908 215 096 354 + 0;
  • 1 908 215 096 354 ÷ 2 = 954 107 548 177 + 0;
  • 954 107 548 177 ÷ 2 = 477 053 774 088 + 1;
  • 477 053 774 088 ÷ 2 = 238 526 887 044 + 0;
  • 238 526 887 044 ÷ 2 = 119 263 443 522 + 0;
  • 119 263 443 522 ÷ 2 = 59 631 721 761 + 0;
  • 59 631 721 761 ÷ 2 = 29 815 860 880 + 1;
  • 29 815 860 880 ÷ 2 = 14 907 930 440 + 0;
  • 14 907 930 440 ÷ 2 = 7 453 965 220 + 0;
  • 7 453 965 220 ÷ 2 = 3 726 982 610 + 0;
  • 3 726 982 610 ÷ 2 = 1 863 491 305 + 0;
  • 1 863 491 305 ÷ 2 = 931 745 652 + 1;
  • 931 745 652 ÷ 2 = 465 872 826 + 0;
  • 465 872 826 ÷ 2 = 232 936 413 + 0;
  • 232 936 413 ÷ 2 = 116 468 206 + 1;
  • 116 468 206 ÷ 2 = 58 234 103 + 0;
  • 58 234 103 ÷ 2 = 29 117 051 + 1;
  • 29 117 051 ÷ 2 = 14 558 525 + 1;
  • 14 558 525 ÷ 2 = 7 279 262 + 1;
  • 7 279 262 ÷ 2 = 3 639 631 + 0;
  • 3 639 631 ÷ 2 = 1 819 815 + 1;
  • 1 819 815 ÷ 2 = 909 907 + 1;
  • 909 907 ÷ 2 = 454 953 + 1;
  • 454 953 ÷ 2 = 227 476 + 1;
  • 227 476 ÷ 2 = 113 738 + 0;
  • 113 738 ÷ 2 = 56 869 + 0;
  • 56 869 ÷ 2 = 28 434 + 1;
  • 28 434 ÷ 2 = 14 217 + 0;
  • 14 217 ÷ 2 = 7 108 + 1;
  • 7 108 ÷ 2 = 3 554 + 0;
  • 3 554 ÷ 2 = 1 777 + 0;
  • 1 777 ÷ 2 = 888 + 1;
  • 888 ÷ 2 = 444 + 0;
  • 444 ÷ 2 = 222 + 0;
  • 222 ÷ 2 = 111 + 0;
  • 111 ÷ 2 = 55 + 1;
  • 55 ÷ 2 = 27 + 1;
  • 27 ÷ 2 = 13 + 1;
  • 13 ÷ 2 = 6 + 1;
  • 6 ÷ 2 = 3 + 0;
  • 3 ÷ 2 = 1 + 1;
  • 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.

1 100 011 110 001 010 001 001 100 999 987(10) =


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


3. Normalize the binary representation of the number.

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


1 100 011 110 001 010 001 001 100 999 987(10) =


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


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


1.1011 1100 0100 1010 0111 1011 1010 0100 0010 0010 0000 1110 1101 0111 1010 1111 1111 0100 0010 0101 0011 1111 1010 0110 011(2) × 299


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): 99


Mantissa (not normalized):
1.1011 1100 0100 1010 0111 1011 1010 0100 0010 0010 0000 1110 1101 0111 1010 1111 1111 0100 0010 0101 0011 1111 1010 0110 011


5. Adjust the exponent.

Use the 8 bit excess/bias notation:


Exponent (adjusted) =


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


99 + 2(8-1) - 1 =


(99 + 127)(10) =


226(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;
  • 226 ÷ 2 = 113 + 0;
  • 113 ÷ 2 = 56 + 1;
  • 56 ÷ 2 = 28 + 0;
  • 28 ÷ 2 = 14 + 0;
  • 14 ÷ 2 = 7 + 0;
  • 7 ÷ 2 = 3 + 1;
  • 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) =


226(10) =


1110 0010(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. 101 1110 0010 0101 0011 1101 1101 0010 0001 0001 0000 0111 0110 1011 1101 0111 1111 1010 0001 0010 1001 1111 1101 0011 0011 =


101 1110 0010 0101 0011 1101


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) =
1110 0010


Mantissa (23 bits) =
101 1110 0010 0101 0011 1101


Decimal number 1 100 011 110 001 010 001 001 100 999 987 converted to 32 bit single precision IEEE 754 binary floating point representation:

0 - 1110 0010 - 101 1110 0010 0101 0011 1101


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