# Decidability of language of TMs which accept only their Gödel number [duplicate]

I am trying to prove that $$L = \{\langle M \rangle \mid L(M) = \{\langle M \rangle \}\}$$ is undecidable, where $$\langle M \rangle$$ is the code of the TM $$M$$, and $$L(M)$$ the language recognized by $$M$$.

I think I can't use Rice's theorem, so I tried to find a reduction. The halting problem for example does not help me in this case. Do you have any idea how to prove it?

• Are you familiar with the recursion theorem? – Yuval Filmus Feb 1 '19 at 17:24
• unfortunately not – Marc Feb 1 '19 at 17:40

The recursion theorem states that if $$A(x,y)$$ is a two-input Turing machine then there is a Turing machine $$M$$ such that $$M(x) = A(x,\langle M \rangle)$$. Moreover, $$M$$ can be constructed from $$A$$ effectively (i.e., using an algorithm). Using this, we can reduce the halting problem to your problem. Given a Turing machine $$B$$ and an input $$z$$, construct a new Turing machine $$A(x,y)$$ which acts as follows:
• If $$x = y$$ then simulate $$B$$ on $$z$$.
Use the recursion theorem to construct a new machine $$M$$ that on input $$x$$ acts as follows:
• If $$x = \langle M \rangle$$ then simulate $$B$$ on $$z$$.
Then $$M \in L$$ iff $$B$$ accepts $$z$$.