Professional Documents
Culture Documents
CH 5
CH 5
WITH
APPROPRIATE
TRANSFORMATIONS
The area of numerical grid generation is relatively young in practice, although its roots in mathematics are old. This
somewhat eclectic area involves the engineers feel for physical behavior, the mathematician understanding of
Functional behavior; and a lot of imagination, with perhaps a little help from Urania.
Joe F. Thompson, Z. V. A, Warsi, and C. Wayne Mastin, from Numerical Grid Generation, North-Holland,
New York, 1985
1. INTRODUCTION:
The arrangement of The discrete points to use finite difference or finite volume throughout the flow
field is simply called a grid. The way that such a grid is determined is called grid generation. The
matter of grid generation is a significant consideration in CFD; the type of grid you choose for a
given problem can make or break the numerical solution.
The generation of an appropriate grid or mesh is one thing; the solution of the governing flow
equations over such a grid is quite another thing. For example, The standard finite-difference
approach requires a uniform grid. We do not have a direct way of numerically solving the governing
flow equations over a nonuniform grid within the context of a finite-difference method. Instead, the
nonuniform grid must (somehow) be transformed into a uniform, rectangular grid. Moreover, along
with this transformation, the governing partial differential equations must be recast so as to apply in
this transformed, rectangular grid. Since the need for such grid transformations is inherent in the
finite-difference method, then much of what we have to say in this chapter concerning the
transformation of the governing partial differential equations pertains just to that method.
An example about non-uniform grid is: assume we wish to calculate the flow over an airfoil, as
sketched in Fig. 1. We have placed the airfoil in a rectangular grid. Note the problems with this
rectangular grid:
1. Some grid points fall inside the airfoil, where they are completely out of the flow.
2. There are few, if any, grid points that fall on the surface of the airfoil. This is not good, because
the airfoil surface is a vital boundary condition for the determination of the flow, and hence the
airfoil surface must be clearly and strongly seen by the numerical solution.
So the
rectangular grid in Fig. 5.1 is not appropriate for the solution of the flow field. In contrast, a grid
that is appropriate is sketched in Fig. 5.2 a. Here we see a nonuniform, curvilinear grid which is
literally wrapped around the airfoil. New coordinate lines and are defined such that the airfoil
surface becomes a coordinate line, = constant. This is called a boundary-fitted coordinate
system.
In fig 5.2 a ,we can't apply FDM to this plane as it isn't a rectangular ,uniform grid. So we have to
transform this plane to a uniform plane as in fig. 5.2b. The rectangular grid shown in Fig. 5.2b is
called the computational plane. The transformation must be defined such that there is a one-to-one
correspondence between the rectangular grid in Fig. 5.2b and the curvilinear grid in Fig. 5.2a, called
the physical plane. For example, points a, b, and c in the physical plane (Fig. 5.2a) correspond to
points a, b, and c in the computational plane. the governing equations are solved in the
computational space, they must be expressed in terms of the variables and rather than of x and y.
That is, the governing equations must be transformed from (x, y) to (t, q ) as the new independent
variables.
The purpose of this chapter is to first describe the general transformation of the governing partial
differential equations between the physical plane and the computational plane.
The coefficients of the derivatives with respect to , , and are called metrics; for example,/x,
/y, /x, and /y are metric terms which can be obtained from the general transformation
given by Eqs. (5. la) to (5. lc).
Let u =
u(x, y), x = x(,) and y = y(,). The total differential of u is given by
Equations (5.20) and (5.21) can be viewed as two equations for the two unknowns u/x and u/y.
Solving the system of Eqs. (5.20) and (5.21) for u/x using Cramer's rule, we have
Examine Eqs. (5.23a) and (5.23b). They express the derivatives of the flow- field variables in
physical space in terms of the derivatives of the flow-field variables in computational space.
Another approach, by substituting in Eqs. (5.2) and (5.3) by
we get
The above two equations are identically Eqs. (5.24a) and (5.24b).
If so, we are be able to retain in our transformed space all those advantages of the strong
conservation form.
Comment: the transformation we discussed about all the chapter, is inherently not required for
finite-volume methods, which can deal directly with a nonuniform mesh in the physical plane.
as
Let us examine what happens to the governing flow equations in both the physical and the
computational planes. For simplicity, we will assume steady flow, and we will illustrate by means of
the continuity equation.
This equation can be formally transformed to the computational plane using the generic derivative
transformation given by Eqs. (5.2) and (5.3)
The metrics in Eq. (5.54) are obtained from the direct transformation given by Eqs. (5.50a) and
(5.50b)
Substituting the
metrics from Eqs. (5.55) into (5.54), we obtain
However, from Eq. (5.50b), y+ 1
= e. Therefore, Eq. (5.56) becomes
10
For this flow, a simple rectangular grid in the physical plane is not appropriate. Instead, we draw the
curvilinear grid in Fig. 5 . 6a. which allows both the upper boundary de and the centerline fg to be
coordinate lines, exactly fitting these boundaries. In turn, the curvilinear grid must be transformed
to a rectangular grid in the computational plane, Fig. 5.6b. This can be accomplished as follows. Let
ys = f (x) be the ordinate of the upper surface de . Then the following transformation will result in a
rectangular grid in (5, q) space:
we can see that all the points along the curved upper boundary in the physical plane fail, via the
transformation given by Eq. (5.66), along the horizontal line = 1 in the computational plane.
A more sophisticated example is shown in Fig. 5.7, which is an elaboration of the case the airfoil
shape given in Fig. 5.7a. A curvilinear system is wrapped around the airfoil, where one coordinate
line = 1 = constant is on the airfoil surface.
11
This is the inner boundary of the grid, designated by 1 in both the physical and computational
planes in Fig. 5.7. The outer boundary of the grid is labeled 2 in Fig. 5.7 and is given by = 2 =
constant. The shape and location of the outer boundary 2 is somewhat arbitrary-it is whatever you
choose to draw. Examining this grid, we see that it clearly fits the boundary, and hence it is a
boundary-fitted coordinate system.
let us consider the transformation in Fig. 5.7 to be defined by an elliptic partial differential
equation
For a properly posed problem dealing with elliptic equations, we need to specify boundary
conditions along the entire boundary of the domain. . To this point in our discussion, we have
specified the values of x and y along the boundaries 1 and 2 only; we need also to have some
boundary conditions given along 3 and 4 to have a properly posed problem. qp and sr - at the
trailing edge- present two additional boundaries. . In reality, qp and sr are the same curve in the xy
plane; qp simply denotes the upper surface of the cut and sr denotes the lower surface, but they lie
on top of each other. In the physical plane, the points q and s lie on top of each other, and the points
p and r also lie on top of each other; indeed, the entirety of 3 lies on top of 4. However, this is not
the case in the plane shown in Fig. 5.7b. Here, 3 and 4 are totally separated and form the right
and left boundaries, respectively, of the domain in the computational space. We choose qp ,and sr
arbitrary but we choose it we have values of x and y specified along 3 and 4 in Fig. 5.7b.
For each grid point inside the domain shown in Fig. 5.7b, these equations can be solved
numerically, along with the specified boundary values of (x, y) along 1 , 2, 3 and 4 , to give the
corresponding (x, y) values of that same grid point in the physical plane. For example, consider the
internal grid point labeled A ; this corresponds to the point labeled A in both the physical and
computational planes in Fig. 5.7. At point A in the computational plane. Eqs. (5.69) and (5.70) are
solved for its (x, y) coordinates. This now locates point A in the physical plane. The solution of
Eqs. (5.69) and (5.70) is carried out by an appropriate finite-difference solution for elliptic
equations. Because this transformation is being carried out via the solution of a system of elliptic
partial differential equations, it is called elliptic grid generation.
advantages are (1) increased accuracy for a fixed number of grid points or (2) for a given accuracy,
fewer grid points are needed.
An example of a simple adaptive grid is that for the solution of viscous supersonic flow over a
rearward-facing step. Here, the transformation is expressed in the form
where g is a primitive flow-field variable, such a s p , u, or T; If g = p , then Eqs. (5.71) and (5.72)
cluster the grid points in regions of large pressure gradients. In Eqs. (5.71) and (5.72), ,and
are fixed, uniform grid spacings in the computational plane, b and c are constants chosen to increase
or decrease the effect of the gradient in changing the grid spacing in the physical plane, B and C are
scale factors, and x and y are the new grid spacing in the physical plane.
Consider the specific grid point labeled N in Fig. 5.12b. This point is fixed in the computational
plane; it does not move with time. So is its adjacent grid point, labeled N + 1. As usual, the distance
between grid point N and N + 1 is . Now examine the corresponding grid points in the physical
plane, Fig. 5.12a. The location of points N and N + 1 in the physical plane at time level t are
13
denoted by the black dots. The distance between these two points in the x direction is (Ax)t, where
the superscript t denotes the time level t. Now consider the situation at the next time level, t+t.
Because g\x will in general change from one time level to the next during the time-marching
process. then Eq. (5.71) yields a new value of x, denoted by (x)t+t at time level t+t. Hence, the
x location of point N shifts to a new value at time t + t. Of course, because of the simultaneous
application of Eq. (5.72), the y location of point N shifts also. The new locations of points N and
N+1 at time level t + At are shown by crossmarks in Fig. 5.12a.
Here Eq(5.5) [t=] is not applied so \t and \t are finite. As The physical meaning of \t, is
the time rate of change of at a fixed (x, y) location in the physical plane. Imagine that you have
your eyes locked to a fixed (x, y) location in the physical plane. As a function of time, the values of
and associated with this fixed (x, y) location will change. This is why \t and \t are
finite.
We have
As
M denotes the value of the corresponding y index, namely, j = M as N is simply the value of the x
index, namely, i = N. From those equations we get \t and \t.
As
14
Another mesh type is Cartesian grid. The mesh cells away from the body can be rectangular, and
those cells adjacent to the body can be modified in shape such that one side of each cell is along the
body surface.
15