7 Computer Arithmetic

Computer Architecture · Unit 7 · 6 hrs

Computer Arithmetic

Exam-focused notes for Computer Arithmetic (Computer Architecture, CSC213): what the TU syllabus asks and how it has actually been tested, with 10 solved past questions from this unit.

What this unit covers

  • Addition and Subtraction with Signed Magnitude Data
  • Addition and Subtraction with Signed 2's Complement Data
  • Multiplication of Signed Magnitude Data
  • Booth Multiplication
  • Division of Signed magnitude Data
  • Divide Overflow

Addition and Subtraction with Signed 2's Complement Data

208110 marks

Draw flowchart for addition and subtraction of signed 2's complement numbers and perform the operation (90-43).[10]

- Operation to perform: $90 - 43$ - Numbers are represented in signed 2's complement form. - Using 8-bit representation (sufficient since $90 < 128$). --- Rules: - For addition, add the two numbers directly including the sign bits. - For subtraction, take t...

Full solved answer →

Booth Multiplication

208010 marks

Explain the working of Booth's multiplication algorithm and perform multiplication of 50 and (-13) using the same algorithm.[10]

- Multiplicand: $M = 50$ - Multiplier: $Q = -13$ - Operation: signed binary multiplication using Booth's algorithm - Bit width: not specified. Since $50$ needs 6 magnitude bits, we must use at least 7 bits for signed representation. I will use 8-bit two's c...

Full solved answer →
20785 marks

Explain the Booth Multiplication algorithm with example. [5]

Booth's algorithm gives a procedure for multiplying binary integers in signed 2's complement representation. It handles both positive and negative numbers efficiently by replacing a sequence of additions with shifts, reducing the number of arithmetic operat...

Full solved answer →
207710 marks

Explain Booth multiplication algorithm with hardware implementation diagram. Multiply (-4) x (-3) using Booth multiplication algorithm.[10]

Booth's algorithm is a technique for multiplying two signed binary numbers represented in 2's complement form. It treats both positive and negative multipliers uniformly and reduces the number of arithmetic operations by examining pairs of adjacent bits, ta...

Full solved answer →
2075.16 marks

Describe the steps of multiplication process using Booth algorithm with example. [6]

Booth's algorithm gives a procedure for multiplying binary integers in signed 2's complement representation. It handles both positive and negative numbers efficiently by reducing the number of arithmetic operations. --- The algorithm uses the following regi...

Full solved answer →

Division of Signed magnitude Data

207910 marks

Differentiate between floating point representation and fixed point representation. Divide 23 by 9 using restoring division algorithm.[10]

- Dividend = 23 - Divisor = 9 - Method: Restoring division algorithm --- Feature Fixed Point Representation Floating Point Representation --------- Definition Number represented with a fixed number of digits before and after the (binary) point Number repres...

Full solved answer →
207810 marks

Explain the non-restoring division algorithm with flow chart, and hardware implementation diagram. Divide 10/3 using restoring division.[10]

--- In restoring division, after subtracting the divisor, if the partial remainder becomes negative, the divisor is added back (restored). This wastes an operation. In non-restoring division, we do NOT restore. Instead, we keep the negative remainder and ad...

Full solved answer →
20775 marks

Differentiate between restoring division and non-restoring division. [5]

Both are hardware algorithms used to divide unsigned integers using shift and subtract operations, but they differ in how they handle the case when the partial remainder becomes negative. --- Feature Restoring Division Non-Restoring Division --------- Basic...

Full solved answer →
20755 marks

Divide 10/4 using non-restoring division. [5]

- Dividend = 10 - Divisor = 4 - Operation: Non-restoring division Bit width: dividend needs 4 bits, so let n = 4. - Q (dividend) = 10 = $1010$ (4 bits) - M (divisor) = 4 = $00100$ (5 bits, using n+1 = 5 for sign) - 2's complement of M (i.e. $-M$) = $11100$ ...

Full solved answer →
2075.110 marks

Write down the non-restoring division flowchart algorithm and divide 5/3 using non-restoring division.[10]

- Dividend = 5 - Divisor = 3 - Operation: 5 / 3 using non-restoring division Non-restoring division avoids the extra restore step of restoring division. It uses the sign of the partial remainder A to decide whether to add or subtract the divisor in the next...

Full solved answer →