A mapping reduction from a problem to a problem is a computable function such that .
means is (mapping) reducible to .
Theorem: if and is decidable, then is also decidable
Proof:
- Suppose that and is decidable.
- From (i), there is some computable function such that
- From (ii) there is some sound, complete, and terminating machine such that
- Hence, we can construct a sound, complete, and terminating algorithm for . It follows that: As required.
Theorem: The Accepting Problem is undecidable
Proof:
- Since is undecidable, it is sufficient to show that .
- Given any input machine , we construct a new machine prime that accepts when accepts and rejects, or otherwise when it does not terminate.
Hence we have that . - Hence, Therefore our computable function for our reduction is given by Which we formalise as:
Theorem: The non-Emptiness Problem is undecidable
Proof:
- Since is undecidable, it is sufficient to show that
- Given any input machine and input word , we construct a new machine as:
\text{Language}(M_w) \neq \emptyset &= 1 \Leftrightarrow M(w) = 1 \end{aligned}\langle code(M), w \rangle \in A_{TM} \Leftrightarrow code(M_w) \in E_{TM}f(\langle code(M), w \rangle) = code(M_w)f(u) = \begin{cases} code(M_w) &\text{if } u = \langle code(M), w \rangle \ \epsilon &\text{otherwise} \end{cases}$$