What Do Students Get Wrong About Don't-Cares in K-Maps?

Mostly, they treat don't-cares as compulsory 1s, or ignore them, when the rule is that each one may be taken as 1 or 0, whichever gives larger groups. In the example below, using them freely shrinks F from 5 literals to 4, while forcing them all to 1 inflates it to 6. Two equally minimal answers can also disagree on the don't-care inputs themselves, which matters if those inputs ever occur.

What you'll learn

  • What a don't-care means and when a question will give you one
  • The four mistakes that turn a minimal answer into a wrong or oversized one
  • A full worked example, F = Σm(1, 3, 7, 11, 15) + d(0, 2, 5), checked by brute-force search
  • Why the same function can have two correct minimal expressions
  • How to tell whether a don't-care group is helping or just adding a term

What does a don't-care actually mean?

A don't-care, written X or d, marks an input combination whose output the designer does not need to specify. Usually that is because the input can never occur, like the six unused codes 1010 to 1111 in a BCD digit, or because the output is ignored whenever it does occur. In a K-map an X cell may be included in a group or left out, independently for every group you draw, and you choose whatever gives the fewest and largest groups. It is never required to be covered, and it never forbids a group the way a 0 does.

Notation used in this post

A is the most significant bit, so minterm 5 is ABCD = 0101. Rows of the K-map are AB and columns are CD, both in Gray-code order (00, 01, 11, 10), which keeps neighbouring cells one bit apart. A prime after a variable means its complement, so A' is NOT A. Cost is counted in literals, the number of variable appearances in the sum of products.

Worked example: F = Σm(1, 3, 7, 11, 15) + d(0, 2, 5)

K-map for F grouped as CD plus A-bar B-barK-map of F with rows AB and columns CD in Gray-code order. The 1s are minterms 1, 3, 7, 11 and 15; don't-cares are 0, 2 and 5. One group is the CD column of four cells. The other is the whole top row, AB equals 00, which uses don't-cares 0 and 2 and gives A-bar B-bar.ABCD0001111000011110X11X0X1000100010F = CD + A'B'uses don't-cares 0 and 2 as 1s
The K-map of F. The CD column is a group of four 1s. The top row (AB = 00) becomes a group of four by taking don't-cares 0 and 2 as 1s, giving A'B'.
  • Plot the 1s at minterms 1, 3, 7, 11 and 15, the Xs at 0, 2 and 5, and 0s everywhere else.
  • Minterms 3, 7, 15 and 11 fill the CD column: one group of four, giving CD (2 literals).
  • Only minterm 1 is left uncovered. On its own with its neighbour 3 it would be A'B'D (3 literals).
  • Take don't-cares 0 and 2 as 1s and the whole top row becomes a group of four: A'B' (2 literals).
  • Result: F = CD + A'B', 4 literals. Don't-care 5 was not needed for this grouping, so it is left as 0.

Is there only one minimal answer?

The same K-map grouped as CD plus A-bar DK-map of F with rows AB and columns CD in Gray-code order. The 1s are minterms 1, 3, 7, 11 and 15; don't-cares are 0, 2 and 5. One group is the CD column of four cells. The other is a square of four cells in rows 00 and 01 and columns 01 and 11, which uses don't-care 5 and gives A-bar D.ABCD0001111000011110X11X0X1000100010F = CD + A'Duses don't-care 5 as a 1
The same function grouped differently: minterms 1, 3, 7 and don't-care 5 form a square, A'D. F = CD + A'D is also 4 literals.

No. A brute-force search over every product term that avoids the 0 cells finds exactly two covers with 4 literals: CD + A'B' and CD + A'D. Either is a correct minimal answer. In a multiple-choice question you may see only one of them among the options, so check each option by expanding it rather than looking for your own grouping. The two circuits are not identical, though: they agree on all 13 specified inputs but disagree on the three don't-care inputs.

What each minimal circuit outputs on the don't-care inputsA table. For input 0000, CD plus A-bar B-bar outputs 1 and CD plus A-bar D outputs 0. For input 0010, the first outputs 1 and the second 0. For input 0101, the first outputs 0 and the second 1. Both agree on every input where F is specified.mintermABCDCD+A'B'CD+A'D000001020010105010101Both give F on all 13 specified inputs
On don't-care inputs 0 and 2, CD + A'B' outputs 1 and CD + A'D outputs 0; on input 5 it is the other way round.

The four mistakes

Each of these was checked against the same function by brute force.

Mistake 1: treating every don't-care as a 1 you must cover

If you insist on covering minterms 0, 2 and 5 as well as the 1s, the best you can do is A'B' + A'D + CD: three terms and 6 literals, a term more than necessary. Don't-cares are optional. Include one only when it enlarges a group that is needed for some real 1.

Mistake 2: ignoring the don't-cares completely

Treating every X as 0 is safe but wasteful. The minimal answer then is CD + A'B'D, 5 literals, because minterm 1 can only pair with minterm 3. The don't-cares were given to you to make the circuit smaller; leaving them out usually loses a literal or a whole term.

Mistake 3: drawing a group made only of don't-cares

A group that contains no 1 adds a term to the expression and covers nothing that needed covering. Here, grouping 0 and 2 alone gives A'B'D', which is pure cost. Every group in a minimal answer must contain at least one 1 that no other group already covers, or be needed to cover one.

Mistake 4: assuming the circuit outputs 0 (or 1) on don't-care inputs

Once you have chosen your groups, the circuit's output on every don't-care input is fixed by those groups, and it differs between the two minimal answers above. That is harmless only if the don't-care inputs truly never occur. If an unused state could be reached after a glitch or at power-up, as in a counter, check what your minimised logic does there instead of assuming.

Common mistakes

  • Covering every X as if it were a 1, which adds unnecessary terms.
  • Ignoring the Xs and settling for a larger expression.
  • Grouping Xs on their own, which adds a term that covers no 1.
  • Believing there is only one correct minimal answer and rejecting a valid alternative.
  • Assuming a minimised circuit outputs 0 on don't-care inputs, when it outputs whatever the groups give.

Check your understanding

  • Q1. Minimise J = Σm(8, 9, 10) + d(11). Answer: J = AB' (2 literals), using don't-care 11. Without it the best is AB'C' + AB'D', 6 literals.
  • Q2. Minimise G = Σm(0, 4, 8, 12) + d(2, 6). Should don't-cares 2 and 6 be used? Answer: No. G = C'D' covers all four 1s on its own; adding 2 and 6 would only add a term.
  • Q3. In F = CD + A'D, what is the output for input 0000? Answer: 0, since neither CD nor A'D is true when every input is 0. In CD + A'B' the same input gives 1.

Related

Official source

Last verified

The GATE 2027 EC syllabus lists minimisation of functions using Boolean identities and Karnaugh maps under Section 5, Digital Circuits (checked against the official PDF from IIT Madras on 10 October 2026). Every minimal expression here was confirmed by an exhaustive search over all product terms in code.