Professional Documents
Culture Documents
SEQUENTIAL CIRCUIT
DESIGN
FALL, 2023
1
DIGITAL SYSTEMS AND BINARY NUMBERS
2
CONTENTS
3
DIGITAL SYSTEMS
• Digital Systems exist everywhere
• Communication, banks, hospitals, Internet etc.
4
ANALOG VS DIGITAL SYSTEMS
time
ANALOG VS DIGITAL SYSTEMS
11 12
9 10
7 8
5 6
3 4
1 2
Value
Jan Feb Mar Apr May Jun Jul Aug Sep Oct Nov Dec
6
ANALOG VS DIGITAL SYSTEMS
7
ANALOG VS DIGITAL SYSTEMS
Analog
Digital
8
DIGITIZATION
9
COMPUTERS
Computers are digital systems
1 1
10
BIT
binary digit 11
LOGIC GATES
12
AND GATE
1 output
2 inputs
3 inputs
4 inputs
Multiple inputs
13
AND GATE FUNCTION
Logical Multiplication function
Input Output
F A B
A B F F A B C .... N
0 0 0
0 1 0
1 0 0
1 1 1
14
AND GATE TIMING DIAGRAM
t0 t1 t2 t3 t4 t5 t6
15
OR GATE
1 output
2 inputs
3 inputs
4 inputs
Multiple inputs
16
OR GATE FUNCTION
Input Output
F A B
A B F
0 0 0 F A B C .. N
0 1 1
1 0 1
1 1 1
17
OR GATE TIMING DIAGRAM
A
t0 t1 t2 t3 t4 t5 t6
18
NOT GATE
1 input
1 output
19
NOT GATE FUNCTION
Invert function
Input Output
A F
FA
0 1
1 0
20
NOT GATE TIMING DIAGRAM
A
t0 t1 t2 t3 t4 t5 t6
21
OR GATE APPLICATIONS
Car door open alarm
22
NOT GATE APPLICATIONS
1’s Complement
1 1 0 0 1 0 1 0
0 0 1 1 0 1 0 1
23
NAND GATE
1 output
2 inputs
3 inputs
4 inputs
Multiple inputs
24
NAND GATE FUNCTION
Input Output
F A B
A B F
0 0 1 F A B C .... N
0 1 1
1 0 1
1 1 0
25
NAND GATE TIMING DIAGRAM
A
t0 t1 t2 t3 t4 t5 t6
26
NOR GATE
1 output
2 inputs
3 inputs
4 inputs
Multiple inputs
27
NOR GATE FUNCTION
Input Output
A B F F A B
0 0 1 F A B C .... N
0 1 0
1 0 0
1 1 0
28
NOR GATE TIMING DIAGRAM
t0 t1 t2 t3 t4 t5 t6
29
NAND GATE APPLICATIONS
ALARM
30
ALTERNATE LOGIC SYMBOLS
31
ALTERNATE LOGIC-GATE REPRESENTATION
32
XOR GATE
1 output
2 inputs
Multiple inputs
33
XOR GATE FUNCTION
Odd Function:
34
XOR GATE FUNCTION
Input Output
A B F
0 0 0 F A B
0 1 1
1 0 1
1 1 0
35
XOR GATE TIMING DIAGRAM
t0 t1 t2 t3 t4 t5 t6
36
XNOR GATE
1 output
2 inputs
Multiple inputs
37
XNOR GATE FUNCTION
Even Function:
38
XNOR GATE FUNCTION
Input Output
A B F
F A B
0 0 1
0 1 0
1 0 0
1 1 1
39
XNOR GATE TIMING DIAGRAM
t0 t1 t2 t3 t4 t5 t6
40
SUMMARY OF LOGIC GATES
41
SUMMARY OF LOGIC GATES
42
LOGIC GATE INTEGRATED
CIRCUITS
14 13 12 11 10 9 8
14 13 12 11 10 9 8
1 2 3 4 5 6 7
1 2 3 4 5 6 7
7408
7432
Four 2-Input AND Gate
Four 2-Input OR Gate
14 13 12 11 10 9 8
14 13 12 11 10 9 8
1 2 3 4 5 6 7
7404 1 2 3 4 5 6 7
Hex Inverters 7400
Four 2-Input NAND Gate 43
LOGIC GATE INTEGRATED
CIRCUITS
14 13 12 11 10 9 8 14 13 12 11 10 9 8
1 2 3 4 5 6 7
1 2 3 4 5 6 7 7402
7486 Four 2-Input NOR Gate
Four 2-Input XOR Gate
14 13 12 11 10 9 8
1 2 3 4 5 6 7
74266 44
Four 2-Input XNOR Gate
UNIVERSAL GATE – NAND
How a NAND gate can be used to replace an AND gate, an
OR gate, or an INVERTER gate.
How a logic circuit implemented with AND-OR-invert (AOI)
logic gates can be re-implemented using only NAND gates.
That using a single gate type, in this case NAND, will reduce
the number of integrated circuits (IC) required to implement a
logic circuit.
45
X Y Z
0 0 1
0 1 1
1 0 1
1 1 0
46
NAND GATE AS AN INVERTER GATE
XX X (Before Bubble)
X ZX
X Z
0 1
Equivalent to Inverter
1 0
47
NAND GATE AS AN AND GATE
XY
X
Z XYXY
Y
X Y Z
0 0 0
0 1 0
Equivalent to AND Gate
1 0 0
1 1 1
48
NAND GATE AS AN OR GATE
X
X Y
Z XY XY XY
Y
X Y Z
0 0 0
0 1 1
Equivalent to OR Gate
1 0 1
1 1 1
49
NAND GATE EQUIVALENT TO AOI GATES
AND OR INVERTER
50
PROCESS FOR NAND IMPLEMENTATION
1. If starting from a logic expression, implement the design
with AOI logic.
2. In the AOI implementation, identify and replace every
AND,OR, and INVERTER gate with its NAND
equivalent.
3. Redraw the circuit.
4. Identify and eliminate any double inversions (i.e., back-
to-back inverters).
5. Redraw the final circuit.
51
NAND IMPLEMENTATION
Example:
Design a NAND Logic Circuit that is equivalent to the AOI circuit
shown below.
BC A C
52
NAND IMPLEMENTATION
Identify and replace every AND,OR, and INVERTER gate with its NAND
equivalent.
53
NAND IMPLEMENTATION
Redraw the circuit.
54
NAND IMPLEMENTATION
Identify and eliminate any double inversions.
55
NAND IMPLEMENTATION
Redraw the circuit.
56
PROOF OF EQUIVALENCE
C BC
BCAC
Z BCAC
AC
Z BCA C
57
AOI VS. NAND
59
X Y Z
0 0 1
0 1 0
1 0 0
1 1 0
60
NOR GATE AS AN INVERTER GATE
X ZX
X Z
0 1
Equivalent to Inverter
1 0
61
NOR GATE AS AN OR GATE
XY
X
Z XY XY
Y
X Y Z
0 0 0
0 1 1
Equivalent to OR Gate
1 0 1
1 1 1 62
NOR GATE AS AN AND GATE
X
X Y
ZXYXYXY
Y
X Y Z
0 0 0
0 1 0
Equivalent to AND Gate
1 0 0
1 1 1 63
NOR GATE EQUIVALENT OF AOI GATES
AND OR INVERTER
64
PROCESS FOR NOR IMPLEMENTATION
1. If starting from a logic expression, implement the design
with AOI logic.
2. In the AOI implementation, identify and replace every
AND,OR, and INVERTER gate with its NOR equivalent.
3. Redraw the circuit.
4. Identify and eliminate any double inversions. (i.e. back-to-
back inverters)
5. Redraw the final circuit.
65
NOR IMPLEMENTATION
Example:
Design a NOR Logic Circuit that is equivalent to the AOI circuit
shown below.
BC A C
66
NOR IMPLEMENTATION
Identify and replace every AND,OR, and INVERTER gate with its NAND
equivalent.
67
NOR IMPLEMENTATION
Redraw Circuit.
68
NOR IMPLEMENTATION
Identify and eliminate any double inversions.
69
NOR IMPLEMENTATION
Redraw Circuit.
70
PROOF OF EQUIVALENCE
BCBCBC
C
B BCA C
C
Z BCA C
BCA C
A 71
ACACAC
AOI VS NOR
73
BASIC DEFINITION
Closure
A set S is closed w.r.t. a binary operator if, for every pair of elements of S, the binary
operator specifies a rule for obtaining a unique element of S.
Example
74
BASIC DEFINITIONS
Associative Law
A binary operator * on a set S is said to be associative whenever:
Commutative Law
A binary operator * on a set S is said to be commutative whenever:
75
BASIC DEFINITIONS
Identity Element
76
BASIC DEFINITIONS
QUESTION
With respect to operator +, what is the identity element for the set of natural numbers
NONE
With respect to operator +, what is the identity element for the set of whole numbers
ZERO
77
BASIC DEFINITIONS
Inverse
x * y = e for every x S
Example
For set of integers I and operator +, e=0
Inverse of a = -a
a+ (-a) = 0 = e 78
BASIC DEFINITIONS
Distributive Law
a * (b + c) = (a * b) + (a * c)
79
BOOLEAN ALGEBRA
Boolean
BooleanAlgebra
Algebra developed
developed
by
by George
George Boole
Boole (1815-
(1815-
1864)
1864)
80
POSTULATES & THEOREMS
Postulate (a fact)
A Abasic
basic assumption
assumption that that isis accepted
accepted without
without proof
proof
Accepted
Accepted asas true
true in
in order
order to to provide
provide aa basis
basis for
for
logical
logical reasoning
reasoning
Theorem
A Astatement
statement which
which can
can be
be proved
proved to
to be
be true
true using
using
logical
logical (deductive)
(deductive) reasoning
reasoning
A Aproposition
proposition deducible
deducible from
from basic
basic postulates
postulates
81
BOOLEAN ALGEBRA
82
POSTULATE 1
A1. Closure: For every a, b B
I. a + b is in B; Closure with respect to ‘+’
II. a · b is in B; Closure with respect to ‘.’
(1,0)
(1,0) (1,0)
(1,0)
(1,0) (1,0)
83
POSTULATE 2
A2. Existence of identity elements: The set B has two distinct identity
elements, denoted as 0 and 1, such that for every element a B
additive identity element
I. a+0=0+a=a
II. a·1=1·a= a
a a
a 1 a
0
OR operation AND operation 84
POSTULATE 3
A3. Commutative laws: For every a, b B
I. a+b=b+a
II. a·b=b·a
a
F=a+b a F = a.b
b b
b
F=b+a b F = b.a
a a
85
POSTULATE 4
A4. Distributive laws: For every a, b, c B
a · (b + c) = (a · b) + (a · c)
a·+(b . c) = (a·+ b) . (a + c)
86
POSTULATES 5 & 6
A5. Existence of a complement: For every element a B there exists an
element a’ such that
I. a + a’ = 1
II. a · a’ = 0
the complement of a
87
BOOLEAN ALGEBRA
Closure x + y is in B and x . y is in B
Obvious as result either 0 or 1
Commutative x + y = y + x and x . y = y . x
Can be checked from the Truth Table
Duals
Postulate
Expression 1 Expression 2
1 a, b, a + b ε B a, b, a · b ε B
2 a+0=a a·1=a
3 a+b=b+a a·b=b·a
4 a + (b + c) = (a + b) + c a · (b · c) = (a · b) · c
6 aa 1 aa 0
90
EXAMPLES OF DUALS
Expressions:A · B A+B
A B A B
Equations: duals
A + (BC) = (A+B)(A+C) ↔ A (B+C) = AB + AC
The postulates are basic axioms of the algebraic structure and need no proof.
The theorems must be proven from the postulates.
92
Identity
Identity a)a)xx++00==xx
b)b)xx.1.1==xx
Commutative
Commutative a)a)xx++yy==yy++xx
b)b)xx.y.y==y.x
y.x
THEOREM 1: Distributive
Distributive a)a)x.(y
x.(y++z)z)==(x(x.y)
.y)++(x.z)
(x.z)
b)b)xx++(y.z) = (x+y).(x+z)
(y.z) = (x+y).(x+z)
IDEMPOTENCY Complement
Complement a)a)xx++x’x’==11
b)b)x.x’
x.x’==00
Proof
a+a = (a + a).1
= (a + a).(a + ā)
= a + a.ā
= a+0
= a
93
Identity
Identity a)a)xx++00==xx
b)b)xx.1.1==xx
Commutative
Commutative a)a)xx++yy==yy++xx
b)b)xx.y.y==y.x
y.x
THEOREM 1: Distributive
Distributive a)a)x.(y
x.(y++z)z)==(x(x.y)
.y)++(x.z)
(x.z)
b)b)xx++(y.z) = (x+y).(x+z)
(y.z) = (x+y).(x+z)
IDEMPOTENCY Complement
Complement a)a)xx++x’x’==11
b)b)x.x’
x.x’==00
Proof
a.a = (a.a) + 0
= (a.a) + (a.ā)
= a.(a + ā)
= a .1
= a
94
Identity
Identity a)a)xx++00==xx
THEOREM 2 b)b)xx.1.1==xx
Commutative
Commutative a)a)xx++yy==yy++xx
a + 1 = 1, for + operator b)b)xx.y.y==y.x
y.x
Distributive
Distributive a)a)x.(y
x.(y + z)==(x(x.y)
+ z) .y)++(x.z)
(x.z)
a · 0 = 0, for · operator b)b)xx++(y.z) = (x+y).(x+z)
(y.z) = (x+y).(x+z)
Complement
Complement a)a)xx++x’x’==11
Proof: b)b)x.x’
x.x’==00
a+1 = (a + 1).1
= 1.(a + 1)
= (a + ā).(a + 1)
= a + ā.1
= a+ā
= 1
a · 0 = 0 (By Duality) 95
Identity
Identity a)a)xx++00==xx
b)b)xx.1.1==xx
Commutative
Commutative a)a)xx++yy==yy++xx
b)b)xx.y.y==y.x
y.x
Distributive
Distributive a)a)x.(y
x.(y++z)z)==(x(x.y)
.y)++(x.z)
(x.z)
b)b)xx++(y.z) = (x+y).(x+z)
THEOREM 2 Complement
Complement
(y.z) = (x+y).(x+z)
a)a)xx++x’x’==11
b)b)x.x’
x.x’==00
a + 1 = 1, for + operator
a · 0 = 0, for · operator
Proof:
a.0 = (a.0) + 0
= 0 + (a.0)
= (a.ā) + (a.0)
= a.(ā + 0)
= a.ā
= 0
96
THEOREM 3 - INVOLUTION
a=a
=
Proof:
a + ā = 1 and a ā = 0, (complements)
or ā + a = 1 and ā a = 0, (commutativity)
i.e., a is complement of ā
Therefore, a = a
97
THEOREM 4 - ABSORPTION
Identity
Identity a)a)xx++00==xx
b)b)xx.1.1==xx
Commutative
Commutative a)a)xx++yy==yy++xx
b)b)xx.y.y==y.x
y.x
Distributive
Distributive a)a)x.(y
x.(y++z)z)==(x(x.y)
.y)++(x.z)
(x.z)
b)b)xx++(y.z) = (x+y).(x+z)
(y.z) = (x+y).(x+z)
a+ab=a Complement a)a)xx++x’x’==11
Complement
a (a + b) = a b)b)x.x’
x.x’==00
Proof:
a + a.b = a.1 + a b
= a.(1 + b)
= a .1
= a
98
THEOREM 5 – DEMORGAN
(a+b)’ = a’.b’
(a.b)’ = a’+ b’
a b a+b (a+b)’ a’ b’ a’b’
0 0 0 1 1 1 1
0 1 1 0 1 0 0
1 0 1 0 0 1 0
1 1 1 0 0 0 0
99
THEOREM 6 - ASSOCIATIVITY
a + (b + c) = (a + b) + c
a.(b.c) = (a.b).c
100
BOOLEAN FUNCTIONS
each other
Designers try to reduce complexity and number of gates to reduce circuit
cost
Two different boolean functions may represent the same logic and truth
table
A single variable in a boolean function is called literal
Group of literals which forming an input to a gate are together called a term
101
IMPLEMENTATION OF BOOLEAN FUNCTIONS
a
b
F
102
IMPLEMENTATION OF BOOLEAN FUNCTIONS
FF11 xx yy''zz
Boolean Function expresses logical relationship between
binary variables
x
F1
y
z 103
IMPLEMENTATION OF BOOLEAN FUNCTIONS
F2
z
104
IMPLEMENTATION OF BOOLEAN FUNCTIONS
Try another implementation using a simplified F2:
x' z xy '
x
y
F2
z
105
This implementation has fewer gates and fewer inputs to the gates (or wires) than the previous one .
SIMPLIFYING BOOLEAN FUNCTIONS
F3 xy x' z yz
xy x' z yz ( x x' ) Identity .1 is same & Complement Pos (x.x’)=1
106
z
COMPLEMENT OF A FUNCTION
DeMorgan’s Theorem
(x+y)’ = x.’y’
(x.y)’=x’+y’
(A+B+C+D+…+F)’= A’B’C’D’…. F’
(ABCD…F)’ = A’+B’+C’+D’+… + F’
The complement of a function can be obtained by interchanging AND and OR operators and
complementing each literal
107
COMPLEMENT OF A FUNCTION
F = x’yz’+x’y’z
F’ = (x’yz’+x’y’z)’
= (x’yz’)’.(x’y’z)’
=(x+y’+z).(x+y+z’)
108
COMPLEMENT OF A FUNCTION
Example: Find the complement of F by taking its dual and complementing each
literal
F = x’yz’+x’y’z
Dual of F
= (x’+y+z’).(x’+y’+z)
Complement each literal
=(x+y’+z).(x+y+z’) = F’
109
COMPLEMENT OF A FUNCTION
Example: Find the Complement of
F ( AB 'C ) D ' E
F ' [( AB 'C ) D ' E ]'
[( AB 'C ) D ' ]' E '
[( AB 'C )' D ' ' ]E '
[( AB ' )' C ' D ]E '
( A' B )C ' E ' DE '
110
DEFINITIONS
111