The Asynchronous Leapfrog Method as a Stiff ODE Solver

The asynchronous leapfrog method together with a simple adaptive step-size control is tested with a well-known stiff initial value problem, which is a simplified model for an expanding flame ball. It describes the flame ball as going through three phases: slow growth, very fast expansion, and a final phase of constant size. No constant time step integrator can run through these phases in reasonable time and with normal 64-bit arithmetic. This can be considered a practical characterization of stiffness.
This Demonstration shows that an extremely simple integrator (explicit, second-order, only one evaluation of the right-hand side per time step) and a very simple step-size control master the challenge of running through the process with reasonable accuracy.
Three plots are provided to support this claim. The first one shows the computed solution in red and the much more accurate solution obtained from NDSolve superimposed in blue. We observe that the graphical resolution prevents us from clearly differentiating between the two solutions. The second plot shows the difference between the solutions in logarithmic representation and gives a clear picture of the integration error. The last plot shows how the time step evolves under adaptive step-size control for the method parameters as set via the second and third slider. These method parameters are explained in the Details section.
The default values are reasonable for all cases and variability is provided only for the investigative mind. The first slider is by far the most important. It controls the steepness of the expansion phase and thus, in a sense, the stiffness of the problem. In more general terms, it defines the initial value problem to be solved.


  • [Snapshot]
  • [Snapshot]


This is the asynchronous leapfrog integrator for fixed step size in fully explicit form:
The initial value problem under consideration is , . The discrete trajectory gives values for the times . In addition to these values, the asynchronous leapfrog method gives velocities that are defined by the time-stepping algorithm upon initialization as .
Let and let , , and be given. Set , , , , , . Writing the step algorithm as a value change of the fixed variables , , , it becomes shorter and more symmetrical: , , , , . This is the form used in this Demonstration.
Although in our case is simply real-valued, the algorithm only assumes that its values belong to some real affine space. Our adaptive step control algorithm assumes that the underlying vector space (to which the values of belong) is a normed linear space. With a step we associate the kink . For this dimensionless quantity, we specify a tolerated maximum value , for example, 1/1000. If the kink exceeds this value, this is taken as a sign that the terrain is getting more difficult. We therefore discard the present value of and reinitialize it as , and we decrease the step size by multiplying it by , for example, . If the kink is found to be smaller than , this is taken as a sign that the terrain is getting easier, and we simply increase the step size by multiplying it with . Computing the kink does not entail an evaluation of . However, in the case of an objectionably large kink, we have to reinitialize, which does entail an evaluation of . Of course, it is not mandatory to couple the parameters for treating the easy terrain and the difficult terrain in exactly the way chosen here.
Snapshot 1: initial value set for a quite flat solution
Snapshot 2: initial value set for a very steep solution
[1] U. Mutze. "An Asynchronous Leap-Frog Method." (May 16, 2013) www.ma.utexas.edu/mp_arc/c/08/08-197.pdf.
[2] U. Mutze. "An Asynchronous Leap-Frog Method." (May 16, 2013) (Updated version of [1]) www.ulrichmutze.de/articles/leapfrog4.pdf.
[3] L. Shampine and S. Thompson. "Stiff Systems." Scholarpedia. (May 16, 2013) www.scholarpedia.org/article/Stiff_systems.
    • Share:

Embed Interactive Demonstration New!

Just copy and paste this snippet of JavaScript code into your website or blog to put the live Demonstration on your site. More details »

Files require Wolfram CDF Player or Mathematica.

Mathematica »
The #1 tool for creating Demonstrations
and anything technical.
Wolfram|Alpha »
Explore anything with the first
computational knowledge engine.
MathWorld »
The web's most extensive
mathematics resource.
Course Assistant Apps »
An app for every course—
right in the palm of your hand.
Wolfram Blog »
Read our views on math,
science, and technology.
Computable Document Format »
The format that makes Demonstrations
(and any information) easy to share and
interact with.
STEM Initiative »
Programs & resources for
educators, schools & students.
Computerbasedmath.org »
Join the initiative for modernizing
math education.
Step-by-Step Solutions »
Walk through homework problems one step at a time, with hints to help along the way.
Wolfram Problem Generator »
Unlimited random practice problems and answers with built-in step-by-step solutions. Practice online or make a printable study sheet.
Wolfram Language »
Knowledge-based programming for everyone.
Powered by Wolfram Mathematica © 2017 Wolfram Demonstrations Project & Contributors  |  Terms of Use  |  Privacy Policy  |  RSS Give us your feedback
Note: To run this Demonstration you need Mathematica 7+ or the free Mathematica Player 7EX
Download or upgrade to Mathematica Player 7EX
I already have Mathematica Player or Mathematica 7+