-1 148 808 356 456 832 895 106 387 279 940 Converted to 32 Bit Single Precision IEEE 754 Binary Floating Point Representation Standard

Convert decimal -1 148 808 356 456 832 895 106 387 279 940(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 148 808 356 456 832 895 106 387 279 940(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. Start with the positive version of the number:

|-1 148 808 356 456 832 895 106 387 279 940| = 1 148 808 356 456 832 895 106 387 279 940


2. 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 148 808 356 456 832 895 106 387 279 940 ÷ 2 = 574 404 178 228 416 447 553 193 639 970 + 0;
  • 574 404 178 228 416 447 553 193 639 970 ÷ 2 = 287 202 089 114 208 223 776 596 819 985 + 0;
  • 287 202 089 114 208 223 776 596 819 985 ÷ 2 = 143 601 044 557 104 111 888 298 409 992 + 1;
  • 143 601 044 557 104 111 888 298 409 992 ÷ 2 = 71 800 522 278 552 055 944 149 204 996 + 0;
  • 71 800 522 278 552 055 944 149 204 996 ÷ 2 = 35 900 261 139 276 027 972 074 602 498 + 0;
  • 35 900 261 139 276 027 972 074 602 498 ÷ 2 = 17 950 130 569 638 013 986 037 301 249 + 0;
  • 17 950 130 569 638 013 986 037 301 249 ÷ 2 = 8 975 065 284 819 006 993 018 650 624 + 1;
  • 8 975 065 284 819 006 993 018 650 624 ÷ 2 = 4 487 532 642 409 503 496 509 325 312 + 0;
  • 4 487 532 642 409 503 496 509 325 312 ÷ 2 = 2 243 766 321 204 751 748 254 662 656 + 0;
  • 2 243 766 321 204 751 748 254 662 656 ÷ 2 = 1 121 883 160 602 375 874 127 331 328 + 0;
  • 1 121 883 160 602 375 874 127 331 328 ÷ 2 = 560 941 580 301 187 937 063 665 664 + 0;
  • 560 941 580 301 187 937 063 665 664 ÷ 2 = 280 470 790 150 593 968 531 832 832 + 0;
  • 280 470 790 150 593 968 531 832 832 ÷ 2 = 140 235 395 075 296 984 265 916 416 + 0;
  • 140 235 395 075 296 984 265 916 416 ÷ 2 = 70 117 697 537 648 492 132 958 208 + 0;
  • 70 117 697 537 648 492 132 958 208 ÷ 2 = 35 058 848 768 824 246 066 479 104 + 0;
  • 35 058 848 768 824 246 066 479 104 ÷ 2 = 17 529 424 384 412 123 033 239 552 + 0;
  • 17 529 424 384 412 123 033 239 552 ÷ 2 = 8 764 712 192 206 061 516 619 776 + 0;
  • 8 764 712 192 206 061 516 619 776 ÷ 2 = 4 382 356 096 103 030 758 309 888 + 0;
  • 4 382 356 096 103 030 758 309 888 ÷ 2 = 2 191 178 048 051 515 379 154 944 + 0;
  • 2 191 178 048 051 515 379 154 944 ÷ 2 = 1 095 589 024 025 757 689 577 472 + 0;
  • 1 095 589 024 025 757 689 577 472 ÷ 2 = 547 794 512 012 878 844 788 736 + 0;
  • 547 794 512 012 878 844 788 736 ÷ 2 = 273 897 256 006 439 422 394 368 + 0;
  • 273 897 256 006 439 422 394 368 ÷ 2 = 136 948 628 003 219 711 197 184 + 0;
  • 136 948 628 003 219 711 197 184 ÷ 2 = 68 474 314 001 609 855 598 592 + 0;
  • 68 474 314 001 609 855 598 592 ÷ 2 = 34 237 157 000 804 927 799 296 + 0;
  • 34 237 157 000 804 927 799 296 ÷ 2 = 17 118 578 500 402 463 899 648 + 0;
  • 17 118 578 500 402 463 899 648 ÷ 2 = 8 559 289 250 201 231 949 824 + 0;
  • 8 559 289 250 201 231 949 824 ÷ 2 = 4 279 644 625 100 615 974 912 + 0;
  • 4 279 644 625 100 615 974 912 ÷ 2 = 2 139 822 312 550 307 987 456 + 0;
  • 2 139 822 312 550 307 987 456 ÷ 2 = 1 069 911 156 275 153 993 728 + 0;
  • 1 069 911 156 275 153 993 728 ÷ 2 = 534 955 578 137 576 996 864 + 0;
  • 534 955 578 137 576 996 864 ÷ 2 = 267 477 789 068 788 498 432 + 0;
  • 267 477 789 068 788 498 432 ÷ 2 = 133 738 894 534 394 249 216 + 0;
  • 133 738 894 534 394 249 216 ÷ 2 = 66 869 447 267 197 124 608 + 0;
  • 66 869 447 267 197 124 608 ÷ 2 = 33 434 723 633 598 562 304 + 0;
  • 33 434 723 633 598 562 304 ÷ 2 = 16 717 361 816 799 281 152 + 0;
  • 16 717 361 816 799 281 152 ÷ 2 = 8 358 680 908 399 640 576 + 0;
  • 8 358 680 908 399 640 576 ÷ 2 = 4 179 340 454 199 820 288 + 0;
  • 4 179 340 454 199 820 288 ÷ 2 = 2 089 670 227 099 910 144 + 0;
  • 2 089 670 227 099 910 144 ÷ 2 = 1 044 835 113 549 955 072 + 0;
  • 1 044 835 113 549 955 072 ÷ 2 = 522 417 556 774 977 536 + 0;
  • 522 417 556 774 977 536 ÷ 2 = 261 208 778 387 488 768 + 0;
  • 261 208 778 387 488 768 ÷ 2 = 130 604 389 193 744 384 + 0;
  • 130 604 389 193 744 384 ÷ 2 = 65 302 194 596 872 192 + 0;
  • 65 302 194 596 872 192 ÷ 2 = 32 651 097 298 436 096 + 0;
  • 32 651 097 298 436 096 ÷ 2 = 16 325 548 649 218 048 + 0;
  • 16 325 548 649 218 048 ÷ 2 = 8 162 774 324 609 024 + 0;
  • 8 162 774 324 609 024 ÷ 2 = 4 081 387 162 304 512 + 0;
  • 4 081 387 162 304 512 ÷ 2 = 2 040 693 581 152 256 + 0;
  • 2 040 693 581 152 256 ÷ 2 = 1 020 346 790 576 128 + 0;
  • 1 020 346 790 576 128 ÷ 2 = 510 173 395 288 064 + 0;
  • 510 173 395 288 064 ÷ 2 = 255 086 697 644 032 + 0;
  • 255 086 697 644 032 ÷ 2 = 127 543 348 822 016 + 0;
  • 127 543 348 822 016 ÷ 2 = 63 771 674 411 008 + 0;
  • 63 771 674 411 008 ÷ 2 = 31 885 837 205 504 + 0;
  • 31 885 837 205 504 ÷ 2 = 15 942 918 602 752 + 0;
  • 15 942 918 602 752 ÷ 2 = 7 971 459 301 376 + 0;
  • 7 971 459 301 376 ÷ 2 = 3 985 729 650 688 + 0;
  • 3 985 729 650 688 ÷ 2 = 1 992 864 825 344 + 0;
  • 1 992 864 825 344 ÷ 2 = 996 432 412 672 + 0;
  • 996 432 412 672 ÷ 2 = 498 216 206 336 + 0;
  • 498 216 206 336 ÷ 2 = 249 108 103 168 + 0;
  • 249 108 103 168 ÷ 2 = 124 554 051 584 + 0;
  • 124 554 051 584 ÷ 2 = 62 277 025 792 + 0;
  • 62 277 025 792 ÷ 2 = 31 138 512 896 + 0;
  • 31 138 512 896 ÷ 2 = 15 569 256 448 + 0;
  • 15 569 256 448 ÷ 2 = 7 784 628 224 + 0;
  • 7 784 628 224 ÷ 2 = 3 892 314 112 + 0;
  • 3 892 314 112 ÷ 2 = 1 946 157 056 + 0;
  • 1 946 157 056 ÷ 2 = 973 078 528 + 0;
  • 973 078 528 ÷ 2 = 486 539 264 + 0;
  • 486 539 264 ÷ 2 = 243 269 632 + 0;
  • 243 269 632 ÷ 2 = 121 634 816 + 0;
  • 121 634 816 ÷ 2 = 60 817 408 + 0;
  • 60 817 408 ÷ 2 = 30 408 704 + 0;
  • 30 408 704 ÷ 2 = 15 204 352 + 0;
  • 15 204 352 ÷ 2 = 7 602 176 + 0;
  • 7 602 176 ÷ 2 = 3 801 088 + 0;
  • 3 801 088 ÷ 2 = 1 900 544 + 0;
  • 1 900 544 ÷ 2 = 950 272 + 0;
  • 950 272 ÷ 2 = 475 136 + 0;
  • 475 136 ÷ 2 = 237 568 + 0;
  • 237 568 ÷ 2 = 118 784 + 0;
  • 118 784 ÷ 2 = 59 392 + 0;
  • 59 392 ÷ 2 = 29 696 + 0;
  • 29 696 ÷ 2 = 14 848 + 0;
  • 14 848 ÷ 2 = 7 424 + 0;
  • 7 424 ÷ 2 = 3 712 + 0;
  • 3 712 ÷ 2 = 1 856 + 0;
  • 1 856 ÷ 2 = 928 + 0;
  • 928 ÷ 2 = 464 + 0;
  • 464 ÷ 2 = 232 + 0;
  • 232 ÷ 2 = 116 + 0;
  • 116 ÷ 2 = 58 + 0;
  • 58 ÷ 2 = 29 + 0;
  • 29 ÷ 2 = 14 + 1;
  • 14 ÷ 2 = 7 + 0;
  • 7 ÷ 2 = 3 + 1;
  • 3 ÷ 2 = 1 + 1;
  • 1 ÷ 2 = 0 + 1;

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

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

1 148 808 356 456 832 895 106 387 279 940(10) =


1110 1000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0100 0100(2)


4. 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 148 808 356 456 832 895 106 387 279 940(10) =


1110 1000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0100 0100(2) =


1110 1000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0100 0100(2) × 20 =


1.1101 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 1000 100(2) × 299


5. 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 1 (a negative number)


Exponent (unadjusted): 99


Mantissa (not normalized):
1.1101 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 1000 100


6. 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)


7. 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;

8. 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)


9. 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. 110 1000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0000 0100 0100 =


110 1000 0000 0000 0000 0000


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

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


Exponent (8 bits) =
1110 0010


Mantissa (23 bits) =
110 1000 0000 0000 0000 0000


Decimal number -1 148 808 356 456 832 895 106 387 279 940 converted to 32 bit single precision IEEE 754 binary floating point representation:

1 - 1110 0010 - 110 1000 0000 0000 0000 0000


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