Lab Session # 2 Synthesis Using Logic Gates in SOP & POS Forms
Lab Session # 2 Synthesis Using Logic Gates in SOP & POS Forms
1. Introduction
In this experiment, you will get to know what is meant by a Minterm, Maxterm, Sum of Products (SOP)
and Product of Sums (POS). In addition, you will learn how to design the expressions of the SOP and POS
using Quartus II 13.1 software.
2. Objectives
By the end of this lab experiment, students will be:
• Familiar with the Minterms, Maxterms, Sum of Products (SOP) and Product of Sums (POS).
• Able to design the expressions of the SOP and POS using Quartus II Software.
• Able to test the correct behavior of the expressions generated using SOP and POS.
A possible procedure for designing a logic circuit that implements the truth table is to create a product
term that has a value of 1 for each valuation for which the output function f has to be 1. Then we can take
a logical sum of these product terms to realize f. Let us begin with the fourth row of the truth table, which
corresponds to x = y = 1. The product term that is equal to 1 for this valuation is x . y, which is just the AND
of x and y. Next, consider the first row of the table, for which x = y = 0. For this valuation, the value 1 is
produced by the product term x' . y'. Similarly, the second row leads to the term x' . y. Thus, f may be
realized as
f ( x, y ) = x y + x' y' + x' y
The logic network that corresponds to this expression is shown in Figure 1.
Figure 1: The Implementation of the Function in Table 1
Although this network implements f correctly, it is not the simplest such network. To find a simpler
network, we can manipulate the obtained expression using the theorems and properties in Figure 2.
This simple example illustrates two things. First, a straightforward implementation of a function can be
obtained by using a product term (AND gate) for each row of the truth table for which the function is
equal to 1. Each product term contains all input variables, and it is formed such that if the input variable x
i
is equal to 1 in the given row, then x is entered in the term; if x = 0, then x ' is entered. The sum of these
i i i
product terms realizes the desired function. Second, there are many different networks that can realize a
given function. Some of these networks may be simpler than others. Algebraic manipulation can be used
to derive simplified logic expressions and thus lower-cost networks.
If a function f is specified in the form of a truth table, then an expression that realizes f can be obtained by
considering the rows in the table for which f = 1, as has been explained earlier, or by considering the rows
for which f = 0, as will be explained later.
3.1 Minterm
A binary variable may appear either in normal form (x) or in its complement form (x'). Now, consider two
binary variables, x and y, combined with an AND operation. Since each variable may appear in either
form, there are four possible combinations: x' y', x' y, x y' and x y. Each of these four AND terms is called a
minterm, or a standard product. A minterm is defined as a product term in which each of the function
variables appears once in either complemented or uncomplemented form. In a similar manner, n
n n
variables can be combined to form 2 minterms. The different 2 minterms may be determined by a
n
method similar to the one shown in Table 2 for three variables. The binary numbers from 0 to 2 – 1 are
listed under the n variables. Each minterm is obtained from an AND term of the n variables, with each
variable being primed (x') if the corresponding bit of the binary number is a 0 and unprimed (x) if it is a 1.
A symbol for each minterm is also shown in Table 1 and is of the form m , where j denotes the decimal
j
3.2 Maxterm
Given a logic expression, its dual is obtained by replacing all "+" operators with "." operators, and vice
versa, and by replacing all 0s with 1s, and vice versa. This principle suggests that if it is possible to
synthesize a function f by considering the rows in the truth table for which f = 1, then it should also be
possible to synthesize f by considering the rows for which f = 0. This alternative approach uses the
complement of minterms, which are called maxterms. In other words, the n variables forming an OR term,
n
with each variable being primed or unprimed, provide 2 possible combinations, are called maxterms, or
standard sums. The eight maxterms for three variables, together with their symbolic designation, are
n
listed in Table 2. Any 2 maxterms for n variables may be determined similarly. Each maxterm is obtained
from an OR term of the n variables, with each variable being unprimed if the corresponding bit is a 0 and
primed if it is a 1. Note that each maxterm is the complement of its corresponding minterm, and vice
versa.
Table 2: Minterms and Maxterms for Three Binary Variables
Minterms Maxterms
x y z Term Designation Term Designation
0 0 0 x' y' z' m x+y+z M
0 0
0 0 1 x' y' z m x + y + z' M
1 1
0 1 0 x' y z' m x + y' + z M
2 2
0 1 1 x' y z m x + y' + z' M
3 3
1 0 0 x y' z' m x' + y + z M
4 4
1 0 1 x y' z m x' + y + z' M
5 5
1 1 0 x y z' m x' + y' + z M
6 6
1 1 1 xyz m x' + y' + z' M
7 7
can be represented as
f ( x, y ) = m . 1 + m . 1 + m . 0 + m . 1
0 1 2 3
f ( x, y ) = m + m + m
0 1 3
Any function f can be represented by a sum of minterms that correspond to the rows in the truth table for
which f = 1. The resulting implementation is functionally correct and unique, but it is not necessarily the
lowest-cost implementation of f. A logic expression consisting of product (AND) terms that are summed
(ORed) is said to be of the sum-of-products (SOP) form. If each product term is a minterm, then the
expression is called canonical sum-of-products for the function f. As we have seen in the example of Table
1, the first step in the synthesis process is to derive a canonical sum-of-products expression for the given
function. Then we can manipulate the expression, using the Boolean Algebraic theorems, with the goal of
finding a functionally equivalent sum-of-products expression that has a lower cost.
Minterms, with their row-number subscripts, can also be used to specify a given function in a more
concise form. Again, for the example of Table 1, the function can be specified as
f ( x, y ) = Ʃ ( m , m , m )
0 1 3
f ( x, y ) = Ʃ ( 0, 1, 3 )
where the sign Ʃ denotes the logical sum operation. This shorthand notation is often used in practice.
where M is the maxterm for row 2 in the truth table. Using shorthand notation, an alternative way of
2
1. From the specification of the circuit, determine the required number of inputs and outputs
and assign a symbol to each one of them, if they were not given in the problem statement.
2. Derive the truth table that defines the required relationship between inputs and outputs.
3. Obtain the simplified Boolean functions using Boolean algebra for the output as a function of
input variables.
4. Draw the logic diagram (graphical design) or write a Verilog code representing your design.
5. Simulate and check the functionality of the designed circuit.
Problem Statement: Designing simplest SOP & POS circuits for a given function
f ( x, y ) = Ʃ ( 0, 1, 3 )
F Minterms Maxterms
x y Output
Term Designation Term Designation
0 1 1 x' y m x + y' M
1 1
1 0 0 x y' m x' + y M
2 2
1 1 1 xy m x' + y' M
3 3
Step 5: Simulation
1. Synthesize your design for the implemented circuit (refer to Section 3.2.5 in Lab Session#1).
2. Perform Functional Simulation (refer to Section 3.4 in Lab Session#1).
Student Name: Date:
Student ID:
Lab Exercise # 2
Problem Statement:
Use the expression of the logic circuit given to you by your instructor to derive the SOP and POS forms,
then design them using Quartus II Software. Synthesize your designs and test their functionality
correctness (Functional Simulation) for the correct behavior of the expressions generated using SOP and
POS.
Procedure:
1. Design the combinational circuit for the given function:
The given Equation is: …………………………………………………………………………………………………………………
2. Fill in the truth table for the given equation, in Table 4 shown below.
Table 4: Minterms and Maxterms for the Given Equation
F Minterms Maxterms
x y z Output
Term Designation Term Designation
3. Use the Boolean Algebraic simplification rules given in Figure 2 to design the simplest Sum-Of-
Products (SOP) circuit equation that implements F.
4. Use graphical/schematic to design the simplest SOP expression.
5. Create a Block Diagram/Schematic design file for the designed circuit (refer to Section 3.2 in Lab
Session#1).
6. Synthesize it (refer to Section 3.2.5 in Lab Session#1).
7. Perform a Functional Simulation (refer to Section 3.4 in Lab Session#1) to test your design for all
the possible test cases (Table 4).
8. Use the Boolean Algebraic simplification rules given in Figure 2 to design the simplest Product-Of-
Sums (POS) circuit equation that implements F.
Ask your engineer to check your results, write his/her comments and sign below:
………………………………………………………………………………………………………………………...…………………………...……….
……………………………………………………………………………………………………………………...………………………...…………….
…………………………………………………………………………………………………………………...…………………………………………
Engineer Signature
……..……………..
Attachments:
Please attach with the lab exercise sheet printouts of the files indicated below. Don't forget to
write your Name and ID Number as comments in every file before printing.