©2010 Cengage Learning SLIDES FOR CHAPTER 6 QUINE-McCLUSKEY METHOD This chapter in the book...

32
©2010 Cengage Learning SLIDES FOR CHAPTER 6 QUINE-McCLUSKEY METHOD This chapter in the book includes: Objectives Study Guide 6.1 Determination of Prime Implicants 6.2 The Prime Implicant Chart 6.3 Petrick’s Method 6.4 Simplification of Incompletely Specified Functions 6.5 Simplification Using Map-Entered Variables 6.6 Conclusion Programmed Exercises Problems

Transcript of ©2010 Cengage Learning SLIDES FOR CHAPTER 6 QUINE-McCLUSKEY METHOD This chapter in the book...

©2010 Cengage Learning

SLIDES FOR

CHAPTER 6

QUINE-McCLUSKEY METHOD

This chapter in the book includes:ObjectivesStudy Guide

6.1 Determination of Prime Implicants6.2 The Prime Implicant Chart6.3 Petrick’s Method6.4 Simplification of Incompletely Specified Functions6.5 Simplification Using Map-Entered Variables6.6 Conclusion

Programmed ExercisesProblems

©2010 Cengage Learning

Why we need to learn Quine-McCluskey method?

1.卡諾圖化簡法提供一有效率的布林函數化簡,可是當變數過多( 六變數 ) 時,就不容易用 K-maps來做化簡,需要倚靠人的經驗判斷,不易用電腦程序來執行。

2.Quine-Mccluskey發表一種適合於電腦執行簡化工作的方法稱為列表法。列表法沿用一定步驟來逐步化簡,過程冗長重複,因此可以使用數位電路來執行簡化。3.Q-M method可以用來一 minimum sum of products: (a) 尋找必要項 (find out the prime implicants) (b) 篩選必要項 (select a minimum set of prime implicants)

©2010 Cengage Learning

Determination of Prime Implicants

In order to apply the Quine-McCluskey method to determine a minimum sum-of-products expression for a function, the function must be given as a sum of minterms.

If the function is not in minterm form, the minterm expansion can be found by using one of the techniques given in section 5.3.

Section 6.1 (p. 164)

©2010 Cengage Learning

In the first part of the Quine-McCluskey method, all of the prime implicants of a function are systematically formed by combining minterms.

©2010 Cengage Learning

f(a, b, c, d) = ∑m(0, 1, 2, 5, 6, 7, 8, 9, 10, 14)

To reduce the required number of comparisons, the binary minterms are sorted into groups according to the number of 1’s in each term.

依照數值中之位元為 1 的個數來分組

©2010 Cengage Learning

Table 6-1. Determination of Prime Implicants

1. 相鄰兩 group 互相比對,若可合併 () ,即可挑選為下一行之新項2. 重複項移除3. 留下未記號者 () ,即為必要項之組合

• 兩組比對皆超過一個變數 不同 , 則比對合併結束

©2010 Cengage Learning

由上述之分析獲得必要項之組合

但上述結果可藉由 Consensus law 再化簡為三個項

因此藉由列表所獲得之必要項組合並非一最佳 ( 最簡 ) 化結果所以… . 列表法獲得之必要項需要進行篩選。

©2010 Cengage Learning

Definition: Given a function F of n variables, a product term P is an implicant of F iff for every combination of values of the n variables for which P = 1, F is also equal to 1.

Definition: A prime implicant of a function F is a product term implicant which is no longer an implicant if any literal is deleted from it.

©2010 Cengage Learning

The Prime Implicant Chart

The second part of the Quine-McCluskey method employs a prime implicant chart to select a minimum set of prime implicants.

The minterms of the function are listed across the top of the chart, and the prime implicants are listed down the side.

If a prime implicant covers a given minterm, an X is placed at the intersection of the corresponding row and column.

©2010 Cengage Learning

Table 6-2. Prime Implicant Chart

If a minterm is covered by only one prime implicant, then that prime implicant is called an essential prime implicant and must be included in the minimum sum of products.

篩選出”本質必要項” minterm

©2010 Cengage Learning

Table 6-3.

Each time a prime implicant is selected for inclusion in the minimum sum, the corresponding row should be crossed out. After doing this, the columns which correspond to all minterms covered by that prime implicant should also be crossed out.

Essential

Un-covered minterm:

若選 (1,5) 僅 cover5若選 (6,7) 僅 cover7

; 故選 (5,7)

©2010 Cengage Learning

Derivation of prime implicants:

Example 1:

©2010 Cengage Learning

Table 6-4.

A cyclic prime implicant chart is a prime implicant chart which has two or more X’s in every column. We will find a solution by trial and error. We will start by trying (0, 1) to cover column 0.

One solution is F=a’b’+bc’+ac

Cyclic prime implicant

©2010 Cengage Learning

Table 6-5.

We are not guaranteed that the previous solution is minimum. We must go back and solve the problem over again starting with the other prime implicant that covers column 0. Trying (0,2)

One solution is F=a’c’+b’c+ab the same “cost-effective” of previous one

©2010 Cengage Learning

Petrick’s Method

Petrick’s method is a technique for determining all minimum sum-of-products solutions from a prime implicant chart.

Petrick’s method provides a more systematic way of finding all minimum solutions from a prime implicant chart than the method used previously.

Before applying Petrick’s method, all essential prime implicants and the minterms they cover should be removed from the chart.

Section 6.3 (p. 171)

©2010 Cengage Learning

First, we label the rows of the prime implicant chart P1, P2, P3, ect.

We will form a logic function, P, which is true when all of the minterms in the chart have been covered.

Let P1 be a logic variable which is true when the prime implicant in row P1 is included in the solution, P2 be a logic variable which is true when the prime implicant in row P2 is included in the solution, etc.

©2010 Cengage Learning

Section 6.3 (p. 172-173)

Table 6-5. Because column 0 has X’s in rows P1

and P2, we must choose row P1 or P2

in order to cover minterm 0.

Therefore, (P1 + P2) must be true.

P = (P1 + P2)(P1 + P3)(P2 + P4)(P3 + P5)(P4 + P6)(P5 + P6) = 1

©2010 Cengage Learning

Use X + XY = X to eliminate redundant terms, yielding:

P = (P1 + P2)(P1 + P3)(P2 + P4)(P3 + P5)(P4 + P6)(P5 + P6) = 1

P = (P1 + P2P3)(P4 + P2P6)(P5 + P3P6)

= (P1P4 + P1P2P6 + P2P3P4 + P2P3P6)(P5 + P3P6)

= P1P4P5 + P1P2P5P6 + P2P3P4P5 + P2P3P5P6 + P1P3P4P6 + P1P2P3P6 + P2P3P4P6 + P2P3P6

P = P1P4P5 + P1P2P5P6 + P2P3P4P5 + P1P3P4P6 + P2P3P6

There are two minimal solutions, each with three prime implicants.

F=a’b’+bc’+ac or a’c’+b’c+ab

上述之五個解,皆可以讓 P成立 (P=1),選擇最簡化的解 :

©2010 Cengage Learning

1. Reduce the prime implicant chart by eliminating the essential prime implicant rows and the corresponding columns.

2. Label the rows of the reduced prime implicant chart P1, P2, P3, etc.

3. Form a logic function P which is true when all columns are covered. P consists of a product of sum terms, each sum term having the form (Pi0 + Pi1 + . . . ), where Pi0, Pi1 . . . represent the rows which cover column i.

In summary, Petrick’s method is as follows:

©2010 Cengage Learning

4. Reduce P to a minimum sum of products by multiplying out and applying X + XY = X.

5. Each term in the result represents a solution, that is, a set of rows which covers all of the minterms in the table. To determine the minimum solutions (as defined in Section 5.1), find those terms which contain a minimum number of variables. Each of these terms represents a solution with a minimum number of prime implicants.

©2010 Cengage Learning

6. For each of the terms found in step 5, count the number of literals in each prime implicant and find the total number of literals. Choose the term or terms which correspond to the minimum total number of literals, and write out the corresponding sums of prime implicants.

Petrick’s method 程序繁複,但卻有系統化,可由電腦來執行程序

©2010 Cengage Learning

Simplification of Incompletely Specified Functions

Section 6.4 (p. 173)

In this section, we will show how to modify the Quine-McCluskey method in order to obtain a minimum solution when don’t-care terms are present.

©2010 Cengage Learning

F(A, B, C, D) =Σ m(2, 3, 7, 9, 11, 13) + Σ d(1, 10, 15)

The don’t-care terms are treated like

required minterms when finding the prime implicants.

• 當其可以用來合併化簡 ,才利用之。

©2010 Cengage Learning

Section 6.4 (p. 174)

The don’t-care columns are omitted when forming the prime implicant chart: 1. Chart 不列出 don’t care terms

2. 先找 Essentail

©2010 Cengage Learning

Simplification Using Map-Entered Variables(參考教材 )

Although the Quine-McCluskey method can be used with functions with a fairly large number of variables, it is not very efficient for functions that have many variables and relatively few terms.

By using map-entered variables, Karnaugh map techniques can be extended to simplify functions with more than four or five variables.

Section 6.5 (p. 174)

©2010 Cengage Learning

Figure 6-2: Simplification Using aMap-Entered Variable

We will simplify

F(A, B, C, D) = A′B′C + A′BC + A′BC′D + ABCD + (AB′C)

using a 3-variable map with D as a map-entered variable. Placing D in squares 010 and 111 means that minterms A′BC′ and ABC are present when D = 1.

To find a minimal expression for F, we will first consider D = 0.

When D = 0, F reduces to A′C.

©2010 Cengage Learning

Figure 6-2: Simplification Using aMap-Entered Variable

F(A, B, C, D) = A′B′C + A′BC + A′BC′D + ABCD + (AB′C)

Next, consider D = 1. Notice the two 1’s on the original map have been replaced with don’t cares because they have already been covered by A′C.

When D = 1, F simplifies to D(C + A′B).

©2010 Cengage Learning

Figure 6-2: Simplification Using aMap-Entered Variable

F(A, B, C, D) = A′B′C + A′BC + A′BC′D + ABCD + (AB′C)

Thus, our minimum sum-of-products for F is:

F = A′C + CD + A′BD.

©2010 Cengage Learning

Given a map with variables P1, P2, ... Entered into some of the squares, the minimum sum-of-products expression for F can be found as follows:

Find a sum-of-products expression for F of the form

F = MS0 + P1MS1 + P2MS2 + • • •

where

MS0 is the minimum sum obtained by setting P1 = P2 = • • • = 0.

MS1 is the minimum sum obtained by setting P1 = 1, Pj = 0 (j ≠ 1), and replacing all 1’s on the map with don’t-cares.

MS2 is the minimum sum obtained by setting P2 = 1, Pj = 0 (j ≠ 2), and replacing all 1’s on the map with don’t-cares.

©2010 Cengage Learning

Figure 6-1: Use of Map-Entered Variables

Next, we will simplify a 6-variable function G(A, B, C, D, E, F) using a 4-variable map with map-entered variables E and F.

©2010 Cengage Learning

The minimum sum of products for G is:

G = MS0 + EMS1 + FMS2

G = A′B′ + ACD + EA′D + FAD

Figure 6-1

©2010 Cengage Learning

HW 66.26.8