Sub topic 17
Further Directions: Approximation-Preserving and Fine-Grained Reductions
This chapter assumes you know Karp reductions, NP-completeness, and the Independent Set and Vertex Cover reductions from earlier chapters. It is a short map of two areas where reductions have to carry more information than a yes or no answer.
When yes/no is not enough
A Karp reduction only promises that yes-instances map to yes-instances. It says nothing about how close a near-solution of B is to a near-solution of A. It also says nothing about the exact exponent in the running time. Each of these questions needs its own kind of reduction.
Approximation-preserving reductions
An approximation-preserving reduction maps an instance x of A to an instance f(x) of B. It must also come with a way to turn any good-enough solution of f(x) back into a good-enough solution of x. Common variants include:
| Reduction | What it preserves |
|---|---|
| L-reduction | Optimum values and absolute errors, each within constant factors |
| PTAS reduction | The existence of (1 + ε)-approximation schemes |
| Gap-preserving reduction | A gap between "optimum ≥ c" and "optimum < s", used for inapproximability |
The complement reduction from Independent Set to Vertex Cover keeps the yes and no answers, but it does not keep approximation quality. Vertex Cover has a simple 2-approximation. Independent Set cannot be approximated within n^(1−ε) for any ε > 0 unless P = NP. The code below shows the problem.
def matching_vertex_cover(edges):
# Classic 2-approximation: take both ends of a maximal matching
cover = set()
for u, v in edges:
if u not in cover and v not in cover:
cover |= {u, v}
return cover
n = 5
vertices = list(range(2 * n))
edges = [(2 * i, 2 * i + 1) for i in range(n)] # n disjoint edges
cover = matching_vertex_cover(edges)
independent = set(vertices) - cover
print("cover size:", len(cover), "optimum:", n) # 10 vs 5
print("independent set size:", len(independent), "optimum:", n) # 0 vs 5The cover is within a factor of 2, which is acceptable. Its complement is empty, so it gives no approximation of the largest independent set at all.
Fine-grained reductions
NP-hardness separates polynomial time from exponential time. Fine-grained complexity asks a sharper question: can this O(n²) algorithm be improved to O(n^(2−ε))? A fine-grained reduction from A to B shows that a faster algorithm for B gives a faster algorithm for A, with the exponents tracked exactly.
The field rests on a few conjectures:
- SETH (Strong Exponential Time Hypothesis): for every ε > 0, there is some k such that k-SAT cannot be solved in O(2^((1−ε)n)) time.
- 3SUM: deciding whether three of n numbers sum to zero needs n^(2−o(1)) time.
- APSP: all-pairs shortest paths needs n^(3−o(1)) time.
For example, Backurs and Indyk (2015) showed that an O(n^(2−ε)) algorithm for edit distance would refute SETH. This is strong evidence that the standard dynamic program is close to optimal.
Exercise
The complement map sends a vertex cover C to the independent set V − C. Why does this preserve exact optima but not approximation ratios?
Show answer
Exact optima correspond because the minimum cover size equals |V| minus the maximum independent set size. Approximation errors behave differently. A cover with only k extra vertices has a complement with k fewer vertices, and when the optimum independent set is small, losing those k vertices can wipe it out completely. The perfect matching example shows a factor-2 cover whose complement has size 0.
Exercise
Suppose a reduction maps an Orthogonal Vectors instance of size n to an edit distance instance of size n log n in O(n log n) time. What would an O(m^1.9) edit distance algorithm, where m is the input size, imply?
Show answer
It would solve Orthogonal Vectors in O((n log n)^1.9) = O(n^1.95) time. That beats the O(n^(2−ε)) bound implied by SETH, so SETH would be false.