














Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
Prepare for your exams
Study with the several resources on Docsity
Earn points to download
Earn points by helping other students or get them with a premium plan
The np-completeness of the knapsack problem and its approximability. Definitions, facts, propositions, and algorithms related to the knapsack problem and its optimization and decision versions. It also mentions the relationship between knapsack and other np-complete problems such as subset sum and vertex cover.
Typology: Study notes
1 / 22
This page cannot be seen from the preview
Don't miss anything!















CMPSCI 601: Recall From Last Time Lecture 21
To prove
is NP-complete:
The following problems are NP-Complete:
Knapsack
Given objects:
object weight value = max weight I can carry in my knapsack.
Optimization Problem:
choose
to maximize (^)
such that (^)
Decision Problem:
Given! "!
$# , can I get total value # while total
?
CMPSCI 601: Approximability Lecture 21
Fact: NP-complete decision problems are all equiva- lent.
Belief: NP-complete problems require exponential time in the worst case.
Fact: Difficulty of NP Approximation problems varies widely.
Definition 21.
is an NP-optimization problem iff For each instance , , is the
. Each has a cost Z. The cost is computable in P.
For minimization problems,
OPT
For maximization problems,
OPT
Four Classes of NP Optimization Problems
NP
APPROX
exists PTIME -approx alg no PTIME -approx alg if P
NP
PTAS exists PTIME -approx alg
FPTAS exists uniform -approx alg running in time poly( )
(F)PTAS stands for (Fully) Polynomial-Time Approxima- tion Scheme.
APPROX
P
FPTAS (^) Knapsack
PTAS ETSP
Clique TSP
VertexCover MAX SAT^ ∆TSP
INAPPROX
Better: Find a Maximal Matching
) do
The edges picked are a maximal matching , a disjoint set of edges to which we can’t add another disjoint edge. If there are edges in this matching, we’ve used nodes in but any algorithm would have to use at least .
opt Best known approx ratio
that starts and ends at some vertex and visits every other vertex exactly once.
HC