Mapping Reductions
Context: FIT2014_MOC · the machinery for transporting decidability between languages — the tool that turns one hard-won result (FA-Empty is decidable) into many, and later turns one undecidable language into a whole family
Quick Revision
- 🎯 Objective: a computable with for every ➔ written , read ” is no harder than “.
- ⚠️ Key Constraint: direction is everything. To prove decidable, reduce to a known-decidable language. To prove undecidable, reduce a known-undecidable language to . Reversing the arrow proves nothing at all.
📝 Core
A mapping reduction from language to language is a computable function such that, for every , .
- Notation ➔ means there exists a mapping reduction from to ; the function itself is usually left anonymous once exhibited.
- What does and does not do ➔ is a translator, never a decider: it answers nothing, it only rewrites an instance of one problem as an instance of another preserving the Yes/No answer.
- Where the outputs land ➔ maps into and into . Into, not onto — need not be injective, surjective, or invertible, and may miss most of entirely.
- Reflexivity ➔ via the identity function, which is trivially computable.
- Totality is mandatory ➔ must be defined and halt on every , including junk inputs; a partial “reduction” that loops on malformed input is not computable and the transfer theorem collapses.
🧮 Proof Blueprint — the transfer theorem
Theorem. .
Corollary. .
Strategy ➔ exhibit a decider for built from and the decider for ; the corollary is then the contrapositive, obtained for free.
Derivation
Decider for , on input :
Both steps halt, so the composite halts on every input ⟹ it is a decider, and it Accepts exactly . Transitivity. : take , computable as a composition of computable functions, and
- Key move: the theorem spends only halting, so it transports decidability backwards along and undecidability forwards. Fix which of is the known one before choosing the direction of .
🔧 Worked reductions
Each is stated as: the function, then the iff chain that certifies it. The chain is the marked part of the answer — a bare function earns nothing.
- ➔ sort .
- Why it works ➔ sorting preserves letter frequencies and forces the canonical s-then-s shape, so the counting property survives and the ordering property is manufactured.
- ➔ scan left to right; if the previous letter was and the current is (i.e. the substring , impossible in HALF-AND-HALF) output the single string
)and stop; otherwise replace and .- Two failure routes, one target ➔ wrong order is caught by the guard, which emits a lone unmatched
); wrong counts survive to with . Both land outside PARENTHESES, and , which is balanced (see Writing a CFG).
- Two failure routes, one target ➔ wrong order is caught by the guard, which emits a lone unmatched
- ➔ compose the two above; justified by transitivity, no new construction needed.
- ➔ given : vertices states of ; every transition becomes a directed edge ; add a new vertex and an edge from every Final State ; set the Start State’s vertex; output .
- What the new sink buys ➔ collapsing many Final States into the single target converts “reaches some Final State” into the standard single-pair reachability question (Walks, Trails, and Paths); letters are discarded because emptiness ignores which word is read.
- ➔ the FA for ; the symmetric difference is empty iff the languages agree. This is the Lecture-20 decidability proof re-read as a reduction — same construction, now named.
🚫 Reducing from a decidable language is worthless
Theorem. If is decidable and is any language except and , then .
- Construction ➔ let decide ; pick a fixed and a fixed (both exist precisely because ). Define if accepts , else .
- The lecture’s joke instance ➔ by outputting on a palindrome and otherwise.
- ⚡ Key Constraint: the reduction has already decided inside — so it transfers nothing and proves nothing. Reductions are only informative when the source language is not known to be decidable, which is why every serious use runs from an undecidable language.
- Where the two excluded cases go ➔ has no and has no , so a constant-valued cannot separate the two answers.
⚠️ Common Mistakes
- 💡 Reducing the wrong way ➔ the single biggest mark-killer. pushes hardness up and easiness down: it lets you conclude ” decidable decidable” and ” undecidable undecidable” — never the reverse of either.
- 💡 Proving only one direction ➔ is half a reduction. The converse forbids from mapping a No-instance onto a Yes-instance; without it the composite decider accepts too much.
- 💡 Treating as a decider ➔ outputs a string, not a verdict, and is not allowed to consult an oracle for . If your needs to know whether , you have assumed what you are proving.
- 💡 Forgetting must handle malformed input ➔ every needs an image, including strings that encode no object; map them to any fixed non-member of .
- 💡 Assuming is symmetric ➔ it is reflexive and transitive (a preorder), not an equivalence. says nothing about .
🧠 Active Recall
You want to prove that a new language is undecidable. Which language do you reduce, and in which direction — and why does the other direction fail?
Answer
- Short answer: reduce a known-undecidable to , i.e. build with , giving ; the corollary then forces undecidable.
- Why: A decider for would manufacture one for ➔ compute , run it, echo. Since none exists for , none can exist for . The reverse direction would only say ” is no harder than something hard” — compatible with being trivially decidable, so it carries no information.
Why does the theorem "every decidable reduces to every non-trivial " not make reducibility useless?
Answer
- Short answer: because that reduction smuggles a decider for inside . It is only available when was already decidable, so it transports no information — the transfer theorem still holds, it just tells you something you knew.
- Why: The content of lies in what is ➔ reductions become informative exactly when the source is not known to be decidable, so the conclusion ” is undecidable” is genuinely new. It also shows is far too coarse to compare decidable languages — separating those needs a resource bound, which is the complexity material still to come.