
642 An excursion concerning numerical procedures
25.3 A practical method for the elimination of the weak instability
The combination of the results of the previous sections leads to a practical compu-
tational method, which will be outlined now. For the first-order partial differential
equation (25.1) a unique solution is guaranteed whenever the variable ψ is speci-
fied at t = 0. The corresponding difference equation (25.5), however, requires an
arbitrary specification of the variable ψ not only at time t = t
0
= 0 but also at
t = t
1
= t. The initial data for the two times t
0
and t
1
are not harmonized in
any way by the difference equation. This freedom in the choice of the initial data
resulted in the weak instability.
The application of the forward-in-time difference scheme (25.29), in agreement
with the differential equation, requires specification of the variable only for the
time t = 0. The weak instability does not occur in this case, but the numerical
scheme is unstable. Thus we apply equation (25.29) only for the very first time
step.
This suggests that we should use a combination of these two procedures, as will
be explained now. The numerical calculations are started by applying the forward-
in-time difference method for a fraction, say t
=
1
8
t, of the regular time step
t. In this way we calculate with a high degree of stability, without the presence
of the numerical wave, the variable ψ at the time t = t/8. In the second step
the normal solution scheme is applied, using the centered difference quotients with
t
=
1
8
t. In the third step one doubles the time step, i.e. t
=
1
4
t, thereby
always starting from n = 0. In the next step we use t
=
1
2
t until, in the
fifth step with t
= t,thevalueofψ at time step n = 2 is obtained. The
procedure, which is also known as the leap-frog method, is shown schematically
in Figure 25.3. By means of this successive initialization the phenomenon of the
weak instability is suppressed very efficiently. Much more could be said about this
and other calculation procedures, but we have given sufficient evidence that great
care must be taken in applying finite-difference schemes. Later we will discuss an
entirely different instability, which is associated with the numerical treatment of
the nonlinear advection equation.
25.4 The implicit method
It is possible to give a numerical scheme for the solution of (25.1) that is abso-
lutely stable. In this case we proceed as follows. Time and spatial derivatives are
discretized by
∂ψ
∂t
=
ψ
n+1
j
− ψ
n
j
t
∂ψ
∂x
=
1
2
ψ
n+1
j+1
− ψ
n+1
j−1
2 x
+
ψ
n
j+1
− ψ
n
j−1
2 x
(25.38)