COMP-330 Theory of Computation Fall 2017 -- Prof. Claude Crépeau Lecture 1 : Introduction
COMP 330 Fall 2017: Lectures Schedule 1-2. Introduction 1.5. Some basic mathematics 2-3. Deterministic finite automata +Closure properties, 3-4. Nondeterministic finite automata 5. Minimization+ Myhill-Nerode theorem 6. Determinization+Kleene s theorem 7. Regular Expressions+GNFA 8. Regular Expressions and Languages 9-10. The pumping lemma 11. Duality 12. Labelled transition systems 13. MIDTERM 14. Context-free languages 15. Pushdown automata 16. Parsing 17. The pumping lemma for CFLs 18. Introduction to computability 19. Models of computation Basic computability theory 20. Reducibility, undecidability and Rice s theorem 21. Undecidable problems about CFGs 22. Post Correspondence Problem 23. Validity of FOL is RE / Gödel s and Tarski s thms 24. Universality / The recursion theorem 25. Degrees of undecidability 26. Introduction to complexity
I N T R O D U C T I O N
Paris, 1900 German mathematician David Hilbert presented ten problems in mathematics from a list of 23 ( 1, 2, 6, 7, 8, 13, 16, 19, 21 and 22). Speaking on 8 August 1900, at the Paris 2 nd International Congress of Mathematicians, at La Sorbonne. The full list was published later. The problems were all unsolved at the time, and several of them turned out to be very influential for 20 th century mathematics.
Fundamental questions? Can we prove all the mathematical statements that we can formulate? (Hilbert s 2 nd problem) Example: for all natural integers x,y,z and n>2 x n +y n z n (Fermat s last theorem) Certainly, there are many mathematical problems that we do not know how to solve. Is this just because we are not smart enough to find a solution? Or, is there something deeper going on?
Computer Science version of these issues If my boss / supervisor / teacher formulates a problem to be solved urgently, can I write a program to efficiently solve this problem???
Computer Science version of these issues Are there some problems that cannot be solved at all? and, are there problems that cannot be solved efficiently?? (related to Hilbert s 10 th problem)
Computer Science version of these issues If my boss / supervisor / teacher formulates a problem to be solved urgently, can I write a program to efficiently solve this problem???
Kurt Gödel In 1931, he proved that any formalization of mathematics contains some statements that cannot be proved or disproved.
Alan Turing In 1934, he formalized the notion of decidability of a language by a computer.
A Language Let be a finite alphabet. (ex: {0,1}) Let * be all sequences of elements from this alphabet. (ex: 0, 1, 00000, 0101010101,...) A language L is any subset of *. An algorithm A decides a language L if A answers Yes when x L and No when x L.
Comparing Cardinalities languages that we can decide = languages that we can describe < All languages = N = N = R
Alonzo Church In 1936, he proved that certain languages cannot be decided by any algorithm whatsoever...
Emil Post In 1946, he gave a very natural example of an undecidable language...
(PCP) Post Correspondence Problem aaa a bbb aa b bb bb a a bb An instance of PCP with 6 tiles. A solution to PCP aa bbb b a a bb bb
Post Correspondence Problem u 1 u 2 u 3 u n... v 1 v 2 v 3 v n Given n tiles, u 1 /v 1... u n /v n where each u i or v i is a sequence of letters. Is there a k and a sequence <i 1,i 2,i 3,...,i k > ( with each 1 i j n ) such that u i 1 u i 2 u i 3... u i k = v i 1 v i 2 v i 3... v i k?
A Solution to Post Correspondence Problem u 1 u 2 u 3 u n... v 1 v 2 v 3 v n A solution is of this form: u i 1 u i 2 u i 3 u i 4 u i 5 u i k... v i 1 v i 2 v i 3 v i 4 v i 5 v i k with the top and bottom strings identical when we concatenate all the substrings.
Post Correspondence Problem Theorem: The Post Correspondence Problem cannot be decided by any algorithm (or computer program). In particular, no algorithm can identify in a finite amount of time some instances that have a No outcome. However, if a solution exists, we can find it.
Post Correspondence Problem Proof: Reduction technique - if PCP was decidable then another undecidable problem (the halting problem) would be decidable.
The Halting Problem Notice that an algorithm is a piece of text. An algorithm can receive text as input. An algorithm can receive the text description of an algorithm as input. The Halting Problem: Given two texts A,B, consider A as an algorithm and B as an input. Will algorithm A halt (as opposed to loop forever) on input B?
The Halting Problem and PCP Any algorithm to decide PCP can be converted to an algorithm to decide the Halting Problem as well. Conclusion: PCP cannot be decided either.
Computability Theory All languages languages that we can describe languages that we can decide
Syracuse Conjecture For any integer n>0 define the following sequence: { S i /2 S 1 =n, S i+1 = 3S i +1 { if S i is even, if S i is odd. Syracuse(n)= least i s.t. S 1 =n,...,s i =1 0 if S i >1 for all i.
Syracuse Conjecture Example: Syracuse(9) = 20 S 1 =9, S 2 =28, S 3 =14, S 4 =7, S 5 =22, S 6 =11, S 7 =34, S 8 =17, S 9 =52, S 10 =26, S 11 =13, S 12 =40, S 13 =20, S 14 =10, S 15 =5, S 16 =16, S 17 =8, S 18 =4, S 19 =2, S 20 =1 60 45 30 15 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20
Syracuse Conjecture For all n that we have computed so far, Syracuse(n) > 0. Conjecture for all n>0, Syracuse(n)>0 If there exists N such that Syracuse(N) = 0 we might not be able to prove it.
Syracuse Conjecture The Syracuse conjecture is believed to be true but no proof of that statement was discovered so far. It is an open problem. Even worse, it might be true but there might be no proof that it is!!! That s because when you write an algorithm you need not know what it does!!!
COMP-330 Theory of Computation Fall 2017 -- Prof. Claude Crépeau Lecture 1 : Introduction