Behavioral Equivalence Hossein Hojjat Formal Lab University of Tehran.

Slides:



Advertisements
Similar presentations
Process Algebra Book: Chapter 8. The Main Issue Q: When are two models equivalent? A: When they satisfy different properties. Q: Does this mean that the.
Advertisements

Process Algebra (2IF45) Abstraction in Process Algebra Suzana Andova.
Giving a formal meaning to “Specialization” In these note we try to give a formal meaning to specifications, implementations, their comparisons. We define.
1.6 Behavioral Equivalence. 2 Two very important concepts in the study and analysis of programs –Equivalence between programs –Congruence between statements.
1 1 CDT314 FABER Formal Languages, Automata and Models of Computation Lecture 3 School of Innovation, Design and Engineering Mälardalen University 2012.
Determinization of Büchi Automata
4/25/20151 Metodi formali nello sviluppo software a.a.2013/2014 Prof.Anna Labella.
Complexity 18-1 Complexity Andrei Bulatov Probabilistic Algorithms.
1 Introduction to Computability Theory Lecture3: Regular Expressions Prof. Amos Israeli.
A Semantic Characterization of Unbounded-Nondeterministic Abstract State Machines Andreas Glausch and Wolfgang Reisig 1.
1 Introduction to Computability Theory Lecture4: Regular Expressions Prof. Amos Israeli.
1 Introduction to Computability Theory Lecture11: Variants of Turing Machines Prof. Amos Israeli.
Introduction to Computability Theory
Finite Automata and Non Determinism
EECS 20 Lecture 15 (February 21, 2001) Tom Henzinger Simulation.
1 Synchronization strategies for global computing models Ivan Lanese Computer Science Department University of Bologna.
Regular Languages Sequential Machine Theory Prof. K. J. Hintz Department of Electrical and Computer Engineering Lecture 3 Comments, additions and modifications.
EECS 20 Lecture 16 (February 26, 2001) Tom Henzinger Determinization.
CSC 3130: Automata theory and formal languages Andrej Bogdanov The Chinese University of Hong Kong Regular.
1 Ivan Lanese Computer Science Department University of Bologna Italy Behavioural Theory for SSCC Joint work with Luis Cruz-Filipe, Francisco Martins,
Bridging the gap between Interaction- and Process-Oriented Choreographies Talk by Ivan Lanese Joint work with Claudio Guidi, Fabrizio Montesi and Gianluigi.
07/06/98 知的インタフェース特論 1 Operational Semantics Again, the question? Operational Model = Labeled Transition System If P and Q yields a same LTS. How to define.
CSC 3130: Automata theory and formal languages Andrej Bogdanov The Chinese University of Hong Kong Nondeterminism.
CS5371 Theory of Computation Lecture 6: Automata Theory IV (Regular Expression = NFA = DFA)
Bridging the gap between Interaction- and Process-Oriented Choreographies Talk by Ivan Lanese Joint work with Claudio Guidi, Fabrizio Montesi and Gianluigi.
1 Ivan Lanese Computer Science Department University of Bologna Italy Concurrent and located synchronizations in π-calculus.
CS5371 Theory of Computation Lecture 8: Automata Theory VI (PDA, PDA = CFG)
EECS 20 Chapter 3 Sections State Machines Continued Last time we Introduced the deterministic finite state machine Discussed the concept of state.
Model Checking LTL over (discrete time) Controllable Linear System is Decidable P. Tabuada and G. J. Pappas Michael, Roozbeh Ph.D. Course November 2005.
Introduction to CS Theory Lecture 3 – Regular Languages Piotr Faliszewski
Advanced Topics in SE Spring Process Algebra Hossein Hojjat Formal Methods Lab University of Tehran.
Communication and Concurrency: CCS
Reactive systems – general
2G1516 Formal Methods2005 Mads Dam IMIT, KTH 1 CCS: Operational Semantics And Process Algebra Mads Dam Reading: Peled 8.3, 8.4, 8.6 – rest of ch. 8.
Process Algebra Calculus of Communicating Systems Daniel Choi Provable Software Lab. KAIST.
11/19/20151 Metodi formali nello sviluppo software a.a.2013/2014 Prof.Anna Labella.
Laws of concurrent design Tony Hoare Microsoft ResearchCambridge FMCAD October.
Recognising Languages We will tackle the problem of defining languages by considering how we could recognise them. Problem: Is there a method of recognising.
MPRI 3 Dec 2007Catuscia Palamidessi 1 Why Probability and Nondeterminism? Concurrency Theory Nondeterminism –Scheduling within parallel composition –Unknown.
CS 5204 Spring 99 1 A Simple Agent A CCS agent is described both by a structural diagram and one or more algebraic equations. The diagram is for readability.
MPRI – Course on Concurrency Lectures 11 and 12 The pi-calculus expressiveness hierarchy Catuscia Palamidessi INRIA Futurs and LIX
Lecture # 12. Nondeterministic Finite Automaton (NFA) Definition: An NFA is a TG with a unique start state and a property of having single letter as label.
LDK R Logics for Data and Knowledge Representation ClassL (part 2): Reasoning with a TBox 1.
2G1516 Formal Methods2005 Mads Dam IMIT, KTH 1 CCS: Processes and Equivalences Mads Dam Reading: Peled 8.5.
2G1516/2G1521 Formal Methods2004 Mads Dam IMIT, KTH 1 CCS: Processes and Equivalences Mads Dam Reading: Peled 8.1, 8.2, 8.5.
Recognising Languages We will tackle the problem of defining languages by considering how we could recognise them. Problem: Is there a method of recognising.
Foundations of (Theoretical) Computer Science Chapter 2 Lecture Notes (Section 2.2: Pushdown Automata) Prof. Karen Daniels, Fall 2010 with acknowledgement.
Concurrency 5 The theory of CCS Specifications and Verification Expressive Power Catuscia Palamidessi
On the origins of Bisimulation & Coinduction
Process Algebra (2IF45) Abstraction Parallel composition (short intro) Suzana Andova.
1 Turing Machines and Equivalent Models Section 13.1 Turing Machines.
FORMAL LANGUAGES, AUTOMATA AND COMPUTABILITY TexPoint fonts used in EMF. Read the TexPoint manual before you delete this box.: AA.
Nondeterministic Finite Automata (NFAs). Reminder: Deterministic Finite Automata (DFA) q For every state q in Q and every character  in , one and only.
Process Algebra (2IF45) Basic Process Algebra Dr. Suzana Andova.
Regular Languages Chapter 1 Giorgi Japaridze Theory of Computability.
Laurea Triennale in Informatica – Corso di Ingegneria del Software I – A.A. 2006/2007 Andrea Polini VII. System Specification (I)
Probabilistic Algorithms
CSC 4170 Theory of Computation Nondeterminism Section 1.2.
CAP 4800/CAP 5805: Computer Simulation Concepts
CAP 4800/CAP 5805: Computer Simulation Concepts
Internet of Things A Process Calculus Approach
Non-Deterministic Finite Automata
Formal Methods in software development
Logics for Data and Knowledge Representation
Formal Methods in software development
Instructor: Aaron Roth
Formal Methods in software development
CAP 4800/CAP 5805: Computer Simulation Concepts
CSC 4170 Theory of Computation Nondeterminism Section 1.2.
Presentation transcript:

Behavioral Equivalence Hossein Hojjat Formal Lab University of Tehran

Equivalence A concurrent system shouldn’t just be a single model (Petri net, process expression,…) Instead it is represented by an equivalence class of such objects The models give a representation that isn’t abstract enough For this purpose many equivalence notions have been proposed in the literature

Implementation Correctness Often equivalence relations are used to establish the correctness of implementations with respect to specifications of concurrent systems Suppose that P represents a specification Q represents an implementation P ~ Q states that the implementation is correct ~

Equivalence Notions Many different equivalence notions have been proposed in the literature Which aspects of system are crucial and which of them can be avoided We shall introduce bisimulation equivalence, which is an important semantic equivalence over CCS processes

Vending machine Consider a tea/coffee vending machine A = coin. (tea.A + coin.coffee.A) coin coffee tea A B C

Non-det vending machine Now consider a non deterministic vending machine A’ = coin. (tea.A’ + coin.coffee.A’) + coin.tea.A’ coin coffee tea B’ C’ A’ B0’B0’ tea coin

Equivalence coin coffee tea A B C coin coffee tea B’ C’ A’ B0’B0’ tea coin These two systems are language equivalent (why?)

Equivalence coin coffee tea A B C coin coffee tea B’ C’ A’ B0’B0’ tea coin These two systems are language equivalent (why?) But the machines are different When we supply a coin to the second machine, it can non- deterministically go to a state as before, or to a state that we can only obtain tea!

What’s wrong? The reactive behavior of the system is changed If every input and output seen as an interaction with the environment, they are not equivalent We need a different notion of equivalency

Strong simulation A Relation R on the states of an LTS is a strong simulation if p R q implies if p p’ then there exists q’ such that q q’ and p’ R q’ If such a relation exists, we say Q strongly simulates P α α pq p’q’ R R α α

Strong simulation in vending machine coin coffee tea A B C coin coffee tea B’ C’ A’ B0’B0’ tea coin We claim that the first system strongly simulates the second A’ R A B’ R B B 0 ’ R B C’ R C

Proof- Step1 coin coffee tea A B C coin coffee tea C’ A’ B0’B0’ tea coin B’ coin

Proof- Step2 coin coffee tea A B C coin coffee tea C’ A’ B0’B0’ tea coin B’ coin

Proof- Step3 coin coffee tea A B C coin coffee tea C’ A’ B0’B0’ tea coin B’ tea

Proof- Step4 coin coffee tea A B C coin coffee tea A’ B0’B0’ tea coin B’ C’ coin

Proof- Step5 coin coffee tea A B C coin coffee tea C’ A’ B0’B0’ tea coin B’ tea

Proof- Step6 coin coffee tea A B coin coffee tea A’ B0’B0’ tea coin B’ C’ C coffee

The opposite direction The second system also strongly simulates the first one A R A’ B R B’ C R C’ Intuitively it is correct Thee second machine can simulate every step the first machine can take

Problem It seems that we have defeated our original purpose The two machines should not be observationally equivalent But each one can strongly simulates the other We need a new idea

Strong bisimulation In 1981 David Park proposed a new approach to define the equivalence of automatons: bisimulation Strong Bisimulation: There is a single relation that both the relation and its converse are strong simulation Under this definition the two vending machines are not equivalent

Exercise Prove that these systems are bisimilar: A = a.A B = a.B + a.a.B def

τedges The original definition of bisimulation holds in LTS without τ Milner introduced a new kind of bisimulation Weak bisimulation equivalence It permits arbitrary sequences of τsteps to precede or follow corresponding atomic actions

Definition We define P P’ iff P … P’ τ*τ* τ τ P P’ iff P P 1 P 2 P’ τ*λ τ* τ*τ* λ τ*τ*

Weak simulation We say R is a weak simulation if the following two satisfied: 1. If P R Q and P P’ then there exists a Q’ such that Q Q’ and P’ R Q’ 2. If P R Q and P P’ then there exists a Q’ such that Q Q’ and P’ R Q’ P and Q are weakly bisimilar if there is a relation R such that both R and inverse are weak bisimulation τ τ*τ* λ τ*λ τ*

Weak simulation- graphically pq p’q’ R R τ pq p’q’ R R λ τ*λτ*τ*λτ* τ*τ*