1 / 9

Assignment 7 Zhiyong Yang CS 10051 Instructor: Dean Zeller

Assignment 7 Zhiyong Yang CS 10051 Instructor: Dean Zeller. Q.1 00011001 = 25 11111101 = 253 11010101 = 213 00111010 = 58 001010011000 = 664 111011101110 = 3822. Diagram: 2048 1024 512 256 128 64 32 16 8 4 2 1 1 1 0 1 1 1 0 1 1 1 0

Download Presentation

Assignment 7 Zhiyong Yang CS 10051 Instructor: Dean Zeller

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Assignment 7 Zhiyong Yang CS 10051 Instructor: Dean Zeller Q.1 00011001 = 25 11111101 = 253 11010101 = 213 00111010 = 58 001010011000 = 664 111011101110 = 3822 • Diagram: • 2048 1024 512 256 128 64 32 16 8 4 2 1 • 1 1 0 1 1 1 0 1 1 1 0 • = 1x2048 + 1x1024 + 1x512 + • 1x128 + 1x64 + 1x32 + • 1x8 + 1x4 + 1x2 • = 3822

  2. Q.2 29 = 00011101 78 = 01001110 250 = 11111010 315 = 000100111011 1000 = 001111101000 2049 = 100000000001 Diagram: 2049/2 = 1024 R = 1 1024/2 = 512 R = 0 512/2 = 256 R = 0 256/2 = 128 R = 0 128/2 = 64 R = 0 64/2 = 32 R = 0 32/2 = 16 R = 0 16/2 = 8 R = 0 8/2 = 4 R = 0 4/2 = 2 R = 0 2/2 = 1 R = 0 1/2 = 0 R = 1 Thus 2049 = 1000000000001

  3. Q.3 10101100 + 1001010 11110010 10111011 + 1110010 100101101 10101000 + 1010111 11111111 11000000 + 1111111 100111111 100010001010 + 1111011100 110001100110 100111001000 + 101101000101 1010100001101 Q.4 10101000 - 1011111 01001001 10111011 - 1001001 01110010 10110110 - 1011001 01011101 111111001000 - 101111000101 010000000011 11101011 - 11011110 00001101 101110101010 - 1111011100 11111001110

  4. Q.5 00001101 x 111 01011011 00011010 x 1101 101010010 Example: 00011010 x 1101 11010 00000 11010 +11010 101010010 00100010 x 10010 1001100100 00101011 x 11101 10011011111 00101001 x 10101 1101011101 10100011 x 11111 1001110111101

  5. Assignment 8 Zhiyong Yang CS 10051 Instructor: Dean Zeller 001001 110)110110 R = 0 001101100 100)110110000 R = 0 Q.1 000110100 1000)110110000 R = 0 00100001 101) 10101001 R = 100 011011000 10)110110000 10 10 10 11 10 10 10 0 R = 0 00010110 111)10011011 R = 1 000011011 10000)110110000 R = 0 00010101 1010)11010110 R = 100

  6. Q.2 ½ ¼ 1/8 1/16 1/32 1/64 1/128 1/256 . 0 1 0 1 0 1 0 1 = ¼ + 1/16 + 1/64 + 1/256 = 0.33203125 0.01101000 = 0.40625 0.00000001 = 0.00390625 0.10000100 = 0.515625 0.10101010 = 0.6640625 0.11111111 = 0.99609375 0.10000100 = 0.515625 0.00000011 = 0.01171875 0.01010100 = 0.328125

  7. Q.3 0.00390625 x 2 = 0.00781250 R = 0 0.00781250 x 2 = 0.01562500 R = 0 0.01562500 x 2 = 0.03125000 R = 0 0.03125000 x 2 = 0.06250000 R = 0 0.06250000 x 2 = 0.12500000 R = 0 0.12500000 x 2 = 0.25000000 R = 0 0.25000000 x 2 = 0.50000000 R = 0 0.50000000 x 2 = 1.00000000 R = 1 0.00000000 x 2 = 0 R = 0 Thus 0.00390625 = 0.00000001 1/5 = 0.0011 1/7 = 0.001 1/10 = 0.00011 1/20 = 0.000011 3/8 = 0.011 1/14 = 0.0001 4/11 = 0.0101110100 3/16 = 0.0011 3/32 = 0.00001 3/64 = 0.000001 5/16 = 0.0101 61/64 = 0.111101 0.2 = 0.0011 0.3 = 0.01001 0.7125 = 0.10110110 0.796875 = 0.110011 0.00390625 = 0.00000001

  8. Q.4 0.0525 = 0.000011010111000010100011 0.995 x 2 = 1.990 R = 1 0.990 x 2 = 1.980 R = 1 0.980 x 2 = 1.960 R = 1 0.960 x 2 = 1.920 R = 1 0.920 x 2 = 1.840 R = 1 0.840 x 2 = 1.680 R = 1 0.680 x 2 = 1.360 R = 1 0.360 x 2 = 0.720 R = 0 0.720 x 2 = 1.440 R = 1 0.440 x 2 = 0.880 R = 0 0.880 x 2 = 1.760 R = 1 0.760 x 2 = 1.520 R = 1 0.520 x 2 = 1.040 R = 1 0.040 x 2 = 0.080 R = 0 0.080 x 2 = 0.160 R = 0 0.160 x 2 = 0.320 R = 0 0.320 x 2 = 0.640 R = 0 0.640 x 2 = 1.280 R = 1 0.280 x 2 = 0.560 R = 0 0.560 x 2 = 1.120 R = 1 0.120 x 2 = 0.240 R = 0 0.240 x 2 = 0.480 R = 0 0.480 x 2 = 0.960 R = 0 0.960 0.995 = 0.11111110101110000101000

  9. Q.5 ~ 0.53 = 0.10000111 0.42 = 0.01101011 0.10 = 0.00011001 0.75 = 0.11000000 0.73 = 0.10111010 0.25 = 0.10000000 0.99 = 0.11111101 0.01 = 0.00000010 0.51 = 0.10000001 0.24 = 0.00111101 Example: 0.53 x 2 = 1.06 R = 1 0.06 x 2 = 0.12 R = 0 0.12 x 2 = 0.24 R = 0 0.24 x 2 = 0.48 R = 0 0.48 x 2 = 0.96 R = 0 0.96 x 2 = 1.92 R = 1 0.92 x 2 = 1.84 R = 1 0.84 x 2 = 1.68 R = 1 ~ ~ ~ ~ ~ ~ ~

More Related