Lecture 4: More Boolean Algebra Syed M. Mahmud, Ph.D ECE Department Wayne State University Original Source: Prof. Russell Tessier of University of Massachusetts Aby George of Wayne State University ENGIN2 L6: More Boolean Algebra September 5, 23
Overview Epressing Boolean functions Relationships between algebraic equations, symbols, and truth tables Simplification of Boolean epressions Minterms and Materms AND-OR representations Product of sums Sum of products ENGIN2 L6: More Boolean Algebra September 5, 23
Conversion between Boolean Epression and Truth Table Boolean Epression Truth Table ENGIN2 L6: More Boolean Algebra September 5, 23
ENGIN2 L6: More Boolean Algebra September 5, 23 Truth Table to Epression What Boolean function is represented by the following Truth Table? Is it an AND or an OR function? The answer is AND because G= only for one combination of, y and z (=, y= and z=). Therefore, G = yz y z G
ENGIN2 L6: More Boolean Algebra September 5, 23 Truth Table to Epression What about G2 and G3? Both G2 and G3 represent AND operations because each one of these two functions is also equal to, only for one combination of, y and z. G2= for =, y= and z=, and G3= for =, y= and z=. Therefore, G2 = yz and G3 = yz y z G2 y z G3
ENGIN2 L6: More Boolean Algebra September 5, 23 Truth Table to Epression If G = G+G2+G3, as shown in the following Truth Table, then G = yz + yz + yz y z G G2 G3 G = G+G2+G3
Truth Table to Epression Converting a truth table to an epression Each row with output of becomes a product term Sum all the product terms together. y z G Any Boolean Epression can be represented in sum of products form! yz + yz + yz G = yz + yz' +'yz Product Terms Sum of 3 Product Terms ENGIN2 L6: More Boolean Algebra September 5, 23
Implementation of the SOP Epression SOP Epression: G = yz + yz' +'yz A SOP epression is implemented using one OR gate and multiple AND gates. This is not a minimum logic. We will minimize later. ENGIN2 L6: More Boolean Algebra September 5, 23
Reducing the epression for G using Boolean Algebra G = yz + yz' +'yz Step : Use Theorum (a + a = a) So yz + yz + yz = yz + yz + yz + yz Step 2: Use distributive rule a(b + c) = ab + ac So yz + yz + yz + yz = y(z + z ) + yz( + ) Step 3: Use Postulate 3 (a + a = ) So y(z + z ) + yz( + ) = y. + yz. Step 4: Use Postulate 2 (a. = a) So y. + yz. = y + yz Therefore, G = y + yz ENGIN2 L6: More Boolean Algebra September 5, 23
ENGIN2 L6: More Boolean Algebra September 5, 23 Reduced Hardware Implementation Reduced equation requires less hardware! Same function implemented! y z y z G G = yz + yz + yz = y + yz G
Product of Sums (POS) Epression Any Boolean Epression can be represented in Product of Sums (POS) form. Let's find a POS epression for G. We have shown how G was written in a SOP epression. Using the same technique we can write a SOP epression for G'. G' = 'y'z'+'y'z+'yz'+y'z'+y'z Using DeMorgan's Theorem we can convert the SOP epression for G' into a POS epression for G ENGIN2 L6: More Boolean Algebra September 5, 23
Product of Sums (POS) Epression G' = 'y'z'+'y'z+'yz'+y'z'+y'z G = (G')' = ('y'z'+'y'z+'yz'+y'z'+y'z)' Using DeMorgan G=('y'z')'.('y'z)'.('yz')'.(y'z')'.(y'z)' Using DeMorgan again G=(+y+z).(+y+z').(+y'+z).('+y+z).('+y+z') Sum Terms POS Epression ENGIN2 L6: More Boolean Algebra September 5, 23
Summary of SOP and POS Epressions for G SOP Epression: G = yz + yz' +'yz POS Epression: G=(+y+z)(+y+z')(+y'+z)('+y+z)('+y+z') Notice, the SOP epression has 3 Product terms and the POS epression has 5 Sum terms. There are 8 terms in both SOP and POS epressions together. Why? Because G is a function of 3 variable (, y and z), and 3 variables have 8 different combinations. The 's of G are used for SOP and the 's of G are used for POS. ENGIN2 L6: More Boolean Algebra September 5, 23
Implementation of the POS Epression POS Epression: G=(+y+z)(+y+z')(+y'+z)('+y+z)('+y+z') A POS epression is implemented using one AND gate and multiple OR gates. ENGIN2 L6: More Boolean Algebra September 5, 23
Minterms and Materms The boolean variables and their complements are called Literals. For eample, is a literal, and y' is also a literal. The Product Terms of literals are called Minterms. The Sum Terms of literals are called Materms. ENGIN2 L6: More Boolean Algebra September 5, 23
ENGIN2 L6: More Boolean Algebra September 5, 23 Representing Functions with Minterms A SOP epression is a Sum of Minterms. The Minterms of a function correspond to the 's of the function. Shorthand way to represent functions y z G G = yz + yz + yz G = m 3 + m 6 + m 7 = Σm(3, 6, 7)
ENGIN2 L6: More Boolean Algebra September 5, 23 Representing Functions with Materms A POS epression is a Product of Materms. The Materms of a function correspond to the 's of the function. Shorthand way to represent functions G = (+y+z)(+y+z )(+y +z)( +y+z)( +y+z ) G = M M M 2 M 4 M 5 = ΠM(,,2,4,5) y z G
ENGIN2 L6: More Boolean Algebra September 5, 23 Canonical Forms The Minterm and Materm epressions are also called Canonical Forms y z G G = m 3 + m 6 + m 7 = Σm(3, 6, 7) G = M M M 2 M 4 M 5 = ΠM(,,2,4,5) Canonical Forms
Conversion Between Canonical Forms Easy to convert between Minterm and Materm epressions. Since 3 variables can take 8 combinations, if there are N Minterms in the epression for a function, then there will be 8-N Materms in the epression for the function. Similarly, since 4 variables can take 6 combinations, if there are N Minterms in the epression for a function, then there will be 6-N Materms in the epression for the function. Eample: IF F = Σ m(, 3, 6, 7,, 2, 5) THEN F = Π M(, 2, 4, 5, 8, 9,, 3, 4) ENGIN2 L6: More Boolean Algebra September 5, 23
Representation in Circuits All logic epressions can be represented in 2-level format Circuits can be reduced to minimal 2-level representation Sum of products representations are most common in industry. ENGIN2 L6: More Boolean Algebra September 5, 23
Summary Truth table, circuit, and boolean epression formats are equivalent Easy to translate truth table to SOP and POS representation Boolean algebra rules can be used to reduce circuit size while maintaining function All logic functions can be made from AND, OR, and NOT ENGIN2 L6: More Boolean Algebra September 5, 23
Practice Problems Boolean algebra, Basic theorems and Postulates 2., 2.2, 2.3, 2.5, 2.6 Boolean functions 2.8, 2.9, 2., 2.8 Canonical and standard forms and digital logic gates 2.2, 2.22, 2.23, 2.27, 2.28 ENGIN2 L6: More Boolean Algebra September 5, 23