Question

Suppose a polynomial time algorithm is discovered that correctly computes the largest clique in a given graph. In this scenario, which one of the following represents the correct Venn diagram of the complexity classes P, NP and NP Complete (NPC)?

Venn diagrams showing four candidate relationships between complexity classes P, NP, and NPC
Choose one option
Official answer and solution
Official answer
D
From
Official GATE 2014 answer key

Solution

Recall the definition and consequences of NP-completeness and polynomial-time solvability of CLIQUE.

  1. The CLIQUE problem (determining whether a graph has a clique of size kk) is one of Karp's 21 NP-complete problems.

  2. Computing the largest clique allows one to solve the CLIQUE decision problem in polynomial time by simply checking whether the size of the largest clique is ≥k\ge k.

  3. By definition of NP-completeness, every problem in NP polynomial-time reduces to CLIQUE. Therefore, if CLIQUE is solvable in polynomial time, then every problem in NP is solvable in polynomial time:

P=NPP = NP
  1. Furthermore, when P=NPP = NP, every non-trivial language in NP (any language other than ∅\emptyset and Σ∗\Sigma^*) is NP-complete under polynomial-time many-one reductions.

  2. Thus, the complexity classes collapse entirely to P=NP=NPCP = NP = NPC.

This is depicted in diagram (D), where P=NP=NPCP = NP = NPC.

Final answer

D

Common trap

Assuming NPC remains a proper subset of P = NP, whereas under polynomial reductions every non-trivial problem in P is NP-complete if P = NP.

The answer is the one in the official GATE answer key. The solution is this site's own explanation.

Source

Paper
GATE 2014 Computer Science and Information Technology (CS) Session 1
Question
48 of 65, printed as CS Q.38
Section
Computer Science and Information Technology

Report an error in this question

GATE questions are the work of the organising institutes. This site is independent and is not affiliated with them.