CprE 305 Homework #5

Reading Assignment: Chapter 4. Read lightly on floating point.

P1. (15 points) Using Booth's algorithm as shown in Figure 4.34, multiply two four bits operands 1000 by 1000. Show the results in a table. Explain the result.

Does Booth's algorithm fail in this case? If you think so, is there a simple fix? (Hint: assume the ALU has an overflow detection unit, and recall the properties of Booth's encoding discussed in the class.)

P2. (15 points) Problem 4.40, 4.41.

P3. (20 points) Problem 4.46, 4.48.

P4. (10 points) Problem 4.49.

P5. (10 points) Problem 4.51.

P6. (20 points) Problem 4.54.

P7. (10 points) Represent the following numbers using floating point representation as per the IEEE 754 standard.

  1. 0.1
  2. 10.5
  3. -2/3
  4. a negative infinity
  5. 0.1 x 10 -135