You are on page 1of 42

Introduction

to Modal
Logic

W.Gunther

Propositional
Logic Introduction to Modal Logic
Our Language
Semantics
Syntax
Results

Modal Logic William Gunther


Our language
Semantics
Relations Carnegie Mellon University
Soundness
Results wgunther@cmu.edu

February 16, 2011


Propositional Logic

Introduction
to Modal
Logic

W.Gunther

Propositional
Logic
Our Language
Semantics
Syntax
Results First, let me review some ideas from basic Propositional Logic
Modal Logic (logic without the quantifiers ∀ and ∃)
Our language
Semantics
Relations
Soundness
Results
Alphabet

Introduction
to Modal
Logic

W.Gunther
Our alphabet will be composed of the following symbols:
Propositional
Logic
Our Language
Semantics
1. p0 , p1 , . . . variables
Syntax
Results 2. ¬, →, ∧, ∨ connectives
Modal Logic
Our language
3. (, ) precedence symbols
Semantics
Relations 4. ⊥ false
Soundness
Results

We write P := { p0 , p1 , . . . }.
Formulas

Introduction
to Modal
Logic
We define the set of propositional formulas, F by:
W.Gunther
For every p ∈ P, p ∈ F and ⊥ ∈ F
Propositional
Logic If ϕ ∈ F then ¬ϕ ∈ F .
Our Language
Semantics If ϕ, ψ ∈ F
Syntax
Results (ϕ ∧ ψ) ∈ F
Modal Logic (ϕ ∨ ψ) ∈ F
(ϕ → ψ) ∈ F
Our language
Semantics
Relations
Soundness
Results
Example

((p ∧ (q ∨ r )) → s) ∈ F
/F
(p∧) ∧ ∨q ∈
Truth

Introduction
to Modal
Logic

W.Gunther

Propositional
Logic
Our Language
Semantics
Syntax What does it mean for a formula to be true?
Results

Modal Logic
There are two approaches to showing that a formula is true:
Our language
Semantics
Syntactically and Semantically. We will begin with semantics.
Relations
Soundness
Results
Semantics

Introduction
to Modal
Logic

W.Gunther

Propositional
Note, we desire a way of deciding the truth of a statement.
Logic
Our Language
Semantics
Definition
Syntax
Results A truth assignment is a function v : P → {T , F }.
Modal Logic We then extend v to a function v̄ : F → {T , F } called a
Our language
Semantics valuation in the way you’d expect, ie. by consulting a truth
Relations
Soundness
Results
table.
For example, if v (p) = T and v (q) = T then v̄ (p ∧ q) = T .
and so on for other connectives.
Tautologies

Introduction
to Modal
Logic

W.Gunther

Propositional
Logic Definition
Our Language
Semantics We say a truth assignment v models a formula ϕ (written
Syntax
Results v |= ϕ) if v̄ (ϕ) = T .
Modal Logic
Our language
We say a formula ϕ is satisfiable if there is a truth assignment
Semantics
Relations
v such that v |= ϕ.
Soundness
Results We say a formula ϕ is a tautology if for every truth
assignment v , v |= ϕ.
Examples

Introduction
to Modal
Logic

W.Gunther
Example
Propositional
Logic
Our Language The sentence ϕ = P ∨ ¬P is a tautology; for any truth
Semantics
Syntax assignment this statement is sent to T . (This is called the law
Results
of the excluded middle)
Modal Logic
Our language The statement ψ = P =⇒ Q is not a tautology; consider the
Semantics
Relations truth assignment P 7→ T and Q 7→ F . Then ψ is sent to F by
Soundness
Results the valuation.
ψ is valid however. The truth assignment v where P 7→ F , we
have v |= ψ.
Syntax

Introduction
to Modal Another avenue for deciding whether a formula ϕ is true is
Logic
whether we can prove ϕ from a list of axioms.
W.Gunther
Here is a list of axioms:
Propositional
Logic ϕ → (ψ → ϕ)
Our Language
Semantics (ϕ → (ψ → θ)) → ((ϕ → ψ) → (ϕ → θ))
Syntax
Results
ϕ → (ψ → ϕ ∧ ψ)
Modal Logic
Our language ϕ∧ψ →ϕ
Semantics
Relations
Soundness
ϕ∧ψ →ψ
Results
ϕ→ϕ∨ψ
ψ →ϕ∨ψ
(ϕ → θ) → ((ψ → θ) → (ϕ ∨ ψ → θ))
⊥→ϕ
ϕ ∨ ¬ϕ
Inference

Introduction
to Modal
Logic

W.Gunther

Propositional
Logic
Our Language
Semantics
There is one rule of inference: Modus Ponens. That says if we
Syntax
Results
can prove ϕ → ψ and we can prove ϕ then we can infer ψ.
Modal Logic
Our language
Definition
Semantics
Relations If there is a proof of ϕ then we write ` ϕ.
Soundness
Results
Soundness

Introduction
to Modal
Logic

W.Gunther

Propositional
Logic Theorem
Our Language
Semantics If ϕ is provable, then ϕ is true under all truth assignments.
Syntax
Results In symbols, ` ϕ implies |= ϕ.
Modal Logic
Our language
Semantics
Relations
Proof.
Soundness
Results You need only check that the axioms and the rule of modus
ponens is valid with respect to truth assignments. It is!
Completeness

Introduction
to Modal
Logic

W.Gunther

Propositional
Logic
Our Language
Theorem
Semantics
Syntax If ϕ is true under all truth assignments, then ϕ is provable.
Results
In symbols, |= ϕ implies ` ϕ.
Modal Logic
Our language
Semantics
Relations Proof.
Soundness
Results
Out of our scope!
Modal Logic

Introduction
to Modal
Logic

W.Gunther

Propositional
Logic
Our Language
Semantics
Syntax
We have now seen the propositional calculus. We wish to
Results extend it to make it a bit more expressive.
Modal Logic
Our language
To do this, we add two unary operators to our alphabet:  and
Semantics
Relations
♦, which we read as necessarily and possibly.
Soundness
Results
Formulas

Introduction
to Modal
Logic
The set of modal formulas FM is defined to be:
W.Gunther
If ϕ ∈ F then ϕ ∈ FM , ie. all propositional formulas are
Propositional
Logic modal formulas.
If ϕ ∈ FM then ϕ ∈ FM .
Our Language
Semantics
Syntax
Results
If ϕ ∈ FM then ♦ϕ ∈ FM .
Modal Logic
Our language
Semantics Example
Relations
Soundness
Results A typical modal formula may look like:

 (A → (♦B ∨ A))

odes bind tight.


Truth

Introduction
to Modal
Logic

W.Gunther

Propositional
Logic
Our Language
Semantics
Syntax
Results As before, we now have a set of formulas. We need to make
Modal Logic
Our language
sense of what it means for a formula to be true.
Semantics
Relations
Soundness
Results
Modal Models

Introduction
to Modal
Logic

W.Gunther Definition
Propositional A model M = hW , R, V i is a triple, where:
Logic
Our Language W is a nonempty set. W is called our universe and
Semantics
Syntax elements of W are called worlds
Results

Modal Logic R is a relation on W . R is called our accessibility


Our language
Semantics
relation. The interpretation is if w1 is R-related to w2
Relations
Soundness
then w1 “knows about” w2 and must consider it in making
Results
decisions about whether something is possible or necessary.
V is a function mapping the set of propositional variables
P to P(W ). The interpretation is the if P is mapped into
a set contain w then w thinks that the variable P is true.
Models

Introduction
to Modal
Logic Definition
W.Gunther Fix M = hW , R, V i. We will define now what it means for M
Propositional
to model a modal formula ϕ at some world w .
Logic
Our Language M |=w P if and only if w ∈ V (P).
Semantics
Syntax
Results
M |=w ¬P if and only if M 6|=w P.
Modal Logic We decide if M |=w ϕ where ϕ = ψ ∧ θ, ϕ = ψ ∨ θ, or
Our language
Semantics ψ → θ by looking it up in the truth table.
Relations
Soundness
Results
M |=w ϕ if and only if for every w 0 ∈ W such that
wRw 0 we have M |=w 0 ϕ; ie. every world that w is
“accessible” to via R thinks that ϕ is true.
M |=w ♦ϕ if and only if there is w 0 ∈ W such that wRw 0
we have M |=w 0 ϕ; ie. there’s some world that w is
“accessible” to via R thinks that ϕ is true.
More on Models

Introduction
to Modal
Logic

W.Gunther

Propositional
Logic
Our Language
Semantics Definition
Syntax
Results
For a formula ϕ and a model M we say M |= ϕ if M |=w ϕ
Modal Logic
Our language for every world w .
Semantics
Relations We say |= ϕ if M |= ϕ for every model M .
Soundness
Results
An Example

Introduction
to Modal
Logic

W.Gunther

Propositional 1 M |=w1 P ∧ P
Logic
Our Language 2 M |=w1 Q ∧ ♦Q
Semantics w1 P, Q P, ¬Q w3
Syntax
Results
3 M |=w1 ¬Q
Modal Logic 4 M |=w2 Q ∧ ♦¬Q
Our language
Semantics
Relations
5 M |=w3 P
w2 ¬P, Q ¬P, Q w4
M |=w3 ¬P
Soundness
Results 6

7 M |=w4 (P) ∧ ¬(♦P)


Unexpected behavior!

Introduction
to Modal
Logic

W.Gunther
Notice, some things happen that we didn’t really want. For
Propositional
Logic example, you would expect:
Our Language
Semantics
Syntax
1 P → P
Results
2 P → ♦P
Modal Logic
Our language
Semantics
3 P → ♦P
Relations
Soundness 4 P → P
Results

5 P → ♦P
6 ♦P → ♦P
Relations

Introduction
to Modal
Logic

W.Gunther

Propositional
Logic
Our Language
Semantics
Syntax
Results Too see why, let’s first talk about some special properties of
Modal Logic
Our language
relations.
Semantics
Relations
Soundness
Results
Serial

Introduction
to Modal
Logic

W.Gunther

Propositional Definition
Logic
Our Language
Semantics
Let R be a relation on W . We say R is serial if for every
Syntax
Results
x ∈ W there is some y ∈ W such that xRy .
Modal Logic
Our language
Semantics
Relations
Soundness
Results
x y
Reflexive

Introduction
to Modal
Logic

W.Gunther

Propositional
Definition
Logic
Our Language Let R be a relation on W . We say R is reflexive if for every
Semantics
Syntax x ∈ W we have xRx.
Results

Modal Logic
Our language
Semantics
Relations
Soundness
Results

x
Symmetric

Introduction
to Modal
Logic

W.Gunther

Propositional Definition
Logic
Our Language
Semantics
Let R be a relation on W . We say R is symmetric if for every
Syntax
Results
x, y ∈ W if xRy then yRx.
Modal Logic
Our language
Semantics
Relations
Soundness
Results
x y
Transitive

Introduction
to Modal
Logic

W.Gunther
Definition
Propositional
Logic
Our Language
Let R be a relation on W . We say R is transitive if for every
Semantics
Syntax
x, y , z ∈ W if xRy and yRz then xRz.
Results

Modal Logic
Our language
Semantics
Relations
Soundness
Results

x y z
Euclidean

Introduction
to Modal
Logic
Definition
W.Gunther
Let R be a relation on W . We say R is euclidean if for every
Propositional
Logic x, y , z ∈ W if xRy and xRz then yRz.
Our Language
Semantics
Syntax
Results

Modal Logic
y z
Our language
Semantics
Relations
Soundness
Results

x
Introduction
to Modal
Logic

W.Gunther

Propositional
Logic
Our Language
Semantics
Syntax
Results Properties of the accessibility relation will tell us about axioms
Modal Logic that hold in our models.
Our language
Semantics
Relations
Soundness
Results
Some Axioms

Introduction
to Modal
Logic

W.Gunther
Here are some axioms:
Propositional
Logic N ψ for all propositional tautologies ψ
Our Language
Semantics
Syntax
K (ϕ → ψ) → (ϕ → ψ)
Results

Modal Logic
T ϕ → ϕ
Our language
Semantics D ϕ → ♦ϕ
Relations
Soundness
Results
4 ϕ → ϕ
B ϕ → ♦ϕ
5 ♦ϕ → ♦ϕ
Introduction
to Modal
Logic

W.Gunther
Theorem
Propositional
N and K hold in all models.
Logic
Our Language
Semantics Proof.
Syntax
Results If ψ is an axiom, then ψ holds in every model, so clearly ψ holds in
Modal Logic every model.
Our language
Semantics Assume (ϕ → ψ). Want to show ϕ → ψ. Assume ϕ. Fix a
Relations
Soundness world w . Then for every world related to w , ϕ holds and ϕ → ψ
Results
holds. So ψ holds. So ψ holds in w .

Corollary
The axioms N and K are sound for all models.
Axiom D fails

Introduction
to Modal
Logic

W.Gunther
There is a model M such that P → ♦P fails.
Propositional
Logic
Our Language
Proof.
Semantics
Syntax
Results

Modal Logic P
Our language
Semantics
Relations
w
Soundness
Results

Problem: The relation is not serial!


Serial implies Axiom D

Introduction
to Modal
Logic Theorem
W.Gunther If a the accessibility relation is serial, then
Propositional
Logic
Our Language
M |= ϕ → ♦ϕ
Semantics
Syntax
Results

Modal Logic Proof.


Our language
Semantics
Relations
By seriality, for every world w there is w 0 such that wRw 0 . If
Soundness
Results ϕ holds at w , then ϕ holds in w 0 , and thus ♦ϕ holds in
w.

Corollary
The axiom D is sound for all models with serial accessibility
relations.
Axiom T fails

Introduction
to Modal
Logic

W.Gunther The is a model M where ϕ → ϕ fails.


Propositional Proof.
Logic
Our Language
Semantics
Syntax
Results

Modal Logic P ¬P
Our language
Semantics
Relations
Soundness
Results
w1 w2

Problem: The relation is not reflexive!


Reflexive implies Axiom T

Introduction
to Modal
Logic

W.Gunther

Propositional Theorem
Logic
Our Language
Semantics
If a the accessibility relation is reflexive, then
Syntax
Results

Modal Logic
M |= ϕ → ϕ
Our language
Semantics
Relations
Soundness
Results Proof.
If ϕ holds at w , then ϕ holds in w as wRw by reflexivity.
Soundness of T and D

Introduction
to Modal
Logic

W.Gunther

Propositional
Logic
Our Language
Lemma
Semantics
Syntax Reflexive implies Serial
Results

Modal Logic
Our language Corollary
Semantics
Relations
Soundness The axioms T and D are sound for all models with reflexive
Results
accessibility relations.
Axiom 4 fails

Introduction
to Modal
Logic

W.Gunther The is a model M where ϕ → ϕ fails.


Propositional Proof.
Logic
Our Language
Semantics
Syntax
Results

Modal Logic P P ¬P
Our language
Semantics
Relations
Soundness
Results
w1 w2 w3

Problem: The relation is not transitive!


Soundness of Axiom 4

Introduction
to Modal
Logic

W.Gunther

Propositional
Logic
Our Language
Semantics
Syntax Corollary
Results

Modal Logic Axiom 4 is sound for all models with transitive accessibility
Our language
Semantics relations.
Relations
Soundness
Results
Axiom B fails

Introduction
to Modal
Logic

W.Gunther The is a model M where ϕ → ♦ϕ fails.


Propositional Proof.
Logic
Our Language
Semantics
Syntax
Results

Modal Logic P ¬P
Our language
Semantics
Relations
Soundness
Results
w1 w2

Problem: The relation is not symmetric!


Soundness of Axiom B

Introduction
to Modal
Logic

W.Gunther

Propositional
Logic
Our Language
Semantics
Syntax Corollary
Results

Modal Logic Axiom B is sound for all models with symmetric accessibility
Our language
Semantics relations.
Relations
Soundness
Results
Axiom 5 fails

Introduction
to Modal
Logic
The is a model M where ♦ϕ → ♦ϕ fails.
W.Gunther
Proof.
Propositional
Logic
Our Language
Semantics
w3 w2
Syntax
Results
P ¬P
Modal Logic
Our language
Semantics
Relations
Soundness
Results P

w1

Problem: The relation is not euclidean!


Soundness of Axiom 5

Introduction
to Modal
Logic

W.Gunther

Propositional
Logic
Our Language
Semantics
Syntax Corollary
Results

Modal Logic Axiom 5 is sound for all models with euclidean accessibility
Our language
Semantics relations.
Relations
Soundness
Results
Soundness of S5

Introduction
to Modal
Logic Lemma
W.Gunther
TFAE:
Propositional
Logic
1 Equivalence Relation
Our Language
Semantics 2 Reflexive, Symmetric, Transitive
Syntax
Results 3 Serial, Symmetric, Transitive
Modal Logic
Our language 4 Euclidean, Reflexive
Semantics
Relations
Soundness
Results Let the Axiom S be defined as K+N+T.
Corollary (S5 is sound)
If we can prove ϕ using the axioms S5 then every model with
its accessibility relation an equivalence relation models ϕ, ie.
this system is sound.
Completeness of S5

Introduction
to Modal
Logic

W.Gunther

Propositional
Logic
Our Language
Semantics Theorem (S5 is complete)
Syntax

If every model M with its accessibility relation an equivalence


Results

Modal Logic
Our language relation models ϕ then we can prove ϕ using the axioms S5, ie.
Semantics
Relations this system is complete.
Soundness
Results

You might also like