Assignment 3
Assignment 3
Theory:
Half Adder:A half adder is a simple combinational circuit that adds two single-bit
binary numbers and provides two outputs: Sum and Carry.
● Inputs:
○ A (first binary digit)
○ B (second binary digit)
● Outputs:
○ Sum (S): The sum of A and B, without considering any carry from a
previous addition.
○ Carry (C): A carry-out bit, which is generated if the sum of A and B
exceeds 1.
Truth Table:
Full Adder:
A full adder is a more complex combinational circuit that adds three binary digits: two
input bits (A and B) and a carry-in (C_in) from a previous addition. The full adder
produces two outputs: the Sum and the Carry-out (C_out).
● Inputs:
○ A (first binary digit)
○ B (second binary digit)
○ Carry-in (C_in) from a previous stage
● Outputs:
○ Sum (S): The sum of the input bits and the carry-in.
○ Carry-out (C_out): The carry resulting from the addition, which can be
passed to the next stage of addition.
Truth Table:
Half Subtractor:
A half subtractor is a digital circuit that performs subtraction of two single-bit binary
numbers. It has two inputs, the minuend (A) and the subtrahend (B), and two outputs:
Difference (D) and Borrow (B).
Full Subtractor:
A full subtractor is a more advanced version of the half subtractor. It can handle three
inputs: two binary numbers (minuend A and subtrahend B), and a borrow-in (Bin) from
the previous stage. It produces two outputs: Difference (D) and Borrow-out (Bout).
Conclusion: Half adder and full adder are used for binary addition, with the full adder
handling carry-in from previous stages. Half subtractor and full subtractor perform binary
subtraction, with the full subtractor accounting for borrow-in. The half adder has two
inputs and outputs (Sum, Carry), while the full adder adds three inputs (A, B, Cin).
Similarly, the half subtractor has two inputs (A, B) and outputs (Difference, Borrow),
while the full subtractor works with three inputs (A, B, Bin). These circuits are essential
building blocks for performing arithmetic operations in digital systems.