• 沒有找到結果。

NP ≡ Polynomial NTM I

N/A
N/A
Protected

Academic year: 2022

Share "NP ≡ Polynomial NTM I"

Copied!
8
0
0

加載中.... (立即查看全文)

全文

(1)

NP ≡ Polynomial NTM I

Polynomial verifier ⇔ polynomial NTM Idea:

“⇒” NTM by guessing certificate

“⇐” using NTM’s accepting branch as certificate Proof:

“⇒”: now we have a verifier V in time nk

(2)

NP ≡ Polynomial NTM II

Recall the definition below

A = {w | V accepts hw , ci for some strings c}

We have

|c| ≤ nk

because to handle hw , ci in nk, |c| should be bounded by nk

Use an NTM to

1 nondeterministically select c

2 run V on hw , ci

(3)

NP ≡ Polynomial NTM III

That is, run c in parallel and each is polynomial We have that for any w ∈ A, the NTM accepts it in polynomial time

“⇐”: now w is accepted by a polynomial NTM Let c be any accepting branch

Note that for polynomial NTM, each branch is polynomial

Then we have a verifier V that handles input hw , ci in polynomial time

Note: the definition of V requires only “some c.”

So finding one is sufficient

(4)

SUBSET-SUM I

Given x1, . . . , xk and t, is sum of a subset = t?

Formally

{hs, ti | s = {x1, . . . , xk} and ∃ {y1, . . . , yl} ⊂ {x1, . . . , xk} such that X

yi = t}

Example

h{4, 11, 16, 21, 27}, 25i OK as 4 + 21 = 25

(5)

SUBSET-SUM II

Note: allow repetition here

h{4, 11, 11, 16, 21, 27}, 25i We prove that this problem is NP Idea: the subset is the certificate.

Consider any input

hhs, ti, ci We

1 check if P ci = t

(6)

SUBSET-SUM III

2 check if all ci ∈ s

If both pass, accept; otherwise, reject Here

length of c < length of s

The verification can be done in polynomial time

(7)

P vs. NP I

Roughly

P: problems decided quickly NP: problems verified quickly Question: is P = NP?

This is one of the greatest unsolved problems Most believe P 6= NP

(8)

NP-completeness I

It has been shown that some problems in NP are related

For certain NP problems:

If ∃ a polynomial algorithm for one NP ⇒ P = NP These problems are called NP-complete problems They are useful to study the issue of P versus NP To prove P 6= NP: only need to focus on

NP-complete problems

To prove P=NP: need only polynomial algorithms for an NP-complete problem

參考文獻

相關文件

The NP-completeness of finding the mini- mum diameter subgraph with a budget constraint was es- tablished in [17], while a polynomial-time algorithm for finding the minimum

• As the binary quadratic programming program is NP-hard in general, identifying polynomially solvable subclasses of binary quadratic programming problems not only offers the-

2002, Kanpur, India, Agrawal, and university students Kayal and Saxena found a polynomial time algorithm for the primality testing problem, thereby proves it is a problem in class

[r]

[r]

這些問題目前尚未找到可以在 polynomial time 內解決的 algorithm.. 這些問題目前尚未被證明無法在 polynomial time

If P6=NP, then for any constant ρ ≥ 1, there is no polynomial-time approximation algorithm with approximation ratio ρ for the general traveling-salesman problem...

The set of concrete decision problems that are polynomial-