ECS 120, Summer II 2013, Prof. Franklin, Final Exam, 9/11/13 1. (10 points) This question is about the proof that every nondeterministic pushdown automaton has an equivalent context free grammar. a. What is each variable A_pq for? b. What simplifying assumptions are made about the pushdown automaton? c. Whatt is the rule A_pq -> A_pr A_rq for? 2. (5 points) Let ALL_DFA = { : A is a DFA that accepts every string in {0,1}^*}. Show that ALL_DFA is decidable. 3. (20 points) This question is about nondeterministic Turing Machines. a. How does the definition of a nondeterministic TM differ from that of a deterministic TM? b. What does it mean for a nondeterministic TM to be a decider? c. What is the language decided by a nondeterministic TM? d. Define NP in terms of nondeterministic TM deciders. 4. (20 points) This question is about A_TM = { : M is a deterministic TM that accepts input w}. a. Sketch the main ideas in the proof that A_TM is undecidable. b. Sketch the main ideas in the proof that a language closely related to A_TM is not Turing-recognizable. 5. (15 points) This question is about the Cook-Levin theorem. a. What does it mean for a language to be NP-Complete? b. What does the Cook-Levin theorem say? c. In the proof of the Cook-Levin theorem, what is a tableau? d. In the proof of the Cook-Levin theorem, what does x_ijs represent? e. In the proof of the Cook-Levin theorem, what is a valid window? 6. (15 points) This question is about poly-time reductions. CONNECTED = { : G is a connected undirected graph}. CLIQUE = { : G is an undirected graph with a subset of k vertices that have all possible edges between them}. a. Is there a polytime reduction from 3SAT to CLIQUE ? Explain why or why not. b. Is there a polytime reduction from CLIQUE to SAT ? Explain why or why not. c. Is there a polytime reduction from CONNECTED to 0*1* ? Explain why or why not. d. Is there a polytime reduction from SAT to A_TM ? Explain why or why not. e. Is there a polytime reduction from A_TM to SAT ? Explain why or why not. 7. (15 points) This question is about some nonstandard notions of time complexity. a. Define DFA-TIME(n^k) to be the class of regular languages recognized by deterministic finite automata that take at most O(n^k) steps to accept inputs of length n (possibly taking more steps, or never halting, on inputs that are not accepted). Give a characterization of the regular languages in terms of DFA-TIME(.) and justify your answer. b. Define DTM-TIME(n^k) to be the class of languages recognized by deterministic Turing Machines that take at most O(n^k) steps to accept any input of length n (possibly taking more steps than that, or never halting, on inputs that are not accepted). Give a characterization of P in terms of DTM-TIME(.) and justify your answer. c. Define NPDA-TIME(n^k) to be the class of languages recognized by nondeterministic pushdown automata that take at most O(n^k) steps to accept any input of length n (possibly taking more steps than that, or never halting, on inputs that are not accepted). Give a characterization of the context free languages in terms of NPDA-TIME(.).