Download - Lesson 4.2 Universal Gates - Anula Vidyalaya
ISHANI NARAHENPITA © 2020 ANULA VIDYALAYA 1
Universal Gates
A universal logic gate is a logic gate that can be used to construct all other logic gates. The NAND gate and NOR
gates can be considered as universal logic gates.
The advantage of universal gates: NAND and NOR gates are economical and easier to fabricate and are the basic
gates used in all IC digital logic families.
NAND Gate
1. How to implement NOT gate using NAND gates?
Simplification of the output of above NAND gate produces A’ at the end.
(A.A)’
A’ + A’
A’
2. How to implement AND gate using NAND gates?
Simplification of the output of above NAND gate produces A.B at the end.
((A.B). (A.B))
(A.B) + (A.B)
(A.B) + (A.B)
A.B
Lesson 4 - Uses logic gates to design basic digital circuits and devices
Lesson 4.2 – Universal Gates
Advanced Level Information & Communication Technology
Ishani Narahenpita (B.Sc. Sp. (Hon) IT, M.Sc. (IT)
ISHANI NARAHENPITA © 2020 ANULA VIDYALAYA 2
3. How to implement OR gate using NAND gates?
Simplification of the output of above NAND gate produces A+B at the end.
NOR Gate
1. How to implement NOT gate using NOR gates?
Simplification of the output of above NOR gate produces A’ at the end.
(A+A)’
A’.A’
A’
2. How to implement OR gate using NOR gates?
Simplification of the output of above NOR gate produces A+B at the end.
((A.A). (B.B))
(A.A) + (B.B)
(A.A) + (B.B)
A + B
((A+B) + (A+B))
(A+B). (A+B)
(A+B). (A+B)
A+B
(A.A)’
(B.B)’
((A.A). (B.B))
ISHANI NARAHENPITA © 2020 ANULA VIDYALAYA 3
3. How to implement AND gate using NOR gates?
Simplification of the output of above NOR gate produces AB at the end.
Represent following Boolean expression using NAND gates
bc + bd
((A+A)+(B+B))
(A+A).(B+B)
(A+A).(B+B)
A.B
𝑏𝑐
𝑏𝑐
𝑏𝑑
𝑏𝑐
𝑏𝑑
𝑏𝑐
𝑏𝑑
𝑏𝑐. 𝑏𝑑
𝑏𝑑
𝑏𝑐. 𝑏𝑑 𝑏𝑐. 𝑏𝑑
𝑏𝑐+𝑏𝑑 De Morgan’s law
𝑏𝑐 + 𝑏𝑑 Double Complement law
Example 1
𝑏𝑐 𝑏𝑐 𝑏𝑐
𝑏𝑐. 𝑏𝑑
AND
AND
OR
EXTRA GATES
ISHANI NARAHENPITA © 2020 ANULA VIDYALAYA 4
METHOD TWO
bc + bd
Step 1- Convert bc + bd to NAND only Boolean expression. For this put two over bars on whole Boolean expression
𝑏𝑐 + 𝑏𝑑
Step 2- Apply De Morgan’s law as below
𝑏𝑐. 𝑏𝑑
Step -Draw the circuit
Represent following Boolean expression using NOR gates
bc + bd
Seven NOR gates are required for above implementation. When trying to implement product terms as it is from NOR gates,
it require more gates. So it is possible to convert bc+bd to a NOR only sum term. For this you can apply De morgan’s law
on bc+bd.
Represent following Boolean expression using NOR gates
bc + bd
Step 1- Apply distributive law → b(c+d)
Convert b(c+d) to NOR only Boolean expression. For this put two over bars on whole Boolean expression
𝑏(𝑐 + 𝑑)
𝑐
𝑏
𝑑
𝑏𝑐
𝑏𝑑
𝑏𝑐 + 𝑏𝑑 𝑏𝑐 + 𝑏𝑑
Example 2
𝑏𝑐
𝑏𝑑
𝑏𝑐. 𝑏𝑑
𝑏𝑐. 𝑏𝑑
𝑏𝑐+𝑏𝑑 De Morgan’s law
𝑏𝑐 + 𝑏𝑑 Double Complement law
AND
AND
OR
ISHANI NARAHENPITA © 2020 ANULA VIDYALAYA 5
Step 2- Apply De Morgan’s law as below
𝑏 + 𝑐 + 𝑑
Step -Draw the circuit
Represent following Boolean expression using NAND gates
𝑏𝑐 + 𝑏𝑑
bc bc
bc
d
bd bd
bd
𝑏𝑐. 𝑏𝑑
Example 3
𝑏
𝑐 + 𝑑
𝑏 + 𝑐 + 𝑑
AND
NOT
AND
OR
bc bc
bc
d
bd bd
bd
EXTRA GATES
EXTRA GATES
ISHANI NARAHENPITA © 2020 ANULA VIDYALAYA 6
METHOD 2
𝑏𝑐 + 𝑏𝑑
Step 1- Convert bc + bd to NAND only Boolean expression. For this put two over bars on whole Boolean expression
𝑏𝑐 + 𝑏𝑑
Step 2- Apply De Morgan’s law as below
𝑏𝑐. 𝑏𝑑
Step -Draw the circuit
𝑏𝑐. 𝑏𝑑
𝑏𝑐+𝑏𝑑 De Morgan’s law
𝑏𝑐 + 𝑏𝑑 Double Complement law
𝑑
𝑏𝑐
𝑏𝑑
𝑏𝑐. 𝑏𝑑
𝑑
𝑏𝑐
𝑏𝑑
𝑏𝑐. 𝑏𝑑
𝑏𝑐. 𝑏𝑑
𝑏𝑐+𝑏𝑑 De Morgan’s law
𝑏𝑐 + 𝑏𝑑 Double Complement law
ISHANI NARAHENPITA © 2020 ANULA VIDYALAYA 7
Represent following Boolean expression using NOR gates
𝑏𝑐 + 𝑏𝑑
Six NOR gates are required for above implementation. When trying to implement product terms as it is from NOR gates, it
require more gates. So it is possible to convert bc+bd to a NOR only sum term. For this you can apply De morgan’s law on
bc+bd as below
Represent following Boolean expression using NOR gates → 𝑏𝑐 + 𝑏𝑑
Step 1- Apply distributive law → b(c+𝑑)
Convert b(c+𝑑)to NOR only Boolean expression. For this put two over bars on whole Boolean expression
𝑏(𝑐 + 𝑑)
Step 2- Apply De Morgan’s law as below
𝑏 + 𝑐 + 𝑑
Step -Draw the circuit
𝑐
𝑏
𝑑
𝑐
𝑑
𝑏𝑐
𝑏𝑑 + 𝑏𝑐
𝑏𝑑
𝑏
𝑏𝑑
𝑏𝑐 𝑏𝑑 + 𝑏𝑐 𝑏𝑑 + 𝑏𝑐
𝑏𝑑 + 𝑏𝑐
Example 4
AND
NOT
AND
OR
EXTRA GATES
𝑑
𝑏
𝑐 + 𝑑
𝑏 + 𝑐 + 𝑑
ISHANI NARAHENPITA © 2020 ANULA VIDYALAYA 8
Represent following Boolean expression using NAND gates
b (c + d)
Five NAND gates are required for above implementation. When trying to implement SUM terms as it is from NAND gates,
it require more gates. So it is possible to convert b(c+d) to a NAND only PRODUCT terms. For this you can apply De
morgan’s law on b(c+d) as below
Represent following Boolean expression using NAND gates
b (c + d)
Step 1- Apply distributive law → bc + b𝑑
Step 1- Convert bc + bd to NAND only Boolean expression. For this put two over bars on whole Boolean expression
𝑏𝑐 + 𝑏𝑑
Step 2- Apply De Morgan’s law as below
𝑏𝑐. 𝑏𝑑
Step -Draw the circuit
𝑐
𝑑
𝑐. 𝑑
(𝑐. 𝑑)𝑏
𝑏
𝑑 (𝑐. 𝑑)𝑏
(𝑐. 𝑑)𝑏
(𝑐 + 𝑑) . 𝑏 De Morgan’s law
(𝒄 + 𝒅) . 𝒃 Double Complement law
Example 5
OR
AND
(𝑐. 𝑑)𝑏
(𝑐 + 𝑑) . 𝑏 De Morgan’s law
(𝒄 + 𝒅) . 𝒃 Double Complement law
𝑑
𝑏𝑐
𝑏𝑑
𝑏𝑐. 𝑏𝑑
𝑏𝑐. 𝑏𝑑
𝑏𝑐+𝑏𝑑 De Morgan’s law
𝑏𝑐 + 𝑏𝑑 Double Complement law
ISHANI NARAHENPITA © 2020 ANULA VIDYALAYA 9
Represent following Boolean expression using NOR gates
b (c + d)
METHOD 2
Represent following Boolean expression using NOR gates
b (c + d)
Step 1- Apply distributive law → b(c+𝑑)
Convert b(c+𝑑)to NOR only Boolean expression. For this put two over bars on whole Boolean expression
𝑏(𝑐 + 𝑑)
Step 2- Apply De Morgan’s law as below
𝑏 + 𝑐 + 𝑑
Step -Draw the circuit
𝑐 + 𝑑 + 𝑏
(𝑐 + 𝑑) . 𝑏 De Morgan’s law
(𝒄 + 𝒅) . 𝒃 Double Complement law
Example 6
𝑐 + 𝑑 + 𝑏
(𝑐 + 𝑑) . 𝑏 De Morgan’s law
(𝒄 + 𝒅) . 𝒃 Double Complement law
𝑐 + 𝑑 𝑐 + 𝑑
𝑐 + 𝑑
𝑏
OR
AND
EXTRA GATES
ISHANI NARAHENPITA © 2020 ANULA VIDYALAYA 10
A⊕B = 𝐴. 𝐵 + 𝐴. 𝐵
Option 1
Option 2
𝐴
𝐵
𝐴. 𝐵
𝐴. 𝐵
(𝐴. 𝐵)(𝐴. 𝐵)
(𝐴. 𝐵) (𝐴. 𝐵)= 𝐴. 𝐵 + 𝐴. 𝐵
(𝐴. 𝐵) + (𝐴. 𝐵) De Morgan’s law
𝐴. 𝐵 + 𝐴. 𝐵 Double Complement law
∴ 𝐴. 𝐵 + 𝐴. 𝐵 = A⊕B
𝐴. 𝐵
𝐴(𝐴. 𝐵)
𝐵(𝐴. 𝐵)
𝐴(𝐴. 𝐵). 𝐴(𝐴. 𝐵)
𝐴(𝐴. 𝐵). 𝐴(𝐴. 𝐵) = 𝐴. 𝐵 + 𝐴. 𝐵
𝐴(𝐴. 𝐵) + 𝐵(𝐴. 𝐵) De Morgan’s law
𝐴(𝐴. 𝐵) + 𝐵(𝐴. 𝐵) Double Complement law
𝐴(𝐴 + 𝐵) + 𝐵(𝐴 + 𝐵) De Morgan’s law
𝐴𝐴 + 𝐴𝐵 + 𝐵𝐴 + B𝐵 Distributive law
𝐴𝐵 + 𝐵𝐴 Inverse Law
∴ 𝐴. 𝐵 + 𝐴. 𝐵 = A⊕B
How to represent XOR gate using NAND gates and NOR gates?
XOR gate using NAND gates
ISHANI NARAHENPITA © 2020 ANULA VIDYALAYA 11
Option 1
Option 2
𝐴
𝐵
𝐴 + 𝐵
𝐴 + 𝐵
𝐴 + 𝐵 + 𝐴 + 𝐵
𝐴 + 𝐵 + 𝐴 + 𝐵 = 𝐴. 𝐵 + 𝐴. 𝐵
(𝐴 + 𝐵)(𝐴 + 𝐵) De Morgan’s law
(𝐴 + 𝐵)(𝐴 + 𝐵) Double Complement law
𝐴𝐴 + 𝐵𝐵 + 𝐵𝐴 + 𝐴𝐵 Distributive Law
𝐵𝐴 + 𝐴𝐵 Inverse Law
∴ 𝐴. 𝐵 + 𝐴. 𝐵 = A⊕B
𝐴 + 𝐵
𝐴 + 𝐴 + 𝐵
𝐵 + 𝐴 + 𝐵
𝐴 + 𝐴 + 𝐵 + 𝐵 + 𝐴 + 𝐵
(𝐴 + 𝐴 + 𝐵 + 𝐵 + 𝐴 + 𝐵)
(𝐴 + 𝐴 + 𝐵 + 𝐵 + 𝐴 + 𝐵)= 𝐴. 𝐵 + 𝐴. 𝐵
((𝐴. (𝐴 + 𝐵) + 𝐵. (𝐴 + 𝐵)) De Morgan’s law
(𝐴(𝐴 + 𝐵) + 𝐵(𝐴 + 𝐵)) Double Complement law
𝐴𝐴 + 𝐴𝐵 + 𝐵𝐴 + 𝐵𝐵 Distributive Law
𝐴𝐵 + 𝐵𝐴 Inverse Law
∴ 𝐴. 𝐵 + 𝐴. 𝐵 = A⊕B
XOR gate using NOR gates
ISHANI NARAHENPITA © 2020 ANULA VIDYALAYA 12
A ⊕ B = A. 𝐵 + 𝐴. 𝐵
Option 1
Option 2
𝐴
𝐴. 𝐵
𝐵
𝐴. 𝐵
(𝐴. 𝐵) (𝐴. 𝐵)
(𝐴. 𝐵) (𝐴. 𝐵)= A. 𝐵 + 𝐴. 𝐵
(𝐴. 𝐵) + (𝐴. 𝐵) De Morgan’s law
𝐴. 𝐵 + 𝐴. 𝐵 Double Complement law
∴ 𝐴. 𝐵 + 𝐴. 𝐵 = A ⊕ B
𝐴. 𝐵
𝐴(𝐴. 𝐵)
𝐵(𝐴. 𝐵)
𝐴(𝐴. 𝐵). 𝐵(𝐴. 𝐵)
𝐴(𝐴. 𝐵). 𝐵(𝐴. 𝐵)
𝐴(𝐴. 𝐵). 𝐵(𝐴. 𝐵)= A. 𝐵 + 𝐴. 𝐵
𝐴 + (𝐴. 𝐵) . 𝐵 + (𝐴. 𝐵) De Morgan’s law
(𝐴 + 𝐴. 𝐵) ( 𝐵 + 𝐴. 𝐵) Double Complement law
𝐴. 𝐵 + 𝐴. 𝐴. 𝐵+ 𝐴. 𝐵. 𝐵 + 𝐴. 𝐵. 𝐴. 𝐵 Distributive law
𝐴. 𝐵 +0.B+ 0.B + 𝐴. 𝐵. 𝐴. 𝐵 Inverse law
𝐴. 𝐵 +0+ 0 + 𝐴. 𝐵. 𝐴. 𝐵 Identity law
𝐴. 𝐵 + 𝐴. 𝐴. 𝐵. 𝐵 Associative law
𝐴. 𝐵 + 𝐴. 𝐵 Idempotent law
∴ 𝐴. 𝐵 + 𝐴. 𝐵 = A ⊕ B
How to represent XNOR gate using NAND gates and NOR gates?
XNOR gate using NAND gates
ISHANI NARAHENPITA © 2020 ANULA VIDYALAYA 13
Option 1
Option 2
𝐴 + 𝐵
𝐴 + 𝐴 + 𝐵
𝐵 + 𝐴 + 𝐵
𝐴 + 𝐴 + 𝐵 + 𝐵 + 𝐴 + 𝐵
𝐴 + 𝐴 + 𝐵 + 𝐵 + 𝐴 + 𝐵
(𝐴 + 𝐴 + 𝐵). (𝐵 + 𝐴 + 𝐵) De Morgan’s law
(𝐴 + 𝐴 + 𝐵). (𝐵 + 𝐴 + 𝐵) Double Complement law
(𝐴 + 𝐴. 𝐵)( 𝐵 + 𝐴. 𝐵) De Morgan’s law
(𝐴 + 𝐵) (𝐵 + 𝐴) Redundancy Law
𝐴𝐵 + 𝐵. 𝐴 + 𝐵. 𝐵 + 𝐴𝐴 Distributive law
𝐴𝐵 + 𝐵. 𝐴 Inverse Law
∴ 𝐴𝐵 + 𝐵. 𝐴= A ⊕ B
𝐴
𝐵
𝐴 + 𝐵
𝐵 + 𝐴
𝐴 + 𝐵 + 𝐵 + 𝐴
𝐴 + 𝐵 + 𝐵 + 𝐴
(𝐴 + 𝐵). (𝐵 + 𝐴) De Morgan’s law
(𝐴 + 𝐵). (𝐵 + 𝐴) Double Complement law
𝐴𝐴 + 𝐴. 𝐵 + 𝐵𝐵 + 𝐵𝐴 Distributive law
𝐴. 𝐵 + 𝐵𝐴 Inverse Law
∴ 𝐴𝐵 + 𝐴. 𝐵= A ⊕ B
XNOR gate using NOR gates