Multi affine

Post on 15-Jun-2015

384 views 0 download

Tags:

transcript

Ezio Bartocci

Multi Affine Cardiac Cell Models

Joint work with

R. Grosu, F. Fenton, J. Glimm, C. Le Guernic, and S. A. Smolka

SUNY Stony Brook

Overview• Background

– Cardiac Cells, Action Potential, Restitution

• Biological Switching• Minimal Model

– Resistor Model

– Sigmoid Closure and Conductance Model

• Piecewise Multi Affine Minimal Model

– Optimal Polygonal Approximation

– Model Comparison

• Parameter Identification

– RoverGene

• Conclusion

Background

Emergent Behavior in Heart Cells

Arrhythmia afflicts more than 3 million Americans alone

EKG

Surface

Single Cell Reaction: Action Potential

Membrane’s AP depends on: • Stimulus (voltage or current):

– External / Neighboring cells

• Cell’s state

time

volt

age

Sti

mu

lus

failed initiation

Threshold

Resting potential

Schematic Action Potential

AP has nonlinear behavior!• Reaction diffusion system:

∂u

∂t= R(u) +∇(D∇u)

BehaviorIn time

Reaction Diffusion

DI

APD

AP

D

DI

t (ms)

u (

mV

)

Frequency Response

APD90: AP > 10% APm DI90: AP < 10% APm BCL: APD + DI

Existing Models

• Detailed ionic models: – Luo and Rudi: 14 variables– Tusher, Noble2 and Panfilov: 17 variables – Priebe and Beuckelman: 22 variables – Iyer, Mazhari and Winslow: 67 variables

• Approximate models:– Cornell: 3 or 4 variables – SUNYSB: 2 or 3 variable

Biological Switching

θ =0.5

k = 16

Biological Switching

S+(u,θ,k,0,1) =1

1+ e−2k(u−θ )

H +(u,θ,0,1) = 0 u<θ1 u≥θ

⎧⎨⎩⎪

R+(u,θ1,θ2 ,0,1) =

0 u<θ1

u−θ1

θ2 −θ1

else

1 u≥θ2

⎪⎪

⎪⎪

• Arithmetic Generalization of Boolean predicates u ≤ θ:

Threshold-Based Switching Functions

~(u ≤ θ) : h-(u,θ,0,1) = 1 – h+(u,θ,0,1)

(u ≤θ1) & (v ≤θ2) : h+(u,θ1,0,1) * h+(v,θ2,0,1)

(u ≤θ1) | (u ≤θ2) : h+(u,θ1,0,1) + h+(v,θ2,0,1) - h+(u,θ1,0,1) * h+(v,θ2,0,1)

• Generalization: h±(u,θ,um,uM), s± (u,θ,k,um,uM) , r± (u,θ1,θ2,um,uM)

- Step: H+(u,θ,0,1), H-(u,θ,0,1) = 1 - H+(u,θ,0,1)

- Sigmoid: S+(u,θ,k,0,1), S-(u,θ,k,0,1) = 1 - S+(u,θ,k,0,1)

- Ramp: R+(u,θ1,θ2,0,1), R-(u,θ1,θ2,0,1) = 1 - R+(u,θ1,θ2,0,1)

• Boolean algebra generalizes to probability algebra:

Gene Regulatory Networks (GRN)

• GRNs have the following general form:

&xi = amns±(xmn,,θmn,kmn

n=1

nm

∏ ,umn,vmn)−bixim=1

mi

where:

amn : are activation / inhibition cons tants

bi : are decay cons tants

s±(..) : are possibly complemented sigmoidal functions

• Note: our steps and ramps are sigmoid approximations

Minimal Model

&u =∇(D∇u)−(J fi + J si + J so)

Cornell’s Minimal Resistor Model

&v = H−(u,θv,0,1) (v∞ −v) / τ v−−H +(u,θv,0,1)v / τ v

+

&w = H−(u,θw,0,1)(w∞ −w) / τw−−H +(u,θw,0,1)w/ τw

+

&s = (S+(u,us,2ks,0,1)−s) / τ s

J fi =−H(u−θv)(u−θv)(uu −u)v/ τ fi

J fi =−H +(u,θv,0,1) (u−θv)(uu −u)v/ τ fi

J si =−H +(u,θw,0,1) ws / τ si

J so = H−(u,θw,0,1) u / τo + H +(u,θw,0,1) / τ so

PiecewiseNonlinear

Heaviside(step)

Sigmoid(s-step)

PiecewiseNonlinear

PiecewiseBilinear

PiecewiseLinear

Nonlinear

ActivationThreshol

d

Fast inputGateSlow Input

GateSlow Output

GateResistanceTime Cst

Fast inputcurrent

DiffusionLaplacia

nvoltage Slow input

currentSlow output

current

τ v− = (1 − H (u −θ v

− )) τ v1− + H (u −θ v

− ) τ v2−

τ s = (1 − H (u −θw )) τ s1 + H (u −θw ) τ s2

τ o = (1 − H (u −θo )) τ o1 + H (u −θo ) τ o2

w∞

τw− = τ w1

− + (τ w2− − τ w1

− ) S(2kw− (u − uw

− ))

τ so = τ so1 + (τ so2 − τ so1) S(2kso(u − uso ))

w∞

Voltage-controlled resistances

PiecewiseConstant

Sigmoidal

v∞ = (1−H(u−θv−))

w∞ = (1−H(u−θo)) (1−u / τw∞) + H(u−θo) w∞*

τ so = (1−H(u−θo)) τo1 + H(u−θo) τo2

PiecewiseLinear

u ≥θo

u ≥θv

u ≥θw

θo ≤ u < θw

&u = ∇(D∇u) − u / τ o2

&v = −v / τ v2−

&w = (w∞* − w) / τ w1

&s = (S(2ks (u − us )) − s) / τ s

θw ≤ u < θv

&u = ∇(D∇u) + ws / τ si −1 / τ so

&v = −v / τ v2−

&w = −w / τ w+

&s = (S(2ks (u − us )) − s) / τ s2

u < θo =θv− =0.006

u < θw =0. 13

u < θv =0.3

Cornell’s Minimal Resistance Model

u < θo

&u =∇(D∇u)−u / τo1

&v = (1−v) / τ v1−

&w = (1−u / τw∞ −w) / τw−

&s = (S(2ks(u−us))−s) / τ s

θv ≤ u

&u =∇(D∇u) + (u−θv)(uu −u)v/ τ fi +ws / τ fi −1 / τ so

&v =−v/ τ v+

&w =−w/ τw+

&s = (S(2ks(u−us))−s) / τ s2

Sigmoid Closure

S+(u,k,θ,a,b)−1 =S−(u,k,θ + ln(a /b) / 2k,b−,a−)

For ab > 0, scaled sigmoids are closed under multiplicative inverses (division):Theorem

S+(u,k,θ,a,b)−1 =1

a+b−a

1+ e−2k u−θ( )

=1+ e−2k(u−θ )

b+ ae−2k(u−θ ) =

=1a×

a−b+b+ ae−2k(u−θ )

b+ ae−2k(u−θ ) =1a−

1a−1b

1+ab

e−2k(u−θ )=

=1a−

1a−1b

1+ e−2k(u−(θ+ lna−lnb

2k))=S−(u,k,θ +

lnab

2k,1b,1a)

Proof

a

b-a

θ

S+(u,k,θ,a,b)

1/b-1/a

θ + ln(a / b) / 2k

S+(u,k,θ,a,b)−1

1/a

gv− =1 / τ v

− = H−(u,θv−,gv1

−,gv2− )

go =1 / τo = H +(u,θv−,go1,go2 )

gs =1 / τ s = H−(u,θw,gs1,gs2 )

w∞

Resistances vs Conductances

Removing Divisions using Sigmoid Closure

gw− =1 / τw

− = S+(u,kw−,u'w

−,gw1− ,gw2

− )

gso =1 / τ s0 = S+(u,kso,u'so,gso1,gso2 )

θv−

0.006

θv

0.3

θw

0.13

uuu

1.55

us

0.9087

uw−

0.03

uso

0.65

Removing Divisions using

τw− = S− (u,kw

− ,uw− ,τ w1

− ,τ w2− )

τ so = S− (u,kso,uso,τ so1,τ so2 )

τ v− = H + (u,θ v

− ,τ v1− ,τ v2

− )

τ o = H − (u,θ v− ,τ o1,τ o2 )

τ s = H + (u,θw ,τ s1,τ s2 ) v∞ = h−(u,θv

−,0,1)

w∞ = h−(u,θv−,0,1) (1−ugw∞ ) + h+(u,θv

−,0,w∞* )

u 'w−

u 'so−

H +(u,θ,a,b)−1 =H−(u,θ,b−1,a−1)

u ≥θo

u ≥θv

u ≥θw

θv− ≤ u < θw

&u = ∇(D∇u) − u go2

&v = −v gv2−

&w = (w∞* − w) gw1

&s = (s+ (u,us ,2ks ,0,1) − s) gs1

θw ≤ u < θv

&u = ∇(D∇u) + ws gsi − gso

&v = −v gv2−

&w = −w gw+

&s = (Ss+ (u,us ,2ks ,0,1) − s) gs2

u < θo =θv− =0.006

u < θw =0. 13

u < θv =0.3

Conductances Minimal Model

θv ≤ u

&u =∇(D∇u) + (u−θv)(uu −u)v gfi +ws gsi −gso

&v =−v gv+

&w =−w gw+

&s = (s+(u,us,2ks,0,1)−s) gs2

u < θv−

&u =∇(D∇u)−u go1

&v = (1−v) gv1−

&w = (1−u gw∞ −w) gw−

&s = (s+(u,us,2ks,0,1)−s) gs1

Piecewise Multi Affine Model

Our goals

• Learn a Piecewise Multi Affine model:

– This should facilitate analysis

– We want to improve the computational efficiency

• Identify the parameters based on: – Data generated by a detailed ionic model– Experimental, in-vivo data

Optimal Polygonal ApproximationProblem to solve:Given a nonlinear curve and the desired number of the segments return the optimal polygonal approximation:

Example: What is the optimal polygonal approximation of the blu curvewith 3 segments ?

Marc Salotti, An efficient algorithm for the optimal polygonal approximation of digitized curves, Pattern Recognition Letters 22 (2001), Pag 215-221

Dynamic Programming Algorithm with Complexity O(P2S)P the number of points of the curveS the number of segments

Global Optimal Polygonal ApproximationOur problem:Given a set of nonlinear curves and the desired number of the segments return the optimal polygonal approximation:

Example: What is the optimal polygonal approximation of the blu and the red curve with 5 segments ?

But combining the two we obtain 8 segments and not 5 segmentsWe modify the optimal polygonal approximation algorithm to perform the linearization on a set of curves trying to minimize the maximum error.

Our solution:

Deriving the Piecewise Multi Affine Model

DI

APD

AP

D

DI

t (ms)

u (

mV

)

Minimal Resistor Model

Multi Affine Model (26 ramps)

1D Cable Comparison

2D Comparison

Simulation of the Multi Affine Model is computational efficient (1.43 x)

1024x1024 cells 100000 iterations 556 sec. vs. 810 sec. (GPU Tesla C1060)

Parameter Identification

• Find parameters such that network is bistable

cross-inhibition network

x: protein concentration

: rate parametersthreshold concentrationka ,kb ,γa,γb

θa1,θa

2 ,θb1,θb

2

Genetic Regulatory Networks

G. Batt, C. Belta and R. Weiss (2008)Temporal logic analysis of gene networks under parameter uncertainty

• Partition of the state space: rectangles

ka ,kb

Genetic Regulatory Networks

Specifications of dynamical properties

Embedding transition system

Iterative exploration of parameter space

Analysis Problem

• Find parameter ranges reproducing non-excitability:

– Restated as an LTL formula: G (u <θv)

• Initial region:

u ∈[0,θ1] v ∈[0.95,1] w ∈[0.95,1] s ∈[0,0.01]

• Uncertain parameter ranges:

go1 ∈[1,180] go2∈[0,10] gsi ∈[0.1,100] gso ∈[0.9,50]

• Stimulus: e=1

State Space Partition

• Hyperrectangles: 4 dimensional (uv-projection)

– Arrows: indicate the vector field

u

v1.00

0.95

0.00θ0 θ1 θ2 θ3 θ7 θ8 θ12 θ13 θ25 θ26θ11θ9

Embedding Transition System TX(p)

u

v1.00

0.95

0.00θ0 θ1 θ2 θ3 θ7 θ8 θ12 θ13 θ25 θ26θ11θ9

xTX (p)⏐ →⏐ ⏐ x' iff there is a solution ξ and time τ such that:

x 'x

− ξ(0) = x, ξ (τ ) = x'

− ∀t ∈[0,τ ]. ξ (t)∈rect(x)∪ rect(x')

− rect(x) is adjacent to rect(x ')

ξ

The Discrete Abstraction TR(p)

u

v1.00

0.95

0.00θ0 θ1 θ2 θ3 θ7 θ8 θ12 θ13 θ25 θ26θ11θ9

x : R( p) x' iff rect(x) =rect(x')

TR (p) is the quotiont of TX (p) with res pect to : R( p)

Theorem: ∀p. TX (p) ≤ TR (p)

Computing TR(p)

Theorem: If f is multi-affine then

∀x ∈R. f (x)∈cHull({ f (v) | v ∈VR})f (v1)

f (v4 )

f (v2 )

f (v3)

v3v4

v1 v2

x

f (x)

R

Corollary:

1.00

0.95

0.00θ0 θ1 θ2

1.00

0.95

0.00θ0 θ1 θ2

Partitioning the Parameter Space

go2

go10

go1go2

1

go2

0

go11 go1

2 go1m−1 go1

m

go2

n

go2

n−1

go2

2

• Parameter space: 4 dimensional (go1/go2

projection)

– Each rectangle: a different transition system

• In each vertex: affine equation in the parameters

1.00

0.95

0.00θ1 θ2

&u =1−u go1

= 0

go1 =1 /θ2go1 =1 /θ1

u

Results

• Rovergene: intelligently explores the PS rectangles

go2

go1

1

0

166.94 180

10

7.69

gso

gsi

0.1

0.9

90.18

100

50

26.95

independent linearly dependent simulation

Conclusions and Outlook • First automatic parameter-range identification for CC

- Validated both in MCM and MRM- Can be validated experimentally as for ischemia

• Currently work on time-dependent properties of CC- Extend SpaceEx with RoverGene MA-techniques

• Moving towards 2D/3D parameter-range identification- Use PS partitioning, simulation and curvature analysis

• Derive the MRM from Iyer model through TS abstraction

Resistances Minimal Model (RMM)

(Assumption: resistances are sigmoids)

&v = h−(u,θv,0,1) (v∞ −v) / τ v−−h+(u,θv,0,1)v / τ v

+

&w = h−(u,θw,0,1)(w∞ −w) / τw−−h+(u,θw,0,1)w/ τw

+

&s = (s+(u,us,2ks,0,1)−s) / τ s

J fi =−H(u−θv)(u−θv)(uu −u)v/ τ fi

&u =∇(D∇u)−(J fi + J si + J so)

J fi =−H(u−θv)(u−θv)(uu −u)v/ τ fiJ fi =−h+(u,θv,0,1) (u−θv)(uu −u)v/ τ fi

J si =−h+(u,θw,0,1) ws / τ si

J so = h−(u,θw,0,1) u / τo +h+(u,θw,0,1) / τ so

RMM with Currents and Gates

θv−

0.006

θv

0.3

θw

0.13

uuu

1.55

us

0.9087

uw−

0.03

uso

0.65

&v = h−(u,θv,0,1) (v∞ −v) / τ v−−h+(u,θv,0,1)v / τ v

+

&w = h−(u,θw,0,1)(w∞ −w) / τw−−h+(u,θw,0,1)w/ τw

+

&s = (s+(u,us,2ks,0,1)−s) / τ s

J fi =

&u =∇(D∇u)−(J fi + J si + J so)

J fi + h+(u,θv,0,1) (u−θv)(uu −u)v/ τ fi

J si + h+(u,θw,0,1) ws / τ si

J so − h−(u,θw,0,1) u / τo +h+(u,θw,0,1) / τ so

RMM State Variables

θv−

0.006

θv

0.3

θw

0.13

uuu

1.55

us

0.9087

uw−

0.03

uso

0.65

τ v− = h− (u,θ v

− ,0,τ v1− ) + h+ (u,θ v

− ,0,τ v2− )

τ o = h− (u,θ v− ,0,τ o1) + h+ (u,θ v

− ,0,τ o2 )

τ s = h− (u,θw ,0,τ s1) + h+ (u,θw ,0,τ s2 )

w∞τw− = s+ (u,uw

− ,2kw− ,τ w1

− ,τ w2− )

τ so = s+ (u,uso,2kso,τ so1,τ so2 )

w∞v∞ = h−(u,θv−,0,1)

w∞ = h−(u,θv−,0,1) (1−u / τw∞) + h+(u,θv

−,0,w∞* )

τ so = h−(u,θv−,0,1)τo1 + Hh(u−θo) τo2θv

0.006

θv

0.3

θw

0.13

uuu

1.55

us

0.9087

uw−

0.03

uso

0.65

RMM Resistances

&v = h−(u,θv,0,1)(v∞ −r+(v,0,v,0,v)) / τ v−−h+(u,θv,0,1) r

+(v,0,1,0,1) / τ v+

&w = h−(u,θw,0,1)(w∞ −r+(w,0,1,0,1)) / τw−−h+(u,θw,0,1)r

+(w,0,1,0,1) / τw+

&s = (s+(u,us,2ks,0,1)−r+(s,0,1,0,1)) / τ s

J fi =−H(u−θv)(u−θv)(uu −u)v/ τ fi

&u =∇(D∇u)−(J fi + J si + J so)

J fi + r+(u,θv,uu,0,uu-θv)r−(u,θv,uu,0,uu-θv)r

+(v,0,1,0,1) / τ fi

J si + h+(u,θw,0,1)r+(w,0,1,0,1)r+(s,0,1,0,1) / τ si

J so − r(u,0,θw,0,θw) / τo +h+(u,θw,0,1) / τ so

State Variables with Ramps

θv−

0.006

θv

0.3

θw

0.13

uuu

1.55

us

0.9087

uw−

0.03

uso

0.65

Resistances with Ramps

τ v− = h+ (u,θ v

− ,τ v1− ,τ v2

− )

τ o = h+ (u,θ v− ,τ o1,τ o2 )

τ s = h+ (u,θw ,τ s1,τ s2 )

w∞τw− = s+ (u,uw

− ,2kw− ,τ w1

− ,τ w2− )

τ so = s+ (u,uso,2kso,τ so1,τ so2 )

w∞v∞ = h−(u,θv−,0,1)

w∞ = r−(u,0,θv−,1,1-θv

−/τw∞) + h+(u,θv−,0,w∞

* )

τ so = h−(u,θv−,0,1)τo1 + Hh(u−θo) τo2θv

0.006

θv

0.3

θw

0.13

uuu

1.55

us

0.9087

uw−

0.03

uso

0.65

function [e,a,b,xb] = optimalLinearApproximation(x,y,S)Input: x,y: Curves given as an x-points vector and a vector of y-points vectors S: Number >= 2 of desired segmentsOutput: e: Errors matrix a,b: Line-segment-coefficients matrix xb: x-coordinate at breaking point matrixInitializationz1 = size(x); P = z1(2); Get number of points in each curvez2 = size(y); C = z2(1); Get number of digitized curvesse = zeros(1,C); Initialize vector of errors, one error for each curve Cost tablescost = ones(P,S) * inf; cost(30,4) = min cost to pt 30 with 4-segm polylineerror = ones(P,P) * inf; error(i, n) = cached error of line segment (i,n) cost(2,1) = 0; 1-segment-polyline cost of polyline (1,2) = 0Predecessor tablefather = ones(P,S) * inf; father(30,4) = pred of pt 30 on a 4-segm polyline

Computation of optimal segmentationInitialize cost and father for 1-segment-polyline, from pt 1 to all other ptsfor p = 2:P Traverse all other points for c = 1:C Traverse all curves se(c) = segmentError(x(1:p), y(c,1:p)); (1,p)-line-segment appr error end; for c cost(p,1) = max(se); Maximum error among all curves father(p,1) = 1; All 1-segment polylines have father point 1end; for p

Compute s-segm-polyline cost from point 1 to all other pointsfor s = 2:S Number of segments in the polyline for p = 3:P Next-point-number to consider minErr = cost(p-1,s-1); minIndex = p-1; Error of (p-1,p) = 0 for i = s:p-2 Next-intermediate-point to consider if (error(i,p) == Inf) Error of line segment (i,n) not cashed for c = 1:C Next curve-number to consider se(c) = segmentError(x(i:p), y(k,i:p)); (i,p)-segment error end; for k error(i,p) = max(se); Maximum line segment error end; if currErr = cost(i,s-1) + error(i,p); s-segment-polyline error if (currErr < minErr) Smaller error? minErr = currErr; minIndex = i; Update error and parent end; if end; for i cost(p,s) = minErr; s-segment-polyline minimal cost father(p,s) = minIndex; Last point's father on the polyline end; for pend; for s[e,a,b,xb] = ExtractAnswer; end

function [e,a,b] = segmentError(x,y) Input: x,y: Digitized curve-segment as an x-vector and an y-vector Output: e: Error of the line segment between the first and last point a,b: The coeficients defining this segmentInitialization:z = size(x); P = s(2); Find out the number of points of x,y

Compute 1-segment linear-interpolation of (x,y) coefficients a = (y(n) - y(1)) / (x(n) - x(1));b = (y(1) * x(n) - y(n) * x(1)) / (x(n) - x(1));

Compute perpendicular-distance error for above line segmente = 0; Initialize Errorfor p = 1:P Compute error for the each point on the curve e = e + (y(p) - a * x(p) - b)2 / (a2+1); Accumulate least square end;end

function [e,a,b,xb] = ExtractAnswer Output: e,a,b,xb: As in the output of optimalLinearApproximationInitialization:ib = zeros(S,S+1); xb = zeros(S,S+1); yb = zeros(C, S,S+1); Points matricesa = zeros(C, S,S); b = zeros(C, S,S); er = zeros(C, S,S); Coefficients/errorExtract error and coefficient matricesfor s = S:-1:1 Traverse polyline segments in inverse order ib(s,s+1) = P; Get last point number xb(s,s+1) = x(ib(s,s+1)); Get x-value for this point for c = 1:C Traverse all curves yb(c,s,s+1) = y(c,ib(s,s+1)); Get y-value for this point end; for i = s:-1:1 Traverse predecessor points in inverse order ib(s,i) = father(ib(j,i+1),i); Get predecessor point number xb(s,i) = x(ib(s,i)); Get x-value for this point for c = 1:C Traverse all curves yb(c,s,i) = y(c,ib(s,i)); Get y-value for this point [er(c,s,i), a(c,s,i), b(c,s,i)] = Compute err, a and b for segm (x,y) segmentError( x(ib(s,i):ib(s,i+1)), y(c,ib(s,i):ib(s,i+1)) ); end end;end; end