1 011 000 001 110 010 011 010 000 111 254 Converted to 32 Bit Single Precision IEEE 754 Binary Floating Point Representation Standard

Convert decimal 1 011 000 001 110 010 011 010 000 111 254(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 000 001 110 010 011 010 000 111 254(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 000 001 110 010 011 010 000 111 254 ÷ 2 = 505 500 000 555 005 005 505 000 055 627 + 0;
  • 505 500 000 555 005 005 505 000 055 627 ÷ 2 = 252 750 000 277 502 502 752 500 027 813 + 1;
  • 252 750 000 277 502 502 752 500 027 813 ÷ 2 = 126 375 000 138 751 251 376 250 013 906 + 1;
  • 126 375 000 138 751 251 376 250 013 906 ÷ 2 = 63 187 500 069 375 625 688 125 006 953 + 0;
  • 63 187 500 069 375 625 688 125 006 953 ÷ 2 = 31 593 750 034 687 812 844 062 503 476 + 1;
  • 31 593 750 034 687 812 844 062 503 476 ÷ 2 = 15 796 875 017 343 906 422 031 251 738 + 0;
  • 15 796 875 017 343 906 422 031 251 738 ÷ 2 = 7 898 437 508 671 953 211 015 625 869 + 0;
  • 7 898 437 508 671 953 211 015 625 869 ÷ 2 = 3 949 218 754 335 976 605 507 812 934 + 1;
  • 3 949 218 754 335 976 605 507 812 934 ÷ 2 = 1 974 609 377 167 988 302 753 906 467 + 0;
  • 1 974 609 377 167 988 302 753 906 467 ÷ 2 = 987 304 688 583 994 151 376 953 233 + 1;
  • 987 304 688 583 994 151 376 953 233 ÷ 2 = 493 652 344 291 997 075 688 476 616 + 1;
  • 493 652 344 291 997 075 688 476 616 ÷ 2 = 246 826 172 145 998 537 844 238 308 + 0;
  • 246 826 172 145 998 537 844 238 308 ÷ 2 = 123 413 086 072 999 268 922 119 154 + 0;
  • 123 413 086 072 999 268 922 119 154 ÷ 2 = 61 706 543 036 499 634 461 059 577 + 0;
  • 61 706 543 036 499 634 461 059 577 ÷ 2 = 30 853 271 518 249 817 230 529 788 + 1;
  • 30 853 271 518 249 817 230 529 788 ÷ 2 = 15 426 635 759 124 908 615 264 894 + 0;
  • 15 426 635 759 124 908 615 264 894 ÷ 2 = 7 713 317 879 562 454 307 632 447 + 0;
  • 7 713 317 879 562 454 307 632 447 ÷ 2 = 3 856 658 939 781 227 153 816 223 + 1;
  • 3 856 658 939 781 227 153 816 223 ÷ 2 = 1 928 329 469 890 613 576 908 111 + 1;
  • 1 928 329 469 890 613 576 908 111 ÷ 2 = 964 164 734 945 306 788 454 055 + 1;
  • 964 164 734 945 306 788 454 055 ÷ 2 = 482 082 367 472 653 394 227 027 + 1;
  • 482 082 367 472 653 394 227 027 ÷ 2 = 241 041 183 736 326 697 113 513 + 1;
  • 241 041 183 736 326 697 113 513 ÷ 2 = 120 520 591 868 163 348 556 756 + 1;
  • 120 520 591 868 163 348 556 756 ÷ 2 = 60 260 295 934 081 674 278 378 + 0;
  • 60 260 295 934 081 674 278 378 ÷ 2 = 30 130 147 967 040 837 139 189 + 0;
  • 30 130 147 967 040 837 139 189 ÷ 2 = 15 065 073 983 520 418 569 594 + 1;
  • 15 065 073 983 520 418 569 594 ÷ 2 = 7 532 536 991 760 209 284 797 + 0;
  • 7 532 536 991 760 209 284 797 ÷ 2 = 3 766 268 495 880 104 642 398 + 1;
  • 3 766 268 495 880 104 642 398 ÷ 2 = 1 883 134 247 940 052 321 199 + 0;
  • 1 883 134 247 940 052 321 199 ÷ 2 = 941 567 123 970 026 160 599 + 1;
  • 941 567 123 970 026 160 599 ÷ 2 = 470 783 561 985 013 080 299 + 1;
  • 470 783 561 985 013 080 299 ÷ 2 = 235 391 780 992 506 540 149 + 1;
  • 235 391 780 992 506 540 149 ÷ 2 = 117 695 890 496 253 270 074 + 1;
  • 117 695 890 496 253 270 074 ÷ 2 = 58 847 945 248 126 635 037 + 0;
  • 58 847 945 248 126 635 037 ÷ 2 = 29 423 972 624 063 317 518 + 1;
  • 29 423 972 624 063 317 518 ÷ 2 = 14 711 986 312 031 658 759 + 0;
  • 14 711 986 312 031 658 759 ÷ 2 = 7 355 993 156 015 829 379 + 1;
  • 7 355 993 156 015 829 379 ÷ 2 = 3 677 996 578 007 914 689 + 1;
  • 3 677 996 578 007 914 689 ÷ 2 = 1 838 998 289 003 957 344 + 1;
  • 1 838 998 289 003 957 344 ÷ 2 = 919 499 144 501 978 672 + 0;
  • 919 499 144 501 978 672 ÷ 2 = 459 749 572 250 989 336 + 0;
  • 459 749 572 250 989 336 ÷ 2 = 229 874 786 125 494 668 + 0;
  • 229 874 786 125 494 668 ÷ 2 = 114 937 393 062 747 334 + 0;
  • 114 937 393 062 747 334 ÷ 2 = 57 468 696 531 373 667 + 0;
  • 57 468 696 531 373 667 ÷ 2 = 28 734 348 265 686 833 + 1;
  • 28 734 348 265 686 833 ÷ 2 = 14 367 174 132 843 416 + 1;
  • 14 367 174 132 843 416 ÷ 2 = 7 183 587 066 421 708 + 0;
  • 7 183 587 066 421 708 ÷ 2 = 3 591 793 533 210 854 + 0;
  • 3 591 793 533 210 854 ÷ 2 = 1 795 896 766 605 427 + 0;
  • 1 795 896 766 605 427 ÷ 2 = 897 948 383 302 713 + 1;
  • 897 948 383 302 713 ÷ 2 = 448 974 191 651 356 + 1;
  • 448 974 191 651 356 ÷ 2 = 224 487 095 825 678 + 0;
  • 224 487 095 825 678 ÷ 2 = 112 243 547 912 839 + 0;
  • 112 243 547 912 839 ÷ 2 = 56 121 773 956 419 + 1;
  • 56 121 773 956 419 ÷ 2 = 28 060 886 978 209 + 1;
  • 28 060 886 978 209 ÷ 2 = 14 030 443 489 104 + 1;
  • 14 030 443 489 104 ÷ 2 = 7 015 221 744 552 + 0;
  • 7 015 221 744 552 ÷ 2 = 3 507 610 872 276 + 0;
  • 3 507 610 872 276 ÷ 2 = 1 753 805 436 138 + 0;
  • 1 753 805 436 138 ÷ 2 = 876 902 718 069 + 0;
  • 876 902 718 069 ÷ 2 = 438 451 359 034 + 1;
  • 438 451 359 034 ÷ 2 = 219 225 679 517 + 0;
  • 219 225 679 517 ÷ 2 = 109 612 839 758 + 1;
  • 109 612 839 758 ÷ 2 = 54 806 419 879 + 0;
  • 54 806 419 879 ÷ 2 = 27 403 209 939 + 1;
  • 27 403 209 939 ÷ 2 = 13 701 604 969 + 1;
  • 13 701 604 969 ÷ 2 = 6 850 802 484 + 1;
  • 6 850 802 484 ÷ 2 = 3 425 401 242 + 0;
  • 3 425 401 242 ÷ 2 = 1 712 700 621 + 0;
  • 1 712 700 621 ÷ 2 = 856 350 310 + 1;
  • 856 350 310 ÷ 2 = 428 175 155 + 0;
  • 428 175 155 ÷ 2 = 214 087 577 + 1;
  • 214 087 577 ÷ 2 = 107 043 788 + 1;
  • 107 043 788 ÷ 2 = 53 521 894 + 0;
  • 53 521 894 ÷ 2 = 26 760 947 + 0;
  • 26 760 947 ÷ 2 = 13 380 473 + 1;
  • 13 380 473 ÷ 2 = 6 690 236 + 1;
  • 6 690 236 ÷ 2 = 3 345 118 + 0;
  • 3 345 118 ÷ 2 = 1 672 559 + 0;
  • 1 672 559 ÷ 2 = 836 279 + 1;
  • 836 279 ÷ 2 = 418 139 + 1;
  • 418 139 ÷ 2 = 209 069 + 1;
  • 209 069 ÷ 2 = 104 534 + 1;
  • 104 534 ÷ 2 = 52 267 + 0;
  • 52 267 ÷ 2 = 26 133 + 1;
  • 26 133 ÷ 2 = 13 066 + 1;
  • 13 066 ÷ 2 = 6 533 + 0;
  • 6 533 ÷ 2 = 3 266 + 1;
  • 3 266 ÷ 2 = 1 633 + 0;
  • 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 000 001 110 010 011 010 000 111 254(10) =


1100 1100 0010 1011 0111 1001 1001 1010 0111 0101 0000 1110 0110 0011 0000 0111 0101 1110 1010 0111 1110 0100 0110 1001 0110(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 000 001 110 010 011 010 000 111 254(10) =


1100 1100 0010 1011 0111 1001 1001 1010 0111 0101 0000 1110 0110 0011 0000 0111 0101 1110 1010 0111 1110 0100 0110 1001 0110(2) =


1100 1100 0010 1011 0111 1001 1001 1010 0111 0101 0000 1110 0110 0011 0000 0111 0101 1110 1010 0111 1110 0100 0110 1001 0110(2) × 20 =


1.1001 1000 0101 0110 1111 0011 0011 0100 1110 1010 0001 1100 1100 0110 0000 1110 1011 1101 0100 1111 1100 1000 1101 0010 110(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 0101 0110 1111 0011 0011 0100 1110 1010 0001 1100 1100 0110 0000 1110 1011 1101 0100 1111 1100 1000 1101 0010 110


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 0010 1011 0111 1001 1001 1010 0111 0101 0000 1110 0110 0011 0000 0111 0101 1110 1010 0111 1110 0100 0110 1001 0110 =


100 1100 0010 1011 0111 1001


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 0010 1011 0111 1001


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

0 - 1110 0010 - 100 1100 0010 1011 0111 1001


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