ECE 331 – Digital System Design Karnaugh Maps (Lecture #7) The slides included herein were taken from the materials accompanying Fundamentals of Logic Design, 6th Edition, by Roth and Kinney, and were used with permission from Cengage Learning.
Simplification of Logic Functions Logic functions can generally be simplified using Boolean algebra. However, two problems arise: It is difficult to apply to Boolean algebra laws and theorems in a systematic way. It is difficult to determine when a minimum solution has been achieved. Using a Karnaugh map is generally faster and easier than using Boolean algebra. Spring 2011 ECE 331 - Digital System Design
Simplification using Boolean Algebra Given: F(A,B,C) = Sm(0, 1, 2, 5, 6, 7) Find: minimum SOP expression Combining terms in one way: Combining terms in a different way: Spring 2011 ECE 331 - Digital System Design
ECE 331 - Digital System Design Karnaugh Maps Like a truth table, a Karnaugh map specifies the value of a function for all combinations of the input variables. Spring 2011 ECE 331 - Digital System Design
ECE 331 - Digital System Design Two-variable K-map 1 m 2 3 B A row # A B minterm m0 1 m1 2 m2 3 m3 Spring 2011 ECE 331 - Digital System Design
Two-variable K-map: Example 2 1 3 row # A B F 1 2 3 Minterm expansion: F(A,B) = S m(0, 1) = A'B' + A'B Maxterm expansion: F(A,B) = P M(2, 3) = (A'+B).(A'+B') numeric algebraic Spring 2011 ECE 331 - Digital System Design
ECE 331 - Digital System Design Three-variable K-map row # A B C minterm m0 1 m1 2 m2 3 m3 4 m4 5 m5 6 m6 7 m7 m 4 5 1 BC A 3 7 6 2 0 0 0 1 1 1 1 0 Gray Code Spring 2011 ECE 331 - Digital System Design
Three-variable K-map: Example 3 7 2 6 4 1 5 row # A B C F 1 2 3 4 5 6 7 Minterm expansion: F(A,B,C) = S m(2, 3, 4, 6) Maxterm expansion: F(A,B,C) = P M(0, 1, 5, 7) Spring 2011 ECE 331 - Digital System Design
Minimization using K-maps K-maps can be used to derive the Minimum Sum of Products (SOP) expression Minimum Product of Sums (POS) expression Procedure: Enter functional values in the K-map Identify adjacent cells with same logical value Adjacent cells differ in only one bit Use adjacency to minimize logic function Horizontal and Vertical adjacency K-map wraps from top to bottom and left to right Spring 2011 ECE 331 - Digital System Design
Minimization using K-maps Logical Adjacency is used to Reduce the number number of literals in a term Reduce the number of terms in a Boolean expression. The adjacent cells Form a rectangle Must be a power of 2 (e.g. 1, 2, 4, 8, …) The greater the number of adjacent cells that can be grouped together (i.e. the larger the rectangle), the more the function can be reduced. Spring 2011 ECE 331 - Digital System Design
K-maps – Logical Adjacency Gray code Spring 2011 ECE 331 - Digital System Design
Minimization: Example #1 Minimize the following logic function using a Karnaugh map: F(A,B,C) = S m(2, 6, 7) Specify the equivalent maxterm expansion. Spring 2011 ECE 331 - Digital System Design
Minimization: Example #2 Minimize the following logic function using a Karnaugh map: F(A,B,C) = P M(1, 3, 5, 6, 7) Specify the equivalent minterm expansion. Spring 2011 ECE 331 - Digital System Design
Minimization: Example #3 Use a Karnaugh map to determine the 1. minimum SOP expression 2. minimum POS expression For the following logic function: F(A,B,C) = S m(0, 1, 5, 7) Specify the equivalent maxterm expansion. Spring 2011 ECE 331 - Digital System Design
Minimization: Example #4 Use a Karnaugh map to determine the 1. minimum SOP expression 2. minimum POS expression For the following logic function: F(A,B,C) = P M(0, 1, 5, 7) Specify the equivalent minterm expansion. Spring 2011 ECE 331 - Digital System Design
Minimization: Example #5 For the following truth table: # A B C F 1 2 3 4 5 6 7 Spring 2011 ECE 331 - Digital System Design
Example #5 Specify the: Use a K-map to determine the: 1. minterm expansion 2. maxterm expansion Use a K-map to determine the: 1. minimum SOP expression 2. minimum POS expression Spring 2011 ECE 331 - Digital System Design
Minimization: Example #6 For the following truth table: # A B C F 1 2 3 4 5 6 7 Spring 2011 ECE 331 - Digital System Design
Example #6 Specify the: Use a K-map to determine the: 1. minterm expansion 2. maxterm expansion Use a K-map to determine the: 1. minimum SOP expression 2. minimum POS expression Spring 2011 ECE 331 - Digital System Design
Minimal Forms Can a logic function have more than one minimum SOP expression? Can a logic function have more than one minimum POS expression? Spring 2011 ECE 331 - Digital System Design
K-maps – Two minimal forms F(A,B,C) = S m(0,1,2,5,6,7) = P M(3,4) Spring 2011 ECE 331 - Digital System Design
ECE 331 - Digital System Design Questions? Spring 2011 ECE 331 - Digital System Design