Geoscience Reference
In-Depth Information
If Equation (6.10) is used when the velocity is negative and Equation (6.11) is used
when the velocity is positive, the first derivative is computed using an “upstream
method,” since in both cases no downstream information is used.
Adding Equation (6.7) and Equation (6.8), we obtain
*
*
*
*
CCC
x
−+ +
2
2
=
C
x
i
+
1
i
i
1
2
0
()
x
(6.12)
2
2
i
which is the finite-difference form of the second spatial derivative, discretized with
a second-order truncation order.
In the next subsection, the stability criteria for some of these discretizations are
analyzed. It will be shown that central differences for first-order derivatives generate
unstable algorithms, and it will be shown that truncation error is not the unique
aspect to take into account for estimating the accuracy of a numerical algorithm.
6.2.5
S TABILITY AND A CCURACY
6.2.5.1
Introductory Example
The exponential decay equation is considered first as an example because it illustrates
the main features of stability without having to deal with spatial derivatives. This
differential equation reads
C
t
=−
α
C
(6.13)
where C is a generic concentration and
α
is a positive constant. The analytical solution
to this problem is
CC
=
0 exp(
α
t
)
where
C 0
is the initial concentration at time
t
=
0
. If the previous equation is
discretized in time, we obtain
t
+
t
t
CC
t
) *
t
=−
(
α
C
As explained previously, we still must decide at which time level the term on
the right-hand side has to be evaluated. Starting with an explicit approach, such that
, we can solve the equation directly for C at the new time level:
t
*
=
t
t
+
t
t
t
t
CC tC
=−
α
=−
(
1
α
t C
)
 
 
Search WWH ::




Custom Search