Graphics Reference
In-Depth Information
integration since we are approximating the solution
q ( t )= t
0
f ( q ( τ )) dτ,
which has an integral in it.
The simplest time integration method is forward Euler , based on the
first one-sided finite difference formula we saw:
q n +1
q n
∂q
∂t ( t n )+ O t ) .
=
Δ t
Plugging in the differential equation and rearranging gives the formula for
the new value q n +1 based on the previous value q n :
q n +1 = q n tf ( q n )
This is only first-order accurate, however.
This topic makes use of a few more advanced time integration schemes,
such as Runge-Kutta methods. The Runge-Kutta family gets higher-order
accuracy and other numerical advantages by evaluating f at several points
during a time step. For example, one of the classic second-order accurate
Runge-Kutta methods can be written as
q n +1 / 2 = q n + 2 Δ tf ( q n ) ,
q n +1 = q n tf ( q n +1 / 2 ) .
One of the better third-order accurate Runge-Kutta formulas is
k 1 = f ( q n ) ,
k 2 = f ( q n + 2 Δ tk 1 ) ,
k 3 = f ( q n + 4 Δ tk 2 ) ,
q n +1 = q n + 9 Δ tk 1 + 9 Δ tk 2 + 9 Δ tk 3 .
Note that these are not easy to derive in general!
Many time integration schemes come with a caveat that unless Δ t is
chosen small enough, the computed solution exponentially blows up despite
the exact solution staying bounded. This is termed a stability time-step
restriction . For some problems, a time integration scheme may even be
unstable no matter how small Δ t is: both forward Euler and the second-
order accurate Runge-Kutta scheme above suffer from this flaw in some
cases. The third-order accurate Runge-Kutta scheme may be considered
the simplest general-purpose method as a result.
Search WWH ::




Custom Search