Skip to content
BetterDL

K-map grouping rules

Also called: grouping rules, rules for grouping, K-map rules, Karnaugh map rules

The rules for circling K-map groups: only 1s and don't-cares, power-of-two sizes, rectangles only, edges wrap, and as few, as large groups as possible.

Every correct K-map solution follows the same short list of grouping rules.

What makes a group legal:

  • It contains only 1s and don't-cares. Never a 0.
  • Its size is a power of two: 1, 2, 4, 8 or 16 (k map group size).
  • It is a rectangle. No L-shapes, zigzags or diagonals.
  • It may cross an edge, because the map wraps.

What makes a set of groups minimal:

Don't-cares are optional: include an X only when it makes a group bigger, and never circle a group made only of X's.

Why rectangles? A rectangle of 2ᵏ cells is exactly the set of cells where some variables are fixed and the rest are free, which is what a product term describes. Any other shape matches no single term.

A\BC00011110
0
0m0
0m1
0m3
0m2
1
1m4
1m5
1m7
0m6

Worked examples

Example

Legal or not?

In a 3-variable map, assume each listed cell is a 1. Which sets can be one group?

  1. 1.

    m0, m1, m3: 3 cells. Not a power of two, so no.

  2. 2.

    m0, m5: diagonal (000 and 101 differ in A and C), so no.

  3. 3.

    m1, m3, m5, m7: a 2×2 square in columns 01 and 11. Yes: C stays 1, so it reads .

  4. 4.

    m0, m2, m4, m6: the two end columns, joined by the wrap. Yes: C stays 0, so it reads .

Example

Three 1s in an L

F = Σm(4, 5, 7), shown above.

  1. 1.

    The three cells can't form one group.

  2. 2.

    m5 touches both others, so use it twice: m4 m5 → and m5 m7 → .

  3. 3.

    F = .

Common mistakes

  • Taking in a 0 to complete a shape. Even one 0 makes the group wrong.

  • Avoiding overlap and leaving a 1 stuck in a smaller group than necessary.

  • Treating don't-cares as 1s that must be covered.

Practice K-map grouping rules

Interactive questions with instant feedback and a worked solution for every wrong answer.

Learn it step by step

K-map grouping rules is taught in Karnaugh Maps.