Adders & Subtractors Virtual Lab
Full Adder, Half Adder, Full Subtractor & Half Subtractor – Theory
1. Introduction
Adders and subtractors are fundamental combinational circuits used in digital electronics to perform arithmetic operations. These circuits form the core of Arithmetic Logic Units (ALUs), which are critical in microprocessors and digital systems.
A half adder performs binary addition of two bits, while a full adder includes an additional carry input. Similarly, subtractors handle binary subtraction, with half subtractors dealing with two inputs and full subtractors considering a borrow input as well.
2. Full Adder
A full adder adds three binary inputs: A, B, and a carry input Cin. It produces a sum and a carry output.
Equations:
- Sum: S = A ⊕ B ⊕ Cin
- Carry: C = (A & B) | (B & Cin) | (A & Cin)
Full Adder Truth Table:
3. Half Adder
A half adder adds two single-bit binary numbers A and B. It has two outputs: the sum and the carry.
Equations:
- Sum: S = A ⊕ B
- Carry: C = A & B
4. Full Subtractor
A full subtractor performs the subtraction of three binary bits: A − B − Bin (borrow in). It outputs the difference and the borrow.
Equations:
- Difference: D = A ⊕ B ⊕ Bin
- Borrow: B = (~A & B) | (~A & Bin) | (B & Bin)
5. Half Subtractor
A half subtractor subtracts two single-bit numbers, A and B. It outputs a difference and a borrow.
Equations:
- Difference: D = A ⊕ B
- Borrow: B = ~A & B
6. Applications
- Used in digital calculators and processors to perform binary addition and subtraction.
- Core components of Arithmetic Logic Units (ALUs) in CPUs.
- Found in embedded systems for arithmetic computation.
- Utilized in digital signal processing and control systems.
No comments:
Post a Comment