Computability and Complexity 7 1 Recursion Theorem Computability
Computability and Complexity 7 -1 Recursion Theorem Computability and Complexity Andrei Bulatov
Computability and Complexity 7 -2 Self-Printing Program A Turing Machine S (transducer) that on every input prints out its o description Claim For any string x, there is a TM, • Erase the input • Print x • Halt , that on every input o
Computability and Complexity 7 -3 Example 01| |RR |0|R 01 |111|R 01 |000|R
Computability and Complexity 7 -4 Self-Printing Program (Cnt’d) A B H? T H?
Computability and Complexity Claim There is a Turing Machine, T, that, for any string x, outputs the TM Set B=T, then Then S operates as follows: • On the empty input • Print the description of T • Simulate T on the content of the tape (that is T) 7 -5
Computability and Complexity 7 -6 Recursion Theorem A TM (a program) can not just obtain its own description, but also perform any computation with it Theorem For any computable function there is a TM such that, for every input x, , For example, a TM can use experience x to change itself, and so to
Computability and Complexity 7 -7 Proof Idea A B T x H? T computes , H? B computes H?
Computability and Complexity 7 -8 operation: • prints the description of B and T on the tape ig the input, but not damaging it • A passes control to B • using the description of B and T from the tape B compute prints the description of TM , that is A • B passes control to T • T computes the value of the content of the tape, that (ABT, x)
Computability and Complexity Self-Printing Instance: A Turing Machine T. Question: Does T( ) print the description of T? The corresponding language is: Theorem Proof - see next slide is undecidable. 7 -9
Computability and Complexity 7 -10 We show that For every input “T; x” of an input y as follows: , let S be a machine operating on • Erase input y • Simulate T on x • If T(x) halts then write the description of S on the tape and “Accept” Observe that • If T halts on x, then S prints itself on any input • If T does not halt on x, then S does not print itself QED
- Slides: 10