Systems of ordinary differential equations

Here is a simple but somewhat amusing system of two ode's. The equations are


Viewing this page correctly requires a Web browser that supports Java applets (such as Netscape 2.0 or later). Since your browser does not seem to support Java, instead of an interactive page, only static pictures will be provided.

and the initial conditions are

The graphs on the left show the first and second components as a function of time (x is the blue one, y is red), the graph on the right is the phase plane plot. You can edit the fields below to try your own variations.

There is also available a short description of the syntax that you can use. All fields accept mathematical expressions, not just numbers.

Stiff equations

Here is an example of a system of differential equations whose numerical solution demonstrates a phenomenon called "stiffness". The equations are


You should use a Java capable browser to view this page

and the general exact solution (unless you've changed the equations) is


You should use a Java capable browser to view this page

The term with the exponent -10000*t contributes very little to the solution. Its presence, however, causes convergence problems for explicit solution methods such as Runge-Kutta and Explicit Euler.

Try to compute the solution using different algorithms and different number of steps. How many steps does Runge-Kutta need to converge to the correct solution?

Implicit methods are needed to compute the solution with a reasonable amount of work. Try also implicit Euler's method, which is the simplest of this class of methods.


You should use a Java capable browser to view this page

For a more thorough discussion of stiff systems see e.g. "Introduction to Numerical Analysis" by J. Stoer and R. Bulirsch (Springer-Verlag).


Back to my home page

Last updated July 1, 1996. Copyright © 1996 by Harri Ojanen.