Fall 2013 CMU CS 15-855 Computational Complexity Lecture 5 Savich’s theorem, and IS theorems. These slides are mostly a resequencing of Chris Umans’ slides.

Slides:



Advertisements
Similar presentations
COMPLEXITY THEORY CSci 5403 LECTURE VII: DIAGONALIZATION.
Advertisements

Part VI NP-Hardness. Lecture 23 Whats NP? Hard Problems.
CS151 Complexity Theory Lecture 4 April 11, 2013.
1 Savitch and Immerman- Szelepcsènyi Theorems. 2 Space Compression  For every k-tape S(n) space bounded offline (with a separate read-only input tape)
1 Nondeterministic Space is Closed Under Complement Presented by Jing Zhang and Yingbo Wang Theory of Computation II Professor: Geoffrey Smith.
Complexity Theory Lecture 3 Lecturer: Moni Naor. Recap Last week: Non deterministic communication complexity Probabilistic communication complexity Their.
1 Space Complexity. 2 Def: 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)
Giorgi Japaridze Theory of Computability Savitch’s Theorem Section 8.1.
CS151 Complexity Theory Lecture 3 April 6, CS151 Lecture 32 Introduction A motivating question: Can computers replace mathematicians? L = { (x,
Umans Complexity Theory Lectures Lecture 4b: Nondeterministic Space: I-S Theorem: NL = coNL.
NL equals coNL Section 8.6 Giorgi Japaridze Theory of Computability.
CSCI 4325 / 6339 Theory of Computation Zhixiang Chen.
INHERENT LIMITATIONS OF COMPUTER PROGRAMS CSci 4011.
CSC 3130: Automata theory and formal languages Andrej Bogdanov The Chinese University of Hong Kong Variants.
Complexity 12-1 Complexity Andrei Bulatov Non-Deterministic Space.
Complexity 15-1 Complexity Andrei Bulatov Hierarchy Theorem.
Complexity 11-1 Complexity Andrei Bulatov Space Complexity.
Computability and Complexity 22-1 Computability and Complexity Andrei Bulatov Hierarchy Theorem.
Complexity 13-1 Complexity Andrei Bulatov Hierarchy Theorem.
P and NP Sipser (pages ). CS 311 Fall Polynomial time P = ∪ k TIME(n k ) … P = ∪ k TIME(n k ) … TIME(n 3 ) TIME(n 2 ) TIME(n)
CS151 Complexity Theory Lecture 3 April 6, Nondeterminism: introduction A motivating question: Can computers replace mathematicians? L = { (x,
CS151 Complexity Theory Lecture 5 April 13, 2015.
Computability and Complexity 19-1 Computability and Complexity Andrei Bulatov Non-Deterministic Space.
Complexity ©D.Moshkovitz 1 Turing Machines. Complexity ©D.Moshkovitz 2 Motivation Our main goal in this course is to analyze problems and categorize them.
CS151 Complexity Theory Lecture 5 April 13, 2004.
Complexity ©D.Moshkovits 1 Space Complexity Complexity ©D.Moshkovits 2 Motivation Complexity classes correspond to bounds on resources One such resource.
CS151 Complexity Theory Lecture 12 May 6, CS151 Lecture 122 Outline The Polynomial-Time Hierarachy (PH) Complete problems for classes in PH, PSPACE.
Computability and Complexity 20-1 Computability and Complexity Andrei Bulatov Class NL.
Complexity 1 The Padding Argument. Complexity 2 Motivation: Scaling-Up Complexity Claims space + non-determinism We have: space + determinism can be simulated.
Fall 2004COMP 3351 Reducibility. Fall 2004COMP 3352 Problem is reduced to problem If we can solve problem then we can solve problem.
Non Deterministic Space Avi Ben Ari Lior Friedman Adapted from Dr. Eli Porat Lectures Bar-Ilan - University.
CS151 Complexity Theory Lecture 2 April 3, Time and Space A motivating question: –Boolean formula with n nodes –evaluate using O(log n) space?
Alternating Turing Machine (ATM) –  node is marked accept iff any of its children is marked accept. –  node is marked accept iff all of its children.
February 20, 2015CS21 Lecture 191 CS21 Decidability and Tractability Lecture 19 February 20, 2015.
CS151 Complexity Theory Lecture 2 April 1, CS151 Lecture 22 Time and Space A motivating question: –Boolean formula with n nodes –evaluate using.
Non-Deterministic Space is Closed Under Complementation Neil Immerman Richard Szelepcsenyi Presented By: Subhajit Dasgupta.
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.
חישוביות וסיבוכיות Computability and Complexity Lecture 7 TexPoint fonts used in EMF. Read the TexPoint manual before you delete this box.: A AAAA.
February 18, 2015CS21 Lecture 181 CS21 Decidability and Tractability Lecture 18 February 18, 2015.
Fall 2013 CMU CS Computational Complexity Lecture 3 and 4 Non-determinism, NTIME hierarchy threorem, Ladner’s Proof 9/17/2013.
Theory of Computing Lecture 21 MAS 714 Hartmut Klauck.
Fall 2013 CMU CS Computational Complexity Lecture 7 Alternating Quantifiers, PH, PSPACE. These slides are mostly a resequencing of Chris Umans’
NP-completeness Class of hard problems. Jaruloj ChongstitvatanaNP-complete Problems2 Outline  Introduction  Problems and Languages Turing machines and.
Hierarchy theorems Section 9.1 Giorgi Japaridze Theory of Computability.
The Classes L and NL Section 8.4 Giorgi Japaridze Theory of Computability.
Umans Complexity Theory Lectures Lecture 1c: Robust Time & Space Classes.
Fall 2013 CMU CS Computational Complexity Lecture 2 Diagonalization, 9/12/2013.
Theory of Computational Complexity Yuji Ishikawa Avis lab. M1.
Chapter 7 Introduction to Computational Complexity.
Space Complexity Guy Feigenblat Based on lecture by Dr. Ely Porat Complexity course Computer science department, Bar-Ilan university December 2008.
 2005 SDU Lecture14 Mapping Reducibility, Complexity.
Umans Complexity Theory Lectures Lecture 3c: Nondeterminism: Ladner’s Theorem: If P≠ NP then ∃ NP Languages neither NP Complete nor in P.
Umans Complexity Theory Lectures
Space Complexity Complexity ©D.Moshkovits.
Umans Complexity Theory Lectures
HIERARCHY THEOREMS Hu Rui Prof. Takahashi laboratory
Theory of Computational Complexity
Intractable Problems Time-Bounded Turing Machines Classes P and NP
Intro to Theory of Computation
CS151 Complexity Theory Lecture 3 April 10, 2017.
CSC 4170 Theory of Computation Space complexity Chapter 8.
Part II Theory of Nondeterministic Computation
CS21 Decidability and Tractability
Umans Complexity Theory Lectures
CS21 Decidability and Tractability
Instructor: Aaron Roth
CS151 Complexity Theory Lecture 5 April 16, 2019.
CS151 Complexity Theory Lecture 4 April 12, 2019.
Intro to Theory of Computation
CS151 Complexity Theory Lecture 4 April 8, 2004.
Presentation transcript:

Fall 2013 CMU CS Computational Complexity Lecture 5 Savich’s theorem, and IS theorems. These slides are mostly a resequencing of Chris Umans’ slides From CS 151: Complexity Theory (Spring 2013) at CalTech.CS 151: Complexity Theory (Spring 2013)

World Picture EXP PSPACE P L NEXP NP coNP coNEXP 9/24/2013

Ladner’s Theorem Try to “merge”: on input x, either –answer SAT(x) –answer TRIV(x) if can decide which one in P, L  NP SATTRIV MiMi M0M0 L N0N0 NiNi :: ::... ≠ ≠ ≠ ≠ 9/24/2013

Ladner’s Theorem Key: n eventually large enough to notice completed previous stage L f 0011kkk... MiMi input x input z < x ≠ suppose k = 2i I’m sup- posed to ensure M i is killed I finally have enough time to check input z I notice z did the job, increase f to k+1 kk 9/24/2013

April 4, At most 2 O(f(n)) bits to describe a SPACE(fn)) configuration.. # configurations for a q-tape TM (work tape + read-only input) that runs in space f(n) n x f(n) q x |Q| x |∑| f(n)q = O( c qf(n) ) = 2 O(f(n)) input-tape head position work-tape head positions state work-tape contents

At most 2 O(f(n)) bits to describe a SPACE(fn)) configuration.. Pick any consistent way of interpreting binary strings as configurations of a TM. n x f(n) q x |Q| x |∑| f(n)q = O( c qf(n) ) = 2 O(f(n))

April 4, Configuration graph for NTMs configuration graph of M on input x: nodes are all sequences of 2 O(f(n)) bits configurations, edge (C, C’) iff the config of M(x) represented by C, and the config of M(x) represented by C’ are consistent with the transition relation of M.

NSPACE(f(n)) = languages decidable by a multi-tape NTM that touches at most f(n) squares of its work tapes along any computation path, where n is the input length, and f :N ! N Let C configuration graph for a space f(n) NTM on input x. C has c f(n) = 2 kf(n) nodes (Exponential in f(n)) f(n) = k’log(n) means POLY-SIZED graph. 9/24/2013

Do DFS or BFS on C most n k configurations of given NTM M running in NSPACE(log n). q start x 1 x 2 x 3 …x n q accept q reject xLxL q accept q reject xLxL easy to determine if C yields C’ in one step configuration graph for M on input x: 9/24/2013

Reachability Conclude: NL  P –and NPSPACE  EXP S-T-Connectivity (STCONN): given directed graph G = (V, E) and nodes s, t, is there a path from s to t ? Theorem: STCONN is NL-complete under logspace reductions. 9/24/2013

Reachability Proof: –given L  NL decided by NTM M construct configuration graph for M on input x (can be done in logspace) –s = starting configuration; t = q accept 9/24/2013

STCONN is in NL NUMSTEPS = 0 (number of steps taken.) C = s (current node) FLAG=False Until NUMSTES = n do –GUESS Z from 1 to n –Increment NUMSTEPS –If (c,z) is an edge in G, set c=z –If c==t set FLAG= True. 9/24/2013

I started at S – I got drunk – and now I am at T I wandered, therefore, my path from S to T exists. 9/24/2013

Two startling theorems Strongly believe P ≠ NP nondeterminism seems to add enormous power for space: Savitch ‘70: NPSPACE = PSPACE and NL  SPACE(log 2 n) 9/24/2013

Two startling theorems Strongly believe NP ≠ coNP seems impossible to convert existential into universal for space: Immerman/Szelepscényi ’87/’88: NL = coNL 9/24/2013

Savitch’s Theorem Theorem: STCONN  SPACE(log 2 n) Corollary: NL  SPACE(log 2 n) Corollary: NPSPACE = PSPACE 9/24/2013

Proof of Theorem –input: G = (V, E), two nodes s and t –recursive algorithm: /* return true iff path from x to y of length at most 2 i */ PATH(x, y, i) if i = 0 return ( x = y or (x, y)  E ) /* base case */ for z in V if PATH(x, z, i-1) and PATH(z, y, i-1) return(true); return(false); end 9/24/2013

Proof of Theorem –answer to STCONN: PATH(s, t, log n) –space used: (depth of recursion) x (size of “stack record”) –depth = log n –claim stack record: “(x, y, i)” sufficient size O(log n) –when return from PATH(a, b, i) can figure out what to do next from record (a, b, i) and previous record 9/24/2013

Nondeterministic space Robust nondeterministic space classes: NL = NSPACE(log n) NPSPACE =  k NSPACE(n k ) 9/24/2013

Second startling theorem Strongly believe NP ≠ coNP seems impossible to convert existential into universal for space: Immerman/Szelepscényi ’87/’88: NL = coNL 9/24/2013

I started at S – I got drunk  NL lucky, tiny brain – and now I am NOT at T How might I know that NO PATH from S to T exists ???? ! 9/24/2013

I-S Theorem Theorem: ST-NON-CONN  NL Proof: slightly tricky setup: –input: G = (V, E), two nodes s, t t s “yes” t s “no” 9/24/2013

I-S Theorem –want nondeterministic procedure using only O(log n) space with behavior: “yes” input “no” input q accept q reject q accept q reject t s t s 9/24/2013

I-S Theorem –observation: given count of # nodes reachable from s, can solve problem for each v  V, guess if it is reachable if yes, guess path from s to v –if guess doesn’t lead to v, reject. –if v = t, reject. –else counter++ if counter = count accept 9/24/2013

I-S Theorem –every computation path has sequence of guesses… –only way computation path can lead to accept: correctly guessed reachable/unreachable for each node v correctly guessed path from s to v for each reachable node v saw all reachable nodes t not among reachable nodes 9/24/2013

I-S Theorem –R(i) = # nodes reachable from s in at most i steps –R(0) = 1: node s –we will compute R(i+1) from R(i) using O(log n) space and nondeterminism –computation paths with “bad guesses” all lead to reject 9/24/2013

I-S Theorem –Outline: in n phases, compute R(1), R(2), R(3), … R(n) –only O(log n) bits of storage between phases –in end, lots of computation paths that lead to reject –only computation paths that survive have computed correct value of R(n) –apply observation. 9/24/2013

I-S Theorem –computing R(i+1) from R(i): –Initialize R(i+1) = 0 –For each v  V, guess if v reachable from s in at most i+1 steps R(i) = R(2) = 6 9/24/2013

I-S Theorem –if “yes”, guess path from s to v of at most i+1 steps. Increment R(i+1) –if “no”, visit R(i) nodes reachable in at most i steps, check that none is v or adjacent to v for u  V guess if reachable in ≤ i steps; guess path to u; counter++ KEY: if counter ≠ R(i), reject at this point: can be sure v not reachable 9/24/2013

I-S Theorem correctness of procedure: two types of errors we can make (1) might guess v is reachable in at most i+1 steps when it is not –won’t be able to guess path from s to v of correct length, so we will reject. “easy” type of error 9/24/2013

I-S Theorem (2) might guess v is not reachable in at most i+1 steps when it is –then must not see v or neighbor of v while visiting nodes reachable in i steps. –but forced to visit R(i) distinct nodes –therefore must try to visit node v that is not reachable in ≤ i steps –won’t be able to guess path from s to v of correct length, so we will reject. “easy” type of error 9/24/2013

Summary nondeterministic space classes NL and NPSPACE ST-CONN NL-complete 9/24/2013