Theory of Computing Lecture 21 MAS 714 Hartmut Klauck.

Slides:



Advertisements
Similar presentations
Lecture 3 Universal TM. Code of a DTM Consider a one-tape DTM M = (Q, Σ, Γ, δ, s). It can be encoded as follows: First, encode each state, each direction,
Advertisements

Theory of Computing Lecture 23 MAS 714 Hartmut Klauck.
Variants of Turing machines
Lecture 24 MAS 714 Hartmut Klauck
CSCI 4325 / 6339 Theory of Computation Zhixiang Chen Department of Computer Science University of Texas-Pan American.
Theory of Computing Lecture 16 MAS 714 Hartmut Klauck.
CS21 Decidability and Tractability
Complexity 12-1 Complexity Andrei Bulatov Non-Deterministic Space.
Complexity 15-1 Complexity Andrei Bulatov Hierarchy Theorem.
Computability and Complexity 22-1 Computability and Complexity Andrei Bulatov Hierarchy Theorem.
Complexity 13-1 Complexity Andrei Bulatov Hierarchy Theorem.
1 Introduction to Computability Theory Lecture14: Recap Prof. Amos Israeli.
Introduction to Computability Theory
1 Introduction to Computability Theory Lecture12: Decidable Languages Prof. Amos Israeli.
1 Introduction to Computability Theory Lecture2: Non Deterministic Finite Automata Prof. Amos Israeli.
Computability and Complexity 19-1 Computability and Complexity Andrei Bulatov Non-Deterministic Space.
P, NP, PS, and NPS By Muhannad Harrim. Class P P is the complexity class containing decision problems which can be solved by a Deterministic Turing machine.
Complexity ©D.Moshkovitz 1 Turing Machines. Complexity ©D.Moshkovitz 2 Motivation Our main goal in this course is to analyze problems and categorize them.
FORMAL LANGUAGES, AUTOMATA AND COMPUTABILITY Read sections 7.1 – 7.3 of the book for next time.
CHAPTER 4 Decidability Contents Decidable Languages
Computability and Complexity 20-1 Computability and Complexity Andrei Bulatov Class NL.
RELATIVIZATION CSE860 Vaishali Athale. Overview Introduction Idea behind “Relativization” Concept of “Oracle” Review of Diagonalization Proof Limits of.
Theory of Computing Lecture 20 MAS 714 Hartmut Klauck.
Theory of Computing Lecture 22 MAS 714 Hartmut Klauck.
1 Introduction to Computability Theory Lecture11: The Halting Problem Prof. Amos Israeli.
FORMAL LANGUAGES, AUTOMATA AND COMPUTABILITY
Theory of Computing Lecture 19 MAS 714 Hartmut Klauck.
Definition: Let M be a deterministic Turing Machine that halts on all inputs. Space Complexity of M is the function f:N  N, where f(n) is the maximum.
CSCI 4325 / 6339 Theory of Computation Zhixiang Chen.
Theory of Computing Lecture 15 MAS 714 Hartmut Klauck.
February 18, 2015CS21 Lecture 181 CS21 Decidability and Tractability Lecture 18 February 18, 2015.
Computational Complexity Theory Lecture 2: Reductions, NP-completeness, Cook-Levin theorem Indian Institute of Science.
Theory of Computing Lecture 17 MAS 714 Hartmut Klauck.
1 Undecidability Reading: Chapter 8 & 9. 2 Decidability vs. Undecidability There are two types of TMs (based on halting): (Recursive) TMs that always.
ATM, Halting Problem, P vs. NP Chapter 4, 5 & 7. Russel’s Paradox An Index is a book that lists other books in.
1 Linear Bounded Automata LBAs. 2 Linear Bounded Automata (LBAs) are the same as Turing Machines with one difference: The input string tape space is the.
1 Turing’s Thesis. 2 Turing’s thesis: Any computation carried out by mechanical means can be performed by a Turing Machine (1930)
 2005 SDU Lecture13 Reducibility — A methodology for proving un- decidability.
1Computer Sciences Department. Book: INTRODUCTION TO THE THEORY OF COMPUTATION, SECOND EDITION, by: MICHAEL SIPSER Reference 3Computer Sciences Department.
D E C I D A B I L I T Y 1. 2 Objectives To investigate the power of algorithms to solve problems. To explore the limits of algorithmic solvability. To.
INHERENT LIMITATIONS OF COMPUTER PROGAMS CSci 4011.
Hierarchy theorems Section 9.1 Giorgi Japaridze Theory of Computability.
Fall 2013 CMU CS Computational Complexity Lecture 2 Diagonalization, 9/12/2013.
Donghyun (David) Kim Department of Mathematics and Computer Science North Carolina Central University 1 Chapter 4 Decidability Some slides are in courtesy.
Chapter 5 Finite Automata Finite State Automata n Capable of recognizing numerous symbol patterns, the class of regular languages n Suitable for.
CSCI 4325 / 6339 Theory of Computation Zhixiang Chen.
 2005 SDU Lecture14 Mapping Reducibility, Complexity.
CSE 105 theory of computation
Busch Complexity Lectures: Reductions
Linear Bounded Automata LBAs
Reductions Costas Busch - LSU.
CSE 105 theory of computation
HIERARCHY THEOREMS Hu Rui Prof. Takahashi laboratory
Turing Machines Acceptors; Enumerators
Summary.
Jaya Krishna, M.Tech, Assistant Professor
Alternating tree Automata and Parity games
Decidable Languages Costas Busch - LSU.
Chapter Nine: Advanced Topics in Regular Languages
CS154, Lecture 12: Time Complexity
Recall last lecture and Nondeterministic TMs
Turing Machines Complexity ©D.Moshkovitz.
CS21 Decidability and Tractability
Time Complexity Classes
CSE 105 theory of computation
Chapter 1 Regular Language
Instructor: Aaron Roth
CSE 105 theory of computation
Instructor: Aaron Roth
CSE 105 theory of computation
Presentation transcript:

Theory of Computing Lecture 21 MAS 714 Hartmut Klauck

Time Hierarchy We briefly return to complexity theory We believe that NP is larger than P Now we prove that EXP is larger than P Why now? Idea of the proof is similar to undecidability proofs/diagonalization

Time Hierarchy Informal statement: – If we increase the computing time enough, more languages can be decided – DTIME(f(n)) is larger than DTIME(g(n)) as long as f(n) is suitably larger than g(n) Problem: in this generality the statement is false Fix: f(n) and g(n) need to be `nice’ bounds

Constructible bounds What is nice? We should be able to compute f(n), so we can use a counter from 1…f(n) Definition: A function f(n):N  N is called time- constructible, if f(n) can be computed by a TM from input 1 n in time O(f(n)) Example: everything reasonable, e.g. polynomial, exponential bounds etc. Usually first compute n in binary Example: given 1 n we can compute n in binary in time O(n log n) and then n 2, takes time O(n log n) in total Example: given 1 n we can compute 2 n in time O(n)

Time Hierarchy Theorem: – Let f(n),g(n)>n be time-constructible functions with f(n)=  (g 2 (n) log 2 n) – Then there is a language L such that L is in DTIME(f(n)) L is not in DTIME(g(n))

Proof L={,x: M accepts x in at most g(|x|) log|x| steps} – M is 1-tape TM We first need to show that L in DTIME(f(n)) – On a 1-tape TM – We give a 2-tape machine that runs in time O(g(|x|) log |x|), then there is a 1-tape machine that runs in time O(f(n)) old exercise – 2-tape machine: tape 1: simulate M on x using the universal TM – tape 2: first construct g(|x|) [time g(n)] – Then use tape 2 to count the steps of M – If more than g(|x|) log |x| steps used: reject – Accept if M accepts in g(|x|) log |x| steps

Proof Show that L not in DTIME(g(n)) Assume A decides L in time O(g(n)) Intuition: cannot simulate M, because the time is not enough Construct a new machine N that on input x simulates A on x, x and rejects if A accepts on x, x and vice versa N is O(g(n)) time bounded [use universal 1-tape TM] What happens on input x= ? – If N accepts in time at most g(|x|)log |x| then A says accept, and hence N will reject. This takes time O(g(|x|)) – If N does not accept in time g(|x|) log |x|, then A says reject, and N will accept. This takes time O(g|x|) Contradiction for large enough |x|

Note Tighter time hierarchies are known, it is enough to increase the time bound by ! (log g(n)) factor – Idea: simulate the 2-tape machine by keeping the counter on the first tape, and moving it in each step together with the head movement – Counter needs O(log g(n)) bits For the nondeterministic time hierarchy the log-factor is not needed

Corollary DTIME(n k ) is a proper subset of DTIME(n 2k+1 ) for all constants k P is a subset of DTIME(n log n ) – log n grows faster than any constant P is a proper subset of EXP Improved hierarchy: DTIME(n k ) is proper subset of DTIME(n k+ ² )

Space Complexity We list a few results NP µ PSPACE µ EXP PSPACE=NPSPACE More specifically, NSPACE(f(n)) µ DSPACE(f 2 (n)) – Savitch’s theorem Def: co-NSPACE(f(n))={L: C(L) 2 NSPACE(f(n)) co-NSPACE(f(n))=NSPACE(f(n)) – Immerman–Szelepcsényi Space-hierarchy: like time hierarchy, no log-factor needed

Provably intractable Problems that are complete for EXP can provably not be computed in polynomial time Problems that are complete for EXPSPACE can provably not be computed with polynomial space Completeness: polynomial time reductions Proof: – If the complete problem is in P then EXP=P resp. EXPSPACE=PSPACE, contradiction to hierarchy

P vs. NP Why can we not prove that P is not equal to NP using diagonalization? The diagonalization technique relativizes, i.e., it applies to oracle TM’s There are oracles such that relative to them P=NP (and oracles where the opposite is the case)

Last Part of the Course Turing machines with constant space I.e., machines that cannot write on the tape – Any additional constant space can be moved into the internal state Definition: A two-way deterministic finite automaton is a Turing machine that cannot write on it’s tape and cannot leave the section where the input is Definition: A deterministic finite automaton (DFA) is a two way DFA whose head only moves from left to right on the input tape

Finite Automata Definition: A DFA is a 5-tuple (Q, §, ±,q 0,F) – Q: states – § : alphabet – ± : Q £ §  Q: transition function – q 0 : starting state – F µ Q: accepting states No need to specify terminal states, halts on the last input symbol

Graph of a finite automaton An DFA can be described by a directed graph with |Q| vertices and |Q| ¢ | § | edges Every vertex has | § | outgoing edges Computation starts on vertex q 0 In each step we follow the edge labeled by the next input symbol from the current state to the next state DFA accepts, iff the state reached after reading the whole input is in F

Example 1: Parity

Example: Set of all strings that contain substring 001

Regular languages Definition: A language is called regular, if it can be decided by a DFA – This is definition 1, name is explained by definition 2 later (via regular expressions)

Topics: 1.Closure Properties 2.Power of Non-determinism 3.Which languages are regular and which ones are not? 4. Two-way versus one-way automata 5.Regular expressions 6.DFA as a data-structure for languages – DFA minimization

1) Closure: complementation Observation: – If L is regular, then so is the complement of L Proof: swap accepting and nonaccepting states of a DFA Closure under union and intersection: later