Geoscience Reference
In-Depth Information
Assuming that
φ
1 and
φ
i are related by
i
φ
=
c i
φ
+
d i
(4.213)
i
1
i
and substituting Eq. (4.213) into Eq. (4.209) leads to
φ
=
c i + 1
φ
+
d i + 1
(4.214)
i
i
+
1
where
c i + 1
=
a E , i
/(
a P , i
c i a W , i
)
,
d i + 1
= (
b i
+
d i a W , i
)/(
a P , i
c i a W , i
)
(4.215)
Comparing the boundary condition (4.210) with Eq. (4.214) at the first point yields
the coefficients c 2 and d 2 :
c 2
=
a E ,1
/
a P ,1 ,
d 2
=
b 1
/
a P ,1
(4.216)
and then the coefficients c i + 1 and d i + 1 are determined by Eq. (4.215) in the order of
increasing i from 2 to m
1. This is the forward sweep.
At the last grid point, substituting
φ
=
c m
φ
+
d m into the boundary condition
m
1
m
(4.211) yields
φ
= (
b m
+
d m a W , m )/(
a P , m
c m a W , m )
(4.217)
m
i can be obtained using Eq. (4.213) in the order of decreasing i from m to
2. This is the backward sweep.
The Thomas algorithm is a direct solution method; it is particularly economical and
requires only 5 m
Now all
φ
4 operations (multiplications and divisions) for linear problems.
For non-linear problems, the coefficients and source term in Eq. (4.209) are related to
the solution of
φ
, so an iteration procedure is needed. At each iteration step, an initial
guess is given to
φ
at each point, the coefficients and source term are evaluated using
the guessed
φ
, and then the double sweep calculations are performed to obtain the
new value of
at each point. This procedure is repeated until a convergent solution
is reached. However, to obtain the convergent solution, it is necessary that
φ
|
a P , i
| > |
a E , i
|+|
a W , i
|
(4.218)
4.5.2 Jacobi and Gauss-Seidel iteration methods
Jacobi and Gauss-Seidel methods solve the algebraic equations point by point in
a certain order. They can be used in the solution of 1-D, 2-D, and 3-D prob-
lems. Consider the following algebraic equation resulting from a 2-D second-order
Search WWH ::




Custom Search