Polynomial Computable Function:: For Any Computes in Polynomial Time
Polynomial Computable Function:: For Any Computes in Polynomial Time
1
Language A is polynomial time reducible to
language B if there is a polynomial
computable function f such that:
w ∈ A ⇔ f ( w) ∈ B
2
Theorem:
Suppose that A is polynomial reducible to B.
If B ∈ P then A∈ P .
Proof:
Let M be the machine to accept B
Machine to accept A in polynomial time:
On input w :
1. Compute f (w)
2. Run M on input f (w)
3
3CNF formula:
( x1 ∨ x2 ∨ x3 ) ∧ ( x3 ∨ x5 ∨ x6 ) ∧ ( x3 ∨ x6 ∨ x4 ) ∧ ( x4 ∨ x5 ∨ x6 )
Language:
3SAT ={ w : w is a satisfiable
3CNF formula}
4
Clique:
A 5-clique
5
Theorem: 3SAT is polynomial time
reducible to CLIQUE
6
NP-Completeness
•It is in NP
7
Observation:
P = NP
8
Observation:
If we prove that
we cannot solve an NP-complete problem
in Deterministic Polynomial Time (P time)
then we know:
P ≠ NP
9
Cook’s Theorem:
Proof:
Convert a Non-Deterministic Turing Machine
to a Boolean expression
in conjunctive normal form
10
Other NP-Complete Problems:
•Vertex cover
•Hamiltonian Path