lect21-MoreNPCompleteProblemspnp3

lect21-MoreNPCompleteProblemspnp3 - MoreNPCompleteProblems...

Info iconThis preview shows pages 1–12. Sign up to view the full content.

View Full Document Right Arrow Icon
1 More NP-Complete Problems NP-Hard Problems Tautology Problem Node Cover Knapsack
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
2 Next Steps We can now reduce 3SAT to a large  number of problems, either directly or  indirectly. Each reduction must be polytime. Usually we focus on length of the output  from the transducer, because the  construction is easy. But  key issue : must be polytime.
Background image of page 2
3 Next Steps – (2) Another essential part of an NP- completeness proof is showing the  problem is in  NP . Sometimes, we can only show a problem  NP-hard   = “if the problem is in  P , then  P   NP ,” but the problem may not be in  NP .
Background image of page 3

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
4 Example : NP-Hard Problem The  Tautology Problem   is: given a  Boolean formula, is it satisfied by  all   truth assignments? Example : x + -x + yz Not obviously in  NP , but it’s  complement is. Guess a truth assignment; accept if that  assignment doesn’t satisfy the formula.
Background image of page 4
5 Key Point  Regarding Tautology An NTM can guess a truth assignment  and decide whether formula F is  satisfied by that assignment in polytime. But if the NTM accepts when it guesses  a satisfying assignment, it will accept F  whenever F is in SAT, not Tautology.
Background image of page 5

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
6 Co- NP A problem/language whose complement is  in  NP  is said to be in  Co- NP . Note P  is closed under complementation. Thus,  P    Co- NP . Also, if  P  =  NP , then  P  =  NP  = Co- NP .
Background image of page 6
7 Tautology is NP-Hard While we can’t prove Tautology is in  NP , we can prove it is NP-hard. Suppose we had a polytime algorithm  for Tautology. Take any Boolean formula F and  convert it to -(F). Obviously linear time.
Background image of page 7

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
8 Tautology is NP-Hard – (2) F is satisfiable if and only -(F) is  not  a  tautology. Use the hypothetical polytime algorithm  for Tautology to test if -(F) is a  tautology. Say “yes, F is in SAT” if -(F) is not a  tautology and say “no” otherwise. Then SAT would be in  P , and  P  =  NP .
Background image of page 8
9 Historical Comments There were actually two notions of “NP- complete” that differ subtlely. And only if  P     NP . Steve Cook, in his 1970 paper, was  really concerned with the question “why  is Tautology hard?” Remember : theorems are really logical  tautologies.
Background image of page 9

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
10 History – (2) Cook used “if problem X is in  P , then  P   NP ” as the definition of “X is NP- hard.” Today called  Cook completeness . In 1972, Richard Karp wrote a paper  showing many of the key problems in  Operations Research to be NP- complete.
Background image of page 10
11 History – (3) Karp’s paper moved “NP-completeness”  from a concept about theorem proving  to an essential for any study of  algorithms.
Background image of page 11

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Image of page 12
This is the end of the preview. Sign up to access the rest of the document.

This note was uploaded on 03/30/2012 for the course CS 154 taught by Professor Motwani,r during the Spring '08 term at Stanford.

Page1 / 49

lect21-MoreNPCompleteProblemspnp3 - MoreNPCompleteProblems...

This preview shows document pages 1 - 12. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online