Download presentation

Presentation is loading. Please wait.

Published byFrederica Chase Modified about 1 year ago

1
CHAPTER 3: PRINCIPLES OF COMBINATIONAL LOGIC (Sections 3.1 – 3.5)

2
3.1 DEFINITION OF COMBINATIONAL LOGIC Logic circuits without feedback from output to the input, constructed from a functionally complete gate set, are said to be combinational. Inputs Outputs Combinational Logic Functions · · · · · ·

3
3.1.1 PROBLEM STATEMENTS TO TRUTH TABLES E.g : Conveyor system(P85, Ex. 3.1) E.g : Conveyor system(P85, Ex. 3.1) M=a’bms+ab’ms+abms

4
3.1.1 PROBLEM STATEMENTS TO TRUTH TABLES E.g. A NASA system(P87, Ex. 3.2) E.g. A NASA system(P87, Ex. 3.2) C1 C2 C3

5
3.1.1 PROBLEM STATEMENTS TO TRUTH TABLES E.g. Conveyor system(P88, ex. 3.4) E.g. Conveyor system(P88, ex. 3.4) S3 S1 S2 m3 m1 m2m4

6
The process of converting a verbal problem statement into a truth table : The process of converting a verbal problem statement into a truth table : Determine the input variables and output variables that are involved Assign mnemonic or letter or number symbols to each variable determine the size of the truth table; how many input combinations exist: 2 x =y where x=number of input variables and y=number of combinations. Construct a truth table containing all of the input variable combinations By careful reading of the problem statement determine the combinations of inputs that cause a given output to be true 3.1.1 PROBLEM STATEMENTS TO TRUTH TABLES

7
Exe: Design a truth table to indicate a majority of three inputs is true Exe: Design a truth table to indicate a majority of three inputs is true 3.1.1 PROBLEM STATEMENTS TO TRUTH TABLES I 3 I 2 I 1 O 1 0 0 0 0 0 0 1 0 0 1 0 0 0 1 1 1 1 0 0 0 1 0 1 1 1 1 0 1 1 1 1 1

8
3.1.2 Deriving Switching Equations Definitions Definitions Product term: literals connected by Sum term: literals connected by + Minterm: a product term in which all the variables appear exactly once, either complemented or uncomplemented Maxterm: a sum term in which all the variables appear exactly once, either complemented or uncomplemented

9
Minterm Represents exactly one combination in the truth table. Represents exactly one combination in the truth table. Denoted by m j, where j is the decimal equivalent of the minterm ’ s corresponding binary combination (b j ). Denoted by m j, where j is the decimal equivalent of the minterm ’ s corresponding binary combination (b j ). A variable in m j is complemented if its value in b j is 0, otherwise is uncomplemented. A variable in m j is complemented if its value in b j is 0, otherwise is uncomplemented. M(a,b,m,s)=a’bms+ab’ms+abms M(a,b,m,s)=a’bms+ab’ms+abms (m 7 ) (m 11 ) (m 15 ) (m 7 ) (m 11 ) (m 15 )

10
Maxterm Represents exactly one combination in the truth table. Represents exactly one combination in the truth table. Denoted by M j, where j is the decimal equivalent of the maxterm ’ s corresponding binary combination (b j ). Denoted by M j, where j is the decimal equivalent of the maxterm ’ s corresponding binary combination (b j ). A variable in M j is complemented if its value in b j is 1, otherwise is uncomplemented. A variable in M j is complemented if its value in b j is 1, otherwise is uncomplemented. F(a,b,c)=(a’+b+c’)(a+b+c’)(a+b’+c’) F(a,b,c)=(a’+b+c’)(a+b+c’)(a+b’+c’) 101 001 011 101 001 011 M 5 M 1 M 3 M 5 M 1 M 3

11
Truth Table notation for Minterms and Maxterms 3 variables x,y,z (order is fixed)

12
3.2 Canonical( 规范 ) Forms Any Boolean function F( ) can be expressed as a unique sum of minterms and a unique product of maxterms (under a fixed variable ordering). Any Boolean function F( ) can be expressed as a unique sum of minterms and a unique product of maxterms (under a fixed variable ordering). every function F() has two canonical forms: every function F() has two canonical forms: Canonical Sum-Of-Products (sum of minterms) Canonical Product-Of-Sums (product of maxterms)

13
Expand non-canonical terms by inserting equivalent of 1 in each missing variable x: (x + x ’ ) = 1 Expand non-canonical terms by inserting equivalent of 1 in each missing variable x: (x + x ’ ) = 1 Remove duplicate minterms Remove duplicate minterms f 1 (a,b,c) = a ’ b ’ c + bc ’ + ac ’ = a ’ b ’ c + (a+a ’ )bc ’ + a(b+b ’ )c ’ = a ’ b ’ c + abc ’ + a ’ bc ’ + abc ’ + ab ’ c ’ = a ’ b ’ c + abc ’ + a ’ bc + ab ’ c ’ f 1 (a,b,c) = a ’ b ’ c + bc ’ + ac ’ = a ’ b ’ c + (a+a ’ )bc ’ + a(b+b ’ )c ’ = a ’ b ’ c + abc ’ + a ’ bc ’ + abc ’ + ab ’ c ’ = a ’ b ’ c + abc ’ + a ’ bc + ab ’ c ’ Convert switching equations to canonical form

14
SOP SOP E.g. P=f(a,b,c)=ab’+ac’+bc =ab’(c+c’)+ac’ (b+b’)+bc(a+a’) =ab’c+ab’c’+abc’+ab’c’+abc+a’bc=ab’c+ab’c’+abc’+abc+a’bc

15
Expand noncanonical terms by adding 0 in terms of missing variables (e.g., xx ’ = 0) and using the distributive law Expand noncanonical terms by adding 0 in terms of missing variables (e.g., xx ’ = 0) and using the distributive law Remove duplicate maxterms Remove duplicate maxterms f 1 (a,b,c) = (a+b+c) (b ’ +c ’ ) (a ’ +c ’ ) = (a+b+c) (aa ’ +b ’ +c ’ ) (a ’ +bb ’ +c ’ ) = (a+b+c) (a+b ’ +c ’ ) (a ’ +b ’ +c ’ ) (a ’ +b+c ’ ) (a ’ +b ’ +c ’ ) = (a+b+c) (a+b ’ +c ’ ) (a ’ +b ’ +c ’ ) (a ’ +b+c ’ ) f 1 (a,b,c) = (a+b+c) (b ’ +c ’ ) (a ’ +c ’ ) = (a+b+c) (aa ’ +b ’ +c ’ ) (a ’ +bb ’ +c ’ ) = (a+b+c) (a+b ’ +c ’ ) (a ’ +b ’ +c ’ ) (a ’ +b+c ’ ) (a ’ +b ’ +c ’ ) = (a+b+c) (a+b ’ +c ’ ) (a ’ +b ’ +c ’ ) (a ’ +b+c ’ ) Convert switching equations to canonical form

16
POS POS E.g. T=f(a,b,c)=(a+b’)(b’+c) =(a+b’+cc’)(b’+c+aa’) =(a+b’+c) (a+b’+c’)(a+b’+c)(a’+b’+c) =(a+b’+c) (a+b’+c’)(a’+b’+c)

17
Exe: Exe:P=f(w,x,y,z)=w’x+yz’T=f(a,b,c,d)=(a+b’+c)(a’+d) Convert switching equations to canonical form Ans: Ans: P=f(w,x,y,z)=wxyz’+wx’yz’+w’xyz+w’xyz’+w’xy’z +w’xy’z’+w’x’yz’ T=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)

18
3.3 GENERATION OF SWITCHING EQUATIONS FROM TRUTH TABLES Canonical Sum-Of-Products: The minterms included are those m j such that F( ) = 1 in row j of the truth table for F( ). Canonical Sum-Of-Products: The minterms included are those m j such that F( ) = 1 in row j of the truth table for F( ). Canonical Product-Of-Sums: The maxterms included are those M j such that F( ) = 0 in row j of the truth table for F( ). Canonical Product-Of-Sums: The maxterms included are those M j such that F( ) = 0 in row j of the truth table for F( ).

19
Example Truth table for f 1 (a,b,c) at right Truth table for f 1 (a,b,c) at right The canonical sum-of-products form for f 1 is f 1 (a,b,c) = m 1 + m 2 + m 4 + m 6 = a’b’c + a’bc’ + ab’c’ + abc’ The canonical sum-of-products form for f 1 is f 1 (a,b,c) = m 1 + m 2 + m 4 + m 6 = a’b’c + a’bc’ + ab’c’ + abc’ The canonical product-of-sums form for f 1 is f 1 (a,b,c) = M 0 M 3 M 5 M 7 = (a+b+c)(a+b’+c’) (a’+b+c’)(a’+b’+c’). The canonical product-of-sums form for f 1 is f 1 (a,b,c) = M 0 M 3 M 5 M 7 = (a+b+c)(a+b’+c’) (a’+b+c’)(a’+b’+c’). Observe that: m j = M j ’ Observe that: m j = M j ’ 0111 1011 0101 1001 0110 1010 1100 0000 f1f1f1f1cba

20
Shorthand: ∑ and ∏ f 1 (a,b,c) = ∑ m(1,2,4,6), where ∑ indicates that this is a sum-of-products form, and m(1,2,4,6) indicates that the minterms to be included are m 1, m 2, m 4, and m 6. f 1 (a,b,c) = ∑ m(1,2,4,6), where ∑ indicates that this is a sum-of-products form, and m(1,2,4,6) indicates that the minterms to be included are m 1, m 2, m 4, and m 6. f 1 (a,b,c) = ∏ M(0,3,5,7), where ∏ indicates that this is a product-of-sums form, and M(0,3,5,7) indicates that the maxterms to be included are M 0, M 3, M 5, and M 7. f 1 (a,b,c) = ∏ M(0,3,5,7), where ∏ indicates that this is a product-of-sums form, and M(0,3,5,7) indicates that the maxterms to be included are M 0, M 3, M 5, and M 7. ∑ m(1,2,4,6) = ∏ M(0,3,5,7) = f 1 (a,b,c) ∑ m(1,2,4,6) = ∏ M(0,3,5,7) = f 1 (a,b,c)

21
Conversion Between Canonical Forms Replace ∑ with ∏ (or vice versa) and replace those j ’ s that appeared in the original form with those that do not. Replace ∑ with ∏ (or vice versa) and replace those j ’ s that appeared in the original form with those that do not. Example: f 1 (a,b,c)= a ’ b ’ c + a ’ bc ’ + ab ’ c ’ + abc ’ = m 1 + m 2 + m 4 + m 6 = ∑ (1,2,4,6) = ∏ (0,3,5,7) = (a+b+c) (a+b ’ +c ’ ) (a ’ +b+c ’ ) (a ’ +b ’ +c ’ ) Example: f 1 (a,b,c)= a ’ b ’ c + a ’ bc ’ + ab ’ c ’ + abc ’ = m 1 + m 2 + m 4 + m 6 = ∑ (1,2,4,6) = ∏ (0,3,5,7) = (a+b+c) (a+b ’ +c ’ ) (a ’ +b+c ’ ) (a ’ +b ’ +c ’ )

22
Karnaugh Maps Why Karnaugh maps ？ Why Karnaugh maps ？ to simplify boolean equations Karnaugh maps (K-maps) are graphical representations of boolean functions. Karnaugh maps (K-maps) are graphical representations of boolean functions. One map cell corresponds to a row in the truth table. One map cell corresponds to a row in the truth table. one map cell corresponds to a minterm or a maxterm in the boolean expression one map cell corresponds to a minterm or a maxterm in the boolean expression

23
Karnaugh Maps m0m0m0m0 m3m3m3m3 m1m1m1m1 m2m2m2m2 01 1 0 A B m0m0m0m0 m1m1m1m1 m3m3m3m3 m7m7m7m7 m5m5m5m5 m2m2m2m2 m6m6m6m6 m4m4m4m4 00011110 0 1 AB C m0m0m0m0 m1m1m1m1 m3m3m3m3 m5m5m5m5 m 13 m9m9m9m9 m4m4m4m4 m 12 m8m8m8m8 m6m6m6m6 m 14 m 10 m7m7m7m7 m 15 m 11 m2m2m2m2 AB CD 00011110 00 01 11 10 Logic adjacency : Any two adjacent cells in the map differ by ONLY one. Logic adjacency : Any two adjacent cells in the map differ by ONLY one. Example: m 0 (=x 1 ’x 2 ’) is adjacent to m 1 (=x 1 ’x 2 ) and m 2 (=x 1 x 2 ’) but NOT m 3 (=x 1 x 2 ) Example: m 0 (=x 1 ’x 2 ’) is adjacent to m 1 (=x 1 ’x 2 ) and m 2 (=x 1 x 2 ’) but NOT m 3 (=x 1 x 2 )

24
2-Variable Map -- Example E.g. E.g. f(x 1,x 2 ) = x 1 ’x 2 ’+ x 1 ’x 2 + x 1 x 2 ’ = m 0 + m 1 + m 2 f(x 1,x 2 ) = x 1 ’x 2 ’+ x 1 ’x 2 + x 1 x 2 ’ = m 0 + m 1 + m 2 What (simpler) function is represented by each dashed rectangle? What (simpler) function is represented by each dashed rectangle? x 1 ’x 2 ’+ x 1 ’x 2 =x 1 ’(x 2 ’+x 2 )=x 1 ’ x 1 ’x 2 ’+ x 1 x 2 ’=x 2 ’(x 1 ’+x 1 ) =x 2 ’ f(x 1,x 2 ) =x 1 ’+x 2 ’ 011 110 10 x2x2x2x2 x1x1 0 2 13

25
Minimization as SOP using K-map Enter 1s in the K-map for each product term in the function Enter 1s in the K-map for each product term in the function Group adjacent K-map cells containing 1s to obtain a product with fewer variables. Groups must be in power of 2 (2, 4, 8, … ) Group adjacent K-map cells containing 1s to obtain a product with fewer variables. Groups must be in power of 2 (2, 4, 8, … ) Handle “ boundary wrap ” for K-maps of 3 or more variables. Handle “ boundary wrap ” for K-maps of 3 or more variables.

26
Three-Variable Map m6m6m6m6 m7m7m7m7 m5m5m5m5 m4m4m4m41 m2m2m2m2 m3m3m3m3 m1m1m1m1 m0m0m0m00 10110100yz x 0132 4576 -Note: variable ordering is (x,y,z); yz specifies column, x specifies row. -Each cell is adjacent to three other cells (left or right or top or bottom or edge wrap)

27
Three-Variable Map (cont.) The types of structures that are either minterms or are generated by repeated application of the minimization theorem on a three variable map are shown at right. Groups of 1, 2, 4, 8 are possible. minterm group of 2 terms group of 4 terms

28
Simplification Example: f(a,b,c) = ac’ + abc + bc’ Example: f(a,b,c) = ac’ + abc + bc’ =a(b+b’)c’+abc+(a+a’)bc’ =a(b+b’)c’+abc+(a+a’)bc’ =abc’+ab’c’+abc+abc’+a’bc’ =abc’+ab’c’+abc+abc’+a’bc’ =abc’+ab’c’+abc+a’bc’ =abc’+ab’c’+abc+a’bc’ Result: f(a,b,c) = ac’+ab+bc’ Result: f(a,b,c) = ac’+ab+bc’ 1 111 ab c 10110100 1 0

29
More Examples f 1 (x, y, z) = ∑ m(2,3,5,7) f 1 (x, y, z) = ∑ m(2,3,5,7) f 2 (x, y, z) = ∑ m (0,1,2,3,6) f 2 (x, y, z) = ∑ m (0,1,2,3,6) f 1 (x, y, z) = x’y + xz f 1 (x, y, z) = x’y + xz f 2 (x, y, z) = x’+yz’ 10110100 xy xyz 1 0 11 1 1 11 111 z 10110100 1 0

30
10 11 01 00 Four-Variable Maps Top cells are adjacent to bottom cells. Left- edge cells are adjacent to right-edge cells. Top cells are adjacent to bottom cells. Left- edge cells are adjacent to right-edge cells. Note variable ordering (WXYZ). Note variable ordering (WXYZ). m 10 m 11 m9m9m9m9 m8m8m8m8 m 14 m 15 m 13 m 12 m6m6m6m6 m7m7m7m7 m5m5m5m5 m4m4m4m4 m2m2m2m2 m3m3m3m3 m1m1m1m1 m0m0m0m0 10 10 11 11 01 01 00 00 WX YZ

31
Four-variable Map Simplification One square represents a minterm of 4 literals. One square represents a minterm of 4 literals. A rectangle of 2 adjacent squares represents a product term of 3 literals. A rectangle of 2 adjacent squares represents a product term of 3 literals. A rectangle of 4 squares represents a product term of 2 literals. A rectangle of 4 squares represents a product term of 2 literals. A rectangle of 8 squares represents a product term of 1 literal. A rectangle of 8 squares represents a product term of 1 literal. A rectangle of 16 squares produces a function that is equal to logic 1. A rectangle of 16 squares produces a function that is equal to logic 1.

32
Example Simplify the following Boolean function (A,B,C,D) = ∑m(0,1,2,3,4,5,6,7,8,10,13). Simplify the following Boolean function (A,B,C,D) = ∑m(0,1,2,3,4,5,6,7,8,10,13). First put the function g( ) into the map, and then group as many 1s as possible. First put the function g( ) into the map, and then group as many 1s as possible. ab cd 1 11 11 1 11 1 11 g(A,B,C,D) = a’+b’d’+bc’d 111 11 111 111 10 11 01 00 10 10 11 11 01 01 00 00

33
Implicants,Prime Implicants (PIs) and Essential Prime Implicant (EPI) Implicant: Implicant: any single minterm Prime Implicant (PI) Prime Implicant (PI): a group of minterms that cannot be combined with any other minterms or groups Essential Prime Implicant (EPI): Essential Prime Implicant (EPI): a PI in which one or more miniterms are unique How to find PI and EPI? How to find PI and EPI? 1 11 1 11 A’BC’D BCD BD ABC’ AC’D’ 00011110 00 01 11 10 AB CD 1?

34
Example a’b’ is not a prime implicant because it is contained in b’. a’b’ is not a prime implicant because it is contained in b’. acd is not a prime implicant because it is contained in ad. acd is not a prime implicant because it is contained in ad. b’, ad, and a’cd’ are prime implicants. b’, ad, and a’cd’ are prime implicants. b’, ad, and a’cd’ are essential prime implicants. b’, ad, and a’cd’ are essential prime implicants. 111 111 111 11 b’ cd ab ad a’cd’ a’b’ acd

35
Another Example Consider f 2 (a,b,c,d), whose K-map is shown below. Consider f 2 (a,b,c,d), whose K-map is shown below. The only essential PI is b’d. The only essential PI is b’d. 111 11 111 1 cd ab

36
Systematic Procedure for Simplifying Boolean Functions 1. 1. Load the minterms into the K-map by placing a 1 in the appropriate square. 2. 2. Look for groups of minterms (PI) 1. The group size must be a power of 2 2. Find the largest groups of minterms first, then smaller collections until all groups are found. 3. 3. Find all essential PIs. 4. 4. For remaining min-terms not included in the essential PIs, select a set of other PIs to cover them. 5. 5. The resulting simplified function is the logical OR of the product terms selected above.

37
Example f(a,b,c,d) = ∑m(0,1,4,5,8,11,12,13,15). f(a,b,c,d) = ∑m(0,1,4,5,8,11,12,13,15). F(a,b,c,d) = c’d’ + a’c’ + bc’ + acd F(a,b,c,d) = c’d’ + a’c’ + bc’ + acd 11 111 1111 cd ab

38
Homework Simplifying Boolean Functions Simplifying Boolean Functions F(x,y,z)=∑(0,2,3,4,5,7) F(x,y,z)=∑(0,2,3,4,5,7) F(a,b,c,d)=∑(0,3,4,5,7,11,13,15) F(a,b,c,d)=∑(0,3,4,5,7,11,13,15) F(w,x,y,z)=∑(0,1,4,5,9,11,13,15) F(w,x,y,z)=∑(0,1,4,5,9,11,13,15) F(a,b,c,d)=∑(0,1,2,4,5,6,8,9,12,13,14) F(a,b,c,d)=∑(0,1,2,4,5,6,8,9,12,13,14) F(a,b,c,d)=∑(1,3,4,5,7,8,9,11,15) F(a,b,c,d)=∑(1,3,4,5,7,8,9,11,15) F(w,x,y,z)=∑(1,5,7,8,9,10,11,13,15) F(w,x,y,z)=∑(1,5,7,8,9,10,11,13,15) P151: 4-c, 4-e P151: 4-c, 4-e

Similar presentations

© 2017 SlidePlayer.com Inc.

All rights reserved.

Ads by Google