1.4.3 - Karnaugh maps

1.4.3 - Karnaugh maps

A Karnaugh map places truth-table results so that adjacent cells differ in one input. You will use that arrangement to find groups, remove changing variables, and derive a simpler expression with the same outputs.

Putting truth-table results into Gray order

A Karnaugh map is a rearranged truth table: each cell represents one input combination and contains that combination's output.

For two inputs, put A=0,1A=0,1 along the rows and B=0,1B=0,1 along the columns. The four cells represent 00,01,10,11. For more inputs, combine variables in a row or column label, but use Gray order: 00,01,11,1000,01,11,10. Binary order 00,01,10,1100,01,10,11 would place 01 next to 10, changing both bits and breaking the grouping rule.

Karnaugh-map adjacency

Adjacent cells represent input combinations differing in exactly one bit. They meet horizontally or vertically, including across opposite edges of a Gray-ordered map. A diagonal pair through the interior is not adjacent.

For three inputs, use rows A=0,1A=0,1 and columns BC=00,01,11,10BC=00,01,11,10. For example, consider this truth table:

AABBCCFF
0000
0011
0100
0111
1000
1010
1101
1111

The corresponding map is:

AA / BCBC00011110
00110
10011

Notice that the 010 row goes into the final column of the top row, while 011 goes into the preceding column. Copy by the input labels, not by blindly placing the original output sequence from left to right. Four inputs need a 4-by-4 map, usually ABAB rows and CDCD columns, both in Gray order. The cell AB=10,CD=01AB=10,CD=01 represents A=1,B=0,C=0,D=1A=1,B=0,C=0,D=1.

Turning groups of ones into terms

To obtain a sum-of-products expression, group output-1 cells and write one AND term for each group, then OR those terms together.

A valid group is a rectangular block of 1,2,4,81,2,4,8 or another power-of-two number of cells. Every included cell must be 1. An L-shaped group or a group of three cells cannot cancel variables in the required way.

Implicant

A term whose true input combinations are all output-1 cases of the function. Each valid group of ones gives an implicant by retaining the variables that stay constant throughout the group.

For each group, inspect every input variable. Keep a variable if it has the same value in every cell: write the ordinary variable if that value is 1, or its negation if that value is 0. Remove any variable that changes. A pair removes one variable; a four-cell group removes two; an eight-cell group removes three.

In the three-input map above, group the top-row ones in columns 01 and 11. Across those cells, A=0A=0 and C=1C=1 stay fixed while BB changes, giving ¬A∧C\neg A\land C. Group the bottom-row ones in columns 11 and 10. Here A=1,B=1A=1,B=1 stay fixed while CC changes, giving A∧BA\land B. Hence

F≡(¬A∧C)∨(A∧B).F\equiv(\neg A\land C)\lor(A\land B).

The cancellation has an algebraic explanation. The top pair originally represents (¬A∧¬B∧C)∨(¬A∧B∧C)(\neg A\land\neg B\land C)\lor(\neg A\land B\land C). Factoring gives ¬A∧C∧(¬B∨B)\neg A\land C\land(\neg B\lor B), which reduces to ¬A∧C\neg A\land C. The map exposes exactly the complementary-variable pairing used in Boolean algebra.

Cover every one without including a zero

Prefer large valid groups, because they retain fewer variables. Every 1 must be covered at least once; no 0 may be covered. An isolated 1 needs a singleton group retaining all inputs. If the entire map is 1, the expression is simply 1; if it contains no 1s, the expression is 0.

Using wrapping and overlapping groups

Opposite edges of a Karnaugh map are adjacent because the last and first Gray labels also differ in one bit.

Continue this lesson.

You’re previewing NovaLearn without an account. Create a free account to read the rest.

Create free account