📝 GATE Previous Year Questions: Propositional Logic

📝 About This Section

These are questions from GATE CS and GATE DA exams on propositional logic topics. Each question includes a detailed step-by-step solution.

Question 1

GATE CS 2019 — 2 Marks

Problem

Which one of the following is a tautology?

  1. P ∨ Q → P ∧ Q
  2. P ∧ Q → P ∨ Q
  3. P ∨ Q → P
  4. P → P ∧ Q

Solution

Test each option by trying to falsify it (set → to false: antecedent T, consequent F).

(A) P ∨ Q → P ∧ Q: Set P=T, Q=F. LHS: T∨F = T. RHS: T∧F = F. So T→F = F. Not a tautology. ❌

(B) P ∧ Q → P ∨ Q: Try to falsify: need P∧Q = T and P∨Q = F. But if P∧Q = T then both P,Q are T, so P∨Q = T. Contradiction! Cannot be falsified → Tautology. ✅

(C) P ∨ Q → P: Set P=F, Q=T. LHS: F∨T = T. RHS: F. So T→F = F. Not a tautology. ❌

(D) P → P ∧ Q: Set P=T, Q=F. LHS: T. RHS: T∧F = F. So T→F = F. Not a tautology. ❌

Answer: (B)

Key insight: If a conjunction is true, the disjunction of the same variables must be true.

Question 2

GATE CS 2020 — 2 Marks

Problem

Let p and q be two propositions. The number of truth assignments for which (p → q) ↔ (¬q → ¬p) evaluates to True is ______ .

Solution

We know that (p → q) ≡ (¬q → ¬p) — this is the contrapositive equivalence.

Since they are logically equivalent, (p → q) ↔ (¬q → ¬p) is a tautology.

With 2 variables, there are 2² = 4 possible truth assignments.

Since the formula is a tautology, it is true in ALL assignments.

Answer: 4

Question 3

GATE CS 2017 — 2 Marks

Problem

The number of models (satisfying truth assignments) of the formula:

(P ∨ Q ∨ ¬R) ∧ (P ∨ ¬Q) ∧ (¬P)

is ______ .

Solution

Step 1: From clause (¬P): P = False.

Step 2: Substitute P=F into (P ∨ ¬Q): F ∨ ¬Q = ¬Q. So Q = False.

Step 3: Substitute P=F, Q=F into (P ∨ Q ∨ ¬R): F ∨ F ∨ ¬R = ¬R. So R = False.

The only satisfying assignment is P=F, Q=F, R=F. Let us verify:

  • (F ∨ F ∨ T) = T ✅
  • (F ∨ T) = T ✅
  • (T) = T ✅

Answer: 1

Question 4

GATE CS 2015 — 1 Mark

Problem

Which one of the following is NOT logically equivalent to ¬∃x(¬P(x) ∧ Q(x))?

Note: While this involves quantifiers, the propositional logic manipulation is key. We treat it at the propositional level inside the quantifier.

  1. ∀x(P(x) ∨ ¬Q(x))
  2. ∀x(¬Q(x) → ¬P(x))
  3. ∀x(P(x) ← Q(x))
  4. ∀x(¬P(x) → ¬Q(x))

Solution

Starting: ¬∃x(¬P(x) ∧ Q(x)) = ∀x ¬(¬P(x) ∧ Q(x)) = ∀x (P(x) ∨ ¬Q(x))

This is ∀x(Q(x) → P(x)) using material implication.

(A) ∀x(P(x) ∨ ¬Q(x)): Direct De Morgan's result. Equivalent. ✅

(B) ∀x(¬Q(x) → ¬P(x)): ¬Q → ¬P is the inverse of Q → P, NOT equivalent. This is the contrapositive of P → Q, not Q → P. ❌

(C) ∀x(P(x) ← Q(x)): P ← Q means Q → P. Equivalent. ✅

(D) ∀x(¬P(x) → ¬Q(x)): ¬P → ¬Q is the contrapositive of Q → P. Equivalent. ✅

Answer: (B)

Question 5

GATE CS 2018 — 2 Marks

Problem

Consider the following propositional statements:

P₁: ((A ∧ B) → C)) ≡ ((A → C) ∧ (B → C))

P₂: ((A ∨ B) → C)) ≡ ((A → C) ∧ (B → C))

Which of the above statements is/are tautologies?

  1. P₁ only
  2. P₂ only
  3. Both P₁ and P₂
  4. Neither P₁ nor P₂

Solution

Check P₁: (A ∧ B) → C ≡ (A → C) ∧ (B → C)?

LHS = ¬(A ∧ B) ∨ C = ¬A ∨ ¬B ∨ C

RHS = (¬A ∨ C) ∧ (¬B ∨ C)

Try A=T, B=T, C=F: LHS = F∨F∨F = F. RHS = (F∨F)∧(F∨F) = F∧F = F. Same ✅

Try A=T, B=F, C=F: LHS = F∨T∨F = T. RHS = (F∨F)∧(T∨F) = F∧T = F. Different! ❌

P₁ is NOT a tautology.

Check P₂: (A ∨ B) → C ≡ (A → C) ∧ (B → C)?

LHS = ¬(A ∨ B) ∨ C = (¬A ∧ ¬B) ∨ C

RHS = (¬A ∨ C) ∧ (¬B ∨ C)

Distribute RHS: (¬A ∨ C) ∧ (¬B ∨ C) = (¬A ∧ ¬B) ∨ C [by factoring C out]

LHS = RHS! P₂ IS a tautology. ✅

Answer: (B) P₂ only

Question 6

GATE CS 2016 — 1 Mark

Problem

Consider the following two statements:

S₁: If it rains then the road is wet. The road is wet. Therefore it rained.

S₂: If it rains then the road is wet. It did not rain. Therefore the road is not wet.

Which of the above arguments is/are logically valid?

  1. S₁ only
  2. S₂ only
  3. Both S₁ and S₂
  4. Neither S₁ nor S₂

Solution

Let R = "it rains", W = "road is wet".

S₁: R → W, W, ∴ R — This is Affirming the Consequent, a well-known logical fallacy. Invalid! The road could be wet for other reasons (sprinkler, spill, etc.).

S₂: R → W, ¬R, ∴ ¬W — This is Denying the Antecedent, another logical fallacy. Invalid! The road could be wet even if it didn't rain.

Answer: (D) Neither S₁ nor S₂

Remember: Only Modus Ponens (R→W, R ∴ W) and Modus Tollens (R→W, ¬W ∴ ¬R) are valid.

Question 7

GATE DA 2024 — 2 Marks

Problem

How many clauses are there in the CNF equivalent of the formula:

(P ∧ Q) ∨ (R ∧ S)

Solution

Convert to CNF by distributing ∨ over ∧:

(P ∧ Q) ∨ (R ∧ S)

= ((P ∧ Q) ∨ R) ∧ ((P ∧ Q) ∨ S)   [distribute ∨ over ∧ on R∧S]

= (P ∨ R) ∧ (Q ∨ R) ∧ (P ∨ S) ∧ (Q ∨ S)   [distribute ∨ over ∧ again]

We have 4 clauses: {P∨R}, {Q∨R}, {P∨S}, {Q∨S}

Answer: 4

General rule: distributing an m-term DNF over an n-term DNF can give up to m×n clauses. Here 2×2 = 4.