1 / 51

SLIDES FOR CHAPTER 5 KARNAUGH MAPS

This chapter in the book includes: Objectives Study Guide 5.1 Minimum Forms of Switching Functions 5.2 Two- and Three-Variable Karnaugh Maps 5.3 Four-Variable Karnaugh Maps 5.4 Determination of Minimum Expressions 5.5 Five-Variable Karnaugh Maps 5.6 Other Uses of Karnaugh Maps

micah
Download Presentation

SLIDES FOR CHAPTER 5 KARNAUGH MAPS

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. This chapter in the book includes: Objectives Study Guide 5.1 Minimum Forms of Switching Functions 5.2 Two- and Three-Variable Karnaugh Maps 5.3 Four-Variable Karnaugh Maps 5.4 Determination of Minimum Expressions 5.5 Five-Variable Karnaugh Maps 5.6 Other Uses of Karnaugh Maps 5.7 Other Forms of Karnaugh Maps Programmed Exercises Problems SLIDES FORCHAPTER 5KARNAUGH MAPS

  2. Switching functions can generally be simplified by using the algebraic techniques described in Unit 3. However, two problems arise when algebraic procedures are used: 1. The procedures are difficult to apply in a systematic way. 2. It is difficult to tell when you have arrived at a minimum solution. The Karnaugh map method is generally faster and easier to apply than other simplification methods. #Karnaugh Map and Quine-McCluskey provide a systematic methods for simply switching function! Karnaugh Maps

  3. Minimum Forms of Switching Functions Given a minterm expansion, the minimum sum-of-products format can often be obtained by the following procedure: • Combine terms by using XY′ + XY = X. Do this repeatedly to eliminate as many literals as possible. A given term may be used more than once because X + X = X. • Eliminate redundant terms by using the consensus theorem or other theorems. Unfortunately, the result of this procedure may depend on the order in which the terms are combined or eliminated so that the final expression obtained is not necessarily minimum.

  4. Minimum Forms of Switching Functions: * Minimum sum-of-products expression: 不同於minterm expansion, 主要目的在於表示為 一個tow-level circuit(以AND,OR gate 來實現電路),並使gate number和gate input 之cost 達最低。 *對於描述一個function,不同於minterm expansion,這邊所述之Minimum sum-of-products expression不必是唯一。

  5. Example: Find a minimum sum-of-products expression for 多次使用 (X+X=X) None of the terms in the above expression can be eliminated by consensus. However, combining terms in a different way leads directly to a minimum sum of products: *minimum sum-of-products expression不必是唯一解

  6. Example: Find a minimum products-of-sum expression for ( X + Y ) ( X + Y’ ) (Z+X’)( Z + Y ) ( Y + X ) Using the theorem (X+Y)(X+Y’)=X, to combine terms. Using consensus law: (X+Y)(X’+Z)(Y+Z)= (X+Y)(X’+Z) • 由上述兩個case可以得知,以minmum POS或minimumSOP • 來化簡為一two-level circuit,雖可以得到化簡,但仍非唯一解。

  7. Karnaugh Maps: Two- and Three- VariableKarnaugh Maps(K-maps) Just like a truth table, the Karnaugh map of a function specifies the value of the function for every combination of values of the independent variables. • 在描述K-maps時,僅一變數於上列,其餘變數在行。 • 下圖為一雙變數之K-maps。

  8. (a) • 如何描述K-maps: • 在maps填入相對應於F的值 • 其中1代表相對應於F的一個minterm。 • 2. 如同上一章節所述,取1的項來描述F的 • minterm expansion,其中位元為0時, • 其文字符號便是一個取補數的變數。 • 3. 相鄰(adjacent)之1變數,由於僅一位元差異 • ,因此可以合併而化簡之。 * Looping the corresponding 1’s on the maps * Adjacent rows differ in only one variable

  9. * The rows are labeled in the sequence 00, 01, 11, 10 so that values in adjacent rows differ in only one variable. (請不要跟truth table混淆,鄰近項差 一變數可幫助化簡!) * Fill the maps from truth table. Construct the K-map Karnaugh Map for Three-Variable Function

  10. * Again, the adjacent squares of the map differ in only one variable (including top and bottom rows) and therefore can be combined using the theorem XY’+XY=X. * 請注意decimal notation 在square 中之順序 Location of Minterms on a Three-Variable Karnaugh Map

  11. The adjacent terms in Karnaugh Map

  12. * 如同二變數K-maps的建構方式,若以 Minterm expansion 描述function F, 將F=1所對應之方格填入1,其餘方格填 滿0。得到: F(a, b, c) = Sm(1, 3, 5) * 反之,若以 Maxterm expansion 描述 function F,取其對應為0的項次。可得: F(a, b, c) = ÕM(0, 2, 4, 6, 7) Karnaugh Map of F(a, b, c) = Sm(1, 3, 5) = ÕM(0, 2, 4, 6, 7)

  13. * You can easily plot a K-maps from a algebraic form. For example, the bc’ is 1 only when b=1 and c=0. Karnaugh Maps for Product Terms

  14. Example: f(a,b,c) = abc' + b'c + a'

  15. 如何藉由K-maps來化簡一布林函數? Simplification of a Three-Variable Function (Figure 5-6)

  16. 要由K-maps取得函數之互補式,可將0’s 方格取代為1‘s,然後再簡化 The map for the complement of F is formed by replacing 0’s with 1’s and 1’s with 9’s on the map of F. F′ = c′ + ab Complement of Map in Figure5-6

  17. * Ch2~Ch3所敘述之運算簡化方式,可以完全由K-maps來描述跟 簡化。K-maps中,looping1’s方格,以最少loops,但涵蓋所有1’s方 格為基礎原則。 (多餘之loop) Karnaugh Maps Which Illustrate the Consensus Theorem

  18. 不同looping方式,獲得不同的solution,就如前所述,表示法為不同looping方式,獲得不同的solution,就如前所述,表示法為 不唯一,但皆符合化簡之”cost down” 和”function demand”之原則。 Different Looping form Function with Two Minimal Forms

  19. 將對應於truth table中之變數填入K-maps中。辨識functionF=0或1 • , 填入K-maps之方格中。 • 圈選(looping)方格中1’s的位置,找出最少個數的loops,但卻足以 • 包含或函蓋標註為1’s的全部方格。如此便可以得出最少乘積項以 • 加總這些乘積時會有最低的輸入成本。 • 在looping時,盡可能使loops大一些,以便包含最多的1’s方格,其 • 乘積項可以得到低輸入成本(input cost) The basic rules to simply function from the K-Maps

  20. * 如同三變數K-maps,注意項次的在方格中的排列次序! Each minterm is located adjacent to the four terms with which it can combine. For example, m5 (0101) could combine with m1 (0001), m4 (0100), m7 (0111), or m13 (1101). Location of Minterms onFour-Variable Karnaugh Map

  21. Plot off(a,b,c,d)= acd + a’b + d’

  22. 為何要取上下兩列? Simplification ofFour-Variable Functions

  23. The don’t-care minterms are indicated by X’s. • When choosing terms to form the minimum SOP, all the 1’s must • be covered, but the X’s are only used if they will simplify the resulting • expression. Simplification of an Incompletely Specified Function

  24. Use a four variable Karnaugh map to find the minimum product of sums for f: f = x′z′ + wyz + w′y′z′ + x′y First, we will plot the 1’s on a Karnaugh map. Example: Obtainning minimum-SOP from minimum POS

  25. Then, from the 0’s we get: f'= y'z + wxz' + w'xy Finally, we can complement f' to get a minimum product of sums of f : f = (y + z′)(w′ + x′ + z)(w + x′ + y′) Figure 5-14 From DeMorgan’s theorem

  26. Any single 1 or any group of 1’s which can be combined together on a map of the function F represents a product term which is called an implicant(意含項) of F. A product term implicant is called a prime implicant(必要項) if it cannot be combined with another term to eliminate a variable. Implicants and Prime Implicants Section 5.4 (p. 136)

  27. Prime Implicant Implicant Implicant Prime Implicant Implicant Prime Implicant

  28. Example 01: Determination of All Prime Implicants

  29. Example 02:

  30. If a minterm is covered by only one prime implicant, that prime implicant is said to be essential, and it must be included in the minimum sum of products. Essential Prime Implicants Prime Implicants Essential Prime Implicants Implicants Section 5.4 (p. 138)

  31. 以系統化的程序從K-map來求出化簡表示式 • Implicant(意含項): K-maps中由含有1之方格所組合而成的所有 • loops 均是意含項。 • Prime implicant(必要項): 可由K-maps中的意含項合併化簡, • 使該合併項不再是函數的一個意含項。 • Essential (本質必要項): 如果函數的某一個miniterm 僅包含在 • 其中一個必要項時。該必要項稱為本質必要項。 Essential

  32. Essential : Note: 1’s shaded in blue are covered by only one prime implicant. All other 1’s are covered by at least two prime implicants. *共有五個必要項,其中有三個本質必要項 * 利用本質必要項來化簡: 因此函數可以由三個本質必要項(AC’、A’B’D’、ACD)和一個必要項(m7) 來獲得:

  33. AB CD 00 01 11 10 00 01 11 10

  34. * Essential term then add the remaining prime implicants Choose a 1 which has not been covered. Find all adjacent 1’s and X’s. Are the chosen 1 and its adjacent 1’s and X’s covered by a single term? That term is an essential prime implicant. Loop it. All uncovered 1’s checked? Find a minimum set of prime implicants which cover the remaining 1’s on the map. no yes no Flowchart for Determining a Minimum Sum of Products Using a Karnaugh Map yes

  35. Example 01: 透過上述之程序來化簡 Shaded 1’s are covered by only one prime implicant. Essential prime implicants: A′B, AB′D′ Then AC′D covers the remaining 1’s.

  36. A five-variable map can be constructed in three dimensions by placing one four-variable map on top of a second one. Terms in the bottom layer are numbered 0 through 15 and corresponding terms in the top layer are numbered 16 through 31, so that the terms in the bottom layer contain A' and those in the top layer contain A. To represent the map in two dimensions, we will divide each square in a four-variable map by a diagonal line and place terms in the bottom layer below the line and terms in the top layer above the line. Five-Variable Karnaugh Maps Section 5.5 (p. 141)

  37. Note that terms m0 and m20 do not combine because they are in different layers and different columns (they differ in two variables). • Each term can be adjacent to exactly five other terms, 5 in the same layer, 1 in other layer.

  38. Simply a five-variable K-maps

  39. How to loop the terms? Each term can be adjacent to exactly five other terms: four in the same layer and one in the other layer. Figure 5-22

  40. When checking for adjacencies, each term should be checked against the five possible adjacent squares. P1 and P2 are essential prime implicants. • 本K-maps共有6個必要項,其中2個為本質必要項。 • 先處理Essential(P1,P2), 在處理Prime implicants(P3,P4),最後補上剩餘兩項次 Example01: F(A, B,C,D,E)=Sm(0,1,4,5,13,15,20,21,22,23,24,26,28,30,31)

  41. Example 02: P1, P2, P3, and P4 are essential prime implicants. F(A, B, C, D, E) = Ʃ m(0, 1, 3, 8, 9, 14, 15, 16, 17, 19, 25, 27, 31)

  42. Using a Karnaugh map to facilitate factoring, we see that the two terms in the first column have A′B′ in common; the two terms in the lower right corner have AC in common. Figure 5-25

  43. F = ABCD + B’CDE + A’B’ + BCE’ We can use a Karnaugh map for guidance in algebraic simplification. From Figure 5-26, we can add the term ACDE by the consensus theorem and then eliminate ABCD and B’CDE.

  44. Figure 5-26

  45. Instead of labeling the sides of a Karnaugh map with 0’s and 1’s, some people prefer to use Veitch diagrams. In Veitch diagrams, A = 1 for the half of the map labeled A, and A = 0 for the other half. The other variables have a similar interpretation. Other Forms of Karnaugh Maps Section 5.7 (p. 146)

  46. Figure 5-27: Veitch Diagrams

  47. Two alternative forms of five-variable maps are also used. One form simply consists of two four-variable maps side-by-side. A modification of this uses a mirror image map. In this map, first and eighth columns are “adjacent” as are second and seventh columns, third and sixth columns, and fourth and fifth columns.

  48. Figure 5-28: Side-by-side Form of Five-Variable Karnaugh Maps

  49. Figure 5-28: Mirror Image Form of Five-Variable Karnaugh Maps

  50. 通常超過六變數後的K-Maps,較依賴人的經驗法則,因此不易執行電腦程序的標準運算,因此當變數過多時,通常會使用通常超過六變數後的K-Maps,較依賴人的經驗法則,因此不易執行電腦程序的標準運算,因此當變數過多時,通常會使用 Quine-McCluskey method來幫助化簡。

More Related