§5 Structural Complexity: NPc

Slides:



Advertisements
Similar presentations
Theory of Computing Lecture 18 MAS 714 Hartmut Klauck.
Advertisements

NP-Completeness: Reductions
FORMAL LANGUAGES, AUTOMATA AND COMPUTABILITY
The Theory of NP-Completeness
INHERENT LIMITATIONS OF COMPUTER PROGRAMS CSci 4011.
Complexity 11-1 Complexity Andrei Bulatov NP-Completeness.
Computability and Complexity 15-1 Computability and Complexity Andrei Bulatov NP-Completeness.
1 Polynomial Time Reductions Polynomial Computable function : For any computes in polynomial time.
Time Complexity.
CSE 421 Algorithms Richard Anderson Lecture 27 NP Completeness.
CS Master – Introduction to the Theory of Computation Jan Maluszynski - HT Lecture NP-Completeness Jan Maluszynski, IDA, 2007
1 The Theory of NP-Completeness 2012/11/6 P: the class of problems which can be solved by a deterministic polynomial algorithm. NP : the class of decision.
Lecture 22 More NPC problems
Theory of Computation, Feodor F. Dragan, Kent State University 1 NP-Completeness P: is the set of decision problems (or languages) that are solvable in.
Computational Complexity Theory Lecture 2: Reductions, NP-completeness, Cook-Levin theorem Indian Institute of Science.
Theory of Computing Lecture 17 MAS 714 Hartmut Klauck.
CSEP 521 Applied Algorithms Richard Anderson Lecture 10 NP Completeness.
INHERENT LIMITATIONS OF COMPUTER PROGRAMS CSci 4011.
NP-complete Problems SAT 3SAT Independent Set Hamiltonian Cycle
Week 10Complexity of Algorithms1 Hard Computational Problems Some computational problems are hard Despite a numerous attempts we do not know any efficient.
1 Design and Analysis of Algorithms Yoram Moses Lecture 11 June 3, 2010
NP-Complete Problems. Running Time v.s. Input Size Concern with problems whose complexity may be described by exponential functions. Tractable problems.
NP-completeness Class of hard problems. Jaruloj ChongstitvatanaNP-complete Problems2 Outline  Introduction  Problems and Languages Turing machines and.
CSE 6311 – Spring 2009 ADVANCED COMPUTATIONAL MODELS AND ALGORITHMS Lecture Notes – Feb. 3, 2009 Instructor: Dr. Gautam Das notes by Walter Wilson.
NP Completeness Piyush Kumar. Today Reductions Proving Lower Bounds revisited Decision and Optimization Problems SAT and 3-SAT P Vs NP Dealing with NP-Complete.
CSC 413/513: Intro to Algorithms
NP-complete Languages
CSCI 2670 Introduction to Theory of Computing December 2, 2004.
CSCI 2670 Introduction to Theory of Computing December 7, 2005.
CSE 421 Algorithms Richard Anderson Lecture 27 NP-Completeness Proofs.
CSC 3130: Automata theory and formal languages Andrej Bogdanov The Chinese University of Hong Kong NP-complete.
Computability Examples. Reducibility. NP completeness. Homework: Find other examples of NP complete problems.
 2005 SDU Lecture15 P,NP,NP-complete.  2005 SDU 2 The PATH problem PATH = { | G is a directed graph that has a directed path from s to t} s t
CSE 332: NP Completeness, Part II Richard Anderson Spring 2016.
The Theory of NP-Completeness
NP-Completeness A problem is NP-complete if: It is in NP
The NP class. NP-completeness
P & NP.
Computational Complexity Theory
Richard Anderson Lectures NP-Completeness
Richard Anderson Lecture 26 NP-Completeness
Richard Anderson Lecture 26 NP-Completeness
NP-Completeness (36.4-5) P: yes and no in pt NP: yes in pt NPH  NPC
NP-Completeness (36.4-5/34.4-5)
NP-Completeness Yin Tat Lee
CS21 Decidability and Tractability
Intro to Theory of Computation
CS154, Lecture 16: More NP-Complete Problems; PCPs
ICS 353: Design and Analysis of Algorithms
Richard Anderson Lecture 25 NP-Completeness
Richard Anderson Lecture 28 NP-Completeness
Richard Anderson Lecture 29 NP-Completeness
Richard Anderson Lecture 29 Complexity Theory
Chapter 34: NP-Completeness
Richard Anderson Lecture 28 NP Completeness
NP-Complete Problems.
CSC 4170 Theory of Computation The class NP Section 7.3.
Richard Anderson Lecture 26 NP-Completeness
NP-Completeness Yin Tat Lee
Umans Complexity Theory Lectures
NP-Completeness Yin Tat Lee
The Theory of NP-Completeness
CS154, Lecture 16: More NP-Complete Problems; PCPs
Umans Complexity Theory Lectures
Instructor: Aaron Roth
Instructor: Aaron Roth
§4 Computational Complexity
The Satisfiability Problem
§6 PSPACE and Polynomial Hierarchy
Lecture 23 NP-Hard Problems
Presentation transcript:

§5 Structural Complexity: NPc Comparing Problems: polynomial-time reduction Reductions: CLIQUE p IS ≼p SAT p 3SAT ≼p IS NP-completeness, Master Reduction coNP, Ladner's Theorem

Comparing Problems, again CLIQUE = { G,k | G contains a k-clique } IS={ G,k : G has k pairwise non-connected vertices} p N N f L L' LC L'C For L,L'N write L≼ L' if exists a computable f: NN such that x: xL  f(x)L'. polynomial-time p a) L'P  LP a) L' decidable  so L. b) L ≼ L' ≼ L''  L≼ L'' p p p

Reduction IS ≼p SAT Let G consist of vertices V={1,..,n} and edges E. Goal: Upon input of (the encoding of) a graph G and kN, produce in polynomial time a CNF formula  such that:  satisfiable iff G contains ≥k independent vertices Let G consist of vertices V={1,..,n} and edges E. Consider Boolean variables xv,i, v  V, i=1...k and clauses Ki := vV xv,i, i=1...k and xv,i  xv,j, v  V, 1≤i<j≤k and xu,i  xv,j, {u,v}  E, 1≤i<j≤k Length of : O(k·n+n·k2+n2k2)=O(n2k2) Computational cost of (G,k) → : polyn. in n+log k Vertex v is #i among the k independent. There is an i-th vertex Vertex v cannot be both #i and #j. No adjacent vertices are independent. since k≤n.

Example Reduction: 4SAT vs. 3SAT 4-SAT: Is formula Φ(Y) in 4-CNF satisfiable? 3-SAT: Is formula Φ(Y) in 3-CNF satisfiable? Given  = (a  b  c  d)  (p  q  r  s)  … with literals a,b,c,d, p,q,r,s,…. Introduce new variables u,v,… and consider ' := ( a  b  u )  (u  c  d )  ( p  q  v)  (v   r  s )  … variables, possibly negated f:   ' For L,L'N write L≼ L' if exists a computable f: NN such that x: xL  f(x)L'.

Reduction 3SAT ≼p IS (k,1) (1,1) (k,2) (1,2) (k,3) (1,3) Produce, given a 3-CNF term , within polynomial time a graph G and integer k such that it holds: iff G contains k pairwise non-adjacent vertices.  is satisfiable e.g. ( u .... )  ( .. u .. )  ( .. .. u )  ( u  .. .. )  = C1  C2 …  Ck, Ci = xi1  xi2  xi3, xis literals V:= { (i,1),…(i,3): i≤k }, E:= { {(i,s),(j,t)} : i=j or xis= xjt } (k,1) (k,2) (k,3) (1,1) (1,2) (1,3) Richard Karp

Problems of similar complexity unknown yet Showed: CLIQUE p IS ≼p SAT p 3SAT ≼p IS. These 4 problem have about same complexity: Either all are belong to P, or none of them. We will show: Also TSP, HC, VC and many further problems in NP belong to this class called NPc. And will show: These are ‘hardest‘ problems in NP. Cook–Levin Theorem: L 2 NP : L ≼p SAT. That is, either all or none of the problems in NPc can be decided in polynomial time. A deterministic WHILE+ program could simulate any non-deterministic one with polynomial slowdown! In the first case:

EXP Complexity Class Picture PSPACE CH #P PH PNP co-NP NP P Def: ANP is NP-complete if L ≼p A holds for every LNP. PSPACE complete PSPACE Theorem (Cook'72/Levin'71): SAT is NP-complete! CH #P PH Lemma: For A NP-complete and A ≼p B NP, B is also NPc. PNP coNP-complete NP- complete co-NP NP Now know ≈500 natural problems NP-complete… P

unSAT := {  Boolean term, x: (x)=0 }  coNPc Scenarios for P≠NP coNP := { LN : N\L  NP } unSAT := {  Boolean term, x: (x)=0 }  coNPc Theorem [Ladner'75]: If P≠NP, there exists LNP \ (PNPc) NP = coNP P = coP coNPc NPc NP coNP NP coNP P NP coNP P = coP

Master Reductions L = {xN: y, ℓ(y)≤poly(ℓ(x)), x,yV }, VP SAT = {  :  Boolean term, y1,…ym: (y1,…ym)=1} Cook/Levin Theorem: SAT is NP-complete! Proof (Sketch): Fix LNP and VP. Fix WHILE+ program B deciding V in time poly(n). Express "bin(z0,…zk-1)V" as Boolean term "k(z0,…zk-1)=1" of length poly(k). Then bin(x0,…xn-1)L  y0,…ym-1{0,1}: n+k(x, y)=1. N x →  := n+k(bin(x), · ) Thm: The following problem UNP is NP-complete: { A,x,2N : nondetermin. WHILE+ program A accepts input x within at most N steps } L = {xN: y, ℓ(y)≤poly(ℓ(x)), x,yV }, VP

SubsetSum is NP-complete { a1,…aN,b | a1,…aN,bN, 1,…N{0,1} : b=i ai·i } SubsetSumNP √ Show: 3SAT ≼p SubsetSum In polyn.time: 3CNF  → AN and bN s.t. satisf. assignm. of   BA: b=aB a Eg. Φ = (x1  x3  x5)  (x1  x5  x4)  (x2  x2  x5) v1 := 100 10000 v2 := 000 01000 v3 := 000 00100 v4 := 010 00010 v5 := 110 00001 v1' := 010 10000 v2' := 002 01000 v3' := 100 00100 v4' := 000 00010 v5' := 001 00001 b := 444 11111 c1:= 100 00000 d1:= 200 00000 c2:= 010 00000 d2:= 020 00000 c3:= 001 00000 d3:= 002 00000 m clauses in n var.s → 2n+2m+1 values à n+m dec.digits A NP-complete, BNP and A ≼p B  B also NP-complete.