← Student tools · Problem 8 · Lecture 6 · Round 1 (30 pts)

EQTM is undecidable · mapping reduction

From ⟨M, w⟩ produce ⟨M1, M2⟩ such that M1 ≡ M2 iff M does not accept w. A mapping reduction ATMm ¬EQTM.

CLO-2R1·30 ptsL6
🔊 Listen

EQTM = {⟨M1, M2⟩ : L(M1) = L(M2)}. We want to show EQTM is undecidable by reducing ATM to it. The trick is to pick one fixed machine (M1) and engineer the other (M2) so the equality question turns into the ATM question in disguise.

Construction · the reduction function f(⟨M, w⟩)

M1: on every input x, reject. Therefore L(M1) = ∅.

M2: on input x, ignore x; simulate M on w; accept iff M accepts w. Therefore L(M2) = Σ* if M accepts w, and L(M2) = ∅ otherwise.

Output: f(⟨M, w⟩) = ⟨M1, M2⟩.

Why this works: M1 accepts the empty language, no matter what. M2 either accepts every string or accepts no string, depending on whether M accepts w. So L(M1) = L(M2) exactly when L(M2) = ∅, which is exactly when M does not accept w.

🔊 Listen
f : ⟨M, w⟩ ↦ ⟨M₁, M₂⟩ · A_TM ≤_m ¬EQ_TM ⟨M, w⟩ A_TM instance "Does M accept w?" f M₁ on input x: reject L(M₁) = ∅ M₂ on input x: ignore x; simulate M on w; accept iff M accepts L(M₂) = Σ* or ∅ ⟨M₁, M₂⟩ EQ_TM instance L(M₁) = L(M₂) ⇔ L(M₂) = ∅ ⇔ M does NOT accept w ↳ ¬A_TM in disguise
🔊 Listen

Let M be the TM that on input y, halts and accepts if y starts with a 1, otherwise loops. Pick w = "01".

Now flip it: let w = "1xyz". Then M accepts w. M2 on every input runs M on "1xyz", accepts, so L(M2) = Σ*. L(M1) = ∅ ≠ Σ* = L(M2), so ⟨M1, M2⟩ ∉ EQTM. Contract holds again.

🔊 Listen
Build M1, M2, compare languages Auto-plays
🔊 Listen

A mapping (many-one) reduction is a single computable function f, no loops, no oracle calls. Our f takes the encoding ⟨M, w⟩ and outputs the encoding ⟨M1, M2⟩. The construction is purely syntactic — write down two new TM descriptions. No simulation happens during the reduction itself; the simulation only happens later, if and when M2 actually runs.

Because the reduction is many-one, undecidability transfers cleanly: if EQTM were decidable, composing with f would give a decider for ¬ATM and hence for ATM — contradiction. The same composition would not work for a Turing reduction without extra care.

🔊 Listen
🔊 Listen
🔊 Listen

Sipser: Theorem 5.4 and §5.3 on mapping reductions. Lecture notes: Module 2 slide 4 (reductions to HALTTM) and Module 3 slide 1 (the general reduction template). Companion problems: P5 (HALTTM), P6 (ETM), P14 (Rice's theorem — generalises this kind of argument to every non-trivial language property).