PROJECTENGRAM

KARNAUGH MAP

Karnaugh Map

Tags: #◇Computer Science #◇CSARCH1 #◇Problem Solving #◇M3


◇Overview

This sub-module discusses how to minimize Boolean functions using the Karnaugh Map.
The objectives are:

  • Learn how to minimize Boolean functions using Karnaugh Map.
  • Learn how to minimize Boolean functions with don’t care conditions using Karnaugh Map.

◇Karnaugh Map

A Karnaugh Map (K-map) is represented by 2m2^m squares where mm is the number of variables, and each of these squares represents a corresponding minterm or maxterm. It is a modified truth table intended to allow minimal SOP (Sum of Products) and POS (Product of Sums) expressions to be obtained by visual inspection.

Rules for Implementing K-Map

  1. Groupings should be a factor of 2n2^n (1, 2, 4, 8, 16, etc.), where n=0,1,…,mn = 0, 1, \dots, m.
  2. Groupings should either be horizontal or vertical only. No diagonal groupings.
  3. For each group, cover as many 1’s (for SOP) or 0’s (for POS) as possible since it will minimize the number of literals.
  4. For each group, there should be at least one exclusive minterm or maxterm (a cell not covered by any other group).
  5. You are allowed to use a minterm or a maxterm more than once if it would make a group bigger.
  6. Each group corresponds to one product or sum term.
  7. Remove redundant groups (a group is redundant when all its entries are already covered by other essential groups).

Number of Variables

  • 2-Variable K-Map: 4 squares. Columns/Rows typically A, B.
  • 3-Variable K-Map: 8 squares. Example headers using gray code (00, 01, 11, 10) to ensure adjacent columns differ by only one bit.
  • 4-Variable K-Map: 16 squares.
  • 5-Variable K-Map: 32 squares. Often split into two 16-square 4-variable K-maps representing A=0 and A=1.
  • 6-Variable K-Map: 64 squares. Grouped as four 4-variable maps representing AB=00, AB=01, AB=10, AB=11.

Don't Care Conditions

  • Don’t care conditions (represented by X or d) can be treated as either 0 or 1.
  • They can be included in groups to make K-map groups bigger and further simplify the expression.
  • Do not use them (i.e., just treat them as 0s) if they do not help in forming larger groups.

◇Worked Examples

  • F(A,B)=Σm(0,2)F(A,B) = \Sigma m(0,2) simplifies to B′B'
  • F(A,B,C)=Σm(0,1,2,5,6,7)F(A,B,C) = \Sigma m(0,1,2,5,6,7) simplifies to A′B′+AC+BC′A'B' + AC + BC'
  • F(A,B,C,D)=Σm(0,2,3,7,8,10,11,13)F(A,B,C,D) = \Sigma m(0,2,3,7,8,10,11,13) simplifies to B′C+B′D′+A′CD+ABC′DB'C + B'D' + A'CD + ABC'D
  • With Don't Care: F(A,B,C,D)=Σm(1,3,7,11,15)F(A,B,C,D) = \Sigma m(1,3,7,11,15) with d(A,B,C,D)=Σm(0,2,5)d(A,B,C,D) = \Sigma m(0,2,5) simplifies to A′D+CDA'D + CD

◇References & Navigation

CONFIRMATION // 理解度の確認

ACTIVE RECALL VERIFICATION

Select an answer to verify conceptual comprehension and reveal the technical rationale.

Q1

In a Karnaugh Map, the number of squares is given by 2^m. What does 'm' represent?

Q2

When grouping cells in a K-map, the number of cells in a group must be a factor of:

Q3

What is the shape or direction of valid groupings in a K-map?

Q4

Why is it beneficial to cover as many 1s (or 0s) as possible in a single K-map group?

Q5

When is a group in a K-map considered "redundant"?

Q6

Can a single minterm or maxterm be used more than once in K-map groupings?

Q7

For a 3-variable K-map representing F(x,y,z), what are the column headers typically labeled as if using gray code?

Q8

What is the primary purpose of a "don't care" condition in a K-map?

Q9

In a 4-variable K-map, how many cells does the map contain?

Q10

Which of the following is NOT a valid grouping size in a K-map?