dc04 6
dc04 6
0/ Digital Circuits
Minimization of Logic Functions Using Cost Criteria Minimization Related Definitions: Implicant and Prime implicant
Implicant (in Sum-of-Products (SOP) form):
• A logic function has many algebraic expressions (see canonical forms and
• An implicant of a function F (in SOP form) is a product P that is covered by this
simplified expressions).
function, i.e., P ≤ F (See Order relation on slide 2.11).
• The purpose of simplification (minimization) is to choose the most appropriate
• Reminder: Each minterm (product) of the 1st canonical form corresponds to a
expression (with the minimum cost) from the set of all possible expressions
single 1-generating (“true”) point.
according to a cost criterion.
Therefore, the minterms are implicants of the function (m ≤ F ).
• The cost criterion may change and depend on the application.
Example:
For example, the design criteria may require
A B C F F(A, B, C)= Σm(1,3,5,6,7) : 1st canonical form
o the expression to have a minimum number of products (or sums), a minimum
0 0 0 0 = A'B'C + A'BC + AB'C + ABC' + ABC
number of literals (variables) in each product,
0 0 1 1 These products can be simplified into products with fewer
o the use of only one type of gate (such as NAND), or literals, which still cover all the 1s of the function.
0 1 0 0
o the use of only the gates that are at our disposal. 0 1 1 1 This function was simplified previously (slide 2.36):
Objectives of simplification: 1 0 0 0 F= AB + C
• Decreasing the size of the circuit 1 0 1 1 While the minterms in the canonical form cover only a single "1",
1 1 0 1 the AB product covers two 1s, and C covers four 1s.
• Decreasing power consumption (battery, cooling problem)
1 1 1 1
• Decreasing the delay (increasing the speed) (See 6.2: Propagation Delay) Note that products with fewer literals cover more 1s.
• Decreasing the cost Like minterms, the product terms AB and C are also implicants of the function F
because AB ≤ F and C ≤ F.
http://akademi.itu.edu.tr/en/buzluca/ http://akademi.itu.edu.tr/en/buzluca/
http://www.buzluca.info
2011-2024 Feza BUZLUCA 4.1 http://www.buzluca.info
2011-2024 Feza BUZLUCA 4.2
Prime implicant (in SOP form): Minimization process of a Boolean function using cost criteria:
• A prime implicant is a product (implicant) of a function (in SOP form) that
The simplification procedure consists of two steps.
cannot be simplified (i.e., it cannot be combined with another term to eliminate a
literal). 1. Finding the complete set of all prime implicants.
• A prime implicant (PI) of F is an implicant that is minimal - that is, the removal of • We will find all products that are covered by the function and cannot be
any literal from PI results in a non-implicant for F. simplified (prime implicants).
• To find prime implicants, we will use two different methods:
Example:
a) Karnaugh maps
F(A, B, C)= Σm(1,3,5,6,7) : 1st canonical form
= A'B'C + A'BC + AB'C + ABC' + ABC b) Quine-McCluskey (Tabular) method
= AB + C 2. Selection of the “most appropriate” (lowest-cost) subset of the prime
• For the given function above, the minterms are implicants but not prime implicants. implicants that covers all the 1s of the function.
For example, ABC' and ABC are not prime implicants because they can be combined • All prime implicants may not be necessary to cover all 1s of the function.
to form AB, which includes fewer literals and covers more 1s.
• We will calculate the cost of each prime implicant using the given cost
If we remove C from ABC, the new product AB is still an implicant of F (AB ≤ F). criteria.
• AB is a prime implicant because it cannot be reduced to A or B. • Using the prime implicant chart, we will select a subset of prime implicants
If we remove A or B from AB, the new expression (A or B) is not an implicant of F with minimum cost that covers the function.
because the function does not have 1s in all the places A and B would require (A ≰
• The sum of the selected prime implicants will be the lowest-cost expression
, B ≰ ).
of the function in POS form.
• C is also a prime implicant of the function F.
http://akademi.itu.edu.tr/en/buzluca/ http://akademi.itu.edu.tr/en/buzluca/
http://www.buzluca.info
2011-2024 Feza BUZLUCA 4.3 http://www.buzluca.info
2011-2024 Feza BUZLUCA 4.4
Minimization (Simplification) Step 1: Finding All Prime Implicants Combining minterms to obtain products
• Using Boolean algebra, we can combine minterms to obtain products that have that have fewer variables and cover more 1s
fewer variables and cover more 1s. Visualization of the process on Visualization of the process on the
• It is hard to perform these simplifications manually, especially for complicated the Boolean cube: Karnaugh map:
functions (with many variables). Therefore, a computer program can be used. F
B
A B F 0 1
A
A practical procedure (without using the logical expression of the function): 0 0 1 01 11
0 1 0
• Investigate the 1- generating input combinations (output = 1) in the truth table,
0 1 0 B
• Combine 1- generating input combinations with one or more constant variables 1 1 0
(Hamming distance = 1). 1 0 1 10
00
• Retain the constant variables and remove the rest (variables with changing values). 1 1 0 A
Example: Algebraic combining: F = A'B'+AB' = (A'+A)B' = B' Karnaugh maps allow easier grouping
Two points (having 0 dimensions) are
A B F combined to obtain a line (having 1 dimension). of terms.
These input B is constant. For both lines, B=0.
0 0 1 This line represents B=0 (B is constant at Neighboring 1s can be grouped
combinations Hence, B will be retained in the new product.
zero, and A changes) which is the complement together using the adjacency
are adjacent. 0 1 0
of B, namely, B'. property.
Hamming
1 0 1
distance =1 In the grouped column above, B=0 is
1 1 0 fixed, and A is changing.
The value of A is changing.
Remember algebraic combining:
Hence, it will be removed from the new product. This column represents the
F = A'B'+AB'= (A'+A)B' = B' complement of B, namely, B'.
Since B = 0, the new product will be B' .
http://akademi.itu.edu.tr/en/buzluca/ http://akademi.itu.edu.tr/en/buzluca/
http://www.buzluca.info
2011-2024 Feza BUZLUCA 4.5 http://www.buzluca.info
2011-2024 Feza BUZLUCA 4.6
Digital Circuits License: https://creativecommons.org/licenses/by-nc-nd/4.0/ Digital Circuits
If more than one variable is fixed, each one appears in the product that is More than 2 points can also be combined to establish new groups.
the result of their grouping.
For example: F(A,B,C) = ∪1(4,5,6,7)
For example:
011 111
A B C F
110
0 0 0 0 A=1 , C=1 are constant. B is changing. 010 A=1 is constant. B and C are changing.
0 0 1 0 The product AC is formed as the result of this grouping. 001 This face of the cube (a plane) represents A.
B C 101
0 1 0 0 Algebraically: AB'C + ABC = A(B'+B)C = AC Algebraically: AB'C' + AB'C + ABC' + ABC
0 1 1 0 000 A 100 = AB'+AB
1 0 0 0 A=1 , B=1 are constant. C is changing. =A
1 0 1 1 The product AB is formed as the result of this grouping.
1 1 0 1 Algebraically: ABC' + ABC = AB(C'+C) = AB
Using a Karnaugh map:
1 1 1 1
F BC B
F BC B
011 111 A 00 01 11 10
AB A 00 01 11 10
110 0 0 0 0 0
010 0 0 0 0 0
AC
A 1 0 1 1 1
B C 001 A 1 1 1 1 1 A=1 is constant. B and C are changing.
101
C
000 100 C
A AC AB
http://akademi.itu.edu.tr/en/buzluca/ http://akademi.itu.edu.tr/en/buzluca/
http://www.buzluca.info
2011-2024 Feza BUZLUCA 4.7 http://www.buzluca.info
2011-2024 Feza BUZLUCA 4.8
Finding Prime Implicants Using Karnaugh Maps (Diagrams): Example: Find the prime implicants of the following function.
F(A,B,C,D) = ∪1(0,2,5,8,9,10,11,12,13,14,15)
• In Karnaugh maps, only a single variable changes between two neighboring cells;
the rest remain constant. F CD C
00 01 11 10
• To find prime implicants, true points (1s) in the neighboring squares (cells) can be AB
clustered into groups that contain 2, 4, 8, …, 2n cells.
00 1 0 0 1 Prime implicants: A , B'D' , BC'D
• Below, areas where the variable values stay constant are shown on the Karnaugh 01 0 1 0 0
maps for functions with 3 and 4 variables. B
11 1 1 1 1
B Karnaugh maps for the same A A
BC AB
A 00 01 11 10 function can be drawn in different C 00 01 11 10 10 1 1 1 1
0 ways by changing the order of 0
0 2 6 4 D
0 1 3 2 variables (compare the diagrams Method of finding prime implicants (grouping 1s):
A 1 on the left & right). C 1
4 5 7 6 C 1 3 7 5 • The groups must be rectangular and must have an area that is a power of two
CD (i.e., 1, 2, 4, 8…).
00 01 11 10 B
C AB • "True” points (1s) are placed into the largest groups possible.
00 0 1 3 2 • Two points within a larger group (or groups) cannot be combined into a smaller
01 4 subgroup.
5 7 6 B
For example, two points within different 4-point groups cannot be combined
11 12 13 15 14 to form another 2-point group. It is possible to create a new 4-point group.
A
10 8 • However, if a point is not currently in any groups (such as 0101 above), that point
9 11 10
can be grouped with an already grouped point.
D
http://akademi.itu.edu.tr/en/buzluca/ http://akademi.itu.edu.tr/en/buzluca/
http://www.buzluca.info
2011-2024 Feza BUZLUCA 4.9 http://www.buzluca.info
2011-2024 Feza BUZLUCA 4.10
Distinguished Points and Essential Prime Implicants: Example: Finding the set of all prime implicants, distinguished points, and
• Some true points (1s) of a function may be covered only by a single prime essential prime implicants.
implicant. These 1s are called distinguished points. C
F CD
00 01 11 10
Set of all prime implicants:
• The prime implicant that covers a distinguished point is an essential prime AB
implicant. 00 1 1 1 CD , AB , A'C , BC , AD , A'D' , BD'
Essential prime implicants must be included in the minimal covering sum.
01 1 1 1
Otherwise, covering all true points of a function is impossible. B Distinguished points Essential prime implicants
Example: Set of all prime implicants: 11 1 1 1 1 0000 A'D'
A
F CD C 1001 AD
00 01 11 10 C'D , BC' , AC' , BD' ,A'CD' , AB'D 10 1 1
AB
00 1 1 D
Distinguished points Essential prime implicants Here, essential prime implicants do not cover all "true " points (1s) of the function.
01 1 1 1 0001 C'D
B We must decide which prime implicants to include to cover the remaining 1s.
11 1 1 1
0010 A'CD' For example, to cover 0011, we can include A'C or CD.
A 1000 AC'
1 1 1 To cover 1100, we can include AB or BD'.
10 1110 BD'
1011 AB'D For this function, there are multiple possible minimal covering sums.
D
Here, essential prime implicants cover all true points of the function. Only two of them are given below (alternative solutions exist):
̅
This is a special case. The minimum cost solution is:
̅ ̅
http://akademi.itu.edu.tr/en/buzluca/ http://akademi.itu.edu.tr/en/buzluca/
http://www.buzluca.info
2011-2024 Feza BUZLUCA 4.13 http://www.buzluca.info
2011-2024 Feza BUZLUCA 4.14
Example: Find the set of all prime implicants and form the prime implicant chart Example (cont'd):
for the following function. Set of all prime implicants:
f(x1, x2, x3, x4)=Σm(2, 4, 6, 8, 9, 10, 12, 13, 15) x 1 x 3' x 2 x 3' x 4' x1'x2 x4' x1 x2 x4 x1'x3 x4' x 2' x 3 x 4' x 1 x 2' x 4'
Cost criteria: 2 units for each variable and 1 unit for each complement sign.
Symbols: A B C D E F G
Costs: 5 8 8 6 8 8 8
f x3x4 x3 Covered points: 8,9,12,13 4,12 4, 6 13, 15 2, 6 2, 10 8, 10
x1x2 00 01 11 10
00 1 True points (1s) of the function
01 1 1
x2 X X X X 5
11 1 1 1 X X 8
x1
X X 8
10 1 1 1
X X 6
x4 X X 8
Set of all prime implicants:
X X 8
x 1 x 3' x 2 x 3' x 4' x1'x2 x4' x1 x2 x4 x1'x3 x4' x 2' x 3 x 4' x 1 x 2' x 4' X X 8
Symbols: A B C D E F G
Cost: 5 8 8 6 8 8 8
Covered points: 8,9,12,13 4,12 4, 6 13, 15 2, 6 2, 10 8, 10
http://akademi.itu.edu.tr/en/buzluca/ http://akademi.itu.edu.tr/en/buzluca/
http://www.buzluca.info
2011-2024 Feza BUZLUCA 4.17 http://www.buzluca.info
2011-2024 Feza BUZLUCA 4.18
Digital Circuits License: https://creativecommons.org/licenses/by-nc-nd/4.0/ Digital Circuits
Simplification of the Prime Implicant Chart: Example: Simplification of prime implicant chart of the following function
1. Distinguished points are determined. If a column contains only one X, then that f(x1, x2, x3, x4)=Σm(2, 4, 6, 8, 9, 10, 12, 13, 15)
is a distinguished point.
True points of the function
The prime implicant that covers the distinguished point (essential prime
implicant) is necessarily selected.
The row of this essential prime implicant and columns that are covered by this √ x 1 x 3' X X X X 5
x 2 x 3' x 4' X X 8
implicant are removed from the chart (crossed out).
C x1'x2 x4' X X 8
2. If there is an X in the ith row for each X in the jth row, i X √ x1 x2 x4
X 4 X X 6
then row i covers row j. In other words, all points covered j X 5 x1'x3 x4' X X 8
by row j are also covered by row i.
x 2' x 3 x 4' X X 8
If row i covers row j AND the cost at row i is less than or equal to the cost x 1 x 2' x 4' X X 8
at row j, then row j (covered row) is removed from the chart.
3. If a column covers another column, the covering column (with more X's) is 1. step:
removed from the chart. • In this chart, 9 and 15 are the distinguished points.
i X X • As A and D are essential prime implicants, they must be included in the minimal
j X X covering sum.
k X • These products are marked to show their inclusion in the final set.
• The rows and columns that they cover are crossed out (removed from the
These rules are applied successively until all true points are covered with the
chart).
lowest cost.
http://akademi.itu.edu.tr/en/buzluca/ http://akademi.itu.edu.tr/en/buzluca/
http://www.buzluca.info
2011-2024 Feza BUZLUCA 4.19 http://www.buzluca.info
2011-2024 Feza BUZLUCA 4.20
Minimization of Incompletely Specified Functions Example: Implement the following incomplete function with the lowest possible cost.
Reminder: In incompletely specified functions, the function result is f(x1, x2, x3, x4)=∪1(2, 4, 8, 9, 13, 15 ) + ∪Φ(6,10,12)
undetermined (we do not care about it) for some input combinations.
Cost criteria: 2 units for each variable and 1 unit for each complement.
These combinations may never occur in the circuit, or the designer prohibits them.
Example: BCD incrementer circuit on slide 2.26 Finding the prime implicants:
Selection of Unspecified (Don't Care) Values (Φ): f x3x4 x3
For the don't care terms (Φ), it is desirable to choose values (0 or 1), which will x1x2 00 01 11 10
help simplify the function (to find the expression with the lowest cost). 00 1 When we build the set of all prime implicants
01 1 Φ of a function in SOP form, we assign 1 to Φ’s.
• In searching for the set of all prime implicants of a function in SOP form, we
will treat the don't care terms as if they were required minterms (Φ = 1). x2
11 Φ 1 1
This way, they can be combined with other minterms to eliminate as many x1
literals as possible (larger groups in the Karnaugh map). 10 1 1 Φ
x4
• When forming the prime implicant chart, the "don’t cares" are not listed at the Set of all prime implicants:
top (Φ = 0) because there is no need to cover the points with unspecified values.
This way, when the prime implicant chart is solved, the selected prime implicants x 1 x 3' x 2 x 3' x 4' x1'x2 x4' x1 x2 x4 x1'x3 x4' x 2' x 3 x 4' x 1 x 2' x 4'
will cover all of the required minterms (1-generating points).
Symbols: A B C D E F G
However, some of the "don’t cares" are not included in the final solution if they Costs: 5 8 8 6 8 8 8
are not covered by the selected implicants. Points covered: 8,9,13 4 4 13,15 2 2 8
http://akademi.itu.edu.tr/en/buzluca/ http://akademi.itu.edu.tr/en/buzluca/
http://www.buzluca.info
2011-2024 Feza BUZLUCA 4.23 http://www.buzluca.info
2011-2024 Feza BUZLUCA 4.24
Digital Circuits License: https://creativecommons.org/licenses/by-nc-nd/4.0/ Digital Circuits
Forming the prime implicant chart: Simplifying the prime implicant chart:
Set of all prime implicants: True points of the function
x 1 x 3' x 2 x 3' x 4' x1'x2 x4' x1 x2 x4 x1'x3 x4' x 2' x 3 x 4' x 1 x 2' x 4'
Symbols: A B C D E F G √ X X X 5
Costs: 5 8 8 6 8 8 8 X 8
X 8
Points covered: 8,9,13 4 4 13,15 2 2 8
√ X X 6
X 8
True points (1s) of the function X 8
When forming the prime implicant
X 8
chart of a function in SOP form,
X X X 5 we assign 0 to Φ’s.
X 8 Step 1: In this chart, points 9 and 15 are distinguished points.
X 8 • As A and D are the essential prime implicants, they are selected.
X X 6 As there is no need to cover the
points with unspecified values (Φ), • A and D are marked to show that they will be in the final set of prime
X 8 implicants.
these points are not placed into the
X 8 prime implicant chart. • The rows and columns covered by A and D are removed.
X 8
http://akademi.itu.edu.tr/en/buzluca/ http://akademi.itu.edu.tr/en/buzluca/
http://www.buzluca.info
2011-2024 Feza BUZLUCA 4.25 http://www.buzluca.info
2011-2024 Feza BUZLUCA 4.26
http://akademi.itu.edu.tr/en/buzluca/ http://akademi.itu.edu.tr/en/buzluca/
http://www.buzluca.info
2011-2024 Feza BUZLUCA 4.27 http://www.buzluca.info
2011-2024 Feza BUZLUCA 4.28
Minimization of General Functions Finding the Set of All Prime Implicants Using
the Quine-McCluskey (Tabulation) Method
Remark: General functions have more than one output.
• The Karnaugh map method is an effective way to simplify logic functions that
have a small number of variables.
x1 x2 x3 y1 y2
• When the number of variables is large (more than four) or if several functions
must be simplified, the use of a digital computer is desirable.
000 1 1 x1 y1
001 1 Φ x2 f • The Quine-McCluskey (tabulation) method provides a systematic procedure
010 0 0 x3 y2 that can be readily programmed for a digital computer.
011 Φ 0 Quine-McCluskey (Tabulation) Method:
100 1 Φ • Remember: to find the set of all prime implicants, true points (minterms) of the
101 0 1 y1= f1(x1, x2, x3) function are combined (grouped). Adjacent minterms where single variable
110 0 1 changes are grouped together (See the figure on slide 4.5).
111 Φ 0 y2= f2(x1, x2, x3)
• In the tabulation method:
o Each minterm (corresponding to 1-generating input combinations) is compared
• During the simplification of general functions, the set of prime implicants for to all other minterms.
each output is found independently, and prime implicants are selected from
o If a single variable (input) changes between two minterms, they are combined.
these sets.
o The variable with the changing value is removed, and a new term is obtained.
• An important point is to select the common prime implicants of both outputs.
o This process is repeated until no further groups can be formed.
• The minimization of general functions is outside the scope of this course.
o Terms that cannot be grouped are the prime implicants.
http://akademi.itu.edu.tr/en/buzluca/ http://akademi.itu.edu.tr/en/buzluca/
http://www.buzluca.info
2011-2024 Feza BUZLUCA 4.29 http://www.buzluca.info
2011-2024 Feza BUZLUCA 4.30
Digital Circuits License: https://creativecommons.org/licenses/by-nc-nd/4.0/ Digital Circuits
Willard Van Orman Quine (1908-2000) Philosophy, logic Example 1: Find the set of all prime implicants of the following function using
Edward J. McCluskey (1929-2016) Electrical engineer Quine-McCluskey method.
Method (Algorithm):
f(x1, x2, x3, x4)= Σm(0, 1, 2, 8, 10, 11, 14, 15 )
1st Step: Finding the set of all prime implicants (Tabulation method):
• Consider 1-generating input combinations (true points) in the truth table.
1-generating (true) input combinations Groups with 2 points Groups with 4 points
• Cluster the 1-generating input combinations depending on the number of 1s
included in the combination. For example, 1011 has three 1s. Num. x1 x2 x3 x4 Num. x1 x2 x3 x4 Num. x1 x2 x3 x4
This will shorten the running time of the algorithm. 0 0 0 0 0 √ 0,1 0 0 0 - 0,2,8,10 - 0 - 0
• Compare combinations that are in the neighboring clusters. Group the 0,2 0 0 - 0 √
1 0 0 0 1 √ 0,8,2,10 - 0 - 0
combinations where a single variable changes value. 0,8 - 0 0 0 √
2 0 0 1 0 √
• The variable with the changing value will be eliminated. √ 10,11,14,15 1 - 1 -
8 1 0 0 0 √ 2,10 - 0 1 0
• Mark the combinations that are grouped. 8,10 1 0 - 0 √ 10,14,11,15 1 - 1 -
• Repeat the grouping on the newly formed combinations until no further groups 10 1 0 1 0 √
10,11 1 0 1 - √
can be formed. 11 1 0 1 1 √ No need to rewrite the
10,14 1 - 1 0 √
• Combinations that are not grouped (items that are not marked) form the set of 14 1 1 1 0 √ same items.
all prime implicants. 11,15 1 - 1 1 √
15 1 1 1 1 √ 14,15 1 1 1 - √
2nd Step: Finding the minimal covering sum
The prime implicant chart is used to select the subset of prime implicants with Set of all prime implicants (Not marked): x1' x2' x3' , x2' x4' , x1 x3
minimum cost that covers the function (minimal covering sum) (See 4.16).
To find the minimal covering sum with the lowest cost, the prime implicant chart is used.
http://akademi.itu.edu.tr/en/buzluca/ http://akademi.itu.edu.tr/en/buzluca/
http://www.buzluca.info
2011-2024 Feza BUZLUCA 4.31 http://www.buzluca.info
2011-2024 Feza BUZLUCA 4.32
Example 2: Find the set of all prime implicants of the following function using Minimization of functions in Product-of-Sums (POS) form
Quine-McCluskey method. • The principle of duality allows us to use the same techniques to obtain the
f(x1, x2, x3, x4)= Σm(3, 4, 7, 8, 9, 12, 13) minimum-cost expression for functions in the product-of-sums (POS) form.
1-generating (true) input combinations • An implicant of a function F (in POS form) is a sum S that covers this function
group based on the number of 1s F ≤ S (See "Order relation" on slide 2.11).
Num. x1 x2 x3 x4 Num. x1 x2 x3 x4 Num. x1 x2 x3 x4 • Reminder: Each maxterm (sum) in the 2nd canonical form corresponds to a
single 0-generating point. The maxterms are implicants of the function (F ≤ M ).
4 0 1 0 0 √ 4,12 - 1 0 0 8,9,12,13 1 - 0 -
8 1 0 0 0 √ 8,9 1 0 0 - √ Prime implicant (POS form):
8,12,9,13 1 - 0 -
3 0 0 1 1 √ 8,12 1 - 0 0 √ A prime implicant is a sum term of a function (POS form) that cannot be simplified.
9 1 0 0 1 √ 3,7 0 - 1 1 A prime implicant (PI) of F is an implicant that is minimal - that is, the removal of
No need to rewrite
12 1 1 0 0 √ 9,13 1 - 0 1 √ the same items. any literal from PI results in a non-implicant for F (Willard Van Orman Quine).
7 0 1 1 1 √ 12,13 1 1 0 - √ Example: Find the prime implicants of the following F CD C
13 1 1 0 1 √ function in POS form (same example as on slide 4.10). AB
00 01 11 10
00 1 0 0 1
Note: F(A,B,C,D) = ΠΜ(1,3,4,6,7)
• Here, there are no input combinations containing no 1s.
• We start with combinations containing a single 1 (4 and 8). • We group zeros. 01 0 1 0 0
• Also, note that we have 3 following 8 or 7 following 12 because we need to group based on • We use complements of the input variables. B
the number of 1s, not on the increasing order of combinations. 11 1 1 1 1
A
Prime implicants in POS form: 10 1 1 1 1
Set of all prime implicants (Not marked): x2 x3 ' x 4 ' , x 1 ' x 3 x4 , x 1 x3 ' A+B+D' , A+B'+C' , A+B'+D , A+C'+D' D
http://akademi.itu.edu.tr/en/buzluca/ http://akademi.itu.edu.tr/en/buzluca/
http://www.buzluca.info
2011-2024 Feza BUZLUCA 4.33 http://www.buzluca.info
2011-2024 Feza BUZLUCA 4.34
Example: Find the prime implicants of the following function in POS form. Example: Implement the following incompletely specified function in POS form with
(same example as on slide 4.14) the lowest possible cost (same example as on slide 4.24).
For some functions, it is easier to work on 0-generating input combinations than on f(x1, x2, x3, x4)=∪0(0, 1, 3, 5, 7, 11, 14) + ∪Φ(6,10,12)
1-generating combinations. Cost criteria: 2 units for each variable and 1 unit for each complement.
F CD C
00 01 11 10 Set of all prime implicants: Finding the prime implicants:
AB x3
00 1 0 1 1 A+C+D' , A'+B+D f x3x4
x1x2 00 01 11 10
• Since A+C+D' and A'+B+D are essential prime
01 1 0 1 1
implicants, we must take them.
00 0 0 0 When we are finding the set of all prime
B implicants of a function in POS form, we
11 1 1 1 1 • By including these prime implicants, we cover 01 0 0 Φ
A
all 0-generating points.
assign 0 to Φ’s.
x2
10 0 1 1 0 11 Φ 0
• The expression for F in POS form: x1
D
( )( ̅ ) 10 0 Φ
Conversions between forms: x4
• We can use axioms and theorems of Boolean algebra on this expression (POS) to Set of all prime implicants:
reach expressions in SOP form given on slide 4.14.
̅ x1+x4' x1 +x2+x3 x1+x2'+x3' x2'+x3'+x4 x1'+x2'+x4 x2 +x3'+x4' x1' +x3'+x4 x1'+x2+x3'
̅ ̅ A B C D E F G H
• Note that all these expressions have the same truth table. They generate the Cost: 5 6 8 8 8 8 8 8
same output value given the same input values. 1,3,5,7 0,1 7 14 14 3,11 14 11
http://akademi.itu.edu.tr/en/buzluca/ http://akademi.itu.edu.tr/en/buzluca/
http://www.buzluca.info
2011-2024 Feza BUZLUCA 4.35 http://www.buzluca.info
2011-2024 Feza BUZLUCA 4.36
Digital Circuits License: https://creativecommons.org/licenses/by-nc-nd/4.0/ Digital Circuits
Example (contd): Forming the prime implicant chart: Simplifying the prime implicant chart (contd):
Set of all prime implicants: Step 2:
x1+x4' x1+x2+x3 x1+x2'+x3' x2'+x3'+x4 x1'+x2'+x4 x2 +x3'+x4' x1' +x3'+x4 x1'+x2+x3' • D, E, and G cover the same point (14) and have the same cost.
11 14 Cost
Therefore, it is not possible to choose between them; any one
A B C D E F G H D x 8
of D, E, and G can be selected.
Cost: 5 6 8 8 8 8 8 8 E x 8
F x 8 • The same is true for prime implicants F and H. They cover 11.
1,3,5,7 0,1 7 14 14 3,11 14 11
G x 8 • In the end, the same function can be implemented using any of
False ("0") points of the function
H x 8 the following expressions, which have the same (lowest) cost.
When we are forming the
√ X X X X 5 prime implicant chart for f A ∙ B ∙ D ∙ F (x1 x4')(x1 x2 x3)(x2' x3' x4)(x2 x3' x4')
√ X X 6 a function in POS form, f A ∙ B ∙ D ∙ H (x1 x4')(x1 x2 x3)(x2' x3' x4)(x1' x2 x3')
8
X
we assign 1 to Φ’s. f A ∙ B ∙ E ∙ F (x1 x4')(x1 x2 x3)(x1' x2' x4)(x2 x3' x4')
X 8
X 8 f A ∙ B ∙ E ∙ H (x1 x4')(x1 x2 x3)(x1' x2' x4)(x1' x2 x3')
As there is no need to cover the points
X X 8 f A ∙ B ∙ G ∙ F (x1 x4')(x1 x2 x3)(x1' x3' x4)(x2 x3' x4')
with unspecified values (Φ), these points
X 8 are not listed in the prime implicant chart. f A ∙ B ∙ G ∙ H (x1 x4')(x1 x2 x3)(x1' x3' x4)(x1' x2 x3')
X 8
All designs have the same cost (27).
Step 1: Since this function is the same as the one given on slide 4.24, we can use axioms
As A and B are essential prime implicants, they are selected. The rows and and theorems of Boolean algebra on any of these expressions to reach the
columns covered by A and B are crossed out (removed). expression in the SOP form given on slide 4.27.
http://akademi.itu.edu.tr/en/buzluca/ http://akademi.itu.edu.tr/en/buzluca/
http://www.buzluca.info
2011-2024 Feza BUZLUCA 4.37 http://www.buzluca.info
2011-2024 Feza BUZLUCA 4.38