You are on page 1of 12

Chapter 4 Boolean Algebra and Logic Simplification

The Karnaugh Map:


 Karnaugh Map is a systematic method for simplifying Boolean expressions
 In order to minimize through Karnaugh maps, expressions must be in standard SOP
or standard POS form
 Karnaugh maps similar to a truth table because it presents all the possible values of
input variables and the resulting output for each value
 Karnaugh Map
- Is an array of cells
- each cell represent the binary value for a product/sum term
- the cells represents a binary value that a term in expression could take
- the number of cells is equal to the number of input combinations (as in truth
tables)
- Karnaugh maps can be used with expression with two, three, four and five
variables
- most commonly, Karnaugh maps are used with 3-variable-domain expressions and
4-variable-domain expressions
- thus Karnaugh maps are usually depicted as follow:

Cell Adjacency:
1
Chapter 4 Boolean Algebra and Logic Simplification

 cells are arranged in Karnaugh maps so that there is only a single-variable change
between adjacent cells
 adjacent cells: are those that differ by only one variable
 non-adjacent cells: are those that differ by more than one variable
 physical cell arrangement:
- each cell is adjacent to the cells that are immediately next to it on any of its four
sides
- a cell is not adjacent to the cells that diagonally touch any of its corners
- wrap-around adjacency:
o the cells in the top row are adjacent to the corresponding cells in the
bottom row
o the cells in the outer left column are adjacent to the corresponding cells in
the outer right column

Karnaugh Map SOP Minimization:


 Note: if an SOP expression is not in standard form then we first must convert it to
standard SOP form then we can use Karnaugh map
 Mapping Standard SOP expression to Karnaugh Map:
- Step 1: determine the binary value for each product term in the standard SOP
expression
- Step 2: for each evaluated, place 1 in the cell that have the same binary value as
the term
 the cells that don’t have ones are those cells for which the expression is 0

___________________________________________________________________________

2
Chapter 4 Boolean Algebra and Logic Simplification

Example 4.16:

___________________________________________________________________________

 After mapping the standard SOP expression to Karnaugh map, the simplification
process consist of two steps:
- Grouping the 1s
- Determining the minimum SOP expression from the map
 Grouping the 1s:
- When grouping the 1s we must try to maximize the size of each group and to
minimize the number of groups
- Grouping is performed according to the following rules:
o A group must contain either 1,2,4,8,or 16 cells, which are all powers of two.
In the case of a 3 –variable map, cells is the maximum group.
o Each cell in the group do not have to be adjacent to one or more cells in
that same group, but all cells in the group do not have to be adjacent to
each other.
o Always include the largest possible number of 1s in a group in accordance
with rule 1.

3
Chapter 4 Boolean Algebra and Logic Simplification

o Each 1 on the map must be included in at least one group. The 1s already in
a group can be included in another group as long as the overlapping groups
include noncommon 1s.

___________________________________________________________________________

Example 4.17:

Group the 1s in each of the following Karnaugh maps:

Solution:

___________________________________________________________________________

 Determining the minimum SOP expression from the Map:


- Group the cells that have 1s. Each group of cells containing 1s creates on product
term composed of all variables that occur in only one from (either
uncomplemented or complemented) within the group. Variables that occur both
uncomplemented and complemented within the group are eliminated. These are
called contradictory variables.
- Determine the minimum product term for each group.
a. for a 3- variable map:
1. A 1-cell group yields a 3-variable product term
2. A 2-cell group yields a 2-variable product term

4
Chapter 4 Boolean Algebra and Logic Simplification

3. A 4-cell group yields a 1-variable term


4. An 8- cell group yields a value of 1 for the expression
b. For a 4-variable map:
1. A 1-cell group yields a 4-variable product term
2. A 2-cell group yields a 3-variable product term
3. A 4-cell group yields a 2-variable product term
4. An 8- cell group yields a 1- variable term
5. A 16- cell group yields a value of 1 for the expression
- When all the minimum product terms are derived from the Karnaugh map, they
are summed to form the minimum SOP expression.

___________________________________________________________________________

Example 4.18:

Determine the minimum SOP expression from the following Karnaugh map

Solution:

___________________________________________________________________________

Example 4.19:

Use.....

Solution:

5
Chapter 4 Boolean Algebra and Logic Simplification

___________________________________________________________________________

Example 4.20:

Solution:

___________________________________________________________________________

 Mapping Directly From a Truth Table:


- For each 1 in the truth table output, place 1 in the cell that has the same input
combination value

6
Chapter 4 Boolean Algebra and Logic Simplification

 “Don’t Care” Conditions:


- In some circuits there are situations (states), where some input combination will
never occur(or it should never occur)
- For example: the input combinations 1010, 1011,1100,1101,1110,1111 for BCD
circuit
- For such input combinations it really doesn’t matter whether 0 or 1 will appear on
the output since the input combination will never actually occur
- So we say that we “don’t care” what is the output of the circuit for these input
combinations
- for such input combinations we assign X “don’t care” to the output column in the
truth table
- During the simplification process we can take advantage of such don’t care
outputs so we can chose to treat them as 0 or 1 depending on what would enable
us to perform better simplification
o So in Karnaugh map we place X in the cells that correspond to the input
combination that will never occur
o When grouping the 1s we can chose to treat X as 1 in order to generate
bigger groups or we can treat them as 0 if they cannot be used to
advantage
o Recall that the larger the groups are, the simpler the resulting expression
will be

___________________________________________________________________________

Example 4.21:

7
Chapter 4 Boolean Algebra and Logic Simplification

___________________________________________________________________________

Karnaugh Map POS Minimization:


 Note: if an POS expression is not in standard form then we first must convert it to
standard POS form then we can use Karnaugh map
 Mapping Standard POS expression to Karnaugh Map:
- Step 1: determine the binary value for each sum term in the standard POS
expression
- Step 2: for each evaluated term, place 0 in the cell that have the same binary
value as the term
 the cells that don’t have 0s are those cells for which the expression is 1

___________________________________________________________________________

Example 4.22:

8
Chapter 4 Boolean Algebra and Logic Simplification

___________________________________________________________________________

 the process of minimizing POS expression is basically the same as that foe minimizing
SOP expressions except that you group 0s to produce minimum sum terms instead of
grouping 1s to produce minimum product terms. And the rules for grouping 0s are
the same as for grouping 1s

___________________________________________________________________________

Example 4.23:

9
Chapter 4 Boolean Algebra and Logic Simplification

___________________________________________________________________________

Example 4.24:

Solution:

___________________________________________________________________________

 Mapping Directly From a Truth Table:


- For each 0 in the truth table output, place 0 in the cell that has the same input
combination value
 Converting Between POS and SOP Using Karnaugh Map:

10
Chapter 4 Boolean Algebra and Logic Simplification

- After an expression (whether SOP or POS) is already mapped it is very easy to


convert the expression to the other type
- Such a practice is useful in order to compare both minimum forms of the
expression in order to determine which form would produce fewer gates
- For POS expressions, all the cells that don’t contain 0s contain 1s from which the
SOP expression can be derived
- For SOP expressions, all the cells that don’t contain 1s contain 0s from which the
POS expression can be derived

___________________________________________________________________________

Example 4.24:

Solution:

11
Chapter 4 Boolean Algebra and Logic Simplification

___________________________________________________________________________

12

You might also like