FORMAL METHODS LECTURE III: LINEAR TEMPORAL LOGIC

Size: px
Start display at page:

Download "FORMAL METHODS LECTURE III: LINEAR TEMPORAL LOGIC"

Transcription

1 Alessandro Artale (FM First Semester 2007/2008) p. 1/39 FORMAL METHODS LECTURE III: LINEAR TEMPORAL LOGIC Alessandro Artale Faculty of Computer Science Free University of Bolzano artale/ Some material (text, figures) displayed in these slides is courtesy of: M. Benerecetti, A. Cimatti, M. Fisher, F. Giunchiglia, M. Pistore, M. Roveri, R.Sebastiani.

2 Alessandro Artale (FM First Semester 2007/2008) p. 2/39 Summary of Lecture III Introducing Temporal Logics. Intuitions beyond Linear Temporal Logic. LTL: Syntax and Semantics. LTL in Computer Science. LTL Interpreted over Kripke Models. LTL and Model Checking: Intuitions.

3 Alessandro Artale (FM First Semester 2007/2008) p. 3/39 An Introduction to Temporal Logics In classical logic, formulae are evaluated within a single fixed world. For example, a proposition such as it is Monday must be either true or false. Propositions are then combined using constructs such as,, etc. But, most (not just computational) systems are dynamic. In temporal logics, evaluation takes place within a set of worlds. Thus, it is Monday may be satisfied in some worlds, but not in others.

4 Alessandro Artale (FM First Semester 2007/2008) p. 4/39 An Introduction to Temporal Logics (Cont.) The set of worlds correspond to moments in time. How we navigate between these worlds depends on our particular view of time. The particular model of time is captured by a temporal accessibility relation between worlds. Essentially, temporal logic extends classical propositional logic with a set of temporal operators that navigate between worlds using this accessibility relation.

5 Typical Models of Time Alessandro Artale (FM First Semester 2007/2008) p. 5/39

6 Alessandro Artale (FM First Semester 2007/2008) p. 6/39 Summary Introducing Temporal Logics. Intuitions beyond Linear Temporal Logic. LTL: Syntax and Semantics. LTL in Computer Science. LTL Interpreted over Kripke Models. LTL and Model Checking: Intuitions.

7 Alessandro Artale (FM First Semester 2007/2008) p. 7/39 Linear Temporal Logic (LTL): Intuitions Consider a simple temporal logic (LTL) where the accessibility relation characterises a discrete, linear model isomorphic to the Natural Numbers. Typical temporal operators used are ϕ ϕ ϕ ϕu ψ Examples: ϕ is true in the next moment in time ϕ is true in all future moments ϕ is true in some future moment ϕ is true until ψ is true (( passport ticket) board_ f light)

8 Alessandro Artale (FM First Semester 2007/2008) p. 8/39 Computational Example (requested received) (received processed) (processed done) From the above we should be able to infer that it is not the case that the system continually re-sends a request, but never sees it completed ( done); i.e. the statement requested done should be inconsistent.

9 Alessandro Artale (FM First Semester 2007/2008) p. 9/39 Summary Introducing Temporal Logics. Intuitions beyond Linear Temporal Logic. LTL: Syntax and Semantics. LTL in Computer Science. LTL Interpreted over Kripke Models. LTL and Model Checking: Intuitions.

10 Alessandro Artale (FM First Semester 2007/2008) p. 10/39 LTL: Syntax Countable set Σ of atomic propositions: p,q,... the set FORM of formulas is: ϕ, ψ p (atomic proposition) (true) (false) ϕ (complement) ϕ ψ (conjunction) ϕ ψ (disjunction) ϕ (next time) ϕ (always) ϕ (sometime) (until) ϕu ψ

11 Alessandro Artale (FM First Semester 2007/2008) p. 11/39 Temporal Semantics We interpret our temporal formulae in a discrete, linear model of time. Formally, this structure is represented by M = N,I where I : N 2 Σ maps each Natural number (representing a moment in time) to a set of propositions. The semantics of a temporal formula is provided by the satisfaction relation: =: (M N FORM) {true,false}

12 Alessandro Artale (FM First Semester 2007/2008) p. 12/39 Semantics: The Propositional Aspect We start by defining when an atomic proposition is true at a time point i M, i = p iff p I(i) (for p Σ) The semantics for the classical operators is as expected: M, i = ϕ iff M, i = ϕ M, i = ϕ ψ iff M, i = ϕ and M, i = ψ M, i = ϕ ψ iff M, i = ϕ or M, i = ψ M, i = ϕ ψ iff if M, i = ϕ then M, i = ψ M, i = M, i =

13 Alessandro Artale (FM First Semester 2007/2008) p. 13/39 Temporal Operators: next M, i = ϕ iff M, i+1 = ϕ This operator provides a constraint on the next moment in time. Examples: (sad rich) sad ((x = 0) add3) (x = 3)

14 Alessandro Artale (FM First Semester 2007/2008) p. 14/39 Temporal Operators: sometime M, i = ϕ iff there exists j. ( j i) M, j = ϕ N.B. while we can be sure that ϕ will be true either now or in the future, we can not be sure exactly when it will be true. Examples: ( resigned sad) famous sad happy send receive

15 Alessandro Artale (FM First Semester 2007/2008) p. 15/39 Temporal Operators: always M, i = ϕ iff for all j. if ( j i) then M, j = ϕ This can represent invariant properties. Examples: lottery-win rich

16 Alessandro Artale (FM First Semester 2007/2008) p. 16/39 Temporal Operators: until M, i = ϕu ψ iff there exists j. ( j i) M, j = ψ for all k. (i k < j) M, k = ϕ Examples: start_lecture talk U end_lecture born alive U dead request reply U acknowledgement

17 Alessandro Artale (FM First Semester 2007/2008) p. 17/39 Satisfiability and Validity A structurem = N,I is a model of φ, if M, i = φ, for some i N. Similarly as in classical logic, an LTL formula φ can be satisfiable, unsatisfiable or valid. A formula φ is: Satisfiable, if there is model for φ. Unsatisfiable, if φ is not satisfiable. Valid (i.e., a Tautology): = φ iff M, i N. M, i = φ.

18 Alessandro Artale (FM First Semester 2007/2008) p. 18/39 Entailment and Equivalence Similarly as in classical logic we can define the notions of entailment and equivalence between two LTL formulas Entailment. φ = ψ iff M, i N. M, i = φ M, i = ψ Equivalence. φ ψ iff M, i N. M, i = φ M, i = ψ

19 Alessandro Artale (FM First Semester 2007/2008) p. 19/39 Equivalences in LTL The temporal operators and are duals ϕ ϕ (and then ) can be rewritten in terms ofu ϕ U ϕ All the temporal operators can be rewritten using the Until and Next operators

20 Alessandro Artale (FM First Semester 2007/2008) p. 20/39 Equivalences in LTL (Cont.) distributes over while distributes over (ϕ ψ) ϕ ψ (ϕ ψ) ϕ ψ The following equivalences are useful for generating formulas in Negated Normal Form. ϕ ϕ (ϕu ψ) ( ψu ( ϕ ψ)) ψ

21 Alessandro Artale (FM First Semester 2007/2008) p. 21/39 LTL Vs. FOL Linear Temporal Logic can be thought of as a specific decidable (PSPACE-complete) fragment of classical first-order logic We just map each proposition to a unary predicate in FOL. In general, the following satisfiability preserving mapping ( ) holds: p p(t) p p(t + 1) p t. (t t) p(t ) p t. (t t) p(t )

22 Alessandro Artale (FM First Semester 2007/2008) p. 22/39 Summary Introducing Temporal Logics. Intuitions beyond Linear Temporal Logic. LTL: Syntax and Semantics. LTL in Computer Science. LTL Interpreted over Kripke Models. LTL and Model Checking: Intuitions.

23 Alessandro Artale (FM First Semester 2007/2008) p. 23/39 Temporal Logic in Computer Science Temporal logic was originally developed in order to represent tense in natural language. Within Computer Science, it has achieved a significant role in the formal specification and verification of concurrent reactive systems. Much of this popularity has been achieved as a number of useful concepts can be formally, and concisely, specified using temporal logics, e.g. safety properties liveness properties fairness properties

24 Alessandro Artale (FM First Semester 2007/2008) p. 24/39 Safety Properties Safety: something bad will not happen Typical examples: (reactor_temp > 1000) (one_way other_way) ((x = 0) (y = z/x)) and so on... Usually:...

25 Alessandro Artale (FM First Semester 2007/2008) p. 25/39 Liveness Properties Liveness: something good will happen Typical examples: rich (x > 5) (start terminate) and so on... Usually:...

26 Alessandro Artale (FM First Semester 2007/2008) p. 26/39 Fairness Properties Often only really useful when scheduling processes, responding to messages, etc. Strong Fairness: if something is attempted/requested infinitely often, then it will be successful/allocated infinitely often Typical example: ready run

27 Alessandro Artale (FM First Semester 2007/2008) p. 27/39 Summary Introducing Temporal Logics. Intuitions beyond Linear Temporal Logic. LTL: Syntax and Semantics. LTL in Computer Science. LTL Interpreted over Kripke Models. LTL and Model Checking: Intuitions.

28 Alessandro Artale (FM First Semester 2007/2008) p. 28/39 Kripke Models and Linear Structures Consider the following Kripke structure:!done done Its paths/computations can be seen as a set of linear structures (computation tree):!done!done!done!done!done!done!done!done done...!done done!done!done done done!done done done!done done done done!done done done done

29 Alessandro Artale (FM First Semester 2007/2008) p. 29/39 Path-Semantics for LTL LTL formulae are evaluated over the set N of Natural Numbers. Paths in Kripke structures are infinite and linear sequences of states. Thus, they are isomorphic to the Natural Numbers: π = s 0 s 1 s i s i+1 We want to interpret LTL formulas over Kripke structures. Given a Kripke structure,km = (S,I,R,AP,L), a path π inkm, a state s S, and an LTL formula φ, we define: 1. KM,π = φ, and then 2. KM,s = φ Based on the LTL semantics over the Natural Numbers.

30 Alessandro Artale (FM First Semester 2007/2008) p. 30/39 Path-Semantics for LTL (Cont.) We first extract an LTL model,m π = (π,i π ), from the Kripke structurekm.m π = (π,i π ) is such that: π is a path inkm I π is the restriction of L to states in π: s π and p AP, p I π (s) iff p L(s) Given a Kripke structure,km = (S,I,R,AP,L), a path π inkm, a state s S, and an LTL formula φ: 1. KM,π = φ iff M π,s 0 = φ with s 0 initial state of π 2. KM,s = φ iff KM,π = φ for all paths π starting at s.

31 Alessandro Artale (FM First Semester 2007/2008) p. 31/39 LTL Model Checking Definition Given a Kripke structure,km = (S,I,R,AP,L), the LTL model checking problemkm = φ: Check if KM,s 0 = φ, for every s 0 I initial state of the Kripke structurekm.

32 Alessandro Artale (FM First Semester 2007/2008) p. 32/39 Summary Introducing Temporal Logics. Intuitions beyond Linear Temporal Logic. LTL: Syntax and Semantics. LTL in Computer Science. LTL Interpreted over Kripke Models. LTL and Model Checking: Intuitions.

33 Alessandro Artale (FM First Semester 2007/2008) p. 33/39 Example 1: mutual exclusion (safety) N = noncritical, T = trying, C = critical N1, N2 User 1 User 2 turn=0 T1, N2 N1, T2 C1, N2 T1, T2 T1, T2 N1, C2 C1, T2 T1, C2 KM = (C 1 C 2 )?

34 Alessandro Artale (FM First Semester 2007/2008) p. 33/39 Example 1: mutual exclusion (safety) N = noncritical, T = trying, C = critical N1, N2 User 1 User 2 turn=0 T1, N2 N1, T2 C1, N2 T1, T2 T1, T2 N1, C2 C1, T2 T1, C2 KM = (C 1 C 2 )? YES: There is no reachable state in which (C 1 C 2 ) holds!

35 Alessandro Artale (FM First Semester 2007/2008) p. 34/39 Example 2: mutual exclusion (liveness) N = noncritical, T = trying, C = critical N1, N2 User 1 User 2 turn=0 T1, N2 N1, T2 C1, N2 T1, T2 T1, T2 N1, C2 C1, T2 T1, C2 KM = C 1?

36 Alessandro Artale (FM First Semester 2007/2008) p. 34/39 Example 2: mutual exclusion (liveness) N = noncritical, T = trying, C = critical N1, N2 User 1 User 2 turn=0 T1, N2 N1, T2 C1, N2 T1, T2 T1, T2 N1, C2 C1, T2 T1, C2 KM = C 1? NO: the blue cyclic path is a counterexample!

37 Alessandro Artale (FM First Semester 2007/2008) p. 35/39 Example 3: mutual exclusion (liveness) N = noncritical, T = trying, C = critical N1, N2 User 1 User 2 turn=0 T1, N2 N1, T2 C1, N2 T1, T2 T1, T2 N1, C2 C1, T2 T1, C2 KM = (T 1 C 1 )?

38 Alessandro Artale (FM First Semester 2007/2008) p. 35/39 Example 3: mutual exclusion (liveness) N = noncritical, T = trying, C = critical N1, N2 User 1 User 2 turn=0 T1, N2 N1, T2 C1, N2 T1, T2 T1, T2 N1, C2 C1, T2 T1, C2 KM = (T 1 C 1 )? YES: in every path if T 1 holds afterwards C 1 holds!

39 Alessandro Artale (FM First Semester 2007/2008) p. 36/39 Example 4: mutual exclusion (fairness) N = noncritical, T = trying, C = critical N1, N2 User 1 User 2 turn=0 T1, N2 N1, T2 C1, N2 T1, T2 T1, T2 N1, C2 C1, T2 T1, C2 KM = C 1?

40 Alessandro Artale (FM First Semester 2007/2008) p. 36/39 Example 4: mutual exclusion (fairness) N = noncritical, T = trying, C = critical N1, N2 User 1 User 2 turn=0 T1, N2 N1, T2 C1, N2 T1, T2 T1, T2 N1, C2 C1, T2 T1, C2 KM = C 1? NO: the blue cyclic path is a counterexample!

41 Alessandro Artale (FM First Semester 2007/2008) p. 37/39 Example 4: mutual exclusion (strong fairness) N = noncritical, T = trying, C = critical N1, N2 User 1 User 2 turn=0 T1, N2 N1, T2 C1, N2 T1, T2 T1, T2 N1, C2 C1, T2 KM = T 1 C 1? T1, C2

42 Alessandro Artale (FM First Semester 2007/2008) p. 37/39 Example 4: mutual exclusion (strong fairness) N = noncritical, T = trying, C = critical N1, N2 User 1 User 2 turn=0 T1, N2 N1, T2 C1, N2 T1, T2 T1, T2 N1, C2 C1, T2 KM = T 1 C 1? T1, C2 YES: every path which visits T 1 infinitely often also visits C 1 infinitely often!

43 Alessandro Artale (FM First Semester 2007/2008) p. 38/39 LTL Alternative Notation Alternative notations are used for temporal operators. F sometime in the Future G Globally in the future X nextime

44 Alessandro Artale (FM First Semester 2007/2008) p. 39/39 Summary of Lecture III Introducing Temporal Logics. Intuitions beyond Linear Temporal Logic. LTL: Syntax and Semantics. LTL in Computer Science. LTL Interpreted over Kripke Models. LTL and Model Checking: Intuitions.

FORMAL METHODS LECTURE IV: COMPUTATION TREE LOGIC (CTL)

FORMAL METHODS LECTURE IV: COMPUTATION TREE LOGIC (CTL) Alessandro Artale (FM First Semester 2007/2008) p. 1/37 FORMAL METHODS LECTURE IV: COMPUTATION TREE LOGIC (CTL) Alessandro Artale Faculty of Computer Science Free University of Bolzano artale@inf.unibz.it

More information

Summary. Computation Tree logic Vs. LTL. CTL at a glance. KM,s =! iff for every path " starting at s KM," =! COMPUTATION TREE LOGIC (CTL)

Summary. Computation Tree logic Vs. LTL. CTL at a glance. KM,s =! iff for every path  starting at s KM, =! COMPUTATION TREE LOGIC (CTL) Summary COMPUTATION TREE LOGIC (CTL) Slides by Alessandro Artale http://www.inf.unibz.it/ artale/ Some material (text, figures) displayed in these slides is courtesy of: M. Benerecetti, A. Cimatti, M.

More information

FORMAL METHODS LECTURE V: CTL MODEL CHECKING

FORMAL METHODS LECTURE V: CTL MODEL CHECKING FORMAL METHODS LECTURE V: CTL MODEL CHECKING Alessandro Artale Faculty of Computer Science Free University of Bolzano Room 2.03 artale@inf.unibz.it http://www.inf.unibz.it/ artale/ Some material (text,

More information

T Reactive Systems: Temporal Logic LTL

T Reactive Systems: Temporal Logic LTL Tik-79.186 Reactive Systems 1 T-79.186 Reactive Systems: Temporal Logic LTL Spring 2005, Lecture 4 January 31, 2005 Tik-79.186 Reactive Systems 2 Temporal Logics Temporal logics are currently the most

More information

Formal Methods Lecture VII Symbolic Model Checking

Formal Methods Lecture VII Symbolic Model Checking Formal Methods Lecture VII Symbolic Model Checking Faculty of Computer Science Free University of Bozen-Bolzano artale@inf.unibz.it http://www.inf.unibz.it/ artale/ Academic Year: 2006/07 Some material

More information

Logic: Propositional Logic (Part I)

Logic: Propositional Logic (Part I) Logic: Propositional Logic (Part I) Alessandro Artale Free University of Bozen-Bolzano Faculty of Computer Science http://www.inf.unibz.it/ artale Descrete Mathematics and Logic BSc course Thanks to Prof.

More information

Timo Latvala. February 4, 2004

Timo Latvala. February 4, 2004 Reactive Systems: Temporal Logic LT L Timo Latvala February 4, 2004 Reactive Systems: Temporal Logic LT L 8-1 Temporal Logics Temporal logics are currently the most widely used specification formalism

More information

Automata-Theoretic Model Checking of Reactive Systems

Automata-Theoretic Model Checking of Reactive Systems Automata-Theoretic Model Checking of Reactive Systems Radu Iosif Verimag/CNRS (Grenoble, France) Thanks to Tom Henzinger (IST, Austria), Barbara Jobstmann (CNRS, Grenoble) and Doron Peled (Bar-Ilan University,

More information

Introduction to Model Checking. Debdeep Mukhopadhyay IIT Madras

Introduction to Model Checking. Debdeep Mukhopadhyay IIT Madras Introduction to Model Checking Debdeep Mukhopadhyay IIT Madras How good can you fight bugs? Comprising of three parts Formal Verification techniques consist of three parts: 1. A framework for modeling

More information

Probabilistic Model Checking Michaelmas Term Dr. Dave Parker. Department of Computer Science University of Oxford

Probabilistic Model Checking Michaelmas Term Dr. Dave Parker. Department of Computer Science University of Oxford Probabilistic Model Checking Michaelmas Term 2011 Dr. Dave Parker Department of Computer Science University of Oxford Overview Temporal logic Non-probabilistic temporal logic CTL Probabilistic temporal

More information

LTL and CTL. Lecture Notes by Dhananjay Raju

LTL and CTL. Lecture Notes by Dhananjay Raju LTL and CTL Lecture Notes by Dhananjay Raju draju@cs.utexas.edu 1 Linear Temporal Logic: LTL Temporal logics are a convenient way to formalise and verify properties of reactive systems. LTL is an infinite

More information

Linear-time Temporal Logic

Linear-time Temporal Logic Linear-time Temporal Logic Pedro Cabalar Department of Computer Science University of Corunna, SPAIN cabalar@udc.es 2015/2016 P. Cabalar ( Department Linear oftemporal Computer Logic Science University

More information

Linear-Time Logic. Hao Zheng

Linear-Time Logic. Hao Zheng Linear-Time Logic Hao Zheng Department of Computer Science and Engineering University of South Florida Tampa, FL 33620 Email: zheng@cse.usf.edu Phone: (813)974-4757 Fax: (813)974-5456 Hao Zheng (CSE, USF)

More information

Modal and Temporal Logics

Modal and Temporal Logics Modal and Temporal Logics Colin Stirling School of Informatics University of Edinburgh July 23, 2003 Why modal and temporal logics? 1 Computational System Modal and temporal logics Operational semantics

More information

Chapter 4: Computation tree logic

Chapter 4: Computation tree logic INFOF412 Formal verification of computer systems Chapter 4: Computation tree logic Mickael Randour Formal Methods and Verification group Computer Science Department, ULB March 2017 1 CTL: a specification

More information

Logic: Propositional Logic Truth Tables

Logic: Propositional Logic Truth Tables Logic: Propositional Logic Truth Tables Raffaella Bernardi bernardi@inf.unibz.it P.zza Domenicani 3, Room 2.28 Faculty of Computer Science, Free University of Bolzano-Bozen http://www.inf.unibz.it/~bernardi/courses/logic06

More information

First Order Logic: Syntax and Semantics

First Order Logic: Syntax and Semantics CS1081 First Order Logic: Syntax and Semantics COMP30412 Sean Bechhofer sean.bechhofer@manchester.ac.uk Problems Propositional logic isn t very expressive As an example, consider p = Scotland won on Saturday

More information

Chapter 5: Linear Temporal Logic

Chapter 5: Linear Temporal Logic Chapter 5: Linear Temporal Logic Prof. Ali Movaghar Verification of Reactive Systems Spring 94 Outline We introduce linear temporal logic (LTL), a logical formalism that is suited for specifying LT properties.

More information

Description Logics. Deduction in Propositional Logic. franconi. Enrico Franconi

Description Logics. Deduction in Propositional Logic.   franconi. Enrico Franconi (1/20) Description Logics Deduction in Propositional Logic Enrico Franconi franconi@cs.man.ac.uk http://www.cs.man.ac.uk/ franconi Department of Computer Science, University of Manchester (2/20) Decision

More information

Chapter 6: Computation Tree Logic

Chapter 6: Computation Tree Logic Chapter 6: Computation Tree Logic Prof. Ali Movaghar Verification of Reactive Systems Outline We introduce Computation Tree Logic (CTL), a branching temporal logic for specifying system properties. A comparison

More information

PROPOSITIONAL LOGIC. VL Logik: WS 2018/19

PROPOSITIONAL LOGIC. VL Logik: WS 2018/19 PROPOSITIONAL LOGIC VL Logik: WS 2018/19 (Version 2018.2) Martina Seidl (martina.seidl@jku.at), Armin Biere (biere@jku.at) Institut für Formale Modelle und Verifikation BOX Game: Rules 1. The game board

More information

Tecniche di Verifica. Introduction to Propositional Logic

Tecniche di Verifica. Introduction to Propositional Logic Tecniche di Verifica Introduction to Propositional Logic 1 Logic A formal logic is defined by its syntax and semantics. Syntax An alphabet is a set of symbols. A finite sequence of these symbols is called

More information

Verification Using Temporal Logic

Verification Using Temporal Logic CMSC 630 February 25, 2015 1 Verification Using Temporal Logic Sources: E.M. Clarke, O. Grumberg and D. Peled. Model Checking. MIT Press, Cambridge, 2000. E.A. Emerson. Temporal and Modal Logic. Chapter

More information

Safety and Liveness Properties

Safety and Liveness Properties Safety and Liveness Properties Lecture #6 of Model Checking Joost-Pieter Katoen Lehrstuhl 2: Software Modeling and Verification E-mail: katoen@cs.rwth-aachen.de November 5, 2008 c JPK Overview Lecture

More information

Description Logics. Foundations of Propositional Logic. franconi. Enrico Franconi

Description Logics. Foundations of Propositional Logic.   franconi. Enrico Franconi (1/27) Description Logics Foundations of Propositional Logic Enrico Franconi franconi@cs.man.ac.uk http://www.cs.man.ac.uk/ franconi Department of Computer Science, University of Manchester (2/27) Knowledge

More information

Chapter 4: Classical Propositional Semantics

Chapter 4: Classical Propositional Semantics Chapter 4: Classical Propositional Semantics Language : L {,,, }. Classical Semantics assumptions: TWO VALUES: there are only two logical values: truth (T) and false (F), and EXTENSIONALITY: the logical

More information

Property Checking of Safety- Critical Systems Mathematical Foundations and Concrete Algorithms

Property Checking of Safety- Critical Systems Mathematical Foundations and Concrete Algorithms Property Checking of Safety- Critical Systems Mathematical Foundations and Concrete Algorithms Wen-ling Huang and Jan Peleska University of Bremen {huang,jp}@cs.uni-bremen.de MBT-Paradigm Model Is a partial

More information

Learning Goals of CS245 Logic and Computation

Learning Goals of CS245 Logic and Computation Learning Goals of CS245 Logic and Computation Alice Gao April 27, 2018 Contents 1 Propositional Logic 2 2 Predicate Logic 4 3 Program Verification 6 4 Undecidability 7 1 1 Propositional Logic Introduction

More information

Model for reactive systems/software

Model for reactive systems/software Temporal Logics CS 5219 Abhik Roychoudhury National University of Singapore The big picture Software/ Sys. to be built (Dream) Properties to Satisfy (caution) Today s lecture System Model (Rough Idea)

More information

Theoretical Foundations of the UML

Theoretical Foundations of the UML Theoretical Foundations of the UML Lecture 17+18: A Logic for MSCs Joost-Pieter Katoen Lehrstuhl für Informatik 2 Software Modeling and Verification Group moves.rwth-aachen.de/teaching/ws-1718/fuml/ 5.

More information

Timo Latvala. March 7, 2004

Timo Latvala. March 7, 2004 Reactive Systems: Safety, Liveness, and Fairness Timo Latvala March 7, 2004 Reactive Systems: Safety, Liveness, and Fairness 14-1 Safety Safety properties are a very useful subclass of specifications.

More information

Temporal logics and explicit-state model checking. Pierre Wolper Université de Liège

Temporal logics and explicit-state model checking. Pierre Wolper Université de Liège Temporal logics and explicit-state model checking Pierre Wolper Université de Liège 1 Topics to be covered Introducing explicit-state model checking Finite automata on infinite words Temporal Logics and

More information

22c:145 Artificial Intelligence

22c:145 Artificial Intelligence 22c:145 Artificial Intelligence Fall 2005 Propositional Logic Cesare Tinelli The University of Iowa Copyright 2001-05 Cesare Tinelli and Hantao Zhang. a a These notes are copyrighted material and may not

More information

LTL is Closed Under Topological Closure

LTL is Closed Under Topological Closure LTL is Closed Under Topological Closure Grgur Petric Maretić, Mohammad Torabi Dashti, David Basin Department of Computer Science, ETH Universitätstrasse 6 Zürich, Switzerland Abstract We constructively

More information

An Introduction to Temporal Logics

An Introduction to Temporal Logics An Introduction to Temporal Logics c 2001,2004 M. Lawford Outline Motivation: Dining Philosophers Safety, Liveness, Fairness & Justice Kripke structures, LTS, SELTS, and Paths Linear Temporal Logic Branching

More information

First Order Logic: Syntax and Semantics

First Order Logic: Syntax and Semantics irst Order Logic: Syntax and Semantics COMP30412 Sean Bechhofer sean.bechhofer@manchester.ac.uk Logic Recap You should already know the basics of irst Order Logic (OL) It s a prerequisite of this course!

More information

Lecture 16: Computation Tree Logic (CTL)

Lecture 16: Computation Tree Logic (CTL) Lecture 16: Computation Tree Logic (CTL) 1 Programme for the upcoming lectures Introducing CTL Basic Algorithms for CTL CTL and Fairness; computing strongly connected components Basic Decision Diagrams

More information

Temporal Logic. M φ. Outline. Why not standard logic? What is temporal logic? LTL CTL* CTL Fairness. Ralf Huuck. Kripke Structure

Temporal Logic. M φ. Outline. Why not standard logic? What is temporal logic? LTL CTL* CTL Fairness. Ralf Huuck. Kripke Structure Outline Temporal Logic Ralf Huuck Why not standard logic? What is temporal logic? LTL CTL* CTL Fairness Model Checking Problem model, program? M φ satisfies, Implements, refines property, specification

More information

THEORY OF SYSTEMS MODELING AND ANALYSIS. Henny Sipma Stanford University. Master class Washington University at St Louis November 16, 2006

THEORY OF SYSTEMS MODELING AND ANALYSIS. Henny Sipma Stanford University. Master class Washington University at St Louis November 16, 2006 THEORY OF SYSTEMS MODELING AND ANALYSIS Henny Sipma Stanford University Master class Washington University at St Louis November 16, 2006 1 1 COURSE OUTLINE 8:37-10:00 Introduction -- Computational model

More information

Applied Logic. Lecture 1 - Propositional logic. Marcin Szczuka. Institute of Informatics, The University of Warsaw

Applied Logic. Lecture 1 - Propositional logic. Marcin Szczuka. Institute of Informatics, The University of Warsaw Applied Logic Lecture 1 - Propositional logic Marcin Szczuka Institute of Informatics, The University of Warsaw Monographic lecture, Spring semester 2017/2018 Marcin Szczuka (MIMUW) Applied Logic 2018

More information

Overview. overview / 357

Overview. overview / 357 Overview overview6.1 Introduction Modelling parallel systems Linear Time Properties Regular Properties Linear Temporal Logic (LTL) Computation Tree Logic syntax and semantics of CTL expressiveness of CTL

More information

Modal logics: an introduction

Modal logics: an introduction Modal logics: an introduction Valentin Goranko DTU Informatics October 2010 Outline Non-classical logics in AI. Variety of modal logics. Brief historical remarks. Basic generic modal logic: syntax and

More information

Announcements. CS243: Discrete Structures. Propositional Logic II. Review. Operator Precedence. Operator Precedence, cont. Operator Precedence Example

Announcements. CS243: Discrete Structures. Propositional Logic II. Review. Operator Precedence. Operator Precedence, cont. Operator Precedence Example Announcements CS243: Discrete Structures Propositional Logic II Işıl Dillig First homework assignment out today! Due in one week, i.e., before lecture next Tuesday 09/11 Weilin s Tuesday office hours are

More information

Guest lecturer: Prof. Mark Reynolds, The University of Western Australia

Guest lecturer: Prof. Mark Reynolds, The University of Western Australia Università degli studi di Udine Corso per il dottorato di ricerca: Temporal Logics: Satisfiability Checking, Model Checking, and Synthesis January 2017 Lecture 01, Part 02: Temporal Logics Guest lecturer:

More information

Logical Structures in Natural Language: Propositional Logic II (Truth Tables and Reasoning

Logical Structures in Natural Language: Propositional Logic II (Truth Tables and Reasoning Logical Structures in Natural Language: Propositional Logic II (Truth Tables and Reasoning Raffaella Bernardi Università degli Studi di Trento e-mail: bernardi@disi.unitn.it Contents 1 What we have said

More information

Computation Tree Logic (CTL) & Basic Model Checking Algorithms

Computation Tree Logic (CTL) & Basic Model Checking Algorithms Computation Tree Logic (CTL) & Basic Model Checking Algorithms Martin Fränzle Carl von Ossietzky Universität Dpt. of Computing Science Res. Grp. Hybride Systeme Oldenburg, Germany 02917: CTL & Model Checking

More information

COMP9414: Artificial Intelligence Propositional Logic: Automated Reasoning

COMP9414: Artificial Intelligence Propositional Logic: Automated Reasoning COMP9414, Monday 26 March, 2012 Propositional Logic 2 COMP9414: Artificial Intelligence Propositional Logic: Automated Reasoning Overview Proof systems (including soundness and completeness) Normal Forms

More information

Linear Temporal Logic (LTL)

Linear Temporal Logic (LTL) Linear Temporal Logic (LTL) Grammar of well formed formulae (wff) φ φ ::= p (Atomic formula: p AP) φ (Negation) φ 1 φ 2 (Disjunction) Xφ (successor) Fφ (sometimes) Gφ (always) [φ 1 U φ 2 ] (Until) Details

More information

Finite-State Model Checking

Finite-State Model Checking EECS 219C: Computer-Aided Verification Intro. to Model Checking: Models and Properties Sanjit A. Seshia EECS, UC Berkeley Finite-State Model Checking G(p X q) Temporal logic q p FSM Model Checker Yes,

More information

Propositional logic (revision) & semantic entailment. p. 1/34

Propositional logic (revision) & semantic entailment. p. 1/34 Propositional logic (revision) & semantic entailment p. 1/34 Reading The background reading for propositional logic is Chapter 1 of Huth/Ryan. (This will cover approximately the first three lectures.)

More information

Chapter 3: Linear temporal logic

Chapter 3: Linear temporal logic INFOF412 Formal verification of computer systems Chapter 3: Linear temporal logic Mickael Randour Formal Methods and Verification group Computer Science Department, ULB March 2017 1 LTL: a specification

More information

Logic Model Checking

Logic Model Checking Logic Model Checking Lecture Notes 10:18 Caltech 101b.2 January-March 2004 Course Text: The Spin Model Checker: Primer and Reference Manual Addison-Wesley 2003, ISBN 0-321-22862-6, 608 pgs. the assignment

More information

Introduction to Temporal Logic. The purpose of temporal logics is to specify properties of dynamic systems. These can be either

Introduction to Temporal Logic. The purpose of temporal logics is to specify properties of dynamic systems. These can be either Introduction to Temporal Logic The purpose of temporal logics is to specify properties of dynamic systems. These can be either Desired properites. Often liveness properties like In every infinite run action

More information

FORMAL METHODS LECTURE VI BINARY DECISION DIAGRAMS (BDD S)

FORMAL METHODS LECTURE VI BINARY DECISION DIAGRAMS (BDD S) Alessandro Artale (FM First Semester 2009/2010) p. 1/38 FORMAL METHODS LECTURE VI BINARY DECISION DIAGRAMS (BDD S) Alessandro Artale Faulty of Computer Siene Free University of Bolzano artale@inf.unibz.it

More information

Computation Tree Logic

Computation Tree Logic Computation Tree Logic Hao Zheng Department of Computer Science and Engineering University of South Florida Tampa, FL 33620 Email: zheng@cse.usf.edu Phone: (813)974-4757 Fax: (813)974-5456 Hao Zheng (CSE,

More information

Temporal Logic. Stavros Tripakis University of California, Berkeley. We have designed a system. We want to check that it is correct.

Temporal Logic. Stavros Tripakis University of California, Berkeley. We have designed a system. We want to check that it is correct. EE 244: Fundamental Algorithms for System Modeling, Analysis, and Optimization Fall 2016 Temporal logic Stavros Tripakis University of California, Berkeley Stavros Tripakis (UC Berkeley) EE 244, Fall 2016

More information

Logic. Propositional Logic: Syntax. Wffs

Logic. Propositional Logic: Syntax. Wffs Logic Propositional Logic: Syntax Logic is a tool for formalizing reasoning. There are lots of different logics: probabilistic logic: for reasoning about probability temporal logic: for reasoning about

More information

CHAPTER 4 CLASSICAL PROPOSITIONAL SEMANTICS

CHAPTER 4 CLASSICAL PROPOSITIONAL SEMANTICS CHAPTER 4 CLASSICAL PROPOSITIONAL SEMANTICS 1 Language There are several propositional languages that are routinely called classical propositional logic languages. It is due to the functional dependency

More information

Linear Temporal Logic (LTL)

Linear Temporal Logic (LTL) Chapter 9 Linear Temporal Logic (LTL) This chapter introduces the Linear Temporal Logic (LTL) to reason about state properties of Labelled Transition Systems defined in the previous chapter. We will first

More information

Alan Bundy. Automated Reasoning LTL Model Checking

Alan Bundy. Automated Reasoning LTL Model Checking Automated Reasoning LTL Model Checking Alan Bundy Lecture 9, page 1 Introduction So far we have looked at theorem proving Powerful, especially where good sets of rewrite rules or decision procedures have

More information

Propositional Logic. Spring Propositional Logic Spring / 32

Propositional Logic. Spring Propositional Logic Spring / 32 Propositional Logic Spring 2016 Propositional Logic Spring 2016 1 / 32 Introduction Learning Outcomes for this Presentation Learning Outcomes... At the conclusion of this session, we will Define the elements

More information

Computer-Aided Program Design

Computer-Aided Program Design Computer-Aided Program Design Spring 2015, Rice University Unit 3 Swarat Chaudhuri February 5, 2015 Temporal logic Propositional logic is a good language for describing properties of program states. However,

More information

Model Checking: An Introduction

Model Checking: An Introduction Model Checking: An Introduction Meeting 3, CSCI 5535, Spring 2013 Announcements Homework 0 ( Preliminaries ) out, due Friday Saturday This Week Dive into research motivating CSCI 5535 Next Week Begin foundations

More information

MODEL CHECKING. Arie Gurfinkel

MODEL CHECKING. Arie Gurfinkel 1 MODEL CHECKING Arie Gurfinkel 2 Overview Kripke structures as models of computation CTL, LTL and property patterns CTL model-checking and counterexample generation State of the Art Model-Checkers 3 SW/HW

More information

cis32-ai lecture # 18 mon-3-apr-2006

cis32-ai lecture # 18 mon-3-apr-2006 cis32-ai lecture # 18 mon-3-apr-2006 today s topics: propositional logic cis32-spring2006-sklar-lec18 1 Introduction Weak (search-based) problem-solving does not scale to real problems. To succeed, problem

More information

Helsinki University of Technology Laboratory for Theoretical Computer Science Research Reports 66

Helsinki University of Technology Laboratory for Theoretical Computer Science Research Reports 66 Helsinki University of Technology Laboratory for Theoretical Computer Science Research Reports 66 Teknillisen korkeakoulun tietojenkäsittelyteorian laboratorion tutkimusraportti 66 Espoo 2000 HUT-TCS-A66

More information

Propositional Logic Language

Propositional Logic Language Propositional Logic Language A logic consists of: an alphabet A, a language L, i.e., a set of formulas, and a binary relation = between a set of formulas and a formula. An alphabet A consists of a finite

More information

Announcements. CS311H: Discrete Mathematics. Propositional Logic II. Inverse of an Implication. Converse of a Implication

Announcements. CS311H: Discrete Mathematics. Propositional Logic II. Inverse of an Implication. Converse of a Implication Announcements CS311H: Discrete Mathematics Propositional Logic II Instructor: Işıl Dillig First homework assignment out today! Due in one week, i.e., before lecture next Wed 09/13 Remember: Due before

More information

The State Explosion Problem

The State Explosion Problem The State Explosion Problem Martin Kot August 16, 2003 1 Introduction One from main approaches to checking correctness of a concurrent system are state space methods. They are suitable for automatic analysis

More information

Propositional Logic: Part II - Syntax & Proofs 0-0

Propositional Logic: Part II - Syntax & Proofs 0-0 Propositional Logic: Part II - Syntax & Proofs 0-0 Outline Syntax of Propositional Formulas Motivating Proofs Syntactic Entailment and Proofs Proof Rules for Natural Deduction Axioms, theories and theorems

More information

ECE473 Lecture 15: Propositional Logic

ECE473 Lecture 15: Propositional Logic ECE473 Lecture 15: Propositional Logic Jeffrey Mark Siskind School of Electrical and Computer Engineering Spring 2018 Siskind (Purdue ECE) ECE473 Lecture 15: Propositional Logic Spring 2018 1 / 23 What

More information

CTL Model checking. 1. finite number of processes, each having a finite number of finite-valued variables. Model-Checking

CTL Model checking. 1. finite number of processes, each having a finite number of finite-valued variables. Model-Checking CTL Model checking Assumptions:. finite number of processes, each having a finite number of finite-valued variables.. finite length of CTL formula Problem:Determine whether formula f 0 is true in a finite

More information

A brief introduction to Logic. (slides from

A brief introduction to Logic. (slides from A brief introduction to Logic (slides from http://www.decision-procedures.org/) 1 A Brief Introduction to Logic - Outline Propositional Logic :Syntax Propositional Logic :Semantics Satisfiability and validity

More information

First-Order Theorem Proving and Vampire

First-Order Theorem Proving and Vampire First-Order Theorem Proving and Vampire Laura Kovács 1,2 and Martin Suda 2 1 TU Wien 2 Chalmers Outline Introduction First-Order Logic and TPTP Inference Systems Saturation Algorithms Redundancy Elimination

More information

Lecture Notes on Software Model Checking

Lecture Notes on Software Model Checking 15-414: Bug Catching: Automated Program Verification Lecture Notes on Software Model Checking Matt Fredrikson André Platzer Carnegie Mellon University Lecture 19 1 Introduction So far we ve focused on

More information

Mathematical Logic Prof. Arindama Singh Department of Mathematics Indian Institute of Technology, Madras. Lecture - 15 Propositional Calculus (PC)

Mathematical Logic Prof. Arindama Singh Department of Mathematics Indian Institute of Technology, Madras. Lecture - 15 Propositional Calculus (PC) Mathematical Logic Prof. Arindama Singh Department of Mathematics Indian Institute of Technology, Madras Lecture - 15 Propositional Calculus (PC) So, now if you look back, you can see that there are three

More information

Model Checking. Temporal Logic. Fifth International Symposium in Programming, volume. of concurrent systems in CESAR. In Proceedings of the

Model Checking. Temporal Logic. Fifth International Symposium in Programming, volume. of concurrent systems in CESAR. In Proceedings of the Sérgio Campos, Edmund Why? Advantages: No proofs Fast Counter-examples No problem with partial specifications can easily express many concurrency properties Main Disadvantage: State Explosion Problem Too

More information

Classical First-Order Logic

Classical First-Order Logic Classical First-Order Logic Software Formal Verification Maria João Frade Departmento de Informática Universidade do Minho 2008/2009 Maria João Frade (DI-UM) First-Order Logic (Classical) MFES 2008/09

More information

Model Checking with CTL. Presented by Jason Simas

Model Checking with CTL. Presented by Jason Simas Model Checking with CTL Presented by Jason Simas Model Checking with CTL Based Upon: Logic in Computer Science. Huth and Ryan. 2000. (148-215) Model Checking. Clarke, Grumberg and Peled. 1999. (1-26) Content

More information

Topics in Verification AZADEH FARZAN FALL 2017

Topics in Verification AZADEH FARZAN FALL 2017 Topics in Verification AZADEH FARZAN FALL 2017 Last time LTL Syntax ϕ ::= true a ϕ 1 ϕ 2 ϕ ϕ ϕ 1 U ϕ 2 a AP. ϕ def = trueu ϕ ϕ def = ϕ g intuitive meaning of and is obt Limitations of LTL pay pay τ τ soda

More information

Principles of Knowledge Representation and Reasoning

Principles of Knowledge Representation and Reasoning Principles of Knowledge Representation and Reasoning Modal Logics Bernhard Nebel, Malte Helmert and Stefan Wölfl Albert-Ludwigs-Universität Freiburg May 2 & 6, 2008 Nebel, Helmert, Wölfl (Uni Freiburg)

More information

Abstractions and Decision Procedures for Effective Software Model Checking

Abstractions and Decision Procedures for Effective Software Model Checking Abstractions and Decision Procedures for Effective Software Model Checking Prof. Natasha Sharygina The University of Lugano, Carnegie Mellon University Microsoft Summer School, Moscow, July 2011 Lecture

More information

Motivation. CS389L: Automated Logical Reasoning. Lecture 10: Overview of First-Order Theories. Signature and Axioms of First-Order Theory

Motivation. CS389L: Automated Logical Reasoning. Lecture 10: Overview of First-Order Theories. Signature and Axioms of First-Order Theory Motivation CS389L: Automated Logical Reasoning Lecture 10: Overview of First-Order Theories Işıl Dillig Last few lectures: Full first-order logic In FOL, functions/predicates are uninterpreted (i.e., structure

More information

First-Order Logic First-Order Theories. Roopsha Samanta. Partly based on slides by Aaron Bradley and Isil Dillig

First-Order Logic First-Order Theories. Roopsha Samanta. Partly based on slides by Aaron Bradley and Isil Dillig First-Order Logic First-Order Theories Roopsha Samanta Partly based on slides by Aaron Bradley and Isil Dillig Roadmap Review: propositional logic Syntax and semantics of first-order logic (FOL) Semantic

More information

Propositional Logic: Review

Propositional Logic: Review Propositional Logic: Review Propositional logic Logical constants: true, false Propositional symbols: P, Q, S,... (atomic sentences) Wrapping parentheses: ( ) Sentences are combined by connectives:...and...or

More information

Formal Verification Techniques. Riccardo Sisto, Politecnico di Torino

Formal Verification Techniques. Riccardo Sisto, Politecnico di Torino Formal Verification Techniques Riccardo Sisto, Politecnico di Torino State exploration State Exploration and Theorem Proving Exhaustive exploration => result is certain (correctness or noncorrectness proof)

More information

Semantics and Pragmatics of NLP

Semantics and Pragmatics of NLP Semantics and Pragmatics of NLP Alex Ewan School of Informatics University of Edinburgh 28 January 2008 1 2 3 Taking Stock We have: Introduced syntax and semantics for FOL plus lambdas. Represented FOL

More information

Temporal & Modal Logic. Acronyms. Contents. Temporal Logic Overview Classification PLTL Syntax Semantics Identities. Concurrency Model Checking

Temporal & Modal Logic. Acronyms. Contents. Temporal Logic Overview Classification PLTL Syntax Semantics Identities. Concurrency Model Checking Temporal & Modal Logic E. Allen Emerson Presenter: Aly Farahat 2/12/2009 CS5090 1 Acronyms TL: Temporal Logic BTL: Branching-time Logic LTL: Linear-Time Logic CTL: Computation Tree Logic PLTL: Propositional

More information

Propositional and Predicate Logic - V

Propositional and Predicate Logic - V Propositional and Predicate Logic - V Petr Gregor KTIML MFF UK WS 2016/2017 Petr Gregor (KTIML MFF UK) Propositional and Predicate Logic - V WS 2016/2017 1 / 21 Formal proof systems Hilbert s calculus

More information

Temporal Logic and Fair Discrete Systems

Temporal Logic and Fair Discrete Systems Temporal Logic and Fair Discrete Systems Nir Piterman and Amir Pnueli Abstract Temporal logic was used by philosophers to reason about the way the world changes over time. Its modern use in specification

More information

15414/614 Optional Lecture 1: Propositional Logic

15414/614 Optional Lecture 1: Propositional Logic 15414/614 Optional Lecture 1: Propositional Logic Qinsi Wang Logic is the study of information encoded in the form of logical sentences. We use the language of Logic to state observations, to define concepts,

More information

Timed Automata. Chapter Clocks and clock constraints Clock variables and clock constraints

Timed Automata. Chapter Clocks and clock constraints Clock variables and clock constraints Chapter 10 Timed Automata In the previous chapter, we have discussed a temporal logic where time was a discrete entities. A time unit was one application of the transition relation of an LTS. We could

More information

First-Order Theorem Proving and Vampire. Laura Kovács (Chalmers University of Technology) Andrei Voronkov (The University of Manchester)

First-Order Theorem Proving and Vampire. Laura Kovács (Chalmers University of Technology) Andrei Voronkov (The University of Manchester) First-Order Theorem Proving and Vampire Laura Kovács (Chalmers University of Technology) Andrei Voronkov (The University of Manchester) Outline Introduction First-Order Logic and TPTP Inference Systems

More information

Lecture Notes on Emptiness Checking, LTL Büchi Automata

Lecture Notes on Emptiness Checking, LTL Büchi Automata 15-414: Bug Catching: Automated Program Verification Lecture Notes on Emptiness Checking, LTL Büchi Automata Matt Fredrikson André Platzer Carnegie Mellon University Lecture 18 1 Introduction We ve seen

More information

AI Principles, Semester 2, Week 2, Lecture 5 Propositional Logic and Predicate Logic

AI Principles, Semester 2, Week 2, Lecture 5 Propositional Logic and Predicate Logic AI Principles, Semester 2, Week 2, Lecture 5 Propositional Logic and Predicate Logic Propositional logic Logical connectives Rules for wffs Truth tables for the connectives Using Truth Tables to evaluate

More information

3. Only sequences that were formed by using finitely many applications of rules 1 and 2, are propositional formulas.

3. Only sequences that were formed by using finitely many applications of rules 1 and 2, are propositional formulas. 1 Chapter 1 Propositional Logic Mathematical logic studies correct thinking, correct deductions of statements from other statements. Let us make it more precise. A fundamental property of a statement is

More information

6. Logical Inference

6. Logical Inference Artificial Intelligence 6. Logical Inference Prof. Bojana Dalbelo Bašić Assoc. Prof. Jan Šnajder University of Zagreb Faculty of Electrical Engineering and Computing Academic Year 2016/2017 Creative Commons

More information

Characterizing Fault-Tolerant Systems by Means of Simulation Relations

Characterizing Fault-Tolerant Systems by Means of Simulation Relations Characterizing Fault-Tolerant Systems by Means of Simulation Relations TECHNICAL REPORT Ramiro Demasi 1, Pablo F. Castro 2,3, Thomas S.E. Maibaum 1, and Nazareno Aguirre 2,3 1 Department of Computing and

More information

Propositional Logic: Syntax

Propositional Logic: Syntax Logic Logic is a tool for formalizing reasoning. There are lots of different logics: probabilistic logic: for reasoning about probability temporal logic: for reasoning about time (and programs) epistemic

More information

Propositional Logic Not Enough

Propositional Logic Not Enough Section 1.4 Propositional Logic Not Enough If we have: All men are mortal. Socrates is a man. Does it follow that Socrates is mortal? Can t be represented in propositional logic. Need a language that talks

More information