8.14

来源:互联网 发布:程序员薪资2017 编辑:程序博客网 时间:2024/06/03 20:45

题目:Prove that the following problem is NP-complete:

given an undirected graph G=[V,E]and an integer k,return a clique of size k as well as an independent set of size k,provided both exist.

解:

将最大团问题规约到该问题,假设要求任意图G(V,E)中大小为k的团,可以在图G中添加k个相互独立的顶点,得到新图G1。新加入的k个顶点确保图G1中存在大小为k的独立集同时又不影响到原图的团。因此该问题为NP完全问题。

原创粉丝点击