I NTRODUCTION TO THE K ARNAUGH M AP 1 Alan Clements.

Slides:



Advertisements
Similar presentations
Digital Circuits.
Advertisements

ECE 238L Computer Logic Design Spring 2010
C HAPTER 3 Architecture and Organization © 2014 Cengage Learning Engineering. All Rights Reserved. 1 Computer Organization and Architecture: Themes and.
ECE 301 – Digital Electronics Karnaugh Maps (Lecture #7) The slides included herein were taken from the materials accompanying Fundamentals of Logic Design,
Karnaugh Maps for Simplification
EET 1131 Unit 5 Boolean Algebra and Reduction Techniques
Computer Engineering (Logic Circuits) (Karnaugh Map)
Chapter 2: Combinatorial Logic Circuits Illustration Pg. 32 Logic Circuit Diagrams - Circuit Optimization -2,3,4 level maps 48 elements Optimized to 25.
IKI a-Simplification of Boolean Functions Bobby Nazief Semester-I The materials on these slides are adopted from those in CS231’s Lecture.
Digital Logic Chapter 4 Presented by Prof Tim Johnson
Chapter 3.5 Logic Circuits. How does Boolean algebra relate to computer circuits? Data is stored and manipulated in a computer as a binary number. Individual.
1 Simplification of Boolean Functions:  An implementation of a Boolean Function requires the use of logic gates.  A smaller number of gates, with each.
Department of Computer Engineering
CHAPTER 1 INTRODUCTION TO DIGITAL LOGIC. K-Map (1)  Karnaugh Mapping is used to minimize the number of logic gates that are required in a digital circuit.
1 Digital Logic Design Week 5 Simplifying logic expressions.
1 © 2015 B. Wilkinson Modification date: January 1, 2015 Designing combinational circuits Logic circuits whose outputs are dependent upon the values placed.
CHAPTER 3: PRINCIPLES OF COMBINATIONAL LOGIC
Lecture 4 Nand, Nor Gates, CS147 Circuit Minimization and
CS1Q Computer Systems Lecture 7
February 2, 2004CS 2311 Karnaugh maps Last time we saw applications of Boolean logic to circuit design. – The basic Boolean operations are AND, OR and.
Karnaugh Maps (K-Maps)
CS231 Boolean Algebra1 Summary so far So far: – A bunch of Boolean algebra trickery for simplifying expressions and circuits – The algebra guarantees us.
LOGIC CIRCUITLOGIC CIRCUIT. Goal To understand how digital a computer can work, at the lowest level. To understand what is possible and the limitations.
Karnaugh Mapping Digital Electronics. Karnaugh Mapping or K-Mapping This presentation will demonstrate how to Create and label two, three, & four variable.
Floyd, Digital Fundamentals, 10 th ed Digital Fundamentals Tenth Edition Floyd Chapter 4 © 2008 Pearson Education.
Karnaugh Map and Circuit Design.
June 12, 2002© Howard Huang1 Karnaugh maps Last time we saw applications of Boolean logic to circuit design. – The basic Boolean operations are.
BOOLEAN ALGEBRA AND LOGIC SIMPLIFICATION
CHAPTER 1 INTRODUCTION TO DIGITAL LOGIC
THE K-MAP.
© 2014 Cengage Learning Engineering. All Rights Reserved.2 Computer Organization and Architecture: Themes and Variations, 1 st Edition Clements.
Digital Logic (Karnaugh Map). Karnaugh Maps Karnaugh maps (K-maps) are graphical representations of boolean functions. One map cell corresponds to a row.
BOOLEAN ALGEBRA LOGIC GATES. Introduction British mathematician George Boole( ) was successful in finding the link between logic and mathematics.
Boolean Algebra and Computer Logic Mathematical Structures for Computer Science Chapter 7 Copyright © 2006 W.H. Freeman & Co.MSCS Slides Boolean Logic.
C HAPTER 1 Computer Systems Architecture © 2014 Cengage Learning Engineering. All Rights Reserved. 1 Computer Organization and Architecture: Themes and.
Karnaugh Maps The minimization method using Boolean Algebra, apart from being laborious and requiring the remembering all the laws, can lead to solutions.
CS231 Boolean Algebra1 Circuit analysis summary After finding the circuit inputs and outputs, you can come up with either an expression or a truth table.
©2010 Cengage Learning SLIDES FOR CHAPTER 5 KARNAUGH MAPS Click the mouse to move to the next page. Use the ESC key to exit this chapter. This chapter.
CE1110: Digital Logic Design Gate Level Minimization Karnaugh Maps (K-Maps)
EET 1131 Unit 5 Boolean Algebra and Reduction Techniques
Lecture 4 Nand, Nor Gates, CS147 Circuit Minimization and
University of Maryland Baltimore County Department of Computer Science and Electrical Engineering   CMPE 212 Laboratory (Discussion 6) Hasib Hasan
Dr. Clincy Professor of CS
Circuit analysis summary
Karnaugh Map Method.
Lecture 3 Gunjeet Kaur Dronacharya Group of Institutions
Karnaugh Maps.
Digital Logic and Design
BASIC & COMBINATIONAL LOGIC CIRCUIT
CHAPTER 5 KARNAUGH MAPS 5.1 Minimum Forms of Switching Functions
Karnaugh Mapping Karnaugh Mapping Digital Electronics
Karnaugh Maps Topics covered in this presentation: Karnaugh Maps
Karnaugh Mapping Digital Electronics
ECE 331 – Digital System Design
ECE 331 – Digital System Design
Karnaugh Mapping Karnaugh Mapping Digital Electronics
Performance– Meaning and Metrics
Karnaugh Mapping Digital Electronics
CS Chapter 3 (3A and ) – Part 3 of 5
Dr. Clincy Professor of CS
From now on: Combinatorial Circuits:
Overview Part 2 – Circuit Optimization
3-Variable K-map AB/C AB/C A’B’ A’B AB AB’
Karnaugh Maps (K maps).
Karnaugh maps Last time we saw applications of Boolean logic to circuit design. The basic Boolean operations are AND, OR and NOT. These operations can.
Basic circuit analysis and design
Karnaugh Map Method By: Asst Lec. Besma Nazar Nadhem
Circuit Simplification and
Computer Architecture
Presentation transcript:

I NTRODUCTION TO THE K ARNAUGH M AP 1 Alan Clements

© 2014 Cengage Learning Engineering. All Rights Reserved. Computer Organization and Architecture: Themes and Variations, 1 st Edition Clements 2 Karnaugh Maps The Karnaugh map, or K-map, is a graphical technique for the representation and simplification of a Boolean expression. The K-map is a two-dimensional form of the truth table, drawn in such a way that the simplification of a Boolean expression can be seen from the location of 1s on the map. A system with n variables has 2 n lines in its truth table and 2 n squares on its K-map. Each square on the K-map is associated with a line (i.e., minterm) in the truth table. Figure 1 shows a K-map for three variables. The key to the Karnaugh map is the layout of the squares. Horizontally and vertically adjacent squares differ by only one variable. For example, in Figure 1 the leftmost two terms on the top line are A  B  C and A  B  C. The only difference between these terms is B and B. Figure 1 K-map for three variables

© 2014 Cengage Learning Engineering. All Rights Reserved. Computer Organization and Architecture: Themes and Variations, 1 st Edition Clements 3 Figure 2 shows a K-map for four Variables where all the 16 minterms of a truth table appear. It is easy to read a K-map. In Figure 2, the square with ABCD in it represents the minterm ABCD and falls in the AB column 01 and the CD row 11. Figure 2 K-map for four variables

© 2014 Cengage Learning Engineering. All Rights Reserved. Computer Organization and Architecture: Themes and Variations, 1 st Edition Clements 4 Figure 3 shows how a K-map can be interpreted in terms of the regions over which a variable is true or false. Here, the region on dark blue shows the region for which A, B, C, and D are true, respectively. The region in light blue corresponds to the region where a variable is false. Figure 3 The regions of a K-map

© 2014 Cengage Learning Engineering. All Rights Reserved. Computer Organization and Architecture: Themes and Variations, 1 st Edition Clements 5 Figure 4 shows how we read a 4-variable K-map. On the right-hand side we have a K-map with four minterms. These correspond to ABCD, ABCD, ABCD, and ABCD. Figure 4 Reading a K-map

© 2014 Cengage Learning Engineering. All Rights Reserved. Computer Organization and Architecture: Themes and Variations, 1 st Edition Clements 6 A three-variable K-map has four vertical columns, one for each of the four possible values of two out of the three variables. The leftmost column is labeled 00 and represents the region for which A = 0, B = 0. The next column is labeled 01, and represents the region for which A = 0, B = 1. The next column is labeled 11 and represents the region for which A = 1, B = 1. The fourth column, 10, represents the region for which A = 1, B = 0. Figure 5 Plotting minterms on a K-map

© 2014 Cengage Learning Engineering. All Rights Reserved. Computer Organization and Architecture: Themes and Variations, 1 st Edition Clements 7 The three-variable K-map below has two horizontal rows, the upper row corresponding to C = 0 and the lower to C = 1. Any square on this K-map represents a unique combination of the three variables in true or complemented form. The figure demonstrates how F = A  B  C + A  B  C +A  B  C is plotted. A square containing a logical 1 is said to be covered by a 1. No two 1s plotted on the K-map are adjacent to each other, and that the function F = A  B  C + A  B  C + A  B  C cannot be simplified. Squares that do not contain a 1 are left unmarked even though they must contain a 0.. Figure 5 Plotting minterms on a K-map

© 2014 Cengage Learning Engineering. All Rights Reserved. Computer Organization and Architecture: Themes and Variations, 1 st Edition Clements 8 Figure 6 Plotting two Boolean expressions on a K-map Consider figure 6 in which the function f 1 = A  B  C + A  B  C is plotted on the left-hand map. The two minterms in this function are A  B  C and A  B  C and occupy the cells for which A = 1, B = 1, C = 0, and A = 1, B = 1, C = 1, respectively.

© 2014 Cengage Learning Engineering. All Rights Reserved. Computer Organization and Architecture: Themes and Variations, 1 st Edition Clements 9 Figure 6 Plotting two Boolean expressions on a K-map In the K-map for F 1 two adjacent squares are covered. Now look at the map for F 2 = A  B. A group of two squares is covered, corresponding to the column A = 1, B = 1. F 2 does not involve C, and a 1 is entered in the squares for which A = B = 1 and C = 0, and A = B = 1 and C = 1; i.e., a 1 is entered for all values of C for which AB = 11. When plotting a product term like A  B, you locate the region for which AB = 11. The two K-maps are identical, so that F 1 = F 2 and A  B  C + A  B  C = A  B. Using Boolean algebra, A  B  C + A  B  C = A  B  (C + C) = A  B(1) = A  B. Two adjacent squares in a K-map can be grouped together to form a single simpler term.

© 2014 Cengage Learning Engineering. All Rights Reserved. Computer Organization and Architecture: Themes and Variations, 1 st Edition Clements 10 Simplifying Sum-of-Product Expressions with a Karnaugh Map The first step in simplifying a Boolean expression by means of a K-map is to plot all the ones in the function's truth table on the K-map. The next step is to combine adjacent 1s into groups of one, two, four, eight, or sixteen. The groups of minterms should be as large as possible—a single group of four minterms yields a simpler expression than two groups of two minterms. The final stage in simplifying an expression is reached when each of the groups of minterms (i.e., the product terms) are ORed together to form the simplified sum-of-products expression. We now have to demonstrate how the product terms of a general Boolean expression are plotted on the map. Figures 7 to 12 presents six functions plotted on K-maps. In these diagrams various sum-of-products expressions have been plotted directly from the equations themselves, rather than from the minterms of the truth table. The following notes should help in understanding these diagrams.

© 2014 Cengage Learning Engineering. All Rights Reserved. Computer Organization and Architecture: Themes and Variations, 1 st Edition Clements 11 The following notes should help in understanding these diagrams. 1.For a four-variable K-map: 1-variable product term covers 8 squares 2-variable product terms cover 4 squares 3-variable product terms cover 2 squares 4-variable product terms cover 1 squares 2.A square covered by a 1 may belong to more than one term in the sum- of-products expression. If a 1 on the K-map appears in two groups, it is equivalent to adding the corresponding minterm to the overall expression for the function plotted on the map twice. Repeating a term in an expression does not alter the value of the expression, because one of the axioms of Boolean algebra is X + X = X.

© 2014 Cengage Learning Engineering. All Rights Reserved. Computer Organization and Architecture: Themes and Variations, 1 st Edition Clements 12 3.The K-map is not a square or a rectangle as it appears in these diagrams. A K-map is a torus or doughnut shape. That is, the top edge is adjacent to the bottom edge and, the left-hand edge is adjacent to the right-hand edge. Whenever a group of terms extends across the edge of a K-map, we have shaded it to emphasize the wrap-around nature of the map. 4.In order either to read a product term from the map, or to plot a product term on the map, it is necessary to ask the question, what minterms (squares) are covered.

© 2014 Cengage Learning Engineering. All Rights Reserved. Computer Organization and Architecture: Themes and Variations, 1 st Edition Clements 13 Figure 7 Plotting two Boolean expressions on a K-map

© 2014 Cengage Learning Engineering. All Rights Reserved. Computer Organization and Architecture: Themes and Variations, 1 st Edition Clements 14 Figure 8 Plotting two Boolean expressions on a K-map

© 2014 Cengage Learning Engineering. All Rights Reserved. Computer Organization and Architecture: Themes and Variations, 1 st Edition Clements 15 Figure 9 Plotting two Boolean expressions on a K-map

© 2014 Cengage Learning Engineering. All Rights Reserved. Computer Organization and Architecture: Themes and Variations, 1 st Edition Clements 16 Figure 10 Plotting two Boolean expressions on a K-map

© 2014 Cengage Learning Engineering. All Rights Reserved. Computer Organization and Architecture: Themes and Variations, 1 st Edition Clements 17 Figure 11 Plotting two Boolean expressions on a K-map

© 2014 Cengage Learning Engineering. All Rights Reserved. Computer Organization and Architecture: Themes and Variations, 1 st Edition Clements 18 Figure 12 Plotting two Boolean expressions on a K-map

© 2014 Cengage Learning Engineering. All Rights Reserved. Computer Organization and Architecture: Themes and Variations, 1 st Edition Clements 19 Example 1 Figure 13 gives a K-map for the expression F = A  B + A  B  C  D + A  B  C  D + A  B  C  D. The simplified function is F = A  B + B  D + A  C  D.

© 2014 Cengage Learning Engineering. All Rights Reserved. Computer Organization and Architecture: Themes and Variations, 1 st Edition Clements 20 Example 2 Figure 14 gives a K-map for the expression F = A  C  D + A  C  D + A  B  C + A  B  D. In this case only one regrouping is possible. The simplified function is F = B  D + A  C  D + A  C  D + A  B  C.

© 2014 Cengage Learning Engineering. All Rights Reserved. Computer Organization and Architecture: Themes and Variations, 1 st Edition Clements 21 Example 3 Figure 15 gives a K-map for the expression F = A  B  C  D + A  B  C  D + A  B  C  D + A  B  C  D + A  B  C  D + A  B  C  D + A  B  C  D + A  B  C  D This can be simplified to two product terms with F = B  D + B  D.

© 2014 Cengage Learning Engineering. All Rights Reserved. Computer Organization and Architecture: Themes and Variations, 1 st Edition Clements 22 Example 4 Figure 16 gives a K-map for the expression F = A  B  C + A  B  C + A  B  C + A  B  C + A  B  C We can group the minterms together in two ways, both of which are equally valid; that is, there are two equally correct simplifications of this expression. We can write either F = A  B + A  C + A  B or F = A  B + B  C + A  B.