A Journey through the Possible Worlds of Modal Logic Lecture 1: Introduction to modal logics Valentin Goranko Department of Philosophy, Stockholm University ESSLLI 2016, Bolzano, August 22, 2016
Outline Brief history of modal logic Variety of modalities and modal logics. Basic generic modal logic: syntax and possible worlds semantics. Truth and validity of modal formulae. Some important modal principles. Modal logics defined semantically and deductively. Relationships between modal logic and classical logic.
Modal logic: some pre-historical remarks Aristotle: Modes of truth. Necessary and possible truths. It is possible for A to hold of some B, A necessarily holds of every B. The problem of assigning truth to future contingencies. Sea-battle tomorrow argument. Megarian School. Diodorus Cronus and Philo of Megara: early versions of propositional logic. Considered the four modalities: possibility, impossibility, necessity and non-necessity as as modal properties of propositions. Diodorus defined possible as what is or will ever be and necessary as what is and will always be. The Diodorean conditional: precursor of the strict implication. Diodorus rejected future contingents. Master Argument Stoic School. Chrysippus: the 2nd greatest ancient logician, after Aristotle. Founder of propositional logic. Also, founder of non-classical logics, incl. modal, tense, epistemic, etc.
Modal logic: from medieval times to early 1900s Medieval (modal) logic: mostly about theological issues, but some interesting ideas, too. E.g., Willem of Ockham. Leibniz: A necessary truth is truth in all possible worlds H. MacColl 1897: causal and general implications. Certain, impossible and variable statements.
Early history of modal logic C.I. Lewis, 1912: problems with the material implication: A false proposition implies any proposition, e.g., If 2+2=5 then the Moon is made of cheese. A true proposition follows from any proposition, e.g. If the Sun is made of ice then the Sun is hot. Lewis proposal: to add a strict implication A B := (A B), where means possibly true. Equivalently: A B (A B), where X := X means X is necessarily true. Lewis, 1920-1932: introduced 5 systems of modal logic, S1 S5, purporting to capture the properties of the strict implication.
Some side remarks on the material implication Other problems with the classical (material) implication: Irrelevance/non-causality: If the Sun is hot, then 2+2=4. Material vs causal implication. E.g. monotonicity applies to the former but not to the latter: If I put sugar in my tea, then it will taste good. If I put sugar and I put petrol in my tea then it will taste good. Lead respectively to relevant logics and non-monotonic logics.
Early history of modal logic, continued K. Gödel, 1933: separates propositional and modal axioms. Interpretation of Brower-Heyting s intuitionistic logic into S4. Necessity as provability. S4 as a logic of provability. G. von Wright, 1951: An Essay in Modal Logic: alethic, epistemic and deontic modal logics. E. Lemmon 1957: alternative axiomatizations of Lewis systems. J. Lukasiewicz, J. Dugundji, J. McKinsey, etc., 1930-50s: Algebraic approaches. Characteristic matrices and algebras. Decidability of S2 S4. A. Tarski and B. Jónsson, 1951-1952: representation theorem for Boolean algebras with operators. No modal logic mentioned!
Modal logic: origins of possible worlds semantics Leibniz: possible worlds. Wittgenstein: possible states of affairs. R. Carnap, 1940s. Meaning and Necessity. State descriptions. Logical truth (L-truth) as holding in all state descriptions. Denoted A. R. Barcan, R. Carnap, 1940s: Modalities and Quantification. Quantified modal logics. Quine: interpretation problem for quantified modal logic. J. Hintikka, S. Kanger, R. Montague, A. Prior, late 1950s: accessibility relations between possible worlds. See Ballarin s SEP article on the Modern Origins of Modal Logic and Lindström & Segerberg s HBML chapter on the logical and metaphysical interpretations of the alethic modalities.
The beginning of modern modal logic: Kripke semantics S. Kripke, early 1960s: Semantical Analysis of Modal Logic I, II puts together all important ingredients of the possible worlds (aka, relational) semantics, characterises semantically and proves completeness and decidability of a wide range of important modal logics, relates possible worlds and algebraic semantics, proves completeness and undecidability of quantified S5.
The golden era of modal logic: 1960s 1960s-1980s: an explosion of model-theoretic and proof-theoretic studies, completeness and expressiveness results in modal logic. 1980s : modal logic gradually changes focus and expands its scope: hybrid, multi-modal, multi-dimensional, multi-agent etc. extended modal logics. ML becomes increasingly popular as a versatile and universal suitably expressive and computationally well-behaved logical framework for knowledge representation and reasoning in various areas of Philosophy, Mathematics, Linguistics, Artificial Intelligence and Computer Science. See the SEP article on Modal Logic and the other supplementary readings on the course webpage.
Modes of truth and meanings of the modal operators Basic modal operators: and. Meaning: In alethic logic: ϕ: ϕ is necessarily true ; ϕ: ϕ is possibly true ; In temporal logic: ϕ: ϕ will always be true, ϕ: ϕ will become true sometime in the future, In logic of beliefs: ϕ: the agent believes ϕ ; ϕ: the agent does not disbelieve ϕ, i.e. ϕ is consistent with the agent s beliefs ; In logic of knowledge: ϕ: the agent knows that ϕ ; ϕ: ϕ is consistent with the agent s knowledge ; In deontic logic: ϕ: ϕ is obligatory ; ϕ: ϕ is permitted ; In logic of (non-deterministic) programs: ϕ: ϕ will be true after every execution of the program, ϕ: ϕ will be true after some execution of the program.
Variety of modal reasoning and logics. Necessary and possible truths. Alethic logics. Truths over time. Temporal reasoning. Temporal logics. Reasoning about knowledge. Epistemic logics. Reasoning about beliefs. Doxastic logics. Reasoning about obligations and permissions. Deontic logics. Reasoning about spatial relations. Spatial logics. Reasoning about ontologies. Description logics. Reasoning about provability in a formal theory (e.g. in Peano Arithmetic). Provability logics. Reasoning about program executions. Logics of programs. Specification of transition systems. Logics of computations. Reasoning about many agents and their knowledge, beliefs, goals, actions, strategies, etc. Logics of multiagent systems.
Necessary and possible truths. Alethic modal logics ϕ ϕ: What is necessarily true is not possibly not true. ϕ ϕ: What is possibly true is not necessarily not true. Iterating: ϕ: ϕ is necessarily possibly true. ϕ: ϕ is possibly necessarily true. etc.
The basic propositional modal logic ML: syntax Language of ML: logical connectives,,, and a unary modal operator, and a set of atomic propositions AP = {p 0, p 1,...}. Formulae: Definable propositional connectives: := ; ϕ ψ := ( ϕ ψ); ϕ ψ := (ϕ ψ); ϕ ψ := (ϕ ψ) (ψ ϕ). ϕ = p ϕ (ϕ ϕ) ϕ is defined as the dual operator of : ϕ = ϕ.
Some important modal principles K: T: D: B: 4: 5: (p q) ( p q) p p p p p p p p p p Church-Rosser: p p McKinsey : Gödel Löb: p p ( p p) p
Semantic structures for modal logic: frames and models Kripke frame: a pair (W, R), where: W is a non-empty set of possible worlds, R W 2 is an accessibility relation between possible worlds. Kripke model over a frame T : a pair (T, V ) where V : AP P(W ) is a valuation assigning to every atomic proposition the set of possible worlds where it is true. Sometimes, instead of valuations, Kripke models are defined in terms of labelling functions: L : W P(AP), where L(s) comprises the atomic propositions true in the possible world s.
Kripke model: example s 2 {p,q} s 3 {p} s 1 {q} s 6 {p,q} s 4 {q} s 5 {} The valuation: V (p) = {s 2, s 3, s 6 }, V (q) = {s 1, s 2, s 4, s 6 }.
Kripke semantics of modal logic Truth of a formula ϕ at a possible world u in a Kripke model M = (W, R, V ), denoted M, u = ϕ, is defined as follows: M, u = p iff u V (p); M, u = ; M, u = ϕ iff M, u = ϕ; M, u = ϕ 1 ϕ 2 iff M, u = ϕ 1 and M, u = ϕ 2 ; M, u = ϕ iff M, w = ϕ for every w W such that Ruw. Respectively, M, u = ϕ iff M, w = ϕ for some w W such that Ruw. An important feature of modal logic: the notion of truth is local, i.e., at a state of a model. However, modal formulae cannot refer explicitly to possible worlds.
Truth of modal formulae: exercises s 1 {q} s 2 {p,q} s 4 {q} M s 3 {p} s 5 {} s 6 {p,q} Check the following: M, s 1? = q p. Yes. M, s 1? = q. No. M, s 1? = q. Yes. M, s 2? = (q q). Yes: take s 6. M, s 2? = (p q). No. M, s 3? = ( q p). Yes; M, s 4? = (q p q). No. M, s 6? = ( q (p q)). Yes.
Validity and satisfiability of modal formulae A modal formula ϕ is: valid in a model M, denoted M = ϕ, if it is true in every world of M valid at a possible world u in a frame T, denoted T, u = ϕ, if it is true in u in every model on T valid in a frame T, denoted T = ϕ, if it is valid on every model on T valid, denoted = ϕ, if it is valid in every model (or frame). satisfiable, if it is true in some possible world of some model, i.e., if its negation is not valid. A proposition ϕ is contingent (in a possible world) if ϕ ϕ holds (true in that possible world); ϕ is analytic (in a possible world) if ϕ ϕ holds (true in that possible world).
Does the strict implication solve the problems of the material implication? Local logical consequence in modal logic: ϕ 1,... ϕ n = ψ iff for every model M and u M, if M, u = ϕ i for each i = 1,... n then M, u = ψ. Do the following hold for the strict implication A B (A B)? 1. ϕ, ϕ ψ = ψ 2. ϕ = ϕ ψ 3. ψ = ϕ ψ 4. ϕ = ϕ ψ 5. ψ = ϕ ψ
Exercise: time and necessity Consider the following postulates: What is true of the past is necessarily true. The impossible cannot follow from the possible. There is something which is possible, but is neither true now nor will ever be true. Are these consistent together?
Addendum: Extension of a formula The extension of a formula ϕ in a Kripke model M = (W, R, V ) is the set of states in M satisfying the formula: ϕ M := {s M, s = ϕ}. The extension of a formula ϕ M can be computed inductively on the construction of ϕ: M = ; p M = V (p) ϕ M = W \ ϕ M ; ϕ 1 ϕ 2 M = ϕ 1 M ϕ 2 M ; ϕ M = {s R(s) ϕ M }.
Addendum: Model checking of modal formulae Model checking is a procedure checking whether a given model satisfies given property, usually specified in some logical language. Model checking may, or may not, be algorithmically decidable, depending on the logical formalism and the class of models under consideration. The main model checking problems for modal logic are: 1. Local model checking: given a Kripke model M, a state u M and a modal formula ϕ, determine whether M, u = ϕ; 2. Global model checking: given a Kripke model M and a modal formula ϕ, determine the set ϕ M.
Global model checking of modal formulae: exercises M Compute the following: s 2 {p,q} s 3 {p} p M = {s 1, s 2, s 6 }. p p M = {s 2, s 6 }. s 1 {q} s 6 {p,q} (p p) M = {s 1, s 2, s 5 }. s 4 {q} s 5 {} q (p p) M = {s 1, s 2, s 4, s 5, s 6 }. ( p q) M =?
Addendum: an algorithm for global model checking of modal formulae Global model checking algorithm for ML: given a (finite) Kripke model M and a formula θ, compute the extensions ϕ M for all subformulae ϕ of θ recursively, by labelling all possible worlds with those subformulae of θ that are true in those worlds, as follows: The labelling of atomic propositions is given by the valuation. The propositional cases are routine. ϕ consists of all states which have all their successors in ϕ, i.e. labelled by ϕ. This simple algorithm is very efficient: it works in linear time, both in the length of the formula and in the size of the model.
Addendum: Standard translation of modal logic to first-order logic L 0 : a FO language with =, a binary predicate R, and individual variables VAR = {x 0, x 1,...}. L 1 : a FO language extending L 0 with a set of unary predicates {P 0, P 1,...}, corresponding to the atomic propositions p 0, p 1,... The formulae of ML are translated into L 1 by the following standard translation, where the individual variable x is a parameter: ST(p i ; x) := P i x, for every p i AP, ST( φ; x) := ST(φ; x), ST(φ 1 φ 2 ; x) := ST(φ 1 ; x) ST(φ 2 ; x), ST( φ; x) := y(rxy ST(φ; y)), where y is the first variable in VAR not used yet in the translation of ST (φ; x). Respectively, we obtain: ST(φ 1 φ 2 ; x) ST(φ 1 ; x) ST(φ 2 ; x) ST(φ 1 φ 2 ; x) ST(φ 1 ; x) ST(φ 2 ; x)
Standard translation of modal formulae: some examples ST( p p; x 0 ) = x 1 (Rx 0 x 1 Px 1 ) Px 0 or, after renaming, just y(rx 0 y Py) Px 0 ) ST( p; x 0 ) = x 1 (Rx 0 x 1 x 2 (Rx 1 x 2 x 3 (Rx 2 x 3 Px 3 ))) or, ignoring the concrete variables: ST( p; x) = y(rxy z(ryz u(rzu Pu))), NB: It suffices to alternate only two variables, e.g. x and y. Note that the formula above is equivalent to y(rxy x(ryx y(rxy Py))). ST( p 1 p 2 ; x) = x 1 (Rxx 1 x 2 (Rx 1 x 2 P 1 x 2 )) x 3 (Rxx 3 P 2 x 3 ) equivalent to y(rxy x(ryx P 1 x)) y(rxy P 2 y). (The formula above re-uses only 2 variables.)
Now, for every Kripke model M, w M and ϕ ML: M, w = ϕ iff M, w = FO ST(ϕ; x)[x := w], Accordingly, M = ϕ iff M = FO xst(ϕ; x). Then, validity of a modal formula in a frame translates into: T = ϕ iff T = P 1... P k xst(ϕ; x). where P 1,..., P k are the unary predicates occurring in ϕ. Thus, modal logic can be used as a language to specify properties of Kripke models, and to specify properties of Kripke frames. In terms of validity in Kripke models, ML is a fragment of the first-order language L 1, while in terms of validity in Kripke frames, it is a fragment of universal monadic second order logic over L 0.
Validity of modal formulae in Kripke frames Checking validity of a modal formula ϕ in a frame T requires checking validity of ϕ in all Kripke models based on T, i.e., for all possible valuations of the atomic propositions occurring in ϕ. T : s 2 s 3 Check the following: T, s 1? = p p. Yes. T, s 1? = p p. No. s 1 T, s 1? = p p. Yes. T, s 1? = p p. Yes. s 4 s 5 T, s 1? = ( p p). No. T? = p p. No. T? = p p. Yes. T? = (p q) ( p q). Yes.
Addendum: Some important properties of binary relations A binary relation R X 2 is called: reflexive if it satisfies x xrx. irreflexive if it satisfies x xrx. serial if it satisfies x y xry. functional if it satisfies x!y xry, where!y means there exists a unique y. symmetric if it satisfies x y(xry yrx). asymmetric if it satisfies x y(xry yrx). antisymmetric if it satisfies x y(xry yrx x = y). connected if it satisfies x y(xry yrx). transitive if it satisfies x y z((xry yrz) xrz). equivalence relation if it is reflexive, symmetric, and transitive. euclidean if it satisfies x y z((xry xrz) yrz). pre-order, (or quasi-order) if it is reflexive and transitive. partial order, if it is reflexive, transitive, and antisymmetric. linear order, (or total order) if it is a connected partial order.
Some relational properties of Kripke frames definable by modal formulae Claim For every Kripke frame T = (W, R) the following holds: T = p p iff the relation R is reflexive. T = p p iff the relation R is serial. Exercise: find a simpler modal formula that defines seriality. T = p p iff T = p p iff the relation R is symmetric. T = p p iff T = p p iff the relation R is transitive. T = p p iff T = p p iff the relation R is euclidean.
Addendum: On the correspondence between modal logic and first-order logic on Kripke frames Not every modal formula defines a first-order property on Kripke frames. Example: for every Kripke frame T = (W, R) the following holds: T = ( p p) p iff the relation R is transitive and has no infinite increasing chains. (NB. The latter property is not definable in FOL.) On the other hand, not every first-order definable property is definable by a modal formula. For instance, the properties of irreflexivity, asymmetry, and connectiveness are not modally definable. The correspondence between modal logic and first-order logic has been studied in depth. See Handbook of Modal Logic for further details and references.
Modal logics defined semantically Many important modal logics can be defined by restricting the class of Kripke frames in which modal formulae are interpreted, and defining the logic to capture the valid formulae in that class of frames. For instance, such are the logics: The logic K of all Kripke frames. The logic D of all serial Kripke frames. The logic T of all reflexive Kripke frames. The logic B of all symmetric Kripke frames. The logic K4 of all transitive Kripke frames. The logic S4 of all reflexive and transitive Kripke frames. The logic S5 of all reflexive, transitive, and symmetric Kripke frames, i.e. all equivalence relations.
Some valid modal formulae Every modal instance of a propositional tautology, i.e., every formula obtained by uniform substitution of modal formulae for propositional variables in a propositional tautology. For instance: p p; ( p q) q, etc. K: (p q) ( p q); (p q) ( p q). (p q) ( p q). ϕ, for every valid modal formula ϕ. E.g., ( p p), ( p p), etc.
The basic modal logic K as a deductive system A (modal) logic can alternatively be defined as a deductive system, e.g. as an axiomatic system. For instance, an axiomatic system for the modal logic K can be defined by extending an axiomatic system H for classical propositional logic with the axiom K : (p q) ( p q) and the Necessitation rule: ϕ ϕ It turns out (Kripke, 1963) that this axiomatic system is sound and complete with respect to validity in all Kripke frames.
Modal logics defined deductively Many (but not all!) modal logics can be defined syntactically, as deductive systems, by extending K with additional axioms defining the respective class of Kripke frames. T = K + p p; D = K + p p; B = K + p p; K4 = K + p p; S4 = T4 = K4 + p p; S5 = BS4 = S4 + p p. Each of these has been proved (most of them already by Kripke, 1963) sound and complete for the respective class of Kripke frames that defines the logic semantically. See some references on the course webpage.
Addendum: A few words on deduction in modal logic Many more sound and complete axiomatic systems have been developed for modal logics, including those mentioned earlier. However, such axiomatic systems are not suitable for practical deduction. Likewise, tableau-based systems of deduction have been developed for a wide range of modal logics, by adding specific rules of inference capturing their specific semantic properties. Such systems are practically useful, but often not easy to design. Also, systems of natural deduction and sequent calculi for various modal logics have been constructed. Alternatively, resolution-based systems of deduction have been developed, typically based on standard translation from modal logic to FOL. They only work well for some modal logics.
Exercises 1. For each of the formulae T, B, D, 4, 5 listed in the slides decide which of the meanings of the following interpretation of the modal operator should be considered a valid principle. Necessity Knowledge Belief Truth always in the future Truth always in the past 2. Consider the following definition: Knowledge is justified true belief. Do you agree with it or not? Why?