comp-330 theory of computation - mcgill...
TRANSCRIPT
COMP-330 Theory of Computation
Fall 2017 -- Prof. Claude Crépeau Lec. 16 :
Turing Machines
COMP 330 Fall 2017: Lectures Schedule
14. MIDTERM15-16. Deterministic CFLs16-17. Turing Machines and Church-Turing Thesis17. Models of computation Basic computability theory18. Reducibility, undecidability and Rice’s theorem19. Undecidable problems about CFGs20. Post Correspondence Problem21. Validity of FOL is RE / Gödel’s and Tarski’s thms22. Universality / The recursion theorem 23. Degrees of undecidability24. Introduction to complexity25. Introduction to Quantum Computing/Complexity26. Review of course material
1-2. Introduction 1.5. Some basic mathematics2-3. Deterministic finite automata +Closure properties,4. Nondeterministic finite automata5. Minimization 6. Determinization+Kleene’s theorem7. Regular Expressions+GNFA8. The pumping lemma9. Myhill-Nerode theorem10. Context-Free Grammar11. PushDown automata12 .CFG - PDA equivalence13. CFG Pumping lemma and applications
All languages
Decidable Languages
Context-freeLanguages
RegularLanguages
Languages we can describe
NON-Regular Languagesvia Pumping Lemma
NON-RegularLanguages
via Reductions
Computability Theory
All languages
Decidable Languages
Context-freeLanguages
Languages we can describe
NON-CFLsvia Pumping Lemma
NON-CFLsvia Reductions
RegularLanguages
Computability Theory
All languages
Decidable Languages
Context-freeLanguages
Languages .we can
describe
NON-decidablevia Diagonalization
NON-decidablevia Reductions
RegularLanguages
Computability Theory
Turing MACHINES
Alan Turing
M1
q1
M1
10010101
q2
1
M1M1
10010101
M1
10010101
q3
0
M1
q2
1
M1M1
10110101read and write!moves Right and Left!
M1
10110101
q3
0
M1
Turing Machines
TM Example
StatesInput AlphabetTape AlphabetTransition functionStart stateAccept stateReject state
Definition of TMq1
q2 q3
a,b,c
q1 q2
b→c,Da,b,c,A,B,C,_
StatesInput AlphabetTape AlphabetTransition functionStart stateAccept stateReject state
Definition of TMq1
q2 q3
a,b,c
q1 q2
b→c,Da,b,c,A,B,C,_
q1 q2
b→c,D
inputsymbol
outputsymbol
L or Rheadmove
StatesInput AlphabetTape AlphabetTransition functionStart stateAccept stateReject state
Definition of TMq1
q2 q3
a,b,c
q1 q2
b→c,D
q1
qacc
a,b,c,A,B,C,_
qrej
TM definition
TM Configuration
TM Computation
For all a,b,c∈𝜞, u,v∈𝜞*, qi,qi∈Q
Config. ua qi bv yields config. u qj acv if δ(qi,b) = qj,c,L
Config. ua qi bv yields config. uac qj v if δ(qi,b) = qj,c,R
Special cases: Config. qi bv yields qj cv if δ(qi,b) = qj,c,LConfig. qi bv yields c qj v if δ(qi,b) = qj,c,R
TM definition
TM Computation
Start configuration: q0 w (w = input string)
Accepting configuration: state = qaccept
Rejecting configuration: state = qreject
TM Computation
Turing Machine M accepts input w if there exists configurations C0, C1,..., Cm such that
C0 is a start configuration
Ci yields Ci+1 for 0≤i<m
Cm is an accepting configuration.
The collection of strings that M accepts is the language of M or the language recognized by M, denoted L(M).
TM Computation
A TM decides a language if it recognizes it and halts (reaches an accepting or rejecting states) on all input strings.
TM Computation
A TM decides a language if it recognizes it and halts (reaches an accepting or rejecting states) on all input strings.
1Often named Recursively-Enumerable in the literature.2Often named Recursive in the literature.
TM Examples
TM Examples
TM Computation
TM Examples
∑ \ { x , _ }
∑ \ { # , _ }
TM Examples
TM Examples
TM Examples
More Turing MACHINES
Multitape Turing Machines
Non-Deterministic Turing Machines
Enumerator Turing Machines
Everything else...
Multitape TM
Multitape TM
Multitape TM
Multitape TM
Non-deterministic TM
Non-deterministic TM
Non-deterministic TM
Enumerator TM
Enumerator TM
Enumerator TM
Enumerator TM
Enumerator TM
Lambda-calculus
Recursive Functions
Programming languages:
FORTRAN, PASCAL, C, JAVA,...
LISP, SCHEME,...
Everything Else
Alonzo Church
J. Barkley Rosser
Stephen Kleene
Lambda-calculus
Recursive Functions
Programming languages:
FORTRAN, PASCAL, C, JAVA,...
LISP, SCHEME,...
Everything Else
Alonzo Church
J. Barkley Rosser
Stephen Kleene
Lambda-calculus
Recursive Functions
Programming languages:
FORTRAN, PASCAL, C, JAVA,...
LISP, SCHEME,...
Everything Else
Alonzo Church
J. Barkley Rosser
Stephen Kleene
Church-Turing Thesis
Alonzo Church Alan Turing
Church-Turing Thesis
Speaking on 8 August 1900, at the Paris 2nd International Congress of Mathematicians, at La Sorbonne, German mathematician David Hilbert presented ten problems in mathematics.
The problems were all unsolved at the time, and several of them turned out to be very influential for 20th century mathematics.
Paris, 1900
David Hilbert
Hilbert’s 10th problem
Let P be a polynomial in several variables: P(x,y,z)=24x2y3+17x+5y+25
Is there a set of integers for x,y,z such that P(x,y,z)=0 ?
This problem is undecidable...but is Turing-Recognizable...
Needed a formal model ofcomputing to prove impossibility. Yuri Matiyasevich
Single variable Poly
COMP-330 Theory of Computation
Fall 2017 -- Prof. Claude Crépeau Lec. 16 :
Turing Machines &Church-Turing Thesis