Lecture 5 The futurebortolu/files/Didattica/SISSAcourse... · 2007-01-31 · Lecture 5 The future...
Transcript of Lecture 5 The futurebortolu/files/Didattica/SISSAcourse... · 2007-01-31 · Lecture 5 The future...
Introduction sCCP Bio-Modeling S-Systems and Diff. Eq. Automata and Temporal Logic
Lecture 5The future
Luca Bortolussi1 Alberto Policriti2
1Dipartimento di Matematica ed InformaticaUniversità degli studi di TriesteVia Valerio 12/a, 34100 Trieste.
[email protected] di Matematica ed Informatica
Università degli studi di UdineVia delle Scienze 206, 33100 Udine.
SISSA, January 2007
Introduction sCCP Bio-Modeling S-Systems and Diff. Eq. Automata and Temporal Logic
Material from:
... on going work.
Introduction sCCP Bio-Modeling S-Systems and Diff. Eq. Automata and Temporal Logic
Systems Biology, Computer Science, and Communication .
Formal tools for specifying Communicating andConcurrent systems have been used as a paradigm for:
1 computability (classic - Milner Calculus of CommunicatingSystems)
2 biological modeling (rather new - π-calculus Shapiro, Priami,Cardelli, ...)
Our proposal:an attempt to establish a closer connection betweencommunication-based and differential equations modeling techniques
Our tool: Stochastic Concurrent Constraint Programming(sCCP) as a link between:
Discrete and Stochastic (Gillespie algorithm)
Continuous and Deterministic modeling (differential equations)
Introduction sCCP Bio-Modeling S-Systems and Diff. Eq. Automata and Temporal Logic
Biological Systems and Stochastic Process Algebras
Molecule ProcessInteraction capability Channel
Interaction CommunicationModification State change
(of cellular components) (state transition systems)
A. Regev and E. Shapiro Nature, 2002.
ProsSimple Language
Compositionality
ConsHard to encodegeneral information
Lackingcomputationalextensibility
Introduction sCCP Bio-Modeling S-Systems and Diff. Eq. Automata and Temporal Logic
The picture
Introduction sCCP Bio-Modeling S-Systems and Diff. Eq. Automata and Temporal Logic
Concurrent Constraint Programming
Constraint StoreIn this process algebra, the main objects are agents and constraints
Constraints are formulae over an interpreted first order language (i.e.X = 10, Y > X − 3).
Constraints can be added to a "pot", called the constraint store, but cannever be removed.
AgentsAgents can perform two basic operations on this store:
Add a constraint (tell instruction)
Ask if a certain relation is entailed by the current configuration (askinstruction)
Introduction sCCP Bio-Modeling S-Systems and Diff. Eq. Automata and Temporal Logic
Syntax of sCCP
Syntax of Stochastic CCP
Program = D.A
D = ε | D.D | p(x) : −A
π = tellλ(c) | askλ(c)M = π.A | π.A.p(y) | M + M
A = 0 | tell∞(c).A | ∃xA | M | (A ‖ A)
Stochastic RatesRates are functions from the constraint store C to positive reals:
λ : C −→ R+.Rates can be thought as speed or duration of communications.
Introduction sCCP Bio-Modeling S-Systems and Diff. Eq. Automata and Temporal Logic
Continuous Time Markov Chains
A Continuous Time Markov Chain (CTMC) is a direct graph with edgeslabeled by a real number, called the rate of the transition (representing thespeed or the frequency at which the transition occurs).
In each state, we select the next stateaccording to a probability distributionobtained normalizing rates (from S to S1
with prob. r1r1+r2
).
The time spent in a state is given by anexponentially distributed random variable,with rate given by the sum of outgoingtransitions from the actual node (r1 + r2).
Introduction sCCP Bio-Modeling S-Systems and Diff. Eq. Automata and Temporal Logic
Mass Action Kinetics in sCCP
ExampleR1 + . . . + Rn →k P1 + . . . + Pm
reaction(k , [R1, . . . , Rn], [P1, . . . , Pm]) : −
askrMA(k ,R1,...,Rn)
(n∧
i=1
(Ri > 0)
).
(‖n
i=i tell∞(Ri = Ri − 1) ‖mj=1 tell∞(Pj = Pj + 1)
).
reaction(k , [R1, . . . , Rn], [P1, . . . , Pm])
where rMA(k , X1, . . . , Xn) = k · X1 · · ·Xn.
Introduction sCCP Bio-Modeling S-Systems and Diff. Eq. Automata and Temporal Logic
Biochemical Arrows to sCCP processes
R1 + . . . + Rn →k P1 + . . . + Pm
reaction(k, [R1, . . . , Rn ], [P1, . . . , Pm ]) : −askrMA(k,R1,...,Rn)
�Vni=1(Ri > 0)
�.�
‖ni=i tell∞(Ri = Ri − 1) ‖m
j=1 tell∞(Pj = Pj + 1)�.
reaction(k, [R1, . . . , Rn ], [P1, . . . , Pm ])
R1 + . . . + Rn k1k2
P1 + . . . + Pmreaction(k1, [R1, . . . , Rn ], [P1, . . . , Pm ]) ‖reaction(k2, [P1, . . . , Pm ], [R1, . . . , Rn ])
S 7→EK ,V0
P
mm_reaction(K , V0, S, P) : −askrMM (K ,V0,S)(S > 0).
(tell∞(S = S − 1) ‖ tell∞(P = P + 1)) .mm_reaction(K , V0, S, P)
S 7→EK ,V0,h P
hill_reaction(K , V0, h, S, P) : −askrHill (K ,V0,h,S)(S > 0).
(tell∞(S = S − h) ‖ tell∞(P = P + h)) .Hill _reaction(K , V0, h, S, P)
where rMA(k, X1, . . . , Xn) = k · X1 · · · Xn ; rMM (K , V0, S) =V0S
S + K; rHill (k, V0, h, S) =
V0Sh
Sh + K h
Introduction sCCP Bio-Modeling S-Systems and Diff. Eq. Automata and Temporal Logic
Enzymatic reaction
S + E k1k−1
ES →k2 P + E
Mass Action Equationsd [ES]
dt = k1[S][E ]− k2[ES]− k−1[ES]d [E ]dt = −k1[S][E ] + k2[ES] + k−1[ES]
d [S]dt = −k1[S][E ]
d [P]dt = k2[ES]
Mass Action Kineticsenz_reaction(k1, k−1, k2, S, E, ES, P) :-
reaction(k1, [S, E ], [ES]) ‖reaction(k−1, [ES], [E, S]) ‖reaction(k2, [ES], [E, P])
Michaelis-Menten Equationsd [P]dt =
V0SS+K
V0 = k2[E0]
K =k2+k−1
k1
Michaelis-Menten Kinetics
mm_reaction
k2 + k−1
k1, k2 · E, S, P
!
Introduction sCCP Bio-Modeling S-Systems and Diff. Eq. Automata and Temporal Logic
Enzymatic reaction
S + E k1k−1
ES →k2 P + E
Mass Action Equationsd [ES]
dt = k1[S][E ]− k2[ES]− k−1[ES]d [E ]dt = −k1[S][E ] + k2[ES] + k−1[ES]
d [S]dt = −k1[S][E ]
d [P]dt = k2[ES]
Michaelis-Menten Kinetics
mm_reaction
k2 + k−1
k1, k2 · E, S, P
!
Introduction sCCP Bio-Modeling S-Systems and Diff. Eq. Automata and Temporal Logic
MAP-Kinase cascade (C.F. Huang and J.T. Ferrel. PNAS, Biochemistry, 1996.)
enz_reaction(ka, kd , kr , KKK , E1, KKKE1, KKKS) ‖ enz_reaction(ka, kd , kr , KKKS, E2, KKKSE2, KKK ) ‖enz_reaction(ka, kd , kr , KK , KKKS, KKKKKS, KKP) ‖ enz_reaction(ka, kd , kr , KKP, KKP1, KKPKKP1, KK ) ‖
enz_reaction(ka, kd , kr , KKP, KKKS, KKPKKKS, KKPP) ‖ enz_reaction(ka, kd , kr , KP, KP1, KPKP1, K ) ‖enz_reaction(ka, kd , kr , K , KKPP, KKKPP, KP) ‖ enz_reaction(ka, kd , kr , KKPP, KKP1, KKPPKKP1, KKP) ‖
enz_reaction(ka, kd , kr , KP, KKPP, KPKKPP, KPP) ‖ enz_reaction(ka, kd , kr , KPP, KP1, KPPKP1, KP)
Introduction sCCP Bio-Modeling S-Systems and Diff. Eq. Automata and Temporal Logic
The gene machine instruction set
null_gate(kp, X) : −tellkp (X = X + 1).null_gate(kp, X)
pos_gate(kp, ke, kf , X , Y ) : −tellkp (X = X + 1).pos_gate(kp, ke, kf , X , Y )
+askr(ke,Y )(true).tellke (X = X + 1).pos_gate(kp, ke, kf , X , Y )
neg_gate(kp, ki , kd , X , Y ) : −tellkp (X = X + 1).neg_gate(kp, ki , kd , X , Y )
+askr(ki ,Y )(true).askkd(true).neg_gate(kp, ki , kd , X , Y )
where r(k, Y ) = k · Y .
Introduction sCCP Bio-Modeling S-Systems and Diff. Eq. Automata and Temporal Logic
Repressilator (M. B. Elowitz and S. Leibler. Nature, 2000.)
neg_gate(0.1, 1, 0.0001, A, C) ‖reaction(0.0001, [A], []) ‖
neg_gate(0.1, 1, 0.0001, B, A) ‖reaction(0.0001, [B], []) ‖
neg_gate(0.1, 1, 0.0001, C, B) ‖reaction(0.0001, [C], [])
Introduction sCCP Bio-Modeling S-Systems and Diff. Eq. Automata and Temporal Logic
Circadian Clock (J. M. G. Vilar, H. Yuan Kueh, N. Barkai, and S. Leibler. PNAS, 2002.)
Introduction sCCP Bio-Modeling S-Systems and Diff. Eq. Automata and Temporal Logic
Circadian Clock
p_gate(αA, α′A, γA, θA, MA, A) ‖p_gate(αR , α′R , γR , θR , MR , A) ‖reaction(βA, [MA], [A]) ‖reaction(δMA, [MA], []) ‖reaction(βR , [MR ], [R]) ‖reaction(δMR , [MR ], []) ‖reaction(γC , [A, R], [AR]) ‖reaction(δA, [AR], [R]) ‖reaction(δA, [A], []) ‖reaction(δR , [R], [])
Introduction sCCP Bio-Modeling S-Systems and Diff. Eq. Automata and Temporal Logic
S-Systems
S-systems describe the dynamical behavior of a biologicalsystem by a set of differential equations over reactants
non-linear, time-invariant, DAE systems;
biologically plausible and expressive;
analytical approximation power.
DefinitionAn S-system’s equation has the form:
Xi = αi
n+mYj=1
Xgijj − βi
n+mYj=1
Xhijj
with αi , βi ≥ 0 called rate constants and gij , hij called kinetic orders.
E. O. Voit. Computational Analysis of Biochemical Systems A Practical Guide for Biochemists andMolecular Biologists. Cambridge University Press, 2000.
M. A. Savageau. Biochemical System Analysis: A Study of Function and Design in Molecular Biology.Addison-Wesley, 1976.
Introduction sCCP Bio-Modeling S-Systems and Diff. Eq. Automata and Temporal Logic
Using S-Systems to determine rate functions
A generic form for S-System equations is
Xi = V +(X1, . . . , Xm+n)| {z }production speed
−V−(X1, . . . , Xm+n)| {z }degradation speed
.
A generic S-System equation has non-linear dependencies on variables.
Xi = αi
n+mYj=1
Xgijj − βi
n+mYj=1
Xhijj
We can use these expression as rates.
Using sCCP, we can associate to each dependent variable an agent subs(Xi): tell(Xi = Xi + σ)�
αiQn+m
j=1 Xgijj
� + tell(Xi = Xi − σ)�βiQn+m
j=1 Xhijj
�!
.subs(Xi).
Introduction sCCP Bio-Modeling S-Systems and Diff. Eq. Automata and Temporal Logic
Encoding S-System’s Repressilator
X1 = α1X−13 − β1X 0.5
1 ,
X2 = α2X−11 − β2X 0.5
2 ,
X3 = α3X−12 − β3X 0.5
3 ,
αi = 0.2, βi = 1.
subs(X1) ::= (tell(X1 = X1 + σ)[α1X−13 ]
+tell(X1 = X1 − σ)[β1X0.51 ]).subs(X1)
subs(X2) ::= (tell(X2 = X2 + σ)[α2X−11 ]
+tell(X2 = X2 − σ)[β2X0.52 ]).subs(X2)
subs(X3) ::= (tell(X3 = X3 + σ)[α3X−12 ]
+tell(X3 = X3 − σ)[β3X0.53 ]).subs(X3)
σ = 1
Introduction sCCP Bio-Modeling S-Systems and Diff. Eq. Automata and Temporal Logic
In progress:Systematic translation and behavioral equivalence theorem
(Probabilistic) Model Checking
Reachability
Reimplementation
L. Bortolussi Constraint-Based Approaches to StochasticDynamics of Biochemical Systems. Ph.D. thesis, Universityof Udine.
Introduction sCCP Bio-Modeling S-Systems and Diff. Eq. Automata and Temporal Logic
ConclusionsA stochastic version of CCP, with functional rates, can helpin “programming” biological (biochemical, genetic)communication networks
sCCP can be used for modeling and checking biologicalsystems, defining libraries for biochemical reactions andgene regulatory networksIt allows a decoupling of
discrete and procedural programming activity (discrete)continuous simulation (functional rates)
Introduction sCCP Bio-Modeling S-Systems and Diff. Eq. Automata and Temporal Logic
Automata for modeling
The general ideaMerge modeling techniques from the mathematical and logicaltraditions using automata as common ground.
Automatastates as tuple of variables’values of the underlying(mathematical) model;
an automated query mechanism/language can beprovided.
Introduction sCCP Bio-Modeling S-Systems and Diff. Eq. Automata and Temporal Logic
The temporal ingredient
Automaton-based models of the temporal evolution of a system
can be built on (heterogeneous) data;
can be queried.
Timed query languageTime dimension built-in the query language: CTL (ACTL∗, LTL,. . . ) language to query the system.
Introduction sCCP Bio-Modeling S-Systems and Diff. Eq. Automata and Temporal Logic
The data
Heterogeneous dataProduced as numerical traces of:
1 in vivo,2 in vitro, and3 in silico ,
experiments.
Quantitative aspects must be considered (e.g. in the querylanguage).
Introduction sCCP Bio-Modeling S-Systems and Diff. Eq. Automata and Temporal Logic
The interaction with the system
given a biological system described by means ofa pathway
a system of differential equations
a set of traces
We want to allow the user to formulate queries about thesystems’s qualitative behavior, e.g.
will the system reach a steady state?
verify:“... the two scaffold proteins axin and APCpromotethe formation of degradation complexes in very differentways. ...”
will concentration of reactant IMP stay over level 0.5?
Introduction sCCP Bio-Modeling S-Systems and Diff. Eq. Automata and Temporal Logic
Computation Tree Logic (CTL) structures
Formally our automata will be:
DefinitionA CTL structure (branching time structure) is M = (S, R, L)such that:
S set of states
R ⊆ S × S binary relation on states
L : S → Pow(AP) labeling function
Capture the intuition about the behavior of reactivesystems;
look like a graph rather than a tree: unfold it!
Introduction sCCP Bio-Modeling S-Systems and Diff. Eq. Automata and Temporal Logic
CTL language
Built using path quantifiers A and E plus the followingoperators:
Next Time: XP ... property P holds in the second state ofthe path;
Eventually: FP ... property P holds at some future state inthe path (in the future);
Always: GP ... property P holds at every state on the path(globally);
Until: PUQ ... property Q holds at every state on the pathand property P holds until then;
Release: PRQ ... property Q holds at every state on thepath up to the first state at which P holds.
Introduction sCCP Bio-Modeling S-Systems and Diff. Eq. Automata and Temporal Logic
Model Checking: automatic and formal validation
A classic in verificationTruth of a CTL-formulae can be checked automatically onCTL-structures.
Model Checking Algorithmassociate a set of labels with each state (i.e., the set ofsub-formulae true at that state);
initialize the set of labels in a given state with atomicpropositions (looking at the input);
proceed inductively on the structural complexity offormulae to extend the set of labels: 7 recursive calls to aprocedure label-graph (P,¬p, p ∧q, AX p, EX p,A(p U q), E(p U q)).
Introduction sCCP Bio-Modeling S-Systems and Diff. Eq. Automata and Temporal Logic
Complexity
Model checking is linear in the size of the model
Theorem (Clarke-Emerson-Sistla, Lichtenstein-Pnueli)Truth of a CTL(LTL)-formula p in a CTL(LTL)-structure (S, R, L)can be established in time O(|p|(|S|+ |R|)) (O(2|p|(|S|+ |R|))).
However ...
State explosion problemThe size of the structure can be huge.
Introduction sCCP Bio-Modeling S-Systems and Diff. Eq. Automata and Temporal Logic
The mathematical modeling machinery: S-Systems
A biological system usually involves
dependent reactants (variables) whose values are affected by thesystem
independent reactants that are not affected by the system
S-systems describe the dynamical behavior of a biologicalsystem by a set of differential equations over reactants
non-linear, time-invariant, DAE systems;
biologically plausible and expressive (see Savageau, Voit, ...);
they are an interchangeable component of the approach
E. O. Voit. Computational Analysis of Biochemical Systems A Practical Guide for Biochemists andMolecular Biologists. Cambridge University Press, 2000.
F. Alvarez-Vasquez, K. J. Sims, L. A. Cowart, Y. Okamoto, E. O. Voit, Y. A. Hannun Simulation and validationof modelled sphingolipid metabolism in Saccharomyces cerevisiae. Nature, vol. 433, 27 January 2005.
Introduction sCCP Bio-Modeling S-Systems and Diff. Eq. Automata and Temporal Logic
S-Systems: formal definition
DefinitionAn S-system is a tuple S = (DV , IV , DE , C) such that:
DV = {X1, . . . , Xn} dependent variables
IV = {Xn+1, . . . , Xn+m} independent variables
DE is a set of differential equations of the form
Xi = αi
n+m∏j=1
Xgij
j − βi
n+m∏j=1
Xhij
j
with αi , βi ≥ 0 called rate constants;
C is a set of algebraic constraints
Introduction sCCP Bio-Modeling S-Systems and Diff. Eq. Automata and Temporal Logic
Traces
The dynamic behavior of an S-system can be simulated bycomputing the (approximate) values of its variables at differenttime instants.
Definition
A system’s trace tr(S, t0, ~X (t0), s, tf ) =〈~g(t0), ~g(t0 + s), . . . , ~g(t0 + (j − 1) ∗ s), ~g(t0 + j ∗ s)〉 is obtainedby fixing:
an initial time t0the initial values ~X (t0) of the system variables
a time step s
a final time tf = to + j ∗ s, (j ≥ 0)
Introduction sCCP Bio-Modeling S-Systems and Diff. Eq. Automata and Temporal Logic
From Traces to Automata
Statesare tuples of variables’values.
Basic assumptionThe traces of a system are convergent: if two tracesreach the same state, then they evolve in the sameway
(we could use a less restrictive assumption, i.e., fusion closure)
This implies that:
the system is memoryless
a set of traces can be correctly encoded into an automaton
Tr is the set of traces under consideration.
Introduction sCCP Bio-Modeling S-Systems and Diff. Eq. Automata and Temporal Logic
S-System Automaton
DefinitionAn S-system automaton A(S, Tr) = (V ,∆, I, F ) is a tuple suchthat
states V = {~v = 〈v1, . . . , vn+m〉 | ∃tr ∈ Tr : ~v is in tr}transition ∆ = {(~v , ~w) | ∃tr ∈ Tr : ~v , ~w are consecutive intr}initial states I = {~v | ∃tr ∈ Tr : ~v is initial in tr} ⊆ V
final states F = {~v | ∃tr ∈ Tr : ~v is final in tr} ⊆ V
Introduction sCCP Bio-Modeling S-Systems and Diff. Eq. Automata and Temporal Logic
The Simpathica system
Simpathica ( Simulation of Pathways and Integrated ConcurrentAnalysis)
A tool that integrates numerical analysis, temporal logic,verification, and visualization tools and allows to:
handle biological systems described by means ofa pathwaya set of differential equations (PLAS, Octave/Mathlab, ...)a set of traces
encode the system’s behaviors into a standard automaton
easily express system’s properties to be checked
automatically verify system’s properties
Introduction sCCP Bio-Modeling S-Systems and Diff. Eq. Automata and Temporal Logic
The Architecture
Introduction sCCP Bio-Modeling S-Systems and Diff. Eq. Automata and Temporal Logic
Example: the Repressilator
Introduction sCCP Bio-Modeling S-Systems and Diff. Eq. Automata and Temporal Logic
The Repressilator Automaton
X1 = X4X−13 − X 0.5
1 , X4 = 0.2,
X2 = X5X−11 − X 0.578151
2 , X5 = 0.2,
X3 = X6X−12 − X 0.5
3 , X6 = 0.2.
Introduction sCCP Bio-Modeling S-Systems and Diff. Eq. Automata and Temporal Logic
Reducing the number of States
State explosion problemThe automata we work with may have a huge number of states
Two simple ways to reduce the automata areprojection: “ignore” some variables and consequentlyidentify states
collapsing: delete intermediate states
Introduction sCCP Bio-Modeling S-Systems and Diff. Eq. Automata and Temporal Logic
Projection can introduce false behaviors
Example
Projecting safely: BsimulationTwo automata are bisimilar if the states states missing in onecan be simulated by states in the other. Bisimilar automatasatisfy the same CTL-formulae.