1 011 111 001 100 000 000 000 000 000 197 Converted to 32 Bit Single Precision IEEE 754 Binary Floating Point Representation Standard

Convert decimal 1 011 111 001 100 000 000 000 000 000 197(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 011 111 001 100 000 000 000 000 000 197(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 011 111 001 100 000 000 000 000 000 197 ÷ 2 = 505 555 500 550 000 000 000 000 000 098 + 1;
  • 505 555 500 550 000 000 000 000 000 098 ÷ 2 = 252 777 750 275 000 000 000 000 000 049 + 0;
  • 252 777 750 275 000 000 000 000 000 049 ÷ 2 = 126 388 875 137 500 000 000 000 000 024 + 1;
  • 126 388 875 137 500 000 000 000 000 024 ÷ 2 = 63 194 437 568 750 000 000 000 000 012 + 0;
  • 63 194 437 568 750 000 000 000 000 012 ÷ 2 = 31 597 218 784 375 000 000 000 000 006 + 0;
  • 31 597 218 784 375 000 000 000 000 006 ÷ 2 = 15 798 609 392 187 500 000 000 000 003 + 0;
  • 15 798 609 392 187 500 000 000 000 003 ÷ 2 = 7 899 304 696 093 750 000 000 000 001 + 1;
  • 7 899 304 696 093 750 000 000 000 001 ÷ 2 = 3 949 652 348 046 875 000 000 000 000 + 1;
  • 3 949 652 348 046 875 000 000 000 000 ÷ 2 = 1 974 826 174 023 437 500 000 000 000 + 0;
  • 1 974 826 174 023 437 500 000 000 000 ÷ 2 = 987 413 087 011 718 750 000 000 000 + 0;
  • 987 413 087 011 718 750 000 000 000 ÷ 2 = 493 706 543 505 859 375 000 000 000 + 0;
  • 493 706 543 505 859 375 000 000 000 ÷ 2 = 246 853 271 752 929 687 500 000 000 + 0;
  • 246 853 271 752 929 687 500 000 000 ÷ 2 = 123 426 635 876 464 843 750 000 000 + 0;
  • 123 426 635 876 464 843 750 000 000 ÷ 2 = 61 713 317 938 232 421 875 000 000 + 0;
  • 61 713 317 938 232 421 875 000 000 ÷ 2 = 30 856 658 969 116 210 937 500 000 + 0;
  • 30 856 658 969 116 210 937 500 000 ÷ 2 = 15 428 329 484 558 105 468 750 000 + 0;
  • 15 428 329 484 558 105 468 750 000 ÷ 2 = 7 714 164 742 279 052 734 375 000 + 0;
  • 7 714 164 742 279 052 734 375 000 ÷ 2 = 3 857 082 371 139 526 367 187 500 + 0;
  • 3 857 082 371 139 526 367 187 500 ÷ 2 = 1 928 541 185 569 763 183 593 750 + 0;
  • 1 928 541 185 569 763 183 593 750 ÷ 2 = 964 270 592 784 881 591 796 875 + 0;
  • 964 270 592 784 881 591 796 875 ÷ 2 = 482 135 296 392 440 795 898 437 + 1;
  • 482 135 296 392 440 795 898 437 ÷ 2 = 241 067 648 196 220 397 949 218 + 1;
  • 241 067 648 196 220 397 949 218 ÷ 2 = 120 533 824 098 110 198 974 609 + 0;
  • 120 533 824 098 110 198 974 609 ÷ 2 = 60 266 912 049 055 099 487 304 + 1;
  • 60 266 912 049 055 099 487 304 ÷ 2 = 30 133 456 024 527 549 743 652 + 0;
  • 30 133 456 024 527 549 743 652 ÷ 2 = 15 066 728 012 263 774 871 826 + 0;
  • 15 066 728 012 263 774 871 826 ÷ 2 = 7 533 364 006 131 887 435 913 + 0;
  • 7 533 364 006 131 887 435 913 ÷ 2 = 3 766 682 003 065 943 717 956 + 1;
  • 3 766 682 003 065 943 717 956 ÷ 2 = 1 883 341 001 532 971 858 978 + 0;
  • 1 883 341 001 532 971 858 978 ÷ 2 = 941 670 500 766 485 929 489 + 0;
  • 941 670 500 766 485 929 489 ÷ 2 = 470 835 250 383 242 964 744 + 1;
  • 470 835 250 383 242 964 744 ÷ 2 = 235 417 625 191 621 482 372 + 0;
  • 235 417 625 191 621 482 372 ÷ 2 = 117 708 812 595 810 741 186 + 0;
  • 117 708 812 595 810 741 186 ÷ 2 = 58 854 406 297 905 370 593 + 0;
  • 58 854 406 297 905 370 593 ÷ 2 = 29 427 203 148 952 685 296 + 1;
  • 29 427 203 148 952 685 296 ÷ 2 = 14 713 601 574 476 342 648 + 0;
  • 14 713 601 574 476 342 648 ÷ 2 = 7 356 800 787 238 171 324 + 0;
  • 7 356 800 787 238 171 324 ÷ 2 = 3 678 400 393 619 085 662 + 0;
  • 3 678 400 393 619 085 662 ÷ 2 = 1 839 200 196 809 542 831 + 0;
  • 1 839 200 196 809 542 831 ÷ 2 = 919 600 098 404 771 415 + 1;
  • 919 600 098 404 771 415 ÷ 2 = 459 800 049 202 385 707 + 1;
  • 459 800 049 202 385 707 ÷ 2 = 229 900 024 601 192 853 + 1;
  • 229 900 024 601 192 853 ÷ 2 = 114 950 012 300 596 426 + 1;
  • 114 950 012 300 596 426 ÷ 2 = 57 475 006 150 298 213 + 0;
  • 57 475 006 150 298 213 ÷ 2 = 28 737 503 075 149 106 + 1;
  • 28 737 503 075 149 106 ÷ 2 = 14 368 751 537 574 553 + 0;
  • 14 368 751 537 574 553 ÷ 2 = 7 184 375 768 787 276 + 1;
  • 7 184 375 768 787 276 ÷ 2 = 3 592 187 884 393 638 + 0;
  • 3 592 187 884 393 638 ÷ 2 = 1 796 093 942 196 819 + 0;
  • 1 796 093 942 196 819 ÷ 2 = 898 046 971 098 409 + 1;
  • 898 046 971 098 409 ÷ 2 = 449 023 485 549 204 + 1;
  • 449 023 485 549 204 ÷ 2 = 224 511 742 774 602 + 0;
  • 224 511 742 774 602 ÷ 2 = 112 255 871 387 301 + 0;
  • 112 255 871 387 301 ÷ 2 = 56 127 935 693 650 + 1;
  • 56 127 935 693 650 ÷ 2 = 28 063 967 846 825 + 0;
  • 28 063 967 846 825 ÷ 2 = 14 031 983 923 412 + 1;
  • 14 031 983 923 412 ÷ 2 = 7 015 991 961 706 + 0;
  • 7 015 991 961 706 ÷ 2 = 3 507 995 980 853 + 0;
  • 3 507 995 980 853 ÷ 2 = 1 753 997 990 426 + 1;
  • 1 753 997 990 426 ÷ 2 = 876 998 995 213 + 0;
  • 876 998 995 213 ÷ 2 = 438 499 497 606 + 1;
  • 438 499 497 606 ÷ 2 = 219 249 748 803 + 0;
  • 219 249 748 803 ÷ 2 = 109 624 874 401 + 1;
  • 109 624 874 401 ÷ 2 = 54 812 437 200 + 1;
  • 54 812 437 200 ÷ 2 = 27 406 218 600 + 0;
  • 27 406 218 600 ÷ 2 = 13 703 109 300 + 0;
  • 13 703 109 300 ÷ 2 = 6 851 554 650 + 0;
  • 6 851 554 650 ÷ 2 = 3 425 777 325 + 0;
  • 3 425 777 325 ÷ 2 = 1 712 888 662 + 1;
  • 1 712 888 662 ÷ 2 = 856 444 331 + 0;
  • 856 444 331 ÷ 2 = 428 222 165 + 1;
  • 428 222 165 ÷ 2 = 214 111 082 + 1;
  • 214 111 082 ÷ 2 = 107 055 541 + 0;
  • 107 055 541 ÷ 2 = 53 527 770 + 1;
  • 53 527 770 ÷ 2 = 26 763 885 + 0;
  • 26 763 885 ÷ 2 = 13 381 942 + 1;
  • 13 381 942 ÷ 2 = 6 690 971 + 0;
  • 6 690 971 ÷ 2 = 3 345 485 + 1;
  • 3 345 485 ÷ 2 = 1 672 742 + 1;
  • 1 672 742 ÷ 2 = 836 371 + 0;
  • 836 371 ÷ 2 = 418 185 + 1;
  • 418 185 ÷ 2 = 209 092 + 1;
  • 209 092 ÷ 2 = 104 546 + 0;
  • 104 546 ÷ 2 = 52 273 + 0;
  • 52 273 ÷ 2 = 26 136 + 1;
  • 26 136 ÷ 2 = 13 068 + 0;
  • 13 068 ÷ 2 = 6 534 + 0;
  • 6 534 ÷ 2 = 3 267 + 0;
  • 3 267 ÷ 2 = 1 633 + 1;
  • 1 633 ÷ 2 = 816 + 1;
  • 816 ÷ 2 = 408 + 0;
  • 408 ÷ 2 = 204 + 0;
  • 204 ÷ 2 = 102 + 0;
  • 102 ÷ 2 = 51 + 0;
  • 51 ÷ 2 = 25 + 1;
  • 25 ÷ 2 = 12 + 1;
  • 12 ÷ 2 = 6 + 0;
  • 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 011 111 001 100 000 000 000 000 000 197(10) =


1100 1100 0011 0001 0011 0110 1010 1101 0000 1101 0100 1010 0110 0101 0111 1000 0100 0100 1000 1011 0000 0000 0000 1100 0101(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 011 111 001 100 000 000 000 000 000 197(10) =


1100 1100 0011 0001 0011 0110 1010 1101 0000 1101 0100 1010 0110 0101 0111 1000 0100 0100 1000 1011 0000 0000 0000 1100 0101(2) =


1100 1100 0011 0001 0011 0110 1010 1101 0000 1101 0100 1010 0110 0101 0111 1000 0100 0100 1000 1011 0000 0000 0000 1100 0101(2) × 20 =


1.1001 1000 0110 0010 0110 1101 0101 1010 0001 1010 1001 0100 1100 1010 1111 0000 1000 1001 0001 0110 0000 0000 0001 1000 101(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.1001 1000 0110 0010 0110 1101 0101 1010 0001 1010 1001 0100 1100 1010 1111 0000 1000 1001 0001 0110 0000 0000 0001 1000 101


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. 100 1100 0011 0001 0011 0110 1010 1101 0000 1101 0100 1010 0110 0101 0111 1000 0100 0100 1000 1011 0000 0000 0000 1100 0101 =


100 1100 0011 0001 0011 0110


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) =
100 1100 0011 0001 0011 0110


Decimal number 1 011 111 001 100 000 000 000 000 000 197 converted to 32 bit single precision IEEE 754 binary floating point representation:

0 - 1110 0010 - 100 1100 0011 0001 0011 0110

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