Thompson, Warsi, Mastin - Numerical Grid Generation (523190), страница 12
Текст из файла (страница 12)
Volume elementAn increment of volume is given by(12)But, by the identity (9),Also from (9),and by the vector identity(13)we haveso that with the dot products replaced according to the definition (5),This last expression is simply the determinant of the (symmetric) covariant metric tensorexpanded by cofactors. Therefore(14)so that the volume increment can be written(15)where(called the Jacobian of the transformation) can be evaluated by either of thefollowing expressions:(16)3.
Derivative OperatorsExpressions for the derivative operators, such as gradient, divergence, curl, Laplacian,etc., are obtained by applying the Divergence Theorem to a differential volume incrementbounded by coordinate surfaces. The gradient operator then leads to the expression ofcontravariant base vectors in terms of the covariant base vectors, and to the contravariantmetric tensor as the inverse of the covariant metric tensor.By the Divergence Theorem,(17)for any tensor , where is the outward-directed unit normal to the closed surface Senclosing the volume V.
For a differential surface element lying on a coordinate surface wehave, by Eq. (8),(18)with the choice of sign being dependent on the location of the volume relative to the surface.Then considering a differential element of volume, V, bounded by six faces lying oncoordinate surfaces, as shown in the figure on p. 98, we have, using Eq. (15) and (18),(19)where the notationandindicates the element on i two sides of the which isconstant and which are located at larger and smaller values, respectively, of .
Here, asusual, the indices (i,j,k) are cyclic.A. DivergenceProceeding to the limit as the element of volume shrinks to zero we then have an expressionfor the divergence:(20)where, as noted, the subscripti onthe bracket indicates partial differentiation.A basic metric identity is involved here, sinceThe indices (i,j,k) are cyclic, and therefore the last summation may be written equivalentlyasSince this is then the negative of the first summation we have the identity,(21)This is a fundamental metric identity which will be used several times in the developmentsthat follow. This identity also follows directly from Eq.
(20) for uniform . It then followsthat the divergence can also be written as(22)Although the equations (20) and (22) are equivalent expressions for the divergence,because of the identity (21), the numerical representations of these two forms may not beequivalent. The form given by Eq. (20) is called the conservative form, and that of Eq. (22),where the product derivative has been expanded and Eq. (21) has been used, is called thenon-conservative form.
Recalling that the quantityrepresents an increment ofsurface area (cf.Eq. (8)), so thatis a flux through this area, it is clear that thedifference between the two forms is that the area used in numerical representation of the fluxin the conservative form, Eq. (20), is the area of the individual sides of the volume element,but inthe nonconservative form, a common area evaluated at the center of the volumeelement is used. The conservative form thus gives the telescopic collapse of the flux termswhen the difference equations are summed over the field, so that this summation theninvolves only the boundary fluxes.
This would seem to favor the conservative form as thebetter numerical representation of the net flux through the volume element.It is important to note that since the conservative form of the divergence, and of thegradient, curl, and Laplacian to follow, is obtained directly from the closed surface integralin the Divergence Theorem, the use of the conservative difference forms for these derivativeoperators is equivalent to using difference forms for that closed surface integral. Thereforethe finite volume difference formulation can be implemented by using these conservativeforms directly in the differential equations of motion without the necessity of returning to theintegral form of the equations of motion.B.
CurlSince Eq. (17) is also valid with the dot products replaced by cross products, theconservative and non-conservative expressions for the curl follow immediately from Eq. (20)and (22):(23)and(24)These expressions can also be written, using Eq. (13), as(25)and(26)C. GradientEq. (17) is also valid with replaced by a scalar, and the dot product replaced by simpleoperation on the left and multiplication on the right. Therefore the conservative andnon-conservative expressions for the gradient also follow directly from Eq.
(20) and (22) as(27)and(28)D. LaplacianbyThe expressions for the Laplacian then follow from Eq. (20) or (22), withA from Eq. (27) or (28). Thus the conservative form isreplaced(29)and the non-conservative is(30)With the product derivative expanded, the non-conservative form, Eq. (30), can also bewritten as(31)4. Relations Between Covariant and Contravariant MetricsA. Base vectorsThe expression (28) for the gradient allows the contravariant base vectors to beexpressed in terms ofthe co-variant base vectors as follows. With A= m in (28), we havesince the three curvilinear coordinates are independent of each other. Then(32)This gives a relation between the derivatives of the curvilinear coordinates ( i)x and thelderivatives (xr) s of the cartesian coordinates.
By Eq. (4) the contravariant base vectorsmaybe written in terms of the covariant base vectors as(33)By Eq. (33),where here (j,k,l) are cyclic. If ji, either k or l must be i, and in that case the right-handsidevanishessince the three vectors in the triple product may be in any cyclic order and thecross product of any vector with itself vanishes. When j=i, the right-hand side is simplyunity. Therefore, in general(34)Because of this relation, any vectorascan be expressed in terms of either set of base vectors(35)and(36)Here the quantitiesandcomponents, respectively, of the vector, are the contravariant and co-variant.B. Metric TensorsThe components of the contravariant metric tensor are the dot products of thecontravariant base vectors:(37)The relation between the covariant and contravariant metric tensor components is obtainedby use of Eq.
(33) in (37). Thus, with (i,j,k) cyclic and (l,m,n) cyclic,by the identity (9). Then from the definition (5),(38)Since the quantity in parentheses in the above equation is the signed cofactor of the ilcomponent of the covariant metric tensor, the right-hand side above is the li component ofthe inverse of this tensor. Then, since the metric tensor is symmetric we have immediatelythat the contravariant metric tensor is simply the inverse of the covariant metric tensor. Itthen follows thatso that, in terms of the contravariant base vectors, the Jacobian is(39)The identity (21) can be given, using Eq.
(33), as(40)5. Restatement of Derivative OperatorsIn view of Eq. (33), the cross products of the co-variant base vectors in the expressionsgiven above for the gradient, divergence, curl, and Laplacian can be replaced directly by thecontravariant base vectors (multiplied by the Jacobian). The components of thesecontravariant base vectors i in the expressions are the derivatives of the curvilinearcoordinates with respect to the cartesian coordinates, and this notation, rather than thecross-products, often appears in the literature.
Thus, by Eq. (4), the x j-component of ai canbe written as(41)The expressions for the gradient, divergence, curl, Laplacian, etc., given above interms of the cross products of the covariant base vectors, i, involve the derivatives of thecartesian coordinates with respect to the curvilinear coordinates, e.g. (xi) j. The expressionsgiven below in terms of the contravariant base vectors,i,involve the derivatives ( i)xjwhenis evaluated from (39).
From a coding standpoint, however, the contravariant basevectors i in these expressions would be evaluated from the covariant base vectors using Eq.(33).A. ConservativeThe conservative forms are as follows:(42)(43)(44)(45)By expanding the inner derivative, the Laplacian can be expressed as(46)Forwe have(47)or, with the inner derivative expanded,(48)In the expressions for the divergence,may be a tensor, in which case we have(49)From Eq. (42) we have the conservative expressions for the first derivative:(50)whereis the component in the x j-direction. Also, for the second derivative,(51)or, with the inner derivative expanded,(52)It then follows that all of the above conservative expressions can be written in theform(53)where the quantity Ai takes the following form for the various operatfons, with i = 1,2,3,(54)(55)(56)matrix product of square matrixand column vectori.Herei isa vector)(57)(58)(59)(60)(61)(62)(63)(64)It is computationally more efficient to evaluate the producti asan entity from Eq.(33) when the conservative forms are used, in order to avoid the extra multiplication by .Another alternative is to includewith .B.
Non-conservativeThe non-conservative relations are as follows:(65)From Eq. (65) the p operator can be represented by(66)and(67)(68)(69)Since(70)by Eq. (37) and (69), the Laplacian can also be written as(71)Using Eq. (67) and (65) we also haveThus, by Eq. (70), the non-conservative expression is(72)A more practical equation than Eq. (70) for the evaluation ofbe obtained as follows.2Since2 j inthese expressions can=0 it follows from Eq.
(71) that(73)Butj=so that2 l isj.Then dottingl intothis equation and using Eq. 34, we havegiven by(74)The non-conservative form of the divergence of a tensor is, by expansion in Eq. (49),(75)From Eq.(65) the non-conservative expressions for the first and second derivatives are(76)and(77)This non-conservative form in terms of the contravariant base vectors is referred to bysome as the "chain-rule conservation" form (Eq. (76) is equivalent to Eq. (1)). In any caseonly the conservative form gives the telescopic collapse over the field that characterizesconservative numerical representations, and it is necessary to substitute for the contravariantbase vectors from Eq. (33) in implementation, since it is the covariant base vectors that aredirectly calculated from the grid point locations.6.
Normal and Tangential DerivativesExpressions for derivatives normal and tangential to coordinate surfaces are needed inboundary conditions and are obtained from the base vectors as follows.A. Tangent to coordinate linesSince the covariant base vectors are tangent to the coordinate lines, the tangentialderivative on a coordinate line along which i varies is given byusing Eq. (65). In view of Eq. (34), this reduces to(78)B.
Normal to coordinate surfacesAlso, since the contravariant base vectors are normal to the coordinate surfaces, thenormal derivative to a coordinate surface on which i is constant is given by(79)C. Normal to coordinate lines and tangent to coordinate surfacesThe vectoris normal to the coordinate line on whichtangent to the coordinate surface on which i is constant:i variesand is alsoUsing Eq. (33) and the identity (13), this vector is given by(80)and the magnitude is given byThe bracket is the negative of the second and third terms of the determinant,expanded by cofactors. Therefore, we have,(81)The derivative normal to the coordinate line on which i varies and in the coordinatesurface on which i is constant then, using Eq. (65) and (80), is given byBy Eq.