Documenti di Didattica
Documenti di Professioni
Documenti di Cultura
Logic Circuits
Chapter Objectives
Binary Switch
x =0
x =1
(a) Two states of a switch
S
x
(b) Symbol for a switch
Light
Light
x1
x2
Light
Light
x2
(b) The logical OR function (parallel connection)
Series-Parallel Connection
Power
supply
X1
X3
X2
Light
Inverting Circuit
R
Power
supply
Light
x1 x2
(a) AND gate
x1
x2
x1 +x2
(b) OR gate
x
(c) NOT gate
Changes one logic level (HIGH / LOW) to the opposite logic level
INPUT
OUTPUT
OUTPUT
A.B
The OR Gate
OUTPUT
A + B
X = AB + A
INPUT
OUTPUT
X = AB + A
x
1
x
2
x
3
f = x + x x
1
2
3
0 0 1 1
1 1 0 0
0 0 0 1
0 1 0 1
0
1
0
1
1
1
0
1
1 1 0 1
f = x1 + x1 x2
A
Time
(c) Timing diagram
Boolean Algebra
x+y=y+x
xy = yx
x + (y + z) = (x + y) + z
x(yz) = (xy)z
x (y+z) = xy + xz
Boolean Expression
x*0=0
x+1=1
x * 1= x
x+0=x
x*x=x
x+x=x
x * x =0
x + x =1
(x) = x
Duality
Boolean Expression
10 a. Commutative
x * y = y *x
10 b. Commutative
x+y=y+x
11 a. Associative
x * (y * z) = (x * y) * z
11 b. Associative
x + (y + z) = (x + y) + z
12 a. Distributive
x * (y + z) = x * y + x * z
12 b. Distributive
x + (y * z) = (x + y) * (x + z)
13 a. Absorption
x+x*y=x
13 b. Absorption
x * ( x + y) = x
Boolean Expression
14 a. Combining
x * y + x * y= x
14 b. Combining
(x + y ) * ( x + y) = x
15 a. DeMorgans Theorem
(x * y)= (x+ y)
15 b. DeMorgans Theorem
(x + y)= x * y
16 a.
x + x * y = x + y
16 b.
x * (x + y) = x * y
17 a. Consensus
17 b. Consensus
x * y + x * z + y * z = x * y + x * z
(x + y ) * (x + z) * (y + z )
= (x + y) * (x+ z)
Boolean Simplification
Example 1:
F = AB + CD + AB + CD
= AB + CD (by identity 5)
Example 2:
F = ABC + ABC + AC
= AB(C + C) + AC (by identity 13)
= AB(1) + AC (by identity 7)
= AB +AC (by identity 4)
Logic Circuit
Implementation
DeMorgans Theorem
(A B) = A + B
(A + B) = A B
(1)
(2)
Proof of DeMorgans
Theorem
Methods to Complement a
Function
Change F to F, and F to F
Change OR to AND
Change AND to OR
Complement each individual variable
Example 1:
F = AB+ CD + BD
Applying DeMorgans theorem,
F = (A + B)(C + D)(B + D)
Methods to Complement a
Function
Example 2:
Example 3:
Practice Problems
Find the complement: (xyz)
Expand: x + yz
Simplify:
xy +xy + xy
xy + xz + xy + yz
wy + wyz + wxy + wxy
Venn Diagram
Representation
(a) Constant 1
x
(c) Variable
(b) Constant 0
x
x
(d)
Venn Diagram
Representation
x
(e)
x
(f)
x y
x+y
x
x
y
z
(g)
x y
(h)
x y + z
z
(a)
z
(d)
z
(b)
z
(e)
y +z
x y + z
x z
z
(c)
x y
y
z
(f)
x y + x z
Verify xy + xz + yz = xy +
xz
x
x y
x y
x z
y z
x z
y
z
x y + x z + y z
y
z
x y + x z
Boolean Functions
Example 1:
Prove: (A + B) (A + B) = AB + AB
LHS
= AA + AB + BA + BB (by distributive
property)
= O + AB + BA + O = AB + AB = RHS
Example 2:
Prove: AC + B C + AC + BC = AB + AB + AB
LHS
Precedence of Operations
NOT, AND, and then OR
Example: A*B + A*B
1. Complements
2. AND operations
3. OR operation
f=m
* 1 + m1 * 1 + m2 * 0 + m3 *1
Two Implementations
x1
x2
x2
(b) Minimal-cost realization
Synthesis
Analysis
Sum-of-Products (SOP)
Product-of-Sums (POS)
Canonical SOP
Canonical POS
Minterm
Maxterm
A Three-Variable Function
A Three-Variable Function
Canonical Sum-of-Products
Canonical Product-of-Sums
Practice Problems
Minimal Realizations
x2
f
x3
x1
(a) A minimal sum-of-products realization
1
x3
f
x2
NAND
NOR
Exclusive OR (XOR)
Exclusive NOR (XNOR)
OUTPUT
X = (AB)
INPUT
XOR
XNOR
OUTPUT OUTPUT
AB
(AB)
x2
x1 x2 xn
x1 x2
xn
(a) NAND gates
x1
x1
x2
x2
x1 + x2
x1 + x2 + + xn
xn
x1
x1
x2
x2
(a)
x1
x2
x1x2 = x1 +x2
x1
x1
x2
x2
(b)
x1 +x2 = x1x2
x1
x2
x3
x4
x5
x3
x4
x5
x1
x2
x3
x4
x5
x1
x2
x2
x3
x3
x4
x4
x5
x5
x1
x2
x3
x4
x5
x3
(a) POS implementation
x1
x2
x3
(b) NOR implementation
x2
x3
(a) SOP implementation
x1
f
x2
x3
(b) NAND implementation
x1
x2
x3
(a) Sum-of-products realization
x3
x2
x1
f
Implementation of a
Multiplexer
x1
s x1 x2
000
001
010
011
100
101
s
x2
(b) Circuit
s
110
x1
111
x2
(a)Truth table
0
1
s
f
x1
x2
x1
x2
f
x3
VHDL
Entity Declaration
Describes Ports
Input
Output
Architecture Declaration
Describes Functions
: IN BIT ;
: OUT BIT ) ;
Example 2.10
f(x1, x2, x3 ) = AB + AC + BC
Example 2.11
x2
x1
x3
x3
(a) Function A
x2
x1
x2
x3
(c) Function C
(b) Function B
x1
x2
x3
(d) Function f