Download presentation

Presentation is loading. Please wait.

Published byEmilie Loud Modified about 1 year ago

1
Process Algebra (2IF45) Abstraction in Process Algebra Suzana Andova

2
1 Outline of the lecture Our way of dealing with internal behaviour: branching bisimulation How we capture Abstraction in Process Algebra combining it with other concepts Process Algebra (2IF45)

3
2 Abstraction Abstraction is used to check the correctness of implementation against the system specification reduce and simplify the model to enable better, fasted and cleaner model analysis Process Algebra (2IF45) Question: How do we chose to relate behaviours with internal steps? Branching bisimulation

4
3 Process Algebra (2IF45) Branching bisimulation – simple examples first a b is branching bisim to a a b “ related states must have the same potential which does not change until an observable action is executed ”

5
4 Process Algebra (2IF45) Branching bisimulation – simple examples first a b is branching bisim to a b it is not branching bisim to a b

6
5 Branching bisimilar processes t t’ a s a s’ t’’ t s s’ t’’ t s s’ t Branching Bisimulation relation: A binary relation R on the set of state S of an LTS is branching bisimulation relation iff the following transfer conditions hold: 1.for all states s, t, s’ S, whenever (s, t) R and s → s’ for some a A, then there are states t’, t’’ S such that t t’ and t’ → t’’ and (s, t’), (s’,t’’) R; 2. vice versa, for all states s, t, s’ S, whenever (s, t) R and t → t’ for some a A, then there are states s’,s’’ S such that s s’ and s’ → s’’ and (s’, t), (s’’,t’) R; 3. if (s, t) R and s then there is a state t’ such that t t’, t’ and (s, t’) R 4. whenever (s, t) R and t then there is a state s’ such that s s’, s’ and (s’, t) R Two LTSs s and t are branching bisimilar, s b t, iff there is a branching bisimulation relation R such that (s, t) R a a a a

7
6 less more power of the observer Spectrum of behavioural relations

8
7 most powerful

9
8 Weak bisimulation just a short comparison Process Algebra (2IF45) a b c d1 d2 d3 d4 a b c d1 d2 d3 d4 b a b c d1 d2 d3 d4 b

10
9 Branching bisimulation and composition

11
10 Branching bisimulation and composition a a a a b b b branching bisimilar! branching bisimilar ? NO! + +

12
11 Branching bisimulation and composition a a a a b b b branching bisimilar! branching bisimilar ? NO! + + Painful conclusion: branching bisimilation is not compositional.

13
12 Branching bisimulation and composition a a a a b b branching bisimilar components! + + What to do? Two choices: 1.Make the relation weaker and relate the two compositions too! 2.Make the relation stronger and do not relate the two components from the beginning! Not branching bisimilar compositions!

14
13 Rooted Branching Bisimilar processes t’ q b s’ b p r t’ s’ p q t p t’ t s a a t s a a t s a a R is Rooted BB between state (s, t) R if R is Branching Bisimulation relation (as already defined) and the root condition: 1.if s → s’ for a A, then there is a state t’ S such that t → t’ and (s’, t’) R; 2.if t → t’ for a A, then there is a state s’ S such that s → s’ and (s’, t’) R; 3.s if and only if t LTSs s and t are rooted branching bisimilar, s rb t, iff there is a rooted branching bisimulation relation R such that (s, t) R a a a Rooted branching bisimulation is strengthened variant of branching bisimulation strict enough to obtain compositionality a (a A i.e. can be from A or can be )

15
14 Process Algebra (2IF45) Axiomatizing Rooted Branching Bisimulations Language: BPA (A) Signature: 0, 1, (a._ ) a A, , +, Language terms T(BPA (A,)) Closed terms C(BPA (A)) Equality of terms x+ y = y+x (x+y) + z = x+ (y + z) x + x = x x+ 0 = x (x+ y) z = x z+y z (x y) z = x (y z) 0 x = 0 x 1 = x 1 x = x a.x y = a.(x y) Completeness Soundness Deduction rules for BPA (A) (a A ): x x’ x + y x’ a a 11 x (x + y) a.x x a y y’ x + y y’ a a y (x + y) ⑥ x x’ x y x’ a a x y (x y) x y y’ x y y’ a a Strong Bisimilarity on LTSs

16
15 Process Algebra (2IF45) Axiomatizing Rooted Branching Bisimulations Language: BPA (A) Signature: 0, 1, (a._ ) a A, , +, Language terms T(BPA (A,)) Closed terms C(BPA (A)) Strong Bisimilarity on LTSs Equality of terms x+ y = y+x (x+y) + z = x+ (y + z) x + x = x x+ 0 = x (x+ y) z = x z+y z (x y) z = x (y z) 0 x = 0 x 1 = x 1 x = x a.x y = a.(x y) Completeness Soundness Deduction rules for BPA (A) (a A ): x x’ x + y x’ a a 11 x (x + y) a.x x a y y’ x + y y’ a a y (x + y) ⑥ x x’ x y x’ y a a x y (x y) x y y’ x y y’ a a Rooted Branching

17
16 x y x + + x y + .(x+y) + x = x+y Turned into equation looks like: Axiomazing Rooted branching bisimulation bb

18
17 a x y x + + … a x y + … rb B axiom a.( .(x+y) + x) = a.(x+y) Axiomazing Rooted branching bisimulation bb Turned into equation looks like:

19
18 Process Algebra (2IF45) Axiomatizing Rooted Branching Bisimulations Language: BPA (A) Signature: 0, 1, (a._ ) a A, , +, Language terms T(BPA (A,)) Closed terms C(BPA (A)) Strong Bisimilarity on LTSs Equality of terms x+ y = y+x (x+y) + z = x+ (y + z) x + x = x x+ 0 = x (x+ y) z = x z+y z (x y) z = x (y z) 0 x = 0 x 1 = x 1 x = x a.x y = a.(x y) a.( .(x+y) + x) = a.(x+y) Completeness Soundness Deduction rules for BPA (A) (a A ): x x’ x + y x’ a a 11 x (x + y) a.x x a y y’ x + y y’ a a y (x + y) ⑥ x x’ x y x’ y a a x y (x y) x y y’ x y y’ a a Rooted Branching

20
19 Home work Prove soundness of B axiom wrt rooted BB Read the proof of ground completeness Process Algebra (2IF45)

21
20 Process Algebra (2IF45) Combining internal step with other operators Language: BPA (A) Signature: 0, 1, (a._ ) a A, , +, Language terms T(BPA (A,)) Closed terms C(BPA (A)) Axioms Deduction rules

22
21 Process Algebra (2IF45) Combining internal step with other operators: Hiding operator Language: BPA (A) Signature: 0, 1, (a._ ) a A, , +,, I (I A) Language terms T(BPA (A,)) Closed terms C(BPA (A)) Axioms for I Deduction rules for I turns external actions into internal steps

23
22 Process Algebra (2IF45) Combining internal step with other operators: Encapsulation operator Language with Signature: 0, 1, (a._ ) a A, , +, H (H A) blocks actions

24
23 Process Algebra (2IF45) Combining internal step with other operators: Parallel composition and communication Language: TCP (A) Signature : 0, 1, (a._ ) a A, , +,, I (I A), ||, |, ╙, H, Language terms T(BPA (A, )) Closed terms C(BPA (A, )) Axioms for parallel composition with silent step: x ╙ .y = x ╙ y x | .y = 0

25
24 Exercises see distributed copies Process Algebra (2IF45)

26
25 Abstraction, silent steps and Recursion Guardedness and silent steps: cannot be a guard of a variable X = . X has solutions . . a.1 but also . . b.1 Guardedness and hiding operator: I cannot appear in t X in X = t X X = i. I (X), where i I has solutions i.i. a.1 but also i. i. b.1 Process Algebra (2IF45)

27
26 Abstraction and Recursion and Fairness Process Algebra (2IF45) X Y a 0 Z U a 0 Observation: 1.they are rooted bb bisimilar 2.implicitly internal loop is left eventually = fairness

28
27 Abstraction and Recursion and Fairness Process Algebra (2IF45) X Y a 0 X = .Y Y = .Y + a.0 Z U a 0 Z = .U U = a.0 RSP+RDP ? X = Z Observation on LTSs: 1.they are rooted bb bisimilar 2.implicitly internal loop is left eventually = fairness As recursive specifications:

29
28 Abstraction and Recursion and Fairness Process Algebra (2IF45) X Y a 0 X = .Y Y = .Y + a.0 Z U a 0 Z = .U U = a.0 RSP+RDP ? X = Z At least two problems: 1.Those are not guarder recursive specifications! 2.Even if they are somehow made guarded, B axiom is not sufficient to rewrite one spec into another Observation on LTSs: 1.they are rooted bb bisimilar 2.implicitly internal loop is left eventually = fairness As recursive specifications:

30
29 Process Algebra (2IF45) X = .Y Y = .Y + a.0 X’ = i.Y’ Y’ = i.Y’ + a.0 for some action i to be turned internal “soon” by applying I for I = {i} represents X Y a 0 X’ Y’ i a 0 i applying {i} Abstraction and Recursion and Fairness: problem 1. dealing with guardedness

31
30 Process Algebra (2IF45) Z = .U U = a.0 Z’ = i.U’ U’ = a.0 Z’ U’ i a 0 Z U 0 applying {i} a Abstraction and Recursion and Fairness: problem 1. dealing with guardedness X = .Y Y = .Y + a.0 X’ = i.Y’ Y’ = i.Y’ + a.0 for some action i to be turned internal “soon” by applying I for I = {i} represents X Y a 0 X’ Y’ i a 0 i applying {i} represents

32
31 Process Algebra (2IF45) Z = .U U = a.0 Z’ = i.U’ U’ = a.0 Z’ U’ i a 0 applying {i} Z U 0 a Abstraction and Recursion and Fairness: problem 1. dealing with guardedness X = .Y Y = .Y + a.0 X’ = i.Y’ Y’ = i.Y’ + a.0 for some action i to be turned internal “soon” by applying I for I = {i} represents X Y a 0 X’ Y’ i a 0 i applying {i} represents OK! How to connect them ?

33
32 Process Algebra (2IF45) X’ = i.Y’ Y’ = i.Y’ + a.0 Something like this shall help: Y’ = i.Y’ + a.0 . I (Y’) = . I (a.0) Abstraction and Recursion and Fairness: problem 2. derivation rules We want to derive that I (X’) = I (Z’)! We need new rules for this!

34
33 Process Algebra (2IF45) a bit more general rule: x 1 = i 1.x 1 + y 1, i 1 I . I (x 1 ) = . I (y 1 ) Abstraction and Recursion and Fairness: Fairness rule KFAR 1 b

35
34 Process Algebra (2IF45) General KFAR rule is: x 1 = i 1.x 2 + y 1, x 2 = i 2.x 3 + y 2, … x n = i n.x 1 + y n, i 1, … i n I, there is i k . I (x 1 ) = . ( I (y 1 ) + … + I (y n )) Abstraction and Recursion and Fairness: Fairness rule KFAR n b

36
35 Process Algebra (2IF45) Abstraction and Recursion and Fairness: Example of tossing a coin

37
36 Home Work (part2) Study the Coin tossing example Study the complete proof for ABP, derivation up to abstraction and derivation by means of fairness derivation rules. Process Algebra (2IF45)

Similar presentations

© 2016 SlidePlayer.com Inc.

All rights reserved.

Ads by Google