Logics for Computation The Story so Far

Lecture #6: No Way to Say Warm in French I We are working with the R language h i I We saw that the lenguage cannot say Carlos Areces and Patrick Blackburn I “I am not a tree” {carlos.areces,patrick.blackburn}@loria.fr I “I am infinite” I On the positive side INRIA Nancy Grand Est I It has a simple reasoning calculus: labelled tableaux Nancy, I It is decidable.

ESSLLI 2008 - Hamburg -

Areces & Blackburn: Logics for Computation INRIA Nancy Grand Est

What do we do Today One is the Same as Infinite

I We said in the previos lecture that we cannot say infinite in the R language. I We will extend the expressive power of the language. . . h i I Let’s see this in more detail. Consider the model: I . . . and explore quite a number of possibilities.

I We will learn to count till n.

I We will learn to name nodes. I We will learn to say “everywhere”. p p p p p ... I We will learn to say “it won’t take forever”.

I This is not a tree. Hence, there should be a tree like structure which should be the same as this one for the R language. h i

Areces & Blackburn: Logics for Computation INRIA Nancy Grand Est Areces & Blackburn: Logics for Computation INRIA Nancy Grand Est

One is the Same as Two Learning to Count Suppose we want to say that two green nodes are accessible . . .

I But let’s consider a simpler example (after all, infinite is quite a big number).

I We saw that the R language cannot distinguish between one h i and two!!! R green R green h i ∧ h i R (green pink) h i ∧ ∧ R (green pink) h i ∧¬ = 2 R green h i p p p

Areces & Blackburn: Logics for Computation INRIA Nancy Grand Est Areces & Blackburn: Logics for Computation INRIA Nancy Grand Est

Alice in Wonderland Extending the Language Humpty Dumpty: When I use a word, it means just what I choose it to mean – neither more nor less. Alice: The question is, whether you can make words mean so many dif- I What other things we cannot say in the R language? ferent things. h i Humpty Dumpty: The question is: which is to be master – that’s all. I Plenty: 1. In that particular node. If the language cannot express something we are interested in, I 2. Everywhere in the model. we just extend the language! 3. In a finite number of steps. I Counting successors: ... , w = = n R ϕ iff w 0 wRw 0 and , w 0 = ϕ = n Luckily, as Humpty Dumpty says, we are the masters, and we M | h i |{ | M | }| I can desing the language that better pleases us. = 2 R p = 2 R p The models are not the ¬h i h i same for the = n R lan- I Let’s get to work. . . I Clearly: h i guage. p p p

Areces & Blackburn: Logics for Computation INRIA Nancy Grand Est Areces & Blackburn: Logics for Computation INRIA Nancy Grand Est Names for Points Names for Points

Suppose that n is a name for a point. That is, it can labela I When we allow names in our language, our models will look unique point in any relational structure. like this:

n I We have already used something like names. n1 R (pink(blue n) Anybody remembers when? h i ∧ I Tableaux for the R h i language! n I If we also introduce the :-operator we can write I Looks useful. . . things like

I We can introduce names into our language (you probably n1:pink n know them as constants). n2: R pink 2 h i n : R R R n 2 h ih ih i 2

Areces & Blackburn: Logics for Computation INRIA Nancy Grand Est Areces & Blackburn: Logics for Computation INRIA Nancy Grand Est

Everywhere in the model In a Finite Number of Steps

I Suppose we want to paint everything pink (we love pink). I In the R language we can say h i I In one step p: R p I Can we do it? Let’s see and example, consider this model: h i I In two steps p: R R p h ih i I ... I Is there a formula of the R h i I But we cannot say, in a finite (zero or more, [[RU∗]pink]pink language, that we can make but unspecified) number of steps p: true at w, so that pink is p R p R R p ... true everywhere in the w [U]pink ∨ h i ∨ h ih i ∨

model? I Define the R∗ operator as h i I Define the [U] operator as , w = R∗ ϕ iff there is w 0 s.t. wR∗w 0 and , w 0 = ϕ M | h i M | , w = [U]ϕ iff for all w 0, , w 0 = ϕ for R is the reflexive and transitive closure of R. M | M | ∗ [U]pink (Let’s write [R ]ϕ for R ϕ) I Then , w = [U]pink if the ∗ ∗ M | ¬h i¬ whole model is pink. I Pretty choosy! (ok, let’s say selective) I Jah!

Areces & Blackburn: Logics for Computation INRIA Nancy Grand Est Areces & Blackburn: Logics for Computation INRIA Nancy Grand Est

The Complete Menu Back to the Intuitions! Our models are structures like = W , R , P , N M h { i } { i } { i }i The main idea we want to get across is: I Counting successors: There are plenty of options, go and chose what you need! , w = = n R ϕ iff w wRw and , w = ϕ = n. M | h i |{ 0 | 0 M 0 | }| Even more, if it is not there, then define it yourself (compare with , w = R ϕ iff there is w s.t. wRw and , w = ϕ.) Remember what Humpty Dumpty said: M | h i 0 0 M 0 | I Names and the :-operator: “The question is: Which is to be master” , w = n iff w = N M | i i I By combining the operators we have been discusing we obtain (compare with a wide variety of languages.

, w = pi iff w Pi ) I We go from languages of low expressivity (PL) to languages of M | ∈ , w = n :ϕ iff , N = ϕ high expressivity (the selective [R ]). M | 1 M i | ∗ (compare with I We go from languages of ‘low’ complexity (NP-complete) to , w = R ϕ iff there is w s.t. wRw and , w = ϕ.) languages of hight complexity (EXPTIME-complete). M | h i 0 0 M 0 | I The [U]-operator: I By chosing expressivity for a given application we , w = [U]ϕ iff for all w , , w = ϕ will pay the exact price required. M | 0 M 0 | (compare with , w = R ϕ iff there is w s.t. wRw and , w = ϕ.) Areces & Blackburn:M Logics| forh Computationi 0 0 M 0 | INRIA Nancy Grand Est Areces & Blackburn: Logics for Computation INRIA Nancy Grand Est I The [R∗]-operator: , w = R ϕ iff there is w s.t. wR w and , w = ϕ M | h ∗i 0 ∗ 0 M 0 | (compare with , w = R ϕ iff there is w s.t. wRw and , w = ϕ.) M | h i 0 0 M 0 | WhatI weAs weCovered can see, Today the menu is quite varied: GO POLYTHEISM!!! Relevant Bibliography I

[. . . ] No way to say warm in French. There was only hot and tepid. If there’s no word for it, how I We discussed the polytheistic approach in full glory: do you think about it? [. . . ] Imagine, in Spanish I counting I constants having to assign a gender to every object: dog, I universal quantification table, tree, can-opener. Imagine, in Hungarian, I reflexive and transitive closure not being able to assign a gender to anything: he,

I By combining all these operators we obtain very diverse logics. she, it all the same word.

I But, they all share the same semantics: relational structures! I My French is not good enough to say if it’s

I They are just different ways of talking about something. true. . . I But it’s definitely a great science fiction book!

Delany, Samuel (1966). Babel-17. Ace Books.

Areces & Blackburn: Logics for Computation INRIA Nancy Grand Est Areces & Blackburn: Logics for Computation INRIA Nancy Grand Est Relevant Bibliography II The Next Lecture

I Many of the languages that we have been discussing are investigated in detail in the area known as Modal Logics. I The name ‘modal’ (in many cases as opposed to ‘classical’) doesn’t make much sense. I Some of these languages have been extensively studied by somebody you know quite well by now. DIY First Order Logic Blackburn’s Web page: http://www.loria.fr/~blackbur I M. de Rijke also pushed the idea of working with modal logics extending the R language. h i de Rijke’s Web page: http://staff.science.uva.nl/~mdr/ Blackburn, Patrick and van Benthem, J (2006). Chapter 1 of the Handbook of Modal Logics, Blackburn, P.; Wolter, F.; and van Benthem, J., editors, Elsevier. de Rijke, Maarten (1993). Extending Modal Logic PhD Thesis. Institute for Logic, Language and Computation, Unviersity of Amsterdam.

Areces & Blackburn: Logics for Computation INRIA Nancy Grand Est Areces & Blackburn: Logics for Computation INRIA Nancy Grand Est