Full adder
A full adder adds three bits: A, B and a carry in (Cin) from the column before. It gives a Sum bit and a carry out (Cout). It's built from two half adders and an OR gate, and a row of full adders is how a computer adds whole numbers.
How it works
- 01
The first half adder adds A and B.
- 02
The second adds Cin to that sum. Its Sum is the full adder's Sum.
- 03
Either half adder can make a carry, but never both at once, so an OR joins them into Cout.
- 04
1 + 1 + 1 = 11 in binary: Sum and Cout are both on.
Truth table
- Sum = A ⊕ B ⊕ Cin
- Cout = A·B + Cin·(A ⊕ B)
| A | B | Cin | Sum | Cout |
|---|---|---|---|---|
| 0 | 0 | 0 | 0 | 0 |
| 0 | 0 | 1 | 1 | 0 |
| 0 | 1 | 0 | 1 | 0 |
| 0 | 1 | 1 | 0 | 1 |
| 1 | 0 | 0 | 1 | 0 |
| 1 | 0 | 1 | 0 | 1 |
| 1 | 1 | 0 | 0 | 1 |
| 1 | 1 | 1 | 1 | 1 |