All of the Boolean Expressions can be represented in either canonical form or standard form. In this tutorial, I am going to explain both forms with the help of solved examples.
Learning Objectives:
- Determine the canonical forms of a Boolean expression
- Determine the standard forms of a Boolean expression
- Minterms and maxterms explanation with the help of two-variable and three-variable functions
- What is meant by the sum of products (SOP) and product of sum (POS) expressions?
- Convert an SOP expression into a standard SOP and a POS expression into a standard POS
- Non-standard SOP expression to standard SOP expression
- Non-standard POS expression to standard POS expression
- Evaluate the complement of a function from canonical form
- Conversion between standard forms
- standard SOP to standard POS
- standard POS to standard SOP
- Examples of all the topics mentioned above
The canonical forms of a Boolean expression || Standard Form of a Boolean expression
Minterms:
- Draw truth table
- Assign minterms to all possible combinations of variables. For three variables there are 8 possible combinations (23) and there are 8 minterms as well.
- Pick only those minterms that produce 1 at the output.
- spao="font-size: medium;">'OR' all the minterms
Example: Express AND gate expression in the sum of minterms
It is a short notation for the sum of minterms.
Example: Express OR gate expression in the sum of minterms
It is a short notation for the sum of minterms.
Maxterms
- Draw truth table
- Assign maxterms to all possible combinations of variables for 3 variables there are 8 possible combinations
- Pick only those maxterms that produce 0
- 'AND' all the maxterms
Example: Express AND gate expression in the product of maxterms
F = M0 . M1 . M2 = (A + B)(A + B')(A' + B)
F(A,B) = π (0,1,2)
It is a short notation for the product of maxterms.
Example: Express OR gate expression in the product of maxterms
F = M0 = (A + B)
F(A,B) = π (0)
It is a short notation for the product of maxterms.
ANY BOOLEAN FUNCTION CAN EXPRESS IN THE PRODUCT OF MAXTERMS.
Example: The truth table is given. Express the function in the sum of minterms and the product of maxterms.
Sum Of Minterms:
F = A’.B’.C + A.B’.C’ + A.B’.C + A.B.C’ + A.B.C
F = m0 + m4 + m5 + m6 + m7
F(A,B,C) = ∑ (1,4,5,6,7 )
Product Of Maxterms:
F = (A+B+C)(A+B’+C)(A+B’+C’)
F = M0 M2 M3
F(A,B,C) = π (0,2,3 )
Convert The Boolean Expression In Standard POS | Standard SOP:
Standard SOP:
When two or more product terms are summed by Boolean addition, the resulting sum is a Sum of Products (SOP).
Examples:
AB + CD
AB' + CD'
A standard SOP expression is one in which all the variables in the domain apear in each product term in the expression.
Examples:
An example of a standard SOP expression is given below:
AB'C + AB'C' + ABC +A'BC + A'B'C
Domain: Set of variables A, B, C
Each product term contains all three variables.
ANY BOOLEAN FUNCTION CAN BE EXPRESSED IN THE SUM OF PRODUCTS.
Convert an ordinary SOP into a standard SOP:
To convert an ordinary SOP into a standard SOP, we use the following laws of Boolean algebra:
- A variable added to its complement is equal to '1'
- Any variable multiplied by 1 remains the same
- Distributive law
- Check out for non-standard terms
- Find out the missing variable
- Multiply each term by a term containing a variable added to its complement. For example A = A + A' and AB = AB(B + B'). Since B + B' = 1
When two or more sum terms are multiplied, the resulting expression is a product of sum (POS).
Examples of standard POS form:
A standard POS expression is one in which all the variables in the domain appear in each sum term in the expression.
Examples:
It is a standard POS expression.
Convert an ordinary POS into a standard POS:
- A variable multiplied by its complement is equal to 0
- If '0' is added to any term, the result will remain unchanged (additive identity)
- Apply distributive law
- Check out for non-standard terms
- Find out the missing variable
- Add a term that is equivalent to '0'. For example, X.X' = 0
- Apply this rule (A+B)(A+C) = A + BC. Learn more about these rules in my article laws of Boolean algebra.
Complement Of a Function Evaluated With The Help Of Canonical Form:
- The complement of a function is evaluated from the truth table. The complement of a function is equal to the sum of minterms missing in the original function
- Another important property that is clear from the truth table is Mj ' = mj. It means any minterm with subscript j is equal to the complement of the maxterm with the same subscript j.
- To explain my point, I will proceed with the help of the simplest example of the OR gate. The complement of the OR gate is the NOR gate.
The complemented function that is NOR has minterms that are not in the original OR function. In other words NOR function has maxterms that are missing in the original OR function.
Examples: Evaluate the complement of the following Boolean function/ logic expression with the help of canonical forms. F = XY' + X'Y
F = XY' + X'Y F' = (XY' + X'Y)'De Morgan's law F' = (XY')' (X'Y)'again apply De Morgan's LawF' = (X' + Y)(X + Y')Apply distributive lawF' = XX' + X'Y' + XY + YY'XX' = 0F' = X'Y' + XY
The above expression is the complement of the given Boolean function. It is obtained for simplification of laws theorems. For more examples please check out my article here on Boolean expression simplification exercises.
Now our aim is to evaluate with the help of canonical forms.
Step 1: Draw truth tables along with minterms and maxterms
F = M0 . M3
F = m1 + m2
F' = (m1 + m2)'DeMorgan's lawF' = m1' . m2'F' = M1 . M2 This expression F' = M1. M2 is the maxterm notation for the complement of the given function. now draw its truth table. Recall that maxterms are those where the function produces '0' at the output.
F' = m0 + m3
F' = X'Y' + XYF'(X , Y) = ∑ (0 , 3 )
Conversion Between Standard Forms: SOP To POS | POS To SOP:
F = AB + CD SOP formF = (A +B)(C +D) POS formF = (AB + C)(CD + A) Neither POS nor SOP
I have already discussed conversion from ordinary SOP/POS to standard SOP/POS. For more examples please check out my next article for solved examples.
To convert standard POS to SOP or vice versa please do these simple steps.- Convert the given expression into standard form. If it is given in ordinary SOP, convert it into standard SOP, if it is given in ordinary POS, convert it into standard POS. Standard SOP expression contains all the minterms (combination of variables that produce 1) and standard POS expression contains all the maxterms (combination of variables that produce 0).
- Write binary equivalent for each term in standard SOP or POS expression. for example, 1+0+0 is the binary equivalent value for (A'+B+C)
- Evaluate the number of possible combinations with the help of several variables (for 2 variables, the number of possible combinations is 22 )
- If the POS expression contains 2 product terms (for 2 variable expressions) the rest of the 2 terms are SOP terms. And if the POS expression contains 5 product terms (for 3 variable expressions) the rest of the 3 terms are SOP terms.
- Draw the truth table for ease.
Example: (A + B' +C)(A + B +C') (POS To SOP)
Step 1:The expression is already in standard form.
Step 2:Write binary equivalent for each combination of variables.A + B' + C = 0 + 1 + 0A + B + C' = 0 + 0 + 1
Step 3:The total number of possible combinations is 23 = 8.
Step 4:The POS expression contains only 2 combinations of variables. The rest of the 6 terms are SOP.Step 5:Have a look at the truth table.
F = A’.B’.C + A’.B.C + A.B’.C’ + A.B’.C + A.B.C’ + A.B.C
Example: A'B'C + AB'C' +ABC (SOP To POS)
Step 1:The expression is already in standard form.
Step 2:Write binary equivalent for each combination of variables.A'.B'.C = 0.0.1A.B'.C' = 1.0.0A.B.C = 1.1.1
Step 3:The total number of possible combinations is 23 = 8.
Step 4:The SOP expression contains only 3 combinations of variables. The rest of the 6 terms are POS.Step 5:Have a look at the truth table.
F = (A+B+C)(A+B’+C)(A+B’+C’ )(A’+B+C’)(A’+B’+C)
Check out my next article for solved examples here.
F = M0 . M3
F = m1 + m2
F' = m0 + m3
F'(X , Y) = ∑ (0 , 3 )
Conversion Between Standard Forms: SOP To POS | POS To SOP:
- Convert the given expression into standard form. If it is given in ordinary SOP, convert it into standard SOP, if it is given in ordinary POS, convert it into standard POS. Standard SOP expression contains all the minterms (combination of variables that produce 1) and standard POS expression contains all the maxterms (combination of variables that produce 0).
- Write binary equivalent for each term in standard SOP or POS expression. for example, 1+0+0 is the binary equivalent value for (A'+B+C)
- Evaluate the number of possible combinations with the help of several variables (for 2 variables, the number of possible combinations is 22 )
- If the POS expression contains 2 product terms (for 2 variable expressions) the rest of the 2 terms are SOP terms. And if the POS expression contains 5 product terms (for 3 variable expressions) the rest of the 3 terms are SOP terms.
- Draw the truth table for ease.
Example: (A + B' +C)(A + B +C') (POS To SOP)
Example: A'B'C + AB'C' +ABC (SOP To POS)
F = (A+B+C)(A+B’+C)(A+B’+C’ )(A’+B+C’)(A’+B’+C)
Check out my next article for solved examples here.