Lecture 19: Finish NP-Completeness, conp and Friends

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

conp, Oracles, Space Complexity

Lecture 20: conp and Friends, Oracles in Complexity Theory

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

CS154, Lecture 13: P vs NP

CS154, Lecture 13: P vs NP

Chapter 7: Time Complexity

BBM402-Lecture 11: The Class NP

Computability Theory

The Class NP. NP is the problems that can be solved in polynomial time by a nondeterministic machine.

Time Complexity. CS60001: Foundations of Computing Science

1 Non-deterministic Turing Machine

Intro to Theory of Computation

1. Introduction Recap

CSE 135: Introduction to Theory of Computation NP-completeness

NP Complete Problems. COMP 215 Lecture 20

Theory of Computation CS3102 Spring 2014 A tale of computers, math, problem solving, life, love and tragic death

conp = { L L NP } (1) This problem is essentially the same as SAT because a formula is not satisfiable if and only if its negation is a tautology.

1.1 P, NP, and NP-complete

Lecture 24: Randomized Complexity, Course Summary

CS5371 Theory of Computation. Lecture 19: Complexity IV (More on NP, NP-Complete)

Intro to Theory of Computation

Lecture 16: Time Complexity and P vs NP

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

NP and Computational Intractability

Lecture 17: Cook-Levin Theorem, NP-Complete Problems

CSE 555 HW 5 SAMPLE SOLUTION. Question 1.

Turing Machines and Time Complexity

CISC 4090 Theory of Computation

CS21 Decidability and Tractability

CS21 Decidability and Tractability

CSE 105 THEORY OF COMPUTATION

CSC 1700 Analysis of Algorithms: P and NP Problems

CSE 105 THEORY OF COMPUTATION

FORMAL LANGUAGES, AUTOMATA AND COMPUTABILITY

13.1 Nondeterministic Polynomial Time

CSE 105 Theory of Computation

CS20a: NP completeness. NP-complete definition. Related properties. Cook's Theorem

CSE 105 THEORY OF COMPUTATION

Finish K-Complexity, Start Time Complexity

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

Introduction to Complexity Theory

FORMAL LANGUAGES, AUTOMATA AND COMPUTABILITY. FLAC (15-453) Spring l. Blum TIME COMPLEXITY AND POLYNOMIAL TIME;

NP-Completeness. Sections 28.5, 28.6

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

NP and NP Completeness

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

The knapsack Problem

More Completeness, conp, FNP,etc. CS254 Chris Pollett Oct 30, 2006.

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

Theory of Computation Time Complexity

Theory of Computation Chapter 9

P and NP. Or, how to make $1,000,000.

TIME COMPLEXITY AND POLYNOMIAL TIME; NON DETERMINISTIC TURING MACHINES AND NP. THURSDAY Mar 20

Limitations of Algorithm Power

Automata Theory CS S-18 Complexity Theory II: Class NP

Lecture 18: More NP-Complete Problems

Computational Models Lecture 11, Spring 2009

Summer School on Introduction to Algorithms and Optimization Techniques July 4-12, 2017 Organized by ACMU, ISI and IEEE CEDA.

COP 4531 Complexity & Analysis of Data Structures & Algorithms

NP Completeness and Approximation Algorithms

Limits of Feasibility. Example. Complexity Relationships among Models. 1. Complexity Relationships among Models

NP-Completeness. A language B is NP-complete iff B NP. This property means B is NP hard

Lecture 13, Fall 04/05

Computability and Complexity

Lecture 22: PSPACE

Final exam study sheet for CS3719 Turing machines and decidability.

Chapter 2 : Time complexity

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

Cook-Levin Theorem. SAT is NP-complete

NP-Complete Problems. More reductions

Umans Complexity Theory Lectures

COSE215: Theory of Computation. Lecture 20 P, NP, and NP-Complete Problems

8.1 Polynomial-Time Reductions. Chapter 8. NP and Computational Intractability. Classify 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.

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

Agenda. What is a complexity class? What are the important complexity classes? How do you prove an algorithm is in a certain class

Essential facts about NP-completeness:

SAT, NP, NP-Completeness

NP-Complete Reductions 1

CS Lecture 28 P, NP, and NP-Completeness. Fall 2008

Topics in Complexity Theory

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

Could we potentially place A in a smaller complexity class if we consider other computational models?

Polynomial-time reductions. We have seen several reductions:

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?

Polynomial-time Reductions

CS 3719 (Theory of Computation and Algorithms) Lectures 23-32

Lecture 4 : Quest for Structure in Counting Problems

Algorithms and Theory of Computation. Lecture 19: Class P and NP, Reduction

Easy Problems vs. Hard Problems. CSE 421 Introduction to Algorithms Winter Is P a good definition of efficient? The class P

P vs. NP Classes. Prof. (Dr.) K.R. Chowdhary.

ECE 695 Numerical Simulations Lecture 2: Computability and NPhardness. Prof. Peter Bermel January 11, 2017

NP-Completeness. NP-Completeness 1

q FORMAL LANGUAGES, AUTOMATA AND COMPUTABILITY. FLAC (15-453) Spring L. Blum. REVIEW for Midterm 2 TURING MACHINE

Applied Computer Science II Chapter 7: Time Complexity. Prof. Dr. Luc De Raedt. Institut für Informatik Albert-Ludwigs Universität Freiburg Germany

Lecture 18: PCP Theorem and Hardness of Approximation I

NP-Completeness. CptS 223 Advanced Data Structures. Larry Holder School of Electrical Engineering and Computer Science Washington State University

Computational Complexity and Intractability: An Introduction to the Theory of NP. Chapter 9

Transcription:

6.045 Lecture 19: Finish NP-Completeness, conp and Friends 1

Polynomial Time Reducibility f : Σ* Σ* is a polynomial time computable function if there is a poly-time Turing machine M that on every input w, halts with just f(w) on its tape Language A is poly-time reducible to language B, written as A P B, if there is a poly-time computable f : Σ* Σ* so that: w A f(w) B f is a polynomial time reduction from A to B Note there is a k such that for all w, f(w) k w k 2

Definition: A language B is NP-complete if: 1. B NP 2. Every A in NP is poly-time reducible to B That is, A P B When this is true, we say B is NP-hard NP-complete problems: 3SAT, SAT, CLIQUE, IS, VC, SUBSET-SUM, KNAPSACK, PARTITION, BIN-PACKING, 3

Two Problems Let G denote a graph, and s and t denote nodes. SHORTEST PATH = {(G, s, t, k) G has a simple path of < k edges from s to t } LONGEST PATH = {(G, s, t, k) G has a simple path of > k edges from s to t } Are either of these in P? Are both of them? 4

HAMPATH = { (G,s,t) G is an directed graph with a Hamiltonian path from s to t} Theorem: HAMPATH is NP-Complete (1) HAMPATH NP (2) 3SAT P HAMPATH Sipser (p.314-318) 5

HAMPATH P LONGEST-PATH LONGEST-PATH = {(G, s, t, k) G has a simple path of > k edges from s to t } Can reduce HAMPATH to LONGEST-PATH by observing: (G, s, t) 2 HAMPATH (G, s, t, V -2) 2 LONGEST-PATH Therefore LONGEST-PATH is NP-hard. 6

conp and Friends 7

Definition: conp = { L L NP } What does a conp computation look like? A co-nondeterministic machine has multiple computation paths, and has the following behavior: - the machine accepts if all paths reach accept state - the machine rejects if at least one path reaches reject state 8

Definition: conp = { L L NP } What does a conp computation look like? In NP algorithms, we can use a guess instruction in pseudocode: Guess string y of x k length and the machine accepts iff some y leads to an accept state In conp algorithms, we can use a try all instruction: Try all strings y of x k length and the machine accepts iff every y leads to an accept state 9

TAUTOLOGY = { is a Boolean formula and every variable assignment satisfies } Theorem: TAUTOLOGY is in conp How would we write pseudocode for a conp machine that decides TAUTOLOGY? How would we write TAUTOLOGY as the complement of some NP language? 10

Is P conp? Yes! L P implies that L P (hence L NP) In general, deterministic complexity classes are closed under complement 11

Is NP = conp? THIS IS AN OPEN QUESTION! It is believed that NP conp 12

conp P NP 13

Definition: A language B is conp-complete if 1. B conp 2. For every A in conp, there is a polynomial-time reduction from A to B (B is conp-hard) 14

UNSAT = { is a Boolean formula and no variable assignment satisfies } Theorem: UNSAT is conp-complete Proof: UNSAT conp (why?) (2) UNSAT is conp-hard: Let A conp. We show A P UNSAT On input w, transform w into a formula using Cook-Levin via an NP machine N for A w A SAT w A SAT w A UNSAT w A UNSAT 15

UNSAT = { is a Boolean formula and no variable assignment satisfies } Theorem: UNSAT is conp-complete TAUTOLOGY = { is a Boolean formula and every variable assignment satisfies } = { UNSAT} Theorem: TAUTOLOGY is conp-complete (1) TAUTOLOGY conp (already shown) (2) TAUTOLOGY is conp-hard: UNSAT P TAUTOLOGY: Given formula, output 16

Is P = NP conp? THIS IS AN OPEN QUESTION! 17

An Interesting Problem in NP conp FACTORING = { (m, n) m > n > 1 are integers, there is a prime factor p of m where n p < m } If FACTORING P, we could expect to break most public-key cryptography currently in use! Theorem: FACTORING 2 NP conp 18

PRIMES = {n n is a prime integer} Theorem (Pratt 70s): PRIMES NP conp PRIMES is in P Manindra Agrawal, Neeraj Kayal and Nitin Saxena Ann. of Math. Volume 160, Number 2 (2004), 781-793. Abstract We present an unconditional deterministic polynomialtime algorithm that determines whether an input number is prime or composite. 19

FACTORING = { (m, n) m, n > 1 are integers, there is a prime factor p of m where n p < m } Theorem: FACTORING NP conp Proof: (1) FACTORING NP A prime factor p of m such that p n is a proof that (m,n) is in FACTORING (2) FACTORING conp The prime factorization p 1 e1 p k ek of m is a proof that (m,n) is not in FACTORING: Verify each p i is prime, and p 1 e1 p k ek = m Verify that for all i=1,,k that p i < n

conp TAUTOLOGY FACTORING P NP SAT CLIQUE Decidable 22