PROPOSITIONAL LOGIC
Trong-Nghia Nguyen
Faculty of DS & AI
Autumn semester, 2026
AI,
Autumn, 2026
Trong-Nghia Nguyen
2
AI
Content
• Representing problems using logic
• Propositional logic
Trong-Nghia Nguyen
3
AI
Representing problems using logic
Trong-Nghia Nguyen
4
AI
Representing problems using logic
Trong-Nghia Nguyen
5
AI
Representing problems using logic
Trong-Nghia Nguyen
6
AI
Representing problems using logic
Trong-Nghia Nguyen
7
AI
Representing problems using logic
Trong-Nghia Nguyen
8
AI
Content
• Representing problems using logic
• Propositional logic
Trong-Nghia Nguyen
9
AI
Propositional logic
Trong-Nghia Nguyen
10
AI
Propositional logic
(ModusTollens rule)
Trong-Nghia Nguyen
11
AI
Propositional logic
Trong-Nghia Nguyen
12
AI
Propositional logic
● Atomic sentence: a single clause symbol (or
True/False constant). For example: P, Q, Rain.
● Complex sentence: combined from smaller
sentences using connective. For example: ¬P, P ∧
Q, (P ∨ Q) ⇒ R.
● Literal: an atomic sentence or its negation. For
example: P (positive literal), ¬P (negative literal).
● Clause (clause): collection (∨) of literals. For
example: (P ∨ ¬Q ∨ R)
Sentence → AtomicSentence | ComplexSentence
AtomicSentence → True | False | P | Q | R | …
ComplexSentence → ¬ Sentence
| ( Sentence ∧ Sentence )
| ( Sentence ∨ Sentence )
| ( Sentence ⇒ Sentence )
| ( Sentence ⇔ Sentence )
Trong-Nghia Nguyen
13
AI
Propositional logic
Trong-Nghia Nguyen
14
AI
Propositional logic
¬ (Negation) → ∧ (Conjunction) → ∨
(Disjunction) → ⇒ (Implication) → ⇔
(Equivalence)
Trong-Nghia Nguyen
15
AI
Propositional logic
Trong-Nghia Nguyen
16
AI
Propositional logic
Model (world / assignment) — interpretation
● A model m is a way of assigning the value True/False to every propositional symbol.
Each model is "a possible world".
● If there are n symbols, there are 2ⁿ models (2ⁿ lines of the truth table).
● For example: with 2 symbols P, Q → there are 4 models:
m₁ = {P=F, Q=F}, m₂ = {P=F, Q=T}, m₃ = {P=T, Q=F}, m
₄
= {P=T, Q=T}.
What does "the sentence α is true in model m" mean?
● Assign values to symbols according to m, then calculate from inside to outside according
to the truth table of each connective (¬, ∧, ∨, ⇒, ⇔) — obtain True or False.
● Notation: m ⊨ α reads "m satisfies α" (α is true in m).
● M(α) = set of all models that make α true.
Trong-Nghia Nguyen
17
AI
Propositional logic
For example, calculating the value for each model.
Consider the formula α = (P ∨ Q) ∧ ¬Q. Evaluate α across all four models:
→ α is true only in m₃, i.e., M(α) = { m₃ } = {P=T, Q=F}.
Model (world / assignment) — interpretation
Trong-Nghia Nguyen
18
AI
Propositional logic
Entailment (⊨) — "logically implies"
● KB ⊨ α: "KB entails α," meaning: α is true in every model where KB is true.
● If one accepts KB, one is compelled to accept α.
● In terms of model sets: KB ⊨ α ⟺ M(KB) ⊆ M(α) (every world that satisfies KB also
satisfies α).
How to check for entailment
● Consider all models; only look at models as KB = True ;
● If in all of them, α also = True → KB ⊨ α.
● If there is even a model KB=True but α=False → KB ⊭ α.
Trong-Nghia Nguyen
19
AI
Propositional logic
Entailment (⊨) — "logically implies"
Example: Given KB = (P
⇒
Q)
∧
P, does KB
⊨
Q?
● The KB true only at m₄. At m₄, Q = True ⇒ KB ⊨ Q ✓ (this is essentially Modus Ponens
viewed from a semantic perspective).
● Conversely, KB ⊭ ¬Q: because at m₄ (the only model satisfying the KB), ¬Q = False.
Trong-Nghia Nguyen
20
AI
Propositional logic
Soundness & Completeness
● ⊨ (semantics): KB
⊨
α — "α is true in all models making KB true". This is the truth.
● ⊢ (syntax): KB
⊢
ᵢ α — "α is derived from KB by inference procedure i" (applying rules such as Modus
Ponens, resolution…). This is the calculator that calculates it.
Does procedure
⊢
match truth
⊨
?
Soundness
● If KB ⊢ α, then KB ⊨ α.
● Meaning: The procedure derives only what is actually true—it never yields an incorrect conclusion.
(⊢ ⊆ ⊨)
Completeness
● If KB ⊨ α, then KB ⊢ α.
● Meaning: the procedure derives everything that is entailed—no truth is missed. (⊨ ⊆ ⊢)
“A procedure that is both sound and complete is
⊢
identical
⊨
: it calculates correctly and has all logical consequences.
That's what we want.”
Trong-Nghia Nguyen
21
AI
Propositional logic
Soundness & Completeness
Example: SOUND Rule — Modus Ponens
From P ⇒ Q and P, it follows that Q. ("It is raining" ⇒ "the road is wet".)
Check if KB = (P ⇒ Q) ∧ P ⊨ Q?
→ The KB is true in only one row (P=T,
Q=T), and in that row, Q = T. Thus,
every model that satisfies the KB also
satisfies Q → KB ⊨ Q. The rule is sound
✓.
Trong-Nghia Nguyen
22
AI
Propositional logic
Soundness & Completeness
Example: UNSOUND Rule — Affirming the Consequent
From P ⇒ Q and Q, one might infer P. ("Wet road" ⇒ "raining"?) — it sounds
plausible but is incorrect: the road could be wet due to a street-watering truck, not
rain.
Check if KB = (P ⇒ Q) ∧ Q ⊨ P?
→ There is a model {P=F, Q=T} where
the KB is true but P is False. Thus, KB ⊭
P → the rule is NOT sound ✗. That
model corresponds to the scenario of
"wet ground (Q) but no rain (¬P)."
Trong-Nghia Nguyen
23
AI
Propositional logic
Trong-Nghia Nguyen
24
AI
Propositional logic
Trong-Nghia Nguyen
25
AI
Propositional logic
Trong-Nghia Nguyen
26
AI
Propositional logic
Trong-Nghia Nguyen
27
AI
Propositional logic
Trong-Nghia Nguyen
28
AI
Thank you!