Professional Documents
Culture Documents
Adaptive Strategies For Numerical Ivps Solvers: Riccardo Fazio
Adaptive Strategies For Numerical Ivps Solvers: Riccardo Fazio
2. local error control based on Richardson local extrapolation, see Bulirsch and Stoer [6] and the treatment
reported by Hairer et al. [13, pp. 228-233];
Introduction
We consider the adaptive strategies used for the numerical integration of initial value problems (IVPs) governed
by systems of ordinary differential equations
du
= f(u) ,
t [t0 , tmax ]
(1)
dt
u(t ) = u ,
0
ISBN:978-988-18210-1-0
2.1
The most common used strategy for the adaptive numerical solution of IVPs is to take into account some kind of
local truncation error control. In the following we recall,
briefly, how this is done in the case of embedded RungeKutta methods. The local error (LE) is defined as the
error made by the numerical method within a single step
LEn+1 = w(tn+1 ) un+1
WCE 2009
dw
= f(w)
(2)
dt
w(t ) = u .
n
n
Note that for a method of order p, we have LE =
O(tp+1 ). Many routines make use of two methods of
different order to estimate the LE: a method of order p
computes a first approximation un+1 and a method of order p > p provides a more accurate approximation u
n+1 ,
so that, we can define
est = u
n+1 un+1
= u
n+1 w(tn+1 ) + [w(tn+1 ) un+1 ]
= O tp+2 + LEn+1 ,
n+1 = u
here we infer
that LE
n+1 w(tn+1 ) is at least
p+2
O t
because we assumed that p > p. Henceforth,
est is an asymptotically correct estimate of the LE for
the lower order method.
The relationship between local and global error (GE) is
given by
GEn+1
= u(tn+1 ) un+1
= u(tn+1 ) w(tn+1 ) + LEn+1 .
= u(tn ) un
= GEn ,
so that, it depends on the analytical stability of the governing system. In other words, at each step the GE is
made by two addends: the GE evolved by the governing system plus the current LE. If the IVP is unstable,
then, no matter the order of the LE, any small error,
like roundoff errors, will grow within the numerical solution. On the contrary, in the case of a stable IVP, the
GE evolution would be damped, that is
ku(tn+1 ) w(tn+1 )k kGEn k ,
and the global error of a method of order p will be an
O(tp ).
2.2
A different way to provide an estimate of the LE is to apply the same method with two different time steps. The
simplest case is to use tn and tn /2. We can compute
the solution yn+1 (tn ) by a single step and yn+1 (tn /2)
by two half-steps. With a method of order p we can define
the extrapolated value
1 p
yn+1 (tn ) yn+1 (tn /2)
2
yn+1 =
1 p
1
2
ISBN:978-988-18210-1-0
which has an order of accuracy p + 1. Now, an extrapolated estimation of the LE can be obtained as
ext = yn+1 yn+1
= yn+1 u(tn+1 ) + u(tn+1 ) yn+1
= O tp+2 + LEn+1 .
In this case, ext is an asymptotically correct estimate of
the LE of the method used with the largest step size.
2.3
In this sub-section, we recall the simple adaptive procedure defined by Jannelli and Fazio [15]. This procedure
applies the monitor function
kyn+1 yn k
,
n
where n is defined by
kyn k if kyn k =
6 0
n =
otherwise ,
n =
(3)
2.4
WCE 2009
For the current step size selection the user should specify a suitable norm and a tolerance . It turns out that
the two cases of a local error control made by two different order methods or an extrapolation algorithm can be
treated together. In fact, our aim would be to get
kerrk
where err can be est or ext. It has been shown by
Shampine [18] that, both in the case when the step is
rejected and repeated or in the case of a successful step,
the largest factor to multiply by the current step size
in order to get the next a successful one is given by
1/(p+1)
.
=
kerrn k
Henceforth, we can use the new step size tn+1 = tn .
As far as the stability and the linearity strategies described above are concerned, their step size selection can
be treated together. The basic guidelines for setting the
step size are given by the algorithm defined by the following steps:
1. Given a step size tn and an initial value yn at
time tn , the method computes a value yn+1 and,
consequently, a monitoring function n by the above
formula;
2. If min n max , then tn is replaced by tn + tn ;
the step size tn is not changed and the next step,
subject to the check at Step 6, is taken by repeating
Step 1 with initial value yn replaced by yn+1 ;
3. If n < min , then tn is replaced by tn +tn and tn
is replaced by tn where > 1 is a step size amplification factor; the next integration step, subject
to the checks at Step 5 and Step 6, is taken by repeating Step 1 with initial value yn replaced by yn+1 ;
4. If n > max , then tn remains unchanged; tn is
replaced by tn , where 0 < < 1 and the next
integration step, subject to the check at Step 5,
is taken by repeating Step 1 with the same initial
value yn ;
5. If tmin tn tmax , return to Step 1; otherwise
tn is replaced by tmax if tn > tmax or by tmin
if tn < tmin , then proceed with Step 1.
6. If tn > tmax , then we set tn = tmax , and tn =
tmax tn1 .
ISBN:978-988-18210-1-0
=
r
2
dt
|r|3
(5)
1
GM m
mv 2
,
2
r
(6)
GmM
x, 2 GmM
y
x2 +y 2 (x2 +y 2 )
x +y 2 (x2 +y 2 )
v1 , v2 ,
T
WCE 2009
In the following, as a specific test problem, we consider the following parameters: the mass of the satellite is taken as unitary, the mass of the larger body is
M = 1.99 1030 kg, and G = 6.67 1011 m3 /(kg
s2 ) is the universal constant. Moreover, we use the
following initial conditions: the initial position is given
by x(0) = 1 AU, y(0) = 0, and the initial velocity is
v1 (0) = 0, v2 (0) = /2 AU/yr .
For the simulations reported below we used, as a basic
one-step method, the classical fourth order Runge-Kutta
method, see for instance Butcher [7, p. 166].
4.1
Linearity control
ISBN:978-988-18210-1-0
WCE 2009
Conclusions
In the introduction we listed the adaptive step size strategies that have been used in literature. Then, we introduced a novel step selection algorithm based on the simple idea that locally all continuous functions can be suitably approximated by a straight line. We remark that the
stability and the linearity approaches can be used anytime the complexity of the problem to be solved calls for a
low complexity numerical implementation of the adaptive
procedure, see the motivations reported by Jannelli and
ISBN:978-988-18210-1-0
WCE 2009
References
[1] C. J. Budd and G. J. Collins. An invariant moving
mesh scheme for the nonlinear diffusion equation.
Appl. Numer. Math., 26:2339, 1998.
[2] C. J. Budd and G. J. Collins. Symmetry based numerical methods for partial differential equations. In
D. F. Griffiths, D. J. Higham, and G. A. Watson, editors, Numerical Analysis 1997, pages 1636, Harlow,
1998. Longman. Pitman Research Notes in Mathematics 380.
[3] C. J. Budd, W. Huang, and R. D. Russell. Moving
mesh methods for problems with blow-up. SIAM J.
Sci. Comp., 17:305327, 1996.
[4] C. J. Budd, B. Leimkuhler, and M. D. Piggott. Scaling invariance and adaptivity. Appl. Numer. Math.,
39:261288, 2001.
[5] C. J. Budd and M. D. Piggott. The geometric integration of scale invariant ordinary and partial differential equation. J. Comput. Appl. Math., 128:399
422, 2001.
[6] R. Bulirsch and J. Stoer. Numerical treatment of ordinary differential equations by extrapolation methods. J. Comput. Appl. Math., 6:1926, 1966.
[13] E. Hairer, S. P. Norsett, and G. Wanner. Solving Differential Equations I: Nonstiff Problems. Springer,
Berlin, 1987.
[14] A. Iserles. A First Course in the Numerical Analysis of Differential Equations. Cambridge University
Press, Cambridge, 1996.
[15] A. Jannelli and R. Fazio. Adaptive stiff solvers at low
accuracy and complexity. J. Comput. Appl. Math.,
191:246258, 2006.
[16] J. D. Lambert. Numerical Methods for Ordinary Differential Systems. Wiley, Chichester, 1991.
[17] D. Sarafyan. Error estimation for Runge-Kutta
methods through pseudoiterative formulas. Techn.
Rep. No 14, Lousiana State Univ., New Orleans,
1966.
[18] L. F. Shampine. Error estimates and control for
ODEs. J. Sci. Comput., 25:316, 2005.
[19] L. F. Shampine and A. Witt. A simple step size
selection algorithm for ODE codes. J. Comput. Appl.
Math., 58:345354, 1995.
[20] C. Vergara and P. Zunino. Multiscale boundary conditions for drug release from cardiavascular stents.
Multiscale Model. Simul., 7:565588, 2008.
[21] J. M. Verner. Explicit Runge-Kutta methods with
estimates of the local truncation error. SIAM J. Numer. Anal., 15:772790, 1978.
[7] J. C. Butcher. The Numerical Analysis of Ordinary Differential Equations, Runge-Kutta and General Linear Methods. Whiley, Chichester, 1987.
[8] J. R. Dormand and P. J. Price. A family of embedded
Runge-Kutta formulae. Num. Math., 8:113, 1980.
[9] W. H. Enright. A new error-control for initial value
solvers. Appl. Math. Comput., 31:588599, 1989.
[10] W. H. Enright. Continuous numerical methods for
ODEs with defect control. J. Comput. Appl. Math.,
125:159170, 2000.
[11] R. Fazio. Numerical scaling invariance applied to the
van der Pol model. Acta Appl. Math., 104:107114,
2008.
[12] E. Fehlberg. Classical fifth-, sixth-, seventh- and
eighth order formulas with step size control. Computing, 4:93106, 1969.
ISBN:978-988-18210-1-0
WCE 2009
Copyright of World Congress on Engineering 2009 (Volume 2) is the property of International Association of
Engineers/Newswood Limited and its content may not be copied or emailed to multiple sites or posted to a
listserv without the copyright holder's express written permission. However, users may print, download, or
email articles for individual use.