Lecture 22: Introduction to NP Problems
P, NP, and NP-Complete:
P = {Problems that can be solved in polynomial time}
Definition: An algorithm c(-, -) is a certifier for a problem. c(-, -) means a polynomial algorithm such that c = {s | there exists t(c(s,t)) reports true and |t| <=p p(|s|)}. Algorithm a(-) solves A means A = {s | a(s) reports true}.
NP = {c | c(-, -) is a certifier for c and c(-, -) is in P}
NP: Nondeterministic Polynomial time. The “nondeterminism” allows a program to “guess.” If there is a way to guess right, it always does it.
Independent set is in NP because for a problem instance (G, k) we can use a k-size subset of G as a certificate and check that there is a solution in polynomial time. Vertex cover is also in NP because our certificate is a set of k vertices that we can check in polynomial time. There are problems in NP called NP-Complete. A problem is B is NP-Complete means B is a subset of NP and if x is a program in BP, then x <=p B for all x in NP. So, every NP-Complete problem <=p to every other NP-Complete problem. If you solve one, you have effectively solved them all.
Circuit satisfiability (SAT) <=p 3-SAT <=p Independent Set <=p Vertex Cover <=p Set Cover
Given any NP-Complete problem and Q in NP, find a Q <=p C or C <=p Q, then Q is also NP-Complete.
Set Cover:
Given a collection of elements s1, …, sm and a set U, there are k s1, …, sm subsets whose union is U. We want to show Vertex Cover <=p Set Cover. First, Vertex Cover wants to cover all the edges. A vertex covers all of its own edges. Here is an example:

Claim: VC <=p SC. Let U = E, si = {e | e is an edge of vi} This is an instance of SC.
Claim: W <= V is a vertex cover -> {si | vi in W} is a set cover.
Proof: Suppose W is a vertex cover. Then each edge is covered by si that vi covers. Therefore, {si | vi in W} covers U.
Claim: SC is in NP
Proof: Let t be a set of indices for subsets s1, …, sm Then, we can check in polynomial time that each u in U appears at least once in one of A.
This entry was posted on Monday, March 14th, 2005 at 11:17 am and is tagged with polynomial algorithm, nondeterministic polynomial time, np problems, algorithm c, w lt, independent set, problem instance, time definition, certifier, problem c, vertex, vertices, subsets, subset, bp, sm, proof, elements. You can follow any responses to this entry through the RSS 2.0 feed. You can leave a response, or trackback.
Leave a Reply
Please take time to enjoy the archives: May 2005 (1) April 2005 (11) March 2005 (11) February 2005 (15) January 2005 (7)
Fresh, related resources:
- Coding Horror: Your Favorite bNP/b-Complete Cheat
The bproblem/b is to syntactically parse a sentence in natural language using a computer. In that blecture/b, if a syntax theory is "bNP/b-complete", that meant "good, quickly solvable in polynomial time." "Not bNP/b-complete" meant "bad, b.../b - Steven Edwards: Bush delivers farewell blecture/b to UN #39;wax museum b.../b
October 27, 2008, 1:b22/b PM, Steven Edwards: McCain's Palin bproblems/b make Romney look better all the time by Kelly McParland. TAGS: Full Comment, U.S. Politics, Steven Edwards · 8 Comments · Welcome to Full Comment b.../b - National Post Editorial Board: The case for selling asbestos b.../b
Oct b22/b 2008 10:32 AM. "It is a shame, however, that such reasonable remarks should be embedded within a sometimes-tendentious blecture/b whose premise appears to be that we have a moral responsibility to withhold a toxic -- but also b.../b - Telling The Bondmaid?s Tale - FP Comment
The column is a spin-off of a new book: Payback: Debt and the Shadow Side of Wealth, which is also the subject of this year?s Massey bLectures/b, being taped this week across the country for broadcast on CBC Radio next month. b.../b - ecomail rss: Ecomail--gt; Joshua Tree bNP/b Grad Student Research Grants
Ecomail--> Joshua Tree bNP/b Grad Student Research Grants. Begin forwarded message:. From: Tasha La Doux . Date: October 24, 2008 1:32:16 AM EDT. Subject: JOTR Graduate Student Research Grant, due Nov 21, 2008 b.../b
