Process Algebra (2IF45) Probabilistic Process Algebra Suzana Andova.

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) Some Extensions of Basic Process Algebra Dr. Suzana Andova.
Process Algebra (2IF45) Recursion in Process Algebra Suzana Andova
Process Algebra (2IF45) Abstraction in Process Algebra Suzana Andova.
Complexity and Computability Theory I Lecture #4 Rina Zviel-Girshin Leah Epstein Winter
8/27/2009 Sofya Raskhodnikova Intro to Theory of Computation L ECTURE 2 Theory of Computation Finite Automata Operations on languages Nondeterminism L2.1.
Process Algebra (2IF45) Abstraction and Recursions in Process Algebra Suzana Andova.
Process Algebra (2IF45) Probabilistic Process Algebra Suzana Andova.
Process Algebra (2IF45) Dr. Suzana Andova. 1 Process Algebra (2IF45) Practical issues Lecturer - Suzana Andova - Group: Software Engineering and Technology.
Process Algebra (2IF45) Probabilistic extension: semantics Parallel composition Dr. Suzana Andova.
Luca de Alfaro Thomas A. Henzinger Ranjit Jhala UC Berkeley Compositional Methods for Probabilistic Systems.
NFAs Sipser 1.2 (pages 47–54). CS 311 Fall Recall… Last time we showed that the class of regular languages is closed under: –Complement –Union.
1 Introduction to Computability Theory Lecture2: Non Deterministic Finite Automata Prof. Amos Israeli.
NFAs Sipser 1.2 (pages 47–54). CS 311 Mount Holyoke College 2 Recall… Last time we showed that the class of regular languages is closed under: –Complement.
CS5371 Theory of Computation
8 May 2008IPA Lentedagen Dynamic Consistency in Process Algebra: From Paradigm to ACP Suzana Andova (FM TU/e) Luuk Groenewegen (LIACS Leiden Univ.) Erik.
A testing scenario for probabilistic automata Marielle Stoelinga UC Santa Cruz Frits Vaandrager University of Nijmegen.
1 Operational Semantics Mooly Sagiv Tel Aviv University Textbook: Semantics with Applications.
Lecture 3 Goals: Formal definition of NFA, acceptance of a string by an NFA, computation tree associated with a string. Algorithm to convert an NFA to.
Branching Bisimulation Congruence for Probabilistic Transition Systems
Lecture 3 Goals: Formal definition of NFA, acceptance of a string by an NFA, computation tree associated with a string. Algorithm to convert an NFA to.
Review of the automata-theoretic approach to model-checking.
Semantics with Applications Mooly Sagiv Schrirber html:// Textbooks:Winskel The.
CS5371 Theory of Computation Lecture 4: Automata Theory II (DFA = NFA, Regular Language)
Real-Time Systems Group University of Pennsylvania 5/24/2001 Resource-bound family of real-time process algebras Oleg Sokolsky, Insup Lee Real-Time Systems.
Operational Semantics Semantics with Applications Chapter 2 H. Nielson and F. Nielson
Introduction to Finite Automata Adapted from the slides of Stanford CS154.
Regular Expressions and Automata Chapter 2. Regular Expressions Standard notation for characterizing text sequences Used in all kinds of text processing.
Algebraic Properties: The Rules of Algebra Be Cool - Follow The Rules!
Process Algebra (2IF45) Basic Process Algebra (Soundness proof) Dr. Suzana Andova.
Boolean Algebra Dr. Bernard Chen Ph.D. University of Central Arkansas Spring 2009.
Jun. Sun Singapore University of Technology and Design Songzheng Song and Yang Liu National University of Singapore.
Process Algebra (2IF45) Probabilistic Branching Bisimulation: Exercises Dr. Suzana Andova.
Benjamin Gamble. What is Time?  Can mean many different things to a computer Dynamic Equation Variable System State 2.
Theory of Languages and Automata
Some Probability Theory and Computational models A short overview.
SDS Foil no 1 Process Algebra Process Algebra – calculating with behaviours.
Mathematical Operational Semantics and Finitary System Behaviour Stefan Milius, Marcello Bonsangue, Robert Myers, Jurriaan Rot.
Reactive systems – general
CS5270 Lecture 41 Timed Automata I CS 5270 Lecture 4.
Formal Methods for Software Engineering Part II: Modelling & Analysis of System Behaviour.
MPRI 3 Dec 2007Catuscia Palamidessi 1 Why Probability and Nondeterminism? Concurrency Theory Nondeterminism –Scheduling within parallel composition –Unknown.
Lecture 5 1 CSP tools for verification of Sec Prot Overview of the lecture The Casper interface Refinement checking and FDR Model checking Theorem proving.
Representing Relations Using Matrices A relation between finite sets can be represented using a zero-one matrix Suppose R is a relation from A = {a 1,
2G1516 Formal Methods2005 Mads Dam IMIT, KTH 1 CCS: Processes and Equivalences Mads Dam Reading: Peled 8.5.
Process Algebra (2IF45) Basic Process Algebra (Completeness proof) Dr. Suzana Andova.
UW CSE 503 ▪ Software Engineering ▪ Spring 2004 ▪ Rob DeLine1 CSE 503 – Software Engineering Lecture 3: An introduction to Alloy Rob DeLine 5 Apr 2004.
Compositional Formal Verification using MOCHA PI: Tom Henzinger Student 1: Freddy Mang (game-theoretic methods) Student 2: Ranjit Jhala (probabilistic.
Operational Semantics Mooly Sagiv Tel Aviv University Textbook: Semantics with Applications Chapter.
Process Algebra (2IF45) Abstraction Parallel composition (short intro) Suzana Andova.
Process Algebra (2IF45) Analysing Probabilistic systems Dr. Suzana Andova.
Nondeterministic Finite Automata (NFAs). Reminder: Deterministic Finite Automata (DFA) q For every state q in Q and every character  in , one and only.
Operational Semantics Mooly Sagiv Tel Aviv University Sunday Scrieber 8 Monday Schrieber.
Process Algebra (2IF45) Basic Process Algebra Dr. Suzana Andova.
Operational Semantics Mooly Sagiv Reference: Semantics with Applications Chapter 2 H. Nielson and F. Nielson
CS5270 Lecture 41 Timed Automata I CS 5270 Lecture 4.
Krishnendu ChatterjeeFormal Methods Class1 MARKOV CHAINS.
1/29/02CSE460 - MSU1 Nondeterminism-NFA Section 4.1 of Martin Textbook CSE460 – Computability & Formal Language Theory Comp. Science & Engineering Michigan.
Theory of Computation Automata Theory Dr. Ayman Srour.
Formal Methods for Software Engineering
Formal methods: Lecture
Prof. Dr. Holger Schlingloff 1,2 Dr. Esteban Pavese 1
Process Algebra (2IF45) Extending Process Algebra: Abstraction
Process Algebra (2IF45) Expressiveness of BPArec
COSC 3340: Introduction to Theory of Computation
First-order (predicate) Logic
Instructor: Aaron Roth
Chapter 1 Regular Language
Instructor: Aaron Roth
Lexical Analysis Uses formalism of Regular Languages
Presentation transcript:

Process Algebra (2IF45) Probabilistic Process Algebra Suzana Andova

1 Outline of the lecture Semantics of non-determinism in probabilistic setting Analysing probabilistic systems and schedulers Probabilistic branching bisimulation Process Algebra (2IF45)

2 PBPA(A) Probabilistic Basic Process Algebra Language: PBPA(A) Signature: 0, (a._ ) a  A, +, ⊕ , where   (0,1) Language terms T(PBPA(A)) Axioms of PBPA(A): (A1) x+ y = y+x (A2) (x+y) + z = x+ (y + z) (A3) x + x = x (A4) x+ 0 = x x  x’ x + y  x’ a a  11  x  (x + y)   a.x  x  a  y  y’ x + y  y’ a a y  (x + y)  ⑥ Strong Probabilistic Bisimilarity on PLTSs Equality of terms Deduction rules for PBPA(A): x  x’ x   y  x’ a.x  a.x  1 y  y’ x   y  y’ (1-  )  x  x’, y  y’ x +y  x’ + y’      a.x  x a x  x’ x + y  x’ y  y’ x + y  y’ a a a a

3 1/2 a b + = 1/3 c d 2/3 1/3 ab 1/6 a 1/3 d c c d b SOS rules for PBPA(A): non-deterministic choice x  x’, y  y’ x +y  x’ + y’    Deduction rule

4 1/3 a b 2/3 + = 1/3 a b 2/3 2/9 ab 1/9 a 4/9 b a a b b Non-deterministic choice: idempotence? ? p 1/3 a b 2/3 4/9 a 1/9 a 4/9 b a b b

5 Process Algebra (2IF45) Axioms of PBPA(A) (A1) x+ y = y+x (A2) (x+y) + z = x+ (y + z) (A3) x + x = x but (AA3) a.x+a.x = a.x (A4) x+ 0 = x (PA1) x   y = y  1-  x (PA2) x   (y   z) = (x   y)  z where  =  /(  +  -  ) and =  +  -  (PA3) x   x = x (PA4) (x   y) + z = (x + z)   (y + z)

6 Process Algebra (2IF45) PBPA(A) Probabilistic Basic Process Algebra Language: PBPA(A) Signature: 0, (a._ ) a  A, +, ⊕ , where   (0,1) Language terms T(PBPA(A)) x  x’ x + y  x’ a a  11  x  (x + y)   a.x  x  a  y  y’ x + y  y’ a a y  (x + y)  ⑥ Strong Probabilistic Bisimilarity on PLTSs Equality of terms Deduction rules for PBPA(A): x  x’ x   y  x’ a.x  a.x  1 y  y’ x   y  y’ (1-  )  x  x’, y  y’ x +y  x’ + y’      a.x  x a x  x’ x + y  x’ y  y’ x + y  y’ a a a a Axioms of PBPA(A): (A1) x+ y = y+x (A2) (x+y) + z = x+ (y + z) (AA3) a.x+a.x = a.x (A4) x+ 0 = x (PA1) x   y = y  1-  x (PA2) x   (y   z) = (x   y)  z where  =  /(  +  -  ) and =  +  -  (PA3) x   x = x (PA4) (x   y) + z = (x + z)   (y + z)

Process Algebra (2IF45) Analysing Probabilistic systems Dr. Suzana Andova

8 Analysing PLTSs – main ingredients Process Algebra (2IF45) What can we measure on x? The set of all paths in x starting in p?! n p ks 0 x

9 Analysing PLTSs – main ingredients Process Algebra (2IF45) n p ks 0 x Property1: After finitely many c’s, a is observed (Measured set = all paths with trace in c*a) Property2: After finitely many c’s, action b occurs (Measured set = all paths with trace in c*b) Property3: After an even number of c’s, action a occurs (Measured set = all paths with trace in (cc)*a) Property4: After an even number of c’s, action a or action b occurs Property5: Eventually deadlock is reached (state 0) (Measured set = all paths that have 0 as last state) What can we measure on x? The set of all paths in x starting in p?!

10 Example 1 (cont.) Process Algebra (2IF45) Property1: After finitely many c’s, a is observed n p ks 0 x p kss 0 p 1/3 1/2 1/6 a b c kss 0 p 1/2 1/6 a b c 1/

11 Example 1 (cont.) Process Algebra (2IF45) Property1: After finitely many c’s, a is observed n p ks 0 x p kss 0 p 1/3 1/2 1/6 a b c kss 0 p 1/2 1/6 a b c 1/

12 Example 1 (cont.) Process Algebra (2IF45) Property1: After finitely many c’s, a is observed n p ks 0 x p kss 0 p 1/3 1/2 1/6 a b c kss 0 p 1/2 1/6 a b c 1/ Prob(SetPaths1) = ?

13 Example 1 (cont.) Process Algebra (2IF45) Property1: After finitely many c’s, a is observed n p ks 0 x p kss 0 p 1/3 1/2 1/6 a b c kss 0 p 1/2 1/6 a b c 1/ Prob(SetPaths1) = 1/3 + 1/6x1/3 + (1/6)^2x1/3 + …. =  k  0 1/3x(1/6)^k = (1/3)/ (1-1/6) = 2/5

14 Example 1 (cont.) Process Algebra (2IF45) Property2: After finitely many c’s, b is observed n p ks 0 x p kss 0 p 1/3 1/2 1/6 a b c kss 0 p 1/2 1/6 a b c 1/ Prob(SetPaths2) = ?

15 Example 1 (cont.) Process Algebra (2IF45) Property3: After an even number of c’s, action a occurs n p ks 0 x p kss 0 p 1/3 1/2 1/6 a b c kss 0 p 1/2 1/6 a b c 1/ kss 0 p 1/2 1/6 a b c

16 Example 1 (cont.) Process Algebra (2IF45) n p ks 0 x p kss 0 p 1/3 1/2 1/6 a b c kss 0 p 1/2 1/6 a b c 1/ kss 0 p 1/2 1/6 a b c Prob(SetPaths3) = ? Property3: After an even number of c’s, action a occurs

17 Example 1 (cont.) Process Algebra (2IF45) n p ks 0 x Prob(SetPaths5) = ? Property1: After finitely many c’s, a is observed Property2: After finitely many c’s, action b occurs Property3: After even number of c’s, action a occurs Property4: After even number of c’s, action a or action b occurs Property5: Eventually deadlock is reached (state 0) (Measured set = ?)

18 Example 2 Process Algebra (2IF45) n p ks 0 y k p kss 0 p 1/3 1/2 1/6 a b c kss 0 p 1/2 1/6 a b c 1/ b b What can we measure on y? The set of all paths in y starting in p?!

19 Example 2 Process Algebra (2IF45) n p ks 0 y k p kss 0 p 1/3 1/2 1/6 a b c kss 0 p 1/2 1/6 a b c 1/ b b What can we measure on y? The set of all paths in y starting in p?! P roperty1: After finitely many c’s, a is observed

20 Example 2 Process Algebra (2IF45) n p ks 0 y k p kss 0 p 1/3 1/2 1/6 a b c kss 0 p 1/2 1/6 a b c 1/ b b What can we measure on y? The set of all paths in y starting in p?! P roperty1: After finitely many c’s, a is observed

21 Example 2 Process Algebra (2IF45) n p ks 0 y k p kss 0 p 1/3 1/2 1/6 a b c kss 0 p 1/2 1/6 a b c 1/ b b What can we measure on y? P roperty1: After finitely many c’s, a is observed Nothing, unless we resolve the non-determinism!

22 Example 2 Process Algebra (2IF45) n p ks 0 y k p kss 0 p 1/3 1/2 1/6 a b c kss 0 p 1/2 1/6 a b c 1/ b b What can we measure on y? P roperty1: After finitely many c’s, a is observed Nothing, unless we resolve the non-determinism! HOW? By schedulers!

23 Process Algebra (2IF45) Schedulers are used to resolve non-determinism A scheduler “decides” the next step to be performed from a given non- deterministic state It maps a finite path, ending in a non-deterministic state, to an action transition (many detail is missing in this sentence, read the lecture notes for the formal definition) Analysis of a system with non-determinism is relative to the chosen scheduler. Different types of schedulers: randomized vs. deterministic. Special kind of deterministic schedulers are simple schedulers. Schedulers

24 Example 2 (cont.) Process Algebra (2IF45) Property1: After finitely many c’s, a is observed? First select a scheduler, then compute this set, and its probability 1.Let us define a scheduler .

25 Example 2 (cont.) – scheduler  Process Algebra (2IF45) Computation tree CT y (p,  ) n p ks 0 y k p ksn 0 p 1/3 1/2 1/6 a c ksn 0 p 1/2 1/6 b c 1/

26 Example 2 (cont.) – scheduler  Process Algebra (2IF45) Prob  (FPaths(y, trace = c*a)) = 12/35 How? n p ks 0 y k Property1: After finitely many c’s, a is observed p ksn 0 p 1/3 1/2 1/6 a c ksn 0 p 1/2 1/6 b c 1/3....

27 Example 2 (cont.) – scheduler  1 Process Algebra (2IF45) n p ks 0 y k p kss 0 p 1/3 1/2 1/6 a c kss 0 p 1/2 1/6 a b c 1/ b Computation tree CT y (p,  1 )

28 Example 2 (cont.) – scheduler  1 Process Algebra (2IF45) n p ks 0 y k p kss 0 p 1/3 1/2 1/6 a c kss 0 p 1/2 1/6 a b c 1/3 b Property1: After finitely many c’s, a is observed Prob  1 (FPaths(y, trace = c*a) )= 2/5 How? Can we do better?

29 Example 2 (cont.) Process Algebra (2IF45) Property1: After finitely many c’s, a is observed? First select a scheduler, then compute this set, and its probability 1.1. Let us define a scheduler  1.2. Scheduler  1 is the maximal scheduler 1.3. Scheduler  2 is the minimal scheduler

Process Algebra (2IF45) Parallel composition of PLTSs

31 10 January 2008 SOS semantics of PTCP(A,  ) where a and c communicate in e, and no other communication is defined (in this examples) 1/3 a b 2/3 1/2 c d ||= 1/3 c b 1/6 a a c d bd e 1 a a ddb Deduction rules for probabilistic transitions  x  x’  H (x)   H (x’)   x  x’, y  y’ x || y  x’|| y’   x  x’, y  y’ x | y  x’ | y’    c 11 bc 111 1

32 Deduction rules for action transitions x  x’ x || y  x’ || y a a y  y’ x || y  x || y’ a a x  x’ y  y’,  (a,b) = c x || y  x’ || y’ a c b x  x’ y  y’,  (a,b) = c x | y  x’ || y’ a c b x  x’, a  H  H (x)   H (x’) a a SOS semantics of PTCP(A,  )

33 Process Algebra (2IF45) Axioms (not seen yet) of TCP(A,  ) x|| y = x ╙ y + y ╙ x + x | y, only if x=x+x and y=y+y x || (y   z) = (x || y)   (x || z) (x   y) || z = (x || z)   (y || z) x | (y   z) = (x | y)   (x | z) (x   y) | z = (x | z)   (y | z)  H (x   y) =  H (x)    H (y) x ╙ (y   z) = (x ╙ y)   (x ╙ z) (x   y) ╙ z = (x ╙ z)   (y ╙ z)