CleverSphere

Minimising a DFA

Two states are equivalent if no word tells them apart. The minimal automaton merges such states.

Rules

  • Remove unreachable states
  • Start: accepting against non-accepting
  • Split blocks when transitions lead to different blocks
  • Repeat until nothing changes

Your turn

Three problems on this topic. The software checks your answer exactly.

  1. 1 · Minimise a DFA
  2. 2
  3. 3

Minimise the automaton. How many states does the minimal DFA have?

δab
→ *q0q3q2
q1q4q4
*q2q4q1
q3q3q0
q4q1q1

Number of states

Worked example

Minimise the automaton. How many states does the minimal DFA have?

δab
→ *q0q0q3
*q1q2q4
*q2q1q4
*q3q2q2
*q4q5q0
q5q3q1

Worked solution

  1. 1First split accepting and non-accepting states, then refine the blocks until all transitions lead to the same block.
  2. 2Minimal automaton:
  3. 3→ *q0: a→q0, b→q1
  4. 4*q1: a→q2, b→q2
  5. 5*q2: a→q2, b→q3
  6. 6*q3: a→q4, b→q0
  7. 7q4: a→q1, b→q2

Typical mistake: Remove unreachable states first, or too many blocks remain.

Common questions

Is the minimal DFA unique?

Yes, up to the names of the states.

Related

More topics