Measurable Stochastics for Brane Calculus Giorgio Bacci Marino - - PowerPoint PPT Presentation

measurable stochastics for brane calculus
SMART_READER_LITE
LIVE PREVIEW

Measurable Stochastics for Brane Calculus Giorgio Bacci Marino - - PowerPoint PPT Presentation

Measurable Stochastics for Brane Calculus Giorgio Bacci Marino Miculan Department of Mathematics and Computer Science University of Udine, Italy MeCBIC 2010 23rd August 2010, Jena 1 / 23 Stochastic process algebras The semantics of process


slide-1
SLIDE 1

Measurable Stochastics for Brane Calculus

Giorgio Bacci Marino Miculan

Department of Mathematics and Computer Science University of Udine, Italy

MeCBIC 2010

23rd August 2010, Jena

1 / 23

slide-2
SLIDE 2

Stochastic process algebras

The semantics of process algebras is classically described by means

  • f Labelled Transition Systems (LTSs)

P

a

− → Q

The semantics of stochastic process algebras is classically defined by means of Continuous Time Markov Chains (CTMCs)

P

a,r

− − − → Q

rate of an exponentially distributed random variable

2 / 23

slide-3
SLIDE 3

Problems with a point-wise stochastic semantics

Typically, process algebras are endowed with a structural equivalence relation ≡ equating processes with the same behaviour Example: modeling the parallel operator we expect no differences between Q|R, R|Q, and R|Q|0.

3 / 23

slide-4
SLIDE 4

Problems with a point-wise stochastic semantics

Typically, process algebras are endowed with a structural equivalence relation ≡ equating processes with the same behaviour Example: modeling the parallel operator we expect no differences between Q|R, R|Q, and R|Q|0. P

a,r

− → Q|R

3 / 23

slide-5
SLIDE 5

Problems with a point-wise stochastic semantics

Typically, process algebras are endowed with a structural equivalence relation ≡ equating processes with the same behaviour Example: modeling the parallel operator we expect no differences between Q|R, R|Q, and R|Q|0. P

a,r

− → Q|R P

a,r

− → R|Q

3 / 23

slide-6
SLIDE 6

Problems with a point-wise stochastic semantics

Typically, process algebras are endowed with a structural equivalence relation ≡ equating processes with the same behaviour Example: modeling the parallel operator we expect no differences between Q|R, R|Q, and R|Q|0. P

a,r

− → Q|R P

a,r

− → R|Q P

a,r

− → R|Q|0

3 / 23

slide-7
SLIDE 7

Problems with a point-wise stochastic semantics

Typically, process algebras are endowed with a structural equivalence relation ≡ equating processes with the same behaviour Example: modeling the parallel operator we expect no differences between Q|R, R|Q, and R|Q|0. P

a,r

− → Q|R P

a,r

− → R|Q P

a,r

− → R|Q|0

by additivity

P

a,3r

− − → {Q|R, R|Q, R|Q|0}

3 / 23

slide-8
SLIDE 8

A-Markov kernel

[Mardare-Cardelli‘10]

Mardare and Cardelli generalized the concept of CTMC to generic measurable spaces (M, Σ):

A-Markov kernel: (M, Σ, θ)

where

θ: A → M → ∆(M, Σ)

action label current state measure

  • n (M, Σ)

4 / 23

slide-9
SLIDE 9

A-Markov kernel

[Mardare-Cardelli‘10]

Mardare and Cardelli generalized the concept of CTMC to generic measurable spaces (M, Σ):

A-Markov kernel: (M, Σ, θ)

where

θ: A → M → ∆(M, Σ)

θ(α)(m) is a measure on (M, Σ)

action label current state measure

  • n (M, Σ)

4 / 23

slide-10
SLIDE 10

A-Markov kernel

[Mardare-Cardelli‘10]

Mardare and Cardelli generalized the concept of CTMC to generic measurable spaces (M, Σ):

A-Markov kernel: (M, Σ, θ)

where

θ: A → M → ∆(M, Σ)

θ(α)(m) is a measure on (M, Σ) θ(α)(m)(N) ∈ R+ is the rate of m α − → N

action label current state measure

  • n (M, Σ)

4 / 23

slide-11
SLIDE 11

Stochastic bisimulation

[Mardare-Cardelli‘10]

The definition of Markov kernel induces a new definition of stochastic bisimulation

Stochastic bisimulation:

A rate-bisimulation relation R ⊆ M × M is an equivalence relation such that for all α ∈ A and R-closed measurable sets C ∈ Σ.

(m, n) ∈ R iff θ(α)(m)(C) = θ(α)(n)(C)

5 / 23

slide-12
SLIDE 12

Stochastic bisimulation

[Mardare-Cardelli‘10]

The definition of Markov kernel induces a new definition of stochastic bisimulation

Stochastic bisimulation:

A rate-bisimulation relation R ⊆ M × M is an equivalence relation such that for all α ∈ A and R-closed measurable sets C ∈ Σ.

(m, n) ∈ R iff θ(α)(m)(C) = θ(α)(n)(C)

we say m and n are stochastic bisimilar, written m ∼(M,Σ,θ) n, if they are related by a stochastic bisimulation.

5 / 23

slide-13
SLIDE 13

Outline of the construction Problem: the definition of a Markov kernel needs a structural

presentation of the semantics (SOS).

+ Brane Calculus + SOS for Brane Calculus + Markov kernel for Brane Calculus

6 / 23

slide-14
SLIDE 14

(Finite state) Brane calculus

[Cardelli ‘04]

Systems P: P, Q ::= k | σhPi | P m Q nests of membranes Membranes M: σ, τ ::= 0 | σ|τ | a.σ combinations of actions Actions: a, b ::= . . . (not now)

P σ

contents membrane

σhPi P σ τ

membrane patches

σ|τhPi

7 / 23

slide-15
SLIDE 15

Brane Calculus Reactions

Actions: . . . Jn | JI

n(σ) | Kn | KI n | G(σ)

phago J, exo K, pino G

Q JI

n(ρ).τ

τ ′ P Jn.σ σ′ phago Q

τ τ ′

ρ P σ σ′ Q KI

n.τ

τ ′ P Kn.σ σ′ exo Q σ τ σ′ τ ′ P P G(ρ).τ σ pino P

τ

σ ρ

8 / 23

slide-16
SLIDE 16

Reduction Semantics for Brane Calculus Reduction relation (“reaction”): } ⊆ P × P

JI

n(ρ).τ|τ0hQi m Jn.σ|σ0hPi } τ|τ0hρhσ|σ0hPii m Qi (red-phago)

KI

n.τ|τ0hKn.σ|σ0hPi m Qi } σ|σ0|τ|τ0hQi m P (red-exo)

G(ρ).σ|σ0hPi } σ|σ0hρhki m Pi

(red-pino)

P } Q σhPi } σhQi

(red-loc)

P } Q P m R } Q m R

(red-comp)

P ≡ P′ P′ } Q′ Q′ ≡ Q P } Q

(red-equiv)

9 / 23

slide-17
SLIDE 17

Reduction Semantics for Brane Calculus Reduction relation (“reaction”): } ⊆ P × P

JI

n(ρ).τ|τ0hQi m Jn.σ|σ0hPi } τ|τ0hρhσ|σ0hPii m Qi (red-phago)

KI

n.τ|τ0hKn.σ|σ0hPi m Qi } σ|σ0|τ|τ0hQi m P (red-exo)

G(ρ).σ|σ0hPi } σ|σ0hρhki m Pi

(red-pino)

P } Q σhPi } σhQi

(red-loc)

P } Q P m R } Q m R

(red-comp)

P ≡ P′ P′ } Q′ Q′ ≡ Q P } Q

(red-equiv)

not structural

9 / 23

slide-18
SLIDE 18

Towards a Structural Operational Semantics

We give a LTS for the Brane Calculus (along [Rathke-Sobocinski‘08])

Meta-syntax∗∗

(typed λ-calculus) Terms M ::= 0 | k | α.M | M|M | M m M | MhMi X (variable) λX:t. M (lambda abstraction) M(M) (application) α ::= Jn | JI

n(M) | Kn | KI n | Gn(M)

Types t ::= sys | mem | act | t → t

(**) It is not a language extension, λ-terms are introduced only for a structural definition of the LTS.

10 / 23

slide-19
SLIDE 19

Typing System for Brane Calculus

Γ ⊢ M : t

(Judgement)

environment Γ: Vars → Types term type

Γ(X) = t Γ ⊢ X : t

(var)

Γ, X:t ⊢ M : t′ Γ ⊢ λX:t. M : t → t′ (lambda) Γ ⊢ M : t → t′ Γ ⊢ N : t Γ ⊢ M(N) : t′

(app)

11 / 23

slide-20
SLIDE 20

Typing System for Brane Calculus

Γ ⊢ M : t

(Judgement)

environment Γ: Vars → Types term type

a ∈ {Jn, Kn, KI

n}

Γ ⊢ a : act

(act)

a ∈ {JI

n, Gn}

Γ ⊢ M : mem Γ ⊢ a(M) : act

(act-arg)

11 / 23

slide-21
SLIDE 21

Typing System for Brane Calculus

Γ ⊢ M : t

(Judgement)

environment Γ: Vars → Types term type

Γ ⊢ 0 : mem

(zero)

Γ1 ⊢ α : act Γ2 ⊢ M : mem Γ1, Γ2 ⊢ α.M : mem

(α-pref)

Γ1 ⊢ M : mem Γ2 ⊢ N : mem Γ1, Γ2 ⊢ M|N : mem

(par) union of environments supposed to be disjoint

11 / 23

slide-22
SLIDE 22

Typing System for Brane Calculus

Γ ⊢ M : t

(Judgement)

environment Γ: Vars → Types term type

Γ ⊢ k : sys

(void)

Γ1 ⊢ M : mem Γ2 ⊢ N : sys Γ1, Γ2 ⊢ MhNi : sys

(loc)

Γ1 ⊢ M : sys Γ2 ⊢ N : sys Γ1, Γ2 ⊢ M m N : sys

(comp) union of environments supposed to be disjoint

11 / 23

slide-23
SLIDE 23

Labelled Transition System

(membranes)

Labels for mem-transitions: Amem = {Jn, JI

n(ρ), Kn, KI n, Gn(ρ)}

Jn.σ Jn − → σ

(J-pref)

JI

n(ρ).σ JI

n(ρ)

− − − → σ

(JI-pref)

Kn.σ Kn − → σ

(K-pref)

KI

n.σ KI

n

− → σ

(KI-pref)

Gn(ρ).σ

Gn(ρ)

− − − → σ

(G-pref)

σ α − → σ′ σ|τ

α

− → σ′|τ

(L-par)

σ α − → σ′ τ|σ α − → τ|σ′ (R-par)

12 / 23

slide-24
SLIDE 24

Labelled Transition System

(systems)

Labels for sys-transitions: A+

sys = {phagon, phagon, exon} ∪ {id}

Phago fragment∗∗

σ

Jn

− → σ′ σhPi

phagon

− − − − → λZ. Z(σ′hPi)

(J)

σ

JI

n(ρ)

− − − → σ′ σhPi

phagon

− − − − → λX. σ′hρhXi m Pi

(JI)

P

phagon

− − − − → F P m Q

phagon

− − − − → λZ. (F(Z) m Q)

(LmJ)

P

phagon

− − − − → A P m Q

phagon

− − − − → λX. (A(X) m Q)

(LmJI)

P

phagon

− − − − → F Q

phagon

− − − − → A P m Q

id

− → F(A)

(L-idJ)

(**) Right-symmetric rules are omitted

example 13 / 23

slide-25
SLIDE 25

Labelled Transition System

(systems)

Labels for sys-transitions: A+

sys = {phagon, phagon, exon} ∪ {id}

Phago fragment∗∗

σ

Jn

− → σ′ σhPi

phagon

− − − − → λZ. Z(σ′hPi)

(J)

σ

JI

n(ρ)

− − − → σ′ σhPi

phagon

− − − − → λX. σ′hρhXi m Pi

(JI)

P

phagon

− − − − → F P m Q

phagon

− − − − → λZ. (F(Z) m Q)

(LmJ)

P

phagon

− − − − → A P m Q

phagon

− − − − → λX. (A(X) m Q)

(LmJI)

P

phagon

− − − − → F Q

phagon

− − − − → A P m Q

id

− → F(A)

(L-idJ)

(**) Right-symmetric rules are omitted

example

has type (sys → sys) → sys has type sys → sys

13 / 23

slide-26
SLIDE 26

Labelled Transition System

(systems)

Labels for sys-transitions: A+

sys = {phagon, phagon, exon} ∪ {id}

Exo fragment∗∗ σ Kn − → σ′ σhPi exon − − → λXy. σ′|yhXi m P

(K)

P

exon

− − → S P m Q

exon

− − → λXy. S(X m Q)(y)

(LmK)

P

exon

− − → S σ

KI

n

− → σ′ σhPi id − → S(k)(σ′)

(id-K)

(**) Right-symmetric rules are omitted

13 / 23

slide-27
SLIDE 27

Labelled Transition System

(systems)

Labels for sys-transitions: A+

sys = {phagon, phagon, exon} ∪ {id}

Pino fragment σ

Gn(ρ)

− − − → σ′ σhPi id − → σ′hρhki m Pi

(id-G)

Cong-closures∗∗ P

id

− → P′ σhPi id − → σhP′i

(id-loc)

P

id

− → P′ P m Q

id

− → P′ m Q

(Lmid)

(**) Right-symmetric rules are omitted

13 / 23

slide-28
SLIDE 28

Labelled Transition System

(properties)

LTS compatible with reduction semantics:

Proposition

+ If P

id

− → Q then P } Q + If P } Q then P

id

− → Q′ for some Q′ ≡ Q LTS compatible with structural congruence:

Lemma

If P

α

− → P′ and P ≡ Q then ∃. Q′ such that Q′ ≡ P′ and Q

α

− → Q′.

14 / 23

slide-29
SLIDE 29

Stochatic Model for the Brane Calculus Action Labels: A+ = Amem ∪ A+

sys

Markov kernel: (T, Σ, θ) θ: A+ → T → ∆(T, Σ)

15 / 23

slide-30
SLIDE 30

Stochatic Model for the Brane Calculus Action Labels: A+ = Amem ∪ A+

sys

Markov kernel: (T, Σ, θ) θ: A+ → T → ∆(T, Σ)

the same used by the LTS

15 / 23

slide-31
SLIDE 31

Stochatic Model for the Brane Calculus Action Labels: A+ = Amem ∪ A+

sys

Markov kernel: (T, Σ, θ) θ: A+ → T → ∆(T, Σ)

the same used by the LTS expected to be adequate w.r.t. the LTS M

α

− → M′ ⇐ ⇒ θ(α)(M)([M′]≡) > 0

15 / 23

slide-32
SLIDE 32

Markov kernel from SOS

The structural representation of the semantics makes possible the definition of θ by induction on the structure of processes. θ(phagon)(P m Q)(T ) =

(LmJ)

P

phagon

− − − − → F P m Q

phagon

− − − − → λZ. (F(Z) m Q)

(LmJ)

16 / 23

slide-33
SLIDE 33

Markov kernel from SOS

The structural representation of the semantics makes possible the definition of θ by induction on the structure of processes. θ(phagon)(P m Q)(T ) = θ(phagon)(P)(FQ)

(LmJ)

where FQ = {F : (sys → sys) → sys | λZ. (F(Z) m Q) ∈ T )}/≡ P

phagon

− − − − → F P m Q

phagon

− − − − → λZ. (F(Z) m Q)

(LmJ)

16 / 23

slide-34
SLIDE 34

Markov kernel from SOS

The structural representation of the semantics makes possible the definition of θ by induction on the structure of processes. θ(phagon)(P m Q)(T ) = θ(phagon)(P)(FQ) +

(LmJ)

θ(phagon)(Q)(FP)

(RmJ)

where FP = {F : (sys → sys) → sys | λZ. (P m F(Z)) ∈ T )}/≡ Q

phagon

− − − − → F P m Q

phagon

− − − − → λZ. (P m F(Z))

(RmJ)

16 / 23

slide-35
SLIDE 35

Markov kernel from SOS

The structural representation of the semantics makes possible the definition of θ by induction on the structure of processes. θ(id)(P m Q)(T ) = θ(id)(P)(TmQ) + θ(id)(Q)(TmP) +

(Lmid) (Rmid)

P

id

− → P′ P m Q

id

− → P′ m Q

(Lmid)

Q

id

− → Q′ P m Q

id

− → P m Q′

(Rmid)

16 / 23

slide-36
SLIDE 36

Markov kernel from SOS

The structural representation of the semantics makes possible the definition of θ by induction on the structure of processes. θ(id)(P m Q)(T ) = θ(id)(P)(TmQ) + θ(id)(Q)(TmP)

(Lmid) (Rmid) n∈Λ

  • F(A)⊆T

θ(phagon)(P)(F) · θ(phagon)(Q)(A) ι(Jn) + (L-idJ)

n∈Λ

  • F(A)⊆T

θ(phagon)(Q)(F) · θ(phagon)(P)(A) ι(Jn)

(R-idJ)

P

phagon

− − − − → F Q

phagon

− − − − → A P m Q

id

− → F(A)

(L-idJ)

Q

phagon

− − − − → F P

phagon

− − − − → A P m Q

id

− → F(A)

(R-idJ) law of mass action

16 / 23

slide-37
SLIDE 37

Markov kernel and adequacy w.r.t. LTS

The Markov kernel is adequate w.r.t. the LTS

Proposition

  • 1. if θ(α)(M)(T ) > 0 then ∃. M′ ∈ T s.t. M

α

− → M′

  • 2. if M

α

− → M′ then ∃. M ∈ Π s.t. M′ ∈ T and θ(α)(M)(T ) > 0

Corollary

M

α

− → M′ iff θ(α)(M)([M′]≡) > 0

17 / 23

slide-38
SLIDE 38

Stochastic Structural Operational Semantics

M → µ

0 → ωmem (zero) ǫ ∈ {Jn, Kn, KI

n}

ǫ.σ → [ǫ]σ

(pref)

ǫ ∈ {JI

n, Gn}

ǫ(ρ).σ → [ǫ(ρ)]σ

(pref-arg)

σ → µ′ τ → µ′′ σ|τ → µ′στ µ′′

(par)

k → ωsys (void) σ → ν P → µ σhPi → µ@σ

Pν (loc)

P → µ′ Q → µ′′ P m Q → µ′P ⊗Q µ′′ (comp) A+-indexed measure µ: A+ → ∆(T, Σ)

18 / 23

slide-39
SLIDE 39

Stochastic Bisimulation (on systems)

Adequacy w.r.t. Markov kernel

P → µ iff θsys(P)(α)(P) = µ(α)(P) This lead us to define:

Definition (Stochastic bisimulation on systems)

A rate-bisimulation relation is an equivalence relation R ⊆ P × P such that for arbitrary P, Q ∈ P with P → µ and Q → µ′, (P, Q) ∈ R iff µ(α)(C) = µ′(α)(C) ∀.C ∈ Π(R) and α ∈ A+

sys

Two systems P, Q ∈ P are stochastic bisimilar, written P ≈ Q, iff there exists a rate bisimulation relation R such that (P, Q) ∈ R.

19 / 23

slide-40
SLIDE 40

Stochastic bisimulation

(properties)

Theorem (≈ smallest stochastic bisimulation)

The stochastic bisimulation relation ≈ is the smallest equivalence such that for arbitrary P, Q ∈ P with P → µ and Q → µ′, P ≈ Q iff µ(α)(C) = µ′(α)(C) ∀. C ∈ Π(≈) and α ∈ A+

sys.

Theorem (≡ ≈)

+ If P ≡ Q then P ≈ Q + 0hσhii ≈ k and 0hσhii ≡ k.

20 / 23

slide-41
SLIDE 41

Conclusions & Future Work Done:

+ Structural Stochastic Semantics for the Brane Calculus + Labelled Transition System for the Brane Calculus (SOS) + Proved the generality of the approach of [Mardare-Cardelli‘10]

To do:

+ Is ≈ a congruence? + metrics for stochastic Brane processes + refinements (volume, temperature, pressure) + Full Brane Calculus (with bind&release) + comparing the approach with Gillespie algorithm

21 / 23

slide-42
SLIDE 42

Thanks :)

22 / 23

slide-43
SLIDE 43

Example: phago derivation

back to LTS

Jn.σ Jn − → σ

(J-pref)

JI

n(ρ).τ JI

n(ρ)

− − − → τ

(JI-pref)

23 / 23

slide-44
SLIDE 44

Example: phago derivation

back to LTS

Jn.σ Jn − → σ

(J-pref)

JI

n(ρ).τ JI

n(ρ)

− − − → τ

(JI-pref)

Jn.σhPi

phagon

− − − − → λZ. Z(σhPi)

(J)

JI

n(ρ).τhQi phagon

− − − − → λX. τhρhXi m Qi

(JI)

23 / 23

slide-45
SLIDE 45

Example: phago derivation

back to LTS

Jn.σ Jn − → σ

(J-pref)

JI

n(ρ).τ JI

n(ρ)

− − − → τ

(JI-pref)

Jn.σhPi

phagon

− − − − → λZ. Z(σhPi)

(J)

JI

n(ρ).τhQi phagon

− − − − → λX. τhρhXi m Qi

(JI)

Jn.σhPi m JI

n(ρ).τhQi id

− → τhρhσhPii m Qi

(L-idJ)

23 / 23