111 000 099 999 999 999 999 999 999 999 999 999 999 999 999 319 Converted to 64 Bit Double Precision IEEE 754 Binary Floating Point Representation Standard

Convert decimal 111 000 099 999 999 999 999 999 999 999 999 999 999 999 999 319(10) to 64 bit double precision IEEE 754 binary floating point representation standard (1 bit for sign, 11 bits for exponent, 52 bits for mantissa)

What are the steps to convert decimal number
111 000 099 999 999 999 999 999 999 999 999 999 999 999 999 319(10) to 64 bit double precision IEEE 754 binary floating point representation (1 bit for sign, 11 bits for exponent, 52 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;
  • 111 000 099 999 999 999 999 999 999 999 999 999 999 999 999 319 ÷ 2 = 55 500 049 999 999 999 999 999 999 999 999 999 999 999 999 659 + 1;
  • 55 500 049 999 999 999 999 999 999 999 999 999 999 999 999 659 ÷ 2 = 27 750 024 999 999 999 999 999 999 999 999 999 999 999 999 829 + 1;
  • 27 750 024 999 999 999 999 999 999 999 999 999 999 999 999 829 ÷ 2 = 13 875 012 499 999 999 999 999 999 999 999 999 999 999 999 914 + 1;
  • 13 875 012 499 999 999 999 999 999 999 999 999 999 999 999 914 ÷ 2 = 6 937 506 249 999 999 999 999 999 999 999 999 999 999 999 957 + 0;
  • 6 937 506 249 999 999 999 999 999 999 999 999 999 999 999 957 ÷ 2 = 3 468 753 124 999 999 999 999 999 999 999 999 999 999 999 978 + 1;
  • 3 468 753 124 999 999 999 999 999 999 999 999 999 999 999 978 ÷ 2 = 1 734 376 562 499 999 999 999 999 999 999 999 999 999 999 989 + 0;
  • 1 734 376 562 499 999 999 999 999 999 999 999 999 999 999 989 ÷ 2 = 867 188 281 249 999 999 999 999 999 999 999 999 999 999 994 + 1;
  • 867 188 281 249 999 999 999 999 999 999 999 999 999 999 994 ÷ 2 = 433 594 140 624 999 999 999 999 999 999 999 999 999 999 997 + 0;
  • 433 594 140 624 999 999 999 999 999 999 999 999 999 999 997 ÷ 2 = 216 797 070 312 499 999 999 999 999 999 999 999 999 999 998 + 1;
  • 216 797 070 312 499 999 999 999 999 999 999 999 999 999 998 ÷ 2 = 108 398 535 156 249 999 999 999 999 999 999 999 999 999 999 + 0;
  • 108 398 535 156 249 999 999 999 999 999 999 999 999 999 999 ÷ 2 = 54 199 267 578 124 999 999 999 999 999 999 999 999 999 999 + 1;
  • 54 199 267 578 124 999 999 999 999 999 999 999 999 999 999 ÷ 2 = 27 099 633 789 062 499 999 999 999 999 999 999 999 999 999 + 1;
  • 27 099 633 789 062 499 999 999 999 999 999 999 999 999 999 ÷ 2 = 13 549 816 894 531 249 999 999 999 999 999 999 999 999 999 + 1;
  • 13 549 816 894 531 249 999 999 999 999 999 999 999 999 999 ÷ 2 = 6 774 908 447 265 624 999 999 999 999 999 999 999 999 999 + 1;
  • 6 774 908 447 265 624 999 999 999 999 999 999 999 999 999 ÷ 2 = 3 387 454 223 632 812 499 999 999 999 999 999 999 999 999 + 1;
  • 3 387 454 223 632 812 499 999 999 999 999 999 999 999 999 ÷ 2 = 1 693 727 111 816 406 249 999 999 999 999 999 999 999 999 + 1;
  • 1 693 727 111 816 406 249 999 999 999 999 999 999 999 999 ÷ 2 = 846 863 555 908 203 124 999 999 999 999 999 999 999 999 + 1;
  • 846 863 555 908 203 124 999 999 999 999 999 999 999 999 ÷ 2 = 423 431 777 954 101 562 499 999 999 999 999 999 999 999 + 1;
  • 423 431 777 954 101 562 499 999 999 999 999 999 999 999 ÷ 2 = 211 715 888 977 050 781 249 999 999 999 999 999 999 999 + 1;
  • 211 715 888 977 050 781 249 999 999 999 999 999 999 999 ÷ 2 = 105 857 944 488 525 390 624 999 999 999 999 999 999 999 + 1;
  • 105 857 944 488 525 390 624 999 999 999 999 999 999 999 ÷ 2 = 52 928 972 244 262 695 312 499 999 999 999 999 999 999 + 1;
  • 52 928 972 244 262 695 312 499 999 999 999 999 999 999 ÷ 2 = 26 464 486 122 131 347 656 249 999 999 999 999 999 999 + 1;
  • 26 464 486 122 131 347 656 249 999 999 999 999 999 999 ÷ 2 = 13 232 243 061 065 673 828 124 999 999 999 999 999 999 + 1;
  • 13 232 243 061 065 673 828 124 999 999 999 999 999 999 ÷ 2 = 6 616 121 530 532 836 914 062 499 999 999 999 999 999 + 1;
  • 6 616 121 530 532 836 914 062 499 999 999 999 999 999 ÷ 2 = 3 308 060 765 266 418 457 031 249 999 999 999 999 999 + 1;
  • 3 308 060 765 266 418 457 031 249 999 999 999 999 999 ÷ 2 = 1 654 030 382 633 209 228 515 624 999 999 999 999 999 + 1;
  • 1 654 030 382 633 209 228 515 624 999 999 999 999 999 ÷ 2 = 827 015 191 316 604 614 257 812 499 999 999 999 999 + 1;
  • 827 015 191 316 604 614 257 812 499 999 999 999 999 ÷ 2 = 413 507 595 658 302 307 128 906 249 999 999 999 999 + 1;
  • 413 507 595 658 302 307 128 906 249 999 999 999 999 ÷ 2 = 206 753 797 829 151 153 564 453 124 999 999 999 999 + 1;
  • 206 753 797 829 151 153 564 453 124 999 999 999 999 ÷ 2 = 103 376 898 914 575 576 782 226 562 499 999 999 999 + 1;
  • 103 376 898 914 575 576 782 226 562 499 999 999 999 ÷ 2 = 51 688 449 457 287 788 391 113 281 249 999 999 999 + 1;
  • 51 688 449 457 287 788 391 113 281 249 999 999 999 ÷ 2 = 25 844 224 728 643 894 195 556 640 624 999 999 999 + 1;
  • 25 844 224 728 643 894 195 556 640 624 999 999 999 ÷ 2 = 12 922 112 364 321 947 097 778 320 312 499 999 999 + 1;
  • 12 922 112 364 321 947 097 778 320 312 499 999 999 ÷ 2 = 6 461 056 182 160 973 548 889 160 156 249 999 999 + 1;
  • 6 461 056 182 160 973 548 889 160 156 249 999 999 ÷ 2 = 3 230 528 091 080 486 774 444 580 078 124 999 999 + 1;
  • 3 230 528 091 080 486 774 444 580 078 124 999 999 ÷ 2 = 1 615 264 045 540 243 387 222 290 039 062 499 999 + 1;
  • 1 615 264 045 540 243 387 222 290 039 062 499 999 ÷ 2 = 807 632 022 770 121 693 611 145 019 531 249 999 + 1;
  • 807 632 022 770 121 693 611 145 019 531 249 999 ÷ 2 = 403 816 011 385 060 846 805 572 509 765 624 999 + 1;
  • 403 816 011 385 060 846 805 572 509 765 624 999 ÷ 2 = 201 908 005 692 530 423 402 786 254 882 812 499 + 1;
  • 201 908 005 692 530 423 402 786 254 882 812 499 ÷ 2 = 100 954 002 846 265 211 701 393 127 441 406 249 + 1;
  • 100 954 002 846 265 211 701 393 127 441 406 249 ÷ 2 = 50 477 001 423 132 605 850 696 563 720 703 124 + 1;
  • 50 477 001 423 132 605 850 696 563 720 703 124 ÷ 2 = 25 238 500 711 566 302 925 348 281 860 351 562 + 0;
  • 25 238 500 711 566 302 925 348 281 860 351 562 ÷ 2 = 12 619 250 355 783 151 462 674 140 930 175 781 + 0;
  • 12 619 250 355 783 151 462 674 140 930 175 781 ÷ 2 = 6 309 625 177 891 575 731 337 070 465 087 890 + 1;
  • 6 309 625 177 891 575 731 337 070 465 087 890 ÷ 2 = 3 154 812 588 945 787 865 668 535 232 543 945 + 0;
  • 3 154 812 588 945 787 865 668 535 232 543 945 ÷ 2 = 1 577 406 294 472 893 932 834 267 616 271 972 + 1;
  • 1 577 406 294 472 893 932 834 267 616 271 972 ÷ 2 = 788 703 147 236 446 966 417 133 808 135 986 + 0;
  • 788 703 147 236 446 966 417 133 808 135 986 ÷ 2 = 394 351 573 618 223 483 208 566 904 067 993 + 0;
  • 394 351 573 618 223 483 208 566 904 067 993 ÷ 2 = 197 175 786 809 111 741 604 283 452 033 996 + 1;
  • 197 175 786 809 111 741 604 283 452 033 996 ÷ 2 = 98 587 893 404 555 870 802 141 726 016 998 + 0;
  • 98 587 893 404 555 870 802 141 726 016 998 ÷ 2 = 49 293 946 702 277 935 401 070 863 008 499 + 0;
  • 49 293 946 702 277 935 401 070 863 008 499 ÷ 2 = 24 646 973 351 138 967 700 535 431 504 249 + 1;
  • 24 646 973 351 138 967 700 535 431 504 249 ÷ 2 = 12 323 486 675 569 483 850 267 715 752 124 + 1;
  • 12 323 486 675 569 483 850 267 715 752 124 ÷ 2 = 6 161 743 337 784 741 925 133 857 876 062 + 0;
  • 6 161 743 337 784 741 925 133 857 876 062 ÷ 2 = 3 080 871 668 892 370 962 566 928 938 031 + 0;
  • 3 080 871 668 892 370 962 566 928 938 031 ÷ 2 = 1 540 435 834 446 185 481 283 464 469 015 + 1;
  • 1 540 435 834 446 185 481 283 464 469 015 ÷ 2 = 770 217 917 223 092 740 641 732 234 507 + 1;
  • 770 217 917 223 092 740 641 732 234 507 ÷ 2 = 385 108 958 611 546 370 320 866 117 253 + 1;
  • 385 108 958 611 546 370 320 866 117 253 ÷ 2 = 192 554 479 305 773 185 160 433 058 626 + 1;
  • 192 554 479 305 773 185 160 433 058 626 ÷ 2 = 96 277 239 652 886 592 580 216 529 313 + 0;
  • 96 277 239 652 886 592 580 216 529 313 ÷ 2 = 48 138 619 826 443 296 290 108 264 656 + 1;
  • 48 138 619 826 443 296 290 108 264 656 ÷ 2 = 24 069 309 913 221 648 145 054 132 328 + 0;
  • 24 069 309 913 221 648 145 054 132 328 ÷ 2 = 12 034 654 956 610 824 072 527 066 164 + 0;
  • 12 034 654 956 610 824 072 527 066 164 ÷ 2 = 6 017 327 478 305 412 036 263 533 082 + 0;
  • 6 017 327 478 305 412 036 263 533 082 ÷ 2 = 3 008 663 739 152 706 018 131 766 541 + 0;
  • 3 008 663 739 152 706 018 131 766 541 ÷ 2 = 1 504 331 869 576 353 009 065 883 270 + 1;
  • 1 504 331 869 576 353 009 065 883 270 ÷ 2 = 752 165 934 788 176 504 532 941 635 + 0;
  • 752 165 934 788 176 504 532 941 635 ÷ 2 = 376 082 967 394 088 252 266 470 817 + 1;
  • 376 082 967 394 088 252 266 470 817 ÷ 2 = 188 041 483 697 044 126 133 235 408 + 1;
  • 188 041 483 697 044 126 133 235 408 ÷ 2 = 94 020 741 848 522 063 066 617 704 + 0;
  • 94 020 741 848 522 063 066 617 704 ÷ 2 = 47 010 370 924 261 031 533 308 852 + 0;
  • 47 010 370 924 261 031 533 308 852 ÷ 2 = 23 505 185 462 130 515 766 654 426 + 0;
  • 23 505 185 462 130 515 766 654 426 ÷ 2 = 11 752 592 731 065 257 883 327 213 + 0;
  • 11 752 592 731 065 257 883 327 213 ÷ 2 = 5 876 296 365 532 628 941 663 606 + 1;
  • 5 876 296 365 532 628 941 663 606 ÷ 2 = 2 938 148 182 766 314 470 831 803 + 0;
  • 2 938 148 182 766 314 470 831 803 ÷ 2 = 1 469 074 091 383 157 235 415 901 + 1;
  • 1 469 074 091 383 157 235 415 901 ÷ 2 = 734 537 045 691 578 617 707 950 + 1;
  • 734 537 045 691 578 617 707 950 ÷ 2 = 367 268 522 845 789 308 853 975 + 0;
  • 367 268 522 845 789 308 853 975 ÷ 2 = 183 634 261 422 894 654 426 987 + 1;
  • 183 634 261 422 894 654 426 987 ÷ 2 = 91 817 130 711 447 327 213 493 + 1;
  • 91 817 130 711 447 327 213 493 ÷ 2 = 45 908 565 355 723 663 606 746 + 1;
  • 45 908 565 355 723 663 606 746 ÷ 2 = 22 954 282 677 861 831 803 373 + 0;
  • 22 954 282 677 861 831 803 373 ÷ 2 = 11 477 141 338 930 915 901 686 + 1;
  • 11 477 141 338 930 915 901 686 ÷ 2 = 5 738 570 669 465 457 950 843 + 0;
  • 5 738 570 669 465 457 950 843 ÷ 2 = 2 869 285 334 732 728 975 421 + 1;
  • 2 869 285 334 732 728 975 421 ÷ 2 = 1 434 642 667 366 364 487 710 + 1;
  • 1 434 642 667 366 364 487 710 ÷ 2 = 717 321 333 683 182 243 855 + 0;
  • 717 321 333 683 182 243 855 ÷ 2 = 358 660 666 841 591 121 927 + 1;
  • 358 660 666 841 591 121 927 ÷ 2 = 179 330 333 420 795 560 963 + 1;
  • 179 330 333 420 795 560 963 ÷ 2 = 89 665 166 710 397 780 481 + 1;
  • 89 665 166 710 397 780 481 ÷ 2 = 44 832 583 355 198 890 240 + 1;
  • 44 832 583 355 198 890 240 ÷ 2 = 22 416 291 677 599 445 120 + 0;
  • 22 416 291 677 599 445 120 ÷ 2 = 11 208 145 838 799 722 560 + 0;
  • 11 208 145 838 799 722 560 ÷ 2 = 5 604 072 919 399 861 280 + 0;
  • 5 604 072 919 399 861 280 ÷ 2 = 2 802 036 459 699 930 640 + 0;
  • 2 802 036 459 699 930 640 ÷ 2 = 1 401 018 229 849 965 320 + 0;
  • 1 401 018 229 849 965 320 ÷ 2 = 700 509 114 924 982 660 + 0;
  • 700 509 114 924 982 660 ÷ 2 = 350 254 557 462 491 330 + 0;
  • 350 254 557 462 491 330 ÷ 2 = 175 127 278 731 245 665 + 0;
  • 175 127 278 731 245 665 ÷ 2 = 87 563 639 365 622 832 + 1;
  • 87 563 639 365 622 832 ÷ 2 = 43 781 819 682 811 416 + 0;
  • 43 781 819 682 811 416 ÷ 2 = 21 890 909 841 405 708 + 0;
  • 21 890 909 841 405 708 ÷ 2 = 10 945 454 920 702 854 + 0;
  • 10 945 454 920 702 854 ÷ 2 = 5 472 727 460 351 427 + 0;
  • 5 472 727 460 351 427 ÷ 2 = 2 736 363 730 175 713 + 1;
  • 2 736 363 730 175 713 ÷ 2 = 1 368 181 865 087 856 + 1;
  • 1 368 181 865 087 856 ÷ 2 = 684 090 932 543 928 + 0;
  • 684 090 932 543 928 ÷ 2 = 342 045 466 271 964 + 0;
  • 342 045 466 271 964 ÷ 2 = 171 022 733 135 982 + 0;
  • 171 022 733 135 982 ÷ 2 = 85 511 366 567 991 + 0;
  • 85 511 366 567 991 ÷ 2 = 42 755 683 283 995 + 1;
  • 42 755 683 283 995 ÷ 2 = 21 377 841 641 997 + 1;
  • 21 377 841 641 997 ÷ 2 = 10 688 920 820 998 + 1;
  • 10 688 920 820 998 ÷ 2 = 5 344 460 410 499 + 0;
  • 5 344 460 410 499 ÷ 2 = 2 672 230 205 249 + 1;
  • 2 672 230 205 249 ÷ 2 = 1 336 115 102 624 + 1;
  • 1 336 115 102 624 ÷ 2 = 668 057 551 312 + 0;
  • 668 057 551 312 ÷ 2 = 334 028 775 656 + 0;
  • 334 028 775 656 ÷ 2 = 167 014 387 828 + 0;
  • 167 014 387 828 ÷ 2 = 83 507 193 914 + 0;
  • 83 507 193 914 ÷ 2 = 41 753 596 957 + 0;
  • 41 753 596 957 ÷ 2 = 20 876 798 478 + 1;
  • 20 876 798 478 ÷ 2 = 10 438 399 239 + 0;
  • 10 438 399 239 ÷ 2 = 5 219 199 619 + 1;
  • 5 219 199 619 ÷ 2 = 2 609 599 809 + 1;
  • 2 609 599 809 ÷ 2 = 1 304 799 904 + 1;
  • 1 304 799 904 ÷ 2 = 652 399 952 + 0;
  • 652 399 952 ÷ 2 = 326 199 976 + 0;
  • 326 199 976 ÷ 2 = 163 099 988 + 0;
  • 163 099 988 ÷ 2 = 81 549 994 + 0;
  • 81 549 994 ÷ 2 = 40 774 997 + 0;
  • 40 774 997 ÷ 2 = 20 387 498 + 1;
  • 20 387 498 ÷ 2 = 10 193 749 + 0;
  • 10 193 749 ÷ 2 = 5 096 874 + 1;
  • 5 096 874 ÷ 2 = 2 548 437 + 0;
  • 2 548 437 ÷ 2 = 1 274 218 + 1;
  • 1 274 218 ÷ 2 = 637 109 + 0;
  • 637 109 ÷ 2 = 318 554 + 1;
  • 318 554 ÷ 2 = 159 277 + 0;
  • 159 277 ÷ 2 = 79 638 + 1;
  • 79 638 ÷ 2 = 39 819 + 0;
  • 39 819 ÷ 2 = 19 909 + 1;
  • 19 909 ÷ 2 = 9 954 + 1;
  • 9 954 ÷ 2 = 4 977 + 0;
  • 4 977 ÷ 2 = 2 488 + 1;
  • 2 488 ÷ 2 = 1 244 + 0;
  • 1 244 ÷ 2 = 622 + 0;
  • 622 ÷ 2 = 311 + 0;
  • 311 ÷ 2 = 155 + 1;
  • 155 ÷ 2 = 77 + 1;
  • 77 ÷ 2 = 38 + 1;
  • 38 ÷ 2 = 19 + 0;
  • 19 ÷ 2 = 9 + 1;
  • 9 ÷ 2 = 4 + 1;
  • 4 ÷ 2 = 2 + 0;
  • 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.

111 000 099 999 999 999 999 999 999 999 999 999 999 999 999 319(10) =


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


3. Normalize the binary representation of the number.

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


111 000 099 999 999 999 999 999 999 999 999 999 999 999 999 319(10) =


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


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


1.0011 0111 0001 0110 1010 1010 1000 0011 1010 0000 1101 1100 0011 0000 1000 0000 0111 1011 0101 1101 1010 0001 1010 0001 0111 1001 1001 0010 1001 1111 1111 1111 1111 1111 1111 1111 1101 0101 0111(2) × 2156


4. Up to this moment, there are the following elements that would feed into the 64 bit double precision IEEE 754 binary floating point representation:

Sign 0 (a positive number)


Exponent (unadjusted): 156


Mantissa (not normalized):
1.0011 0111 0001 0110 1010 1010 1000 0011 1010 0000 1101 1100 0011 0000 1000 0000 0111 1011 0101 1101 1010 0001 1010 0001 0111 1001 1001 0010 1001 1111 1111 1111 1111 1111 1111 1111 1101 0101 0111


5. Adjust the exponent.

Use the 11 bit excess/bias notation:


Exponent (adjusted) =


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


156 + 2(11-1) - 1 =


(156 + 1 023)(10) =


1 179(10)


6. Convert the adjusted exponent from the decimal (base 10) to 11 bit binary.

Use the same technique of repeatedly dividing by 2:


  • division = quotient + remainder;
  • 1 179 ÷ 2 = 589 + 1;
  • 589 ÷ 2 = 294 + 1;
  • 294 ÷ 2 = 147 + 0;
  • 147 ÷ 2 = 73 + 1;
  • 73 ÷ 2 = 36 + 1;
  • 36 ÷ 2 = 18 + 0;
  • 18 ÷ 2 = 9 + 0;
  • 9 ÷ 2 = 4 + 1;
  • 4 ÷ 2 = 2 + 0;
  • 2 ÷ 2 = 1 + 0;
  • 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) =


1179(10) =


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


0011 0111 0001 0110 1010 1010 1000 0011 1010 0000 1101 1100 0011


9. The three elements that make up the number's 64 bit double precision IEEE 754 binary floating point representation:

Sign (1 bit) =
0 (a positive number)


Exponent (11 bits) =
100 1001 1011


Mantissa (52 bits) =
0011 0111 0001 0110 1010 1010 1000 0011 1010 0000 1101 1100 0011


Decimal number 111 000 099 999 999 999 999 999 999 999 999 999 999 999 999 319 converted to 64 bit double precision IEEE 754 binary floating point representation:

0 - 100 1001 1011 - 0011 0111 0001 0110 1010 1010 1000 0011 1010 0000 1101 1100 0011


How to convert numbers from the decimal system (base ten) to 64 bit double precision IEEE 754 binary floating point standard

Follow the steps below to convert a base 10 decimal number to 64 bit double 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 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 from the previous 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 multiplying operations, starting from the top of the list constructed 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, shifting the decimal mark (the decimal point) "n" positions either to the left, or to the right, so that only one non zero digit remains to the left of the decimal mark.
  • 7. Adjust the exponent in 11 bit excess/bias notation and then convert it from decimal (base 10) to 11 bit binary, by using the same technique of repeatedly dividing by 2, as shown above:
    Exponent (adjusted) = Exponent (unadjusted) + 2(11-1) - 1
  • 8. Normalize mantissa, remove the leading (leftmost) bit, since it's allways '1' (and the decimal mark, if the case) and adjust its length to 52 bits, either by removing the excess bits from the right (losing precision...) or by adding extra bits set on '0' 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 -31.640 215 from the decimal system (base ten) to 64 bit double precision IEEE 754 binary floating point:

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

    |-31.640 215| = 31.640 215

  • 2. First convert the integer part, 31. Divide it repeatedly by 2, keeping track of each remainder, until we get a quotient that is equal to zero:
    • division = quotient + remainder;
    • 31 ÷ 2 = 15 + 1;
    • 15 ÷ 2 = 7 + 1;
    • 7 ÷ 2 = 3 + 1;
    • 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:

    31(10) = 1 1111(2)

  • 4. Then, convert the fractional part, 0.640 215. 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.640 215 × 2 = 1 + 0.280 43;
    • 2) 0.280 43 × 2 = 0 + 0.560 86;
    • 3) 0.560 86 × 2 = 1 + 0.121 72;
    • 4) 0.121 72 × 2 = 0 + 0.243 44;
    • 5) 0.243 44 × 2 = 0 + 0.486 88;
    • 6) 0.486 88 × 2 = 0 + 0.973 76;
    • 7) 0.973 76 × 2 = 1 + 0.947 52;
    • 8) 0.947 52 × 2 = 1 + 0.895 04;
    • 9) 0.895 04 × 2 = 1 + 0.790 08;
    • 10) 0.790 08 × 2 = 1 + 0.580 16;
    • 11) 0.580 16 × 2 = 1 + 0.160 32;
    • 12) 0.160 32 × 2 = 0 + 0.320 64;
    • 13) 0.320 64 × 2 = 0 + 0.641 28;
    • 14) 0.641 28 × 2 = 1 + 0.282 56;
    • 15) 0.282 56 × 2 = 0 + 0.565 12;
    • 16) 0.565 12 × 2 = 1 + 0.130 24;
    • 17) 0.130 24 × 2 = 0 + 0.260 48;
    • 18) 0.260 48 × 2 = 0 + 0.520 96;
    • 19) 0.520 96 × 2 = 1 + 0.041 92;
    • 20) 0.041 92 × 2 = 0 + 0.083 84;
    • 21) 0.083 84 × 2 = 0 + 0.167 68;
    • 22) 0.167 68 × 2 = 0 + 0.335 36;
    • 23) 0.335 36 × 2 = 0 + 0.670 72;
    • 24) 0.670 72 × 2 = 1 + 0.341 44;
    • 25) 0.341 44 × 2 = 0 + 0.682 88;
    • 26) 0.682 88 × 2 = 1 + 0.365 76;
    • 27) 0.365 76 × 2 = 0 + 0.731 52;
    • 28) 0.731 52 × 2 = 1 + 0.463 04;
    • 29) 0.463 04 × 2 = 0 + 0.926 08;
    • 30) 0.926 08 × 2 = 1 + 0.852 16;
    • 31) 0.852 16 × 2 = 1 + 0.704 32;
    • 32) 0.704 32 × 2 = 1 + 0.408 64;
    • 33) 0.408 64 × 2 = 0 + 0.817 28;
    • 34) 0.817 28 × 2 = 1 + 0.634 56;
    • 35) 0.634 56 × 2 = 1 + 0.269 12;
    • 36) 0.269 12 × 2 = 0 + 0.538 24;
    • 37) 0.538 24 × 2 = 1 + 0.076 48;
    • 38) 0.076 48 × 2 = 0 + 0.152 96;
    • 39) 0.152 96 × 2 = 0 + 0.305 92;
    • 40) 0.305 92 × 2 = 0 + 0.611 84;
    • 41) 0.611 84 × 2 = 1 + 0.223 68;
    • 42) 0.223 68 × 2 = 0 + 0.447 36;
    • 43) 0.447 36 × 2 = 0 + 0.894 72;
    • 44) 0.894 72 × 2 = 1 + 0.789 44;
    • 45) 0.789 44 × 2 = 1 + 0.578 88;
    • 46) 0.578 88 × 2 = 1 + 0.157 76;
    • 47) 0.157 76 × 2 = 0 + 0.315 52;
    • 48) 0.315 52 × 2 = 0 + 0.631 04;
    • 49) 0.631 04 × 2 = 1 + 0.262 08;
    • 50) 0.262 08 × 2 = 0 + 0.524 16;
    • 51) 0.524 16 × 2 = 1 + 0.048 32;
    • 52) 0.048 32 × 2 = 0 + 0.096 64;
    • 53) 0.096 64 × 2 = 0 + 0.193 28;
    • We didn't get any fractional part that was equal to zero. But we had enough iterations (over Mantissa limit = 52) 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.640 215(10) = 0.1010 0011 1110 0101 0010 0001 0101 0111 0110 1000 1001 1100 1010 0(2)

  • 6. Summarizing - the positive number before normalization:

    31.640 215(10) = 1 1111.1010 0011 1110 0101 0010 0001 0101 0111 0110 1000 1001 1100 1010 0(2)

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

    31.640 215(10) =
    1 1111.1010 0011 1110 0101 0010 0001 0101 0111 0110 1000 1001 1100 1010 0(2) =
    1 1111.1010 0011 1110 0101 0010 0001 0101 0111 0110 1000 1001 1100 1010 0(2) × 20 =
    1.1111 1010 0011 1110 0101 0010 0001 0101 0111 0110 1000 1001 1100 1010 0(2) × 24

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

    Sign: 1 (a negative number)

    Exponent (unadjusted): 4

    Mantissa (not-normalized): 1.1111 1010 0011 1110 0101 0010 0001 0101 0111 0110 1000 1001 1100 1010 0

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

    Exponent (adjusted) = Exponent (unadjusted) + 2(11-1) - 1 = (4 + 1023)(10) = 1027(10) =
    100 0000 0011(2)

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

    Mantissa (not-normalized): 1.1111 1010 0011 1110 0101 0010 0001 0101 0111 0110 1000 1001 1100 1010 0

    Mantissa (normalized): 1111 1010 0011 1110 0101 0010 0001 0101 0111 0110 1000 1001 1100

  • Conclusion:

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

    Exponent (8 bits) = 100 0000 0011

    Mantissa (52 bits) = 1111 1010 0011 1110 0101 0010 0001 0101 0111 0110 1000 1001 1100

  • Number -31.640 215, converted from decimal system (base 10) to 64 bit double precision IEEE 754 binary floating point =
    1 - 100 0000 0011 - 1111 1010 0011 1110 0101 0010 0001 0101 0111 0110 1000 1001 1100