Question

Consider the decision problem 2CNFSAT defined as follows:

{Φ∣Φ is a satisfiable propositional formula in CNF with at most two literals per clause}\{\Phi \mid \Phi \text{ is a satisfiable propositional formula in CNF with at most two literals per clause}\}

For example, Φ=(x1∨x2)∧(x1∨x3‾)∧(x2∨x4)\Phi = (x_1 \lor x_2) \land (x_1 \lor \overline{x_3}) \land (x_2 \lor x_4) is a Boolean formula and it is in 2CNFSAT.

The decision problem 2CNFSAT is

Choose one option
Official answer and solution
Official answer
B
From
Official GATE 2014 answer key

Solution

Recall the complexity and algorithmic reduction of the 2-Satisfiability (2-SAT) problem.

  1. 2-CNF Satisfiability (2-SAT):
    In a 2-CNF formula, each clause has at most two literals (e.g., u∨vu \lor v).
    Every such clause is logically equivalent to two implications:

    (u∨v)≡(¬u→v)≡(¬v→u).(u \lor v) \equiv (\neg u \to v) \equiv (\neg v \to u).
  2. Reduction to Implication Graph:

    • Construct a directed graph G=(V,E)G = (V, E) where vertices represent all literals (xix_i and ¬xi\neg x_i), and directed edges represent the implication rules.
    • A formula is satisfiable if and only if no variable xix_i and its negation ¬xi\neg x_i lie in the same Strongly Connected Component (SCC) of GG.
  3. Complexity:

    • Finding SCCs in a directed graph takes linear time O(V+E)O(V + E) using Tarjan's or Kosaraju's algorithm.
    • Reachability between literals can be checked in polynomial (linear) time.
    • Thus, 2CNFSAT is solvable in polynomial time by reduction to directed graph reachability (option B).
  4. Other options are incorrect: 3-SAT is NP-complete, but 2-SAT is in P (not NP-complete).

Final answer

B

Common trap

Confusing 2-SAT (in P) with 3-SAT (NP-complete).

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 3
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.