sp-ex12
sp-ex12
a
d
f
c
(b) Is it possible for our vertex cover algorithm (taught in the class) to output a vertex cover of
size 4?
Problem 2. Define “variable” and “literal” in the same way as we did for the MAX-3SAT problem.
However, re-define a clause as the OR of an arbitrary number of literals subject to the constraint that
all literals need to be defined on distinct variables. Prove: by independently setting each variable to
0 or 1 with 50% probability, we ensure that the clause should evaluate to 1 with probability at least
1/2.
5 4
b 2 e
2 3
4 2 4 3
c 3 d
Use the algorithm taught in the class to find a Hamiltonian cycle that achieves an approximation
ratio of 2.
Problem 4. In Step 2 of our 2-approximate algorithm for our traveling salesman problem, we need
to compute a walk from the MST T computed in Step 1. Explain how to compute the walk in time
proportional to the number of vertices in T .
• P = {s1 , s2 , ..., sn };
1
• each (si , ti ) is a segment connecting points si and ti .
The length of the cycle is the total length of all the n segments. Let OPTP be the shortest length
of all cycles. Design a poly(n)-time algorithm (i.e., polynomial in n) that finds a cycle with length
at most 2 · OPTP .
Note: for this problem, you can assume that the distance between any two points can be
calculated in polynomial time.