Introduction To CFD
Introduction To CFD
net/publication/300628334
Introduction to CFD
CITATIONS READS
5 11,163
1 author:
Shamoon Jamshed
Institute of Space Technology
20 PUBLICATIONS 30 CITATIONS
SEE PROFILE
All content following this page was uploaded by Shamoon Jamshed on 06 July 2018.
Dear Author,
Any queries or remarks that have arisen during the processing of your manuscript are listed below and are highlighted by
flags in the proof. (AU indicates author queries; ED indicates editor queries; and TS/TY indicates typesetter queries.)
Please check your proof carefully and answer all AU queries. Mark all corrections and query answers at the appropriate
place in the proof using on-screen annotation in the PDF file. For a written tutorial on how to annotate PDFs, click
http://www.elsevier.com/__data/assets/pdf_file/0016/203560/Annotating-PDFs-Adobe-Reader-9-X-or-XI.pdf. A video
tutorial is also available at http://www.screencast.com/t/9OIDFhihgE9a. Alternatively, you may compile them in
a separate list and tick off below to indicate that you have answered the query.
Please return your input as instructed by the project manager.
,
There are no queries in this article
To protect the rights of the author(s) and publisher we inform you that this PDF is an uncorrected proof for internal business use only by
the author(s), editor(s), reviewer(s), Elsevier and typesetter TNQ Books and Journals Pvt Ltd. It is not allowed to publish this proof
online or in print. This proof copy is the copyright property of the publisher and is confidential until formal publication.
CHAPTER 1
10001-JAMSHED-9780128015674
To protect the rights of the author(s) and publisher we inform you that this PDF is an uncorrected proof for internal business use only by
the author(s), editor(s), reviewer(s), Elsevier and typesetter TNQ Books and Journals Pvt Ltd. It is not allowed to publish this proof
online or in print. This proof copy is the copyright property of the publisher and is confidential until formal publication.
10001-JAMSHED-9780128015674
To protect the rights of the author(s) and publisher we inform you that this PDF is an uncorrected proof for internal business use only by
the author(s), editor(s), reviewer(s), Elsevier and typesetter TNQ Books and Journals Pvt Ltd. It is not allowed to publish this proof
online or in print. This proof copy is the copyright property of the publisher and is confidential until formal publication.
Introduction to CFD 3
p0045 One should compromise for less reliable CFD results when it is known
that not enough computational resources are available. This brings us to a
question regarding the control of uncertainties. Certain numerical schemes
result in dissipation error, such as first order. Other schemes such as
second-order result in dispersion error. Then there is machine error, grid
accuracy error, human error, and truncation error, to name a few. Thus,
unexpected predictions could cause the question, “Did I do something
wrong?.” In this case, it is essential to familiarize the user completely with
CFD tool(s) and avoid allowing him or her to use the tool as a black box.
p0050 Many engineers do not pursue product development, design, and
analysis as deeply as do CFD engineers. They do not understand turbulence
modeling, convergence, mesh, and such. To sell something in the market
using CFD, one should be smart and clever enough to say something the
customer can understand.
p0055 It is also annoying when software does not correspond the way it
should. This occurs when results do not converge or when there is some
complex mesh to deal with. At first, one should:
o0010 1. Carefully make assumptions if required.
o0015 2. Try to make the model simpler (such as using a symmetric or periodic
boundary condition).
o0020 3. Use reasonable boundary conditions. With an excellent mesh, results do
not converge mostly owing to incorrect boundary conditions.
o0025 4. Monitor convergence.
o0030 5. If not satisfied, go to mesh.
o0035 6. If experimental data are unavailable, perform a grid convergence study.
p0090 In this way, the efforts will not change skeptics’ perceptions overnight but
if a history of excellent CFD solutions is delivered, they will start to believe it.
p0095 Although CFD has been criticized, there are many great things about it.
A CFD engineer enjoys writing code and obtaining results, which increases
his confidence level. From a marketing point of view, people are mostly
attracted to the colorful pictures of CFD, which is how one can make a
presentation truly overwhelming. If one can produce good results but
cannot present the work convincingly, then all of the effort is useless.
p0100 From this discussion, it can be concluded that there are two important
points to remember. One is that the problem does not lie in CFD but could
be in the limitation of resources, lack of experimental data, or wrong
interpretation of results. Second, skepticism regarding CFD exists but one
should be smart enough to present the results in an attractive and evocative
manner. Remember the saying that a drop falling on a rock over a long
10001-JAMSHED-9780128015674
To protect the rights of the author(s) and publisher we inform you that this PDF is an uncorrected proof for internal business use only by
the author(s), editor(s), reviewer(s), Elsevier and typesetter TNQ Books and Journals Pvt Ltd. It is not allowed to publish this proof
online or in print. This proof copy is the copyright property of the publisher and is confidential until formal publication.
time can create a hole in it. That philosophy will definitely work here, as
well. CFD can be colorful dynamics or computational fluid dynamics with
colorful, meaningful results. It is your choice: What do you want to see and
what do you see?
10001-JAMSHED-9780128015674
To protect the rights of the author(s) and publisher we inform you that this PDF is an uncorrected proof for internal business use only by
the author(s), editor(s), reviewer(s), Elsevier and typesetter TNQ Books and Journals Pvt Ltd. It is not allowed to publish this proof
online or in print. This proof copy is the copyright property of the publisher and is confidential until formal publication.
Introduction to CFD 5
p0125 All three processes are interdependent. As much as 90% of effort is used
in the meshing (preprocessing) stage. This requires the user to be dexterous
and there must be the idea of creating an understandable topology. The
next stage is to solve the governing equations of flow, which is the com-
puter’s work. Remember that an error embedded in the mesh will prop-
agate in the solving stage as well, and if you are lucky enough, you may get
a converged solution. However, mostly, owing to only one culprit cell, the
solution diverges. The next phase after solving equations is post-processing.
There, the results of whatever was input and solved are obtained; colorful
pictures showing contours are interpreted for product design, development,
or optimization. For validation, the results are compared with experimental
data. If any experimental data are absent, the grid convergence study better
judges the authenticity of the results. In that case, the mesh is refined two or
three times, each time solving and getting results, until a never-changing
result (asymptotically converged solution) is obtained.
p0130 Post-processing has its own delights, and you can impress people by
showing flow simulations such as path lines, flow contours, vector plots,
flow ribbons, cylinders, and so forth. In unsteady flows, such as for direct
numerical simulation (DNS) and large eddy simulation (LES), the
iso-surface of Q-criterion or l-criterion is also shown sometimes. Post-
processing software such as Tecplot has the ability to see multiple things
simultaneously in a single picture. As examples, the stream line and flow
contours are shown simultaneously in Figure 1.2 for Ariane5 base flow [2]
and Figure 1.3 [1] shows the flow over a delta wing. There, the iso-surface
of constant pressure is shown over the wing, which is colored by the Mach
number. An iso-surface is a surface formed by a collection of points with
the same value of a property (such as temperature pressure).
p0135 We will focus on turbulent flows in this text because these problems are
mostly solved with HPC machines. Turbulence is caused by instabilities in
flow and is nondeterministic. There is a range of scales in turbulent flows that
can be as large as half the size of the body that causes the turbulence or
smaller than one-tenth of a millimeter. In current CFD techniques, in which
we use mesh to solve the flow, the mesh size must be such that it contains
cells not larger than the size of the smallest scale. Thus, the total mesh size
10001-JAMSHED-9780128015674
To protect the rights of the author(s) and publisher we inform you that this PDF is an uncorrected proof for internal business use only by
the author(s), editor(s), reviewer(s), Elsevier and typesetter TNQ Books and Journals Pvt Ltd. It is not allowed to publish this proof
online or in print. This proof copy is the copyright property of the publisher and is confidential until formal publication.
f0015 Figure 1.2 Flow structure at the base of Ariane5 ESA Satellite Launch Vehicle [2].
becomes too large for these problems: It could be over 30 million cells. A
case for benchmarking such a problem is discussed in Chapter 6, where the
mesh size is 111 million cells. The question is where to solve them. That is
the purpose of this book, and why we need HPC. HPC solves these
problems for us. Figure 1.4 shows an image of the vortices formed behind a
truck body. The vortices obviously form as a result of the turbulence in the
wake region. A corridor of low velocity often forms behind bodies, called
10001-JAMSHED-9780128015674
To protect the rights of the author(s) and publisher we inform you that this PDF is an uncorrected proof for internal business use only by
the author(s), editor(s), reviewer(s), Elsevier and typesetter TNQ Books and Journals Pvt Ltd. It is not allowed to publish this proof
online or in print. This proof copy is the copyright property of the publisher and is confidential until formal publication.
Introduction to CFD 7
f0025 Figure 1.4 Eddies form and computed in the wake owing to the technique of De-
tached Eddy Simulation (DES), which cannot be seen with conventional Reynolds
Averaged Navier Stokes (RANS) methods.
the wake. The scales I was talking about are the length of these vortices,
often called eddies. These eddies frequently form and are miscible near the
wall of the truck, whereas far from the truck body they mix with outside air
and dissipate in the form of heat. If exhaust from the truck is also considered,
a more realistic flow would be formed but computationally it would be more
complex to solve. An attractive picture of vortices is shown in Figure 1.4.
10001-JAMSHED-9780128015674
To protect the rights of the author(s) and publisher we inform you that this PDF is an uncorrected proof for internal business use only by
the author(s), editor(s), reviewer(s), Elsevier and typesetter TNQ Books and Journals Pvt Ltd. It is not allowed to publish this proof
online or in print. This proof copy is the copyright property of the publisher and is confidential until formal publication.
where
!
U ¼ ½u; v; w
10001-JAMSHED-9780128015674
To protect the rights of the author(s) and publisher we inform you that this PDF is an uncorrected proof for internal business use only by
the author(s), editor(s), reviewer(s), Elsevier and typesetter TNQ Books and Journals Pvt Ltd. It is not allowed to publish this proof
online or in print. This proof copy is the copyright property of the publisher and is confidential until formal publication.
Introduction to CFD 9
! vv
syy ¼ l V$U þ 2m (1.2e)
vy
! vw
szz ¼ l V$U þ 2m (1.2f)
vz
p0190 Asymmetric stress tensors are given as:
vv vu
sxy ¼ syx ¼ m þ (1.2g)
vx vy
vv vw
syz ¼ szy ¼ m þ (1.2h)
vz vy
vw vu
szx ¼ szx ¼ m þ (1.2i)
vx vz
2
l¼ m (1.2j)
3
10001-JAMSHED-9780128015674
To protect the rights of the author(s) and publisher we inform you that this PDF is an uncorrected proof for internal business use only by
the author(s), editor(s), reviewer(s), Elsevier and typesetter TNQ Books and Journals Pvt Ltd. It is not allowed to publish this proof
online or in print. This proof copy is the copyright property of the publisher and is confidential until formal publication.
10001-JAMSHED-9780128015674
To protect the rights of the author(s) and publisher we inform you that this PDF is an uncorrected proof for internal business use only by
the author(s), editor(s), reviewer(s), Elsevier and typesetter TNQ Books and Journals Pvt Ltd. It is not allowed to publish this proof
online or in print. This proof copy is the copyright property of the publisher and is confidential until formal publication.
Introduction to CFD 11
where the subscripts i and i þ 1 are the points for calculating the u values.
Here, Dx denotes the grid spacing. The method for calculating the first de-
rivative is also called the forward difference method, as we will soon observe.
10001-JAMSHED-9780128015674
To protect the rights of the author(s) and publisher we inform you that this PDF is an uncorrected proof for internal business use only by
the author(s), editor(s), reviewer(s), Elsevier and typesetter TNQ Books and Journals Pvt Ltd. It is not allowed to publish this proof
online or in print. This proof copy is the copyright property of the publisher and is confidential until formal publication.
The higher the number of points is, the more accurate will be the nu-
merical result. Consequently, the spacing reduction between points also
improves accuracy, but with some limitations. For a forward difference
approximation the stencil would be i and i þ 1. Hence, for function u the
value at i þ 1, i.e., ui þ 1, would be:
2 3
vu v2 u Dx v3 u Dx
uiþ1 ¼ ui þ Dx þ 2 þ 3 þ/ (1.5)
vx vx 2! vx 3!
10001-JAMSHED-9780128015674
To protect the rights of the author(s) and publisher we inform you that this PDF is an uncorrected proof for internal business use only by
the author(s), editor(s), reviewer(s), Elsevier and typesetter TNQ Books and Journals Pvt Ltd. It is not allowed to publish this proof
online or in print. This proof copy is the copyright property of the publisher and is confidential until formal publication.
Introduction to CFD 13
f0030 Figure 1.5 Graphical representation of three basic finite difference schemes.
p0275 The last term indicates the order of the central difference scheme. The
central difference scheme is second-order accurate. Therefore, it is widely
used in the calculations. The error that arises owing to the truncation
(cutting) of the higher-order derivatives of the Taylor series terms is called
the truncation error.
10001-JAMSHED-9780128015674
To protect the rights of the author(s) and publisher we inform you that this PDF is an uncorrected proof for internal business use only by
the author(s), editor(s), reviewer(s), Elsevier and typesetter TNQ Books and Journals Pvt Ltd. It is not allowed to publish this proof
online or in print. This proof copy is the copyright property of the publisher and is confidential until formal publication.
where fi is the variable value at the elemental surfaces and N denotes the
number of bounding surfaces on the elemental volume. Equation (1.11)
applies for any type of finite volume cell that can be represented within
the numerical grid. For the structured mesh shown in Figure 1.6, N has
a value of 4 because there are four bounding surfaces of the element. In
3D, for a hexagonal element, N becomes 6. Similarly, the first-order deriv-
ative for f in the y-direction is obtained, which can be written as:
Z Z
vf 1 vf 1 1 X N
¼ dV ¼ fdAy ¼ f Ay (1.12)
vy DV vy DV DV i¼1 i i
V A
10001-JAMSHED-9780128015674
To protect the rights of the author(s) and publisher we inform you that this PDF is an uncorrected proof for internal business use only by
the author(s), editor(s), reviewer(s), Elsevier and typesetter TNQ Books and Journals Pvt Ltd. It is not allowed to publish this proof
online or in print. This proof copy is the copyright property of the publisher and is confidential until formal publication.
Introduction to CFD 15
b0010
Problem
This problem describes the discretization of continuity equation using FVM. The results are
shown and compared with the FDM solution of the same equation. The 2D continuity
equation must be discretized:
vu vv
þ ¼0 (1.13)
vx vy
on a structured grid.
10001-JAMSHED-9780128015674
To protect the rights of the author(s) and publisher we inform you that this PDF is an uncorrected proof for internal business use only by
the author(s), editor(s), reviewer(s), Elsevier and typesetter TNQ Books and Journals Pvt Ltd. It is not allowed to publish this proof
online or in print. This proof copy is the copyright property of the publisher and is confidential until formal publication.
f0045 Figure 1.8 Stencil of finite volume method grid for the problem.
Solution: The stencil used for the problem is shown in Figure 1.8. Introducing control
volume integration, that is, applying Eqns (1.11) and (1.12), yields the following expressions,
which are applicable to both structured and unstructured grids:
remove braces and '1'
vf 1 X
N
1 ue Axe uw Axw þ un Axn us Axs
¼ fA ¼
x
(1.14)
vx DV i¼1 i i DV
Similarly,
vf 1 X
N
¼ f Ay (1.15)
vy DV i¼1 i i
10001-JAMSHED-9780128015674
To protect the rights of the author(s) and publisher we inform you that this PDF is an uncorrected proof for internal business use only by
the author(s), editor(s), reviewer(s), Elsevier and typesetter TNQ Books and Journals Pvt Ltd. It is not allowed to publish this proof
online or in print. This proof copy is the copyright property of the publisher and is confidential until formal publication.
Introduction to CFD 17
10001-JAMSHED-9780128015674
To protect the rights of the author(s) and publisher we inform you that this PDF is an uncorrected proof for internal business use only by
the author(s), editor(s), reviewer(s), Elsevier and typesetter TNQ Books and Journals Pvt Ltd. It is not allowed to publish this proof
online or in print. This proof copy is the copyright property of the publisher and is confidential until formal publication.
p0335 Similarly, for the y-component, performing this operation again with N
and S cell centers and v as the velocity component, we get:
vN vS
(1.20)
2Dy
p0340 Summing both Eqns (1.19) and (1.20) and equating to zero to get the
continuity equation:
uE uW vN vS
þ ¼0 (1.21)
2Dx 2Dy
p0345 Comparing Eqn (1.21) with Eqn (1.16), there is no difference between
them. Both schemes are second-order accurate.
10001-JAMSHED-9780128015674
To protect the rights of the author(s) and publisher we inform you that this PDF is an uncorrected proof for internal business use only by
the author(s), editor(s), reviewer(s), Elsevier and typesetter TNQ Books and Journals Pvt Ltd. It is not allowed to publish this proof
online or in print. This proof copy is the copyright property of the publisher and is confidential until formal publication.
Introduction to CFD 19
10001-JAMSHED-9780128015674
To protect the rights of the author(s) and publisher we inform you that this PDF is an uncorrected proof for internal business use only by
the author(s), editor(s), reviewer(s), Elsevier and typesetter TNQ Books and Journals Pvt Ltd. It is not allowed to publish this proof
online or in print. This proof copy is the copyright property of the publisher and is confidential until formal publication.
f0050 Figure 1.9 Flow behind a plane ball and a golf ball, a laminar boundary layer expe-
riences more drag than a turbulent one.
Thus, CFD helps us in many complicated cases for which we cannot easily
p0375 judge or analyze based on experimental or analytical data. The growing
popularity of CFD is solely due to the rapid increase in computational power
and the efficacy that is reflected by the field itself. However, because humanity’s
desires do not rest, as computational power crosses a quadrillion floating-point
operations per second, scientists and fluid dynamicists will begin to float new
complex problems that are currently thought to be impossible to solve.
REFERENCES
[1] Jamshed S, Hussain M. Viscous flow simulations on a delta rectangular wing using Spalart
Allmaras as a turbulence model. In: Proceedings of the 8th international Bhurban
conference on applied sciences & technology. (Islamabad, Pakistan): January 2011.
[2] Jamshed S, Thornber B. Numerical analysis of transonic base-flow of Ariane5. In: 7th
International Bhurban conference on applied sciences & technology. (Islamabad,
Pakistan): Centre of excellence on science and technology (CESAT); January 7, 2010.
[3] Moin P, Kim J. Tackling turbulence with supercomputers. Scientific American January
1997, pp 62–68.
[4] Moin P, Kim J, Choi H. Direct numerical simulation of turbulent flow over riblets.
Journal of Fluid Mechanics October 1993;Vol. 255:503–39. http://dx.doi.org/10.1017/
S0022112093002575.
10001-JAMSHED-9780128015674
JAMSHED: 01
Non-Print Items
Abstract:
This chapter is an introduction to Computational Fluid Dynamics (CFD). Many organizations implement CFD in the
computer-aided engineering phase. However, most of the time, higher management is not interested, perhaps because of
the lengthy simulations or uncertainty regarding results. These issues are discussed and various misconceptions about CFD
are explored and cleared up. The basics of CFD with governing equations are also discussed.
Keywords:
CFD; Governing equations; Simulations; Uncertainty.