Validated simulation of ODEs Julien Alexandre dit Sandretto
Department U2IS ENSTA Paris SSC310-2020 Contents
Initial Value Problem of Ordinary Differential Equations Problem of integral computation Picard-Lindel¨of Integration scheme Problem of wrapping effect Affine arithmetic Stepsize controller Validated integration in a contractor formalism Additive constraints Temporal constraints Bibliography Do it yourself
Julien Alexandre dit Sandretto - Validated simulation of ODEs October 22, 2020- 2 Initial Value Problem of Ordinary Differential Equations Initial Value Problem of Ordinary Differential Equations
Classical problem Consider an IVP for ODE, over the time interval [0, T ]
y˙ = f (y) with y(0) = y0
n n This IVP has a unique solution y(t; y0) if f : R → R is Lipschitz.
Interval IVP
y˙ = f (y, p) with y(0) ∈ [y0] and p ∈ [p]
Julien Alexandre dit Sandretto - Validated simulation of ODEs October 22, 2020- 3 Initial Value Problem of Ordinary Differential Equations Numerical Integration R t How compute y(t) = y0 + 0 f (y(s))ds ? Goal of numerical integration
I Compute a sequence of time instants: t0 = 0 < t1 < ··· < tn = T
I Compute a sequence of values: y0, y1,..., yn such that
∀i ∈ [0, n], yi ≈ y(ti ; y0) .
Goal of validated numerical integration
I Compute a sequence of time instants: t0 = 0 < t1 < ··· < tn = T
I Compute a sequence of values: [y0], [y1],..., [yn] such that
∀i ∈ [0, n], [yi ] 3 y(ti ; y0) .
Julien Alexandre dit Sandretto - Validated simulation of ODEs October 22, 2020- 4 Problem of integral computation Problem of integral computation
R h Discrete system given by yn+1 = yn + 0 f (y(s))ds R h Bounding of 0 f (y(s))ds If y(s) is bounded s.t. y(s) ∈ [x], ∀s ∈ [0, h], then
Z h f ([x])ds ⊂ [0, h] · [f ]([x]) 0
How bound y(s) ? Complex, it is what we are trying to compute ! We note by [y˜n] ⊃ {y(s), s ∈ [tn, tn+1]}
Julien Alexandre dit Sandretto - Validated simulation of ODEs October 22, 2020- 5 Picard-Lindel¨of Picard-Lindelof¨ (or Cauchy-Lipschitz) Theorem (Banach fixed-point theorem)
Let (K, d) a complete metric space and let g : K → K a contraction that is for all x, y in K there exists c ∈ ]0, 1[ such that d (g(x), g(y)) 6 c · d(x, y) , then g has a unique fixed-point in K. ———— We consider the space of continuously differentiable functions 0 n C ([tj , tj+1], R ) and the Picard-Lindel¨of operator Z t pf (y) = t 7→ yj + f(y(s))ds , with yj = y(tj ) (1) tj
If this operator is a contraction then its solution is unique and its solution is the solution of IVP.
Julien Alexandre dit Sandretto - Validated simulation of ODEs October 22, 2020- 6 Picard-Lindel¨of Interval counterpart of Picard-Lindelof¨
n n With a first order integration scheme that is for f : R → R a n continuous function and [a] ⊂ IR , we have Z a f (s)ds ∈ (a − a)f ([a]) = w([a])f([a]) , (2) a
we can define a simple enclosure function of Picard-Lindel¨of such that def [pf ]([r]) = [yj ] + [0, h] · f([r]) , (3)
with h = tj+1 − tj the step-size. In consequence, if one can find [r] such that [pf ]([r]) ⊆ [r] then [y˜j ] ⊆ [r] by the Banach fixed-point theorem.
Julien Alexandre dit Sandretto - Validated simulation of ODEs October 22, 2020- 7 Picard-Lindel¨of Interval counterpart of Picard-Lindelof¨
~ [yj] We can then build the Lohner 2-steps method: [yj] 1. Find [y˜ ] and h with Picard-Lindel¨of j j [y ] operator and Banach’s theorem j+1
2. Compute [yj+1] with a validated integration scheme: Taylor or Runge-Kutta t tj tj+1 hj
It is important to obtain [y˜j ] and [yj+1] as tight as possible Integration scheme at order higher than one: Taylor for example
Julien Alexandre dit Sandretto - Validated simulation of ODEs October 22, 2020- 8 Integration scheme Integration scheme
Two main approaches:
I Taylor series (Vnode, CAPD, etc.): Pp i [i] p+1 [i] th yj+1 = yj + 1 h f (yj ) + O(h ) with f the i term of serie expansion of f .
O(hp+1) can be easily bounded by the Lagrange remainder of p+1 [p+1] serie s.t. O(h ) = f (ξ), with ξ ∈ [y˜j ], and then p+1 [p+1] O(h ) ∈ f (y˜j )
I Runge-Kutta methods (DynIBEX): yj+1 = Φ(yj , f , p) + LTE, with Φ any RK method and LTE the local truncation error.
Julien Alexandre dit Sandretto - Validated simulation of ODEs October 22, 2020- 9 Integration scheme Runge-Kutta methods s-stage Runge-Kutta methods are described by a Butcher tableau c1 a11 a12 ··· a1s . . . . j . . . . c a a ··· a s s1 s2 ss i b1 b2 ··· bs Which induces the following recurrence:
s ! s X X ki = f tj + ci hj , yj + h ail kl yj+1 = yj + h bi ki l=1 i=1
I Explicit method (ERK) if ail = 0 is i 6 l I Diagonal Implicit method (DIRK) if ail = 0 is i 6 l and at least one aii 6= 0 I Implicit method (IRK) otherwise
Julien Alexandre dit Sandretto - Validated simulation of ODEs October 22, 2020- 10 Integration scheme Explicit methods
Interval extensions
1. Computation of k1 = f (yj ), k2 = f (yj + h · a21 · k1), ... , Pi−1 Ps−1 ki = f (yj + h `=1 ai`k`), ... , ks = f (yj + h `=1 as`k`) Ps 2. Computation of yj+1 = yj + h i=1 bi ki + LTE ⇒ with interval arithmetic (natural extension)
Example of HEUN 0 0 0 1 1 0 1/2 1/2
[k1] = [f ]([yj ]), [k2] = [f ]([yj ] + h[k1]), [yj+1] = [yj ] + h([k1] + [k2])/2
Julien Alexandre dit Sandretto - Validated simulation of ODEs October 22, 2020- 11 Integration scheme Implicit Schemes
Example of Radau IIA 1/3 5/12 −1/12 1 3/4 1/4 3/4 1/4
[k1] = [f ]([yj ] + h(5[k1]/12 − [k2]/12)), [k2] = [f ]([yj ] + h(3[k1]/4 + [k2]/4) We need to solve this system of implicit equations !
Julien Alexandre dit Sandretto - Validated simulation of ODEs October 22, 2020- 12 Integration scheme Solve implicit scheme with a contractor point of view
k1 is the approximate of f (y(tj + h/3)), but by construction y(tj + h/3) ∈ [y˜j ], then [k1] ⊂ f ([y˜j ]) (same for k2)
Algorithm based on contraction
Require: f , [y˜j ], [yj ], LTE [k1] = [f ]([y˜j ]) and [k2] = [f ]([y˜j ]) while [k1] or [k2] improved do [k1] = [k1] ∩ [f ]([yj ] + h(5[k1]/12 − [k2]/12)) [k2] = [k2] ∩ [f ]([yj ] + h(3[k1]/4 + [k2]/4) end while [yj+1] = [yj ] + h(3[k1] + [k2])/4 + LTE return [yj+1]
Julien Alexandre dit Sandretto - Validated simulation of ODEs October 22, 2020- 13 Integration scheme How to compute the LTE ?