0 оценок0% нашли этот документ полезным (0 голосов)

17 просмотров14 страницImplicit Finite-difference Solutions of the Enthalpy
Formulation of Stefan Problems

Apr 05, 2013

© Attribution Non-Commercial (BY-NC)

PDF, TXT или читайте онлайн в Scribd

Implicit Finite-difference Solutions of the Enthalpy
Formulation of Stefan Problems

Attribution Non-Commercial (BY-NC)

0 оценок0% нашли этот документ полезным (0 голосов)

17 просмотров14 страницImplicit Finite-difference Solutions of the Enthalpy
Formulation of Stefan Problems

Attribution Non-Commercial (BY-NC)

Вы находитесь на странице: 1из 14

V. R. VOLLER

Centre for Numerical Modelling and Process Analysis, School of Mathematics, Statistics and Computing, Thames Polytechnic, Wellington Street, London SE\i 6PF [Received 29 February 1984 and in revised form 26 September 1984] When related to a phase-change problem, an implicitfinite-differencediscretization of the enthalpy formulation results in a system of non-linear equations at each time step. In this paper, various numerical enthalpy methods based on such discretizations are outlined and examined. An alternative discretization for an enthalpy formulation is developed on separating the sensible and latent heat terms. This approach also results in a non-linear system of equations but with the nonlinearity isolated as a source term of nodal latent heat. This offers an advantage over the previous techniques in that only one variable (i.e. temperature) is solved for in the resulting iterative scheme. Comparison with simple one- and two-dimensional test problems indicate that the computing requirements, with the alternative discretization, are reduced by between 20 and 50%. 1. Introduction

a common choice in the numerical solution of moving phase-change problems (Stefan problems). An important reason for this is the fact that the continuously moving phase front does not have to be tracked over a discrete numerical grid. Investigations have shown, however (Bonacina, Comini, Fasano & Primicerio, 1973; Voller, Cross & Walton, 1979), that the accuracy of enthalpy solutions is influenced by the position of the phase front Stemming from these investigations methods have been developed which overcome the problems of inaccuracy (Voller & Cross, 1981, 1983a, b; Voller, 1983). Another problem with enthalpy solutions arises when an implicit finite difference discretization is used. Such an approach results in a set of non-linear equations to be solved at each time step. Not only are these equations relatively difficult to solve (especially in comparison with explicit enthalpy methods) but they are also computationally demanding. A number of schemes for solution of implicit finite difference enthalpy methods have been proposed (Meyer, 1973; Shamsundar & Sparrow, 1975; Longworth, 1975; Furzeland, 1980, White, 1983). The aim of the current work is to investigate these methods using simple one and two dimensional Stefan problems. In addition an alternative implicit scheme will be developed and tested against the existing schemes. 2. Test Problems The enthalpy H is defined as the sum of sensible and latent heats. The standard formulation for a multidimensional melting/freezing phase change problem takes the 201

. 0272-4929/85/020201 + 14J03.00/0 _ _ .1985 Academic Pros Inc. (London) Limited.

202

V. R. VOLLER

where T is temperature, K conductivity and p density. The enthalpy and temperature may be related via

{

or alternatively by

H/C,

-Cs>H,

e(H - L/2)/(Ce+L/2\

-Ce^H^Ce

+ L,

(2a)

(H-L)/C,

CT,

H>Ce + L,

-e>7\ where C is the specific heat, L is the latent heat of the-e^T^e, phase change and e > 0 (2b) is a T>e, temperature half range over which the phase change occurs. Note that equations (2a) and (2b) have been derived assuming that the phase change occurs about temperature Tm = 0 and that the thermal conditions are constant throughout Two test problems are introduced: (1) a one-dimensional problem of freezing in the semi-infinite half space with fixed surface temperature T < 0 at the surface x = 0; (2) a two-dimensional problem of freezing in a square duct (side 1 m) with fixed surface temperature T < 0. The thermal, boundary and initial conditions for these problems are given in Table 1. It may be noted that in both these problems the thermal conditions (i.e. conductivity etc.) are constant throughout By suitable modification of the discretization equations [see equation (4a)], all the methods examined in this paper can be applied to problems with varying thermal conditions. Such considerations in the current work, however, were thought to introduce unnecessary complications. 3. Solution Methods On discretizing the area of interest and using Taylor Series approximations (Smith, 1965) or "control volume" conservation (Patankar, 1980) the following

TABLE 1 Conditions for test problems (SI units) One dimension Two dimensions

K C L Tm

^Inittal

2-5 x 106

2-5 x 106

10' 0 -10 2

0-125

10 0 -10 2

0-1 (=<5y = h)

5x

203

weightedfinite-differencereplacement for equation (1) may be derived. H' + 1 = HJ+(5(1 9)F(T*) + 8t 0F(T'+1) where H* = (tf 5,fl2l# $ , . . # ; ) and 1* = (7* 7},.. , 1*) are vectors of nodal enthalpies and temperatures respectively at time t = k 5t. The parameter 9 is a weighting factor and can take values between 0 and 1. The vector function F results from the space discretization of the right hand side of equation (1). The form that F takes depends on the geometry and conditions of the problem in question. For a one-dimensional problem with constant thermal properties an ith component of F is _ K

p 5x2

~1

(3)

If there is a step change in the conductivity at the phase change interface then equation (4) is modified as

L 73].

(4a)

where

if T <r T

f v 1 "-2 -^liquid

if T > T l i > J r

In a two dimensional problem in a square region nh x nh covered with a square mesh of side h, with node numbering from bottom left to top right, an ith component of F is _ K Note that both (4) and (5) give components of F at internal nodes. For nodes on or adjacent to boundaries the form of a component of F will need modification. The relationship between the respective nodal enthalpies and temperature in equation (3) is given by equation (2). Since the three possible forms of this relationship are not known a priori, in cases when B > 0 (i.e. implicit solutions), equation (3) becomes a non-linear set of equations. A common approach to solving such equations is to use a modified Gauss-Seidel iterative scheme as suggested by Ortega & Rheinbolt (1970). Meyer (1973) uses equation (2b) writing (3) in terms of T If at time t = j 5t the vector of nodal temperatures T1 is known the corresponding vector at time t = (j+l) 5t, i.e. T ; + 1 may be calculated from (6). The components of an initial estimate TJ0+ i are calculated from tF{], (7)

204

V. R. VOLLER

i.e. the explicit scheme (6 = 0) is used to approximate H J + 1 and the initial estimate for T J + 1 follows from equation (2a). The initial estimate for TJ+1 is improved upon via the Gauss-Seidel iteration in which the k+ lth estimate is given by

where

f 0,

-e>Th

l-L, rc+xe,

R*m = <C+L/2e+X6, {C + X8, and

Tt>e -e>T,,

-e^T.^e, T,>e

Downloaded from imajna.oxfordjournals.org at kingstonuni on July 8, 2011

The value of the parameter X and the form of the vector function G depends on the problem geometry and conditions. In a one-dimensional problem with F defined by equation (4) (9) For a two-dimensional problem with F defined by equation (5)

and

GT) = -^iJi_l

+ Ti-n + Ti+a+Ti+l).

(10)

In all cases the most current iterative values of temperature are used to calculate Equation (8) is applied until a convergence criterion is satisfied with the values of a* and p* calculated at the beginning of each iteration. On convergence the procedure is repeated to find T1+1 and so on. The major drawback in using equation (2b) is that as e -> 0 the iterative scheme defined by equation (8) will not converge due to the rapid change in H(T\ reducing to a jump discontinuity when = 0, near T = 0. In practice as E becomes small the value of a,* associated with the node which is centred on the control volume undergoing the phase change, jumps between values close to 0 and L in successive iterations making the convergence of equation (8) impossible. One way of overcoming the above problem is to use equation (2a) and write equation (3) in terms of the enthalpy H. This step will involve employing the function <I>(H). This function is piecewise continuous for all values of e (in particular = 0). In this manner equation (3) becomes X where (11)

205

Shamsundar & Sparrow (1975) have solved equation (11) via a Gauss-Seidel-type iterative scheme, a method that has been numerically investigated by White (1983a, b). With known nodal enthalpies HJ at time t = j 5t initial approximations are obtained from the explicit scheme, (12) These initial approximations are improved upon via the Gauss-Seidel iterations defined by

X8EL

Downloaded from imajna.oxfordjournals.org at kingstonuni on July 8, 2011

-C

, 1 C'

XB

H,>Ce + L, -C >H ^

The value of X and X form of G, are defined above, equations (9) and (10), for simple one- and two-dimensional examples. An alternative way of solving equation (11) is to use a Newton method. Such a method has been presented by Longworth (1975). With the nodal enthalpy field known at time t = j dt an initial approximation for the nodal enthalpies at time t = (J+l)5t is made via equation (12). This is improved upon by a sequence of corrections

where the ith component of Cm is

CC(]

(14)

-"

l-

and

In the three methods outlined above, for solving the implicit discretization of the enthalpy method, the form of the iterative scheme, equations (8), (13) and (15), at

206

V. R. VOLLER

each time step depend on the nodal temperature or enthalpy field at that time step. Since only approximations exist (viz. equations (7) and (12)) for these values at the start of an iterative loop the form of the scheme may be expected to change during the iterations. This makes it necessary to check the nodal enthalpy or temperature fields at the end of each iterative sweep and modify the vectors a* and P* or at, j) or Jm as appropriate. This restriction introduces an element of inefficiency into the various schemes. An approach proposed by Furzeland and Elliott (see Furzeland, 1980) results in an iterative scheme which does not require a detailed check of the solution fields. The enthalpyfinite-differencc-schemeequation (3) is written as H{+1+WT<>+1 =b, where bi = H{+5t(l-0)F{+5t6Gl+i. (18)

Downloaded from imajna.oxfordjournals.org at kingstonuni on July 8, 2011

(17)

Equation (17) may be written in a point iterative form. If at each node point i, when calculating thefcthiterative values, bt is considered to be a constant (i.e. independent of [7IK+1) a Newton linearization leads to an "inner" iterative scheme for [73^ +1 which on dropping the k subscript is

b

'

^ ^ ^

[ 7 J i + 1

(19)

where the subscript p indicates the position of the inner iteration. The Furzeland/Elliott iterative scheme may be implemented as follows. Initial estimates [T] +1 are generated from equation (7). During the k + lth iteration at each node point in turn bt is calculated using the most current available values. From equations (2) if -e(C + X6) <bt< then [TUtti = (bi-L/2)/(C + X9 + L/2e). If b, lies outside this range then an estimate for [70i+i is provided on performing the inner iteration defined in equation (19) where for the simple test problems outlined above the iteration was performed only once. The Furzeland/Elliott approach is a very neat method in which the main iteration formulas are independent of the iterated values. Although this technique is relatively simple to implement in its "raw state" to make it work at maximum efficiency is more difficult. For example the question should be asked, how should the termination of the inner iteration be governed? Essentially, what is the required number of inner iterations (p) on equation (19) to optimize the convergence of the outer iterations (fc). Furzeland (1980) suggests that SOR in the outer iterations may be beneficial. The optimum choice of SOR is also an area which requires exploration (Elliott, 1981). e(C + X8)+L

207

4. A New Implicit Solution Method The aim of this section is to present a new implicit solution method. Like the Furzeland/Elliott scheme the form of the iterative equations derived are independent of the nodal solution fields. In addition the method performs efficiently in its raw state without the need of additional enhancements. The basic principle in the new implicit enthalpy method is to separate out the latent and sensible heat components. First equation (1) is written as ! ( C r + A#) V.(KVT), (20) or where on assuming the relationship between enthalpy and temperature as given by equation (2b) CO, AH = <L/2(T+e), - e ^ T, -e<T<e, (21)

Downloaded from imajna.oxfordjournals.org at kingstonuni on July 8, 2011

T>e

is the latent heat component of the enthalpy. On re-arrangement equation (20) becomes pC = V.(KVT) + S at where S is a latent heat source given by (22)

The essential feature of equation (22) is that the latent heat contribution has been included into the formulation via a source term. On seeking an implicit finitedifference solution this fact ensures that the non-linearity associated with the latent heat may be isolated and dealt with efficiently. On defining AH to be the vector of nodal latent heats given by equation (21) a general finite-difference scheme for equation (22) is CT>+1 = CTi + 5t(l-ff)F(J') + 5teF(TJ+1) + S'+\ where (24)

The vector S in equation (24) can be regarded as a vector of heat sources, each component representing the change in the latent heat content of the control volumes surrounding the nodes. The physical significance of S can be understood on considering a freezing problem. In a freezing problem over each time step there is a net heat loss from each control volume. For the control volumes in the (/+ l)th time interval (i.e. \J 5t, (j+1) <5r]) this heat loss may be estimated as Q>+1 = 5t(l-ff)F(TJ)+5t8F(JJ+l). (25)

208

- R- VOLLER

In control volumes in which no phase change occurs in the (j+ l)th time interval all the heat loss is accounted for by a change in the sensible heat (i.e. CT). If a phase change occurs within a control volume in the time interval then only a fraction of the heat loss is accounted for by a change in the sensible heat The remainder of the heat loss is accounted for by a latent heat change. The value of Sj*1 will give this latent heat change in the ith control volume. Hence in each control volume during the (J+ l)th time interval the latent heat loss can be calculated as

S{

_r0;^<- fi -|_4+l;

(26)

where the condition T / < - e and TtJ+1 > e implies that no phase change occurs in the ith control value during the (J+ l)th time interval. The value of A{+1 in equation (26) will depend on the fraction of the time interval in question over which the phase change occurs in the ith control volume. There are three possibilities. The phase change in control volume i (1) commences at a point in the time interval, (2) occurs over the entire interval or (3) is completed at a point in the time interval. With these possibilities in mind A{+1 can be calculated as -i?[ei+1-C(^-)], RQ{+\ T/>e, (27)

The value R represents the fraction of heat loss accounted for by the latent heat change during the phase change. If the temperature enthalpy relationship is of the form given in equation (2) then For a melting problem similar equations may be employed for calculating S{+1 with appropriate sign changes in the conditions. An efficient solution methodology for equation (24) is as follows. In each time step a. Gauss-Seidel iteration is defined as

(28) where F and G are functions of T as defined above and If the ith control volume is identified as changing state (i.e. 0 < [Aff jj( + 1 < L) then the nodal temperature is set as

via equation (2). On the completion of each iterative sweep the values of [S])(ti and

ENTHALPY FORMULATION OF STEFAN PROBLEMS Initial values T + ' Generated from explicit scheme equation (30)

209

Convergence check

If convergence go to next time step FIG. 1. Major steps in solution over one time itep.

hence [AtfJ^+i are updated via a suitable iterative form of equation (26). This procedure is continued to convergence. To initialize the procedure on each new time step, values [T]o+1 a r e generated via the use of a fully explicit scheme with S^+ * set to zero, i.e.

(30)

Initial values [Syo+ i are then estimated via equation (26) with (31) In the control volumes where [SJ 0 + 1 ^ 0 0 e tne

210

- R- VOLLER

. (32)

Figure 1 is a flowsheet which illustrates the major steps in the solution for one time step.

5. Comparison of Methods

In comparing the techniques outlined in this paper for computational efficiency care has to be taken that none of the methods is biased by the chosen implementation. To safeguard against this, where possible, the basic structure of the software for each technique was similar. In addition the convergence criterion

, (33,

where y is a prescribed tolerance, was used in all techniques. The performance of all the techniques presented in the paper may be enhanced by relaxation techniques. The major aim of the current work, however, is to test the relative performance of the available techniques in their basic form. Hence in the comparison runs relaxation was not employed In comparing the results four methods will be examined. The method based on equation (13) will be called "White", the method based on equation (15) will be referred to as "Longworth", the method based on equation (19) will be referred to as "Furzeland" and the method described by equations ((26) and (28)) will be referred to as "New". Each of these methods was applied in a "Crank-Nicolson" mode, i.e. 9 was fixed at i. In all five runs were carried out on both the one- and twodimensional test problems. The specifications for each of these runs are recorded in Table 2. Table 3 shows numerically predicted nodal enthalpies at x = 05 m in day intervals up to 12 days for Run 1. These results are typical of all runs in that predictions from each of the methods are in agreement up to the third decimal place. In fact, the Furzeland, White and New methods are in agreement up to the fifth decimal place. In addition the number of iterations per time step required in the Furzeland, White and New methods were identical at all time steps in all runs. These results clearly indicate that each of the above methods is solving the same discrete problem.

TABLE 2 Specification of runs

Run no 1 2 3 4 5

5t (hours) 4 12 4 12 4

211

In presenting results associated with the efficiency of the methods the White method is chosen as a benchmark for CPU comparisons. In this way the CPU requirement for the White method is given the value 1 in each run with the CPU requirements of the other methods normalized appropriately. Table 4 shows a run-by-run comparison for the CPU usage on a Dec PDP 11/34 for each method to reach the termination point (i.e. 12 days in the one-dimensional problem, complete phase change in the two-dimensional problem). The major conclusion that may be drawn from these results is that the New method only requires between 049 and 0-81 the CPU time of the next best method. In addition to the above conclusion the following points are made. (1) Introduction of a mushy zone range e favours the new method. (2) The improvement in CPU usage for the new method when applied to a twodimensional problem is not as marked. This is due to the fact that in multidimensional problems more than one control volume is changing state at the same time. Hence the procedure for updating the latent heat source term has to be used more than once in each iterative sweep. This fact suggests that in complex problems in which many control volumes are changing state

TABLE 3

Enthalpy Predictions at x = 0-5 m, Run 1 Time (days) 1 2 3 4 5 6 7 8 9 10 11 12 Longworth 1035 x 10 1021 1017 1O09 1O07 1006 0-921 0-685 0-435 0182 -0O30 -0O47 White 1035 x 109 1022 1017 1009 1007 1O06 0922 0687 0437 0184 -0O33 -0047 Furzeland 1035 x 10 1022 1017 1009 1007 1O06 0922 0687 0437 0184 -O033 -O047 New 1035 x 109 1022 1017 1O09 1O07 1O06 0922 0687 0437 0184 -0033 -0047

TABLE 4

CPU usage Relative CPU requirement Run no 1 2 3 4 5 White 1 1 1 1 1 Furzeland 0726 0728 0762 0783 0738 New 0538 0521 0423 0386 0606 Longworth 1-340 1-754 1-348 1-760 No run

212

- R- VOLLER

simultaneously the CPU usage of the White or Furzeland and New methods might be compatable. (3) The programming requirements for the Furzeland method are less, e.g. in one dimension the Furzeland method required about 60 lines and the new method about 80 lines. (4) As noted above, SOR techniques may enhance the results given in Table 4. Investigations suggest that due to the small number of iterations per time step (on average 23) in the one dimensional runs, SOR would have no noticeable benefit. In two dimensions, employing the simple SOR strategy of a global value of 2 > a> > 1 for control volumes not changing state and a value of co = 1 for regions which are changing state (Elliott, 1981), does reduce the iterations. The additional complexity in the programming, however, offsets any improvement in efficiency. If SOR is to improve the efficiency then it appears that sophisticated methods for choice of an optimum co will need to be developed. One such candidate, proposed by Elliott (as reported in Furzeland, 1980) is where co is varied automatically according to the relative sizes of the two-phase regions. 6. Conclusions The aim of this paper has been to investigate and develop implicit numerical solution methods for the enthalpy formulation of phase change problems. The approach adopted has been pragmatic in nature and the major interest has been in the development of an implicit enthalpy method which is computationally more general and efficient than existing methods. A rigorous analysis of the numerical techniques presented is left to another time. The basic principle in the development of the new implicit method is the separation of sensible and latent heat terms in a discretized enthalpy formulation, thereby introducing a latent heat source in the equations which acts as a linearization term in subsequent iterative solutions. This represents an advantage over previous schemes in that the form of the iterative scheme does not depend on the iterated values. In addition, only one variable (i.e. temperature) is explicitly solved for at each time step. In application to simple one- and two-dimensional solidification test problems the New method is 20-50% faster than previous methods. Having an efficient means of solving the enthalpy formulation does not create a "magical" means of solving all phase-change problems. The inherent drawbacks found in use of the enthalpy method, Voller et al. (1979), Bonacina et al. (1973), will still make themselves noticed. Hence there is still a need for remedial schemes such as those proposed by Voller & Cross (1981, 1983a, b). With an efficient implicit enthalpy solution, however, such schemes may be applied more effectively (Voller & Cross, 1983b). Application of the methods developed in this work to more complex problems, e.g. geometric complex regions or variations in thermal properties, although "messy", should be possible. The reason for this is that the development of the method is compatible with the control volume conservation numerical technique

213

(Patanker, 1980; Schneider, Strong & Yaranovich, 1975). This approach in the development of a numerical scheme copes well with such situations. Essentially all that is required is the correct formulation of the discrete equations describing heat flow in and out of control volume [e.g. Equation (4a)]. Enthalpy methods have proved a useful means of solving relatively simple phasechange problems. Current interest, however, is directed towards applications of enthalpy formulations in more complex problems, e.g. convective/conduction phase change (Morgan, 1981; Gartling, 1980). To move into such areas, accurate, efficient, flexible and robust enthalpy schemes are required. The enthalpy scheme presented in this paper, it is hoped, goes some way towards meeting these requirements. The author would like to thank Dr C. M. Elliott of Imperial College, London, Dr M. Cross of Thames Polytechnic and the referees of the IMA Journal of Numerical Analysis for many helpful comments.

REFERENCES

C , COMINI, G., FASANO, A. & PRIMICERIO, M. 1973 Numerical solutions of phase change problems. Int. J. Heat Mass Transfer 16, 1825-1832. ELLIOTT, C. M. 1981. On thefiniteelement approximation of an elliptic variational inequality arising from an implicit time discretization of the Stefan problem. IMA J. num. Analysis 1, 115-125. FURZELAND, R. M. 1980 A comparative study of numerical methods for moving boundary problems. /. Inst. Maths Applies 26, 411-429. GARTLING, D. K. 1980 Finite element analysis of convective heat transfer problems with change of phase. In Computer Methods in Fluids (Morgan, K., Taylor, C. & Brebbia, C. A., Eds). London: Pentech. LONGWORTH, D. 1975 A numerical method to determine the temperature distribution around' a Moving Weld Pool. In Moving Boundary Problems in Heat Flow and Diffusion (Ockendon, J. R. & Hodgkins, W. R., Eds). Oxford: OUP. MEYER, G. H. 1973 Multi-dimensional Stefan problems. SIAM J. num. Analysis 10, 522-538. MORGAN, K. 1981 Numerical analysis of freezing and melting with convection. Comput. Meth. app. Mech. Engng 28, 275-284. ORTEGA, J. & RHEINBOLT, W. 1970 Iterative Solutions of Non-linear Equations in Several Variables. New York: Academic Press. PATANKAR, S. V. 1980 Numerical Heat Transfer and Fluid Flow. New York: Hemisphere.

BONACINA,

finite difference solution of the conduction equation in orthogonal curvilinear coordinates. ASME Annual Meeting, Houston, Texas, 1975. New York: ASME publications. SHAMSUNDAR, N. & SPARROW, E. M. 1975 Analysis of multi-dimensional conduction phase change via the enthalpy model. J. Heat Transfer ASME 97, 33-340. VOLLER, V. R. 1983 Interpretation of the enthalpy in a discretized multi-dimensional region undergoing a phase change. Int. Commun. Heat Mass Transfer 10, 323-328. VOLLER, V. R. & GROSS, M. 1981 Accurate solutions of moving boundary problems using the enthalpy method. Int. J. Heat Mass Transfer 24, 545-556. VOLLER, V. R. & CROSS, M. 1983a An explicit numerical mediod to track a moving phase change front. Int. J. Heat Mass Transfer 26, 147-150. VOLLER, V. R. & CROSS, M. 19836 Use of the enthalpy method in the solution of Stefan problems. In Numerical Methods in Thermal Problems, Vol. 3 (Lewis, R. W., Johnson, J. A. & Smith, W. R., Eds). Swansea: Pineridge Press. VOLLER, V. R., CROSS, M. & WALTON, P. 1979 Assessment of the weak solution technique for solving Stefan problems. In Numerical Methods in Thermal Problems (Lewis, R. W. & Morgan, K., Eds). Swansea: Pineridge Press.

214

WHITE,

- R- VOLLER

R. E. 1982a An enthalpy formulation of the Stefan Problem. SIAM J. num. Analysis 19, 1129-1157. WHITE, R. E. 1982* A numerical solution of the enthalpy formulation of the Stefan Problem. SIAM J. num. Analysis 19, 1158-1172.