Lecture 5: Logspace reductions and completeness

Similar documents
Handout 7. and Pr [M(x) = χ L (x) M(x) =? ] = 1.

DSPACE(n)? = NSPACE(n): A Degree Theoretic Characterization

Lecture 3: Nondeterminism, NP, and NP-completeness

Reducibility and Completeness

Lecture 7: Polynomial time hierarchy

CSE200: Computability and complexity Space Complexity

Umans Complexity Theory Lectures

Lecture 8: Complete Problems for Other Complexity Classes

U.C. Berkeley CS278: Computational Complexity Professor Luca Trevisan 9/6/2004. Notes for Lecture 3

Notes on Space-Bounded Complexity

Lecture 7: The Polynomial-Time Hierarchy. 1 Nondeterministic Space is Closed under Complement

Notes on Space-Bounded Complexity

MTAT Complexity Theory October 13th-14th, Lecture 6

Polynomial Time Computation. Topics in Logic and Complexity Handout 2. Nondeterministic Polynomial Time. Succinct Certificates.

L S is not p m -hard for NP. Moreover, we prove for every L NP P, that there exists a sparse S EXP such that L S is not p m -hard for NP.

Space is a computation resource. Unlike time it can be reused. Computational Complexity, by Fu Yuxi Space Complexity 1 / 44

Boolean circuits. Lecture Definitions

Lecture 8: Alternatation. 1 Alternate Characterizations of the Polynomial Hierarchy

Lecture 6: Oracle TMs, Diagonalization Limits, Space Complexity

CS151 Complexity Theory. Lecture 4 April 12, 2017

Notes for Lecture 3... x 4

Advanced topic: Space complexity

The space complexity of a standard Turing machine. The space complexity of a nondeterministic Turing machine

Lecture Notes Each circuit agrees with M on inputs of length equal to its index, i.e. n, x {0, 1} n, C n (x) = M(x).

Circuits. Lecture 11 Uniform Circuit Complexity

Complexity. Complexity Theory Lecture 3. Decidability and Complexity. Complexity Classes

Logarithmic space. Evgenij Thorstensen V18. Evgenij Thorstensen Logarithmic space V18 1 / 18

Space Complexity. The space complexity of a program is how much memory it uses.

Complete problems for classes in PH, The Polynomial-Time Hierarchy (PH) oracle is like a subroutine, or function in

CMPT 710/407 - Complexity Theory Lecture 4: Complexity Classes, Completeness, Linear Speedup, and Hierarchy Theorems

Lecture 3 (Notes) 1. The book Computational Complexity: A Modern Approach by Sanjeev Arora and Boaz Barak;

Lecture 5: The Landscape of Complexity Classes

Outline. Complexity Theory. Example. Sketch of a log-space TM for palindromes. Log-space computations. Example VU , SS 2018

CS294: Pseudorandomness and Combinatorial Constructions September 13, Notes for Lecture 5

an efficient procedure for the decision problem. We illustrate this phenomenon for the Satisfiability problem.

1 Bounding the Margin

8.1 Theore. For every s log, DSPACE(s 2 Pol ) = R p;bit (DSPACE(s Pol)): 8.2 Corollary. PSPACE = R p;bit (POLYLOGSPACE): The class POLYLOGSPACE sees t

List Scheduling and LPT Oliver Braun (09/05/2017)

Lecture 4 : Quest for Structure in Counting Problems

Lecture 3. 1 Terminology. 2 Non-Deterministic Space Complexity. Notes on Complexity Theory: Fall 2005 Last updated: September, 2005.

6.841/18.405J: Advanced Complexity Wednesday, February 12, Lecture Lecture 3

CSC 5170: Theory of Computational Complexity Lecture 4 The Chinese University of Hong Kong 1 February 2010

13.2 Fully Polynomial Randomized Approximation Scheme for Permanent of Random 0-1 Matrices

Lecture 20: PSPACE. November 15, 2016 CS 1010 Theory of Computation

SOLUTION: SOLUTION: SOLUTION:

Review of Basic Computational Complexity

Quantum algorithms (CO 781, Winter 2008) Prof. Andrew Childs, University of Waterloo LECTURE 15: Unstructured search and spatial search

INAPPROX APPROX PTAS. FPTAS Knapsack P

ITCS:CCT09 : Computational Complexity Theory Apr 8, Lecture 7

198:538 Complexity of Computation Lecture 16 Rutgers University, Spring March 2007

Computational Complexity Theory. Markus Bläser, Holger Dell, Karteek Sreenivasaiah Universität des Saarlandes Draft June 15, 2015 and forever

3.8 Three Types of Convergence

CS151 Complexity Theory

1 PSPACE-Completeness

COL 352 Introduction to Automata and Theory of Computation Major Exam, Sem II , Max 80, Time 2 hr. Name Entry No. Group

The Frequent Paucity of Trivial Strings

Lecture 22: PSPACE

Lecture 3: Reductions and Completeness

Lecture 1: Course Overview and Turing machine complexity

Complexity Theory 112. Space Complexity

A Self-Organizing Model for Logical Regression Jerry Farlow 1 University of Maine. (1900 words)

The Immerman-Szelepcesnyi Theorem and a hard problem for EXPSPACE

CSE 200 Lecture Notes Turing machine vs. RAM machine vs. circuits

Introduction to Complexity Theory. Bernhard Häupler. May 2, 2006

Lecture 21: Space Complexity (The Final Exam Frontier?)

1 Circuit Complexity. CS 6743 Lecture 15 1 Fall Definitions

Computational and Statistical Learning Theory

JASS 06 Report Summary. Circuit Complexity. Konstantin S. Ushakov. May 14, 2006

Complexity: Some examples

Definition: Alternating time and space Game Semantics: State of machine determines who

E0 370 Statistical Learning Theory Lecture 5 (Aug 25, 2011)

Universality for Nondeterministic Logspace

CSC 5170: Theory of Computational Complexity Lecture 9 The Chinese University of Hong Kong 15 March 2010

CS256 Applied Theory of Computation

Time Complexity. Definition. Let t : n n be a function. NTIME(t(n)) = {L L is a language decidable by a O(t(n)) deterministic TM}

CS5371 Theory of Computation. Lecture 24: Complexity IX (PSPACE-complete, L, NL, NL-complete)

Lecture 9: Connecting PH, P/poly and BPP

Introduction to Computational Complexity

1 Deterministic Turing Machines

Theory of Computation Space Complexity. (NTU EE) Space Complexity Fall / 1

1 Rademacher Complexity Bounds

Intelligent Systems: Reasoning and Recognition. Perceptrons and Support Vector Machines

1 Identical Parallel Machines

Algorithms for parallel processor scheduling with distinct due windows and unit-time jobs

Lecture 4. 1 Circuit Complexity. Notes on Complexity Theory: Fall 2005 Last updated: September, Jonathan Katz

CSCE 551 Final Exam, April 28, 2016 Answer Key

Math 262A Lecture Notes - Nechiporuk s Theorem

Polygonal Designs: Existence and Construction

Lecture 10: Boolean Circuits (cont.)

COMPLEXITY THEORY. PSPACE = SPACE(n k ) k N. NPSPACE = NSPACE(n k ) 10/30/2012. Space Complexity: Savitch's Theorem and PSPACE- Completeness

De Morgan s a Laws. De Morgan s laws say that. (φ 1 φ 2 ) = φ 1 φ 2, (φ 1 φ 2 ) = φ 1 φ 2.

Umans Complexity Theory Lectures

P = k T IME(n k ) Now, do all decidable languages belong to P? Let s consider a couple of languages:

Advanced Topics in Theoretical Computer Science

Generalized Queries on Probabilistic Context-Free Grammars

Computational Complexity Theory. Markus Bläser, Holger Dell Universität des Saarlandes Draft November 14, 2016 and forever

Ma/CS 117c Handout # 5 P vs. NP

Computational Complexity Theory. Markus Bläser Universität des Saarlandes Draft January 23, 2014 and forever

Introduction to Discrete Optimization

A Simplified Analytical Approach for Efficiency Evaluation of the Weaving Machines with Automatic Filling Repair

Transcription:

Coputational Coplexity Theory, Fall 2010 Septeber 8 Lecture 5: Logspace reductions and copleteness Lecturer: Kristoffer Arnsfelt Hansen Scribe: Claes Højer Jensen Recall the given relation between classes: L NL P NP PSPACE EXP NEXP EXPSPACE... These classes are defined for two reasons: First to study coputation under resources such as tie and space, but also just as iportantly to help us understand the coputational coplexity of concrete coputational probles that we are interested in. It turns out that all the classes above have natural coplete probles. Recalling the notion of NP-copleteness, this is based on polynoial tie reduction. This is however not useable for lesser classes such as NL and P, so a weaker notion of reductions is needed. Definition 1. The language L f associated with a function f : Σ is L f = {< x, bin(j), y > x Σ, j N, y, f(x) j = y} L f will here work as a substitute for the funciton f. Definition 2. We say f is P-coputable if: f(x) = n O(1) and L f P. f is L-coputable if: f(x) = n O(1) and L f L. Definition 3. Let A Σ and B be languages. We say A p B (p stands for polynoial tie, stands for any-one, i.e. any instances ay be apped to one instance) if there is a P-coputable f so that x Σ, x A f(x) B We say A log B if there is an L-coputable f so that x Σ, x A f(x) B Let C be a class of languages. Definition 4. L is log -hard for C if for all L C : L log L. Definition 5. L is log -coplete for C if L is log hard for C, L C. Lea 6. (Transitivity) If A log B and B log C then A log Proof. Let the reductions be given by L-coputable functions f and g, i.e. we have L f L and L g L. Define h(x) = g(f(x)), and let M f, M g be logspace achines for L f, L g. We ust show that h is L-coputable. Note that since we have liited space available, we can t just copute and put f(x) on a tape, as an interediate result. We will now construct a logspace achine M h for L h. C 1

On input < x, bin(j), y >, M h will siulate M g with a fictitious input tape containing < f(x), bin(j), y >. We will aintain the position of the tapehead on the fictitious tape by a counter, stored on the work tape. Whenever M g requires the current sybol on the fictitious input tape, M h will run the achine M f to copute the sybol. M f will be able to read x fro the input tape of M h. Space analysis on input x: for M g : O(log( f(x) )) = O(log( x O(1) )) = O(log( x )). for counter: O(log( f(x) )) = O(log( x O(1) )) = O(log( x )). for M f : O(log( x )). Thus the space used by M h is O(log( x )). We know that NP is closed under reductions; so is all the other classes we have considered. Lea 7. Closure under reductions If B C and A log B then A C, for C = L, NL, P,..., Exaple of log-coplete proble in NL: Definition 8. STCON Instance: Directed graph G = (V, E), s, t V Question: Is there a path fro s to t? Theore 9. STCON is coplete for NL Proof. STCON NL: For this we have the following algorith: 1. v := s 2. for i = 0 to n 1 3. guess u V 4. if (v, u) / E, reject 5. if u = t, accept 6. v = u Space usage: O(log n), since we only need to store node index v, counter i, etc. NL-hardness: Let L NL, and let M be a nondeterinistic O(log n) space bounded achibe for L. We will assue that M has a unique accepting configuration. This we can easily do by odifying M, to clearing the work tape and place tape heads at cell 1, before accepting. Reduction: On input x, output: G: configuration graph of M on input x s: initial confiduration 2

t: accept configuration Since M is O(log n) space bounded, each configuration is encoded by a string of length O(log n). We can thus output the configuration graph, by looping over check pairs of string encoding configurations, and check if M can go fro one configuration to the next in 1 step. This can be done in O(log n) space. Theore 10. (Ieran-Szelepcsenyi) Let S(n) log(n). Then (recall that co - C = {L L C}) co - NSPACE(S(n)) = NSPACE(S(n)) Proof. We will prove that STCON NL. Then the stateent of the theore follows by running the NL algorith on the configuration graph of a O(S(n)) space bounded nondeterinistic achine. We first note that siply switching accept and reject in the algorith fro the proof of STCON is in NL does not work: this would not copute the copleent of STCON. Crucial idea: Let V i = set of vertices reachable fro s in i steps, and let C i = V i. If we are given C i, then we can nondeterinistically enuerate the vertices of V i and afterwards we can know for sure if we enuerated exactly the vertices in V i as follows: 1. count := 0 2. for u V 3. nondeterinistically guess a path fro s to u of length i, vertex by vertex. (done with earlier shown algorith) 4. if found 5. count := count + 1 6. if count = C i, correct enueration! Algorith for STCON : 1. C cur := 1 //C 0 = 1 2. for i = 1 to n 1 //copute C i, given C i 1 3. C prev := C cur, C cur = 0 4. for all v V //test if v V i 5. count := 0, include := false 6. for all u V //enuerate V i 1 7. nondeterinistically guess a patch fro s to u of length i 1 vertex by vertex 8. if (found) 9. count := count + 1 10. if ((u, v) E or u = v) 11. include := true 12. if count! = C prev reject // Enueration of V i 1 failed 13. if (include) C cur := C cur + 1 // At this point we have coputed C n 1 correctly. 3

14. count := 0 15. for all u V // Enuerate V n 1 to see if t V n 1 16. nondeterinistically guess a path fro s to u of length n 1 vertex by vertex 17. if(found) 18. count := count + 1 19. if(u = t) reject 20. if (count = C cur accept) // If enueration was succesful we can tell for sure if t V n 1 Boolean Circuits Inputs: x 1,..., x n 0, 1 Circuit: Directed acyclic graph. Nodes correspond to gates, edges to wires. indegree 0 nodes: labeled by variables indegree 1 nodes: labeled by 1 indegree 2 nodes: labeled by, specified output node C coputes a function f : {0, 1} {0, 1}. Circuit value proble, CVP: Instance: Circuit C on n inputs and concrete input x {0, 1} n. Question: Is C(x) = 1? Circuit-SAT: Instance: Circuit C. Question: Does there exist x 0, 1 n such that C(x) = 1? Theore 11. CVP is log coplete for P Proof. To show that CVP P, given a circuit together with an input, we siple evaluate the circuit botto up. To show log -hardness, let L P, and let M be p(n) tie bounded single-tape TM accepting L. Build circuit by tableu ethod. 4

In each coordinate (i, t) we encode the content of the tape in cell i, whether the tape head is scanning the cell, and if so, the state of the achine. Now given this inforation we can copute the contents of the cell just by looking at the 3 previous cells below, in the neighbor positions (see figure). Theore 12. Circuit-SAT is log coplete for NP Proof. This can again by proven by the tableau ethod. We have additional inputs to describe the nondeterinistic choices. These are fed to each coordinate. The reduction will on input x construct this circuit, and then hardwire x, leaving the inputs for the nondeterinistic choices be the only inputs left. 5