Professional Documents
Culture Documents
DLD Chapter 4
DLD Chapter 4
Chapter IV
Boolean Algebra and Logic Simplification
Addis Ababa Science and Technology University
College of Engineering
Lecturer: Biruk T.
Notes:
SOP and POS expression cannot have more than
one variable combined in a term with an inversion bar
There’s no parentheses in the expression
Digital Logic Design 17
The Sum-of-Products (SOP) Form
• A product term was defined as a term consisting of the product
of literals.
• When two or more product terms are summed by Boolean addition;
• The resulting expression is a sum-of-products (SOP).
• Some examples are;
The Standard SOP Form
• A SOP expressions in which some of the product terms do not contain
all of the variables in the domain of the expression are not standard.
• Example
• The above expression have a domain made up of the variables A, B, C and D.
• From first term D or and from second term C or are missing.
• A standard SOP expression is one in which all the variables in
the domain appear in each product term in the expression.
• Example :
• Is a standard SOP expression.
Exampl
e
Exampl
e
The Product-of-Sums (POS) Form
• A sum term is defined as a term consisting of the sum
(Boolean addition) of literals (variables or their complements).
• When two or more sum terms are multiplied, the resulting expression
is a product-of-sums (POS).
• Some examples are;
The Product-of-Sums (POS) Form
• POS expression can be implemented by logic; in which the outputs of
a number of OR gates connect to the inputs of an AND gate.
The Standard POS Form
• .
• This is not a standard form POS expressions;
• Notice that the complete set of variables in the domain is not represented in
the first two terms of the expression; that is, D or is missing from the first
term and C or is missing from the second term.
• A standard POS expression is one in which all the variables in
the domain appear in each sum term in the expression. For
example;
•
• This is a standard POS expression.
• Any non-standard POS expression can be converted to the standard
form using algebra.
Exampl
e
Converting Standard SOP to Standard POS
• The binary values of the product terms in a given standard SOP
expression are not present in the equivalent standard POS expression.
• Also, the binary values that are not represented in the SOP expression
are present in the equivalent POS expression.
• Therefore, to convert from standard SOP to standard POS;
1. Evaluate each product term in the SOP expression.
• That is, determine the binary numbers that represent the product terms.
2. Determine all of the binary numbers not included in the evaluation in step 1.
3. Write the equivalent sum term for each binary number from step
2 and express in POS form.
• Using a similar procedure, you can go from POS to SOP.
Converting Standard SOP to Standard POS
Boolean Expressions and Truth Tables
• All standard Boolean expressions can be easily converted into
truth table format using binary values for each term in the expression.
3. Place a 1 in the output column for each binary value that makes the
standard SOP expression a 1 and place a 0 for all the remaining
binary values.
Exampl
e
Converting POS Expressions to Truth Table
1. List all the possible combinations of binary values of the variables
just as was done for the SOP expression.
3. Finally, place a 0 in the output column for each binary value that
makes the expression a 0 and place a 1 for all the remaining binary
value.
Exampl
e
𝐴
If given POS or SOP
step 1: find its respective truth table
POS -> zero
SOP->One
• Convert each binary value to the corresponding sum term by replacing each 1
with the corresponding variable complement and each 0 with the
corresponding variable.
• For example:
Example
• From the truth table given below determine standard SOP
expression
the and the equivalent standard POS expression.
Exampl
•eFrom the truth table given below determine standard SOP
expression and the equivalent standard POS expression.
the
The Karanaugh Map (K-Map)
•A karnaugh map provides a systematic method for simplifying
Boolean expressions,
• If properly used, it produce the simplest SOP or POS expression possible,
known as the minimum expression.
• Karnaugh maps (K-maps) provide an easy and visual method for finding the
minimum-cost SoP (or PoS) for a Boolean expression.
• A K-map is similar to a truth table because it presents all of the possible
values of input variables and the resulting output for each value.
• Instead of being organized into columns and rows like a truth table; the K-
Map is an array of cells in which each cell represents a binary value of the
input variables.
Karnaugh Map (K-Map)
• The map is made up of a table of every possible
SOP using the number of variables that are being
used.
• If 2 variables are used then a 2X2 map is used
• If 3 variables are used then a 4X2 map is used
• If 4 variables are used then a 4X4 map is used
• If 5 Variables are used then a 8X4 map is used
K-Map SOP Minimization
• K-map is used for simplifying Boolean expressions to their
minimum form.
• Contains the fewest possible terms with the fewest possible variables
per term.
• Generally, a minimum SOP expression can be implemented with
fewer logic gates than a standard expression.
• Mapping a standard SOP expression:
• A 1 is placed on the K-map for each product term in the expression.
• For Example, for the product term a 1 goes in the 101 cell on 3-
variable map.
2 Variables Karnaugh Map
B B
A Notice that the map is going
0 1
false to true, left to right and
A 2 3
top to bottom
B B
The upper right hand cell A 1
is A B if X= A B then put
A
an X in that cell
B B
If X=AB + AB then
A 1
put an X in both of
these cells A 1
Gray Code 0 1
C C
00 AB 0 1
01 AB 2 3
11 AB 6 7
10 AB
4 5
3 Variables Karnaugh Map (cont’d)
X= + C + A A C
Gray Code 0 1
One
C C
simplification
00 AB 1 1 could be
01 AB
X=AB+AB
11 AB
10 AB
1 1
3 Variables Karnaugh Map (cont’d)
X= + C + A A C
Gray Code 0 1
Another
C C
simplification
00 AB 1 1 could be
01 AB X=BC+BC
11 AB A Karnaugh
10 AB Map does wrap
1 1 around
3 Variables Karnaugh Map (cont’d)
X= + C + A A C
Gray Code
0 1
C C
00 AB The Best
1 1 simplification
01 AB would be
11 AB X =B
10 AB
1 1
4 Variables Karnaugh Map
Gray Code 0 0 01 11 10
CD CD CD CD
00 AB 0 1 3 2
01 AB 4 5 7 6
11 AB 12 13 15 14
10 AB 8 9 11 10
Simplify :
Gray Code 00 01 11 10
CD CD CD CD
00 AB Now try it
1
01 AB with Boolean
1 1
reductions
11 AB
1 1
10 AB
1
X = ABD + ABC + CD
The 3-variable K-Map
• The 3-variable K-map is an array of 8 cells.
m0 m1
ABC ABC
m2 m3
ABC ABC
m6 m7 ABC ABC
m4 m5 ABC ABC
Cell Adjacency
• The cells in a K-map are arranged so that there is only a single-variable
change between adjacent cells.
• In the 3-variable map the 010 cell is adjacent to the 000, 011, 110 cell.
• The 010 cell is not adjacent to the 001, 111, 100 or 101 cell.
• Cells in the top row are adjacent to the corresponding cells in
the bottom row. -> Wrap-around adjacency
• Cells in the outer left column are adjacent to the corresponding cells in
the outer right column. -> Wrap-around adjacency
The 4-variable K-Map
• The 4 variable K-map is an array of 16 cells.
CD
AB 00 01 11 10
00 m0 m1 m3 m2
01 m4 m5 m7 m6
10 m8 m9 m11 m10
Mapping a Standard SOP Expression
• Step 1: Determine the binary value of each product term in the
standard SOP expression.
• Step 2: Place 1 on the K-map in the cell having the same value as the
product term.
4. When all the minimum product terms are derived from K-map, they
are summed to form the minimum SOP expression.
Individual Assignment:
A. Simplify F=A’B’C’ + A’BC’ + A’BC using K-map
B. Implement F using Basic Logic Gates
C. Implement the simplified Boolean expression
D. Discuss the difference
1 1 1 1 0 (B’ + C)
B’ AC F = πM(2,3,6)
F = (A + B’)(B’ + C)
F = B’ + AC
3 Variables Karnaugh Map (cont’d)
4 Variables Karnaugh Map
CD
AB 00 01 1 1 10
00 0 1 3 2
01 4 5 7 6
11 12 13 15 14
10
8 9 11 10
4 Variables Karnaugh Map (cont’d)
4 Variables Karnaugh Map (cont’d)
Karnaugh Map - Assignment
Mapping a Standard SOP expression
Example:
Y A BC D A BC D A BCD ABCD A BC D A BC D
Answer:
Y B D ACD
Mapping a Standard POS expression
Example:
Using K-Map, convert the following standard POS
expression into a minimum SOP expression
Y A( B C )
Answer:
Using the minterms (1’s) Using the maxterms (0’s) and complimenting F
F(ABCD)= B’D’+B’C’+A’C’D Grouping as if they were minterms, then using
De Morgen’s theorem to get F.
F’(ABCD)= BD’+CD+AB
F(ABCD)= (B’+D)(C’+D’)(A’+B’)
Don’t Care Conditions
In some situations, we don’t care about the value of a function for
certain combinations of the variables.
These combinations may be impossible to occur in a certain contexts or
the value of the function may not matter when they occur.
In such situations mentioned above, we say the function is incompletely
specified.
There are multiple (completely specified) logic functions that can be used in the
design. So, we can utilize the don’t cares to create the simplest possible circuit.
When constructing the rectangles in the simplification procedure, we can choose
either to cover or not to cover the don’t cares.
Don’t cares can be treated as 1’s or 0’s, depending on which is more
advantageous.
It may be covered or not. It is denoted with X’s.
Don’t Care Conditions
Here is an example of a Karnaugh map with don’t cares (X).
CD CD
AB 00 01 11 10 AB 00 01 11 10
00 0 0 X 0 00 0 0 X 0
01 1 1 X 1 01 1 1 X 1
11 X 1 0 0 11 X 1 0 0
10 0 X 0 0 10 0 X 0 0
● Covering 1’s without ● Covering 1’s utilizing X
utilizing X
Instead of using 2-cell implicants, we can use 4-cell implicants, and the Boolean
function can be better simplified.
Instead of F = A’BD’ + BC’D
we can use F = BC’ + A’B
Exercise: Don’t Care Conditions
CD
AB 00 01 11 10
00 0 1 0 0
01 X X X 1
F(A,B,C,D) = πM(0,2,3,9) + d(4,5,7,8,14)
11 1 1 1 X F = B + AC + A’C’D
10 X 0 1 1
CD
AB 00 01 11 10
00 1 X 0 1
01 1 1 X 1
F(A,B,C,D) = Σm(0,2,4,5,6,12,13,15)
11 1 1 1 X + d(1,7,8,11,14)
F = B + A’D’
10 X 0 X 0
K-Map with “Don’t Care” Conditions (cont’d)
F ( A, B, C , D) CD BC AD
Solution :
CD
AB 00 01 11 10
00 0 1 1 0
0 1 3 2
01 1 X 1 0
4 5 7 6
11 X X X X AD
BC 12 13 15 14
10 0 0 1 0
8 9 11 10
CD
Minimum SOP expression is
F ( A, B, C , D) CD BC AD
End of Chapter - 4
Questions ?
73