1 / 67

Digital Design & Computer Architecture Dr. Robert D. Kent

Digital Design & Computer Architecture Dr. Robert D. Kent. Lecture 2b Gates & Combinational Networks, Simplification of Boolean Expressions. Circuit Design for Computers. We continue developing the basic notions required for the design of digital circuits for computers.

berget
Download Presentation

Digital Design & Computer Architecture Dr. Robert D. Kent

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. Digital Design & Computer Architecture Dr. Robert D. Kent Lecture 2b Gates & Combinational Networks, Simplification of Boolean Expressions

  2. Circuit Design for Computers • We continue developing the basic notions required for the design of digital circuits for computers. • We have defined the Boolean Algebra and its important aspects • axioms • elements, literals, constants • operators • Boolean calculus as expression manipulation • theorems • Our next goal is to develop and employ methods for expressing combinational circuits and, in particular, techniques for simplifying the logic.

  3. Boolean Expressions - Expansion Theorem • Shannon, the pioneer who developed information theory, also provides several powerful theorems useful in manipulating boolean expressions.

  4. Boolean Expressions - Expansion Theorem • Shannon, the pioneer who developed information theory, also provides several powerful theorems useful in manipulating boolean expressions. • The first theorem is the Expansion Theorem.(a) f(x1, …, xk, …, xN) = xk .f(x1, …, 1, …, xN) + xk’.f(x1, …, 0, …, xN)(b) f(x1, …, xk, …, xN) = [xk + f(x1, …, 0, …, xN)] . [xk’ + f(x1, …, 1, …, xN)]

  5. Boolean Expressions - Expansion Theorem • Shannon, the pioneer who developed information theory, also provides several powerful theorems useful in manipulating boolean expressions. • The first theorem is the Expansion Theorem.(a) f(x1, …, xk, …, xN) = xk .f(x1, …, 1, …, xN) + xk’.f(x1, …, 0, …, xN)(b) f(x1, …, xk, …, xN) = [xk + f(x1, …, 0, …, xN)] . [xk’ + f(x1, …, 1, …, xN)] • In the expressions above, the values 1 (or 0) are substituted for the variable xk whereever it appears in the function f. Note the duality between (a) and (b) expressions.

  6. Boolean Expressions - Expansion Theorem • Example: Given the expressionf(w,x,y,z) = w’x’ + (wx + y)zAssume you want an expression of the form: f = x g1(w,y,z)+x’ g2(w,y,z)

  7. Boolean Expressions - Expansion Theorem • Example: Given the expressionf(w,x,y,z) = w’x’ + (wx + y)zAssume you want an expression of the form: f = x g1(w,y,z)+x’ g2(w,y,z)Then, using g1(w,y,z) = f(w,1,y,z) andg2(w,y,z) = f(w,0,y,z),

  8. Boolean Expressions - Expansion Theorem • Example: Given the expressionf(w,x,y,z) = w’x’ + (wx + y)zAssume you want an expression of the form: f = x g1(w,y,z)+x’ g2(w,y,z)Then, using g1(w,y,z) = f(w,1,y,z) andg2(w,y,z) = f(w,0,y,z),f = x [w’.1’ + (w.1 + y)z] +x’ [w’.0’ + (w.0 + y)z]

  9. Boolean Expressions - Expansion Theorem • Example: Given the expressionf(w,x,y,z) = w’x’ + (wx + y)zAssume you want an expression of the form: f = x g1(w,y,z)+x’ g2(w,y,z)Then, using g1(w,y,z) = f(w,1,y,z) andg2(w,y,z) = f(w,0,y,z),f = x [w’.1’ + (w.1 + y)z] +x’ [w’.0’ + (w.0 + y)z] = x [w’.0 + (w + y)z] +x’ [w’.1 + (0 + y)z]

  10. Boolean Expressions - Expansion Theorem • Example: Given the expressionf(w,x,y,z) = w’x’ + (wx + y)zAssume you want an expression of the form: f = x g1(w,y,z)+x’ g2(w,y,z)Then, using g1(w,y,z) = f(w,1,y,z) andg2(w,y,z) = f(w,0,y,z),f = x [w’.1’ + (w.1 + y)z] +x’ [w’.0’ + (w.0 + y)z] = x [w’.0 + (w + y)z] +x’ [w’.1 + (0 + y)z] = w’ = 0

  11. Boolean Expressions - Expansion Theorem • Example: Given the expressionf(w,x,y,z) = w’x’ + (wx + y)zAssume you want an expression of the form: f = x g1(w,y,z)+x’ g2(w,y,z)Then, using g1(w,y,z) = f(w,1,y,z) andg2(w,y,z) = f(w,0,y,z),f = x [w’.1’ + (w.1 + y)z] +x’ [w’.0’ + (w.0 + y)z] = x [w’.0 + (w + y)z] +x’ [w’.1 + (0 + y)z] = x (w + y) z +x’ (w’ + y.z)

  12. Boolean Expressions - Expansion Theorem • Example: Given the expressionf(w,x,y,z) = w’x’ + (wx + y)zAssume you want an expression of the form: f = x g1(w,y,z)+x’ g2(w,y,z)Then, using g1(w,y,z) = f(w,1,y,z) andg2(w,y,z) = f(w,0,y,z),f = x [w’.1’ + (w.1 + y)z] +x’ [w’.0’ + (w.0 + y)z] = x [w’.0 + (w + y)z] +x’ [w’.1 + (0 + y)z] = x (w + y) z +x’ (w’ + y.z) This technique can be reapplied to generate successive product expressions by expanding g1(w,y,z) andg2(w,y,z) and so on.

  13. Boolean Expressions - Reduction Theorem • The next set of theorems from Shannon concern reduction of the expression to a product form in one variable.

  14. Boolean Expressions - Reduction Theorem • The next set of theorems from Shannon concern reduction of the expression to a product form in one variable. • Given a function of N variables, f(x1, …, xk, …, xN), the first part of the Reduction Theorem deals with the variable xk.(a) xk . f(x1, …, xk, …, xN) = xk .f(x1, …, 1, …, xN)(b) xk + f(x1, …, xk, …, xN) = xk + f(x1, …, 0, …, xN)

  15. Boolean Expressions - Reduction Theorem Xk only! • The next set of theorems from Shannon concern reduction of the expression to a product form in one variable. • Given a function of N variables, f(x1, …, xk, …, xN), the first part of the Reduction Theorem deals with the variable xk.(a) xk . f(x1, …, xk, …, xN) = xk .f(x1, …, 1, …, xN)(b) xk + f(x1, …, xk, …, xN) = xk + f(x1, …, 0, …, xN) • In the expressions above, the values (a) 1 or (b) 0 are substituted for the variable xk whereever it appears in the function f.

  16. Boolean Expressions - Reduction Theorem • Given a function of N variables, f(x1, …, xk, …, xN), the second part of the Reduction Theorem deals with the complement of the variable xk’.

  17. Boolean Expressions - Reduction Theorem • Given a function of N variables, f(x1, …, xk, …, xN), the second part of the Reduction Theorem deals with the complement of the variable xk’.(c) xk’ . f(x1, …, xk, …, xN) = xk’ . f(x1, …, 0, …, xN)(d) xk’ + f(x1, …, xk, …, xN) = xk’ + f(x1, …, 1, …, xN)

  18. Boolean Expressions - Reduction Theorem Xk’ only! • Given a function of N variables, f(x1, …, xk, …, xN), the second part of the Reduction Theorem deals with the complement of the variable xk’.(c) xk’ . f(x1, …, xk, …, xN) = xk’ . f(x1, …, 0, …, xN)(d) xk’ + f(x1, …, xk, …, xN) = xk’ + f(x1, …, 1, …, xN) • In the expressions above, the values (c) 0 or (d) 1 are substituted for the variable xk’ whereever it appears in the function f.

  19. Boolean Expressions - Reduction Theorem • Example: Given the expressionf(w,x,y,z) = x + x’y’ + w’x’(w + z)(y+w’z)

  20. Boolean Expressions - Reduction Theorem • Example: Given the expressionf(w,x,y,z) = x + x’y’ + w’x’(w + z)(y+w’z)Then, definingg(w,x,y,z) = x’y’ + w’x’(w + z)(y+w’z)

  21. Boolean Expressions - Reduction Theorem • Example: Given the expressionf(w,x,y,z) = x + x’y’ + w’x’(w + z)(y+w’z)Then, definingg(w,x,y,z) = x’y’ + w’x’(w + z)(y+w’z) we arrive at the expression: f = x + g(w,x,y,z)

  22. Boolean Expressions - Reduction Theorem • Example: Given the expressionf(w,x,y,z) = x + x’y’ + w’x’(w + z)(y+w’z)Then, definingg(w,x,y,z) = x’y’ + w’x’(w + z)(y+w’z) we arrive at the expression: f = x + g(w,x,y,z)By the reduction theorem (b), it follows thatf = x + g(w,0,y,z)

  23. Boolean Expressions - Reduction Theorem • Example: Given the expressionf(w,x,y,z) = x + x’y’ + w’x’(w + z)(y+w’z)Then, definingg(w,x,y,z) = 0’.y’ + w’ 0’.(w + z)(y+w’z) we arrive at the expression: f = x + g(w,x,y,z)By the reduction theorem (b), it follows thatf = x + g(w,0,y,z)

  24. Boolean Expressions - Reduction Theorem • Example: Given the expressionf(w,x,y,z) = x + x’y’ + w’x’(w + z)(y+w’z)Then, definingg(w,x,y,z) = 1 .y’ + w’ 1 .(w + z)(y+w’z) we arrive at the expression: f = x + g(w,x,y,z)By the reduction theorem (b), it follows thatf = x + g(w,0,y,z) = x + y’ + w’ . (w + z)(y+w’z)

  25. Boolean Expressions - Reduction Theorem • Continuing, f(w,x,y,z) = x + y’ + w’ . (w + z)(y+w’z)

  26. Boolean Expressions - Reduction Theorem • Continuing, f(w,x,y,z) = x + y’ + w’ . (w + z)(y+w’z) From the third term, we now define h(w,y,z) = (w + z)(y+w’z)

  27. Boolean Expressions - Reduction Theorem • Continuing, f(w,x,y,z) = x + y’ + w’ . (w + z)(y+w’z) From the third term, we now define h(w,y,z) = (w + z)(y+w’z) and arrive at the expression: f = x + y’ + w’ . h(w,y,z)

  28. Boolean Expressions - Reduction Theorem • Continuing, f(w,x,y,z) = x + y’ + w’ . (w + z)(y+w’z) From the third term, we now define h(w,y,z) = (w + z)(y+w’z) and arrive at the expression: f = x + y’ + w’ . h(w,y,z) By the reduction theorem (c), it follows that f = x + y’ + w’ . [(0 + z)(y+0’.z) ]

  29. Boolean Expressions - Reduction Theorem • Continuing, f(w,x,y,z) = x + y’ + w’ . (w + z)(y+w’z) From the third term, we now define h(w,y,z) = (w + z)(y+w’z) and arrive at the expression: f = x + y’ + w’ . h(w,y,z) By the reduction theorem (c), it follows that f = x + y’ + w’ . [(0 + z)(y+0’.z) ] = x + y’ + w’.z(y+z)

  30. Boolean Expressions - Reduction Theorem • Again, continuing, f(w,x,y,z) = x + y’ + w’.z(y+z)

  31. Boolean Expressions - Reduction Theorem • Again, continuing, f(w,x,y,z) = x + y’ + w’.z(y+z) Defining k(w,x,y,z) = x + w’.z(y+z) it follows thatf(w,x,y,z) = y’ + k(w,x,y,z)

  32. Boolean Expressions - Reduction Theorem • Again, continuing, f(w,x,y,z) = x + y’ + w’.z(y+z) Defining k(w,x,y,z) = x + w’.z(y+z) it follows thatf(w,x,y,z) = y’ + k(w,x,y,z) Using reduction theorem (d) we findf(w,x,y,z) = y’ + k(w,x,1,z)

  33. Boolean Expressions - Reduction Theorem • Again, continuing, f(w,x,y,z) = x + y’ + w’.z(y+z) Defining k(w,x,y,z) = x + w’.z(y+z) it follows thatf(w,x,y,z) = y’ + k(w,x,y,z) Using reduction theorem (d) we findf(w,x,y,z) = y’ + k(w,x,1,z) = y’ + x + w’.z(1+z)

  34. Boolean Expressions - Reduction Theorem • Again, continuing, f(w,x,y,z) = x + y’ + w’.z(y+z) Defining k(w,x,y,z) = x + w’.z(y+z) it follows thatf(w,x,y,z) = y’ + k(w,x,y,z) Using reduction theorem (d) we findf(w,x,y,z) = y’ + k(w,x,1,z) = y’ + x + w’.z(1+z) = y’ + x + w’.z

  35. Boolean Expressions - Reduction Theorem • Again, continuing, f(w,x,y,z) = x + y’ + w’.z(y+z) Defining k(w,x,y,z) = x + w’.z(y+z) it follows thatf(w,x,y,z) = y’ + k(w,x,y,z) Using reduction theorem (d) we findf(w,x,y,z) = y’ + k(w,x,1,z) = y’ + x + w’.z(1+z) = y’ + x + w’.z • Recall we started with: f(w,x,y,z) = x + x’y’ + w’x’(w + z)(y+w’z)

  36. Boolean Expressions: Complement of Canonical Forms • Previously, we defined the terms canonical DNF (SOP) and CNF (POS). • DNF (SOP) Sum m( {k} ) • CNF (POS) Prod M( {k} )where the notation {k} refers to the set of all indices kj that appear in the sum of minterms mk or product of maxterms Mk.

  37. Boolean Expressions: Complement of Canonical Forms • Previously, we defined the terms canonical DNF (SOP) and CNF (POS). • DNF (SOP) Sum m( {k} ) • CNF (POS) Prod M( {k} )where the notation {k} refers to the set of all indices kj that appear in the sum of minterms mk or product of maxterms Mk. • The complement, f’, of a canonical DNF or CNF function f(x) of N variables x=(x1,.., xj,.., xN) is found by replacing the set of indices {k} by its set complement {k}’. • The set complement {k}’ includes all indices that remain after removing the set {k} from the complete set formed from the index sequence [0..N-1].

  38. Boolean Expressions: Complement of Canonical Forms DNF (SOP) Complement f(x1,.., xj,.., xN) = Sum m( {k} )f’(x1,.., xj,.., xN) = Sum m( {k}’ ) CNF (POS) Complement f(x1,.., xj,.., xN) =Prod M( {k} )f’(x1,.., xj,.., xN) = Prod M( {k}’ ) • Previously, we defined the terms canonical DNF (SOP) and CNF (POS). • DNF (SOP) G m( {k} ) • CNF (POS) A M( {k} )where the notation {k} refers to the set of all indices kj that appear in the sum of minterms mk or product of maxterms Mk. • The complement, f’, of a canonical DNF or CNF function f(x) of N variables x=(x1,.., xj,.., xN) is found by replacing the set of indices {k} by its set complement {k}’. • The set complement {k}’ includes all indices that remain after removing the set {k} from the complete set formed from the index sequence [0..N-1].

  39. Boolean Expressions: Complement of Canonical Forms • Example: 4 input variable function, F(W,X,Y,Z) - SOP form K W X Y Z F 0 0 0 0 0 0 1 0 0 0 1 1 2 0 0 1 0 0 3 0 0 1 1 0 F = Sum m( {k} ) 4 0 1 0 0 1 5 0 1 0 1 1 6 0 1 1 0 1 7 0 1 1 1 0 8 1 0 0 0 0 9 1 0 0 1 1 10 1 0 1 0 0 11 1 0 1 1 1 12 1 1 0 0 0 13 1 1 0 1 0 14 1 1 1 0 1 15 1 1 1 1 1

  40. Boolean Expressions: Complement of Canonical Forms • Example: 4 input variable function, F(W,X,Y,Z) - SOP form K W X Y Z F 0 0 0 0 0 0 1 0 0 0 1 1 {k} = 1, 4, 5, 6, 9, 11, 14, 15 2 0 0 1 0 0 3 0 0 1 1 0 F = Sum m( {k} ) 4 0 1 0 0 1 5 0 1 0 1 1 6 0 1 1 0 1 7 0 1 1 1 0 8 1 0 0 0 0 9 1 0 0 1 1 10 1 0 1 0 0 11 1 0 1 1 1 12 1 1 0 0 0 13 1 1 0 1 0 14 1 1 1 0 1 15 1 1 1 1 1

  41. Boolean Expressions: Complement of Canonical Forms • Example: 4 input variable function, F(W,X,Y,Z) - SOP form K W X Y Z F 0 0 0 0 0 0 1 0 0 0 1 1 {k} = 1, 4, 5, 6, 9, 11, 14, 15 2 0 0 1 0 0 3 0 0 1 1 0 F = Sum m( {k} ) 4 0 1 0 0 1 5 0 1 0 1 1 = Sum m(1, 4, 5, 6, 9, 11, 14, 15) 6 0 1 1 0 1 7 0 1 1 1 0 8 1 0 0 0 0 9 1 0 0 1 1 10 1 0 1 0 0 11 1 0 1 1 1 12 1 1 0 0 0 13 1 1 0 1 0 14 1 1 1 0 1 15 1 1 1 1 1

  42. Boolean Expressions: Complement of Canonical Forms • Example: 4 input variable function, F(W,X,Y,Z) - SOP form K W X Y Z F 0 0 0 0 0 0 1 0 0 0 1 1 {k} = 1, 4, 5, 6, 9, 11, 14, 15 2 0 0 1 0 0 3 0 0 1 1 0 F = Sum m( {k} ) 4 0 1 0 0 1 5 0 1 0 1 1 = Sum m(1, 4, 5, 6, 9, 11, 14, 15) 6 0 1 1 0 1 7 0 1 1 1 0 8 1 0 0 0 0 F’ = Sum m( {k}’ ) Complement 9 1 0 0 1 1 10 1 0 1 0 0 11 1 0 1 1 1 12 1 1 0 0 0 13 1 1 0 1 0 14 1 1 1 0 1 15 1 1 1 1 1

  43. Boolean Expressions: Complement of Canonical Forms • Example: 4 input variable function, F(W,X,Y,Z) - SOP form Full Index Set {j in [0..N-1]} 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15 SOP Index Set {k} 1, 4, 5, 6, 9, 11, 14, 15 SOP Complement Index Set {k}’ 0, 2, 3, 7, 8, 10, 12, 13 K W X Y Z F 0 0 0 0 0 0 1 0 0 0 1 1 {k} = 1, 4, 5, 6, 9, 11, 14, 15 2 0 0 1 0 0 3 0 0 1 1 0 F = Sum m( {k} ) 4 0 1 0 0 1 5 0 1 0 1 1 = Sum m(1, 4, 5, 6, 9, 11, 14, 15) 6 0 1 1 0 1 7 0 1 1 1 0 8 1 0 0 0 0 F’ = Sum m( {k}’ ) 9 1 0 0 1 1 10 1 0 1 0 0 11 1 0 1 1 1 12 1 1 0 0 0 13 1 1 0 1 0 14 1 1 1 0 1 15 1 1 1 1 1

  44. Boolean Expressions: Complement of Canonical Forms • Example: 4 input variable function, F(W,X,Y,Z) - SOP form Full Index Set {j in [0..N-1]} 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15 SOP Index Set {k} 1, 4, 5, 6, 9, 11, 14, 15 SOP Complement Index Set {k}’ 0, 2, 3, 7, 8, 10, 12, 13 K W X Y Z F 0 0 0 0 0 0 1 0 0 0 1 1 {k} = 1, 4, 5, 6, 9, 11, 14, 15 2 0 0 1 0 0 3 0 0 1 1 0 F = Sum m( {k} ) 4 0 1 0 0 1 5 0 1 0 1 1 = Sum m(1, 4, 5, 6, 9, 11, 14, 15) 6 0 1 1 0 1 7 0 1 1 1 0 8 1 0 0 0 0 F’ = Sum m( {k}’ ) 9 1 0 0 1 1 10 1 0 1 0 0 = Sum m(0, 2, 3, 7, 8, 10, 12, 13) 11 1 0 1 1 1 12 1 1 0 0 0 13 1 1 0 1 0 14 1 1 1 0 1 15 1 1 1 1 1

  45. Boolean Expressions: Complement of Canonical Forms • Example: 4 input variable function, F(W,X,Y,Z) - POS form K W X Y Z F 0 0 0 0 0 0 1 0 0 0 1 1 {k} = 1, 4, 5, 6, 9, 11, 14, 15 2 0 0 1 0 0 3 0 0 1 1 0 F = Prod M( {k} ) 4 0 1 0 0 1 5 0 1 0 1 1 = Prod M(1, 4, 5, 6, 9, 11, 14, 15) 6 0 1 1 0 1 7 0 1 1 1 0 8 1 0 0 0 0 9 1 0 0 1 1 10 1 0 1 0 0 11 1 0 1 1 1 12 1 1 0 0 0 13 1 1 0 1 0 14 1 1 1 0 1 15 1 1 1 1 1

  46. Boolean Expressions: Complement of Canonical Forms • Example: 4 input variable function, F(W,X,Y,Z) - POS form K W X Y Z F 0 0 0 0 0 0 1 0 0 0 1 1 {k} = 1, 4, 5, 6, 9, 11, 14, 15 2 0 0 1 0 0 3 0 0 1 1 0 F = Prod M( {k} ) 4 0 1 0 0 1 5 0 1 0 1 1 = Prod M(1, 4, 5, 6, 9, 11, 14, 15) 6 0 1 1 0 1 7 0 1 1 1 0 8 1 0 0 0 0 F’ = Prod M( {k}’ ) 9 1 0 0 1 1 10 1 0 1 0 0 = Prod M(0, 2, 3, 7, 8, 10, 12, 13) 11 1 0 1 1 1 12 1 1 0 0 0 13 1 1 0 1 0 14 1 1 1 0 1 15 1 1 1 1 1

  47. Boolean Expressions: Complementing Forms • For general boolean expressions, particularly those that are not canonical, use de Morgan’s theorems. Be methodical in their application, deriving each step carefully.

  48. Incomplete Boolean Expressions • It does happen in circuit design that the specification of output values for some terms of the output function F are missing.

  49. Incomplete Boolean Expressions • It does happen in circuit design that the specification of output values for some terms of the output function F are missing. • When this occurs and the impact of those missing terms is irrelevant, they are referred to as don’t care conditions or terms. • We use the notation: dc( {h} )to denote the SOP (or POS) expression of all the don’t care terms in the index set {h}.

  50. Incomplete Boolean Expressions • It does happen in circuit design that the specification of output values for some terms of the output function F are missing. • When this occurs and the impact of those missing terms is irrelevant, they are referred to as don’t care conditions or terms. • We use the notation: dc( {h} )to denote the SOP (or POS) expression of all the don’t care terms in the index set {h}. • Thus, a typical function might be represented as:F(x) = Sum m( {k} ) + dc( {h} )

More Related