peaceman rachford paper

14
J. Soc. INDUST. APPL. MATH. Vol. 3, No. 1, March, 1955 Printed in U.S.A. THE NUMERICAL SOLUTION OF PARABOLIC AND ELLIPTIC DIFFERENTIAL EQUATIONS* D. W. PEACEMAN AND H. H. RACHFORD, JR. Introduction. Numerical approximations to solutions of the heat flow equation in two space dimensions may be obtained by the stepwise solution of an associated difference equation. Two types of difference equations have previously been studied: (1) explicit difference equations, which are simple to solve, but which require an uneconomically large number of time steps of limited size, and (2) implicit difference equations, which do not limit the time step but which require at each time step the solution by iteration of large sets of simultaneous equations. In this paper, an alternating-direction implicit procedure is presented that requires the line-by-line solution of small sets of simultaneous equa- tions that can be solved by a direct, non-iterative method. Analysis of the procedure shows it to be stable for any size time step and to require much less work than other methods that have been studied. As a practical test, the new procedure was used to solve the heat flow equation with boundary conditions for which the formal solution is known; the two solutions were in good agreement. In addition, the alternating-direction implicit method is applicable to the iterative solution of two-dimensional steady-state problems. In a practical test, rapid convergence for the solution of Laplace’s equation in a square was obtained by using a suitable set of iteration parameters which were easily calculated. An analysis is presented that shows the method to require about (2 log N)/N as many calculations as the best previously known iterative procedure for solving Laplace’s equation, where N is the number of points for which the solution is computed. In the first part of the paper, the numerical solution of unsteady-state problems in two dimensions is discussed. For illustrative purposes, only the simplest type of problem is considered, that of unsteady-state heat flow in a square. In the second part of the paper, the numerical solution of steady-state problems in two dimensions is discussed. Again, only the simplest type problem is considered, namely, the solution of Laplace’s equation in a square. In both parts of the paper, the analyses will be per- formed for special boundary conditions. These analyses can, in many cases, be extended in a straightforward manner to problems having different boundary conditions. * Received by the editors October 18, 1954. f Presented to the American Mathematical Society, August 31, 1954. 28 Downloaded 04/05/16 to 130.101.92.171. Redistribution subject to SIAM license or copyright; see http://www.siam.org/journals/ojsa.php

Upload: himel-barua

Post on 11-Jul-2016

10 views

Category:

Documents


0 download

DESCRIPTION

This paper in one of the ground breaking paper in solving hyperbolic equations

TRANSCRIPT

Page 1: Peaceman Rachford Paper

J. Soc. INDUST. APPL. MATH.Vol. 3, No. 1, March, 1955

Printed in U.S.A.

THE NUMERICAL SOLUTION OF PARABOLIC AND ELLIPTICDIFFERENTIAL EQUATIONS*

D. W. PEACEMAN AND H. H. RACHFORD, JR.

Introduction. Numerical approximations to solutions of the heat flowequation in two space dimensions may be obtained by the stepwise solutionof an associated difference equation. Two types of difference equationshave previously been studied: (1) explicit difference equations, which aresimple to solve, but which require an uneconomically large number oftime steps of limited size, and (2) implicit difference equations, which donot limit the time step but which require at each time step the solutionby iteration of large sets of simultaneous equations.

In this paper, an alternating-direction implicit procedure is presentedthat requires the line-by-line solution of small sets of simultaneous equa-tions that can be solved by a direct, non-iterative method. Analysis of theprocedure shows it to be stable for any size time step and to require muchless work than other methods that have been studied. As a practical test,the new procedure was used to solve the heat flow equation with boundaryconditions for which the formal solution is known; the two solutions werein good agreement.

In addition, the alternating-direction implicit method is applicable to theiterative solution of two-dimensional steady-state problems. In a practicaltest, rapid convergence for the solution of Laplace’s equation in a squarewas obtained by using a suitable set of iteration parameters which wereeasily calculated. An analysis is presented that shows the method to requireabout (2 log N)/N as many calculations as the best previously knowniterative procedure for solving Laplace’s equation, where N is the numberof points for which the solution is computed.In the first part of the paper, the numerical solution of unsteady-state

problems in two dimensions is discussed. For illustrative purposes, onlythe simplest type of problem is considered, that of unsteady-state heat flowin a square. In the second part of the paper, the numerical solution ofsteady-state problems in two dimensions is discussed. Again, only thesimplest type problem is considered, namely, the solution of Laplace’sequation in a square. In both parts of the paper, the analyses will be per-formed for special boundary conditions. These analyses can, in many cases,be extended in a straightforward manner to problems having differentboundary conditions.

* Received by the editors October 18, 1954.f Presented to the American Mathematical Society, August 31, 1954.

28

Dow

nloa

ded

04/0

5/16

to 1

30.1

01.9

2.17

1. R

edis

trib

utio

n su

bjec

t to

SIA

M li

cens

e or

cop

yrig

ht; s

ee h

ttp://

ww

w.s

iam

.org

/jour

nals

/ojs

a.ph

p

Page 2: Peaceman Rachford Paper

NUMERICAL SOLUTION OF DIFFERENTIAL EQUATIONS 29

The theoretical aspects of the procedures discussed here are treated ingreater detail in a companion paper by Douglas [5].

SOLUTION OF THE HEAT FLOW EQUATION

The problem which is considered is that of unsteady-state heat flow in asquare, wherein the boundaries are maintained at zero temperature andthe square initially has a temperature of unity. The heat flow equation is

02T 02T cOT(1)OX Oy Ot

where T is the temperature, x and y are the distances from the center of thesquare in the two perpendicular directions, and is the time. The boundaryconditions are

(2)

Ix= 1, T=0.

Ix --1, T 0.

ly= 1, T=0.

[,y --1, T 0.

and the initial condition is

(3) t=0, T= 1.

Because of symmetry, only a quarter of the square need be considered, inwhich case the boundary conditions become

(4)

0,OT

-0.Ox

x: 1, T=O.

[y =0, -0.

y 1, T=0.

Background. In this section, numerical methods already developed forthe solution of the heat flow equation are discussed in some detail in orderto provide background for the description of the new method, and also inorder to develop several equations that will be useful later.

Numerical procedures for the solution of equation (1) fall into twocategories, explicit and implicit. One explicit scheme for the solution usesthe following difference equation"

Dow

nloa

ded

04/0

5/16

to 1

30.1

01.9

2.17

1. R

edis

trib

utio

n su

bjec

t to

SIA

M li

cens

e or

cop

yrig

ht; s

ee h

ttp://

ww

w.s

iam

.org

/jour

nals

/ojs

a.ph

p

Page 3: Peaceman Rachford Paper

30 D. W. PEACEMAN AND H. H. RACHFORD JR.

T,.,,,+- T,.,,, T_,.,, 2T,i,,, -t- T+,.,,,

()T,_, 2T,,+ (Ay)

where i, j, and n are the indices in the x, y, and directions, respectively.If we choose the mesh so that Ax Ay, and define

(ax) (ay)(6)At At

then the unknown temperatures at the n 1 time step may be solved forexplicitly by the equation

(7) T,,+ T,,. + [T_,,. + T+,,. + T,_, T,+,. 4T,,].P

The stability of this scheme will be analyzed by a procedure very similarto that used by O’Brien, Hyman, and Kaplan [4]. Assume that there existsan error e,, at each mesh point. It is easily shown for linear problems withconstant coefficients that these errors obey the same difference equationthat is used to obtain the numerical solution. Then, for the explicit schemedescribed above,

(8) e,,.+ e., _1 [ei_,,. + e,i, + e,i-, W e,i+, 4e,,].P

Because e obeys both the difference equation (8) and the boundary condi-tions (4), it may be expanded in a finite double series of orthogonal func-tions that also satisfy both the difference equation (8) and the boundaryconditions, namely

--1

where (2p W 1)/2, q (2q W 1)/2, and N is the number of in-tervals in each of the x- and y-directions. Thus N 1/5x 1lAy. Sub-stituting equation (9) into equation (8) and examining each term in theseries separately shows that

1o) +p

or

A,q,n p 2

For stability, this ratio must have an absolute value less than or equal tounity for all p and q. This requires that

Dow

nloa

ded

04/0

5/16

to 1

30.1

01.9

2.17

1. R

edis

trib

utio

n su

bjec

t to

SIA

M li

cens

e or

cop

yrig

ht; s

ee h

ttp://

ww

w.s

iam

.org

/jour

nals

/ojs

a.ph

p

Page 4: Peaceman Rachford Paper

NUMERICAL SOLUTION OF DIFFERENTIAL EQUATIONS

(12) --1<1 4(sin ,AX q:y)p 2 "t- sin < 1.

The right-hand inequality is trivial, while the left-hand inequality is satis-fied if

(13) p -> 4.

The restriction on the size of the time step is, then,

(14) At < (Ax) 14 4N"

Thus, a total of 4Nt time steps are required to calculate the solution totime t. Since 7 arithmetic operations are required for each of the N pointsat each time step, a total of 28 N4t operations is necessary for the completesolution. For example, if it is desired to carry out the solution to time

1.5, when T is everywhere less than 0.001,420,000 operations are re-quired for a ten-by-ten net; the situation rapidly becomes worse for a finermesh,.

It has been shown [4] for the heat flow equation in one dimension thatthe restriction on the size of At arising from stability can be removed bythe use of .an implicit procedure in which the second derivatives are ap-proximated by second differences evaluated in terms of the unknown tem-peratures, Tn+l. An extension of this idea to the problem in two dimensionsyields the following equation:

At(15)

A derivation similar to the preceding one shows that

(16) A,q,,+ 1A,q, 1+4(sinhx;2 + sinks)"

For all values of p, this ratio has an absolute value less than unity, so thatthe procedure is stable for all size time steps.Other stable implicit procedures similar to equation (15) might be pro-

posed. However, they lead to large sets of N linear simultaneous equationswith N: unknowns. In particular, the simultaneous equations that arisefrom Equation (15) may be written as follows:

T_,.,+ - T+1,’,+I -[- T,._,.+I T,.+I,.+I(17)

(4 - p)T,,,+ -pT,,,, (0 <= n <= N- 1).

Dow

nloa

ded

04/0

5/16

to 1

30.1

01.9

2.17

1. R

edis

trib

utio

n su

bjec

t to

SIA

M li

cens

e or

cop

yrig

ht; s

ee h

ttp://

ww

w.s

iam

.org

/jour

nals

/ojs

a.ph

p

Page 5: Peaceman Rachford Paper

3 D. yr. PECEM.N AND H. H. RACHFORD JR.

Solution of these equations by an elimination procedure is out of thequestion, since the labor involved is roughly proportional to (N2)3. Fortu-nately, iterative methods are quite successful for solving simultaneousequations of this type. Frankel [3] has examined the rates of convergenceof several methods of iterating the Laplace difference equation (which maybe obtained from equation (17) by setting p 0) and found the best methodto be the extrapolated Liebmann method (also known as the successiveoverrelaxation method). The authors, using Frankel’s analysis of con-vergence, examined several methods of iterating equation (17) and foundthe extrapolated Liebmann method to be the best for these equations also.This process may be written:

T(m/l) rp(m) rrr(m+l) r/(m) rr(m-{-1)

(18)TCm) TCm)- ,.-+1.,+1 (4 -{- p) ,.i.,,+ -{"

where the superscript, m, is the number of iteration stages already carriedout, and is the relaxation factor, chosen for the maximum rate of con-vergence. The analysis of convergence is the same as that given by Frankelfor the Laplace difference equation, except that the boundary conditions(4) are not the same as those used by Frankel. If this difference in boundaryconditions, as well as the presence of p, is taken into account, the optimuma is found to be the smaller root of

(19) 2u- (4 + p)a+ 1 0

where

(20) u 2 cos - - 24N

In each step of the iteration, the magnitude of every error component isdecreased at worst by a factor, K*, which is the largest eigenvalue of thedifference operator (18). This eigenvalue is found to be

(21) K* (4 -t- p) 1.

Solving for a and K*, we obtain

4 -- p (8p -- p2 ..}_ 47r2/N2)l/2(22)

(23) K* 1 --(4 + )(8p + p + 4/N)/ (8p + p)8

If the iteration is continued until all errors are reduced by a factor of 10-,the number of cycles of iteration will be approximately

(24) v/log0 (l/K*).

Dow

nloa

ded

04/0

5/16

to 1

30.1

01.9

2.17

1. R

edis

trib

utio

n su

bjec

t to

SIA

M li

cens

e or

cop

yrig

ht; s

ee h

ttp://

ww

w.s

iam

.org

/jour

nals

/ojs

a.ph

p

Page 6: Peaceman Rachford Paper

NUMERICAL SOLUTION OF DIFFERENTIAL EQUATIONS 33

In each iteration, 7N arithmetic operations must be performed. Conse-quently,

7vN/logo (l/K*)

operations are required for each time step.In any case where an implicit procedure is used, p will be considerably

less than 4, inasmuch as the explicit procedure may be used for p => 4. Asa minimum estimate of the number of iterations required, we may con-sider the case of p 1, with N sufficiently large that the term containingit may be ignored. Then K* 0.25, and 5 cycles of iteration are requiredto reduce the errors by a factor of 10-. For larger time steps, correspondingto smaller values of p, more cycles of iteration are required.

Alternating-direction implicit method. As was shown in the precedingsection, when the implicit procedure is set up with both of the secondderivatives replaced by second differences evaluated in terms of the un-known values of T, large sets of simultaneous equations are formed, whichcan be solved, practically, only by iteration. If, however, only one of thesecond derivatives, say 02T/Ox2, is replaced by a second difference evalu-ated in terms of the unknown values of T, while the other derivative,O2T/Oy, is replaced by a second difference evaluated in terms of knownvalues of T, sets of simultaneous equations are formed that can be solvedeasily without iteration. These equations are implicit in the x-direction.If the procedure is then repeated for a second time step of equal size, withthe difference equations implicit in the y-direction, the overall procedurefor the two time steps is stable for any size time step.

Thus, two difference eqiations are used, one for the first time step, theother for the second time step:

T..=,+I Ti.j.=, Ti_l,.=,+l 2T..=,+1 - T+I..=,+(x)

(25)T.-I. 2T.. Ti..+.+ (Ay)

T..+: T...+ T_..:+ 2T..:,+ T+..+at (x)

(6)T._.+ 2T..:+: T.+.+

(ny)

These equations may be arranged in the following form, more suitable forcalculation.

Dow

nloa

ded

04/0

5/16

to 1

30.1

01.9

2.17

1. R

edis

trib

utio

n su

bjec

t to

SIA

M li

cens

e or

cop

yrig

ht; s

ee h

ttp://

ww

w.s

iam

.org

/jour

nals

/ojs

a.ph

p

Page 7: Peaceman Rachford Paper

3 D. W’. PEACEMAN AND H. . RACI-IFORD, JR.

Ti,i-l,2n+2 (2 - p)Ti,i,2n+2 2,_ Ti,i+l,2n+2(28)

--Ti-l,i,2n+l (2- p)Ti,i,2,+- Ti+,’,2"+1.

Use of equation (27) or (28) at each time step leads to N sets of N si-multaneous equations of the form

BoTo CoT Do,

(29) ArTr_l + BrTr -t- CrTr+ Dr (1 __< r -< N 2),

AN_T_ -[- B_T_ Dv-1.

The solution of these equations may be obtained in a straightforwardmanner. Let

(30) {w0 B0,

wr-- Br- Arbr_ (1 -< r =< N- 1),

br- Cr (0 =< r-< N- 2).Wr

(31)

and

(32)

The solution is

(33)

Dog0--

00

gr-- (t -< r __< N- 1).Wr

(0_<r =<N- 2).

Thus, w, b, and g are computed in order of increasing r, and T is computedin order of decreasing r. Examples of the use of this method of solving equa-tions (29) for the solution of one-dimensional flow problems, as well as aproof, by matrix algebra, of equations (30) to (33) are given in a recentarticle by the authors [1].

Stability. The stability of the procedure may be demonstrated by aderivation similar to that leading to equation (10). The following equationsare obtained"

(34) A,q,.+[2 cospAx- (2 + p)] A,q,[-2 costqAy + (2 p)]

(35) Ap,q,.,+2[2cosqAy- (2 + p)] A,q,n+l[-2 cosAx + (2 p)].

If equation (27) were used for every time step, the amplification factor foreach step would be

Dow

nloa

ded

04/0

5/16

to 1

30.1

01.9

2.17

1. R

edis

trib

utio

n su

bjec

t to

SIA

M li

cens

e or

cop

yrig

ht; s

ee h

ttp://

ww

w.s

iam

.org

/jour

nals

/ojs

a.ph

p

Page 8: Peaceman Rachford Paper

NUMERICAL SOLUTION OF DIFFERENTIAL EQUATIONS 35

(36) A,,q,2n+l p 4 sin (q Ay/2)Ap,q,2n p 4 sin (Ax/2)

For some values of p, q, and p, this ratio has an absolute value considerablygreater than unity. Hence, such a procedure is highly unstable. Whenequations (27) and (28) are used alternately, however, the amplificationfactor for the two-step procedure is

(37) Ap, ,2n+2

Ap,q,2np 4 sin (fAx/2) p 4 sin (qAy/2)p + 4 sin (fl,Ax/2) X p + 4 sin (qAy/2)

This ratio has an absolute value less than unity for all p, q, and p. Note thatit is necessary that p and, therefore, At, be the same for two time steps.

Work requirement. For the N simultaneous equations resulting from theuse of equation (27) or (28) on a single line, the solution by equations (30)to (33) require approximately 9N arithmetic operations. For each timestep, 9N operations must be performel. We have seen that, for the extra-polated Liebmann method, with p 1, at least five iterations are neces-sary, each requiring 7N operations. Therefore, for p 1, the best itera-tire procedure known requires about four times as much work as thealternating-direction method. For smaller values of p, the iterative pro-cedure compares even more unfavorably, as will be seen in the numericalexample below. If p is kept constant, the number of operations is 9pN4t.However, it is not necessary that a constant time step be used [6].The alternating direction implicit method requires a relatively small

increase in storage capacity over the extrapolated Liebmann method. Thelatter method requires approximately N registers of storage, whereas thenew method requires approximately N N registers.

llumerical example. The alternating-direction implicit method wastested by carrying out a numerical solution of equations (1), (3) and (4)on an I.B.M. Card Programmed Calculator, wired to perform eight-digit,floating-decimal arithmetic. Because of storage limitations, fourteen in-crements were used in each of the x- and y-directions. Thirty-six time stepswere used; small steps were used at the beginning and continually largersteps were used as the solution progressed. It was necessary, of course,that each size time step be used an even number of times. The schedulefollowed is shown in Table 1. Included in the table is the value of p associ-ated with each At, as well as the value of 7, the number of iterations thatwould have been required for each time step if the extrapolated Liebmannmethod had been used. The quantity is calculated from equations (23)and (24) using v 3.

Results of the numerical calculation at even time steps were comparedwith the exact solution of the problem at 0.06, 0.1, 0.2, 0.4, 0.8, and

Dow

nloa

ded

04/0

5/16

to 1

30.1

01.9

2.17

1. R

edis

trib

utio

n su

bjec

t to

SIA

M li

cens

e or

cop

yrig

ht; s

ee h

ttp://

ww

w.s

iam

.org

/jour

nals

/ojs

a.ph

p

Page 9: Peaceman Rachford Paper

36 D. . PEACEMAN AND H. H. RACHFORD JR.

1.5. The exact solution was calculated by the series given in Carslaw andJaeger [2]. The maximum error found was 0.0042 at 0.1. It may beseen that this error is due to truncation by repeating the calculation witha smaller value of zt and comparing the errors. First, the exact solution at

0.06 was taken for the initial condition, and the solution at 0.1was calculated in two steps using At 0.02. The maximum error was0.0032. Then, with the same initial condition, the solution at 0.1 wascalculated in ten steps, using At 0.004. The maximum absolute error inthis case was only 0.0004.

It is possible to make an exact comparison between the labor involvedin using the alternating-direction implicit method for the solution of thisproblem and that which would have been involved if either the explicitmethod or the implicit method with iteration had been used. Since 36time steps were used, the alternating-direction method required approxi-mately (36)(9)(14) 63,500 arithmetic operations. The explicit procedurewould have required about 28(14)4(1.5) 1,610,000 operations, or about25 times as much work. The implicit procedure, with extrapolated Lieb-mann iteration, would have required for each of the 36 time steps thenumber of iterations, 7, shown in Table 1, or a total of 326 iterations. Thisimplicit procedure, then, would have required about (326) (7) (14)2447,000 arithmetic operations, or about seven times as much work.

SOLUTION OF LAPLACE’S EQUATION

In this section, the numerical solution of steady-state heat flow anddiffusion problems in two dimensions is discussed. The typical problemconsidered here is that of determining the temperature distribution in asquare in which two opposite faces are at zero temperature while the re-maining two faces have a temperature of unity. Because of symmetry, it is

TABLE 1.--Time Steps Used in the Solution of the Heat Flow Problem.

0.001.002.003.005:01.02.03.05.1.25

No. of times used

6 54 224242462

.102

.551

.701

.0200.51020.25510.17010.10200.051020.02041

33457911131721

Dow

nloa

ded

04/0

5/16

to 1

30.1

01.9

2.17

1. R

edis

trib

utio

n su

bjec

t to

SIA

M li

cens

e or

cop

yrig

ht; s

ee h

ttp://

ww

w.s

iam

.org

/jour

nals

/ojs

a.ph

p

Page 10: Peaceman Rachford Paper

NUMERICAL SOLUTION OF DIFFERENTIAL EQUATION 37

again sufficient to consider only one-quarter of the square. The differentialequation that applies is Laplace’s equation"

OT. OT(38) -- 0

The boundary conditions are

x=O,

(39)

OT-0

Ox

x=l, T=O

OTy =0, -0

Oy

y-l, T-1.

Iteration by extrapolated Liebmann method. The conventional numericalsolution of Laplace’s equation consists in approximating it by the differenceequation

(40) Ti-l,j T+I,j Ti,_ T,+- 4Ti, 0

and iterating to the solution of the resulting simultaneous equations. Aspointed out above, Frankel [3] has examined the rates of convergence ofseveral methods of iterating the Laplace difference equation and found theextrapolated Liebmann method to be the best. The iteration process maybe represented by equation (18) with p 0, so that equations (22) and(23) may be used to calculate the optimum relaxation factor and the cor-responding rate of convergence. These are"

2 -/N(41) a4

(42) K* 1 ’/N.

The number of cycles of iteration required to reduce all errors by a factorof 10 will be approximately

(43) q 2.3vN/r.

Since 7N arithmetic operations must be performed in each iteration, atotal of approximately 5vN operations is necessary.

Iteration by alternating-direction implicit method. The alternating-direction implicit method may also be used to iterate to the solution ofLaplace’s equation. In this case, each stage of iteration may be regarded

Dow

nloa

ded

04/0

5/16

to 1

30.1

01.9

2.17

1. R

edis

trib

utio

n su

bjec

t to

SIA

M li

cens

e or

cop

yrig

ht; s

ee h

ttp://

ww

w.s

iam

.org

/jour

nals

/ojs

a.ph

p

Page 11: Peaceman Rachford Paper

38 D. W. PEACEMAN AND II. It. RACHFORD JR.

as a time step of an unsteady-state problem, while the starting values usedfor the first iteration correspond to the initial condition. Equations (27)and (28) are used for alternate stages of the iteration, with n representingthe number of pairs of stages already carried out and p serving as aniteration parameter.

Convergence. We now investigate the convergence of this iterationprocedure in order to determine the optimum values of the iteration param-eter, p. The rate of convergence is determined by studying how the errorsdecay at successive stages of the iteration. Since the starting values shouldsatisfy the boundary conditions (39), the initial errors as well as the in-termediate errors should satisfy the boundary conditions given by equa-tion (4). Hence, these errors behave in precisely the same manner as theerrors present in the application of equations (27) and (28) to the solutionof the heat flow equation. Thus, the results obtained for the analysis ofstability may also be used for the analysis of convergence. The iterationerrors may be expanded in the double cosine series of equation (9), and theamplification factor for each component, Ap,q, of the error is again givenby equation (37).As may be seen from equation (37), the amplification factor may be

reduced to zero for each component by suitable choices of p. If we use

(44) p 4 sin x 4 sin(2p + 1)Tr

2 4N

for each of the values of p: 0, 1, 2, N 1, all of the components willbe reduced to zero on some one of the iterations.

It would appear that all of the components could be reduced to zero byusing only equation (27) with the values of p given by equation (44); thatis, by iterating with the unknowns implicit in just the x-direction. How-ever, equation (36) shows that such a process is highly unstable for all butthe pth component. It is, therefore, necessary to iterate using both equa-tions (27) and (28) alternately. This permits the successive reduction ofeach component to zero without the simultaneous amplification of any ofthe other components.From these considerations, it follows that 2N iterations are required to

reduce all the error components to zero. However, it is not necessary totake 2N iterations to obtain a satisfactory convergence. If N is sufficientlylarge, an examination of the values of pp shows that, at the larger values ofp, the values of pp lie fairly close together. Consequently, an average p maybe used for a group of values of p. The amplification factors for the com-ponents corresponding to the values of p falling within that group whilenot zero, are sufficiently small to reduce these components effectively.

Dow

nloa

ded

04/0

5/16

to 1

30.1

01.9

2.17

1. R

edis

trib

utio

n su

bjec

t to

SIA

M li

cens

e or

cop

yrig

ht; s

ee h

ttp://

ww

w.s

iam

.org

/jour

nals

/ojs

a.ph

p

Page 12: Peaceman Rachford Paper

NUMERICAL SOLUTION OF DIFFERENTIAL EUATIONS 39

When N is not too large, it is possible to calculate all the values of p byequation (44) and to set up the groups by inspection. For large values ofN, however, it is desirable to have a formal procedure for setting up thesegroups, and to examine how the number of groups increases as N increases.

Let pu be the lowest value of p in a particular group and p,+l be thehighest. It can be seen from equation (37) that every component, A.qwith pu < p < p+l or p < q < p+l, is acted upon at least once with anamplification factor whose magnitude is less than or equal to the greaterof the two quantities

p 4 sin ((2p + 1)/4N) p 4 sin (2p+1 + 1)r/4N)p + 4 sin ((2p + 1)r/4N) p + 4 sin (2p+1 + 1)r/4N)

where p is the iteration parameter associated with that group. It is thuspossible to group the p’s in such a way that every component is acted uponat least once by an amplification factor whose magnitude is less than orequal to some quantity, R. To have as few groups as possible, and thereforethe minimum number of iterations, p, p+, and p for each group mustsatisfy the following relationship:

(45)

p 4 sin ((2p + 1)r/4N)p + 4 sin ((2p, -{- 1)r/4N)

p 4 sin ((2p,+ -t- 1) r/4N) R.p -[- 4 sin ((2p,+ -t- 1)r/4N)

For large N,

(48)

(49)

(47) sin4N

sm 4--"

For the group containing the highest values of p, p+ N 1, while forthe group containing the lowest values, p 0. Then, if s is the total numberof groups,

log N + log (4/r) log Nlog [(1 -{- R)/(1 -R)] 2R

It is assumed, for purposes of setting up the groups, that p, may have non-integral values. By eliminating p from equation (45), we have for eachgroup,

(11 RR)(46) sin(2p+1 -t- 1)r + sin

(2p, + 1)4N 4N

Dow

nloa

ded

04/0

5/16

to 1

30.1

01.9

2.17

1. R

edis

trib

utio

n su

bjec

t to

SIA

M li

cens

e or

cop

yrig

ht; s

ee h

ttp://

ww

w.s

iam

.org

/jour

nals

/ojs

a.ph

p

Page 13: Peaceman Rachford Paper

40 D, W’, PEACEA.N" AND I. H, RACHFORD JR.

TABLE 2.--Iteration Parameters for N 14.

012345678910111213

0.0125760.112230.306550.585790.935961.33941.77612.22392.66063.06423.41423.69353.88783.9874

0.405710454601664.008710005451003809.00287.00229.00192.00166.00149.00138.00131.00128

Thus, the number of iterations increases approximately as the logarithmof N, and the number of arithmetic operations increases as N log N, as

opposed to N for the extrapolated Liebmann method.

Numerical example. Iteration of the Laplace difference equation by thealternating-direction implicit method was tested by carrying out thenumerical solutions of equations (38) and (39) on the Card ProgrammedCalculator. Again, fourteen increments on a side were used. Using N 14,the values of pp were calculated from equation (44) and are listed in Table2. The corresponding Atp, calculated from equation (6), are also listed.For the calculation, five values of At were chosen by inspection: 0.0015

for p 8 to 13; 0.003 for p 4 to 7; 0.01 for p 2, 3; 0.04546 for p1 and 0.40571 for p 0. These values of At were used in order of increasingmagnitude. Each At was used twice, once with the unknowns implicit inthe x-direction, and once with the unknowns implicit in the y-direction.The following relationship for T was used for the first trial:

(50) T 1 -x2 --x--y

In the ten stages of iteration, the solution converged to within 0.000014of the exact solution of the difference equation. The initial guess had amaximum error of about 0.039, so that the ten steps reduced the errors bya factor of about 4 10-4.The work involved in reducing the errors by a factor of 10-3, then, is

about (10)(9)(14) arithmetic operations. In the more general case, we

may expect the number of iterations to be about

Dow

nloa

ded

04/0

5/16

to 1

30.1

01.9

2.17

1. R

edis

trib

utio

n su

bjec

t to

SIA

M li

cens

e or

cop

yrig

ht; s

ee h

ttp://

ww

w.s

iam

.org

/jour

nals

/ojs

a.ph

p

Page 14: Peaceman Rachford Paper

NUMERICAL SOLUTION OF DIFFERENTIAL EQUATIONS 41

10log N 3.8 log N,log 14

and the total work to be about (3.8 log N)(9)N or 34N log N operations.The extrapolated Liebmann method requires 15N operations, so that thenew method is better by a factor of about N/(2 log N) over the next bestiterative method.

Since this paper was submitted, several examples involving more com-plex regions and less simple boundary conditions have been solved by meansof the alternating-direction-implicit method [7]; however, no proofs of thevalidity of the procedure in these cases have been obtained.

REFERENCES

1. Bruce, G. H., Peaceman, D. W., Rachford, H. H., and Rice, J. D., Calculation ofunsteady-state gas flow through porous media, Trans. Amer. Inst. Miningand Met. Engrs. 198(1953), p. 79.

2. Carslaw, H. S., and Jaeger, J. C., Conduction of Heat in Solids, 1st ed., p. 152,Oxford University Press, London, (1948).

3. Frankel, S. P., Convergence rates of iterative treatments of partial differential equa-tions, Mathematical Tables and Other Aids to Computation, 4 (1950), pp.65-75.

4. O’Brien, G. G., Hyman, M. A., and Kaplan, S., A study of the numerical solution ofpartial differential equations, J. Math. Physics, 29 (1951), pp. 223-251.

5. Douglas, J., Jr., On the numerical integration of Ou/Ox 02u/Oy Ou/Ot by im-plicit methods, this journal, 3 (1955), pp. 42-65.

6. Douglas, J., Jr., and Gallic, T. M., Jr., Variable time steps in the solution of theheat flow equation by a difference equation, submitted to Proc. Amer. Math.

7. Douglas, J., Jr., and Peaceman, D. W., Numerical solution of two-dimensional heatflow problems, to be presented at the May, 1955 meeting of The AmericanInstitute of Chemical Engineers at Houston, Texas.

HUMBLE OIL AND REFINING COMPANYHOUSTON, TEXAS

Dow

nloa

ded

04/0

5/16

to 1

30.1

01.9

2.17

1. R

edis

trib

utio

n su

bjec

t to

SIA

M li

cens

e or

cop

yrig

ht; s

ee h

ttp://

ww

w.s

iam

.org

/jour

nals

/ojs

a.ph

p