Full Adder with Carry
Full adder circuit using half adders and OR gate. Learn carry input handling and full arithmetic operations.
배울 내용
- Add three bits and produce a sum + carry-out.
- Read the full-adder truth table — 8 rows.
- Recognise sum as parity (XOR of all three) and carry-out as majority.
- See the full-adder's role as the building block of all wider adders.
- Apply for ripple-carry chains, counters, multipliers, and FP mantissa add.
작동 원리
This circuit shows a single full-adder cell with all three inputs (A, B, Cin) wired to switches and both outputs (Sum, Cout) wired to lights. It's the elementary building block of all multi-bit integer arithmetic.
The sum bit is the parity of the three inputs (XOR-XOR-XOR): high if an odd number of inputs are 1. The carry-out is the majority function: high if at least 2 of the 3 inputs are 1.
Teaching the full-adder in isolation lets you focus on its 8-row truth table and verify the parity/majority pattern without distraction from carry chains. Once you grasp this single cell, multi-bit adders are just N copies wired in a chain — every bit position is identical.
Full-adders are also used as cells in carry-save adder arrays (multipliers), where their parity-and-majority properties combine partial-product columns efficiently before a final ripple stage.
진리표
Three inputs, two outputs. Sum is parity; Cout is majority of the three inputs.
| 입력 | 출력 | ||||
|---|---|---|---|---|---|
| A | B | Cin | Sum | Cout | |
| 0 | 0 | 0 | 0 | 0 | 0 + 0 + 0 = 0 |
| 0 | 0 | 1 | 1 | 0 | 0 + 0 + 1 = 1 |
| 0 | 1 | 0 | 1 | 0 | 0 + 1 + 0 = 1 |
| 0 | 1 | 1 | 0 | 1 | 0 + 1 + 1 = 2 (binary 10) |
| 1 | 0 | 0 | 1 | 0 | 1 + 0 + 0 = 1 |
| 1 | 0 | 1 | 0 | 1 | 1 + 0 + 1 = 2 |
| 1 | 1 | 0 | 0 | 1 | 1 + 1 + 0 = 2 |
| 1 | 1 | 1 | 1 | 1 | 1 + 1 + 1 = 3 (binary 11) |
불 대수식
Parity — high iff an odd number of inputs are 1.
3-input majority — high iff at least 2 of the 3 inputs are 1.
단계별로 시도해 보세요
위 임베드에서 입력을 설정한 후, 예상 결과를 읽고 직접 확인하세요.
- 1A = 1 B = 0 Cin = 0예상:
S=1, Cout=0관찰 포인트: Single bit set — sum is 1. - 2A = 1 B = 1 Cin = 0예상:
S=0, Cout=1관찰 포인트: Two bits set — sum is 2 (binary 10), so S=0 and Cout=1. - 3A = 0 B = 1 Cin = 1예상:
S=0, Cout=1관찰 포인트: Different two bits set — same result. Order of which two bits doesn't matter. - 4A = 1 B = 1 Cin = 1예상:
S=1, Cout=1관찰 포인트: All three bits set — sum is 3 (binary 11), so both outputs are 1.
사용된 구성 요소
실제 응용 사례
Every multi-bit adder in every CPU. A 64-bit adder is 64 full-adders chained — this exact cell, replicated.
Hardware multipliers. Wallace-tree and Dadda-tree multipliers use 2D arrays of full-adders to compress N×N partial products into a single sum.
Counters. Incrementing a counter by 1 is a full-adder chain with B = 0...01.
Floating-point mantissa add/subtract. After exponent alignment, the mantissa addition uses chained full-adders.
Multi-precision libraries. Software big-integer libraries chain hardware adds via the carry-out flag — full-adder semantics implemented at the ISA level.