Formal Methods in Software Engineering. Lecture 07

Similar documents
Introduction to Linear-Time Temporal Logic. CSE 814 Introduction to LTL

Software Model Checking: Theory and Practice

T Reactive Systems: Kripke Structures and Automata

System Correctness. EEC 421/521: Software Engineering. System Correctness. The Problem at Hand. A system is correct when it meets its requirements

Formal Verification. Lecture 10

Proving the Correctness of Distributed Algorithms using TLA

Leveraging DTrace for runtime verification

Model Checking with Automata An Overview

Formal modelling and verification in UPPAAL

Timo Latvala. January 28, 2004

Formal Analysis and Verification of a Communication Protocol

Formal Specification and Verification

Linear Temporal Logic. Model Checking and. Based on slides developed by Natasha Sharygina. Carnegie Mellon University.

INF672 Protocol Safety and Verification. Karthik Bhargavan Xavier Rival Thomas Clausen

Finite State Verification. CSCE Lecture 14-02/25/2016

Distributed Systems Programming (F21DS1) Formal Verification

Formal Methods for Software Development

Double Header. Two Lectures. Flying Boxes. Some Key Players: Model Checking Software Model Checking SLAM and BLAST

Model checking Timber program. Paweł Pietrzak

Finite State Verification. CSCE Lecture 21-03/28/2017

Lecture 11 Lecture 11 Nov 5, 2014

Temporal Logic and Timed Automata

Warm-Up Problem. Let L be the language consisting of as constant symbols, as a function symbol and as a predicate symbol. Give an interpretation where

Specification and Analysis of Real-Time Systems Using Real-Time Maude

A MODELING TOOL FOR A NEW DEFINITION OF STOCHASTIC ACTIVITY NETWORKS *

NOTES ON OBJECT-ORIENTED MODELING AND DESIGN

Course Modelling of Concurrent Systems Summer Semester 2016 University of Duisburg-Essen

A Tutorial on Runtime Verification and Assurance. Ankush Desai EECS 219C

Development of Generic Ground Systems by the Use of a Standard Modeling Method. Takahiro Yamada JAXA/ISAS March 1, 2005

Petri Nets. Petri Nets. Petri Net Example. Systems are specified as a directed bipartite graph. The two kinds of nodes in the graph:

COMP 763. Eugene Syriani. Ph.D. Student in the Modelling, Simulation and Design Lab School of Computer Science. McGill University

Model Checking. Dragana Cvijanovic

Coq projects for type theory 2018

[module 2.2] MODELING CONCURRENT PROGRAM EXECUTION

Overview. CS389L: Automated Logical Reasoning. Lecture 6: First Order Logic Syntax and Semantics. Constants in First-Order Logic.

Distributed Systems Programming (F21DS1) SPIN: Formal Analysis II

The Maude LTL Model Checker and Its Implementation

Cyber Physical System Verification with SAL

Further Topics in Modelling & Verification

Overview. Discrete Event Systems - Verification of Finite Automata. What can finite automata be used for? What can finite automata be used for?

Symbolic Trajectory Evaluation - A Survey

Distributed Memory LTL Model Checking

SCADE S E M I N A R I N S O F T W A R E E N G I N E E R I N G P R E S E N T E R A V N E R B A R R

A Modular Model Checking Algorithm for Cyclic Feature Compositions

CSC2108: Automated Verification Assignment 1 - Solutions

Verifying Temporal Properties via Dynamic Program Execution. Zhenhua Duan Xidian University, China

Verification of Concurrent Programs, Part I: The Temporal Framework

Relational Specification of Interface Modules for Real-time Systems

Negations in Refinement Type Systems

Monitoring Interfaces for Faults

Chapter 3: Propositional Languages

Model Checking. Automatic Verification Model Checking. Process A Process B. when not possible (not AI).

Design and Analysis of Distributed Interacting Systems

junit RV Adding Runtime Verification to junit

Course Modelling of Concurrent Systems Summer Semester 2016 University of Duisburg-Essen

To be or not programmable Dimitri Papadimitriou, Bernard Sales Alcatel-Lucent April 2013 COPYRIGHT 2011 ALCATEL-LUCENT. ALL RIGHTS RESERVED.

Distributed Systems Programming (F21DS1) SPIN: Formal Analysis I

NuSMV 2.2 Tutorial. Roberto Cavada, Alessandro Cimatti, Gavin Keighren, Emanuele Olivetti, Marco Pistore and Marco Roveri

Checking General Safety Criteria on UML Statecharts

Tutorial on Model Checking Modelling and Verification in Computer Science

Lectures 20, 21: Axiomatic Semantics

Temporal Logic of Actions (TLA) (a brief introduction) Shmuel Katz Computer Science Department The Technion

COS 598D: PATTERNS IN NETWORK ARCHITECTURE

RECENT advances in the development of portable devices

Promela and SPIN. Mads Dam Dept. Microelectronics and Information Technology Royal Institute of Technology, KTH. Promela and SPIN

Chapter 3 (part 3) Describing Syntax and Semantics

Property-based design with HORUS / SYNTHORUS

Lecture 2: Symbolic Model Checking With SAT

Verification of Bakery algorithm variants for two processes

TTM/PAT: Specifying and Verifying Timed Transition Models

4/6/2011. Model Checking. Encoding test specifications. Model Checking. Encoding test specifications. Model Checking CS 4271

Lecture 14: Recursive Types

SimGrid MC 101. Getting Started with the SimGrid Model-Checker. Da SimGrid Team. April 11, 2017

SPIN part 2. Verification with LTL. Jaime Ramos. Departamento de Matemática, Técnico, ULisboa

Model Checking Revision: Model Checking for Infinite Systems Revision: Traffic Light Controller (TLC) Revision: 1.12

Logic Model Checking

CS5232 Formal Specification and Design Techniques. Using PAT to verify the Needham-Schroeder Public Key Protocol

Verifiable Hierarchical Protocols with Network Invariants on Parametric Systems

Design and Analysis of Real-Time Systems Microarchitectural Analysis

CS558 Programming Languages

Research Collection. Formal background and algorithms. Other Conference Item. ETH Library. Author(s): Biere, Armin. Publication Date: 2001

How useful is the UML profile SPT without Semantics? 1

CS 510/13. Predicate Abstraction

Specifying and Executing Protocols for Cooperative Action

Formal Verification. Lecture 7: Introduction to Binary Decision Diagrams (BDDs)

Separating Product Variance and Domain Concepts in the Specification of Software Product Lines

Lecture 2: Intro to Concurrent Processing

Semantics. There is no single widely acceptable notation or formalism for describing semantics Operational Semantics

!"#$"%"& When can a UAV get smart with its operator, and say 'NO!'? Jerry Ding**, Jonathan Sprinkle*, Claire J. Tomlin**, S.

AN ABSTRACTION TECHNIQUE FOR REAL-TIME VERIFICATION

By: Chaitanya Settaluri Devendra Kalia

GUI for model checkers

Tracing the executions of concurrent programs

Algorithmic Verification. Algorithmic Verification. Model checking. Algorithmic verification. The software crisis (and hardware as well)

Overview of SRI s. Lee Pike. June 3, 2005 Overview of SRI s. Symbolic Analysis Laboratory (SAL) Lee Pike

Theorem proving. PVS theorem prover. Hoare style verification PVS. More on embeddings. What if. Abhik Roychoudhury CS 6214

Tool demonstration: Spin

Automatic Synthesis of a Voting Machine Design

20b -Advanced-DFA. J. L. Peterson, "Petri Nets," Computing Surveys, 9 (3), September 1977, pp

Page # 20b -Advanced-DFA. Reading assignment. State Propagation. GEN and KILL sets. Data Flow Analysis

Transcription:

Formal Methods in Software Engineering Lecture 07

What is Temporal Logic? Objective: We describe temporal aspects of formal methods to model and specify concurrent systems and verify their correctness properties. In concurrent reactive systems, correctness not only validates the correct input and output of the computational system, but also objectively monitors the execution of the system. Temporal logic is explicitly developed to treat these aspects and to monitor infinite behavior of reactive systems.,

What is Temporal Logic? Temporal logics have played vital role in formal verification wherever needed to state the specification requirements for hardware and software systems. Time: It represents the set of rules for reasoning in terms of time and the time domain is expressed in terms of state. A present time corresponds to current state and next moment of time corresponds to the immediate next state. Alternatively, system behavior is observed in terms of discrete time points such as 0, 1, 2,.., n.

What is Temporal Logic? Transition: Transition corresponds to the progressions from current time step to the next time step with specific action. Temporal logic is applicable due to its behavioral aspects of hardware and software in terms of time. Reasoning in the temporal logic is much easier with the translation into the predicate calculus because relationship among time is implicit manner.

Temporal Logic Operators Temporal logic has introduced some additional operators that represent the time variable and reflect their relationships. In essence, temporal logic is an extension of propositional logic. It is also known as propositional temporal logic (PTL). With the set of temporal operators, these enable the definition of formulas with the accessibility relation. When defining temporal properties, some temporal operators are needed to model the system in terms of time.

Temporal Logic Operators These operators include F ----- Future or eventually G ---- Globally X ------ Next U ------ Unitl The first three operators are unary whereas the last one is binary

Computational Paths, System run Define in terms of states and transitions A sequence of states, starting with an initial state s 0 s 1 s 2 such that R(s i, s i+1 ) is true Also called run, or (computation) path Trace: sequence of observable parts of states Sequence of state labels

Core Properties of Temporal Logic Safety property means something bad must not happen. E.g.: system should not crash. Liveness property means something good must happen. E.g.: every packet sent must be received at its destination Guarantee of Service states that if one process sends a request, it must have to be responded by other process. Mutually exclusion occur when two processes execute concurrently at the same critical section. Then, it is prescribed as bad thing.

Temporal Logic Operators

Temporal Logic Operators Globally (Always) p: G p G p is true for a computation path if p holds at all states (points of time) along the path

Temporal Logic Operators Eventually p: F p F p is true for a path if p holds at some state along that path

Temporal Logic Operators Next p: X p X p is true along a path starting in state s i (suffix of the main path) if p holds in the next state s i+1

Temporal Logic Operators Examples: What do they mean? G F p F G p G( p F q ) F( p (X X q) )

Temporal Logic Operators p Until q: p U q p U q is true along a path starting at s if q is true in some state reachable from s p is true in all states from s until q holds

Temporal Logic Types There are two types of temporal logics, each having their own temporal operators. In linear time temporal logic, there is a single successor state at each moment of time Branching time temporal logic, time is split into different alternative paths.

Temporal Logic Models Linear Time Temporal Logic Branching time temporal logic

Linear Time Temporal Logic (LTL) Linear Temporal Logic has been proposed as a formal verification tool by Amir Pnueli. LTL models time as a sequence of states and the future state is seen as a path in LTL. Accordingly, there are different future paths from where any path is taken as an actual path. There are many LTL model checking tools available which use LTL as a property specification language

LTL Syntax

LTL Semantics

LTL Semantics The semantics is defined by induction on the structure of ⱷ, is given as:

Thanks