0% found this document useful (0 votes)
12 views45 pages

Week 4

The document discusses the sum-of-products (SOP) and product-of-sums (POS) forms of Boolean expressions, highlighting their significance in simplifying combinational logic, particularly in programmable logic devices (PLDs). It explains the standard forms of SOP and POS, including how to represent minterms and maxterms, and introduces Karnaugh maps (K-maps) as a graphical tool for simplifying Boolean functions. Additionally, it provides examples of using K-maps for minimization and the importance of variable ordering in these maps.

Uploaded by

minzaimran0
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
12 views45 pages

Week 4

The document discusses the sum-of-products (SOP) and product-of-sums (POS) forms of Boolean expressions, highlighting their significance in simplifying combinational logic, particularly in programmable logic devices (PLDs). It explains the standard forms of SOP and POS, including how to represent minterms and maxterms, and introduces Karnaugh maps (K-maps) as a graphical tool for simplifying Boolean functions. Additionally, it provides examples of using K-maps for minimization and the importance of variable ordering in these maps.

Uploaded by

minzaimran0
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 45

Week 4 – SoP and PoS with K-Maps

SOP and POS forms


• Boolean expressions can be written in the sum-of-products form (SOP) or in the
product-of-sums form (POS).
• These forms can simplify the implementation of combinational logic, particularly
with PLDs.
• In both forms, an overbar cannot extend over more than one variable.
• An expression is in SOP form when two or more product terms are summed as in
the following examples:
ABC+AB ABC+CD CD+E
• An expression is in POS form when two or more sum terms are multiplied as
in the following examples:
(A + B)(A + C) (A + B + C)(B + D) (A + B)C
SOP and POS forms
• Boolean expressions can be written in the sum-of-products form (SOP) or in the
product-of-sums form (POS).
• These forms can simplify the implementation of combinational logic, particularly
with PLDs.
• In both forms, an overbar cannot extend over more than one variable.
• An expression is in SOP form when two or more product terms are summed as in
the following examples:
ABC+AB ABC+CD CD+E
• An expression is in POS form when two or more sum terms are multiplied as
in the following examples:
(A + B)(A + C) (A + B + C)(B + D) (A + B)C
SOP Standard form
• Standard SOP is an SOP expression which involves every variable or its
component.
• E.g F(A,B,C) = ABC + ABC+ ABC+ABC
F(A,B) = AB
• Every minterm is represented by mn and it is a product of all inputs.
• For writing a minterm add a complement to inputs with values 0.
• In equation, we write all minterms where output = 1.
A B C XOR Minterm

0 0 0
0 0 1
0 1 0
0 1 1
1 0 0
1 0 1
1 1 0
1 1 1
SOP Standard form
• In SOP standard form, every variable in the domain must appear in each term.
This form is useful for constructing truth tables or for implementing logic in PLDs.

• You can expand a nonstandard term to standard form by multiplying the term by a
term consisting of the sum of the missing variable and its complement.

Convert X = A B + A B C to standard form.


SOP Standard form
• In SOP standard form, every variable in the domain must appear in each term.
This form is useful for constructing truth tables or for implementing logic in PLDs.

• You can expand a nonstandard term to standard form by multiplying the term by a
term consisting of the sum of the missing variable and its complement.

Convert X = A B + A B C to standard form.


The first term does not include the variable C. Therefore, multiply it by the
(C + C), which = 1:

X = A B (C + C) + A B C
=ABC+ABC+ABC
SOP Standard form
SOP Standard form
POS Standard form
• Standard POS is an POS expression which involves every variable or its
component.
• E.g F(A,B,C) = (A+B+C) .(A+B+C).( A+B+C).(A+B+C)
F(A,B) = A+B
• Every maxterm is represented by Mn and it is a product of all inputs.
• For writing a maxterm add a complement to inputs with values 1.
• In equation, we write all maxterms where output = 0.
A B C XOR Maxterm

0 0 0
0 0 1
0 1 0
0 1 1
1 0 0
1 0 1
1 1 0
1 1 1
POS Standard form
POS Standard form
In POS standard form, every variable in the domain must
appear in each sum term of the expression.
You can expand a nonstandard POS expression to standard form by
adding the product of the missing variable and its complement and
applying rule 12, which states that (A + B)(A + C) = A + BC.

Convert X = (A + B)(A + B + C) to standard form.

The first sum term does not include the variable C.


Therefore, add C C and expand the result by rule 12.
X = (A + B + C C)(A + B + C)
= (A +B + C )(A + B + C)(A + B + C)
Example
Design the minimum-cost product-of-sums
expression for the function

F (x1, x2, x3) = Σ (0, 2, 4, 5, 6, 7)


Minterms and Maxterms
(with three variables)

f(x1, x2, x3) = Σ (0, 2, 4, 5, 6, 7)


Minterms and Maxterms
(with three variables)

The function is
1 for these rows
Minterms and Maxterms
(with three variables)

The function is The function is


1 for these rows 0 for these rows
Minterms and Maxterms
(with three variables)

Two different ways to specify the


same function f of three variables

f(x1, x2, x3) = Σ (0, 2, 4, 5, 6, 7)


f(x1, x2, x3) = Π (1, 3)

The function is The function is


1 for these rows 0 for these rows
The POS Expression

f(x1, x2, x3) = Π M(1, 3)

= M1  M3
= ( x1 + x2 + x3)( x1 + x2 + x3)

= ( x1 + x3 + x2)( x1 + x3 + x2)

= ( x1 + x3 )
Alternative Solution Using K-Maps
x1 x2 x3
x1 x2
0 0 0 m0 x3
00 01 11 10
0 0 1 m1
0 m0 m2 m6 m4
0 1 0 m2
0 1 1 m3 1 m1 m3 m7 m5
1 0 0 m4
1 0 1 m5 (b) Karnaugh map
1 1 0 m6
1 1 1 m7

(a) Truth table


Karnaugh Maps
• Karnaugh maps (K-maps) are graphical representations of Boolean functions.
• One map cell corresponds to a row in the truth table.
• Also, one map cell corresponds to a minterm or a maxterm in the Boolean
expression.
• Multiple-cell areas of the map correspond to standard terms.
Two-Variable Map
• Karnaugh maps, or K-maps, are often used to simplify logic problems with 2, 3, 4 or 5 variables.

No. of Cells = 2n ,where n is a number of variables

For the case of 2 variables, we form a map consisting of 22=4 cells, as shown in Figure

B B B
0 1 0 1 0 1
A A A

A+ B A+ B 00 01
0 0 0 1 0 AB A B
1 A+B A+B 1 10 11 1 AB AB
2 3

Maxterm Minterm
Two-Variable Map
x2 x1
x1 0 1 x2 0 1
0 1 0 2
0 m0 m1
OR 0 m0 m2
2 3 1 3
1 m2 m3 1 m1 m3

NOTE: ordering of variables is IMPORTANT for f(x1,x2), x1 is the row, x2 is the


column.
Cell 0 represents x1’x2’; Cell 1 represents x1’x2; etc. If a minterm is present in the
function, then a 1 is placed in the corresponding cell.
Two-Variable Map
• Any two adjacent cells in the map differ by ONLY one variable, which appears
complemented in one cell and uncomplemented in the other.
• Example:
m0 (= x1’x2’) is adjacent to m1 (= x1’x2) and m2 (= x1x2’) but NOT m3 (= x1x2)
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.
Group size must be in power of 2 (2, 4, 8, …)
• Handle “boundary wrap” for K-maps of 3 or more variables.
• Realize that answer may not be unique
2-Variable Map -- Example
• f(x1,x2) = x1’x2’+ x1’x2 + x1x2’
= m0 + m1 + m2
= x1’ + x2’
• 1s placed in K-map for specified
minterms m0, m1, m2
• Grouping (ORing) of 1s allows
simplification x2
• What (simpler) function is x1 0 1
represented by each dashed
rectangle? 0 1
• x1’ = m0 + m1
• x2’ = m0 + m2 0 1 1
• Note m0 covered twice 2 3

1 1 0
Example
2-variable Karnaugh maps are trivial but can be used to introduce the
methods you need to learn. The map for a 2-input OR gate looks like this:

A A
0 1
Y B
B
0 1
A
1 1 1
A B Y
0 0 0
0 1 1 B
1 0 1
1 1 1
A+B
Three-Variable Map
• 3 variables Karnaugh map

Cells = 23 = 8

BC
A 00 01 11 10
0 1 3 2
0
A B C A B C A BC A BC
4 5 7 6
1 AB C AB C ABC ABC
Three-Variable Map
yz
x 00 01 11 10
0 1 3 2
0 m0 m1 m3 m2
4 5 7 6
1 m4 m5 m7 m6

yz
x 00 01 11 10
0 1 3 2
0 m0 m1 m3 m2
4 5 7 6
1 m4 m5 m7 m6

-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)
Three-Variable Map
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
Simplification
• Enter minterms of the Boolean function into the map, then group terms
• Example: f(a,b,c) = a’c + abc + bc’
• Result: f(a,b,c) = a’c+ b
bc
a
1 1 1
1 1
1 1 1
1 1
More Examples
yz
X 00 01 11 10

• f1(x, y, z) = ∑ m(2,3,5,7) 0 1 1
1 1 1
◼ f1(x, y, z) = x’y + xz
• f2(x, y, z) = ∑ m (0,1,2,3,6)

1 1 1 1
◼f2(x, y, z) = x’+yz’
1
Alternative Solution Using K-Maps
x1 x2 x3 yz
Two different ways to specify the x
x 1 x002 01 11 10
same function f of three variables 0 0 0 m0 x3
0 00 1 01 3 11 210
0 0 1 m1 0 m0 m1 m3 m2
f(x1, x2, x3) = Σ (0, 2, 4, 5, 6, 7) 0 m0 m2 m6 m
0 1 0 m2 4 5 7 6 4
1 m4 m m m6
f(x1, x2, x3) = Π (1, 3) 0 1 1 m3 1 m1 m 53 m7 7 m5
1 0 0 m4
1 0 1 m5 (b) Karnaugh map
1 1 0 m6
1 1 1 m7

(a) Truth table


Alternative Solution Using K-Maps
x1 x2 x3
x yz
x
1 2
0 0 0 m0 x3
x 00
00 01 01 11 1110 10
0 0 1 m1 0 1 3 2
00 m 0m m 2 mm 6 mm3 4 m2
0 1 0 m2 0 1
4 5 7 6
0 1 1 m3 1 m1 m3 m m
1 m4 m5 7 m7 5 m6
1 0 0 m4
1 0 1 m5 (b) Karnaugh map
1 1 0 m6 yz
1 1 1 m7 x 00 01 11 10
0 1 3 2

(a) Truth table 0


4 5 7 6
1
Exercise
• Let us use Karnaugh map to simplify the follow function.
a. F1 = m0+m2+m3+m4+m5+m6+m7
b. F2 = m0+m1+m2+m5+m7
Exercise
Given the truth table, find the simplified SOP and POS form.

A B C Y
0 0 0 0
0 0 1 0
0 1 0 0
0 1 1 1
1 0 0 1
1 0 1 1
1 1 0 1
1 1 1 1
Exercise
• Design logic circuit from the follow timing diagram.

F
Example 3
Condition A
Condition B
Condition C
The output of the circuit can be expressed as
f = AB + AC + BC
The output of the circuit can be expressed as
f = AB + AC + BC
The output of the circuit can be expressed as
f = AB + AC + BC
Finally, we get

You might also like