Syntax and Semantics of Propositional Logic

GATE DA β€” High Importance

Prerequisites

  • Basic understanding of mathematical logic
  • Familiarity with Boolean algebra concepts

🎯 Learning Objectives

  • Understand the syntax of propositional logic: atomic propositions and connectives
  • Define well-formed formulas (WFFs) formally
  • Apply operator precedence to parse complex formulas
  • Evaluate formulas under given truth assignments

1. What is Propositional Logic?

Propositional logic (also called sentential logic or zeroth-order logic) is the simplest form of formal logic. It deals with propositionsβ€”statements that are either true or falseβ€”and how they can be combined using logical connectives.

Definition: Proposition

A proposition is a declarative sentence that is either true (⊀) or false (βŠ₯), but not both. It has a definite truth value.

Examples of Propositions

  • "The Earth revolves around the Sun." β€” True
  • "7 + 5 = 13" β€” False
  • "GATE DA 2026 exam has an AI section." β€” True

Non-Propositions (Not Declarative)

  • "What time is it?" β€” Question, no truth value
  • "Close the door." β€” Command, no truth value
  • "x + 2 = 5" β€” Open sentence (depends on x)

2. Syntax of Propositional Logic

The syntax defines the alphabet (symbols) and grammar (rules for forming valid expressions) of the language.

2.1 Alphabet

The alphabet of propositional logic consists of:

Symbol TypeSymbolsDescription
Propositional variablesP, Q, R, S, ... (or p, q, r, s, ...)Atomic propositions
Truth constants⊀ (True), βŠ₯ (False)Logical constants
Negation¬NOT (unary connective)
Conjunction∧AND (binary connective)
Disjunction∨OR (binary connective)
Implication→IF...THEN (binary connective)
Biconditional↔IF AND ONLY IF (binary connective)
Parentheses( , )Grouping

2.2 The Five Logical Connectives

Negation (Β¬)

Β¬P is true when P is false, and false when P is true. It flips the truth value.

¬P is true ⟺ P is false

Conjunction (∧)

P ∧ Q is true only when both P and Q are true.

P ∧ Q is true ⟺ P is true AND Q is true

Disjunction (∨)

P ∨ Q is true when at least one of P or Q is true. This is inclusive OR.

P ∨ Q is false ⟺ P is false AND Q is false

Implication (β†’)

P β†’ Q is false only when P is true and Q is false. P is the antecedent (hypothesis), Q is the consequent (conclusion).

P β†’ Q is false ⟺ P is true AND Q is false

⚠️ Common GATE Mistake: Implication

Many students get confused: P β†’ Q is true when P is false, regardless of Q. A false hypothesis makes the entire implication vacuously true. For example: "If 2 + 2 = 5, then the moon is made of cheese" is True!

Biconditional (↔)

P ↔ Q is true when P and Q have the same truth value.

P ↔ Q is true ⟺ (P β†’ Q) ∧ (Q β†’ P)

3. Well-Formed Formulas (WFFs)

Definition: Well-Formed Formula (WFF)

A well-formed formula is defined recursively:

  1. Base case: Every propositional variable (P, Q, R, ...) is a WFF. The constants ⊀ and βŠ₯ are WFFs.
  2. Negation: If α is a WFF, then ¬α is a WFF.
  3. Binary connective: If Ξ± and Ξ² are WFFs, then (Ξ± ∧ Ξ²), (Ξ± ∨ Ξ²), (Ξ± β†’ Ξ²), and (Ξ± ↔ Ξ²) are WFFs.
  4. Nothing else is a WFF.

WFF or Not?

ExpressionWFF?Reason
P ∧ Qβœ… YesBinary connective applied to two propositional variables
Β¬(P β†’ Q)βœ… YesNegation applied to an implication WFF
∧ P Q❌ NoConnective must be between two WFFs (infix notation)
P ∧ ∨ Q❌ NoTwo consecutive binary connectives without operand
((P ∨ Q) ∧ Β¬R) β†’ Sβœ… YesValid recursive construction

4. Operator Precedence

To reduce the number of parentheses, we adopt a standard precedence (from highest to lowest):

Operator Precedence (Highest to Lowest)

PriorityOperatorNameAssociativity
1 (Highest)Β¬NegationRight
2∧ConjunctionLeft
3∨DisjunctionLeft
4β†’ImplicationRight
5 (Lowest)↔BiconditionalLeft

πŸ“ Key Point for GATE

Implication (β†’) is right-associative: P β†’ Q β†’ R means P β†’ (Q β†’ R), not (P β†’ Q) β†’ R.

Example 1: Parsing P ∧ Q ∨ R β†’ S

Step 1: ∧ binds tighter than ∨: (P ∧ Q) ∨ R β†’ S

Step 2: ∨ binds tighter than β†’: ((P ∧ Q) ∨ R) β†’ S

Fully parenthesized: ((P ∧ Q) ∨ R) β†’ S

Example 2: Parsing Β¬P ∧ Q β†’ R ∨ S

Step 1: Β¬ has highest precedence: (Β¬P) ∧ Q β†’ R ∨ S

Step 2: ∧ next: ((Β¬P) ∧ Q) β†’ R ∨ S

Step 3: ∨ next: ((Β¬P) ∧ Q) β†’ (R ∨ S)

Fully parenthesized: ((Β¬P) ∧ Q) β†’ (R ∨ S)

Example 3: Parsing P β†’ Q β†’ R ↔ S ∨ Β¬T

Step 1: Β¬ first: P β†’ Q β†’ R ↔ S ∨ (Β¬T)

Step 2: ∨ binds: P β†’ Q β†’ R ↔ (S ∨ (Β¬T))

Step 3: β†’ is right-associative: P β†’ (Q β†’ R) ↔ (S ∨ (Β¬T))

Step 4: β†’ again: (P β†’ (Q β†’ R)) ↔ (S ∨ (Β¬T))

Fully parenthesized: (P β†’ (Q β†’ R)) ↔ (S ∨ (Β¬T))

5. Semantics: Truth Assignments and Interpretations

Definition: Truth Assignment (Interpretation)

A truth assignment (also called an interpretation or valuation) is a function v that maps every propositional variable to a truth value:

v : {P, Q, R, ...} β†’ {True, False}

The truth value of any compound formula is then determined by the truth values of its components and the semantics of the connectives.

Semantic Evaluation Rules

Given an interpretation v, the truth value of a formula Ξ±, denoted v(Ξ±), is:

  • v(¬α) = True iff v(Ξ±) = False
  • v(Ξ± ∧ Ξ²) = True iff v(Ξ±) = True and v(Ξ²) = True
  • v(Ξ± ∨ Ξ²) = True iff v(Ξ±) = True or v(Ξ²) = True
  • v(Ξ± β†’ Ξ²) = True iff v(Ξ±) = False or v(Ξ²) = True
  • v(Ξ± ↔ Ξ²) = True iff v(Ξ±) = v(Ξ²)

Example: Evaluate (P β†’ Q) ∧ Β¬R under v(P)=T, v(Q)=F, v(R)=T

  1. v(P β†’ Q) = v(P)=T and v(Q)=F, so P β†’ Q = False (T β†’ F = F)
  2. v(Β¬R) = Β¬True = False
  3. v((P β†’ Q) ∧ Β¬R) = False ∧ False = False

πŸ“ Number of Possible Interpretations

For a formula with n distinct propositional variables, there are 2n possible truth assignments. This is why truth tables have 2n rows.

6. Key Terminology Summary

TermMeaning
Atomic formulaA propositional variable (P, Q, R, ...)
LiteralAn atom or its negation (P or Β¬P)
Compound formulaFormula built using connectives
ModelAn interpretation that makes a formula true
⊨ (entails)Semantic consequence: α ⊨ β means every model of α is a model of β
⊒ (derives)Syntactic derivation using inference rules

7. GATE Exam Tips

🎯 Frequently Tested Concepts

  • Operator precedence β€” Questions often test whether you can parse formulas correctly without full parenthesization.
  • Implication truth table β€” The fact that F β†’ T = T and F β†’ F = T trips up many students.
  • WFF identification β€” Distinguish valid formulas from syntactically incorrect expressions.
  • Number of interpretations β€” For n variables, there are exactly 2n interpretations.