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).

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

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

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

2 P vs. NP and Diagonalization

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

CS154, Lecture 17: conp, Oracles again, Space Complexity

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

Lecture 3: Nondeterminism, NP, and NP-completeness

SOLUTION: SOLUTION: SOLUTION:

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

CSE200: Computability and complexity Space Complexity

Lecture 6: Oracle TMs, Diagonalization Limits, Space Complexity

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

NP-Completeness I. Lecture Overview Introduction: Reduction and Expressiveness

Computability and Complexity Theory: An Introduction

The Polynomial Hierarchy

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

Complexity Theory. Jörg Kreiker. Summer term Chair for Theoretical Computer Science Prof. Esparza TU München

The Cook-Levin Theorem

Notes for Lecture 3... x 4

CS21 Decidability and Tractability

Notes on Computer Theory Last updated: November, Circuits

conp, Oracles, Space Complexity

15.1 Proof of the Cook-Levin Theorem: SAT is NP-complete

Lecture 2. 1 More N P-Compete Languages. Notes on Complexity Theory: Fall 2005 Last updated: September, Jonathan Katz

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

Lecture 18: PCP Theorem and Hardness of Approximation I

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

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

Notes on Space-Bounded Complexity

1 Agenda. 2 History. 3 Probabilistically Checkable Proofs (PCPs). Lecture Notes Definitions. PCPs. Approximation Algorithms.

1 Computational problems

Complexity Theory VU , SS The Polynomial Hierarchy. Reinhard Pichler

Outline. Complexity Theory EXACT TSP. The Class DP. Definition. Problem EXACT TSP. Complexity of EXACT TSP. Proposition VU 181.

P is the class of problems for which there are algorithms that solve the problem in time O(n k ) for some constant k.

Advanced topic: Space complexity

CS151 Complexity Theory. Lecture 1 April 3, 2017

Lecture 20: conp and Friends, Oracles in Complexity Theory

Definition: conp = { L L NP } What does a conp computation look like?

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

satisfiability (sat) Satisfiability unsatisfiability (unsat or sat complement) and validity Any Expression φ Can Be Converted into CNFs and DNFs

1 Circuit Complexity. CS 6743 Lecture 15 1 Fall Definitions

1 Reductions and Expressiveness

DRAFT. Diagonalization. Chapter 4

Notes on Space-Bounded Complexity

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

15-451/651: Design & Analysis of Algorithms October 31, 2013 Lecture #20 last changed: October 31, 2013

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

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

Announcements. Friday Four Square! Problem Set 8 due right now. Problem Set 9 out, due next Friday at 2:15PM. Did you lose a phone in my office?

Space and Nondeterminism

Circuits. Lecture 11 Uniform Circuit Complexity

1 PSPACE-Completeness

Complexity Theory. Jörg Kreiker. Summer term Chair for Theoretical Computer Science Prof. Esparza TU München

Lecture 3: Reductions and Completeness

Lecture 10: Boolean Circuits (cont.)

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

Lecture 22: PSPACE

Umans Complexity Theory Lectures

SAT, NP, NP-Completeness

Essential facts about NP-completeness:

6.045: Automata, Computability, and Complexity (GITCS) Class 15 Nancy Lynch

CS256 Applied Theory of Computation

Complexity Theory. Jörg Kreiker. Summer term Chair for Theoretical Computer Science Prof. Esparza TU München

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

CS154, Lecture 13: P vs NP

Lecture 8. MINDNF = {(φ, k) φ is a CNF expression and DNF expression ψ s.t. ψ k and ψ is equivalent to φ}

Undecidability and Rice s Theorem. Lecture 26, December 3 CS 374, Fall 2015

Lecture 22: Quantum computational complexity

Complexity Classes V. More PCPs. Eric Rachlin

1. Introduction Recap

CS151 Complexity Theory. Lecture 4 April 12, 2017

UC Berkeley CS 170: Efficient Algorithms and Intractable Problems Handout 22 Lecturer: David Wagner April 24, Notes 22 for CS 170

Notes for Lecture 3... x 4

On the Computational Hardness of Graph Coloring

Umans Complexity Theory Lectures

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

CSE 555 HW 5 SAMPLE SOLUTION. Question 1.

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

Polynomial time reduction and NP-completeness. Exploring some time complexity limits of polynomial time algorithmic solutions

MTAT Complexity Theory October 20th-21st, Lecture 7

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

Complexity Theory. Knowledge Representation and Reasoning. November 2, 2005

CS154, Lecture 13: P vs NP

NP Completeness. CS 374: Algorithms & Models of Computation, Spring Lecture 23. November 19, 2015

Chapter 2. Reductions and NP. 2.1 Reductions Continued The Satisfiability Problem (SAT) SAT 3SAT. CS 573: Algorithms, Fall 2013 August 29, 2013

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

NP, polynomial-time mapping reductions, and NP-completeness

Notes for Lecture 2. Statement of the PCP Theorem and Constraint Satisfaction

Notes on Complexity Theory Last updated: October, Lecture 6

6-1 Computational Complexity

COP 4531 Complexity & Analysis of Data Structures & Algorithms

CS154, Lecture 15: Cook-Levin Theorem SAT, 3SAT

NP Completeness. Richard Karp, 1972.

LTCC Course: Graph Theory 2017/18 3: Complexity and Algorithms

Review of Basic Computational Complexity

Lecture 4 : Quest for Structure in Counting Problems

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

A An Overview of Complexity Theory for the Algorithm Designer

: Computational Complexity Lecture 3 ITCS, Tsinghua Univesity, Fall October 2007

Transcription:

CS 221: Computational Complexity Prof. Salil Vadhan Lecture Notes 4 February 3, 2010 Scribe: Jonathan Pines 1 Agenda P-/NP- Completeness NP-intermediate problems NP vs. co-np L, NL 2 Recap Last time, we ended with Turing Machine simulation by boolean circuits (with fan-in 2 using and, or, not gates) and saw the following theorem: Theorem 1 Let M be a time t(n) TM, such that log t(n) is space-constructible. exists a sequence C 1, C 2,... of boolean circuits such that the following properties hold: Then there 1. 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). 2. The circuits are polynomially bounded in size (number of gates), i.e. C n poly(t(n)). 3. (log-space-uniformity) There exists a log-space (space O(log t(n))) TM M constructing the circuits, i.e. such that n, M (1 n ) = C n. 3 P-/NP- Completeness with Circuits Now, we examine P and NP in the framework of circuits. 3.1 P as Circuits Corollary 2 The set of languages decidable by log-space-uniform families of polynomially-sized boolean circuits is equal to P. ( ) Follows from Theorem 1. ( ) Given a family of circuits and an input, we can use log-space-uniformity to construct the appropriate circuit, and evaluate it gate by gate, both in poly-time. 1

So, one approach to the P vs NP problem is to prove that some NP problem requires superpolynomial-sized circuits to decide it, which by Corollary 2 would show P NP. Intuitively, circuits seem easier to reason about than Turing Machines, and historically there was a lot of excitement around this approach. Unfortunately, proving lower bounds on the number of gates needed in a circuit is hard, and the best known bound for an NP problem is something like 5n. Any super-linear lower bound would be a major breakthrough. It is currently believed that even without the assumption of uniformity, NP-complete problems that require super-polynomial circuits. Theorem 3 The following language is P-complete with respect to l : Circuit Value = { C, x : C(x) = 1}. Recall that l refers to log-space reduction; note that using poly-time reductions, anything in P is P-complete. ( P) The circuit can be evaluated in the input in time polynomial in the circuit size. (P-hard) Given a language L P, let M be a poly-time TM deciding L. Apply Theorem 1 to get a family {C n } of circuits, and then use log-space-uniformity to get a log-space reduction to Circuit Value since x L M(x) = 1 C x (x) = 1 C x, x Circuit Value. 3.2 Other P-complete problems Linear Programming (see Problem Set 1). Max-flow. As a corollary to Theorem 3, one can show that if any of these problems is in L, then P = L. The same can be said of other complexity classes within P. If any of these can be efficiently parallelized, then so can all of P. 3.3 Circuit Satisfiability Theorem 4 The following language is NP-complete with respect to l : Circuit Satisfiability = {C : x : C(x) = 1}. ( NP) The satisfying assignment serves as witness. (NP-hard) Given a language L NP, let M be a poly-time verifier for L. Apply Theorem 3 to the verifier to get a family {C n } of circuits such that C n+p(n) (x, u) = M(x, u), where n = x (and maybe off by a couple for divider between the pair). Then, given an input x, we can use logspace-uniformity to compute C n+p(n), fix x in the circuit to get a new circuit C x ( ) = C n+p(n) (x, ), and output C x. Noting that x L M accepts C x is satisfiable, we get a log-space reduction of L to Circuit Satisfiability as desired. Theorem 5 3SAT is NP-complete. 2

( NP) A satisfying assignment serves as witness. (NP-hard) We reduce Circuit Satisfiability to 3SAT. Given a circuit C with inputs x 1,..., x n and m gates, we will construct a 3-CNF formula φ that is satisfiable iff the circuit is. To do this, we introduce variables g 1,..., g m for the m gates of C. Then for each gate with inputs (x, y) and output z (where the inputs can be x s or g s), we add a term for each assignment to (x, y, z) that is not consistent with the gate operation. For example, if the gate is an OR gate, then the term x y z ensures that (x, y, z) = (0, 0, 1) will not satisfy φ. The general fact at play here is that any function on k variables can be written as a k-cnf formula using one clause for each unsatisfying assignment. Finally, we take the conjunction of the output value g m with all of these terms so that the formula is satisfiable if and only if there is a valid execution of the circuit resulting in the output g m = 1, as desired. Note that we have not claimed 3SAT is as powerful as a Turing Machine (false), but rather that a 3SAT instance can verify the computations of a boolean circuit or Turing Machine. The intuition is that the freedom introduced by the new variables g when finding a witness makes it simpler to verify solutions. 4 NP-intermediate Problems Under the assumption that P NP, one might question whether there are languages in NP that are neither in P nor NP-complete. 4.1 Ladner s Theorem Theorem 6 (Ladner s Theorem) If P NP, then there exists a language L NP such that L / P and L is not NP-complete. We call such languages NP-intermediate languages. We omit the proof here; see Arora-Barak. The basic idea is to start with L 0 NP \ P, and then obtain L by blowing large holes in L 0 (i.e. throwing out large intervals of strings). Each hole serves to rule out one polynomial-time reduction from SAT to L 0, and each gap between the holes serves to rule out one polynomial-time algorithm for L. This is possible by taking the holes and the gaps to be sufficiently large. To ensure that L remains in NP, lazy diagonalization is used. See also Problem Set 1 & section for other evidence for the existence of NP-intermediate problems. 4.2 Natural candidates for NP-intermediateness Factoring integers (see PS1). Finding Nash equilibria, e.g. in bimatrix games. Anything in (NP co-np) \ P. TFNP - total search problems; subclass PPAD of fixed-point problems (including finding Nash equilibria). BQP. 3

SZK. Lots more. Proposition 7 If there exists some language L NP co-np that is NP-hard with respect to Cook reduction (i.e. poly-time given an L-oracle), then NP = co-np. (Common belief is that NP co-np, so there is probably no NP-hard language in NP co-np.) 5 NP vs. co-np Claim 8 NP = co-np iff all boolean propositions have poly-sized proofs of validity, with respect to some poly-time checkable proof system. Proof Sketch: of membership. Tautologies is in co-np, and NP languages allow for poly-time verifiable proofs The study of Proof Complexity approaches NP vs. co-np by attempting to find tautologies that have a provably super-polynomial lower bound for proof length in natural proof systems; this has been successful for relatively weak proof systems (like Resolution) but elusive for stronger systems (like Frege, or Zermelo-Frankel Set Theory). The intuition is that we can t have poly-sized certificates for exponentially many inputs. Proof Complexity is a very active area of research that we unfortunately will not have time to say more about. 6 Space Complexity: L=Log-space 6.1 Review We only count the number of cells used on work tapes. Input/output are read/write only, respectively L = SPACE(log n) L P, since the number of configurations of an L-space machine is at most polynomial. 6.2 Why study L? L is a natural point at which nontrivial algorithms exist, such as +,,, and undirected connectivity (UPATH). The latter two are nontrivial and were discovered in the last 5 years. Massive datasets can t be held in memory. For this, people use even more restricted models, like log-space streaming and k-pass algorithms. L is closely related to parallel computation. But, NP = L is not ruled out. 4

6.3 Addition in L In log-space, we can store pointers to input/output by maintaining the index of a given digit. Addition can be computed one digit at a time by maintaining pointers to the current input/output as well as a carry bit at each step. We print the digits from left to right, starting with the least significant bit. What if we wanted to print the output of addition in reverse order? We can t just reverse the output, because the length can be n or n + 1, where n is the length of the summands. To get around this, we run the entire addition process without outputting anything except the last (most significant) bit, and then repeat the addition process for each other bit (stopping each addition when we get the bit needed at that step). This algorithm suggests the general result that follows: 6.4 Closure of L under composition Proposition 9 If f 1, f 2 are computable in log-space, then so is f 2 f 1. Note that we can t simply write the output of f 1 to a work tape, because the output may be polynomial while the tape is constrained to logarithmic size. The intuition is that as for reversed addition, we compute each output bit of f 1 as f 2 actually needs to read it. Slightly more formally, we maintain an input pointer for f 2, and each time it wants to read a value, we simulate f 1 (without printing) until its output head matches f 2 s input head, at which point we print that bit and continue executing f 2. This can be thought of as a virtual tape for the input to f 2, where each input bit is printed as it is needed for access. Using this model, we can effectively run f 2 on the output of f 1 while printing only one bit at a time of f 1 s output onto the work tape. Corollary 10 Log-space reductions are transitive. Corollary 11 A l B, B L A L. 7 NL Next, we look at nondeterministic log-space. Theorem 12 The following language is NL-complete: PATH = { G, s, t : G is a directed graph with an s t path}. Note that the undirected version of this language is in L. ( NL) Let v = s, repeatedly (up to n times) replace v with a nondeterministically chosen one of its neighbors, and halt/accept if v = t. Space required is O(log n) to remember v and a counter for the loop. (NL-hard) Next time - think about it! 5

8 Next Time Finish proof of Theorem 12. Consequences: proving things about NL by reasoning about PATH. NL = co-nl. NPSPACE = PSPACE. 6