Giorgi Japaridze Theory of Computability Decidability Chapter 4
Giorgi Japaridze Theory of Computability Decidability Chapter 4
4. 1. a Giorgi Japaridze Theory of Computability Examples of decidable languages Decidable: • {1, 3, 5} • • {x | x is even} • {x | x is a perfect square} • {x | x 2 -10 x = 0} • {x | x=y*z for some integers y, z>1 (i. e. x is not prime)} • {x | x is a prime (i. e. x is not divisible by anything except 1 and itself)} • {<G> | G is a connected graph} • {<P> | P is a one-variable polynomial expression with an integral root} Undecidable: • {<P> | P is a two-variable polynomial expression with an integral root}
4. 2. a Giorgi Japaridze Theory of Computability The universal Turing machine Let ATM = {<M, w> | M is a TM and M accepts string w} ATM is misleadingly called the halting problem in the textbook. Instead, we will call it the acceptance problem. Theorem: ATM is Turing-recognizable. Proof idea. The following TM U, called the universal TM, recognizes ATM: U = “On input <M, w>, where M is a TM and w is a string: 1. Simulate M on input w. 2. If M ever enters its accept state, accept; if M ever enters its reject state, reject. ” Does U also decide ATM?
4. 2. b. 1 Giorgi Japaridze Theory of Computability ATM is undecidable Theorem 4. 11: ATM is undecidable. Proof idea. Suppose, for a contradiction, that ATM is decidable. That is, there is a TM H that decides ATM. Thus, that machine H behaves as follows: accept if M accepts w H(<M, w>) = reject if M does not accept w Using H as a subroutine, we can construct the following TM D: D = “On input <M>, where M is a TM: 1. Run H on input <M, <M>>. 2. Do the opposite of what H does. That is, if H accepts, reject, and if H rejects, accept. ” Thus, D(<M>) = accept if M does not accept <M> reject if M accepts <M>
4. 2. b. 2 But then D(<D>) = Contradiction! Giorgi Japaridze ATM is undecidable accept if D does not accept <D> reject if D accepts <D> Theory of Computability
4. 2. c Giorgi Japaridze Theory of Computability A Turing-unrecognizable language ATM = {<M, w> | M is a TM and M accepts string w} ATM = {<M, w> | M is a TM and M does not accept string w} Theorem 4. 23: ATM is Turing-unrecognizable. Proof idea. Suppose, for a contradiction, that ATM is Turing-recognizable. That is, there is a TM U that recognizes ATM. • U recognizes ATM (slide 4. 2. a) Thus, • U recognizes ATM Let K = “On input <M, w>: 1. Run both U and U on input <M, w> in parallel; 2. If U accepts, accept; if U accepts, reject. ” It can bee seen that K decides ATM, which contradicts Theorem 4. 11.
4. 2. d Giorgi Japaridze Theory of Computability The language hierarchy summary All languages ATM Turing-recognizable languages ATM Turing-decidable languages {<G> | G is a connected graph}
- Slides: 7