Prove VERTEX COVER NP-complete from INDEPENDENT SET
Analyze the prove vertex cover np-complete from independent set.
Examples
Input: "test_input_1"
Output: "output_1"
Input: "test_input_2"
Output: "output_2"
Hints
Recall that a vertex cover is a set of vertices such that every edge of the graph is incident to at least one vertex in the set, while an independent set is a set of vertices with no edges between them.
Construct a reduction from the Independent Set problem (known to be NP-complete) to the Vertex Cover problem by considering the complement of the independent set in the graph.
Prove the reduction is correct by showing that a graph has an independent set of size ≥ k if and only if it has a vertex cover of size ≤ n - k, where n is the total number of vertices in the graph.
Prove VERTEX COVER NP-complete from INDEPENDENT SET
Analyze the prove vertex cover np-complete from independent set.