48 Computational Modelling in Hydraulic and Coastal Engineering
Rearranging for the unknown f i
n+1
, the explicit solution is written as
f
f
c
t
x
f
f
i
n
i
n
o
i
n
i
n
+
−
= −
−
(
)
1
1
∆
∆
(3.36)
Equation 3.36 produces a numerical solution where the initial form of f(x,t)
is translated correctly with speed c o , but the values of f(x,t) undergo a certain
degree of diffusion (decrease in magnitude with simultaneous spreading in
space), as if they were controlled by a parabolic equation. Thus the solution
presents a diffusive behaviour, as shown schematically in Figure 3.12.
However, the algebraic approximation of the equation can be re-written,
after addition and subtraction of identical terms as
f
f
c
t
x
f
f
c
x
t
x
i
n
i
n
o
i
n
i
n
o
+
+
−
= −
−
(
)+

 

 
1
1
1
2
2
∆
∆
∆
∆
∆
( ) )
2
1
1
2
f
f
f
i
n
i
n
i
n
+
−
−
+
(
)
(3.37)
This is a finite differences algebraic approximation of a mixed-type equation,
containing both the terms of the first-order hyperbolic and the second-order
parabolic equations. Both the hyperbolic and parabolic parts are approximated by forward in time and central in space finite differences. The artificial
diffusion coefficient of the parabolic part of the equation is equal to c
x
o
∆
2
.
Thus, when using forward time differences and backward space differences,
instead of solving the hyperbolic equation, we actually solve a different equation and that fact introduces a numerical error known as numerical diffusion.
Δt
Time t
x-axis
f(x,t)
c o
f(x,t + Δt)
Δx = c o Δt
e signal f(x,t) diffuses as it propagates
Figure 3.12 Numerical ‘diffusion’ of a propagating signal.
Précédent

- 61/302

Suivant