1 / 39

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

CHAPTER 3: PRINCIPLES OF COMBINATIONAL LOGIC (Sections 3.1 – 3.5). 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. ·. ·. Combinational Logic Functions.

kara
Télécharger la présentation

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

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. 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. · · Combinational Logic Functions Inputs · · Outputs · ·

  3. 3.1.1 PROBLEM STATEMENTS TO TRUTH TABLES • 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) C2 C3 C1

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

  6. 3.1.1 PROBLEM STATEMENTS TO TRUTH TABLES • 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: 2x=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

  7. I3 I2 I1 O1 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 3.1.1 PROBLEM STATEMENTS TO TRUTH TABLES • Exe: Design a truth table to indicate a majority of three inputs is true

  8. 3.1.2 Deriving Switching Equations • 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. • Denoted by mj, where j is the decimal equivalent of the minterm’s corresponding binary combination (bj). • A variable in mj is complemented if its value in bj is 0, otherwise is uncomplemented. • M(a,b,m,s)=a’bms+ab’ms+abms (m7) (m11) (m15)

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

  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 uniquesum of minterms and a unique product of maxterms (under a fixed variable ordering). • every function F() has two canonical forms: • Canonical Sum-Of-Products (sum of minterms) • Canonical Product-Of-Sums (product of maxterms)

  13. Convert switching equations to canonical form • Expand non-canonical terms by inserting equivalent of 1 in each missing variable x: (x + x’) = 1 • Remove duplicate minterms • f1(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’

  14. Convert switching equations to canonical form • 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. Convert switching equations to canonical form • Expand noncanonical terms by adding 0 in terms of missing variables (e.g., xx’ = 0) and using the distributive law • Remove duplicate maxterms • f1(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’)

  16. Convert switching equations to canonical form • 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. Convert switching equations to canonical form • Exe: P=f(w,x,y,z)=w’x+yz’ T=f(a,b,c,d)=(a+b’+c)(a’+d) • 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 mj such that F( ) = 1 in row j of the truth table for F( ). • Canonical Product-Of-Sums:The maxterms included are those Mj such that F( ) = 0 in row j of the truth table for F( ).

  19. Example • Truth table for f1(a,b,c) at right • The canonical sum-of-products form for f1 isf1(a,b,c) = m1 + m2 + m4 + m6 = a’b’c + a’bc’ + ab’c’ + abc’ • The canonical product-of-sums form for f1 isf1(a,b,c) = M0• M3• M5• M7 = (a+b+c)•(a+b’+c’)• (a’+b+c’)•(a’+b’+c’). • Observe that: mj = Mj’ a b c f1 0 0 0 0 0 0 1 1 0 1 0 1 0 1 1 0 1 0 0 1 1 0 1 0 1 1 0 1 1 1 1 0

  20. Shorthand: ∑ and ∏ • f1(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 m1, m2, m4, and m6. • f1(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 M0, M3, M5, and M7. • ∑m(1,2,4,6) = ∏M(0,3,5,7) = f1(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. • Example:f1(a,b,c) = a’b’c + a’bc’ + ab’c’ + abc’ = m1 + m2 + m4 + m6= ∑(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? to simplify boolean equations • 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 minterm or a maxterm in the boolean expression

  23. AB A B 0 1 00 01 11 10 0 m0 m2 m0 m2 m6 m4 0 1 m1 m3 1 m1 m3 m7 m5 AB CD 00 01 11 10 00 m0 m4 m12 m8 01 m1 m5 m13 m9 m3 11 m7 m15 m11 10 m2 m6 m14 m10 Karnaugh Maps C • Logic adjacency : Any two adjacent cells in the map differ by ONLY one. • Example:m0 (=x1’x2’) is adjacent to m1 (=x1’x2) and m2 (=x1x2’) but NOT m3 (=x1x2)

  24. 2-Variable Map -- Example • E.g. f(x1,x2) = x1’x2’+ x1’x2 + x1x2’ = m0 + m1 + m2 • What (simpler) function is represented by each dashed rectangle? • x1’x2’+ x1’x2 =x1’(x2’+x2)=x1’ • x1’x2’+ x1x2’=x2’(x1’+x1) =x2’ f(x1,x2) =x1’+x2’ x2 0 1 x1 2 0 0 1 1 1 3 1 1 0

  25. Minimization as SOP using K-map • 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, …) • Handle “boundary wrap” for K-maps of 3 or more variables.

  26. Three-Variable Map yz 00 01 11 10 x 0 m0 m1 m3 m2 0 1 3 2 1 m4 m5 m7 m6 4 5 7 6 -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.) minterm 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. group of 2 terms group of 4 terms

  28. Simplification • Example: f(a,b,c) = ac’ + abc + bc’ =a(b+b’)c’+abc+(a+a’)bc’ =abc’+ab’c’+abc+abc’+a’bc’ =abc’+ab’c’+abc+a’bc’ • Result: f(a,b,c) = ac’+ab+bc’ 00 01 11 10 ab c 0 1 1 1 1 1

  29. More Examples xy z 00 01 11 10 • f1(x, y, z) = ∑ m(2,3,5,7) • f2(x, y, z) = ∑ m (0,1,2,3,6) 0 1 1 1 1 1 f1(x, y, z) = x’y + xz 00 01 11 10 xy z 1 1 1 0 f2(x, y, z) = x’+yz’ 1 1 1

  30. Four-Variable Maps YZ 00 01 11 10 WX • Top cells are adjacent to bottom cells. Left-edge cells are adjacent to right-edge cells. • Note variable ordering (WXYZ). m0 m1 m3 m2 00 m4 m5 m7 m6 01 m12 m13 m15 m14 11 m8 m9 m11 m10 10

  31. Four-variable Map Simplification • One square represents a minterm of 4 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 8 squares represents a product term of 1 literal. • 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). • First put the function g( ) into the map, and then group as many 1s as possible. 00 01 11 10 cd ab 1 1 1 1 1 1 00 1 1 1 1 1 1 01 1 1 1 1 11 1 1 1 1 1 1 10 g(A,B,C,D) = a’+b’d’+bc’d

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

  34. Example • 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. • b’, ad, and a’cd’ are prime implicants. • b’, ad, and a’cd’ are essentialprime implicants. b’ ad cd ab 1 1 1 1 1 1 1 1 a’b’ 1 1 1 acd a’cd’

  35. Another Example • Consider f2(a,b,c,d), whose K-map is shown below. • The only essential PI isb’d. ab cd 1 1 1 1 1 1 1 1 1

  36. Systematic Procedure for Simplifying Boolean Functions • Load the minterms into the K-map by placing a 1 in the appropriate square. • Look for groups of minterms (PI) • The group size must be a power of 2 • Find the largest groups of minterms first, then smaller collections until all groups are found. • Find all essential PIs. • For remaining min-terms not included in the essential PIs, select a set of other PIs to cover them. • 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) = c’d’ + a’c’ + bc’ + acd ab cd 1 1 1 1 1 1 1 1 1

  38. Homework • Simplifying Boolean Functions F(x,y,z)=∑(0,2,3,4,5,7) 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(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(w,x,y,z)=∑(1,5,7,8,9,10,11,13,15) • P151: 4-c, 4-e

  39. TO BE CONTINUED

More Related