How to prove this problem is NP-Complete

133 Views Asked by At

Give a graph G(V, E) and two integers X, Y:
Problem: Is there a subset of vertices V' in V in the size of X
Where in this subset there are at least Y edges?
The problem is to show it is NP-Complete.

Thank you.

1

There are 1 best solutions below

5
On

Clique is a subproblem of your one and is known to be NP-complete. Thus, your problem is NP-hard. To show that it is NP-complete, simply show that it lies in NP.

Regarding the comments, here a little edit: If $V'$ is a set with $X$ vertices, then $V'$ is a complete subgraph (i.e. a clique), if and only if $V'$ contains ... edges. I think you are able to figure out the missing number yourself: How many edges does a complete graph have, if you know the number of vertices?