- Asked 3/22
- 2080 Bhadra · 2+3 marks
- 2080 Baisakh · 5+3 marks
- 2078 Bhadra · 2+4 marks
Prove De Morgan's theorems; XOR using NAND
Short answer
De Morgan's theorems: (A+B)' = A'·B' and (A·B)' = A'+B'. An XOR gate can be built with 4 NAND gates: Y = (A·(AB)')' · (B·(AB)')' = A⊕B.
State and prove De-Morgan's theorems with necessary diagrams. Construct XOR gate using minimum number of NAND gates.
De Morgan's theorems
De Morgan's theorems tell how to complement a sum or a product of variables.
Theorem 1: The complement of a sum equals the product of the complements.
So a NOR gate equals a bubbled AND gate (AND with inverted inputs).
Theorem 2: The complement of a product equals the sum of the complements.
So a NAND gate equals a bubbled OR gate (OR with inverted inputs).
Proof by truth table
| A | B | ||||||
|---|---|---|---|---|---|---|---|
| 0 | 0 | 0 | 1 | 1 | 0 | 1 | 1 |
| 0 | 1 | 1 | 0 | 0 | 0 | 1 | 1 |
| 1 | 0 | 1 | 0 | 0 | 0 | 1 | 1 |
| 1 | 1 | 1 | 0 | 0 | 1 | 0 | 0 |
Column 4 = column 5 and column 7 = column 8 for every input, so both theorems are proved.
Algebraic proof of Theorem 1: if and , then and . Since and , Y is the complement of X. Theorem 2 follows by duality.
Diagrams
Theorem 1: NOR = bubbled AND
A --|‾‾‾\ A --o|‾‾‾\
| OR )o-- Y = | AND )-- Y
B --|___/ B --o|___/
Theorem 2: NAND = bubbled OR
A --|‾‾‾\ A --o|‾‾‾\
| AND )o-- Y = | OR )-- Y
B --|___/ B --o|___/
(o = inversion bubble)
XOR using minimum NAND gates
. It can be built with 4 two-input NAND gates:
A --+-------------[NAND G2]--+
| | |
+--[NAND G1]---+ +--[NAND G4]-- Y
| | |
B --+-------------[NAND G3]--+
G1 output feeds one input of both G2 and G3; A goes to G2, B goes to G3; G2 and G3 feed G4.
| A | B | G1 | G2 | G3 | Y |
|---|---|---|---|---|---|
| 0 | 0 | 1 | 1 | 1 | 0 |
| 0 | 1 | 1 | 1 | 0 | 1 |
| 1 | 0 | 1 | 0 | 1 | 1 |
| 1 | 1 | 0 | 1 | 1 | 0 |
✓ Answer checked by Claude Opus 5.5 (high effort)
Related questions
- XOR gate using minimum NAND gates · Digital Logic, chapter 2 · asked 2×
- De Morgan's laws; XOR from NAND gates · Digital Logic, chapter 2
- De Morgan's laws; XOR using 3-input NAND · Digital Logic, chapter 2
- De Morgan; NOR gate from NAND gates · Digital Logic, chapter 2
- De Morgan; positive NAND equals negative NOR · Digital Logic, chapter 2
- De Morgan's laws; XNOR using NOR gates · Digital Logic, chapter 2
- State and prove De Morgan's theorems · Basic Electronics Engineering, chapter 6 · asked 4×
- X-OR gate using NAND gates only · Basic Electronics Engineering, chapter 6
- Encoder; NAND and XOR truth tables · Basic Electronics Engineering, chapter 6
- De Morgan's theorem and duality theorem · Basic Electronics Engineering, chapter 6