Professional Documents
Culture Documents
AND OR NOT
0·0=0 0+0=0 0=1
0·1=0 0+1=1 1=0
1·0=0 1+0=1
1·1=1 1+1=1
AND OR NOT
X Y Z = X·Y X Y Z = X+Y X Z=X
0 0 0 0 0 0 0 1
0 1 0 0 1 1 1 0
1 0 0 1 0 1
1 1 1 1 1 1
Boolean Algebra and Logic Gates 6
Truth Tables – Cont’d
Used to evaluate any logic function
Consider F(X, Y, Z) = X Y + Y Z
X Y Z XY Y YZ F=XY+YZ
0 0 0 0 1 0 0
0 0 1 0 1 1 1
0 1 0 0 0 0 0
0 1 1 0 0 0 0
1 0 0 0 1 0 0
1 0 1 0 1 1 1
1 1 0 1 0 0 1
1 1 1 1 0 0 1
Boolean Algebra and Logic Gates 7
Logic Function Implementation
Using Switches Switches in parallel => OR
• Inputs:
logic 1 is switch closed
logic 0 is switch open
• Outputs: Switches in series => AND
logic 1 is light on
logic 0 is light off.
• NOT input: Normally-closed switch => NOT
logic 1 is switch open C
logic 0 is switch closed
Light is on (L = 1) for
L(A, B, C, D) = A (B C + D) = A B C + A D
and off (L = 0), otherwise.
Useful model for relay and CMOS gate circuits,
the foundation of current digital logic circuits
Y 0 1 0 1
(AND) X ·Y 0 0 0 1
(OR) X+ Y 0 1 1 1
(NOT) X 1 1 0 0
Boolean Algebra and Logic Gates 11
Logic Diagrams and Expressions
Truth Table Logic Equation
XYZ F = X + Y Z
000 0 F = X +Y Z
001 1
010 0 Logic Diagram
011 0 X
100 1
Y F
101 1
110 1 Z
111 1
Boolean equations, truth tables and logic diagrams describe the
same function!
Truth tables are unique, but expressions and logic diagrams are
not. This gives flexibility in implementing functions.
Boolean Algebra and Logic Gates 12
Gate Delay
In actual physical gates, if an input changes, it causes
the output to change; the output change does not
occur instantaneously.
The delay between an input change and the output
change is the gate delay denoted by tG:
1
Input
0
tG tG tG = 0.3 ns
1
Output
0
0 0.5 1 1.5 Time (ns)
Boolean Algebra and Logic Gates 13
Boolean Algebra
Invented by George Boole in 1854
An algebraic structure defined by a set B = {0, 1}, together with two
binary operators (+ and ·) and a unary operator ( )
X+Y=X·Y X·Y=X+Y
X Y X·Y X+Y X Y X+Y X · Y X·Y X+Y
0 0 0 0 1 1 1 1 1 1
0 1 0 1 1 0 0 0 1 1
1 0 0 1 0 1 0 0 1 1
1 1 1 1 0 0 0 0 0 0
Generalized DeMorgan’s Theorem:
X1 + X2 + … + Xn = X1 · X2 · … · Xn
X1 · X2 · … · Xn = X1 + X2 + … + Xn
Boolean Algebra and Logic Gates 21
Complementing Functions
Use DeMorgan's Theorem:
1. Interchange AND and OR operators
2. Complement each constant and literal
Example: Complement F = xy z + x y z
F = (x + y + z)(x + y + z)
Example: Complement G = (a + bc)d + e
G = (a (b + c) + d) e
Boolean Algebra and Logic Gates 22
Expression Simplification
An application of Boolean algebra
Simplify to contain the smallest number of
literals (variables that may or may not be
complemented)
A B + ACD + A BD + AC D + A BCD
= AB + ABCD + A C D + A C D + A B D
= AB + AB(CD) + A C (D + D) + A B D
= AB + A C + A B D = B(A + AD) +AC
= B (A + D) + A C (has only 5 literals)
Boolean Algebra and Logic Gates 23
Canonical Forms
Minterms and Maxterms
F = m1 + m6 + m7 = ∑ (1, 6, 7) = x y z + x y z + x y z
Boolean Algebra and Logic Gates 31
Sum-Of-Minterm Examples
F(a, b, c, d) = ∑(2, 3, 6, 10, 11)
F(a, b, c, d) = m2 + m3 + m6 + m10 + m11
abcd+abcd+abcd+abcd+abcd
G(a, b, c, d) = ∑(0, 1, 12, 15)
G(a, b, c, d) = m0 + m1 + m12 + m15
abcd+abcd+abcd+abcd
F = m1+m2+m3+m5+m7 = ∑(1, 2, 3, 5, 7) =
xyz+xyz+xyz+xyz+xyz
F = M0 · M4 · M6 = ∏(0, 4, 6) =(x+y+z)(x+y+z)(x+y+z)
Boolean Algebra and Logic Gates 38
Algebraic Conversion to Sum-of-Minterms