4b Digital System - Logic Gates & Boolean Expression
4b Digital System - Logic Gates & Boolean Expression
4b Digital System - Logic Gates & Boolean Expression
Summary
Exercise
Given the Boolean function
F = xy’z + x’y’z + w’xy + wx’y + wxy
(a) Obtain the truth table of the function.
(b) Draw the logic diagram using the original Boolean
expression.
(c) Simplify the function to a minimum number of literals
using Boolean algebra.
(d) Obtain the truth table of the function from the
simplified expression and show that it is the same as
the one in part (a)
(e) Draw the logic diagram from the simplified expression
and compare the total number of gates with the
diagram of part (b).
Boolean Function
Boolean Expression x y z F
Example: F = x + y’ z 0 0 0 0
Truth Table 0 0 1 1
All possible combinations 0 1 0 0
of input variables
0 1 1 0
Logic Circuit
1 0 0 1
x F 1 0 1 1
y
z 1 1 0 1
1 1 1 1
Begin
LOGIC GATES AND BOOLEAN
ALGEBRA
Digital circuits
hardware components that manipulate binary information
implemented using transistors and interconnections in IC
each basic circuit is called logic gate
performs a specific logical operation
A logic gate is an elementary building block of a digital circuit
Most logic gates have two inputs and one output
At any given moment, every terminal is in one of the two binary
conditions low (0) or high (1) represented by different voltage
levels
In most logic gates, the low state is approximately zero volts
(0V)
The high state is approximately five volts positive (+5 V).
Boolean Algebra
Boolean algebra is a mathematical system for the
manipulation of variables that can have one of two
values.
In formal logic, these values are “true” and “false.”
In digital systems, these values are “on” and “off,” 1 and
0, or “high” and “low.”
Boolean expressions are created by performing
operations on Boolean variables.
Common Boolean operators include AND, OR, and
NOT.
A Boolean operator can be completely described
using a truth table.
TRUTH TABLE
A truth table shows how a logic circuit's output responds to
various combinations of the inputs
Using logic 1 for true and logic 0 for false.
All permutations of the inputs are listed on the left
Output of the circuit is listed on the right
The desired output can be achieved by a combination of logic
gates
A truth table for two inputs is shown, but it can be extended to
any number of inputs.
The input columns are usually constructed in the order of
binary counting with a number of bits equal to the number of
inputs.
TYPES OF GATE
Logic Gates
Gates can have multiple inputs and more than one
output.
A second output can be provided for the complement
of the operation.
Example
Answer
Boolean Function Simplification
Commutative Law
x•y=y•x x+y=y+x
Identity Element
x•1=x x+0=x
Complement
x • x’ = 0 x + x’ = 1
Boolean Algebra Theorems
Duality
The dual of a Boolean algebraic expression is obtained
by interchanging the AND and the OR operators and
replacing the 1’s by 0’s and the 0’s by 1’s.
x•(y+z)=(x•y)+(x•z)
x+(y•z)=(x+y)•(x+z)
Theorem 1
x•x=x x+x=x
Theorem 2
x•0=0 x+1=1
Theorem 3: Involution
(x)=x
Theorem 5: DeMorgan
Theorem 6: Absorption
x•(x+y)=x x+(x•y)=x
DeMorgan’s Theorem on Gates
AND Gate
F = x • y F = (x • y) F=x+y
OR Gate
F = x + y F = (x + y) F=x•y
Example
2
1
3
Answer
1 2
3
Example
Use Boolean Algebra to simplify Boolean functions to
produce simpler circuits
F BC AB AC
Product of Sums (POS)
AB (C C )
BC ( A A)
AC ( B B )
F AC ( B B ) AB(C C ) BC ( A A)
F AC AB BC
F ( A C )( A B )( B C )
Sum of Products (SOP) B’
C
A
F BC A B AC B’ F
A
C
F m1 m4 m5 m7 1 0 0 1 1 0
2 0 1 0 0 1
F (1,4,5,7)
3 0 1 1 0 1
Product of Maxterms 4 1 0 0 1 0
F A BC ABC ABC ABC 5 1 0 1 1 0
F ABC ABC ABC ABC 6 1 1 0 0 1
7 1 1 1 1 0
F A BC ABC ABC ABC
F ( A B C )( A B C )( A B C )( A B C )
F M0 M2 M3 M6
F (0,2,3,6)
Exercise
Exercise
Given the Boolean function
F = xy’z + x’y’z + w’xy + wx’y + wxy
(a) Obtain the truth table of the function.
(b) Draw the logic diagram using the original Boolean
expression.
(c) Simplify the function to a minimum number of literals
using Boolean algebra.
(d) Obtain the truth table of the function from the
simplified expression and show that it is the same as
the one in part (a)
(e) Draw the logic diagram from the simplified expression
and compare the total number of gates with the
diagram of part (b).
Boolean Function
Boolean Expression x y z F
Example: F = x + y’ z 0 0 0 0
Truth Table 0 0 1 1
All possible combinations 0 1 0 0
of input variables
0 1 1 0
Logic Circuit
1 0 0 1
x F 1 0 1 1
y
z 1 1 0 1
1 1 1 1