Generalized Coordinate System
Total Page:16
File Type:pdf, Size:1020Kb
Appendix A Generalized Coordinate System In this appendix, vector and tensor derivatives are presented for a generalized coordinate system. Also derived in this appendix are the governing equations for fluid flows with contravariant components of the velocity vector for the generalized coordinate system. A.1 Vector and Tensor Analysis For the fundamentals of vector and tensor analysis, we refer readers to mathematics textbooks as necessary. To gain further knowledge on tensors for fluid and continuum mechanics, one can refer to textbooks by Aris [1] and Flügge [2]. A.1.1 Coordinate Transform As a preparation to transform the governing equations from physical space to com- putational space, let us introduce the fundamental relationship between two arbitrary oblique coordinate systems. Oblique Coordinate System and Basis = , , Consider three linearly independent vectors gi (i 1 2 3) positioned at the origin O as shown in Fig. A.1. If we represent a position vector with x for an arbitrary point P with the linear superposition of gi, = i , x x gi (A.1) © Springer International Publishing AG 2017 309 T. Kajishima and K. Taira, Computational Fluid Dynamics, DOI 10.1007/978-3-319-45304-0 310 Appendix A: Generalized Coordinate System Fig. A.1 Oblique coordinate x3 basis vectors gi and reciprocal basis vectors gj g3 g3 g2 O 2 g1 g2 x g1 x1 1, 2, 3 , , we refer to x x x as the coordinates and g1 g2 g3 as the basis vectors. In general, when the subscripts or superscripts appear in pairs, it implies summa- 1 i = 3 i tion. For example, a bi i=1 a bi. In what follows, we imply summation when the same indices appear twice unless otherwise noted. The vectors gi are not neces- sarily normalized (unit vectors) nor orthogonal but we assume that they follow the right-handed coordinate system. Next, let us introduce reciprocal basis vectors (dual basis vectors) gi (i = 1, 2, 3) · j = δj 1 2 3 1 = such that gi g i . Because g is orthogonal to g and g , we can say g α( 2 × 3) α > · 1 = g g , where 0 for a right-handed system. Noting that g1 g 1, we α = / · ( × ) find that 1 g1 g2 g3 . Generalizing this observation, we have g × g g × g g × g g1 = 2√ 3 , g2 = 3√ 1 , g3 = 1√ 2 , (A.2) g g g √ = · ( × ) = · ( × ) = · ( × ) where g g1 g2 g3 g2 g3 g1 g3 g1 g2 is the triple product of vectors which corresponds to the volume of the box made by the three edges of g1, g2, and g3 as shown in Fig. A.1. The position vector for point P can also be represented by the linear superposition of the reciprocal basis vectors i x = xi g . (A.3) i We refer to x as the contravariant components and xi as the covariant components. FigureA.2a illustrates in two dimensions the relationship between the two compo- nents. The contravariant components can be rewritten as xj = x · gj (A.4) j = iδj = i · j because x x i x gi g . The covariant components can be expressed as = · xi x gi (A.5) 1In Sect.1.3.4, we did not distinguish between the superscripts and subscripts. Appendix A: Generalized Coordinate System 311 (a) (b) x2 P x2 P x2g2 x 2 2g x x x1 1 2 g x g2 x 1 x 1g x1 2g2 x1 1 x x g1 1g1 O O Fig. A.2 Two-dimensional representation of the relationship between contravariant and covariant components of vectors. a Contravariant and covariant components. b Geometrical relationship = δj = j · because xi xj i xj g gi. The vectors shown by the dashed lines in Fig. A.2b represent the above inner product relations. Transformation Matrix Consider an oblique coordinate system with another set of basis vectors gi and a corresponding set of reciprocal basis vectors gi. In this case, let us represent the i position vector x with contravariant components ξ and covariant components ξi = ξi = ξ i. x gi i g (A.6) The coordinate transformation between the two coordinates can be expressed using the contravariant components as ∂ξj dξj = Ajdxi, Aj = , (A.7) i i ∂xi [ j] 1 2 3 where Ai is the coordinate transformation matrix. Since g1, g2, g3 and g , g , g are both linearly independent bases, the coordinate transformation matrix is regular | j| = (i.e., Ai 0) with j k = δk AiAj i (A.8) [ i]=[ j]−1 whose inverse matrix is Aj Ai . The inverse transform of the contravariant components is i i i ∂x dxi = A dξj, A = . (A.9) j j ∂ξj For completeness, we list the components of the inverse matrix: 312 Appendix A: Generalized Coordinate System ⎫ 2 3 2 3 3 1 3 1 1 2 1 2 1 A A − A A 1 A A − A A 1 A A − A A ⎪ A = 2 3 3 2 , A = 2 3 3 2 , A = 2 3 3 2 ⎪ 1 | j| 2 | j| 3 | j| ⎪ Ai Ai Ai ⎪ ⎪ 2 3 2 3 3 1 3 1 1 2 1 2 ⎬ 2 A A − A A 2 A A − A A 2 A A − A A A = 3 1 1 3 , A = 3 1 1 3 , A = 3 1 1 3 (A.10) 1 | j| 2 | j| 3 | j| ⎪ Ai Ai Ai ⎪ ⎪ 2 3 2 3 3 1 3 1 1 2 1 2 ⎪ 3 A A − A A 3 A A − A A 3 A A − A A ⎪ A = 1 2 2 1 , A = 1 2 2 1 , A = 1 2 2 1 ⎭⎪ 1 | j| 2 | j| 3 | j| Ai Ai Ai | j|= ijk 1 2 3 Here, the determinant Ai e Ai Aj Ak, where ⎧ ⎨⎪e123 = e231 = e312 = 1 (even permutation) eijk = e321 = e213 = e132 =−1 (odd permutation) (A.11) ⎩⎪ 0 (otherwise) is called the permutation symbol or the Levi–Civita symbol. Transformation of Vectors and Tensors = i = i ξj From Eqs. (A.1) and (A.9), we see that dx dx gi Ajd gi, and likewise from = ξj = j i Eqs. (A.6) and (A.7), dx d gj Aidx gj. By comparing these two relations, we find the transformation equations for the basis vectors = i , = j . gj Aj gi gi Ai gj (A.12) On the other hand, by denoting the transformation for the reciprocal basis vectors as j = j k δj = j · = j k · l = j k j = j g Bk g ,wehave i g gi Bk g Ai gl BkAi , which shows that Bk Ak. The inverse transform can be derived in a similar manner, yielding j = j i, i = ij. g Ai g g Aj g (A.13) Let us now consider an arbitrary vector = i = i = i = i. u u gi ui g U gi Ui g (A.14) By substituting Eqs. (A.12) and (A.13) into the above equation, we can derive the coordinate transform between vector components. The transformation between covariant components have the same form as the basis vector transformation = i , = j . Uj Ajui ui AiUj (A.15) The transformation between contravariant components has the opposite form from the basis vector transformation j = j i, i = i j. U Aiu u AjU (A.16) Appendix A: Generalized Coordinate System 313 The use of the term covariant or contravariant refers to whether the transformation follows the form of the basis vector transformation. In general, for a tensor of contravariant order m and covariant order n ··· ··· T = ti1 im g ···g gj1 ···gjn = T k1 km g ···g gl1 ···gln , (A.17) j1···jn i1 im l1···ln k1 km the following coordinate transform ··· j j ··· T k1 km = Ak1 ···Akn A 1 ···A n ti1 im (A.18) l1···ln i1 in l1 ln j1···jn is satisfied. Metric Ttensors and Physical Components Denoting the magnitude of a vector u by u,wehave 2 = ( i ) · ( j ) = i j( · ). u u gi u gj u u gi gj (A.19) Here, we can define the covariant metric tensor as = · , gij gi gj (A.20) which is a symmetric tensor that relates the contravariant components and the mag- nitude of the vector. We can also define an analogous tensor for the other coor- = · 2 = k l dinate system, i.e., gij gi gj. Comparing the relations of u U U gkl and 2 = i j = i j k l u u u gij AkAlU U gij, we find the transformation equations for the covariant metric tensor are = i j , = k l . gkl AkAi gij gij Ai Aj gkl (A.21) We define g to be the determinant of the covariant metric tensor g ≡|gij| (A.22) and similarly define g ≡|gij|. Accordingly, by taking the determinant of Eq. (A.21), we can derive that g ≡|A|2g. (A.23) = By denoting the unit basis vector√ by ei for the basis vector gi,wehavegi aei. · = 2 · = 2 = Since gi gi a ei ei a , a gii. This tells us that gi ei = √ . (no summation implied) (A.24) gii Because a basis composed of unit vectors are related to physical scales, we refer to components represented by unit basis vectors as physical components. The physical contravariant component representation u(i) of vector u is 314 Appendix A: Generalized Coordinate System = i = (i) , u u gi u ei (A.25) where √ (i) i u = u gii. (no summation implied) (A.26) The physical contravariant components for tensors are √ √ (ij) ij t = t gii gjj. (no summation implied) (A.27) Transformation Between Covariant and Contravariant Components For reciprocal vectors, let us define the contravariant metric tensor gij = gi · gj.