Proving a Language Non-Regular
Context: FIT2014_MOC · the exam-standard use of the Pumping Lemma · two routes: pump a well-chosen word, or derive a contradiction from closure Problem it solves: given a language, prove it is not regular.
Quick Revision
- 🎯 Trigger: a language that seems to need counting or matching unboundedly ➔ assume regular, get , choose a word, pump, contradict.
- ⚡ Key Constraint: choose so that leaves only ONE case. A lazy choice forces a three-case slog; a good choice makes the proof four lines.
📐 Route 1 — the Pumping Lemma recipe
- Assume is regular. By Kleene’s Theorem it is recognised by some FA; let be its number of states.
- Choose a suitable word with — you get this choice, so choose to make step 4 easy.
- Consider any with , and . (You must handle every such decomposition.)
- Exhibit an with (usually , sometimes ).
- Contradiction with the Pumping Lemma ⟹ is not regular.
🥇 Worked example — HALF-AND-HALF
The naive choice forces three cases:
| Case | is… | Why |
|---|---|---|
| 1 | all s | more s than s (since ) |
| 2 | all s | more s than s |
| 3 | contains an | has two occurrences of , impossible in |
The good choice leaves one case:
- The lesson ➔ the naive proof never used . Exploiting it is what collapses three cases into one.
🥈 Worked example — PALINDROME
- Choose (a palindrome, and ).
- Constraint bites ➔ forces to sit inside the first block of s, so is all s with .
- Pump ➔ has leading s but still trailing s, so the solitary now sits more than half-way along ⟹ not a palindrome ⟹ . Contradiction.
📐 Route 2 — the closure argument (often much faster)
If combined with a known regular language via a closure-preserving operation yields a known non-regular language, then cannot be regular.
Worked example — EQUAL words with equally many s and s:
- When to reach for it ➔ when the language is “close to” a known non-regular one; intersecting with a simple regex like often strips away the noise.
✍️ Practice
Practice: Prove is not regular.
Reference solution
- Assume regular; let be the number of states of an accepting FA.
- Choose (indeed ), and .
- Any with puts inside the leading s, with .
- Pump down with : has leading s but still trailing s, so the -count is no longer strictly greater ⟹ .
- Contradiction ⟹ is not regular.
- Key move: here (deleting the loop) is the natural choice — pumping down breaks a strict inequality more cleanly than pumping up.
⚠️ Common Mistakes
- 💡 You choose ; you do NOT choose ➔ the lemma says there exist ; to contradict it you must defeat every valid decomposition. Picking a convenient yourself is the most common invalid proof.
- 💡 Always use ➔ it is what pins inside the first letters. A proof that ignores it needs far more cases (and often stalls).
- 💡 is a habit, not a rule ➔ for strict-inequality languages, pumping down to is usually the shorter kill.
- 💡 You cannot prove regularity this way ➔ to show a language is regular, build a regex or FA instead (Pumping Lemma for Regular Languages is a one-way tool).
🧠 Active Recall
Why does choosing beat for HALF-AND-HALF?
Answer
- Short answer: with , the condition confines to the first letters — all s — so only one case survives ( is a non-empty block of s) and immediately has too many s.
- Why: Exploit the length constraint ➔ the shorter word lets straddle the / boundary, forcing three separate cases. Choosing so that the first letters are homogeneous is the general trick.
Give the closure-based proof that EQUAL is non-regular, and say why it avoids pumping.
Answer
- Short answer: . Regular languages are closed under intersection and is regular, so if EQUAL were regular then HALF-AND-HALF would be — contradicting its known non-regularity.
- Why: Reduction to a known result ➔ the pumping work is done once (on HALF-AND-HALF) and then reused; intersecting with a regular language filters EQUAL down to the already-settled case, which is far quicker than a fresh case analysis.