Professional Documents
Culture Documents
Details de Descritisation VFM
Details de Descritisation VFM
net/publication/280385280
CITATIONS READS
9 5,905
1 author:
Joel Guerrero
Università degli Studi di Genova
48 PUBLICATIONS 266 CITATIONS
SEE PROFILE
Some of the authors of this publication are also working on these related projects:
All content following this page was uploaded by Joel Guerrero on 13 June 2021.
4 Joel Guerrero
11 3 Turbulence Modeling 13
12 3.1 Reynolds Averaging . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14
13 3.2 Incompressible Reynolds Averaged Navier-Stokes Equations . . . . . . . . . . . . 16
14 3.3 Boussinesq Approximation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17
15 3.4 Two-Equations Models. The k − ω Model . . . . . . . . . . . . . . . . . . . . . . 18
1
42 Chapter 1
45 When presenting the fluid flow equations, as well as throughout this manuscript, we make use
46 of the following vector/tensor notation and mathematical operators.
47
48 From now on we are going to refer to a zero rank tensor as a scalar. A first rank tensor will
49 be referred as a vector. And a second rank tensor will associated to a tensor. Vectors will
50 be denoted by minuscule bold letters, whereas tensors by majuscule bold letters or bold greek
51 symbols. Scalars will be represented by normal letters or normal greek symbols.
52
53 Hereafter, the vector is almost always a column vector and a row vector is expressed as a
54 transpose of a column vector indicated by the superscript T . Vectors a = a1 i + a2 j + a3 k and
55 b = b1 i + b2 j + b3 k are expressed as follows
a1 b1
a = a2 , b = b2 ,
a3 b3
56 the transpose of the column vectors a and b are represented as follows
aT = [a1 , a2 , a3 ] , bT = [b1 , b2 , b3 ] ,
1 1
57 The magnitude of a vector a is defined as |a| = (a · a) 2 = (a1 2 + a2 2 + a3 2 ) 2 .
58
63 The dot product of two vectors a and b (also known as scalar product of two vectors), yields to
64 a scalar quantity and is given by
b1
aT · b = a · b = a1 , a2 , a3 b2 = a1 b1 + a2 b2 + a3 b3 .
b3
2
65 The dot product of two vectors a and b is commutative (a · b = b · a).
66
67 The cross product of two vectors a × b (also known as vector product of two vectors), is the
68 vector normal to the plane of a and b, and is defined by the determinant
i j k a2 b3 − a3 b2
a × b = a1 a2 a3 = a3 b1 − a1 b3 ,
b1 b2 b3 a1 b2 − a2 b1
69 a × b and b × a result in two different vectors, pointing in opposite directions with the same
70 magnitude (a × b = −b × a).
71
72 The tensor product (also known as dyadic product) of two vectors a ⊗ b produces a second rank
73 tensor and is defined by
a1 a1 b1 a1 b2 a1 b3
a ⊗ b = abT = ab = a2 [b1 , b2 , b3 ] = a2 b1 a2 b2 a2 b3 ,
a3 a3 b1 a3 b2 a3 b3
74 notice that unlike the dot product, the tensor product of two vectors is non-commutative
75 (a ⊗ b ̸= b ⊗ a).
76
77 The double dot product (:) of two second rank tensors A and B (also known as scalar product
78 of two second rank tensors)
A11 A12 A13 B11 B12 B13
A = A21 A22 A23 , B = B21 B22
B23 ,
A31 A32 A33 B31 B32 B33
79 produces a scalar ϕ = A:B, which can be evaluated as the sum of the 9 products of the tensor
80 components
81 The double dot product of two second rank tensors is commutative (A:B = B:A) .
82
83 The dot product of a tensor A and a vector a, produces a vector b = A · a, whose components
84 are
A11 a1 + A12 a2 + A13 a3
b = bi = Aij aj = A21 a1 + A22 a2 + A23 a3 .
A31 a1 + A32 a2 + A33 a3
85 The dot product of a non symmetric tensor A and a vector a is non-commutative (Aij aj ̸= ai Aij ).
86 If the tensor A is symmetric then b = a · A = AT · a.
87
88 The dot product of two tensors A and B (also known as single dot product or tensor product of
89 two tensors), produces another second rank tensor C = A · B, whose components are evaluated
90 as
3
91 The dot product of two tensors is non-commutative (A · B ̸= B · A).
92
93 Note that our definitions of the tensor-vector dot product and tensor-tensor dot-product are
94 consistent with the ordinary rules of matrix algebra.
95
104 The dot product of vector a and the operator ∇ is called the divergence (div) of the vector field;
105 the output of this operator is a scalar and is defined as
110 The curl operator of a vector a produces another vector. This operator is defined by
i j k
∂a3 ∂a2 ∂a1 ∂a3 ∂a2 ∂a1 T
∂ ∂ ∂
curl a = ∇ × a = = − , − , − .
∂x ∂y ∂z ∂y ∂z ∂z ∂x ∂x ∂y
a1 a2 a3
111 The divergence of the gradient is called the Laplacian operator and is denoted by ∆. The
112 Laplacian of a scalar ϕ(x, y, z) yields to another scalar field and is defined as
4
∂2ϕ ∂2ϕ ∂2ϕ
div grad ϕ = ∇ · ∇ϕ = ∇2 ϕ = ∆ϕ = + 2 + 2.
∂x2 ∂y ∂z
113 The Laplacian of a vector field a is defined as the diverge of the gradient just like in the scalar
114 case, but in this case it yields to a vector field, such that
2
∂ a1 ∂ 2 a1 ∂ 2 a1
∂x2 + ∂y 2 + ∂z 2
2
2
∂ a2 ∂ 2 a2 ∂ 2 a2
div grad a = ∇ · ∇a = ∇ a = ∆a = 2 +
2
+ .
2
∂x
2 ∂y ∂z
∂ a3 ∂ 2 a3 ∂ 2 a3
+ +
∂x2 ∂y 2 ∂z 2
115 The Laplacian transforms a tensor field into another tensor field of the same rank.
116
117 As previously discussed, a tensor is said to be symmetric if its components are symmetric about
118 the diagonal, i.e., A = AT . A tensor is said to be skew or anti-symmetric if A = −AT which
119 intuitively implies that A11 = A22 = A33 = 0. Every second rank tensor can be decomposed
120 into symmetric and skew parts by
1 1
A + AT + A − AT = symm A + skew A.
A=
|2 {z } |2 {z }
symmetric skew
125 ∇ · ∇ × a = 0.
126 ∇ × ∇α = 0.
5
133 ∇ · (αa) = α∇ · a + a · ∇α.
135 ∇ · (a × b) = b · ∇ × a − a · ∇ × b.
136 ∇ · (a ⊗ b) = b · ∇a + a∇ · b.
140 ∇ × (αa) = α∇ × a + ∇α × a.
144 ab:A = a · (b · A)
145 A:ab = (A · a) · b
146 where α and β are scalars; a, b and c are vectors; and A is a tensor.
6
147 Chapter 2
150 The starting point of any numerical simulation are the governing equations of the physics of the
151 problem to be solved. Hereafter, we present the governing equations of fluid dynamics and their
152 simplification for the case of an incompressible viscous flow.
153
154 The equations governing the motion of a fluid can be derived from the statements of the conser-
155 vation of mass, momentum, and energy [1, 2, 3]. In the most general form, the fluid motion is
156 governed by the time-dependent three-dimensional compressible Navier-Stokes system of equa-
157 tions. For a viscous Newtonian, isotropic fluid in the absence of external forces, mass diffusion,
158 finite-rate chemical reactions, and external heat addition; the conservation form of the Navier-
159 Stokes system of equations in compact differential form and in primitive variable formulation
160 (ρ, u, v, w, et ) can be written as
∂ρ
+ ∇ · (ρu) = 0,
∂t
∂ (ρu)
+ ∇ · (ρuu) = −∇p + ∇ · τ + Su (2.0.1)
∂t
∂ (ρet )
+ ∇ · (ρet u) = −∇ · q − ∇ · (pu) + τ :∇u + Set
∂t
161 where τ is the viscous stress tensor and is given by
τxx τxy τxz
τ = τyx τyy τyz . (2.0.2)
τzx τzy τzz
162 For the sake of completeness, let us recall that in the conservation form (or divergence form)
163 [4], the momentum equation can be written as
∂ (ρu)
+ ∇ · (ρuu) = −∇p + ∇ · τ , (2.0.3)
∂t
164 where the tensor product of the vectors uu in eq. 2.0.3 is equal to
2
u u uv uw
uu = v u v w = vu v 2 vw .
(2.0.4)
w wu wv w2
165 Let us recall the following identity
7
∇ · (uu) = u · ∇u + u(∇ · u), (2.0.5)
166 and from the divergence-free constraint (∇ · u = 0) it follows that u(∇ · u) is zero, therefore
167 ∇ · (uu) = u · ∇u. Henceforth, the conservation form of the momentum equation eq. 2.0.3 is
168 equivalent to
∂ (u)
ρ + u · ∇ (u) = −∇p + ∇ · τ ,
∂t
169 which is the non-conservation form or advective/convective form of the momentum equation.
170
171 The set of equations 2.0.1 can be rewritten in vector form as follows
178 The vectors ev , fv and gv contain the viscous fluxes (or diffusive fluxes) in the x, y and z
179 directions and are defined as follows
0
τxx
ev =
τxy ,
τxz
uτxx + vτxy + wτxz − qx
0
τyx
fv =
τyy ,
(2.0.9)
τyz
uτyx + vτyy + wτyz − qy
0
τzx
gv =
τzy ,
τzz
uτzx + vτzy + wτzz − qz
8
180 where the heat fluxes qx , qy and qz are given by the Fourier’s law of heat conduction as follows
∂T
qx = −k ,
∂x
∂T
qy = −k , (2.0.10)
∂y
∂T
qz = −k ,
∂z
181 and the viscous stresses τxx , τyy , τzz , τxy , τyx , τxz , τzx , τyz and τzy , are given by the following
182 relationships
2 ∂u ∂v ∂w
τxx = µ 2 − − ,
3 ∂x ∂y ∂z
2 ∂v ∂u ∂w
τyy = µ 2 − − ,
3 ∂y ∂x ∂z
2 ∂w ∂u ∂v
τzz = µ 2 − − ,
3 ∂z ∂x ∂y
(2.0.11)
∂u ∂v
τxy = τyx = µ + ,
∂y ∂x
∂u ∂w
τxz = τzx = µ + ,
∂z ∂x
∂v ∂w
τyz = τzy = µ + ,
∂z ∂y
183 In equations 2.0.9-2.0.11, T is the temperature, k is the thermal conductivity and µ is the molec-
184 ular viscosity. In order to derive the viscous stresses in eq. 2.0.11 the Stokes hypothesis was
185 used [5, 1, 6, 7].
186
187 Examining closely equations 2.0.6-2.0.11 and counting the number of equations and unknowns,
188 we clearly see that we have five equations in terms of seven unknown flow field variables u, v,
189 w, ρ, p, T , and et . It is obvious that two additional equations are required to close the system.
190 These two additional equations can be obtained by determining relationships that exist between
191 the thermodynamic variables (p, ρ, T, ei ) through the assumption of thermodynamic equilibrium.
192 Relations of this type are known as equations of state, and they provide a mathematical rela-
193 tionship between two or more state functions (thermodynamic variables). Choosing the specific
194 internal energy ei and the density ρ as the two independent thermodynamic variables, then
195 equations of state of the form
p = ρRg T, (2.0.13)
m2
199 where Rg is the specific gas constant and is equal to 287 for air. Assuming also that the
s2 K
200 working gas behaves as a calorically perfect gas (a calorically perfect gas is defined as a perfect
201 gas with constant specific heats), then the following relations hold
cp Rg γRg
ei = cv T, h = cp T, γ= , cv = , cp = , (2.0.14)
cv γ−1 γ−1
9
202 where γ is the ratio of specific heats and is equal to 1.4 for air, cv the specific heat at constant
203 volume, cp the specific heat at constant pressure and h is the enthalpy. By using eq. 2.0.13 and
204 eq. 2.0.14, we obtain the following relations for pressure p and temperature T in the form of eq.
205 2.0.12
p (γ − 1) ei
p = (γ − 1) ρei , T = = , (2.0.15)
ρRg Rg
206 where the specific internal energy per unit mass ei = p/(γ − 1)ρ is related to the total energy
207 per unit mass et by the following relationship,
1 2
u + v 2 + w2 .
et = ei + (2.0.16)
2
208 In our discussion, it is also necessary to relate the transport properties (µ, k) to the thermody-
209 namic variables. Then, the molecular viscosity µ is computed using Sutherland’s formula
3
C1 T 2
µ= , (2.0.17)
(T + C2 )
210 where for the case of the air, the constants are C1 = 1.458 × 10−6 mskg
√
K
and C2 = 110.4K.
211
212 The thermal conductivity, k, of the fluid is determined from the Prandtl number (P r = 0.72 for air)
213 which in general is assumed to be constant and is equal to
cp µ
k=
, (2.0.18)
Pr
214 where cp and µ are given by equations eq. 2.0.14 and eq. 2.0.17 respectively.
215
216 When dealing with high speed compressible flows, it is also useful to introduce the Mach number.
217 The mach number is a non dimensional parameter that measures the speed of the gas motion
218 in relation to the speed of sound a,
1 r
∂p 2 p p
a= = γ = γRg T . (2.0.19)
∂ρ S ρ
219 Then the Mach number M∞ is given by,
U∞ U∞ U∞
M∞ = =p =p (2.0.20)
a γ(p/ρ) γRg T
220 Another useful non dimensional quantity is the Reynold’s number, this quantity represents the
221 ratio of inertia forces to viscous forces and is given by,
ρ∞ U∞ L
Re = , (2.0.21)
µ∞
222 where the subscript ∞ denotes freestream conditions, L is a reference length (such as the chord
223 of an airfoil or the length of a vehicle), and µ∞ is computed using the freestream temperature
224 T∞ according to eq 2.0.17.
225
226 The first row in eq. 2.0.6 corresponds to the continuity equation. Likewise, the second, third
227 and fourth rows are the momentum equations, while the fifth row is the energy equation in terms
228 of total energy per unit mass.
229
230 The Navier-Stokes system of equations 2.0.6-2.0.9, is a coupled system of nonlinear partial differ-
231 ential equations (PDE), and hence is very difficult to solve analytically. In fact, to the date there
10
232 is no general closed-form solution to this system of equations; hence we look for an approximate
233 solution of this system of equation in a given domain D with prescribed boundary conditions
234 ∂D and given initial conditions Dq̊.
235
236 If in eq. 2.0.6 we set the viscous fluxes ev = 0, fv = 0 and gv = 0, we get the Euler system of
237 equations, which governs inviscid fluid flow. The Euler system of equations is a set of hyperbolic
238 equations while the Navier-Stokes system of equations is a mixed set of hyperbolic (in the inviscid
239 region) and parabolic (in the viscous region) equations. Therefore, time marching algorithms
240 are used to advance the solution in time using discrete time steps.
∇ · (u) = 0,
∂u −∇p (2.1.1)
+ ∇ · (uu) = + ν∇2 u,
∂t ρ
250 where ν is the kinematic viscosity and is equal ν = µ/ρ. The previous set of equations in
251 expanded three-dimensional Cartesian coordinates is written as follows
∂u ∂v ∂w
+ + = 0,
∂x ∂y ∂z
2
2
∂ u ∂2u ∂2u
∂u ∂u ∂uv ∂uw 1 ∂p
+ + + =− +ν + + ,
∂t ∂x ∂y ∂z ρ ∂x ∂x2 ∂y 2 ∂z 2
2
2
∂2v ∂2v
∂v ∂uv ∂v ∂vw 1 ∂p ∂ v (2.1.2)
+ + + =− +ν + + ,
∂t ∂x ∂y ∂z ρ ∂x ∂x2 ∂y 2 ∂z 2
∂w ∂uw ∂vw ∂w2
2
∂ w ∂2w ∂2w
1 ∂p
+ + + =− +ν + + .
∂t ∂x ∂y ∂z ρ ∂x ∂x2 ∂y 2 ∂z 2
252 Equation 2.1.2 governs the unsteady three-dimensional motion of a viscous, incompressible and
253 isothermal flow. This simplification is generally not of a great value, as the equations are
254 hardly any simpler to solve. However, the computing effort may be much smaller than for the
255 full equations (due to the reduction of the unknowns and the fact that the energy equation is
256 decoupled from the system of equation), which is a justification for such a simplification. The
257 set of equations 2.1.1 can be rewritten in vector form as follow
11
0
u
q=
v ,
(2.1.4)
w
259 and ei , fi and gi are the vectors containing the inviscid fluxes (or convective fluxes) in the x, y
260 and z directions and are given by
u v w
u2 + p vu wu
ei = uv ,
fi =
v 2 + p ,
gi =
wv .
(2.1.5)
uw vw w2 + p
261 The viscous fluxes (or diffusive fluxes) in the x, y and z directions, ev , fv and gv respectively,
262 are defined as follows
0 0 0
τxx τyx τzx
ev = τxy ,
τyy ,
fv = gv = τzy .
(2.1.6)
τxz τyz τzz
263 Since we made the assumptions of an incompressible flow, appropriate expressions for shear
264 stresses must be used, these expressions are given as follows
∂u
τxx = 2µ ,
∂x
∂v
τyy = 2µ ,
∂y
∂w
τzz = 2µ ,
∂z
∂u ∂v
(2.1.7)
τxy = τyx = µ + ,
∂y ∂x
∂w ∂u
τxz = τzx = µ + ,
∂x ∂z
∂w ∂v
τyz = τzy = µ + ,
∂y ∂z
265 where we used Stokes hypothesis [5, 1, 6, 7] in order to derive the viscous stresses in eq. 2.1.7.
266
Equation 2.1.7 can be written in compact vector form as τ = 2µD, where D = 12 ∇u + ∇uT
267
268 is the symmetric tensor of the velocity gradient tensor ∇u = [D + S], and where D represents
269 the strain-rate tensor and S represents the spin tensor (vorticity). The skew or anti-symmetric
270 part of the velocity gradient tensor is given by S = 12 ∇u − ∇uT .
271
272 Equations 2.1.3-2.1.6, are the governing equations of an incompressible, isothermal, viscous flow
273 written in conservation form. Hence, we look for an approximate solution of this set of equations
274 in a given domain D with prescribed boundary conditions ∂D and given initial conditions Dq̊.
12
275 Chapter 3
277 All flows encountered in engineering applications, from simple ones to complex three-dimensional
278 ones, become unstable above a certain Reynolds number (Re = U L/ν where U and L are char-
279 acteristic velocity and length scales of the mean flow and ν is the kinematic viscosity). At low
280 Reynolds numbers flows are laminar, but as we increase the Reynolds number, flows are observed
281 to become turbulent. Turbulent flows are characterize by a chaotic and random state of motion
282 in which the velocity and pressure change continuously on a broad range of time and length
283 scales (from the smallest turbulent eddies characterized by Kolmogorov micro-scales, to the flow
284 features comparable with the size of the geometry).
285
286 There are several possible approaches for the numerical simulation of turbulent flows. The first
287 and most intuitive one, is by directly numerically solving the governing equations over the whole
288 range of turbulent scales (temporal and spatial). This deterministic approach is referred as Di-
289 rect Numerical Simulation (DNS) [9, 10, 11, 12, 13, 14]. In DNS, a fine enough mesh and small
290 enough time-step size must be used so that all of the turbulent scales are resolved. Although
291 some simple problems have been solved using DNS, it is not possible to tackle industrial prob-
292 lems due to the prohibitive computer cost imposed by the mesh and time-step requirements.
293 Hence, this approach is mainly used for benchmarking, research and academic applications.
294
295 Another approach used to model turbulent flows is Large Eddy Simulation (LES) [15, 16, 9, 13,
296 14]. Here, large scale turbulent structures are directly simulated whereas the small turbulent
297 scales are filtered out and modeled by turbulence models called subgrid scale models. According
298 to turbulence theory, small scale eddies are more uniform and have more or less common char-
299 acteristics; therefore, modeling small scale turbulence appears more appropriate, rather than
300 resolving it. The computational cost of LES is less than that of DNS, since the small scale
301 turbulence is now modeled, hence the grid spacing is much larger than the Kolmogorov length
302 scale. In LES, as the mesh gets finer, the number of scales that require modeling becomes
303 smaller, thus approaching DNS. Thanks to the advances in computing hardware and parallel
304 algorithms, the use of LES for industrial problems is becoming practical.
305
306 Today’s workhorse for industrial and research turbulence modeling applications is the Reynolds
307 Averaged Navier-Stokes (RANS) approach [17, 18, 13, 12, 19, 14]. In this approach, the RANS
308 equations are derived by decomposing the flow variables of the governing equations into time-
309 mean (obtained over an appropriate time interval) and fluctuating part, and then time averaging
310 the entire equations. Time averaging the governing equations gives rise to new terms, these new
311 quantities must be related to the mean flow variables through turbulence models. This pro-
312 cess introduces further assumptions and approximations. The turbulence models are primarily
313 developed based on experimental data obtained from relatively simple flows under controlled
314 conditions. This in turn limits the range of applicability of the turbulence models. That is, no
13
315 single RANS turbulence model is capable of providing accurate solutions over a wide range of
316 flow conditions and geometries.
317
318 Two types of averaging are presently used, the classical Reynolds averaging which gives rise
319 to the RANS equations and the mass-weighted averaging or Favre averaging which is used to
320 derive the Favre-Averaged Navier-Stokes equations (FANS) for compressible flows applications.
321 In both statistical approaches, all the turbulent scales are modeled, hence mesh and time-step
322 requirements are not as restrictive as in LES or DNS. Hereafter, we limit our discussion to
323 Reynolds averaging.
324
Figure 3.1: Time averaging for a statistically steady turbulent flow (left) and time averaging for an
unsteady turbulent flow (right).
331 Hereafter, x is the vector containing the Cartesian coordinates x, y, and z in N = 3 (where
332 N is equal to the number of spatial dimensions). A key observation in eq. 3.1.1 is that ϕ̄ is
333 independent of time, implying that any equation deriving for computing this quantity must be
334 steady state.
335
336 In eq. 3.1.1, the mean value ϕ̄ is obtained by an averaging procedure. There are three different
337 forms of the Reynolds averaging:
338 1. Time averaging: appropriate for stationary turbulence, i.e., statically steady turbulence
339 or a turbulent flow that, on average, does not vary with time.
Z t+T
1
ϕ̄(x) = lim ϕ(x, t) dt, (3.1.2)
T →+∞ T t
14
340 here t is the time and T is the averaging interval. This interval must be large compared
341 to the typical time scales of the fluctuations; thus, we are interested in the limit T → ∞.
342 As a consequence, ϕ̄ does not vary in time, but only in space.
344 with CV being a control volume. In this case, ϕ̄ is uniform in space, but it is allowed to
345 vary in time.
N
1 X
ϕ̄(x, t) = lim ϕ̄(x, t), (3.1.4)
N →∞ N
i=1
347 where N , is the number of experiments of the ensemble and must be large enough to
348 eliminate the effects of fluctuations. This type of averaging can be applied to any flow
349 (steady or unsteady). Here, the mean value ϕ̄ is a function of both time and space (as
350 illustrated in figure 3.1).
351 We use the term Reynolds averaging to refer to any of these averaging processes, applying any of
352 them to the governing equations yields to the Reynolds-Averaged Navier-Stokes (RANS) equa-
353 tions. In cases where the turbulent flow is both stationary and homogeneous, all three averaging
354 are equivalent. This is called the ergodic hypothesis.
355
356 If the mean flow ϕ̄ varies slowly in time, we should use an unsteady approach (URANS); then,
357 equations eq. 3.1.1 and eq. 3.1.2 can be modified as
367 Before deriving the RANS equations, we recall the following averaging rules,
15
ϕ̄′ = 0,
ϕ̄¯ = ϕ̄,
ϕ̄ = ϕ̄ + ϕ′ = ϕ̄,
ϕ + φ = ϕ̄ + φ̄ ,
ϕ̄φ = ϕ̄φ̄ = ϕ̄φ̄,
ϕ̄φ′ = ϕ̄φ̄′ = 0,
ϕφ = (ϕ̄ + ϕ′ )(φ̄ + φ′ )
= ϕ̄φ̄ + ϕ̄φ′ + φ̄ϕ′ + ϕ′ φ′ (3.1.7)
= ϕ̄φ̄ + ϕ̄φ′ + φ̄ϕ′ + ϕ′ φ′
= ϕ̄φ̄ + ϕ′ φ′ ,
ϕ′2 ̸= 0,
ϕ′ φ′ ̸= 0,
∂ϕ ∂ ϕ̄
= ,
∂x ∂x
Z Z
ϕds = ϕ̄ds
371 we now substitute eq. 3.2.1 into the incompressible Navier-Stokes equations eq. 2.1.1 and we
372 obtain for the continuity equation
∇ · (u) = ∇ · ū + u′ = ∇ · (ū) + ∇ · u′ = 0.
(3.2.2)
373 Then, time averaging this equation results in
∇ · (ū) + ∇ · ū′ = 0, (3.2.3)
374 and using the averaging rules stated in eq. 3.1.7, it follows that
∇ · (ū) = 0. (3.2.4)
375 We next consider the momentum equation of the incompressible Navier-Stokes equations eq.
376 2.1.1. We begin by substituting eq. 3.2.1 into eq. 2.1.1 in order to obtain,
∂ (ū + u′ ) −∇ (p̄ + p′ )
ū + u′ ū + u′ + ν∇2 ū + u′ ,
+∇· = (3.2.5)
∂t ρ
377 by time averaging eq. 3.2.5, expanding and applying the rules set in eq. 3.1.7, we obtain
16
∂ ū −∇p̄
+ ∇ · ūū + u′ u′ = + ν∇2 ū. (3.2.6)
∂t ρ
378 or after rearranging,
∂ ū −∇p̄
+ ν∇2 ū − ∇ · u′ u′
+ ∇ · (ūū) = (3.2.7)
∂t ρ
By setting τ R = −ρ u′ u′ in equation 3.2.7, and grouping with equation 3.2.4, we obtain the
379
∇ · (ū) = 0,
∂ ū −∇p̄ 1 (3.2.8)
+ ∇ · (ūū) = + ν∇2 ū + ∇ · τ R .
∂t ρ ρ
381 The set of equations eq. 3.2.8 are the incompressible Reynolds-Averaged Navier-Stokes (RANS)
382 equations. Notice that in eq. 3.2.8 we have retained the term ∂ ū/∂t, despite the fact that
383 ū is independent of time for statistically steady turbulence, hence this expression is equal to
384 zero when time average. In practice, in all modern formulations of the RANS equations the
385 time derivative term is included. In references [17, 13, 3, 10, 20], a few arguments justifying
386 the retention of this term are discussed. For not statistically stationary turbulence or unsteady
387 turbulence, a time-dependent RANS or unsteady RANS (URANS) approach is required, an
388 URANS computation simply requires retaining the time derivative term ∂ ū/∂t in the computa-
389 tion. For unsteady turbulence, ensemble average is recommended and often necessary.
390
391 The incompressible Reynolds-Averaged Navier-Stokes (RANS) equations eq. 3.2.8 are identical
392 to the incompressible Navier-Stokes equations eq. 2.1.1 with the exception of the additional term
R
τ = −ρ u u , where τ R is the so-called Reynolds-stress tensor. Notice that by doing a check
393
′ ′
394 of dimensions, it will show that τ R it is not actually a stress; it must be multiplied by the density
395 ρ, as it is done consistently in this manuscript, in order to have dimensions corresponding to the
396 stresses. On the other hand, since we are assuming that the flow is incompressible, that is, ρ is
397 constant, we might set the density equal to unity, thus obtaining implicit dimensional correctness.
398 Moreover, because we typically use kinematic viscosity ν, there is an implied division by ρ in
399 any case). The Reynolds-stress tensor represents the transfer of momentum due to turbulent
400 fluctuations. In 3D, the Reynolds-stress tensor τ R consists of nine components
′ ′
ρu u ρu′ v ′ ρu′ w′
τ R = −ρ u′ u′ = − ρv ′ u′ ρv ′ v ′ ρv ′ w′ .
(3.2.9)
′ ′ ′
ρw u ρw v ρw w′ ′ ′
401 However, since u, v and w can be interchanged, the Reynolds-stress tensor forms a symmetrical
402 second order tensor containing only six independent components. By inspecting the set of
403 equations eq. 3.2.8 we can count ten unknowns, namely; three components of the velocity (u, v,
404 w), the pressure (p), and six components of the Reynolds stress τ R = −ρ u′ u′ , in terms of
405 four equations, hence the system is not closed. The fundamental problem of turbulence modeling
406 based on the Reynolds-averaged Navier-Stokes equations is to find six additional relations in
407 order to close the system of equations eq. 3.2.8.
17
411 equations, but it is much simpler to model this term). A common approach uses the Boussinesq
412 hypothesis to relate the Reynolds stresses τ R to the mean velocity gradients such that
R 2 h i 2
τ R = −ρ u′ u′ = 2µT D̄ − ρkI = µT ∇u + (∇u)T − ρkI,
(3.3.1)
3 3
R
413 where D̄ denotes the Reynolds-averaged strain-rate tensor ( 12 (∇u + ∇uT )), I is the identity
414 matrix, µT is called the turbulent eddy viscosity, and
1
k = u′ · u′ , (3.3.2)
2
415 is the turbulent kinetic energy. Basically, we assume that this fluctuating stress is proportional
416 to the gradient of the average quantities (similarly to Newtonian flows). The second term in
417 eq. 3.3.1 ( 23 ρkI), is added in order for the Boussinesq approximation to be valid when traced,
418 that is, the trace of the right hand side in eq. 3.3.1 must be equal to that of the left hand side
419 (−ρ(u′ u′ )tr = −2ρk), hence it is consistent with the definition of turbulent kinetic energy (eq.
420 3.3.2). In order to evaluate k, usually a governing equation for k is derived and solved, typically
421 two-equations models include such an option.
422
423 The turbulent eddy viscosity µT (in contrast to the molecular viscosity µ), is a property of the
424 flow field and not a physical property of the fluid. The eddy viscosity concept was developed
425 assuming that a relationship or analogy exists between molecular and turbulent viscosities. In
426 spite of the theoretical weakness of the turbulent eddy viscosity concept, it does produce rea-
427 sonable results for a large number of flows.
428
429 The Boussinesq approximation reduces the turbulence modeling process from finding the six
430 turbulent stress components τ R to determining an appropriate value for the turbulent eddy
431 viscosity µT .
432
433 One final word of caution, the Boussinesq approximation discussed here, should not be associ-
434 ated with the completely different concept of natural convection.
435
ρk
µT = (3.4.1)
ω
449 Turbulent Kinetic Energy
450
∂k
ρ + ρ∇ · (ūk) = τ R :∇ū − β ∗ ρkω + ∇ · [(µ + σ ∗ µT ) ∇k] (3.4.2)
∂t
18
451 Specific Dissipation Rate
452
∂ω ω
ρ + ρ∇ · (ūω) = α τ R :∇ū − βρω 2 + ∇ · [(µ + σµT ) ∇ω] (3.4.3)
∂t k
453 Closure Coefficients
454
5 3 9 1 1
α= , β= , β∗ = , σ= , σ∗ = (3.4.4)
9 40 100 2 2
455 Auxiliary Relations
456
1
∗ k2
ϵ = β ωk and l= (3.4.5)
ω
457 Equations eq. 3.2.8 and eq. 3.4.1-3.4.5, are the governing equations of an incompressible,
458 isothermal, turbulent flow written in conservation form. Hence, we look for an approximate
459 solution of this set of equations in a given domain D, with prescribed boundary conditions ∂D,
460 and given initial conditions Dq̊.
19
461 Chapter 4
463 The purpose of any discretization practice is to transform a set of partial differential equations
464 (PDEs) into a corresponding system of discrete algebraic equations (DAEs). The solution of
465 this system produces a set of values which correspond to the solution of the original equations at
466 some predetermined locations in space and time, provided certain conditions are satisfied. The
467 discretization process can be divided into two steps, namely; the discretization of the solution
468 domain and the discretization of the governing equation.
469
470 The discretization of the solution domain produces a numerical description of the computational
471 domain (also known as mesh generation). The space is divided into a finite number of discrete
472 regions, called control volumes (CVs) or cells. For transient simulations, the time interval is also
473 split into a finite number of time steps. The governing equations discretization step altogether
474 with the domain discretization, produces an appropriate transformation of the terms of the gov-
475 erning equations into a system of discrete algebraic equations that can be solve using any direct
476 or iterative method.
477
478 In this section, we briefly presents the finite volume method (FVM) discretization, with the
479 following considerations in mind:
480 The method is based on discretizing the integral form of the governing equations over each
481 control volume of the discrete domain. The basic quantities, such as mass and momentum,
482 will therefore be conserved at the discrete levels.
484 The method is applicable to any number of spatial dimensions (1D, 2D or 3D).
485 The control volumes can be of any shape. All dependent variables share the same control
486 volume and are computed at the control volume centroid, which is usually called the
487 collocated or non-staggered variable arrangement.
488 Systems of partial differential equations are treated in a segregated way, meaning that
489 they are are solved one at a time in a sequential manner.
490 The specific details of the solution domain discretization, system of equations discretization
491 practices and implementation of the FVM are far beyond the scope of the present discussion.
492 Hereafter, we give a brief description of the FVM method. For a detailed discussion, the inter-
493 ested reader should refer to references [22, 3, 12, 23, 19, 24, 25].
494
20
495 4.1 Discretization of the Solution Domain
496 Discretization of the solution domain produces a computational mesh on which the governing
497 equations are solved (mesh generation stage). It also determines the positions of points in space
498 and time where the solution will be computed. The procedure can be split into two parts: tem-
499 poral discretization and spatial discretization.
500
501 The temporal solution is simple obtained by marching in time from the prescribed initial condi-
502 tions. For the discretization of time, it is therefore necessary to prescribe the size of the time-step
503 that will be used during the calculation.
504
505 The spatial discretization of the solution domain of the FVM method presented in this manuscript,
506 requires a subdivision of the continuous domain into a finite number of discrete arbitrary con-
507 trol volumes (CVs). In our discussion, the control volumes do not overlap, have a positive finite
508 volume and completely fill the computational domain. Finally, all variables are computed at the
509 centroid of the control volumes (collocated arrangement).
510
Figure 4.1: Arbitrary polyhedral control volume VP . The control volume has a volume V and is con-
structed around a point P (control volume centroid), therefore the notation VP . The vector from the
centroid of the control volume VP (point P), to the centroid of the neighboring control volume VN (point
N), is defined as d. The face area vector Sf points outwards from the surface bounding VP and is normal
to the face. The control volume faces are labeled as f, which also denotes the face center.
511 A typical control volume is shown in figure 4.1. In this figure, the control volume VP is bounded
512 by a set of flat faces and each face is shared with only one neighboring control volume. The
513 shape of the control volume is not important for our discussion, for our purposes it is a general
514 polyhedron, as shown in figure 4.1. The control volume faces in the discrete domain can be
515 divided into two groups, namely; internal faces (between two control volumes) and boundary
516 faces, which coincide with the boundaries of the domain. The face area vector Sf is constructed
517 for each face in such a way that it points outwards from the control volume, is located at the
518 face centroid, is normal to the face and has a magnitude equal to the area of the face (e.g., the
519 shaded face in figure 4.1). Boundary face area vectors point outwards from the computational
520 domain. In figure 4.1, the point P represents the centroid of the control volume VP and the
521 point N represents the centroid of the neighbor control volume VN . The distance between the
21
522 point P and the point N is given by the vector d. For simplicity, all faces of the control volume
523 will be marked with f, which also denotes the face centroid (see figure 4.1).
524
525 A control volume VP , is constructed around a computational point P. The point P, by definition,
526 is located at the centroid of the control volume such that its centroid is given by
Z
(x − xP ) dV = 0. (4.1.1)
VP
527 In a similar way, the centroid of the faces of the control volume VP is defined as
Z
(x − xf ) dS = 0. (4.1.2)
Sf
528 Finally, let us introduce the mean value theorem for the transported quantity ϕ over the control
529 volume VP , such that
Z
1
ϕ= ϕ(x)dV. (4.1.3)
V P VP
530 In the FVM method discussed in this manuscript, the centroid value ϕP of the control volume
531 VP is represented by a piecewise constant profile. That is, we assume that the value of the
532 transported quantity ϕ is computed and stored in the centroid of the control volume VP and
533 that its value is equal to the mean value of ϕ inside the control volume,
Z
1
ϕP = ϕ = ϕ(x)dV. (4.1.4)
V P VP
534 This approximation is exact if ϕ is constant or vary linearly.
535
541 Here ϕ is the transported quantity, i.e., velocity, mass or turbulent energy and Γϕ is the diffusion
542 coefficient of the transported quantity. This is a second order equation since the diffusion
543 term includes a second order derivative of ϕ in space. To represent this term with acceptable
544 accuracy, the order of the discretization must be equal or higher than the order of the equation
545 to be discretized. In the same order of ideas, to conform to this level of accuracy, temporal
546 discretization must be of second order as well. As a consequence of these requirements, all
547 dependent variables are assumed to vary linearly around the point P in space and instant t in
548 time, such that
22
549 Equations 4.2.2 and 4.2.3 are obtained by using Taylor Series Expansion (TSE) around the nodal
550 point P and time t, and truncating the series in such a way to obtain second order accurate
551 approximations.
552
553 A key theorem in the FVM method is the Gauss theorem (also know as the divergence or Ostro-
554 gradsky’s theorem), which will be used throughout the discretization process in order to reduce
555 the volume integrals in eq. 4.2.1 to their surface equivalents.
556
557 The Gauss theorem states that the volume integral of the divergence of a vector field in a region
558 inside a volume, is equal to the surface integral of the outward flux normal to the closed surface
559 that bounds the volume. For a vector a, the Gauss theorem is given by,
Z I
∇ · adV = ndS · a,
V ∂V (4.2.4)
560 where ∂V is the surface bounding the volume V and dS is an infinitesimal surface element with
561 the normal n pointing outward of the surface ∂V . From now on, dS will be used as a shorthand
562 for ndS.
563
564 By using the Gauss theorem, we can write eq. 4.2.1 as follows
Z I I Z
∂
(ρϕ) dV + dS · (ρuϕ) − dS · (ρΓϕ ∇ϕ) = Sϕ (ϕ) dV. (4.2.5)
∂t VP ∂VP | {z } ∂VP | {z } VP
convective flux diffusive flux
565 Equation 4.2.5 is a statement of conservation. It states that the rate of change of the transported
566 quantity ϕ inside the control volume VP is equal to the rate of change of the convective and
567 diffusive fluxes across the surface bounding the control volume VP , plus the net rate of creation
568 of ϕ inside the control volume. Notice that so far we have not introduce any approximation,
569 equation 4.2.5 is exact.
570
571 In the next sections, each of the terms in eq. 4.2.1 will be treated separately, starting with the
572 spatial discretization and concluding with the temporal discretization. By proceeding in this
573 way we will be solving eq. 4.2.1 by using the Method of Lines (MOL). The main advantage of
574 the MOL, is that it allows us to select numerical approximations of different accuracy for the
575 spatial and temporal terms. Each term can be treated differently to yield to different accuracies.
576
582 To calculate the surface integrals in eq. 4.2.5 we need to know the value of the transported quan-
583 tity ϕ on the faces of the control volume. This information is not available, as the variables are
584 calculated on the control volume centroid, so an approximation must be introduced at this stage.
585
586 We now make a profile assumption about the transported quantity ϕ. We assume that ϕ varies
587 linearly over each face f of the control volume VP , so that ϕ may be represented by its mean
588 value at the face centroid f . We can now approximate the surface integral as a product of the
589 transported quantities at the face center f (which is itself an approximation to the mean value
23
590 over the surface) and the face area. This approximation to the surface integral is known as the
591 midpoint rule and is of second-order accuracy.
592
593 It is worth mentioning that a wide range of choices exists with respect to the way of approximat-
594 ing the surface integrals, e.g., midpoint rule, trapezoid rule, Simpson’s rule, Gauss quadrature.
595 Here, we have used the simplest method, namely, the midpoint rule.
596
597 For illustrating this approximation, let us consider the term under the divergence operator in
598 eq. 4.2.4 and recalling that all faces are flat (that is, all vertexes that made up the face are
599 contained in the same plane), eq. 4.2.4 can be converted into a discrete sum of integrals over all
600 faces of the control volume VP as follows,
Z I
∇ · adV = dS · a,
VP ∂VP
X Z
= dS · a ,
f f (4.2.6)
X X
≈ (Sf · af ) = (Sf · af ) .
f f
601 Using the same approximations and assumptions as in eq. 4.2.6, the surface integrals (or fluxes)
602 in eq. 4.2.5 can be approximate as follow
I XZ X X
dS · (ρuϕ) = dS · (ρuϕ)f ≈ Sf · ρuϕ f
= Sf · (ρuϕ)f . (4.2.7)
∂VP | {z }
f f f f
convective flux
I XZ X X
dS · (ρΓϕ ∇ϕ) = dS · (ρΓϕ ∇ϕ)f ≈ Sf · ρΓϕ ∇ϕ f
= Sf · (ρΓϕ ∇ϕ)f . (4.2.8)
∂VP | {z }
f f f f
diffusive flux
603 To approximate the volume integrals in eq. 4.2.5, we make similar assumptions as for the surface
604 integrals, that is, ϕ varies linearly over the control volume and ϕ = ϕP . Integrating eq. 4.2.2
605 over a control volume VP , it follows
Z Z
ϕ (x) dV = [ϕP + (x − xP ) · (∇ϕ)P ] dV,
VP VP
Z Z
(4.2.9)
= ϕP dV + (x − xP ) dV · (∇ϕ)P ,
VP VP
= ϕP V P .
606 The second integral in the RHS of eq. 4.2.9 is equal to zero because the point P is the centroid
607 of the control volume (recall eq. 4.1.1). This quantity is easily calculated since all variables at
608 the centroid of VP are known, no interpolation is needed. The above approximation becomes
609 exact if ϕ is either constant or varies linearly within the control volume; otherwise, it is a second
610 order approximation.
611
∂ X X
ρϕVP + Sf · (ρuϕ)f − Sf · (ρΓϕ ∇ϕ)f = Sϕ VP . (4.2.10)
∂t
f f
24
613 Let us recall that in our formulation of the FVM, all the variables are computed and stored at
614 the control volumes centroid. The face values appearing in eq. 4.2.10; namely, the convective
615 flux F C = S·(ρuϕ) through the faces, and the diffusive flux F D = S·(ρΓϕ ∇ϕ) through the faces,
616 have to be calculated by some form of interpolation from the centroid values of the neighboring
617 control volumes located at both sides of the faces, this issue is discussed in the following section.
618
Z X
∇ · (ρuϕ) dV = Sf · (ρuϕ)f ,
VP f
X
= Sf · (ρu)f ϕf , (4.2.11)
f
X
= F̊ ϕf ,
f
621 where F̊ in eq. 4.2.11 represents the mass flux through the face,
F̊ = Sf · (ρu)f . (4.2.12)
622 Obviously, the flux F̊ depends on the face value of ρ and u, which can be calculated in a similar
623 fashion to ϕf (as it will be described in the next section), with the caveat that the velocity field
624 from which the fluxes are derived must be such that the continuity equation is obeyed, i.e.,
Z I X Z X X
∇ · udV = dS · u = dS · u = Sf · (ρu)f = F̊ = 0. (4.2.13)
VP ∂VP f f f f
625 Before we continue with the formulation of the interpolation scheme or convection differencing
626 scheme used to compute the face value of the transported quantity ϕ; it is necessary to examine
627 the physical properties of the convection term. Irrespective of the distribution of the velocity in
628 the domain, the convection term does not violate the bounds of ϕ given by its initial condition.
629 If for example, ϕ initially varies between 0 and 1, the convection term will never produce values
630 of ϕ that are lower than zero or higher that one. Considering the importance of boundedness
631 in the transport of scalar properties, it is essential to preserve this property in the discretized
632 form of the term.
633
642 Central Differencing (CD) scheme. In this scheme (also known as linear interpo-
643 lation), linear variation of the dependent variables is assumed. The face centered value
25
644 is found from a simple weighted linear interpolation between the values of the control
645 volumes at points P and N (see figure 4.2), such that
ϕf = fx ϕP + (1 − fx ) ϕN . (4.2.14)
646 In eq. 4.2.14, the interpolation factor fx , is defined as the ratio of the distances f N and
647 P N (refer to figure 4.2), i.e.,
fN | xf − x N |
fx = = . (4.2.15)
PN |d|
648 A special case arises when the face is situated midway between the two neighboring control
649 volumes VP and VN (uniform mesh), then the approximation reduces to an arithmetic
650 average
(ϕP + ϕN )
ϕf = . (4.2.16)
2
651 This practice is second order accurate, which is consistent with the requirement of overall
652 second order accuracy of the method. It has been noted however, that CD causes non-
653 physical oscillations in the solution for convection dominated problems, thus violating the
654 boundedness of the solution ([22, 3, 12, 23, 24, 25, 26]).
655
656 Upwind Differencing (UD) scheme. An alternative discretization scheme that guar-
657 antees boundedness is the Upwind Differencing (UD). In this scheme, the face value is
658 determined according to the direction of the flow (refer to figure 4.3),
(
ϕf = ϕP for F̊ ≥ 0,
ϕf = (4.2.17)
ϕf = ϕN for F̊ < 0.
659 This scheme guarantees the boundedness of the solution ([22, 3, 12, 23, 24, 25, 26]). Unfor-
660 tunately, UD is at most first order accurate, hence it sacrifices the accuracy of the solution
661 by implicitly introducing numerical diffusion.
662
663 In order to circumvent the numerical diffusion inherent of UD and unboundedness of CD, linear
664 combinations of UD and CD, second order variations of UD and bounded CD schemes has been
665 developed in order to conform to the accuracy of the discretization and maintain the bounded-
666 ness and stability of the solution [22, 3, 12, 23, 24, 25, 26].
667
26
Figure 4.3: Face interpolation. Upwind Differencing (UD) scheme. A) F̊ ≥ 0. B) F̊ < 0.
Z X
∇ · (ρΓϕ ∇ϕ) dV = Sf · (ρΓϕ ∇ϕ)f ,
VP f
X (4.2.18)
= (ρΓϕ )f Sf · (∇ϕ)f ,
f
fN | x f − xN |
(Γϕ )f = fx (Γϕ )P + (1 − fx ) (Γϕ )N where fx = = . (4.2.19)
PN |d|
676 If the control volumes are uniform (the face f is midway between VP and VN ), then fx is equal
677 to 0.5, and (Γϕ )f is equal to the arithmetic mean.
678
27
679 However, the method above described suffers from the drawback that if (Γϕ )N is equal to zero,
680 it is expected that there would be no diffusive flux across face f . But in fact, eq. 4.2.19
681 approximates a value for (Γϕ )f , namely
687 A better model for the variation of Γϕ between control volumes is to use the harmonic mean,
688 which is expressed as follows,
689
(Γϕ )N (Γϕ )P fN | xf − xN |
(Γϕ )f = where fx = = . (4.2.21)
fx (Γϕ )P + (1 − fx )(Γϕ )N PN |d|
690 This formulation gives (Γϕ )f equal to zero if either (Γϕ )N or (Γϕ )P is zero. For (Γϕ )P >> (Γϕ )N
691 gives
(Γϕ )N
(Γϕ )f = , (4.2.22)
fx
692 as required.
693
Figure 4.5: A) Vector d and S on an orthogonal mesh. B) Vector d and S on a non-orthogonal mesh.
ϕN − ϕP
S · (∇ϕ)f = |S| . (4.2.23)
|d|
698 By using eq. 4.2.23, the face gradient of ϕ can be calculated from the values of the control vol-
699 umes straddling face f (VP and VN ), so basically we are computing the face gradient by using
700 a central difference approximation of the first order derivative in the direction of the vector d.
701 This method is second order accurate, but can only be used on orthogonal meshes.
702
28
703 An alternative to the previous method, would be to calculate the gradient of the control volumes
704 at both sides of face f by using Gauss theorem, as follows
1 X
(∇ϕ)P = (Sf ϕf ) .
VP (4.2.24)
f
705 After computing the gradient of the neighboring control volumes VP and VN , we can find the
706 face gradient by using weighted linear interpolation.
707
708 Although both of the previously described methods are second order accurate; eq. 4.2.24 uses a
709 larger computational stencil, which involves a larger truncation error and can lead to unbounded
710 solutions. On the other hand, spite of the higher accuracy of eq. 4.2.23, it can not be used on
711 non-orthogonal meshes.
712
713 Unfortunately, mesh orthogonality is more an exception than a rule. In order to make use of
714 the higher accuracy of eq. 4.2.23, the product S · (∇ϕ)f is split in two parts
715 The two vectors introduced in eq. 4.2.25, namely; ∆⊥ and k, need to satisfy the following
716 condition
S = ∆⊥ + k. (4.2.26)
717 If the vector ∆⊥ is chosen to be parallel with d, this allows us to use eq. 4.2.23 on the orthogonal
718 contribution in eq. 4.2.25, and the non-orthogonal contribution is computed by linearly interpo-
719 lating the face gradient from the centroid gradients of the control volumes at both sides of face
720 f , obtained by using eq. 4.2.24. The purpose of this decomposition is to limit the error intro-
721 duced by the non-orthogonal contribution, while keeping the second order accuracy of eq. 4.2.23.
722
723 To handle the mesh orthogonality decomposition within the constraints of eq. 4.2.26, let us
724 study the following approaches ([26, 27, 12]), with k calculated from eq. 4.2.26:
725 Minimum correction approach (figure 4.6). This approach attempts to minimize the non-
726 orthogonal contribution by making ∆⊥ and k orthogonal,
d·S
∆⊥ = d. (4.2.27)
d·d
727 In this approach, as the non-orthogonality increases, the contribution from ϕP and ϕN
728 decreases.
729
730 Orthogonal correction approach (figure 4.7). This approach attempts to maintain the
731 condition of orthogonality, irrespective of whether non-orthogonality exist,
d
∆⊥ = |S|. (4.2.28)
|d|
29
Figure 4.6: Non-orthogonality treatment in the minimum correction approach.
732 Over-relaxed approach (figure 4.8). In this approach, the contribution from ϕP and ϕN
733 increases with the increase in non-orthogonality, such as
d
∆⊥ = |S|2 . (4.2.29)
d·S
734 All of the approaches described above are valid, but the so-called over-relaxed approach seems
735 to be the most robust, stable and computationally efficient.
736
737 Non-orthogonality adds numerical diffusion to the solution and reduces the accuracy of the nu-
738 merical method. It also leads to unboundedness, which in turn can conduct to nonphysical
739 results and/or divergence of the solution.
740
741 The diffusion term, eq. 4.2.18, in its differential form exhibits a bounded behavior. Hence, its
742 discretized form will preserve only on orthogonal meshes. The non-orthogonal correction poten-
743 tially creates unboundedness, particularly if mesh non-orthogonality is high. If the preservation
744 of boundedness is more important than accuracy, the non-orthogonal correction has got to be
745 limited or completely discarded, thus violating the order of accuracy of the discretization. Hence
30
746 care must be taken to keep mesh orthogonality within reasonable bounds.
747
748 The final form of the discretized diffusion term is the same for all three approaches. Since eq.
749 4.2.23 is used to compute the orthogonal contribution, meaning that d and ∆⊥ are parallel, it
750 follows
ϕN − ϕP
∆⊥ · (∇ϕ)f = |∆⊥ | , (4.2.30)
|d|
751 then eq. 4.2.25 can be written as
ϕN − ϕP
S · (∇ϕ)f = |∆⊥ | + k · (∇ϕ)f . (4.2.31)
|d| | {z }
non-orthogonal contribution
| {z }
orthogonal contribution
752 In eq. 4.2.31, the face interpolated value of ∇ϕ of the non-orthogonal contribution is calculated
753 as follows
762 By means of the Gauss theorem, the gradient terms of the control volume VP arising from the
763 discretization process or needed to compute the face gradients are calculated as follows,
Z I
∇ϕdV = dSϕ,
VP ∂VP
X
(∇ϕ)P VP = (Sf ϕf ) ,
f (4.2.33)
1 X
(∇ϕ)P = (Sf ϕf ) ,
VP
f
764 where the value ϕf on face f can be evaluated using the convection central differencing scheme.
765
766 After computing the gradient of the control volumes at both sides of face f by using eq. 4.2.33,
767 we can find the face gradient by using weighted linear interpolation,
771 The Green-Gauss cell based gradient evaluation uses a computational stencil larger than the
772 one used by eq. 4.2.23; hence the truncation error is larger and it might lead to oscillatory
31
773 solutions (unboundedness), which in turns can lead to nonphysical values of ϕ and divergence,
774 The advantage of this method is that it can be used in orthogonal and non-orthogonal meshes;
775 whereas eq. 4.2.23, can be only used in orthogonal meshes.
776
777 Another alternative, is by evaluating the face gradient by using a Least-Square fit (LSF). This
778 method assumes a linear variation of ϕ (which is consistent with the second order accuracy
779 requirement), and evaluates the gradient error at each neighboring control volume N using the
780 following expression,
782 where the weighting function w is given by wN = 1/|d|. Then, the following expression is used
783 to evaluate the gradient at the centroid of the control volume VP ,
X
(∇ϕ)P = 2
wN G−1 · d (ϕN − ϕP ) .
N
X (4.2.37)
2
G= wN dd.
N
784 After evaluation the neighbor control volumes gradient, they can be interpolated to the face.
785 Note that G is a symmetric N × N matrix and can easily be inverted (where N is the number of
786 spatial dimensions). This formulation leads to a second order accurate gradient approximation
787 which is independent of the mesh topology.
788
Sϕ (ϕ) = Sc + Sp ϕ, (4.2.38)
797 where Sc is the constant part of the source term and Sp depends on ϕ. For instance, if the source
798 term is assume to be constant, eq. 4.2.38 reduces to Sϕ (ϕ) = Su .
799
800 Following eq. 4.2.9, the volume integral of the source terms is calculated as
Z
Sϕ (ϕ) dV = Sc VP + Sp VP ϕP . (4.2.39)
VP
32
801 4.2.6 Temporal Discretization
802 In the previous sections, the discretization of the spatial terms was presented. Let us now
803 consider the temporal derivative of the general transport eq. 4.2.1, integrating in time we get
Z t+∆t Z Z Z
∂
ρϕdV + ∇ · (ρuϕ) dV − ∇ · (ρΓϕ ∇ϕ) dV dt
t ∂t VP VP VP
Z t+∆t Z
= Sϕ (ϕ) dV dt. (4.2.40)
t VP
804 Using equations 4.2.7-4.2.9 and 4.2.39, eq. 4.2.40 can be written as,
Z t+∆t
∂ρϕ
X X
VP + Sf · (ρuϕ)f − Sf · (ρΓϕ ∇ϕ)f dt
t ∂t P
f f
Z t+∆t
= (Sc VP + Sp VP ϕP ) dt. (4.2.41)
t
805 The above expression is usually called the semi-discretized form of the transport equation. It
806 should be noted that the order of the temporal discretization of the transient term in eq. 4.2.41
807 does not need to be the same as the order of the discretization of the spatial terms (convection,
808 diffusion and source terms). Each term can be treated differently to yield different accuracies.
809 As long as the individual terms are second order accurate, the overall accuracy of the solution
810 will also be second order.
814 where ϕn = ϕ(t + ∆t) and ϕn−1 = ϕ(t) represent the value of the dependent variable at the new
815 and previous times respectively. Equation 4.2.42 provides the temporal derivative at a centered
816 time between times n − 1 and n. Combining equations 4.2.41 and 4.2.42 and assuming that the
817 density and diffusivity do not change in time, we get
ρP ϕnP − ρP ϕn−1 1X 1X
P
VP + F̊ ϕnf − (ρΓϕ )f S · (∇ϕ)nf
∆t 2 2
f f
1X 1X
+ F̊ ϕfn−1 − (ρΓϕ )f S · (∇ϕ)fn−1
2 2
f f
1 1
= Su VP + Sp VP ϕnP + Sp VP ϕPn−1 . (4.2.43)
2 2
818 This form of temporal discretization is called Crank-Nicolson (CN) method and is second order
819 accurate in time. It requires the face values of ϕ and ∇ϕ as well as the control volume values for
33
820 both old (n − 1) and new (n) time levels. The face values are calculated from the control volume
821 values on each side of the face, using the appropriate differencing scheme for the convection term
822 and eq. 4.2.31 for the diffusion term. The CN method is unconditionally stable, but does not
823 guarantee boundedness of the solution.
824
ϕn−2 = ϕt−∆t ,
ϕn−1 = ϕt , (4.2.44)
n t+∆t
ϕ =ϕ ,
832 to calculate the temporal derivative. Expressing time level n − 2 as a Taylor expansion around
833 n we get
n 2 n
n−2 n ∂ϕ ∂ ϕ
∆t2 + O ∆t3 ,
ϕ =ϕ −2 ∆t + 2 2
(4.2.45)
∂t ∂t
834 doing the same for time level n − 1 we obtain
n n
1 ∂2ϕ
n−1 n ∂ϕ
∆t2 + O ∆t3 .
ϕ =ϕ − ∆t + 2
(4.2.46)
∂t 2 ∂t
835 Combining this equation with eq. 4.2.45 produces a second order approximation of the temporal
836 derivative at the new time n as follows
n 3 n
− 2ϕn−1 + 12 ϕn−2
∂ϕ 2ϕ
= . (4.2.47)
∂t ∆t
837 By neglecting the temporal variation in the face fluxes and derivatives, eq. 4.2.47 produces a
838 fully implicit second order accurate discretization of the general transport equation,
3
2 ρP ϕ
n − 2ρP ϕn−1 + 12 ρP ϕn−2 X X
VP + F̊ ϕnf − (ρΓϕ )f S · (∇ϕ)nf
∆t
f f
= Su VP + Sp VP ϕnP . (4.2.48)
839 In the CN method, since the flux and non-orthogonal component of the diffusion term have to
840 be evaluated using values at the new time n, it means that it requires inner-iterations during
841 each time step. Coupled with the memory overhead due to the large number of stored variables,
842 this implies that the CN method is expensive compared to the BD described before. The BD
843 method, although cheaper and considerably easier to implement than the CN method, results in
844 a truncation error larger than the latter. This is due to the assumed lack of temporal variation
845 in face fluxes and derivatives. This error manifests itself as an added diffusion. However, if we
846 restrict the Courant number (CFL) to a value below 1, the time step will tend to be very small,
847 keeping temporal diffusion errors to a minimum.
848
34
849 4.2.7 System of Algebraic Equations
850 At this point, after spatial and temporal discretization and by using equations 4.2.43 or 4.2.48
851 in every control volume of the domain, a system of algebraic equations of the form
879 Mainly, there are three boundary conditions which are used to close the system of equations,
880 namely:
881 Zero-gradient boundary condition, defining the solution gradient to be zero. This condition
882 is known as a Neumann type boundary condition.
883 Fixed-value boundary condition, defining a specified value of the solution. This is a Dirich-
884 let type condition.
885 Symmetry boundary condition, treats the conservation variables as if the boundary was a
886 mirror plane. This condition defines that the component of the solution gradient normal
887 to this plane should be fixed to zero. The parallel components are extrapolated from the
888 interior cells,
889 For example, for an external aerodynamics simulation we might set the following boundary
890 conditions. At the inflow boundary the velocity is defined as fixed-value and the pressure as
891 zero-gradient. At the outflow boundary, the pressure is defined as a fixed-value and the velocity
892 as a zero-gradient. If symmetry is a concern, symmetrical boundary conditions are used at fixed
35
893 boundaries. On a fixed wall, we need to ensure a zero flux through the wall or non penetrating
894 condition. In the case of a no-slip wall, a fixed-value is specified for the velocity (u = 0) in
895 combination with a zero-gradient for the pressure. If the boundary of the wall moves, then the
896 proper boundary condition is a moving-wall velocity which introduces an extra velocity in order
897 to maintain the no-slip condition and ensures a zero flux through the moving boundary.
898
899 Together with suitable boundary conditions we need to impose initial conditions. The initial
900 conditions determine the initial state of the governing equations at the initial time for an un-
901 steady problem (usually at t = 0), or at the first iteration for an iterative scheme. The better
902 the initial conditions are (the closer to the real solution), the stable and robust the numerical
903 scheme will be and the faster a converged solution will be reached (locally or globally). A com-
904 mon practice in external aerodynamics consist in setting the freestream values of velocity and
905 pressure as initial conditions in the whole domain.
906
36
916 Let us first introduce Taylor Series Expansions (TSE), which we are going to use to determine the
917 order of the truncation error O of the various approximations presented in the previous sections.
918
919 Consider the equally spaced mesh shown in figure 4.9, where ∆WP = ∆PE = ∆x. According to
920 TSE, any continuous differentiable function can be expressed as an infinite sum of terms that
921 are calculated from the values of the function derivatives at a single point. For ϕ(x) the TSE at
922 ϕ(x + ∆x) is equal to
927 By using TSE, we can obtain approximate expressions for the first and higher derivatives at a
928 point located in the direction x in terms of the function values at neighboring points.
929
930 Let us consider the discrete points W , P and E shown in figure 4.9. The TSE of ϕE around
931 point P (for P located midway between points W and E such that ∆WP = ∆PE = ∆x and
932 ∆wP = ∆Pe = ∆PE /2 = ∆x/2), is given by
2 3
∂ϕ 1 2 ∂ ϕ 1 3 ∂ ϕ
ϕE = ϕP + ∆x + ∆x + ∆x + HOT . (4.3.5)
∂x P 2! ∂x2 P 3! ∂x3 P
933 Equation 4.3.5 may be rearranged to give
2 3
∂ϕ ϕE − ϕP 1 ∂ ϕ 1 2 ∂ ϕ
= − ∆x − ∆x + HOT . (4.3.6)
∂x P ∆x 2! ∂x2 P 3! ∂x3 P
934 By summing all terms which involve the multiplying factor ∆x and higher and representing
935 them as O(∆x), yields to
∂ϕ ϕE − ϕP
= + O(∆x), (4.3.7)
∂x P ∆x
936 which is an approximation for the first derivative of ϕ with respect to x at the discrete point
937 P . The term O(∆x)n represents the truncation error of the approximation and determines the
938 rate at which the error decreases as the spacing between the points is reduced. The smaller ∆x
939 is, the smaller the error.
940
941 Equation 4.3.7 is known as the forward difference approximation of the first derivative and is
942 first order accurate because the truncation error is of order one or O(∆x).
943
37
944 In our notation we used discrete values ϕP , ϕE and ϕW , by using subscript index notation i to
945 represent the discrete points (this notation might be more amenable to follow for some readers),
946 eq. 4.3.7 is written as
∂ϕ ϕi+1 − ϕi
= + O(∆x). (4.3.8)
∂x i ∆x
947 Let us consider the TSE of ϕW around the discrete point P which is given by
2 3
∂ϕ 1 2 ∂ ϕ 1 3 ∂ ϕ
ϕW = ϕP − ∆x + ∆x − ∆x + HOT . (4.3.9)
∂x P 2 ∂x2 P 3! ∂x3 P
948 Rearranging and grouping eq. 4.3.9 we obtain
∂ϕ ϕP − ϕW
= + O(∆x), (4.3.10)
∂x P ∆x
949 or
∂ϕ ϕi − ϕi−1
= + O(∆x). (4.3.11)
∂x i ∆x
950 Equation 4.3.10 (or eq. 4.3.11) is known as the backward difference approximation of the first
951 derivative and is first order accurate because the truncation error is of order one or O(∆x).
952
953 Now consider the TSE in eq. 4.3.5 and eq. 4.3.9, which are repeated here for convenience
2 3
∂ϕ 1 2 ∂ ϕ 1 3 ∂ ϕ
ϕE = ϕP + ∆x + ∆x + ∆x + HOT , (4.3.12)
∂x P 2! ∂x2 P 3! ∂x3 P
954 and
∂2ϕ ∂3ϕ
∂ϕ 1 1
ϕW = ϕP − ∆x + ∆x2 − ∆x3 + HOT . (4.3.13)
∂x P 2 ∂x2 P 3! ∂x3 P
955 Subtracting eq. 4.3.13 from eq. 4.3.12, we obtain
3
∂ϕ 1 3 ∂ ϕ
ϕE − ϕW = 2∆x + 2 ∆x + HOT . (4.3.14)
∂x P 3! ∂x3 P
956 Rearranging and grouping eq. 4.3.14, we obtain
∂ϕ ϕE − ϕW
= + O(∆x)2 , (4.3.15)
∂x P 2∆x
957 or
∂ϕ ϕi+1 − ϕi−1
= + O(∆x)2 . (4.3.16)
∂x i 2∆x
958 Equation 4.3.15 (or eq. 4.3.16) is known as the central difference approximation of the first
959 derivative and is second order accurate because the truncation error is of order two or O(∆x)2 .
960 Approximations for the derivatives in the other directions are obtained in exactly the same fash-
961 ion.
962
38
963 4.3.2 Accuracy of the Upwind Scheme and Central Differencing Scheme
964 Let us study the truncation error associated with the upwind and central differencing schemes
965 presented in section 4.2.2. Consider the equally spaced mesh shown in figure 4.9, such that
966 ∆WP = ∆PE = ∆x and ∆Pe = ∆eE = ∆PE /2 = ∆x/2. Using TSE about face e, we obtain
2 3
∂2ϕ ∂3ϕ
∆x ∂ϕ 1 ∆x 1 ∆x
ϕP = ϕe − + − + HOT , (4.3.17)
2 ∂x e 2! 2 ∂x2 e 3! 2 ∂x3 e
2 3
∂2ϕ ∂3ϕ
∆x ∂ϕ 1 ∆x 1 ∆x
ϕE = ϕe + + + + HOT . (4.3.18)
2 ∂x e 2! 2 ∂x2 e 3! 2 ∂x3 e
ϕP = ϕe + O(∆x), (4.3.19)
ϕE = ϕe + O(∆x), (4.3.20)
968 and recalling eq. 4.2.17, which we rewrite here for convenience
(
ϕe = ϕP for F̊ ≥ 0,
ϕe = (4.3.21)
ϕe = ϕN for F̊ < 0.
969 From equations 4.3.19-4.3.21 we see that the upwind differencing scheme is first order accurate
970 because the truncation error is of order one or O(∆x).
971
(∆x)2 ∂2ϕ
ϕP + ϕE
ϕe = − + HOT , (4.3.22)
2 8 ∂x2 e
973 which is a central differencing approximation of ϕ at face e. Truncating eq. 4.3.22 at the second
974 order derivative yields to
ϕP + ϕE
+ O(∆x)2 ,
ϕe = (4.3.23)
2
975 hence the central differencing scheme is second order accurate because the truncation error is of
976 order two or O(∆x)2 .
977
978 Equation 4.3.23 is second order accurate only on uniform meshes (when ∆WP = ∆PE = ∆x and
979 ∆Pe = ∆eE = ∆PE /2 = ∆x/2). On non uniform meshes we need to use equations 4.2.14-4.2.15.
980
981 Consider the mesh shown in figure 4.9 and let us say that ∆WP ̸= ∆PE and ∆Pe ̸= ∆eE
982 (non-uniform mesh). The interpolated face value e can be found by using a weighted linear
983 interpolation as follows
ϕe = ex ϕP + (1 − ex ) ϕE , (4.3.24)
984 where the interpolation factor ex , is defined as the ratio of the distances eE and P E, i.e.,
eE | xe − xE |
ex = = . (4.3.25)
PE | ∆PE |
39
985 Let us find the truncation error of eq. 4.3.24. The TSE of ϕP around the discrete point E is
986 given by
987 Solving for ∂ϕ/∂x in eq. 4.3.26 and truncating in the second order derivative, we obtain
∂ϕ ϕE − ϕP
= . (4.3.27)
∂x E (xE − xP )
988 The TSE of ϕe about the discrete point E is expressed as follows
(xE − xe )(xe − xP ) ∂ 2 ϕ
ϕe = (1 − ex ) ϕE + ex ϕP +
2! ∂x2 E
(xE − xe )3 (xe − xP ) ∂ 3 ϕ
− + HOT . (4.3.30)
3!(xE − xe ) ∂x3 E
992 where the interpolation factor ex is given by
xE − xe
ex = (4.3.31)
xE − xP
993 The truncation error in eq. 4.3.30 is proportional to the product of the mesh spacing, hence the
994 scheme is second order accurate on uniform and non uniform meshes. Notice that when the face
995 e is situated midway between the two neighboring control volumes (uniform mesh), ex is equal
996 to 0.5 and eq. 4.3.30 reduces to eq. 4.3.23.
997
(x − xP )2 ∂2ϕ (x − xP )3 ∂3ϕ
∂ϕ
ϕ(x) = ϕP + (x − xP ) + + + HOT . (4.3.32)
∂x P 2! ∂x2 P 3! ∂x3 P
1001 Integrating eq. 4.3.32 over the control volume VP , yields
(x − xP )2 ∂2ϕ
Z Z
∂ϕ
ϕ (x) dV = ϕP + (x − xP ) +
VP VP ∂x P 2! ∂x2
P 3
)3
(x − xP ∂ ϕ
+ + HOT . (4.3.33)
3! ∂x3 P
40
1002 Assuming that ϕ(x) varies linearly over the control volume, all derivatives of order higher than
1003 ∂ϕ/∂x in eq. 4.3.33 are zero. Also, the term containing the derivative ∂ϕ/∂x is equal to zero
1004 since the point P is the centroid of the control volume, which is given by
Z
(x − xP ) dV = 0. (4.3.34)
VP
1005 Hence eq. 4.3.33 becomes
Z
ϕ (x) dV = ϕP VP ,
VP (4.3.35)
1007 Thus, the centroid value ϕP represents the mean value ϕ. Equation 4.3.36 is easily calculated
1008 since all variables at the centroid of VP are known, no interpolation is needed. The above ap-
1009 proximation becomes exact if ϕ is either constant or varies linearly within the control volume;
1010 otherwise, it is a second order approximation. The above analysis can be applied to any variable
1011 being represented by its volume or face centroid value.
1012
2 3
∂2ϕ ∂3ϕ
∆x ∂ϕ 1 ∆x 1 ∆x
ϕE = ϕe + + + + HOT . (4.3.38)
2 ∂x e 2! 2 ∂x2 e 3! 2 ∂x3 e
2 3
∂2ϕ ∂3ϕ
∆x ∂ϕ 1 ∆x 1 ∆x
ϕP = ϕe − + − + HOT , (4.3.39)
2 ∂x e 2! 2 ∂x2 e 3! 2 ∂x3 e
1018 Subtracting eq. 4.3.39 from eq. 4.3.38 , rearranging and manipulating we obtain
∆x2 ∂ 3 ϕ
∂ϕ ϕE − ϕP
= − + HOT . (4.3.40)
∂x e ∆x 48 ∂x3 e
1019 Truncating eq. 4.3.40 at the third order derivative we get
∂ϕ ϕE − ϕP
= + O(∆x)2 . (4.3.41)
∂x e ∆x
1020 Therefore the assumption of linear variation in eq. 4.3.41 leads to a second order accurate ap-
1021 proximation of (∂ϕ/∂x)e because the truncation error is of order two or O(∆x)2 .
1022
41
1023 4.3.5 Spatial and Temporal Linear Variation
1024 Let us study the truncation error associated with the assumption of spatial and temporal linear
1025 variation of ϕ. Using TSE around the discrete point P (refer to figure 4.9) and time t yields to
(x − xP )2 ∂ 2 ϕ
∂ϕ
ϕ(x) = ϕP + (x − xP ) + +
∂x
P 2! ∂x2 P
(x − xP )3 ∂ 3 ϕ
+ HOT , (4.3.42)
3! ∂x3 P
t t t
∆t2 ∂ 2 ϕ ∆t3 ∂ 3 ϕ
t ∂ϕ
ϕ(t + ∆t) = ϕ + ∆t + + + HOT . (4.3.43)
∂t 2! ∂t2 3! ∂t3
∂ϕ
ϕ(x) = ϕP + (x − xP ) + O(∆x)2 , (4.3.44)
∂x P
t
t ∂ϕ
ϕ(t + ∆t) = ϕ + ∆t + O(∆t)2 . (4.3.45)
∂t
1027 From equations 4.3.44-4.3.45 we see that the assumption of spatial and temporal linear variation
1028 is second order accurate because the truncation error is of order two or O(∆x)2 in space, and
1029 O(∆t)2 in time.
1030
Figure 4.10: Orthogonal and non-skew mesh. Notice that the vectors d and S are parallel.
1037 For non-orthogonal meshes (figure 4.11), we computed the face gradient of the transported quan-
1038 tity ϕ using eq. 4.2.31. In this equation we introduced a correction to improve the accuracy of
1039 the face gradient in the case of non-orthogonality. The non-orthogonality affect the solution by
1040 adding numerical diffusion to the solution, hence reducing the accuracy. Non-orthogonality can
1041 also lead to oscillatory solutions (unboundedness), which in turn can lead to nonphysical values
1042 and divergence. The higher the non-orthogonal angle (the angle between the face area vector S
42
1043 and the vector d in figure 4.11), the higher the numerical diffusion, and this in fact reduces the
1044 accuracy of the numerical method.
1045
Figure 4.11: Non-orthogonal and non-skew mesh. Notice that the vectors d and S are not parallel. The
angle between the vector d and S is the non-orthogonal angle.
1046 Let us now study the influence of skewness on the solution accuracy. Skewness can be defined as
1047 the deviation of the face centroid f from the point where the vector d intercepts the face. This
1048 situation is shown in figure 4.12, where f is the face centroid, fi is the point where the vector
1049 d intersects the face f , and ∆i is the vector that represents the deviation of fi from f . Under
1050 these conditions, the face values linearly interpolated from the control volumes VP and VN , no
1051 longer accurately represent the value of the face center.
1052
Figure 4.12: Skewness error in neighboring control volumes; where fi represents the face interpolated
value, f the face centroid, and the vector ∆i is the deviation of fi from f .
1053 With reference to figure 4.12, the degree of skewness can be measured ass follows,
1054
| ∆i |
ψskew = . (4.3.46)
|d|
1055 Skewness adds numerical diffusion to the solution and reduces the accuracy of the numerical
1056 method. It also leads to unboundedness, which in turn can conduct to nonphysical results
1057 and/or divergence of the solution.
1058
1059 In some situations, it can happen that the point fi falls outside face f , which leads to even higher
1060 truncation errors and more severe unboundedness. This type of scenarios is usually found when
1061 dealing with sharp edges or the intersection of two or more surfaces. In general, it is highly
43
1062 advisable to keep the skewness to a minimum.
1063
1064 The error due to mesh skewness can be reduced by correcting the error introduced due to the
1065 deviation of the face interpolated value fi from the face centroid f , by using the following second
1066 order approximation,
ϕfi = fx ϕP + (1 − fx ) ϕN , (4.3.48)
fi N | x fi − x N |
fx = = . (4.3.50)
PN |d|
1072 Problems can be encountered in the evaluation of the gradients of ϕ in eq. 4.3.49, as the
1073 calculation of the gradient of the control volumes VP and VN requires the knowledge of the face
1074 centroid gradient at point fi or (∇ϕ)fi , by using the Gauss theorem (eq. 4.2.33) we obtain,
1 X 1 X h i
(∇ϕ)P = Sf ϕ f = Sf ϕfi + ∆i · (∇ϕ)fi . (4.3.51)
VP VP
f f
1075 One way to circumvent this problem, is by computing an initial approximation of (∇ϕ)fi by
1076 using centered differences as follows,
(ϕN − ϕP )
∇ϕfi = . (4.3.52)
|d|
1077 Then eq. 4.3.51 is used to compute (∇ϕ)P and (∇ϕ)N based on the initial approximation of
1078 (∇ϕ)fi . Once we obtain the new face gradient (∇ϕ)fi by using eq. 4.3.49, we can improve this
1079 initial approximation by iterating again using the newly computed value. At the end of the iter-
1080 ative process, the corrected value of ϕf is computed by using eq. 4.3.47 and the corrected value
1081 of ∇ϕf is approximated by linearly interpolating the gradient of the neighboring control volumes.
1082
1083 Alternatively, we can compute the gradient of the control volumes straddling face f by using
1084 Gauss theorem (eq. 4.2.33), which we repeat here for convenience
1 X
(∇ϕ)P = (Sf ϕf ) , (4.3.53)
VP
f
1085 where the value ϕf on face f can be evaluated by using linear interpolation (eq. 4.2.14). Once
1086 we have obtained the gradient of the neighboring control volumes VP and VN (by using eq.
1087 4.3.53), we can obtain an initial approximation to the face gradient by using arithmetic average
1088 as follows,
(∇ϕP + ∇ϕN )
∇ϕf = . (4.3.54)
2
44
Figure 4.13: Orthogonal and skew mesh; where ∆P f is the vector connecting the centroid of the control
volume VP with the face center f , and ∆N f is the vector connecting the centroid of the control volume
VN with the face center f .
1089 This initial approximation of the face interpolated values is then improved by doing a linear
1090 reconstruction from the control volumes centroid values to the face f (linear extrapolation). By
1091 looking at figure 4.13, this approximation is given by
1099 Skewness and non-orthogonality can be presented together, reducing significatively the accuracy
1100 of the numerical scheme (refer to figure 4.14). Whenever one of these mesh induced errors are
1101 presented (figures 4.11-4.14), corrections should be applied in order to avoid numerical diffusion,
1102 unboundedness, and to maintain second order accuracy. In spite of the fact that the methods
1103 previously presented to handle non-orthogonality and skewness are second order accurate, they
1104 use a large computational stencil, which implies larger truncation errors, and can also lead to
1105 potential unboundedness.
1106
1107 To approximate the convective fluxes with the highest accuracy by using the approximations
1108 presented in the previous sections (e.g., CD and midpoint rule), the vector d connecting the
1109 centroid of two neighboring control volumes should pass through the center of the common
1110 face f (non-skew mesh). Maximum accuracy for the diffusive flux is obtained when the vector
1111 d connecting the centroid of two neighboring control volumes is orthogonal to the face f and
1112 passes through the face center (orthogonal and non-skew mesh). Unfortunately, this type of
1113 meshes are more an exception than a rule. Hence, mesh generation requires careful user input
1114 and good meshing practices in order to avoid highly skewed and/or awful non-orthogonal meshes.
1115
1116 From our discussion, we have seen the importance of mesh quality in the solution accuracy.
1117 Highly skewed and/or awful non-orthogonal meshes, will substantially reduce the accuracy of
1118 the numerical method and will add numerical diffusion to the solution, which in turn will smear
1119 the gradients of the transported quantity ϕ. Bad quality meshes can also lead to oscillatory
45
Figure 4.14: Non-orthogonal and skew mesh; where fi represents the face interpolated value, f the face
centroid and the vector ∆i is the deviation of fi from f .
1120 solutions (unboundedness), which in turn can conduct to nonphysical values and therefore di-
1121 vergence. In practice, in order to avoid unboundedness when reconstructing the face gradients
1122 we use gradient limiters (also known as slope limiters), to bound the face gradients so as to
1123 avoid undershoots and overshoots on the solution. In this manuscript we will not discuss gra-
1124 dient limiters, but the interested reader should refer to references [3, 22, 27, 24, 12, 25, 26, ?, 28].
1125
1133 As we assumed that the values of the transported quantity ϕ are computed and stored in the
1134 centroid of the control volume VP , and at the centroid of the faces of the same control volume;
1135 the mean value approximation (eq. 4.3.36), is valid on both uniform and non-uniform meshes.
1136
1137 However, the value of the face gradient approximation, eq. 4.3.37, is only valid on uniform
1138 meshes (refer to section 4.3.4). For non-uniform meshes (see figure 4.16), some of the terms in
1139 the TSE do not cancel, leaving a formal truncation error of order one or O(∆x), this scenario
1140 will be studied hereafter.
1141
1142 Let us consider the unequally spaced mesh shown in figure 4.16, such that ∆WP < ∆PE ,
1143 ∆Ww < ∆wP , and ∆Pe < ∆eE . Using TSE about face e, we obtain
∂2ϕ ∂3ϕ
∂ϕ 1 1
ϕE = ϕe + ∆eE + ∆2eE + ∆3eE + HOT , (4.3.57)
∂x e 2! ∂x2 e 3! ∂x3 e
∂2ϕ ∂3ϕ
∂ϕ 1 1
ϕP = ϕe − ∆Pe + ∆2Pe − ∆3Pe + HOT . (4.3.58)
∂x e 2! ∂x2 e 3! ∂x3 e
46
Figure 4.15: Uniform mesh. Notice that ∆WP = ∆PE = ∆x, ∆wP = ∆Pe , and ∆Ww = ∆Pe = ∆eE =
∆PE /2 = ∆x/2.
Figure 4.16: Non-uniform mesh. Notice that ∆WP < ∆PE , ∆Ww < ∆wP , and ∆Pe < ∆eE .
47
∂2ϕ
∂ϕ 1 2 2
ϕE − ϕP = (∆eE + ∆Pe ) + ∆eE − ∆Pe +
∂x e 2 ∂x2 e
∂3ϕ
1 3 3
∆eE + ∆Pe + HOT . (4.3.59)
6 ∂x3 e
1 ∆2eE − ∆2Pe
∂2ϕ
∂ϕ ϕE − ϕP
= −
∂x e (∆eE + ∆Pe ) 2 (∆eE + ∆Pe ) ∂x2 e
1 ∆3eE + ∆3Pe
∂3ϕ
− + HOT . (4.3.60)
6 (∆eE + ∆Pe ) ∂x3 e
1147 By inspecting eq. 4.3.61, we notice that if ∆eE = ∆P e (uniform mesh), the leading term of ϵt
1148 is equal to zero and we obtain a second order accurate approximation to (∂ϕ/∂x)e . We can
1149 also infer that the larger the difference between ∆eE and ∆P e , the larger the error. Hence, it
1150 becomes clear that if we keep the difference between ∆eE and ∆P e small, the error of the leading
1151 term in eq. 4.3.61 will tend to zero.
1152
∆eE = Gf ∆P e , (4.3.62)
1154 Gf determines how fast or how slow the mesh expands or contracts between adjacent control
1155 volumes. Substituting eq. 4.3.62 into 4.3.61, yields to
G 2 ∆2 − ∆2 2
1 f Pe Pe ∂ ϕ
ϵt = − , (4.3.63)
2 (Gf ∆Pe + ∆Pe ) ∂x2 e
1156 where we only show the leading term of the truncation error ϵt . Manipulating eq. 4.3.63 yields
1157 to
∂2ϕ
(1 − Gf ) ∆Pe
ϵt = . (4.3.64)
2 ∂x2 e
1158 From eq. 4.3.64 we can see that the truncation error of the centered difference approximation is
1159 of order one and proportional to the mesh spacing ∆Pe . Similarly, the truncation error of the
1160 backward difference approximation (eq. 4.3.58) is of order one and proportional to the mesh
1161 spacing ∆Pe and is given by
∂2ϕ
∆Pe
ϵt = . (4.3.65)
2 ∂x2 e
48
1162 However, if we set the value of Gf close to one in eq. 4.3.64, the truncation error of the centered
1163 difference approximation is significatively smaller than the truncation error of the backward
1164 difference approximation (eq. 4.3.65). It is clear that in order to keep small as possible the error
1165 of the leading term in eq. 4.3.61, we should use a growth factor Gf close to unity.
1166
1167 From the previous discussion, it seems that uniform meshes are desirable. The use of uniform
1168 meshes to represent complex geometries is not an easy task and it is computational expensive,
1169 as it will use the same mesh resolution in areas of high gradients (where we concentrate more
1170 control volumes in order to better resolve steep gradients or local features), and areas where the
1171 solution change slowly. In practice, we refine the mesh (or concentrate more control volumes),
1172 close to walls where we expect boundary layers, in areas of strong gradients, and in zones where
1173 we want to better resolve some local features. Far from the walls and areas of steep gradients or
1174 zones interest, we use a coarse mesh. Non-uniform meshes are the rule rather than the exception
1175 when dealing with complex geometries.
1176
1177 The only thing that we should keep in mind when using non-uniform meshes is that the mesh
1178 should be smooth, i.e., there should be no large spacing differences or fast volume transitions
1179 between neighboring control volumes (otherwise the solution accuracy will be compromise), and
1180 this is achieved by using local refinement an a suitable value of growth factor Gf .
1181
49
1182 Chapter 5
∂ (ρu)
=0 (5.2.2)
∂x
1192 We consider the one-dimensional control volume shown in figure 5.1. Our attention is focused
1193 in a general node P, the neighboring nodes are identified by W and E and the control volume
1194 faces by w and e.
Figure 5.1: A general nodal point is identified by P and its neighbors in a one-dimensional geometry,
the nodes to the west and east, are identified by W and E respectively. The west side face of the control
volume is referred to by w and the east side control volume face by e. The distances between the nodes W
and P, and between nodes P and E, are identified by ∆xW P and ∆xP E respectively. Similarly distances
between face w and point P and between P and face e are denoted by ∆xwP and ∆xP e respectively. Figure
6 shows that the control volume width is ∆x = ∆xwe .
1195 Integration of eq. 5.2.1 over the control volume shown in figure 5.1 gives
50
∂ϕ ∂ϕ
(ρuSϕ)e − (ρuSϕ)w = ΓS − ΓS (5.2.3)
∂x e ∂x w
1196 and integration of eq. 5.2.2 yields to
F = ρu,
Γ (5.2.5)
D=
∆x
1200 The cell face values of the variables F and D can be written as
Fw = (ρu)w Fe = (ρu)e ,
Γ Γ (5.2.6)
Dw = De =
∆xW P ∆xP E
1201 By employing the central differencing approach to represent the contribution of the diffusion
1202 terms on the right hand side of eq. 5.2.3, we obtain
∂ϕ ϕE − ϕP
ΓS = Γe Se
∂x e ∆xP E
(5.2.7)
∂ϕ ϕP − ϕW
ΓS = Γw Sw
∂x w ∆xW P
Fe − Fw = 0 (5.2.9)
1207 In the previous we assumed that Sw = Se = S, so we can divide the left and right hand sides of
1208 eq. 5.2.3 by the area S.
1209
1210 The central differencing approximation has been used to represent the diffusion terms which
1211 appear on the right hand side of eq. 5.2.8, and it seems logical to try linear interpolation to
1212 compute the cell face values for the convective terms on the left hand side of this equation. For
1213 a uniform mesh we can write the cell face values of the quantity ϕ as
(ϕP + ϕE )
ϕe =
2 (5.2.10)
(ϕW + ϕP )
ϕw =
2
51
1214 Substitution of the above equations into the convection terms of eq. 5.2.8 yields to
Fe Fw
(ϕP + ϕE ) − (ϕW + ϕP ) = De (ϕE − ϕP ) − Dw (ϕP − ϕW ) (5.2.11)
2 2
1215 Rearranging and grouping eq. 5.2.11 yields to
aP ϕP = aW ϕW + aE ϕE (5.2.12)
1216 where
Fw
aW = Dw +
2
Fe (5.2.13)
aE = De −
2
aP = aW + aE + (Fe − Fw )
1231 Let us explain step by step the solution method by using the mesh illustrated in figure 5.3. The
1232 domain has been divided into five control volumes, so as ∆x = 0.2 m. Note that L = 1.0 m
1233 (length), ρ = 0.1 kg/m3 , Γ = 0.1 kg/m.s.
52
1234 The discretized eq. 5.2.12 and its coefficients eq. 5.2.13 apply to all internal control volumes
1235 (2, 3 and 4). Control volumes 1 and 5 need special treatment since they are boundary cells.
1236 Integrating the convection-diffusion equation eq. 5.2.1 and using central differences for both
1237 the convective and diffusive terms, and by applying the boundary and initial conditions we can
1238 obtain the solution to our model equation.
1239
1240 The value of ϕ is given at the west face of cell 1 (ϕw = ϕA = 1) so we do not need to make any
1241 approximation in the convective flux term at this boundary. This yields the following equation
1242 for node 1,
Fe
(ϕP + ϕE ) − FA ϕA = De (ϕE − ϕP ) − DA (ϕP − ϕA ) (5.3.2)
2
1243 For the control volume 5, the ϕ value at the east face is known (ϕe = ϕB = 0). As before, we
1244 obtain the following equation
Fw
FB ϕB − (ϕP + ϕW ) = DE (ϕB − ϕP ) − Dw (ϕP − ϕW ) (5.3.3)
2
1245 Rearranging and grouping equations 5.3.2 and 5.3.3, we get the discretized equations at bound-
1246 aries nodes,
aP ϕP = aW ϕW + aE ϕE + Su (5.3.4)
1247 where
aP = aW + aE + (Fe − Fw ) − SP (5.3.5)
1248 Note that DA = DB = 2Γ/∆x = 2D and FA = FB = F .
1249
1250 To introduce the boundary conditions we have suppressed the link to the boundary side and
1251 entered the boundary flux as source terms.
1252
Node aW aE SP Su
1 0 D − F/2 −(2D + F ) (2D + F )ϕA
2, 3, 4 D + F/2 D − F/2 0 0
5 D + F/2 0 −(2D − F ) (2D − F )ϕB
1253 For u = 0.1 m/s, F = ρu = 0.1, D = Γ/∆x = 0.5, the coefficient are summarized in table 2.
1254
Node aW aE SP Su aP = aW + aE − SP
1 0 0.45 -1.1 1.1ϕA 1.55
2 0.55 0.45 0 0 1.0
3 0.55 0.45 0 0 1.0
4 0.55 0.45 0 0 1.0
5 0.55 0 -0.9 0.9ϕB 1.45
53
1.55 −0.45 0.0 0.0 0.0 ϕ1 1.1
−0.55 1.0 −0.45 0.0 0.0 ϕ2 0.0
0.0
−0.55 1.0 −0.45 0.0
ϕ3 = 0.0
(5.3.6)
0.0 0.0 −0.55 1.0 −0.45 ϕ4 0.0
0.0 0.0 0.0 −0.55 1.45 ϕ5 0.0
1256 The solution of the previous system yields to
ϕ1 0.9421
ϕ2 0.8006
ϕ3 = 0.6276 (5.3.7)
ϕ4 0.4163
ϕ5 0.1579
1257 The numerical and analytical solutions are compared in table 5.3 and in figure 5.4. The analytical
1258 solution for this problem is,
2.7183 − ex
ϕ(x) = (5.3.8)
1.7183
1259 From the results, it can be seen that regardless the coarseness of the mesh, the central differ-
1260 encing (CD) scheme gives reasonable agreement with the analytical solution.
1261
Figure 5.4: Comparison of the numerical and analytical solutions for u = 0.1 m/s.
1262 The cell Peclet number (or cell Reynolds number), is defined as,
ρu∆x
P ecell = (5.3.9)
Γ
1263 gives a relation between convection and diffusion. If the local Peclet number is less than 2, it is
1264 sufficient for boundedness of the solution by using CD for computing the convective terms. But
54
1265 when the Peclet number is higher than 2, the solution obtained by using CD for the convective
1266 terms shows an oscillatory behavior (unboundedness).
1267
1268 As an exercise, try to compute the cell Peclet number for the previous example.
1269
1270 In the next case (u = 2.5 m/s), the cell Peclet number is higher than 2. Let us see the solution,
1271 this is let to you as an exercise. You just need to proceed in exactly the same way as we did before.
1272
55
1277 Chapter 6
56
1281 Bibliography
1282 [1] J. D. Anderson. Computational Fluid Dynamics: The Basics with Applications. McGraw-
1283 Hill, 1995.
1285 [3] D. Drikakis and W. Rider. High-Resolution Methods for Incompressible and Low-Speed
1286 Flows. Springer, 2005.
1287 [4] P. M. Gresho. Incompressible fluid dynamics: some fundamental formulation issues. Annual
1288 Review of Fluid Mechanics, 23:413–453, 1991.
1290 [6] P. Kundu, I. Cohen, D. Dowling, and G. Tryggvason. Fluid Mechanics. Academic Press,
1291 2015.
1292 [7] P. Tucker. Advanced Computational Fluid and Aerodynamics. Cambridge University Press,
1293 2016.
1294 [8] C. A. J. Fletcher. Computational Techniques for Fluid Dynamics: Volume 2: Specific
1295 Techniques for Different Flow Categories. Springer, 1996.
1296 [9] X. Jiang and C-H. Lai. Numerical Techniques for Direct and Large-Eddy Simulation. CRC
1297 Numerical Analysis and Scientific Computing Series, 2009.
1298 [10] P. A. Durbin and B. A. Pettersson-Reif. Statistical Theory and Modeling for Turbulent
1299 Flows. Wiley, 2010.
1301 [12] H. Versteeg and W. Malalasekera. An Introduction to Computational Fluid Dynamics: The
1302 Finite Volume Method. Pearson, 2007.
1304 [14] K. A. Hoffmann and S. T. Chiang. Computational Fluid Dynamics. Volume 3. EES, 2000.
1305 [15] P. Sagaut. Large Eddy Simulation for Incompressible Flows: An Introduction. Springer,
1306 2005.
1307 [16] L. C. Berselli, T. Iliescu, and W. J. Layton. Mathematics of Large Eddy Simulation of
1308 Turbulent Flows. Springer, 2010.
1309 [17] D. C. Wilcox. Turbulence Modeling for CFD. DCW Industries, 2006.
1310 [18] T. Cebeci. Turbulence Models and Their Application: Efficient Numerical Methods with
1311 Computer Programs. Springer, 2004.
57
1312 [19] R. H. Pletcher, J. C. Tannehill, and D. A. Anderson. Computational Fluid Mechanics and
1313 Heat Transfer. Taylor and Francis, 1997.
1314 [20] U. Frisch. Turbulence, the legacy of A. N. Kolmogorov. Cambridge University Press, 1995.
1315 [21] D. C. Wilcox. Re-assessment of the scale-determining equation for advanced turbulence
1316 model. AIAA Journal, 26(11):1299–1310, 1988.
1317 [22] J. H. Ferziger and M. Peric. Computational Methods for Fluid Dynamics. Springer, 2002.
1318 [23] S. Patankar. Numerical Heat Transfer and Fluid Flow. McGraw-Hill, 1980.
1319 [24] E. F. Toro. Riemann Solvers and Numerical Methods for Fluid Dynamics. Springer, 2009.
1320 [25] R. J. LeVeque. Finite Volume Methods for Hyperbolic Problems. Cambridge Texts in
1321 Applied Mathematics, 2002.
1322 [26] H. Jasak. Error analysis and estimation for the finite volume method with application for
1323 fluid flows. Technical report, Imperial College London, 1996.
1324 [27] J. Blazek. Computational Fluid Dynamics: Principles and Applications. Elsevier, 2003.
58