\(\IndependentSet\): Given a graph \(G=(V,E)\) and an int \(k\), is there a subset of \(k\) (or more) vertices such that no two are adjacent?
Ex: Is there an independent set of size \(\geq 6\)?
Ex: Is there an independent set of size \(\geq 7\)?
\(\VertexCover\): Given a graph \(G=(V,E)\) and an integer \(k\), is there a subset of vertices of \(k\) (or fewer) vertices such that each edge is incident to at least one vertex in the subset?
Ex: Is there a vertex cover of size \(\leq 4\)?
Ex: Is there a vertex cover of size \(\leq 3\)?
Consider the following graph \(G\). Which are true?
Theorem: \(\VertexCover \equiv_P \IndependentSet\)
Pf: We show \(S\) is an independent set of size \(k\) iff \(V - S\) is a vertex cover of size \(n-k\)
Theorem: \(\VertexCover \equiv_P \IndependentSet\)
Pf: We show \(S\) is an independent set of size \(k\) iff \(V - S\) is a vertex cover of size \(n-k\)
Pf ⇒:
Theorem: \(\VertexCover \equiv_P \IndependentSet\)
Pf: We show \(S\) is an independent set of size \(k\) iff \(V - S\) is a vertex cover of size \(n-k\)
Pf ⇐:
\(\SetCover\): Given a set \(U\) of elements, a collection of \(m\) subsets of \(U\) (\(S_1\), \(S_2\), ..., \(S_m\)), and an int \(k\), are there \(\leq k\) of these subsets whose union is equal to \(U\)?
Sample application
U = { 1, 2, 3, 4, 5, 6, 7 } S1 = { 3, 7 } S4 = { 2, 4 } S2 = { 3, 4, 5, 6 } S5 = { 5 } S3 = { 1 } S6 = { 1, 2, 6, 7 } k = 2
Given following universe \(U\) and sets, which is the minimum size of a set cover of \(U\)?
\[ U = \{1,2,3,4,5,6,7\} \]
\[\begin{array}{lll} S_1 = \{1,4,6\} & S_2 = \{1,6,7\} & S_3 = \{1,2,3,6\} \\ S_4 = \{1,3,5,7\} & S_5 = \{2,6,7\} & S_6 = \{3,4,5\} \end{array}\]
Theorem: \(\VertexCover \leq_P \SetCover\)
Pf: Given a \(\VertexCover\) instance \(G=(V,E)\) and \(k\), we construct a \(\SetCover\) instance \((U,S,k)\) that has a set cover of size \(k\) iff \(G\) has a vertex cover of size \(k\).
Construction:
Theorem: \(\VertexCover \leq_P \SetCover\)
Construction:
![]() |
U = { 1, 2, 3, 4, 5, 6, 7 } Sa = { 3, 7 } Sb = { 2, 4 } Sc = { 3, 4, 5, 6 } Sd = { 5 } Se = { 1 } Sf = { 1, 2, 6, 7 } k = 2 |
Lemma: \(G=(V,E)\) contains a vertex cover of size \(k\) iff \((U,S,k)\) contains a set cover of size \(k\)
Pf ⇒: Let \(X \subseteq V\) be a vertex cover of size \(k\) in \(G\). Then \(Y = \{S_v : v \in X \}\) is a set cover of size \(k\) in \((U,S,k)\).
![]() |
U = { 1, 2, 3, 4, 5, 6, 7 } Sa = { 3, 7 } Sb = { 2, 4 } Sc = { 3, 4, 5, 6 } <== Sd = { 5 } Se = { 1 } Sf = { 1, 2, 6, 7 } <== k = 2 |
Lemma: \(G=(V,E)\) contains a vertex cover of size \(k\) iff \((U,S,k)\) contains a set cover of size \(k\)
Pf ⇐: Let \(Y \subseteq S\) be a set cover of size \(k\) in \((U,S,k)\). Then \(X = \{v : S_v \in Y \}\) is a vertex cover of size \(k\) in \(G\). ∎
![]() |
U = { 1, 2, 3, 4, 5, 6, 7 } Sa = { 3, 7 } Sb = { 2, 4 } Sc = { 3, 4, 5, 6 } <== Sd = { 5 } Se = { 1 } Sf = { 1, 2, 6, 7 } <== k = 2 |