accuracy and stability analysis of numerical schemes for the shallow water model

14
Accuracy and Stability Analysis of Numerical Schemes for the Shallow Water Model Yue-Kuen Kwok Department of Mathematics, Hong Kong University of Science and Technology, Clear Water Bay, Hong Kong Received 25 October 1994; revised manuscript received 18 July 1995 The accuracy and stability properties of several two-level and three-level difference schemes for solving the shallow water model are analyzed by the linearized Fourier Method. The effects of explicit or implicit treatments of the gravity, Coriolis, convective and friction terms on accuracy and stability are examined. The use of Miller’s properties on von Neumann polynomial plays a crucial role to resolve the tedious mathematical procedures in the Fourier analysis. As a best compromise between efficiency and stability, we recommend the semi-implicit schemes, where the surface elevation and friction terms are treated implicitly while the convective and Coriolis terms are treated explicitly. 0 1996 John Wiley & Sons, Inc. 1. INTRODUCTION The set of governing equations for the two-dimensional (2-D) shallow water model, which describes constant density and free surface flows with the assumption of a hydrostatic pressure gradient, is given as au au au az - + u- + v- - fv = at ax ay ax -g- - yu (l.lu) av av av az - + u- + v- + fu = at ax ay aY -g- - yv az a a - + -[Hu] + :[Hv] = 0, at ax dy (1.lb) (I.lc) where u(x,y,t) and v(x,y,t) are the depth-averaged velocity components in the x- and y - direction, respectively, z(x, y, t) is the water surface elevation measured from the undisturbed water surface, g is the gravitational constant, f is the Coriolis coefficient, and y is the linear bottom-friction coefficient. H(x, y, t) is the total water depth, where H(x,y, t) = z(x,.y,t) + h(x,y) is the water depth measured from the undisturbed water surface. The hydrostatic model studies the effects of gravity wave, Coriolis forces, advection, and friction in shallow water flows. Other formulations of the shallow water Numerical Methods for Partial Differential Equations, 12, 85-98 ( 1996) 0 1996 John Wiley & Sons. Inc. CCC 0749- 159)(/96/010085-14

Upload: yue-kuen-kwok

Post on 06-Jun-2016

213 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Accuracy and stability analysis of numerical schemes for the shallow water model

Accuracy and Stability Analysis of Numerical Schemes for the Shallow Water Model Yue-Kuen Kwok Department of Mathematics, Hong Kong University of Science and Technology, Clear Water Bay, Hong Kong

Received 25 October 1994; revised manuscript received 18 July 1995

The accuracy and stability properties of several two-level and three-level difference schemes for solving the shallow water model are analyzed by the linearized Fourier Method. The effects of explicit or implicit treatments of the gravity, Coriolis, convective and friction terms on accuracy and stability are examined. The use of Miller’s properties on von Neumann polynomial plays a crucial role to resolve the tedious mathematical procedures in the Fourier analysis. As a best compromise between efficiency and stability, we recommend the semi-implicit schemes, where the surface elevation and friction terms are treated implicitly while the convective and Coriolis terms are treated explicitly. 0 1996 John Wiley & Sons, Inc.

1. INTRODUCTION

The set of governing equations for the two-dimensional (2-D) shallow water model, which describes constant density and free surface flows with the assumption of a hydrostatic pressure gradient, is given as

a u a u a u az - + u- + v- - f v = a t ax ay a x

-g- - yu ( l . l u )

a v a v a v az - + u- + v- + f u = at ax a y aY

-g- - yv

az a a - + - [Hu] + :[Hv] = 0, at ax dy

(1.lb)

( I . lc)

where u ( x , y , t ) and v ( x , y , t ) are the depth-averaged velocity components in the x - and y - direction, respectively, z(x, y , t ) is the water surface elevation measured from the undisturbed water surface, g is the gravitational constant, f is the Coriolis coefficient, and y is the linear bottom-friction coefficient. H ( x , y , t ) is the total water depth, where H ( x , y , t ) = z ( x , . y , t ) + h ( x , y ) is the water depth measured from the undisturbed water surface. The hydrostatic model studies the effects of gravity wave, Coriolis forces, advection, and friction in shallow water flows. Other formulations of the shallow water

Numerical Methods for Partial Differential Equations, 12, 85-98 ( 1996) 0 1996 John Wiley & Sons. Inc. CCC 0749- 159)(/96/010085-14

Page 2: Accuracy and stability analysis of numerical schemes for the shallow water model

86 KWOK

models are also reported in the literature, such as the wave equation model [ l ] and the vorticity-divergence model [2].

In the forthcoming sections, several two-level and three-level finite difference schemes for solving the above model are presented. The accuracy and stability properties of these difference schemes are then analyzed by the linearized Fourier method. An effective procedure based on the Miller properties of a von Neumann polynomial is employed to resolve the tedious mathematical procedures for deducing the stability properties of the numerical schemes.

II. FORMULATION OF THE DIFFERENCE SCHEMES

A variety of numerical schemes have been developed to perform the numerical simulation of the 2-D shallow water model. These numerical methods range from the fully explicit schemes to the fully implicit schemes and may involve two or three time-level values. A comprehensive summary of these numerical schemes can be found in Tan’s text [ 3 ] .

Suppose that the continuous shallow water model is represented as d

-W = A,.w, at

T where w = ( U I ’ Z ) , and A , is the continuous operator corresponding to all spatial derivative terms. Depending on the types of discretization employed (which include finite-difference, finite-element, and spectral methods), one may obtain the following semi-discretized form of the continuous model:

where w/, is the corresponding grid function defined on some spatial mesh for approximat- ing the continuous variable w, and A is a difference operator approximating the continuous derivative operator A , . For brevity, we drop the subscript “h” in wll starting from here; that is, w represents a spatial-grid and time-continuous variable. We then adopt some appropriate form of splitting: A = B + C, as dictated by considerations of efficiency, accuracy, and stability presented later. A family of two-level schemes can be constructed as follows:

or

w“” = ( I - ArB)-’(I + AfC)w”, (2.311)

where ( I - AtB)-’ is easily invertible. This family of schemes is shown to be first-order time accurate. One may also construct the following family of three-level second-order time-accurate schemes:

,+,ii+I - w n - I w ” + l + w ” - I

2Ar 2

Suppose we write W“ = (,,w“, ), the three-level schemes can be expressed as

= B + C W ” . ( 2 . 4 ~ )

(2.4b)

Page 3: Accuracy and stability analysis of numerical schemes for the shallow water model

. . . NUMERICAL SCHEMES FOR THE SHALLOW WATER MODEL 87

Next, we consider the choice of a staggered grid system for the variables. Arakawa and Lamb [4] proposed five grid systems labeled ‘A’ through ‘E’ for shallow water simulation. In a recent study of semi-discretized schemes by Randall [ 5 ] , grid system ‘C’ (shown here in Fig. 1) is demonstrated to give the best performance in terms of accuracy of approximating the dispersive frequencies. For all fully discretized schemes analyzed below, we shall adopt the same staggered grid system as in Fig. 1.

In the design of numerical schemes, aside from efficiency, we need to think of accuracy and stability. In this article, we employ linearized Fourier analysis to study the amplitude and phase of the propagating waves of the discretized schemes. The required assumptions for linearized Fourier analysis are infinite domain of the problem (or periodic boundary conditions) and linearization of the governing equations by setting the convection velocity, the total height H , the friction, and the Coriolis coefficients to be frozen constants. The amplification matrix of a discretized scheme is constructed and its eigenvalues are examined for possible instability. Also, the modulus and argument of the eigenvalues are compared with that of the continuous problem.

In Section 111, we analyze the accuracy and stability properties of several difference schemes, corresponding to different forms of splitting of operator A. To avoid insurmount- able mathematical tediousness in the accuracy analysis, we switch off the advection and friction terms in the model. In Section IV, we examine the stability requirements of some two-level and three-level schemes for solving the full shallow water model.

111. SIMPLIFIED SHALLOW WATER MODEL

The reduced set of equations for the study of accuracy and stability properties of various types of discretization for the shallow water model is given by

dU 32

at dX - f v + g- = 0 -

d V d2 - + f U + g - = o at aY

( 3 . l a )

(3.1 b)

FIG. 1. Arakawa’s staggered grid system for shallow water simulation.

Page 4: Accuracy and stability analysis of numerical schemes for the shallow water model

88 KWOK

- a z + H - d u + H - a v = 0, at ax aY

(3. Ic)

which corresponds to zero mean flow and absence of friction in the full model. This simplified model has been used frequently to simulate the process of geostropic adjustment in meterology. The accuracy analysis of spatial discretization using Fourier method (essentially the same as transfer function analysis) of various semi-discretized schemes (discretized in space but continuous in time) for the simplified model have been performed extensively by a number of researchers [6]-[ 1 I ] . In this section, we consider the errors arising from both the spatial and temporal discretization for a variety of difference schemes.

Based on centered difference discretization and the choice of Arakawa grid system 'C ' , the semi-discretized scheme for solving system (3.1) takes the form

s: - I duj+t.k i,+ 1.1: - Z ] , k Zj.1: (3.211) g-L- = j V j + i . k -

A x - = fv ,+i .r - g dt

( 3 . 2 ~ )

where A x and A? are stepwidths, S: and S I denote the forward and backward shift operators, respectively, in the x-direction, and similar definition for S: and SL in the ?-direction. The Fourier transforms of the shift operators are

i h , A r = e - ~ f i , y{s:} = e r k , A r = e ' P n , ~ { s I } = e - y{s:} = e - l h " A ' = e - ' P > y { s i } = e'"A\ = e ' P ! ,

where k , and k , are the wavenumbers and p, = k , A x , P , = k , A v . Write li = y { u j + ; k } ,

8 = Y{V, .~+; } , 2 = Y{Z~.~} , and let p , = ? ( I + e'Pl), p , = ? ( I + e l p > ) , q x = 1 - e'Pi, q\ = 1 - e ' f i $ . In the Fourier domain, the matrix representation of the semi- discretized scheme becomes

I I

where 'bar' denotes complex conjugate. The nonzero eigenvalues of the continuous system (3.1) and the semi-discretized system (3.3) are

N

Page 5: Accuracy and stability analysis of numerical schemes for the shallow water model

. . NUMERICAL SCHEMES FOR THE SHALLOW WATER MODEL 89

respectively, where c = is the phase speed of the pure gravity wave (celerity wave). Since A ? are real quantities, the amplitudes of the Rossby-gravity waves in the present simplified model remain constant for all times: and in time A t , the phase changes of the waves of the continuous model are A$‘, = + A t , , / m .

A. Two-Level Schemes

The fully explicit scheme takes the splitting: B , = 0 and CI = A. In the Fourier domain, the scheme reads

1 P,P,f A t -7, P ! f A t 1

- H A / - - H A / - - i T q , T 4 \

The eigenvalues of the amplification matrix are 1, 1 - p p N \ in 5 N \in +

f = c o s ~ c o s + f , k , = - - A < 3 k\ = - - A , . The moduli of the last two eigenvalues

-C j A t d f ? + c2(k t + k : ) , where

L A / l A / N

both equal to 1 + f ? A t ’ + 4(vf sin’ 5 + vz sin’ $), where v, = are called gravity Courant numbers. For finite values of v , and v\, the scheme is seen to be unstable; and so the scheme is rendered useless.

To improve stability, we choose the splitting

and v, =

so that in the Fourier domain, the scheme can be expressed as

1 P I P , f A t 0 l I + I - R A / - 1 (i) =(;; ?;\) ( - -P,P\f - H A / - - H l l - 1 0 ) 1 ( !)I1. (3 .5) 0 0 T 9 , T T 4 \

Note that the computational procedure starts with the explicit evaluation of z;.:’, then use the newly obtained z;,:’ values to update uy:;,, and v:.::;. The eigenvalues of the amplification matrix are

N

The moduli of the last two eigenvalues are 1 - f 2 A t 2 , hence the scheme is stable with respect to von Neumann stability criteria, since f A t = o(1). The arguments of the eigenvalues are

Page 6: Accuracy and stability analysis of numerical schemes for the shallow water model

90 KWOK

It suffices to consider only the wave that corresponds to the positive sign. The ratio of the phase change in time A t , or one time step, of the numerical wave A$n to that of the analytic wave A$[, can be expressed as

(3.6)

The above first and second bracket terms give the relative errors due to spatial and temporal discretization, respectivelz. Note that accuracy is much deteriorated when either 1 - - ( k t + k t ) or 1 - ~ ( k t + k,?) becomes negative. Hence, i t is necessary to observe

N < [ ? A l > N N

J A I

Pi vf sin’ !& + vz sin’ - 5 min for all values of pr, p , . 2 2

Next, the implicit scheme adopts implicit treatment of the gravity and divergence terms, but leaves the Coriolis terms treated explicitly. The corresponding splitting of the operator A is

In the Fourier domain, the scheme reads

In the computational procedure for the scheme, it is necessary to solve a Poisson equation for I1 + I . The eigenvalues of the amplification matrix are

1

The moduli of the last two eigenvalues are again found to be 1 + f ’A t ’ ; and so the implicit scheme is also stable. Similarly, the ratio of the phase changes in one time step is

The relative error due to temporal discretization is of the form J l + K’At’, where

Such a property is desirable, since the accuracy will not deteriorate at an exceedingly large value of c , / m .

Page 7: Accuracy and stability analysis of numerical schemes for the shallow water model

. . . NUMERICAL SCHEMES FOR THE SHALLOW WATER MODEL 91

B. Three-Level Schemes First, we consider the fully explicit scheme, where B = 0 and C = A . Let W“ =

domain can be written as ( f i n e n ~ I I f i t t - 1 t11-1 i. ~ 1 1 - 1 ) 7’ , and then the three-level fully explicit scheme in the Fourier

wn+l = ( 2 A t A I o)w? I

The characteristic polynomial of the above amplification matrix is p I ( p ) = ( p - l)(p + l)[p4 + (4X:At’ - 2 ) p 2 + I]. A polynomial is said to be a von Neumnnnpolynomial if all its roots are on or inside the unit circle; further, it is called a simple von Neumann polynomiul if those roots that are on the unit circle are simple. According to the von Neumann stability condition, a difference scheme is stable if and only if the characteristic polynomial of its amplification matrix is a simple von Neumann polynomial [ 121. It can be shown easily that p I ( p ) is a simple von Neumann polynomial if and only if X + A t < 1. Write the roots of p I ( p ) as ? I , ? p 5 , then

p i = 1 - 2 A t 2 i ’ , _f 2 A t X , d z i . (3.10)

It can be shown that Ip.+ I = 1, provided that A+ A t < 1 . Thus, the stability condition of the scheme is given by X + A t < I .

The numerical parasitic waves happen to be the negative of those numerical waves that approximate the continuous solutions. The ratio of phase change in one time step is

(3.1 1 )

I t is disquieting to observe that the local truncation error due to temporal discretization is only O ( A t 2 ) , the same as that of two-level schemes. Further, we have the reversal of sign of A I + ~ J A @ , ~ when 1 - 2At2X: becomes negative; and A @ l I / A @ ( I becomes large when X + A t is close to l / f i . For accuracy consideration, we would like to maintain X + A t to be much less than l/a.

Next, we consider the three-level implicit scheme where the splitting A = B3 + C3 is employed. In the Fourier domain, the scheme becomes

(3.12)

I t can be shown that the characteristic polynomial of the corresponding amplification matrix is a simple von Neumann polynomial if and only !At < 1, which is less restrictive than that of the explicit scheme (3.9). Let the roots of the characteristic polynomial be -+ 1, fp?; one can obtain

- (3.13)

The ratio of phase changes of numerical waves to that of the analytic waves in one time step is found to be

(3.14)

Page 8: Accuracy and stability analysis of numerical schemes for the shallow water model

92 KWOK

Similarly, for accuracy consideration, we would like to observe the time step requirement

that A r J m be much less than I . For three-level schemes, the implicit scheme does not demonstrate much advantage over

the explicit scheme in terms of time-step restriction and accuracy.

IV. FULL SHALLOW WATER MODEL

In this section, we examine the stability properties of several two- and three-level difference schemes for solving the full shallow water model (1.1). It will be shown later that the characteristic polynomials of the amplification matrices of these schemes are either cubic polynomials for two-level schemes or degree-six polynomials for three-level schemes. The direct determination of the roots of these polynomials and finding the conditions for them to be a simple von Neumann polynomial will be formidable or even insurmountable. Fortunately, the Miller Theorem provides an elegant procedure for checking the conditions for a von Neumann polynomial [ 121.

A. Miller’s properties of a von Neumann Polynomial

Let 4 be a degree d polynomial with coefficients a,, j = 0, I , . . . d. which are in general complex. We define another polynomial 4* by

rn=O

For a polynomial &,(c), we define recursively the reduced polynomials

4;(0) 4, ( c ) - 4, (0) 4,*(z) 4J+l(Z) z= j = 0,1,2 . . . . -

c (4.1)

Note that the degree of the polynomial is reduced by one after each recursion. The Miller Theorem states that 4, is a von Neumann polynomial of degree d if and only if either 4,+1 is a von Neumann polynomial of degree d - 1 and I4,(0)I < lc#,*(O)l, or $J,+~ is identically zero and the derivative 4; is a Schur polynomial. A polynomial is said to be a Schur polynomial if all its roots are inside the uni t circle.

When the coefficients a, are all real, Kinnmark and Gray [I31 derived a set of explicit formulas for finding the conditions required for a polynomial to be a von Neumann polynomial. However, these formulas are inapplicable in the present problem, since the coefficients of the characteristic polynomials considered here are complex due to the presence of convective terms in the model.

In particular, for a quadratic polynomial where 4(:) = ;’ + uI: + a() , the necessary and sufficient conditions for 4(:) to be a simple von Neumann polynomial can be stated explicitly as follows 1141.

( i ) For luol < 1 , the required condition is lal - ZlaoI 5 I - I L IO I ’ ; ( i i ) For la0l = I , the required conditions are L I I = Zlao and la1 I < 2;

( i i i ) For IaoI > I , 4(:) cannot be a simple von Neumann polynomial.

Page 9: Accuracy and stability analysis of numerical schemes for the shallow water model

. . . NUMERICAL SCHEMES FOR THE SHALLOW WATER MODEL 93

6. Two-Level Schemes

An explicit two-level scheme, which is similar in spirit to that of scheme (3.4) can be constructed as follows:

a a where G is some explicit discretization of the convective operator - ( u z + vz) and I is the identity operator. Note that only the friction terms are treated implicitly, while all the other terms are treated explicitly.

To facilitate linearized Fourier analysis of the scheme. we treat the convective velocities as frozen constants. We let (Y denote the Fourier transform of the linearized convective operator and write G = v. Also, we let I +oAr

. f A t 1 + yAt

F =

Suppose that simple upwinding discretization of the convective operator is adopted, and assume that u > 0 , v > 0; we then have

IdAI LA! 1 - z ( l - e - ' P Q ) - K ( l - e-lPb 1 1 + y A t

1 - f i r ( ] - e-'Pa) - F,(I - e - ' P i )

1 + y A t - - G =

uAr - LA/ Here, we define the convective Courant numbers: C , = X,Y, = K . In the Fourier domain, the explicit scheme can be expressed as

(4.3)

The characteristic polynomial of the above amplification matrix is found to be p' - ( 1 + 2G)p' + (G' + 2G + F' + B ) p - (G' + P' + GB), where

-s, 1

4( vt sin- 7 P + + .'sin' $) PI PI F = cos-cos-F and B = 2 2 1 + y A t 1 + y A t

The determination of stability condition from the above cubic characteristic polynomial appears to be mathematically intractable. Since B and G are related to the gravity and convective Courant numbers, respectively, while F is O ( A t ) , F plays a secondary role in

Page 10: Accuracy and stability analysis of numerical schemes for the shallow water model

94 KWOK

defining the required stability condition. When the terms containing polynomial are dropped, the cubic polynomial is reduced to

in the characteristic

P l b ) = ( p - G ) [ p 2 - ( 1 + G ) p + G + BI. (4.4)

For the sake of simplicity, it suffices to consider p l ( p ) for subsequent stability analysis. Concerning the effect of the above simplification on the time-step restriction, the leading order terms in powers of spatial stepwidths would remain unaffected.

A necessary condition for p I ( p ) to be a simple von Neumann polynomial that can be deduced immediately is IC + Bl 5 1. Provided that V , + V , 5 1 (which is a sufficient condition for ICl 5 I ) , the largest real value for G attainable for all possible values of 0 5 p, 9 n-,0 9 p\. 9 n- is seen to be m. The largest value attainable for B is 4(vi + v:)/( 1 + y A t ) . Hence, we require

I

4(vf + v;) 9 1 - 1 - - Y A t 1 + y A t 1 + y A t 1 + yAr

for stability of explicit scheme (4.3). One observes the very restrictive time-step require- ment, which is found to be O(As', A?') and proportional to the reciprocal of the square of the fast gravity wave speed c. With regard to the numerical stability requirement, the explicit scheme is very undesirable.

Following a discretization similar to that of scheme (3.5), we modify the above explicit scheme by first performing explicit evaluation of :;,; I using the continuity equation, and then obtaining u;.'';,~ and from the momentum equations using the newly obtained

z , . ~ 11+ I values. In the Fourier domain, the modified scheme can be represented by

G P l I ' , F 0)(;)11 = i' 0 " 1 r.,)-I( r \ -I',P!.F - G 0 (4.6)

Using a similar argument as above, we set F = 0 in subsequent stability analysis. With F = 0, the characteristic polynomial of scheme (4.6) is found to be

(4.7)

For the quadratic polynomial p? - ( 1 + G + B ) p + G, the reduced monomial obtained from formula (4.1) is found to be ( 1 - GC)p + ( G C - I ) + ( G - 1)B. The required necessary and sufficient conditions for stability are

s, -s,. 1 2 - 0 0 i

pz(p) = ( p - G)[pul - ( 1 + G + B ) p + GI.

and ( I - '"1 5 for all values of p , and p, . I ] + I - G G n Since - and Re( l - G ) are positive for some values of p , and the required

conditions cannot be satisfied. Hence, the modified scheme (4.6) is unconditionally unstable; this renders the scheme useless.

Lastly, we consider the scheme where the gravity and divergence terms are treated implicitly, while the convective and Coriolis terms are treated explicitly. The scheme

Page 11: Accuracy and stability analysis of numerical schemes for the shallow water model

. . NUMERICAL SCHEMES FOR THE SHALLOW WATER MODEL 95

follows in a similar spirit as that of the semi-implicit scheme proposed by Casulli [15]. The computational procedures require the solution of z;.:' by solving a Poisson solution, then followed by the updating of u ; : : . ~ and vy,:lL from the momentum equations using

known values of zJ'.:'. In the Fourier domain, the semi-implicit scheme can be expressed as

1 0 rr (4.8)

0 1

With the neglect of the Coriolis terms, the characteristic polynomial of the above amplification factor is

P 7 ( p ) = ( p - G)[(1 + B)p' - ( I + G ) p + GI. (4.9)

Similarly, the reduced monomial obtained from formula (4.1) for the above quadratic poly- nomial is found to be ( 1 + B - G)[(I + B + G ) p - ( I + G)]. The required necessary and sufficient conditions for numerical stability are given by

Since B 2 0, the inequalities are reduced to a single inequality: IGI < 1. The leading order term of the time-step restriction can be deduced to be

(4.10)

The time-step restriction mainly depends on the Courant limit based on the convection velocities, but not on the faster gravity wave speed c; also, it is lessened by the presence of friction terms.

C. Three-Level Schemes

Adopting the same splitting of operator as in the semi-implicitly scheme (4.8), a three-level scheme is constructed as follows [ 161:

Page 12: Accuracy and stability analysis of numerical schemes for the shallow water model

96 KWOK

The above scheme can be considered as a Leap-frog/Crank-Nicholson discretization. Let

1 - yAr 2aAr 1 + y A t

r = and ti = - 1 + y A t ’

In the Fourier domain, scheme (4.11) can be expressed as (,!, ;\ 0 i : )wJl+l + ( - p y p \ F P l F \ F n 0 + ( ;,,- 0 ~ : l ) w ~ l - l = 0.

0 0 0 (4.12)

The characteristic polynomial associated with the above scheme is found to be (after dropping terms containing F )

(p’ - 17p - r){(l + B)p4 - np’ + [2B - ( 1 + r ) ] p ’ + n p + ( r + B ) } .

Since centered differences are employed to discretize the convective terms in Leap-frog type schemes, then 11 is purely imaginary. For the first quadratic polynomial, it is a simple von Neumann polynomial if and only if r < 1 and In1 5 1 + r = &. The first inequality is identically satisfied, while the second inequality is equivalent to IalAt 5 I . The corresponding time-step restriction is given by

(4.13)

For the second fourth-degree polynomial, the Miller theorem is applied to find the conditions required for it to be a simple von Neumann polynomial. Let & ( p ) = ( 1 + B ) p 4 - tip3 + [2B - ( 1 + r)]p’ + tip + ( r + B ) , and let the recursive polynomials be represented by

c$I(p) = cjp3 + c.p2 + c1p + C ( ] ,

h ( p ) = e l p + eo.

+,(PI = d?pU? + dip + 41,

The required conditions are found to be

( i ) l r + BI < 11 + BI, ( i v ) l e o I 5 [el I. The first inequality is automatically satisfied. For the remaining inequalities, the respective coefficients are found to be

(ii)lco( < 1 ~ 3 1 , ( i i i ) l d ~ l < Idzl, and

cg = n ( l + r + 2B)

c3 = ( 1 - r)(l + r + 2B)

do = ( 1 + r + 2 ~ ) { 2 [ t i ’ + ( I - r ) ’ ] ~ + ( 1 + r)[n’ - ( I - r ) ’ ] }

d2 = [ ( I - r ) 2 - n2] [1 + r + 2 ~ 1 ~

eo = 8tiB(r - 1 ) ( 1 + r + 2B) ( r3 - r 2 - n’r - r - 2Bn’ - t i 2 + 1 )

el = 8B(r - 1)’Il + r + 2B) ( r3 - r 2 - n’r - r - 2Bn’ - n’ + I ) .

After some routine algebraic manipulation, the condition required to satisfy all the inequalities is shown to bz In1 5 1 + r , which gives the same time-step restriction given

Page 13: Accuracy and stability analysis of numerical schemes for the shallow water model

. . . NUMERICAL SCHEMES FOR THE SHALLOW WATER MODEL 97

in (4.13). The time-step restriction is given by the Courant limit based on the convective velocities. This stability result agrees with that obtained by using the energy method, which is another method of stability analysis [16].

D. Remarks

Consider the following scalar wave equations:

with constant convective velocities u and v and damping coefficient y . Following a similar type of discretization as that of two-level semi-implicit scheme (4.6). we construct the scheme

(4.15)

The stability condition is easily seen to be ICl 5 1. Also, employing similar discretization as that of three-level Leap-frog/Crank-Nicholson scheme (4.1 1 ), we have

(4.16)

The characteristic polynomial of the associated amplification factor is 4(p) = p2 - n p - r . It has been shown earlier that the stability requirement is given by In[ 5 1 + r , which is identical to that of the full scheme (4.1 1).

In conclusion, the stability properties of the semi-implicit schemes (4.8) and (4.1 1 ) mimic that of similar scalar difference schemes, which use the same types of discretization apply there to a scalar wave equation with constant convective velocities and damping.

V. DISCUSSION AND CONCLUSION

In this article, the accuracy and stability properties of several two-level and three- level difference schemes for the simulation of two-dimensional shallow water flows are analyzed by the Fourier method. Fourier analysis is believed to be the most useful tool for studying the accuracy and stability properties of difference schemes. However, it is the most restricted tool of analysis, since Fourier analysis is strictly applicable to linear problems with constant coefficients and periodic boundary conditions. Further, the difference schemes must be defined on uniform meshes and the type of stability studied is only in the [?-norm. In order to perform the linearized Fourier analysis, it is necessary that the nonlinear convective terms be linearized by treating the convective velocities as frozen constants.

In this work, all the tedious mathematical manipulation in the Fourier analysis is effected by symbolic computation on a computer. The analysis is much simplified by employing the Miller properties of von Neumann polynomials. The errors arising from different types of spatial and temporal discretization are presented in concise analytic forms.

We find an explicit scheme, which is stable when solving the shallow water model with zero mean flow, but becomes unstable when convective velocities are nonzero. Precise time-step restrictions for a number of numerically stable schemes are presented. When the terms associated with the fast gravity waves are treated implicitly, the time-step restriction

Page 14: Accuracy and stability analysis of numerical schemes for the shallow water model

98 KWOK

becomes independent of the gravity wave speeds. Moreover, the stability requirements of such a semi-implicit scheme mimic that of similar schemes that use the same types of discretization but apply them to a scalar wave equation with constant convective velocities and damping. From past experience, conclusions drawn from Fourier analysis are found to be widely applicable for practical simulation. The success may be partly explained by the phenomenon that most numerical instabilities are initiated by high-frequency modes and so, the effects are localized.

References

1. D. R. Lynch and W. G. Gray, “A wave equation model for finite element tidal computations,” Comput. Fluids 7, 207 (1979).

2. A. N. Staniforth and H. L. Mitchell, “A semi-implicit finite element barotropic model.” Monthly Weuthrr Rev. 105, 154 (1977).

3. W. Y. Tan. S h a l l o ~ ~ Wurer Hydrodynamics-Mathemutical Theoty mid Numerical Solutiori fiir a Two-Ditnensiorial System of Shallow Water Equcitions, Elsevier, Amsterdam, 1992.

4. A. Arakawa and V. R. Lamb, “Computational design of the basic dynamical processes of the UCLA general circulation model,’’ Mrth. Cotitput. P h y . 17. 173 (1977).

5 . D. A. Randall, “Geostrophic adjustment and the finite difference shallow-water equations,” Monthly Weather Rev. 122, 1371 (1994).

6. A. L. Schoenstadt, “The effect of spatial discretization on the steady-state and transient solutions of a dispersive wave equation.” J . Comput. Phys. 23, 364 (1977).

7. A. L. Schoenstadt, “A transfer function analysis of numerical schemes used to simulate geostrophic adjustment,” Monthly Weuther Re\,. 108, 1248 ( 1980).

8. B. Neta and C.L. DeVito, “The transfer function analysis of various schemes for the two- dimensional shallow water equations,” Comput. Math. Applic. 16, I 1 1. ( 1988).

9. B. Neta and I .M. Navon. “Analysis of the Turkel-Zwas scheme for the shallow-water equations,” J . Comput. Phys. 81, 277 (1989).

10. B. Neta and R. T. Williams. “Rossby wave frequencies and group velocities for finite element and finite difference approximations to the vorticity -divergence and the primitive forms of the shallow water equations.” Monthly Weather Re\,. 177, 1439 ( 1989).

1 I . Y. Song, and T. Tang, “Staggered Turkel-Zwas scheme for two-dimensional shallow water equations,” Mortthly Weother Re\,. 122. 223 ( 1994).

12. J . C. Strikwerda. Finite Direrence Scltrmes mid Purtial Differc.ririu1 Eyuatioris, Wadsworth and Brooks, Pacific Grove, 1989.

13. I. P. E. Kinnmark and W. G. Gray, “Stability and accuracy of spatial approximations for wave equation tidal models,” J . Comput. Phys. 60. 447 ( 1985).

14. Y. K. Kwok and K. K. Tam, “Stability analysis of three-level difference schemes for initial- boundary problems for multidimensional convective-diffusion equations,” Commun. irt Numer. Methods in Ens. 9. 595 ( 1 993).

IS. V. Casulli, “Semi-implicit finite difference methods for the two-dimensional shallow water model,” J . Comput. Phys. 86, 56 (1990).

16. L. Wu, Y. K. Kwok, and H. Pan, “Second order AD1 methods for accurate computation of shallow water flows,” submitted to Compur. Math. Applic.