Download as pdf or txt
Download as pdf or txt
You are on page 1of 31

Introduction to Computational Fluid Dynamics:

Governing Equations, Turbulence Modeling Introduction and


Finite Volume Discretization Basics.
Joel Guerrero

July 1, 2012

1 Notation and Mathematical Preliminaries


When presenting the fluid flow equations, as well as throughout this manuscript, we make use
of the following vector/tensor notation and mathematical operators.

Vector and tensors are usually denoted by bold letters. Hereafter, the vector is almost always a
column vector and a row vector is expressed as a transpose of a column vector indicated by the
superscript T . Vectors a = a1 i + a2 j + a3 k and b = b1 i + b2 j + b3 k are expressed as follows
   
a1 b1
a = a2  , b =  b2  ,
a3 b3
the transpose of the column vectors a and b are represented as follows

aT = [a1 , a2 , a3 ] , bT = [b1 , b2 , b3 ] ,
1
The magnitude of a vector a is defined as |a| = (a · a) 2 .

A second rank tensor1 (which we are going to simply defined as a tensor), is represented as
follows
   
A11 A12 A13 A11 A21 A31
A = A21 A22 A23  , AT = A12 A22 A32  .
A31 A32 A33 A13 A23 A33

If A = AT , the tensor is said to be symmetric, that is, its components are symmetric about the
diagonal.

The dot product of two vectors a and b yields to a scalar quantity given by
 
  b1
aT · b = a · b = a1 , a2 , a3 b2  = a1 b1 + a2 b2 + a3 b3 .
b3

The vector or cross product a × b (it is read a cross b) is the vector normal to the plane of a
and b, and is defined by the determinant
1
A first rank tensor is often referred to as a vector and a zero rank tensor to as a scalar

1
 
i
j k
a2 b3 − a3 b2
a × b = a1 a2 a3 = a3 b1 − a1 b3  ,
b1 b2 b3 a1 b2 − a2 b1
a × b and b × a result in two different vectors, pointing in opposite directions with the same
magnitude.

The tensor product of two vectors a ⊗ b produces a second rank 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
notice that unlike the vector product a ⊗ b 6= b ⊗ a.

The double dot product (:) of two second-rank tensors A and B


   
A11 A12 A13 B11 B12 B13
A = A21 A22 A23  , B = B21 B22 B23  ,
A31 A32 A33 B31 B32 B33
produces a scalar φ = A:B, which can be evaluated as the sum of the 9 products of the tensor
components

φ = Aij Bij = A11 B11 + A12 B12 + A13 B13 +


A21 B21 + A22 B22 + A23 B23 +
A31 B31 + A32 B32 + A33 B33 .

The dot product of a tensor A and a vector a, produces a vector b = A · a, whose components
are
 
A11 a1 + A12 a2 + A13 a3
b = bi = Aij aj = A21 a1 + A22 a2 + A23 a3  .
A31 a1 + A32 a2 + A33 a3
The dot product of a tensor A and a vector a (b = A · a) is non-commutative (Aij aj 6= ai Aij ).

The dot product of two tensors A and B, produces another second rank tensor C = A · B,
whose components are evaluated as

C = Cij = Aik Bkj


The dot product of two tensors C = A · B is non-commutative.

Note that our definitions of the tensor-vector dot product and tensor-tensor dot-product are
consistent with the ordinary rules of matrix algebra.

The trace of a tensor A is a scalar, evaluated by summing its diagonal components

tr A = A11 + A22 + A33 .


The gradient operator ∇ (read as nabla) in Cartesian coordinates is defined by
 T
∂ ∂ ∂ ∂ ∂ ∂
∇= i+ j+ k= , , .
∂x ∂y ∂z ∂x ∂y ∂z

2
The gradient operator ∇ when applied to a scalar quantity φ(x, y, z) (where x,y, z are the spatial
coordinates), yields to a vector defined by
 T
∂φ ∂φ ∂φ
∇φ = , , .
∂x ∂y ∂z
The notation grad for ∇ may be also used as the gradient operator, so that, grad φ ≡ ∇φ. The
gradient of a vector a produces a second rank tensor
 
∂a1 ∂a1 ∂a1
 ∂x ∂y ∂z 
 ∂a ∂a2 ∂a2 
 2 
grad a = ∇a =  .
 ∂x ∂y ∂z 
 ∂a3 ∂a3 ∂a3 
∂x ∂y ∂z
The gradient can operate on any tensor field to produce a tensor field that is one rank higher.

The dot product of vector a and the operator ∇ is called the divergence (div) of the vector field;
the output of this operator is a scalar and is defined as

∂a1 ∂a2 ∂a3


div a = ∇ · a = + + .
∂x ∂y ∂z
The divergence of a tensor A, div A or ∇ · A, yields to a vector and is defined as
 
∂A11 ∂A12 ∂A13
+ +
 ∂x ∂y ∂z 
 ∂A ∂A22 ∂A23 
 21 
div A = ∇ · A =  + + .
 ∂x ∂y ∂z 
 ∂A31 ∂A32 ∂A33 
+ +
∂x ∂y ∂z
The divergence can operate on any tensor field of rank 1 and above to produce a tensor that is
one rank lower.

The curl operator of a vector a produces another vector. This operator is defined by

i j k 
T
∂ ∂ ∂ ∂a3 ∂a2 ∂a1 ∂a3 ∂a2 ∂a 1
curl a = ∇ × a = = − , − , − .
∂x ∂y ∂z ∂y ∂z ∂z ∂x ∂x ∂y

a1 a2 a3

The divergence of the gradient is called the Laplacian operator and is denoted by ∆. The
Laplacian of a scalar φ(x, y, z) yields to another scalar field and is defined as

∂2φ ∂2φ ∂2φ


div grad φ = ∇ · ∇φ = ∇2 φ = ∆φ = + 2 + 2.
∂x2 ∂y ∂z
The Laplacian of a vector field a is defined as the diverge of the gradient just like in the scalar
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 +  + .
 ∂x ∂y 2 ∂z 2 
 ∂ 2 a3 ∂ 2 a3 ∂ 2 a3 
+ +
∂x2 ∂y 2 ∂z 2

3
The Laplacian transforms a tensor field into another tensor field of the same rank.

As previously discussed, a tensor is said to be symmetric if its components are symmetric about
the diagonal, i.e. A = AT . A tensor is said to be skew or antisymmetric if A = −AT which
intuitively implies that A11 = A22 = A33 = 0. Every second order tensor can be decomposed
into symmetric and skew parts by
1  1 
A= A + AT + A − AT = symm A + skew A.
|2 {z } |2 {z }
symmetric skew

The jacobian matrix of a vector field a is given by


 
∂a1 ∂a1 ∂a1
 ∂x ∂y ∂z 
 ∂a ∂a ∂a 
 2 2 2
 .
 ∂x ∂y ∂z 
 ∂a3 ∂a3 ∂a3 
∂x ∂y ∂z
Hereafter we present some useful vector/tensor identities:

• ∇ · ∇ × a = 0.
• ∇ × ∇α = 0.
• ∇(αβ) = α∇β + β∇α.
• ∇(αa) = a ⊗ ∇α + α∇a.
a·a
• (∇a)a = ∇ − a × ∇ × a.
2
a·a
• a · (∇a)a = a · ∇ .
2
a·a
• (a ⊗ b) · ∇a = b · ∇ .
2
• ∇(a · b) = b · ∇a + a · ∇b + a × ∇ × b + b × ∇ × a.
• ∇ · (αa) = α∇ · a + a · ∇α.
• ∇ · ∇a = ∇(∇ · a) − ∇ × (∇ × a).
• ∇ · (a × b) = b · ∇ × a − a · ∇ × b.
• ∇ · (a ⊗ b) = b · ∇a + a∇ · b.
• a · ∇ · (b ⊗ c) = (a · b)∇ · c + (a ⊗ b) · ∇b.
• ∇ · (αA) = A∇α + α∇ · A.
• ∇ · (Ab) = (∇ · AT ) · b + AT · ∇b.
• ∇ × (αa) = α∇ × a + ∇α × a.
• ∇ × (a × b) = a∇ · b + b · ∇a − (∇ · a)b − a · ∇b.
• a · (Ab) = A · (a ⊗ b).
• a · (Ab) = (Aa) · b if A is symmetric.

where α and β are scalars; a, b and c are vectors; and A is a tensor.

4
2 Governing Equations of Fluid Dynamics
The starting point of any numerical simulation are the governing equations of the physics of the
problem to be solved. Hereafter, we present the governing equations of fluid dynamics and their
simplification for the case of an incompressible viscous flow.

The equations governing the motion of a fluid can be derived from the statements of the conser-
vation of mass, momentum, and energy [1, 2, 3]. In the most general form, the fluid motion is
governed by the time-dependent three-dimensional compressible Navier-Stokes system of equa-
tions. For a viscous Newtonian, isotropic fluid in the absence of external forces, mass diffusion,
finite-rate chemical reactions, and external heat addition; the conservation form2 of the Navier-
Stokes system of equations in compact differential form and in primitive variable formulation
(ρ, u, v, w, et ) can be written as

∂ρ
+ ∇ · (ρu) = 0,
∂t
∂ (ρu)
+ ∇ · (ρuu) = −∇p + ∇ · τ, (1)
∂t
∂ (ρet )
+ ∇ · (ρet u) = ∇ · q − p · ∇u + τ · ∇u.
∂t
This set of equations can be rewritten in vector form as follows

∂Q ∂Ei ∂Fi ∂Gi ∂Ev ∂Fv ∂Gv


+ + + = + + , (2)
∂t ∂x ∂y ∂z ∂x ∂y ∂z
where Q is the vector of the conserved flow variables given by
 
ρ
 ρu 
 
Q=
 ρv  ,
 (3)
ρw 
ρet
and Ei = Ei (Q), Fi = Fi (Q) and Gi = Gi (Q) are the vectors containing the inviscid fluxes in
the x, y and z directions and are given by
     
ρu ρv ρw
 ρu2 + p   ρvu   ρwu 
   2
  
Ei = 
 ρuv
,
 Fi = 
 ρv + p  ,
 Gi = 
 ρwv
,
 (4)
 ρuw   ρvw   ρw2 + p 
(ρet + p) u (ρet + p) v (ρet + p) w
where u is the velocity vector containing the u, v and w velocity components in the x, y and
z directions and p, ρ and et are the pressure, density and total energy per unit mass respectively.

2
In the conservation form (or divergence form) [4], the momentum equation can be written as (ρu)t +∇·(ρuu) =
−∇p + ∇ · τ , where the tensor product of the vectors uu is equal to
0 1 0 2 1
u ` u uv uw
2
´
uu = @ v A u v w = @ vu v vw A ,
w wu wv w2
and consequently ∇ · (uu) = u · ∇u + u(∇ · u). But from the divergence-free constraint (∇ · u = 0) it follows that
u(∇ · u) is zero, therefore ∇ · (uu) = u · ∇u. Henceforth, (ρu)t + ∇ · (ρuu) = −∇p + ∇ · τ (conservation form) is
equivalent to ρ ((u)t + u · ∇ (u)) = −∇p + ∇ · τ (non-conservation form or advective/convective form).

5
The vectors Ev = Ev (Q), Fv = Fv (Q) and Gv = Gv (Q) contain the viscous fluxes in the x, y
and z directions and are defined as follows

 
0

 τxx 

Ev = 
 τxy ,

 τxz 
uτxx + vτxy + wτxz − qx
 
0

 τyx 

Fv = 
 τyy ,
 (5)
 τyz 
uτyx + vτyy + wτyz − qy
 
0

 τzx 

Gv = 
 τ zy
,

 τzz 
uτzx + vτzy + wτzz − qz

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 , (6)
∂y
∂T
qz = −k ,
∂z
and the viscous stresses τxx , τyy , τzz , τxy , τyx , τxz , τzx , τyz and τzy , are given by the following
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
  (7)
∂u ∂v
τxy = τyx = µ + ,
∂y ∂x
 
∂u ∂w
τxz = τzx = µ + ,
∂z ∂x
 
∂v ∂w
τyz = τzy = µ + ,
∂z ∂y
In equations 5-7, T is the temperature, k is the thermal conductivity and µ is the laminar vis-
cosity. In order to derive the viscous stresses in eq. 7 the Stokes’s hypothesis was used [5].

Examining closely equations 2-5 and counting the number of equations and unknowns, we clearly
see that we have five equations in terms of seven unknown flow field variables u, v, w, ρ, p, T ,
and et . It is obvious that two additional equations are required to close the system. These

6
two additional equations can be obtained by determining relationships that exist between the
thermodynamic variables (p, ρ, T, ei ) through the assumption of thermodynamic equilibrium.
Relations of this type are known as equations of state, and they provide a mathematical rela-
tionship between two or more state functions (thermodynamic variables). Choosing the specific
internal energy ei and the density ρ as the two independent thermodynamic variables, then
equations of state of the form

p = p (ei , ρ) , T = T (ei , ρ) , (8)


are required. For most problems in aerodynamics and gasdynamics, it is generally reasonable
to assume that the gas behaves as a perfect gas (a perfect gas is defined as a gas whose inter-
molecular forces are negligible), i.e.,

p = ρRg T, (9)
m2
where Rg is the specific gas constant and is equal to 287 for air. Assuming also that the
s2 K
working gas behaves as a calorically perfect gas (a calorically perfect gas is defined as a perfect
gas with constant specific heats), then the following relations hold

cp Rg γRg
ei = cv T, h = cp T, γ= , cv = , cp = , (10)
cv γ−1 γ−1
where γ is the ratio of specific heats and is equal to 1.4 for air, cv the specific heat at constant
volume, cp the specific heat at constant pressure and h is the enthalpy. By using eq. 9 and eq.
10, we obtain the following relations for pressure p and temperature T in the form of eq. 8

p (γ − 1) ei
p = (γ − 1) ρei , T = = , (11)
ρRg Rg
where the specific internal energy per unit mass ei = p/(γ − 1)ρ is related to the total energy
per unit mass et by the following relationship,

1 2 
et = ei + u + v 2 + w2 . (12)
2
In our discussion, it is also necessary to relate the transport properties (µ, k) to the thermody-
namic variables. Then, the laminar viscosity µ is computed using Sutherland’s formula
3
C1 T 2
µ= , (13)
(T + C2 )
where for the case of the air, the constants are C1 = 1.458 × 10−6 mskg

K
and C2 = 110.4K.

The thermal conductivity, k, of the fluid is determined from the Prandtl number (P r = 0.72 for air)
which in general is assumed to be constant and is equal to
cp µ
k= , (14)
Pr
where cp and µ are given by equations eq. 10 and eq. 13 respectively.

The first row in eq. 2 corresponds to the continuity equation. Likewise, the second, third and
fourth rows are the momentum equations, while the fifth row is the energy equation in terms of
total energy per unit mass.

The Navier-Stokes system of equations 2-5, is a coupled system of nonlinear partial differential
equations (PDE), and hence is very difficult to solve analytically. In fact, to the date there is

7
no general closed-form solution to this system of equations; hence we look for an approximate
solution of this system of equation in a given domain D with prescribed boundary conditions
∂D and given initial conditions D Q̊.

If in eq. 2 we set the viscous fluxes Ev = 0, Fv = 0 and Gv = 0, we get the Euler system of
equations, which governs inviscid fluid flow. The Euler system of equations is a set of hyperbolic
equations while the Navier-Stokes system of equations is a mixed set of hyperbolic (in the inviscid
region) and parabolic (in the viscous region) equations. Therefore, time marching algorithms
are used to advance the solution in time using discrete time steps.

2.1 Simplification of the Navier-Stokes System of Equations: Incompressible


Viscous Flow Case
Equations 2-5, with an appropriate equation of state and boundary and initial conditions, gov-
erns the unsteady three-dimensional motion of a viscous Newtonian, compressible fluid. In many
applications the fluid density may be assumed to be constant. This is true not only for liquids,
whose compressibility may be neglected, but also for gases if the Mach number is below 0.3
[2, 6]; such flows are said to be incompressible. If the flow is also isothermal, the viscosity is
also constant. In this case, the governing equations written in compact conservation differential
form and in primitive variable formulation (u, v, w, p) reduce to the following set

∇ · (u) = 0,
∂u −∇p (15)
+ ∇ · (uu) = + ν∇2 u,
∂t ρ

where ν is the kinematic viscosity and is equal ν = µ/ρ. The previous set of equations in
expanded three-dimensional Cartesian coordinates is written as follows

∂u ∂v ∂w
+ + = 0,
∂x ∂y ∂z
2  2 
∂u ∂u ∂uv ∂uw 1 ∂p ∂ u ∂2u ∂2u
+ + + =− +ν + + ,
∂t ∂x ∂y ∂z ρ ∂x ∂x2 ∂y 2 ∂z 2
2  2 
∂v ∂uv ∂v ∂vw 1 ∂p ∂ v ∂2v ∂2v (16)
+ + + =− +ν + + ,
∂t ∂x ∂y ∂z ρ ∂x ∂x2 ∂y 2 ∂z 2
 2 
∂w ∂uw ∂vw ∂w2 1 ∂p ∂ w ∂2w ∂2w
+ + + =− +ν + + .
∂t ∂x ∂y ∂z ρ ∂x ∂x2 ∂y 2 ∂z 2

Equation 16 governs the unsteady three-dimensional motion of a viscous, incompressible and


isothermal flow. This simplification is generally not of a great value, as the equations are
hardly any simpler to solve. However, the computing effort may be much smaller than for the
full equations (due to the reduction of the unknowns and the fact that the energy equation is
decoupled from the system of equation), which is a justification for such a simplification. The
set of equations 16 can be rewritten in vector form as follow

∂Q ∂Ei ∂Fi ∂Gi ∂Ev ∂Fv ∂Gv


+ + + = + + , (17)
∂t ∂x ∂y ∂z ∂x ∂y ∂z
where Q is the vector containing the primitive variables and is given by

8
 
0
u
Q=
v  ,
 (18)
w
and Ei , Fi and Gi are the vectors containing the inviscid fluxes in the x, y and z directions and
are given by
     
u v w
u2 + p  vu   wu 
Ei = 
 uv  ,
 Fi = 
v 2 + p ,
 Gi = 
 wv  .
 (19)
uw vw w2 + p
The viscous fluxes in the x, y and z directions, Ev , Fv and Gv respectively, are defined as follows
     
0 0 0
τxx  τyx  τzx 
Ev = 
τxy  ,
 Fv = 
τyy  ,
 Gv = 
τzy  .
 (20)
τxz τyz τzz
Since we made the assumptions of an incompressible flow, appropriate expressions for shear
stresses must be used, these expressions are given as follows

∂u
τxx = 2µ ,
∂x
∂v
τyy = 2µ ,
∂y
∂w
τzz = 2µ ,
∂z  
∂u ∂v (21)
τxy = τyx = µ + ,
∂y ∂x
 
∂w ∂u
τxz = τzx = µ + ,
∂x ∂z
 
∂w ∂v
τyz = τzy = µ + ,
∂y ∂z

where we used Stokes’s hypothesis [5] in order to derive the viscous stresses in eq. 21.

Equations 17-20, are the governing equations of an incompressible, isothermal, viscous flow
written in conservation form. Hence, we look for an approximate solution of this set of equations
in a given domain D with prescribed boundary conditions ∂D and given initial conditions D Q̊.

3 Turbulence Modeling
All flows encountered in engineering applications, from simple ones to complex three-dimensional
ones, become unstable above a certain Reynolds number (Re = U L/ν where U and L are char-
acteristic velocity and length scales of the mean flow and ν is the kinematic viscosity). At low
Reynolds numbers flows are laminar, but as we increase the Reynolds number, flows are observed
to become turbulent. Turbulent flows are characterize by a chaotic and random state of motion
in which the velocity and pressure change continuously on a broad range of time and length
scales (from the smallest turbulent eddies characterised by Kolmogorov microscales, to the flow

9
features comparable with the size of the geometry).

There are several possible approaches to the simulation of turbulent flows. The first and most
intuitive one, is by directly numerically solving the set governing equations 1 over the whole
range of turbulent scales (temporal and spatial). This deterministic approach is referred as Di-
rect Numerical Simulation (DNS) [17, 18, 19, 10, 24, 25]. In DNS, a fine enough mesh and small
enough time-step size must be used so that all of the turbulent scales are resolved. Although
some simple problems have been solved using DNS, it is not possible to tackle industrial prob-
lems due to the prohibitive computer cost imposed by the mesh and time-step requirements.
Hence, this approach is mainly used for research and academic applications.

Another approach used to model turbulent flows is Large Eddy Simulation (LES) [20, 21, 17,
24, 25]. Here, large scale turbulent structures are directly simulated whereas the small turbu-
lent scales are filtered out and modeled by turbulence models called subgrid scale models. In
turbulence, small scale eddies are more uniform and have more or less common characteristics;
therefore, modeling small scale turbulence appears more appropriate, rather than resolving it.
The computational cost of LES is less than that of DNS, since the small scale turbulence is now
modeled, hence the grid spacing is much larger than the Kolmogorov lenght scale. In LES, as the
mesh gets finer, the number of scales that require modeling becomes smaller, thus approaching
DNS. Thanks to the advances in computing hardware and parallel algorithms, the use of LES
for industrial problems is becoming practical.

Today’s workhorse for industrial and research turbulence modeling applications is the Reynolds
Averaged Navier-Stokes (RANS) equations approach [22, 23, 24, 10, 12, 25]. In this approach,
the RANS equations are derived by decomposing the flow variables of the governing equations
eq. 1 into time-mean (obtained over an appropriate time interval) and fluctuating part, and then
time averaging the entire equations. Time averaging the governing equations gives rise to new
terms, these new quantities must be related to the mean flow variables through turbulence mod-
els. This process introduces further assumptions and approximations. The turbulence models
are primarily developed based on experimental data obtained from relatively simple flows under
controlled conditions. This in turn limits the range of applicability of the turbulence models.
That is, no single RANS turbulence model is capable of providing accurate solutions over a wide
range of flow conditions and geometries.

Two types of averaging are presently used, the classical Reynolds averaging which gives rise
to the RANS equations and the mass-weighted averaging or Favre averaging which is used to
derive the Favre-Averaged Navier-Stokes equations (FANS) for compressible flows applications.
In both statistical approaches, all the turbulent scales are modeled, hence the mesh requirements
are not as restrictive as in LES or DNS. Hereafter, we limit our discussion to Reynolds averaging.

3.1 Reynolds Averaging


The starting point for deriving the RANS equations is the Reynolds decomposition [22, 3, 24,
10, 12, 25] of the flow variables of the governing equations. This decomposition is accomplished
by representing the instantaneous flow quantity φ by the sum of a mean value part (denoted by
a bar over the variable, as in φ̄) and a time-dependent fluctuating part (denoted by a prime, as
in φ′ ). This concept is illustrated in figure 1 and is mathematically expressed as follows,

φ(x, t) = φ̄(x, t) + φ′ (x, t) . (22)


| {z } | {z }
mean value f luctuating part

10
Figure 1: Time averaging for a statiscally steady turbulent flow (left) and time averaging for an unsteady
turbulent flow (right).

Hereafter, x is the vector containing the Cartesian coordinates x, y, and z in N = 3 (where N is


equal to the number of spatial dimensions). A key observation in eq. 22 is that φ̄ is independent
of time, implying that any equation deriving for computing this quantity must be steady state.

In eq. 22, the mean value φ̄ is obtained by an averaging procedure. There are three different
forms of the Reynolds averaging:

1. Time averaging: appropriate for stationary turbulence, i.e., statically steady turbulence
or a turbulent flow that, on average, does not vary with time.
Z t+T
1
φ̄(x) = lim φ(x, t) dt, (23)
T →+∞ T t

here t is the time and T is the averaging interval. This interval must be large compared
to the typical time scales of the fluctuations; thus, we are interested in the limit T → ∞.
As a consequence, φ̄ does not vary in time, but only in space.

2. Spatial averaging: appropriate for homogeneous turbulence.


Z
1
φ̄(t) = lim φ(x, t) dCV, (24)
CV→∞ CV CV

with CV being a control volume. In this case, φ̄ is uniform in space, but it is allowed to
vary in time.

3. Ensemble averaging: appropriate for unsteady turbulence.

N
1 X
φ̄(x, t) = lim φ̄(x, t), (25)
N →∞ N
i=1

where N , is the number of experiments of the ensemble and must be large enough to
eliminate the effects of fluctuations. This type of averaging can be applied to any flow.
Here, the mean value φ̄ is a function of both time and space (as illustrated in figure 1).

We use the term Reynolds averaging to refer to any of these averaging processes, applying any of
them to the governing equations yields to the Reynolds-Averaged Navier-Stokes (RANS) equa-
tions. In cases where the turbulent flow is both stationary and homogeneous, all three averaging

11
are equivalent. This is called the ergodic hypothesis.

If the mean flow φ̄ varies slowly in time, we should use an unsteady approach (URANS); then,
equations 22 and 23 can be modified as

φ(x, t) = φ̄(x, t) + φ′ (x, t). (26)


and
Z t+T
1
φ̄(x, t) = φ(x, t)dt, T1 << T << T2 (27)
T t
where T1 and T2 are the characteristics time scales of the fluctuations and the slow variations
in the flow, respectively (as illustrated in figure 1). In eq. 27 the time scales should differ
by several order of magnitude, but in engineering applications very few unsteady flows satisfy
this condition. In general, the mean and fluctuating components are correlated, i.e., the time
average of their product is non-vanishing. For such problems, ensemble averaging is necessary.
An alternative approach to URANS is LES, which is out of the scope of this discussion but the
interested reader should refer to [20, 21, 17, 24, 25].

Before deriving the RANS equations, we recall the following averaging rules,

φ̄′ = 0,
φ = φ̄,
φ̄ = φ̄ + φ′ = φ̄,
∂φ ∂ φ̄
= ,
∂x ∂x
φ + ϕ = φ̄ + ϕ̄ ,
φ̄ϕ = φ̄ϕ̄ = φ̄ϕ̄,
φ̄ϕ̄ = φ̄ϕ̄, (28)
φ̄ϕ′ = φ̄ϕ̄′ = 0,
φϕ = (φ̄ + φ′ )(ϕ̄ + ϕ′ )
= φ̄ϕ̄ + φ̄ϕ′ + ϕ̄φ′ + φ′ ϕ′
= φ̄ϕ̄ + φ̄ϕ′ + ϕ̄φ′ + φ′ ϕ′
= φ̄ϕ̄ + φ′ ϕ′ ,
φ′2 6= 0,
φ′ ϕ′ 6= 0.

3.2 Incompressible Reynolds Averaged Navier-Stokes Equations


Let us recall the Reynolds decomposition for the flow variables of the incompressible Navier-
Stokes equations eq. 15,

u(x, t) = ū(x) + u′ (x, t),


(29)
p(x, t) = p̄(x) + p′ (x, t),

we now substitute eq. 29 into the incompressible Navier-Stokes equations eq. 15 and we obtain
for the continuity equation

12
 
∇ · (u) = ∇ · ū + u′ = ∇ · (ū) + ∇ · u′ = 0. (30)
Then, time averaging this equation results in

∇ · (ū) + ∇ · ū′ = 0, (31)
and using eq. 28 it follows that

∇ · (ū) = 0. (32)
We next consider the momentum equation of the incompressible Navier-Stokes equations eq. 15.
We begin by substituting eq. 29 into eq. 15 in order to obtain,

∂ (ū + u′ )   −∇ (p̄ + p′ ) 
+∇· ū + u′ ū + u′ = + ν∇2 ū + u′ , (33)
∂t ρ

by time averaging eq. 33, expanding and applying the rules set in eq. 28, we obtain

∂ ū  −∇p̄
+ ∇ · ūū + u′ u′ = + ν∇2 ū. (34)
∂t ρ

Grouping equations 32 and 34, we obtain the following set of equations,

∇ · (ū) = 0,
∂ ū −∇p̄ 1 (35)
+ ∇ · (ūū) = + ν∇2 ū − ∇ · τ R .
∂t ρ ρ

The set of equations eq. 35 are the incompressible Reynolds-Averaged Navier-Stokes (RANS)
equations. Notice that in eq. 35 we have retained the term ∂ ū/∂t, despite the fact that ū is
independent of time for statistically steady turbulence, hence this expression is equal to zero
when time average. In practice, in all modern formulations of the RANS equations the time
derivative term is included. In references [22, 24, 3, 18, 30], a few arguments justifying the
retention of this term are discussed. For not statistically stationary turbulence or unsteady
turbulence, a time-dependent RANS or unsteady RANS (URANS) computation is required, an
URANS computation simply requires reatining the time derivative term ∂ ū/∂t in the computa-
tion. For unsteady turbulence, ensemble average is recommended and often necessary.

The incompressible Reynolds-Averaged Navier-Stokes (RANS) equations eq. 35 are identical to


the incompressible
 Navier-Stokes equations eq. 15 with the exception of the additional term
τ = −ρ u u , where τ R is the so-called Reynolds-stress tensor (notice that by doing a check
R ′ ′

of dimensions, it will show that τ R it is not actually a stress; it must be multiplied by the density
ρ, as it is done consistently in this manuscript, in order to have dimensions corresponding to
the stresses. On the other hand, since we are assuming that the flow is incompressible, that
is, ρ is constant, we might set the density equal to unity, thus obtaining implicit dimensional
correctness. Moreover, because we typically emply kinematic viscosity ν, there is an implied
division by ρ in any case). The Reynolds-stress tensor represents the transfer of momentum due
to turbulent 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′  . (36)
ρw′ u′ ρw′ v ′ ρw′ w′

13
However, since u, v and w can be interchanged, the Reynolds-stress tensor forms a symmetrical
second order tensor containing only six independent components. By inspecting the set of
equations eq. 35 we can count ten unknowns, namely; three components of thevelocity (u, v, w),
the pressure (p), and six components of the Reynolds stress τ R = −ρ u′ u′ , in terms of four
equations, hence the system is not closed. The fundamental problem of turbulence modelling
based on the Reynolds-averaged Navier-Stokes equations is to find six additional relations in
order to close the system of equations eq. 35.

3.3 Boussinesq Approximation


The Reynolds averaged approach to turbulence modeling requires that the Reynolds stresses
in eq. 35 to be appropriately modeled (however, it is possible to derive its own governing
equations, but it is much simpler to model this term). A common approach uses the Boussinesq
approximation or hypothesis to relate the Reynolds stresses τ R to the mean velocity gradients
such that
 2 h i 2
τ R = −ρ u′ u′ = 2µT S̄ R − ρκI = µT ∇u + (∇u)T − ρκI, (37)
3 3
where S̄ R denotes the Reynolds-averaged strain-rate tensor ( 21 (∇u + ∇uT )), I is the identity
matrix, T is the transpose, µT is called the turbulent eddy viscosity, and

1
κ = u′ · u′ , (38)
2
is the turbulent kinetic energy. Basically, we assume that this fluctuating stress is proportional
to the gradient of the average quantities (similarly to Newtonian flows). The second term in
eq. 35 ( 23 ρκI), is added in order for the Boussinesq approximation to be valid when traced,
that is, the trace of the right hand side in eq. 35 must be equal to that of the left hand side
(−ρ(u′ u′ )tr = −2ρκ), hence it is consistent with the definition of turbulent kinetic energy (eq.
36). In order to evaluate κ, usually a governing equation for κ is derived and solved, typically
two-equations models include such an option.

The turbulent eddy viscosity µT (in contrast to the molecular viscosity µ), is a property of the
flow field and not a physical property of the fluid. The eddy viscosity concept was developed
assuming that a relationship or analogy exists between molecular and turbulent viscosities. In
spite of the theoretical weakness of the turbulent eddy viscosity concept, it does produce rea-
sonable results for a large number of flows.

The Boussinesq approximation reduces the turbulence modeling process from finding the six
turbulent stress components τ R to determining an appropiate value for the turbulent eddy vis-
cosity µT .

One final word of caution, the Boussinesq aproximation discussed here, should not be associated
with the completely different concept of natural convection.

3.4 Two-Equations Models. The κ − ω Model


In this section we present the widely used κ − ω model. As might be inferred from the termi-
nology (and the tittle of this section), it is a two-equation model. In its basic form it consist
of a governing equation for the turbulent kinetic energy κ, and a governing equation for the
turbulent specific dissipation rate ω. Together, these two quantities provide velocity and length
scales needed to directly find the value of the turbulent eddy viscosity µT at each point in a

14
computational domain. The κ − ω model has been modified over the years, new terms (such
as production and dissipation terms) have been added to both the κ and ω equations, which
have improved the accuracy of the model. Because it has been tested more extensively than any
other κ − ω model, we present the Wilcox model [27].

Eddy Viscosity

ρκ
µT = (39)
ω
Turbulent Kinetic Energy

∂κ
ρ + ρ∇ · (ūκ) = τ R ∇ū − β ∗ ρκω + ∇ · [(µ + σ ∗ µT ) ∇κ] (40)
∂t
Specific Dissipation Rate

∂ω ω
ρ + ρ∇ · (ūω) = α τ R ∇ū − βρω 2 + ∇ · [(µ + σµT ) ∇ω] (41)
∂t κ
Closure Coefficients
5 3 9 1 1
α= , β= , β∗ = , σ= , σ∗ = (42)
9 40 100 2 2
Auxiliary Relations
1
∗ κ2
ǫ = β ωκ and l= (43)
ω
Equations eq. 35 and eq. 39-43, are the governing equations of an incompressible, isothermal,
turbulent flow written in conservation form. Hence, we look for an approximate solution of this
set of equations in a given domain D, with prescribed boundary conditions ∂D, and given initial
conditions D Q̊.

4 Finite Volume Method Discretization


The purpose of any discretization practice is to transform one or more partial differential equa-
tions (PDEs) into a corresponding system of algebraic equations. The solution of this system
produce a set of values which correspond to the solution of the original equations at some
predetermined locations in space and time, provided certain conditions are satisfied. The dis-
cretization process can be divided into two steps, namely; the discretization of the solution
domain and equation discretization.

The discretization of the solution domain produces a numerical description of the computational
domain. The space is divided into a finite number of discrete regions, called control volumes
(CVs) or cells. For transient simulations, the time interval is also split into a finite number of
time steps. The equation discretization step altogether with the domain discretization, produces
an appropriate transformation of the terms of the governing equations into a system of discrete
algebraic equations that can be solve using any direct or iterative method.

In this section, we briefly presents the finite volume method (FVM) discretization, with the
following considerations in mind:

• The method is based on discretizing the integral form of the governing equations over each
control volume of the discrete domain. The basic quantities, such as mass and momentum,
will therefore be conserved at the discrete levels.

15
• The method is applicable to both steady-state and transient calculations.

• The method is applicable to any number of spatial dimensions (1D, 2D or 3D).

• The control volumes can be of any shape. All dependent variables share the same control
volume, which is usually called the collocated or non-staggered variable arrangement.

• Systems of partial differential equations are treated in a segregated way, meaning that
they are are solved one at a time in a sequential manner.

The specific details of the discretization practice and implementation of the FVM (including im-
plementation of the boundary conditions and source terms) are beyond the scope of the present
discussion. The interested reader should refer to references [7, 3, 10, 11, 12, 9, 13] for a detailed
discussion.

4.1 Discretization of the Solution Domain


Discretization of the solution domain produces a computational mesh on which the governing
equations are solved. It also determines the positions of points in space and time where the
solution is sought. The procedure can be split into two parts: discretization of time and dis-
cretization of space.

The solution in time is simple obtained by marching in time from the prescribed initial condi-
tions. For the discretization of time, it is therefore sufficient to prescribe the size of the time-step
that will be used during the calculation.

The dicretization of space for the FVM used in this study requires a subdivision of the domain
into discrete arbitrary control volumes (CVs). In our discussion, the control volumes do not
overlap and completely fill the computational domain. In the present study all variables share
the same CV.

A typical control volume is shown in figure 2. The computational point P is located at the
centroid of the control volume, such that
Z
(x − xP ) dV = 0. (44)
VP

The control volume CV P is bounded by a set of flat faces and each face is shared with only one
neighboring CV. The topology of the control volume is not important for our discussion, for
our purposes it is a general polyhedron, as shown in figure 2. The cell faces in the mesh can
be divided into two groups, namely; internal faces (between two control volumes) and boundary
faces, which coincide with the boundaries of the domain. The face area vector Sf is constructed
for each face in such a way that it points outwards from the CV, is normal to the face and has
the magnitude equal to the area of the face. Boundary face area vectors point outwards from the
computational domain. For the shaded face in figure 2, the point P represents the CV centroid
(owner ) and the point N represents the neighbor CV centroid (neighbor ). The distance between
the point P and the point N is d. The face area vector Sf points outwards from CV P . For
simplicity, all faces of the control volume will be marked with f, which also represents the point
in the middle of the face (figure 2).

16
Figure 2: Arbitrary polyhedral control volume CV P . The CV is constructed around a point P (CV
centroid) and hence the notation CV P and has volume VP . The vector from the cell center point P to the
neighboring cell center point N is d. The faces area vector Sf points outwards from CV P . The CV faces
are labeled as fc , which also denotes the face center.

4.2 Discretisation of the Transport Equation

The general transport equation is used throughout this study to present the FVM discretization
practices. All the equations described in section 1 and 2 can be written in the form of the general
transport equation over a given control volume enclosing a point P (as the control volume CV P
shown in figure 2), as follows

Z Z Z Z
∂ρφ
dV + ∇ · (ρuφ) dV − ∇ · (ρΓφ ∇φ) dV = Sφ (φ) dV . (45)
VP | ∂t{z } VP | {z }
convective term
VP | {z } VP | {z }
diffusion term source term
temporal derivative

Here φ is the transported quantity, i.e., velocity, mass or turbulent energy and Γφ is the diffusion
coefficient of the transported quantity. This is a second order equation since the diffusion term
includes a second order derivative of φ in space. To represent this term with acceptable accuracy,
the order of the discretization must be equal or higher than the equation to be discretized. In
the same manner, to conform to this level of accuracy, temporal discretization must be of second
order as well. As a consequence of this requirement, all dependent variables are assumed to vary
linearly around the point P and time t, so that

φ(x) = φP + (x − xP ) · (∇φ)P ,
 t
∂φ (46)
φ(t + δt) = φt + δt .
∂t

Each of the terms in equation 43 will be treated separately, starting with the spatial functions.
Gauss theorem will be used throughout the discretization process in order to reduce the volume
integrals to their surface equivalents, e.g.,

17
Z I
∇ · adV = dS · a,
VP ∂VP
Z I
∇adV = dSa, (47)
VP ∂VP
Z I
∇φdV = dSφ,
VP ∂VP

where ∂VP is the surface bounding the volume VP and dS is an infinitesimal surface element
with the normal pointing outward on the surface ∂VP .

A series of volume and surface integrals need to be evaluated over the control volume to second
order accuracy. Taking into account the variation of φ over the control volume CV P (eq. 44), it
follows

Z Z
φ (x) dV = [φP + (x − xP ) · (∇φ)P ] dV
VP VP
Z Z 
(48)
= φP dV + (x − xP ) dV · (∇φ)P
VP VP
= φP VP ,

where VP is the volume of the control volume CV P . The second integral in equation 39 is equal
to zero because the point P is the centroid of the control volume.

Let us now consider the terms under the divergence operator. Recalling that all the cell faces
are convex and using similar assumptions as before, integration of the divergence operator over
a CV surface produces

Z I
∇ · φdV = dS · φ
VP ∂VP
X Z 
= dS · φ (49)
f f
X
= S · φf ,
f

In our mesh structure, the face area vector Sf points outwards from CV P only if f is owned by
CV P . For the neighboring faces Sf points inwards, which needs to be taken into account in the
sum in eq. 47. The sum over the faces is therefore split into sums over owned and neighboring
faces as follows
X X X
S · φf = Sf · φf − Sf · φf , (50)
f owner neighbor

and this is true for every summation over the faces. In the rest of our discussion, this split is
automatically assumed.

The face values φf of the variables in eq. 47 or eq. 48 have to be calculated by some form of
interpolation, this issue is discussed in the following sections.

18
4.2.1 Convection Term
The discretization of the convection term is obtained from equation 47,

Z X
∇ · (ρuφ) dV = S · (ρuφ)f
VP f
X
= S · (ρu)f φf (51)
f
X
= F φf ,
f

where F in equation 49 represents the mass flux through the face,

F = S · (ρu)f . (52)
Obviously, the flux F depends on the face value of ρ and u, which can be calculated in a similar
fashion to φf as described in the next section, with the caveat that the velocity field from which
the fluxes are derived must be such that the continuity equation is obeyed, i.e.,
Z I X Z  X
∇ · udV = dS · u = dS · u = F = 0. (53)
VP ∂VP f f

Before we continue with the formulation of the convection differencing scheme to compute the
face value of the variable φ, it is necessary to examine the physical properties of the convection
term. Irrespective of the distribution of the velocity in the domain, the convection term does not
violate the bounds of φ given by its initial condition. If for example, φ initially varies between
0 and 1, the convection term will never produce values of φ that are lower than zero or higher
that one. Considering the importance of boundedness in the transport of scalar properties, it is
essential to preserve this property in the discretized form of the term.

4.2.1.1 Convection Differencing Scheme. The role of the convection differencing scheme
is to determine the value of φ on the face using the values from the nearest neighbors CV centers.
Since linear variation of the dependent variables is assumed, the face centered value can be found
from a simple interpolation between the cell values at P and N (see figure 3), such that

φf = fx φP + (1 − fx ) φN . (54)
In eq. 52, the interpolation factor fx , is defined as the ratio of the distances f N and P N (refer
to figure 3), i.e.,

fN
fx = . (55)
PN
This practice is commonly known as Central Differencing (CD) and has been shown to be sec-
ond order accurate ([7, 3, 10, 11, 9, 13, 15]) which is consistent with the overall accuracy of the
method (second order). It has been noted however, that CD causes unphysical oscillations in
the solution for convection dominated problems, thus violating the boundedness of the solution.

An alternative discretization scheme that guarantees boundedness is the Upwind Differencing


(UD). In this scheme, the face value is determined according to the direction of the flow
(
φf = φP for F ≥ 0,
φf = (56)
φf = φN for F < 0.

19
Figure 3: Face interpolation.

This scheme guarantees the boundedness of the solution([7, 3, 10, 11, 9, 13, 15]). Unfortunately,
UD is first order accurate, hence it sacrifices the accuracy of the solution by implicitly intro-
ducing numerical diffusion. This scheme violates the order of accuracy of the dicretization and
can severely tamper the solution. In order to circumvent the numerical diffusion inherent of UD
and unboundedness of CD, linear combinations of UD and CD and second order variations of
UD has been developed in order to conform to the accuracy of the discretization and maintain
the boundedness and stability of the solution [7, 3, 10, 11, 9, 13, 15].

4.2.1.2 Diffusion Term. Using a similar approach as before, the diffusion term in eq. 43
can be discretized as follows

Z X
∇ · (ρΓφ ∇φ) dV = S · (ρΓφ ∇φ)f ,
VP f
X (57)
= (ρΓφ )f S · (∇φ)f ,
f

where (Γφ )f can be found from eq. 52. If the mesh is orthogonal, i.e., the vectors d and S in
figure 4 are parallel, it is possible to use the following expression

Figure 4: Vector d and S on a non-orthogonal mesh.

20
φN − φP
S · (∇φ)f = |S| . (58)
|d|
Using eq. 56, the face gradient of φ can be calculated from the two values of the closest faces.

Unfortunately, mesh orthogonality is more an exception than a rule. In order to make use of
the higher accuracy of eq. 56, the product S · (∇φ)f is split in two parts

S · (∇φ)f = ∆ · (∇φ)f + k · (∇φ)f . (59)


| {z } | {z }
orthogonal contribution non-orthogonal contribution

The two vectors introduced in eq. 57, namely; ∆ and k, need to satisfy the following condition

S = ∆ + k. (60)

If the vector ∆ is chosen to be parallel with d. This allows us to use eq. 56 on the orthogonal
contribution, limiting the less accurate method only to the non-orthogonal part which cannot
be treated in any other way.

To handle the mesh orthogonality decomposition within the constraints of eq. 58, several ap-
proaches have been studied ([15, 8, 10]), but the so-called over-relaxed approach seems to be
the most robust, stable and computationally efficient. In this approach, the importance of the
term in φP and φN is caused to increase with the increase in non-orthogonality, such as

d
∆= |S|2 . (61)
d·S

Figure 5: Non-orthogonality treatment in the over-relaxed approach.

The decomposition of the face area vector is shown in figure 5. The diffusion term eq. 55, in
its differential form exhibits a bounded behavior. Hence, its discretized form will preserve only
on orthogonal meshes. The non-orthogonal correction potentially creates unboundeness, partic-
ularly if mesh non-orthogonality is high. If the preservation of boundedness is more important
than accuracy, the non-orthogonal correction has got to be limited or completely discarded,
thus violating the order of accuracy of the discretization. Hence care must be taken to keep
mesh orthogonality within reasonable bounds. In eq. 57, the face interpolated values of ∇φ are
calculated using eq. 52.

21
4.2.1.3 Source Terms. All terms of the transport equation that cannot be written as con-
vection, diffusion or temporal contributions are here loosely classified as source terms. The
source term, Sφ (φ), can be a general function of φ. When deciding on the form of the dis-
cretization for the source term, its interaction with other terms in the equation and its influence
on boundedness and accuracy should be examined. Some general comments on the treatment
of source terms are given in references [7, 3, 10, 9, 13]. But in general and before the actual
discretization, the source terms need to be linearized (for instance by using Picard’s method),
such that,

Sφ (φ) = Su + Sp φ,
where Su and Sp can also depend on φ. Following eq. 46, the volume integral of the source
terms is calculated as
Z
Sφ (φ) dV = Su VP + Sp VP φP . (62)
VP

4.2.2 Temporal Discretization


In the previous section, the discretization of the spatial terms was presented. Let us now consider
the temporal derivative of the general transport eq. 43, by 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. (63)
t VP

Using equations 47, 55 and 60, eq. 61 can be written as,

 
Z t+δt  
 ∂ρφ
X X
VP + F φf − (ρΓφ )f S · (∇φ)f  dt
t ∂t P
f f
Z t+δt
= (Su VP + Sp VP φP ) dt. (64)
t

The above expression is usually called the semi-discretized form of the transport equation. It
should be noted that the order of the temporal discretization of the transient term in eq. 64
does not need to be the same as the order of the discretization of the spatial terms (convection,
diffusion and source). Each term can be treated differently to yield different accuracies. As long
as the individual terms are second order accurate, the overall accuracy will also be second order.

4.2.2.1 Time Centered Crank-Nicolson. Keeping in mind the assumed variation of φ


with t (eq. 44), the temporal derivative and time integral can be calculated as follows,

 
∂ρφ ρnP φnP − ρPn−1 φPn−1
= ,
∂t P δt
Z t+δt (65)
1 n−1 
φ(t)dt = φP + φn δt,
t 2

where φn = φ(t + δt) and φn−1 = φ(t) represent the value of the dependent variable at the new
and previous times respectively. Equation 63 provides the temporal derivative at a centered

22
time between times n − 1 and n. Combining equations 62 and 63 and assuming that the density
and diffusivity do not change in time, we get

ρP φnP − ρP φPn−1 1X 1X
VP + F φnf − (ρΓφ )f S · (∇φ)nf (66)
δ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 .
2 2
This form of temporal discretization is called Crank-Nicolson (CN) method and is second order
accurate in time. It requires the face values of φ and ∇φ as well as the cell values for both old
and new time levels. The face values are calculated from the cell values on each side of the face,
using the appropriate differencing scheme for the convection term and eq. 57 for the diffusion
term. The CN method is unconditionally stable, but does not guarantee boundedness of the
solution.

4.2.2.2 Backward Differencing. Since the variation of φ in time is assumed to be linear,


eq. 63 provides a second order accurate representation of the time derivative at t + 21 δt only.
Assuming the same value for the derivative at time t or t + δt reduces the accuracy to first order.
However, if the temporal derivative is discretized to second order, the whole discretization of the
transport equation will be second order without the need to center the spatial terms in time.
The scheme produced is called Backward Differencing (BD) and uses three time levels,

φn−2 = φt−δt ,
φn−1 = φt , (67)
n t+δt
φ =φ ,
to calculate the temporal derivative. Expressing time level n − 2 as a Taylor expansion around
n we get
 n  2 n
n−2 n ∂φ ∂ φ 2 3

φ =φ −2 δt + 2 δt + O δt , (68)
∂t ∂t2
doing the same for time level n − 1 we obtain
 n  n
∂φ 1 ∂2φ 
φn−1 = φn − δt + δt 2
+ O δt 3
. (69)
∂t 2 ∂t2
Combining this equation with eq. 66 produces a second order approximation of the temporal
derivative at the new time n as follows
 n 3 n
∂φ 2φ − 2φn−1 + 12 φn−2
= . (70)
∂t δt
By neglecting the temporal variation in the face fluxes and derivatives, eq. 68 produces a 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 . (71)

23
In the CN method, since the flux and non-orthogonal component of the diffusion term have to
be evaluated using values at the new time n, it means that it requires inner-iterations during
each time step. Coupled with the memory overhead due to the large number of stored variables,
this implies that the CN method is expensive compared to the BD described before. The BD
method, although cheaper and considerably easier to implement than the CN method, results in
a truncation error larger than the latter. This is due to the assumed lack of temporal variation
in face fluxes and derivatives. This error manifests itself as an added diffusion similar to that
produced by UD of the convection term. However, if we restrict the Courant number (CFL) to
a value below 1, the time step will tend to be very small, keeping temporal diffusion errors to a
minimum and promoting the stability of the spatial discretization scheme and the boundedness
of the BD method.

At this point, after spatial and temporal discretization and by using equations 64 or 69 in every
control volume CV of the domain, a system of algebraic equations of the form

[A] [φ] = [R] , (72)


is assembled. In eq. 70, [A] is a sparse matrix, with coefficients aP on the diagonal and aN off
the diagonal, [φ] is the vector of φ for all control volumes and [R] is the source term vector.
When this system is solved, it gives a new set of [φ] values (the solution for the new time step
n). The coefficients aP include the contribution from all terms corresponding to [φnP ], that is,
the temporal derivative, convection and diffusion terms, as well as the linear part of the source
term. The coefficients aN include the corresponding terms for each of the neighboring points.
The summation is done over all the control volumes that share a face with the current control
volume. The source term includes all terms that can be evaluated without knowing the new [φ],
namely, the constant part of the source term and the parts of the temporal derivative, convection
and diffusion terms corresponding to the old time level n − 1. This system of equations can be
solved either by direct or iterative methods. Direct methods give the solution of the system of
algebraic equations in a finite number of arithmetic operations. Iterative methods start with an
initial guess and then continue to improve the current approximation of the solution until some
solution tolerance is met. While direct methods are appropriate for small systems, the number
of operations necessary to reach the solution raises with the number of equations squared, mak-
ing them prohibitively expensive for large systems. Iterative methods are more economical, but
they usually pose some requirements on the matrix.

4.2.3 Boundary Conditions


Each control volume provides one algebraic equation. Volume integrals are calculated in the
same way for every interior CV, but fluxes through CV faces coinciding with the domain bound-
ary require special treatment. These boundary fluxes must either be known, or be expressed as a
combination of interior values and boundary data. Since they do not give additional equations,
they should not introduce additional unknowns . Since there are no nodes outside the boundary,
these approximations must be based on one-sided differences or extrapolations.

Usually there are three boundary conditions, which are used to close the system of equations,
namely:

• Zero-gradient boundary condition, defining the solution gradient to be zero. This condition
is known as a Neumann-type boundary condition.

• Fixed-value boundary condition, defining a specified value of the solution. This is a


Dirichlet-type condition.

24
• Symmetry boundary condition, treats the conservation variables as if the boundary was a
mirror plane. This condition defines that the component of the solution gradient normal
to this plane should be fixed to zero. The parallel components are extrapolated from the
interior cells,

For example, for an external aerodynamics simulation, at the inflow boundary the velocity is
defined as fixed-value and the pressure as zero-gradient. At the outflow boundary, the pressure is
defined as a fixed-value and the velocity as a zero-gradient. If symmetry is a concern, symmetry
boundary conditions are used at fixed boundaries. On a fixed wall the no-slip condition needs to
be guaranteed, therefore a fixed-value is specified for the velocity (u = 0) in combination with
a zero-gradient for the pressure. If the boundary of the wall moves, then the proper boundary
condition is a moving-wall velocity which introduces an extra velocity in order to maintain the
no-slip condition and ensures a zero flux through the moving boundary.

5 The Finite Volume Method for Diffusion and Convection-


Diffusion Problems
5.1 Steady One-Dimensional Diffusion
5.2 Steady One-Dimensional Convection-Diffusion
In the absence of sources, steady convection and diffusion of a property φ in a given one-
dimensional flow field is governed by
 
∂ ∂ ∂φ
(ρuφ) = Γ (73)
∂x ∂x ∂x
The flow must also satisfy continuity

∂ (ρu)
=0 (74)
∂x
We consider the one-dimensional control volume shown in figure 6. Our attention is focused in
a general node P, the neighboring nodes are identified by W and E and the control volume faces
by w and e.

Figure 6: 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 .

Integration of eq. 73 over the control volume shown in figure 6 gives


   
∂φ ∂φ
(ρuSφ)e − (ρuSφ)w = ΓS − ΓS (75)
∂x e ∂x w

25
and integration of eq. 74 yields to

(ρuS)e − (ρuS)w = 0 (76)


To obtain discretized equations for the convection-diffusion problem we must approximate the
terms in eq. 75. It is convenient to define two variables F and D to represent the convective
mass flux per unit area and diffusion conductance at cell faces

F = ρu,
Γ (77)
D=
δx
The cell face values of the variables F and D can be written as

Fw = (ρu)w Fe = (ρu)e ,
Γ Γ (78)
Dw = De =
δxW P δxP E

By employing the central differencing approach to represent the contribution of the diffusion
terms on the right hand side of eq. 75, we obtain

   
∂φ φE − φP
ΓS = Γe Se
∂x e δxP E
    (79)
∂φ φP − φW
ΓS = Γw Sw
∂x w δxW P

for the diffusive terms.

Integrating the convection-diffusion eq. 75, we obtain

Fe φe − Fw φw = De (φE − φP ) − Dw (φP − φW ) (80)

and the integrated continuity eq. 76 becomes

Fe − Fw = 0 (81)
In the previous we assumed that Sw = Se = S, so we can divide the left and right hand sides of
eq. 75 by the area S.

The central differencing approximation has been used to represent the diffusion terms which
appear on the right hand side of eq. 80, and it seems logical to try linear interpolation to
compute the cell face values for the convective terms on the left hand side of this equation. For
a uniform grid we can write the cell face values of property the φ as

(φP − φE )
φe =
2 (82)
(φW − φP )
φw =
2
Substitution of the above equations into the convection terms of eq. 80 yields to

26
Fe Fw
(φP + φE ) − (φW + φP ) = De (φE − φP ) − Dw (φP − φW ) (83)
2 2
Rearranging and grouping eq. 80 yields to

aP φP = aW φW + aE φE (84)
where

Fw
aW = Dw +
2
Fe (85)
aE = De −
2
aP = aW + aE + (Fe − Fw )

To solve a one-dimensional convection-diffusion problem we write discretized equations of the


form of eq. 85 for all grid nodes. This yields to a set of algebraic equations that is solved to
obtain the distribution of the transported property φ. We also need to defined the initial and
boundary condition in order to have a well posed problem. Let us now present the previously
discussed concepts by means of a working example.

5.2.1 Steady one-dimensional convection-diffusion working example


A property φ is transported by means of convection and diffusion through the one-dimensional
domain sketched in figure 7. The governing equation is eq. 73 and eq. 74; the boundary
conditions are φ0 = 1 at x = 0 and φL = 0 at x = L. Using five equally spaced cells and the
central differencing scheme for the convection and diffusion terms, calculate the distribution of φ
as a function of x for u = 0.1 m/s and u = 2.5 m/s, and compare the results with the analytical
solution
ρux
φ − φ0 e Γ −1
= ρuL (86)
φL − φ0 e Γ −1

Figure 7: Domain with initial and boundary conditions.

Let us explain step by step the solution method by using the grid illustrated in figure 8. The
domain has been divided into five control volumes, so as δx = 0.2 m. Note that L = 1.0 m
(length), ρ = 0.1 kg/m3 , Γ = 0.1 kg/m.s.

Figure 8: Grid used for discretization.

The discretized eq. 84 and its coefficients eq. 85 apply to all internal control volumes (2, 3 and
4). Control volumes 1 and 5 need special treatment since they are boundary cells. Integrating

27
the convection-diffusion equation eq. 73 and using central differences for both the convective
and diffusive terms, and by applying the boundary and initial conditions we can obtain the
solution to our model equation.

The value of φ is given at the west face of cell 1 (φw = φA = 1) so we do not need to make any
approximation in the convective flux term at this boundary. This yields the following equation
for node 1,

Fe
(φP + φE ) − FA φA = De (φE − φP ) − DA (φP − φA ) (87)
2
For the control volume 5, the φ value at the east face is known (φe = φB = 0). As before, we
obtain the following equation

Fw
FB φB − (φP + φW ) = DE (φB − φP ) − Dw (φP − φW ) (88)
2
Rearranging and grouping equations 87 and 88, we get the discretized equations at boundaries
nodes,

aP φP = aW φW + aE φE + Su (89)

where

aP = aW + aE + (Fe − Fw ) − SP (90)

Note that DA = DB = 2Γ/δx = 2D and FA = FB = F .

To introduce the boundary conditions we have suppressed the link to the boundary side and
entered the boundary flux as source terms.

Table 1: Nodes discretization.

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

For u = 0.1 m/s, F = ρu = 0.1, D = Γ/δx = 0.5, the coefficient are summarized in table 2.

Table 2: Coefficients summary.

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

By setting now φA = 1 and φB = 0, we get the following system of equations,

28
    
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
    (91)
 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
The solution of the previous system yields to
   
φ1 0.9421
φ2  0.8006
   
φ3  = 0.6276 (92)
   
φ4  0.4163
φ5 0.1579
The numerical and analytical solutions are compared in table 3 and in figure 9. The analytical
solution for this problem is,

2.7183 − ex
φ(x) = (93)
1.7183
From the results, it can be seen that regardless the coarseness of the grid, the central differencing
(CD) scheme gives reasonable agreement with the analytical solution.

Table 3: Comparison of the numerical and analytical solutions.

Node Position FVM solution Analytical solution Difference Percentage error


1 0.1 0.9421 0.9387 -0.003 -0.36
2 0.3 0.8006 0.7963 -0.004 -0.53
3 0.5 0.6276 0.6224 -0.005 -0.83
4 0.7 0.4163 0.4100 -0.006 -1.53
5 0.9 0.1579 0.1505 -0.007 -4.91

Figure 9: Comparison of the numerical and analytical solutions for u = 0.1 m/s.

The cell Peclet number (or cell Reynolds number), is defined as,

ρu∆x
P ecell = (94)
Γ

29
gives a relation between convection and diffusion. If the local Peclet number is less than 2, it is
sufficient for boundedness of the solution by using CD for computing the convective terms. But
when the Peclet number is higher than 2, the solution obtained by using CD for the convective
terms shows an oscillatory behaviour (unboundedness).

As an exercise, try to compute the cell Peclet number for the previous example.

In the next case (u = 2.5 m/s), the cell Peclet number is higher than 2. Let us see the solution,
this is let to you as an exercise. You just need to proceed in exactly the same way as we did before.

5.3 Unsteady One-Dimensional Diffusion


5.4 Unsteady One-Dimensional Convection-Diffusion

6 Finite Volume Method Algorithms for Pressure-Velocity Cou-


pling

References
[1] J. D. Anderson, “Computational Fluid Dynamics: The Basics with Applications”, McGraw-
Hill, 1995.

[2] J. D. Anderson, “Fundamentals of Aerodynamics”, McGraw-Hill, Fifth Edition, 2010.

[3] D. Drikakis and W. Rider, “High-Resolution Methods for Incompressible and Low-Speed
Flows”, Springer, 2005.

[4] P. M. Gresho, “Incompressible fluid dynamics: some fundamental formulation issues”, An-
nual Review of Fluid Mechanics, Vol. 23, 1991, pp. 413-453.

[5] F. M. White, “Viscous Fluid Flow”, McGraw-Hill, Third Edition, 2005.

[6] C. A. J. Fletcher, “Computational Techniques for Fluid Dynamics: Volume 2: Specific


Techniques for Different Flow Categories”, Springer, Second Edition, 1996.

[7] J. H. Ferziger and M. Peric, “Computational Methods for Fluid Dynamics”, Springer, Sec-
ond Edition, 2002.

[8] J. Blazek, “Computational Fluid Dynamics: Principles and Applications”, Elsevier, Second
Edition, 2003.

[9] E. F. Toro, “Riemann Solvers and Numerical Methods for Fluid Dynamics”, Springer, Third
Edition, 2009.

[10] H. Versteeg and W. Malalasekera, “An Introduction to Computational Fluid Dynamics:


The Finite Volume Method”, Pearson, Second Edition, 2007.

[11] S. Patankar, “Numerical Heat Transfer and Fluid Flow”, McGraw-Hill, 1980.

[12] R. H. Pletcher, J. C. Tannehill and D. A. Anderson, “Computational Fluid Mechanics and


Heat Transfer”, Taylor and Francis, Second Edition, 1997.

[13] R. J. LeVeque, “Finite Volume Methods for Hyperbolic Problems”, Cambridge Texts in
Applied Mathematics, 2002.

30
[14] C. Hirsch, “Numerical Computation of Internal and External Flows: The Fundamentals of
Computational Fluid Dynamics”, Butterworth-Heinemann, Second Edition, 2007.

[15] H. Jasak, “Error Analysis and Estimation for the Finite Volume Method with Application
for Fluid Flows”, PhD Thesis, Imperial College London, 1996.

[16] H. Jasak, “High Resolution NVD Differencing Scheme for Arbitrarily Unstructured
Meshes”, Int. J. Numer. Meth. Fluids, Vol. 31, pp. 431-449, 1999.

[17] X. Jiang and C-H. Lai, “Numerical Techniques for Direct and Large-Eddy Simulations”,
CRC Numerical Analysis and Scientific Computing Series, 2009.

[18] P. A. Durbin and B. A. Pettersson-Reif, “Statistical Theory and Modeling for Turbulent
Flows”, Wiley, Second Edition, 2010.

[19] A. Dewan, “Tackling Turbulent Flows in Engineering”, Springer, 2011.

[20] P. Sagaut, “Large Eddy Simulation for Incompressible Flows: An Introduction”, Springer,
2005.

[21] L. C. Berselli, T. Iliescu and W. J. Layton , “Mathematics of Large Eddy Simulation of


Turbulent Flows”, Springer, 2010.

[22] D. C. Wilcox, “Turbulence Modeling for CFD”, DCW Industries, Third Edition, 2006.

[23] T. Cebeci, “Turbulence Models and Their Application: Efficient Numerical Methods with
Computer Programs”, Springer, 2004.

[24] S. B. Pope , “Turbulent Flows”, Cambridge University Press, 2000.

[25] K. A. Hoffmann and S. T. Chiang, “Computational Fluid Dynamics. Volume 3”, EES,
Fourth Edition, 2000.

[26] C. M. Rhie and W. L. Chow, “Numerical Study of the Turbulent Flow Past an Airfoil with
Trailing Edge Separation”, AIAA Journal, 21(11), 1983, pp. 1525-1532.

[27] D. C. Wilcox, “Re-assessment of the Scale-Determining Equation for Advanced Turbulence


Models”, AIAA Journal, vol. 26(11), 1988, pp. 1299-1310.

[28] T. J. Barth and D. C. Jespersen, “The Design and Application of Upwind Schemes on Un-
structured Meshes”, AIAA Paper 89-0366, AIAA 27th Aerospace Sciences Meeting, Reno,
Nevada, 1989.

[29] S.-E. Kim, B. Makarov and D. Caraeni, “A Multi-Dimensional Linear Reconstruction


Scheme for Arbitrary Unstructured Grids”, Technical Report, AIAA Paper, 2003-3990,
AIAA 16th Computational Fluids Dynamics Conference, Orlando, Florida, 2003.

[30] U. Frisch, “Turbulence, the legacy of A. N. Kolmogorov”, Cambridge University Press,


Cambridge, 1995.

31

You might also like