Section 7.5 shows how to implement the traditional long division that is done by hand. A different

Question:

Section 7.5 shows how to implement the traditional long division that is done by “hand.” A different approach for implementing integer division is to perform repeated subtraction as indicated in the pseudo-code in Figure P7.1.
(a) Give an ASM chart that represents the pseudo-code in Figure P7.1.
(b) Show the data path circuit corresponding to part (a).
(c) Give the ASM chart for the control circuit corresponding to part (b).
(d) Give Verilog code that represents the divider circuit.
(e) Discuss the relative merits and drawbacks of your circuit in comparison with the circuit designed in Section 7.5.


Data From Section 7.5

Divider

The preceding example implements the traditional method of performing multiplication by hand. In this example we will design a circuit that implements the traditional long-hand  division. Figure 7.28a gives an example of long-hand division. The first step is to try to divide the divisor 9 into the first digit of the dividend 1, which does not work. Next, we try to divide 9 into 14, and determine that 1 is the first digit in the quotient. We perform the subtraction 14 − 9 = 5, bring down the last digit from the dividend to form 50, and then determine that the next digit in the quotient is 5. The remainder is 50 − 45 = 5, and the quotient is 15. Using binary numbers, as illustrated in Figure 7.28b, involves the same process, with the simplification that each digit of the quotient can be only 0 or 1. 

Given two unsigned n-bit numbers A and B, we wish to design a circuit that produces two n-bit outputs Q and R, where Q is the quotient A/B and R is the remainder. The procedure illustrated in Figure 7.28b can be implemented by shifting the digits in A to the left, one digit at a time, into a shift register R. After each shift operation, we compare R with B. If R ≥ B, a 1 is placed in the appropriate bit position in the quotient and B is subtracted from R. Otherwise, a 0 bit is placed in the quotient. This algorithm is described using

Fantastic news! We've Found the answer you've been seeking!

Step by Step Answer:

Related Book For  book-img-for-question
Question Posted: