Download as pdf or txt
Download as pdf or txt
You are on page 1of 5

29-08-2021

Addition and Subtraction

Addition and Subtraction with Sign –


Magnitude Data
 A, B represents Magnitudes of two numbers
 As, Bs represents Sign of two numbers

1
29-08-2021

Hardware Implementation
 Two registers A, B – to hold magnitudes of two numbers
 Two flipflops As, Bs– to hold corresponding signs
 Reuse of register and flopflop to hold result of the operation
 A Parallel adder to perform the microoperation A+B.
 A comparator circuit to establish A>B, A<B, or A=B.
 Two Parallel Subtractor circuits to perform the
microoperations A-B and B-A
 One X-OR gate to find the sign relation ships with As, Bs as
inputs

Hardware Implementation

2
29-08-2021

Flowchart for Add operation

Flowchart for Subtract operation

3
29-08-2021

Flowchart for Add and Subtract


operation

Addition and Subtraction with 2’s


Complement Data
 Hardware

4
29-08-2021

Flowchart

You might also like