When an engineer is tasked with designing a new product, e.g. a winning race car for the next season, aerodynamics play an important role in the engineering process. However, aerodynamic processes are not easily quantifiable during the concept phase. Usually the only way for the engineer to optimize his designs is to conduct physical tests on product prototypes. With the rise of computers and ever-growing computational power (thanks to Moore’s law!), the field of **Computational Fluid Dynamics** became a commonly applied tool for generating solutions for fluid flows with or without solid interaction. In a CFD analysis, the examination of fluid flow in accordance with its physical properties such as velocity, pressure, temperature, density and viscosity is conducted. To virtually generate a solution for a physical phenomenon associated with fluid flow, without compromise on accuracy, those properties have to be considered simultaneously.

A mathematical model of the physical case and a numerical method are used in a software tool to analyze the fluid flow. For instance, the Navier-Stokes equations are specified as the mathematical model of the physical case. This describes changes on all those physical properties for both fluid flow and heat transfer. The mathematical model varies in accordance with the content of the problem such as heat transfer, mass transfer, phase change, chemical reaction, etc. Moreover, the reliability of a CFD analysis highly depends on the whole structure of the process. The verification of the mathematical model is extremely important to create an accurate case for solving the problem. Besides, the determination of proper numerical methods to generate a path through the solution is as important as a mathematical model. The software, which the analysis is conducted with is one of the key elements in generating a sustainable product development process, as the amount of physical prototypes can be reduced drastically.

From antiquity to present, humankind has been eager to discover phenomena based on fluid flow. So, how old is CFD? Experimental studies in the field of computational fluid dynamics have one big disadvantage: if they need to be accurate, they consume a significant amount of time and money. Consequently, scientists and engineers wanted to generate a method that enabled them to pair a mathematical model and a numerical method with a computer for faster examination.

The brief story of Computational Fluid Dynamics can be seen below:

**Until 1910:**Improvements on mathematical models and numerical methods.**1910 – 1940:**Integration of models and methods to generate numerical solutions based on hand calculations1

${}^{1}$.

**1940 – 1950:**Transition to computer-based calculations with early computers (ENIAC)3

${}^{3}$. Solution for flow around cylinder by Kawaguti with a mechanical desk calculator in 19538

${}^{8}$.

**1950 – 1960:**Initial study using computers to model fluid flow based on the Navier-Stokes equations by Los Alamos National Lab, US. Evaluation of vorticity – stream function method4

${}^{4}$. First implementation for 2D, transient, incompressible flow in the world6

${}^{6}$.

**1960 – 1970:**First scientific paper “Calculation of potential flow about arbitrary bodies” was published about computational analysis of 3D bodies by Hess and Smith in 19675

${}^{5}$. Generation of commercial codes. Contribution of various methods such k-ε turbulence model, Arbitrary Lagrangian-Eulerian, SIMPLE algorithm which are all still broadly used6

${}^{6}$.

**1970 – 1980:**Codes generated by Boeing, NASA and some have unveiled and started to use several yields such as submarines, surface ships, automobiles, helicopters and aircrafts4,6

${}^{4,6}$.

**1980 – 1990:**Improvement of accurate solutions of transonic flows in three-dimensional case by Jameson et. al. Commercial codes have started to implement through both academia and industry7

${}^{7}$.

**1990 – Present:**Thorough developments in Informatics: worldwide usage of CFD virtually in every sector.

**The bigger picture:** The central mathematical description for all theoretical fluid dynamics models is given by the Navier-Stokes equations, which describe the motion of viscous fluid domains. The history of their discoveries is quite interesting. It is a bizarre coincidence that the famous equation of Navier-Stokes has been generated by Claude-Louis Navier (1785-1836) and Sir George Gabriel Stokes (1819-1903) who had never met. At first, Claude-Louis Navier conducted studies on a partial section of equations up until 1822. Later, Sir George Gabriel Stokes adjusted and finalized the equations in 18459

.

${}^{14}$

(left) and Sir George Gabriel Stokes15

${}^{15}$(right)

The main structure of thermo-fluids examinations is directed by governing equations that are based on the conservation law of fluid’s physical properties. The basic equations are the three physics laws of conservation10,11

${}^{10,11}$:

**1. Conservation of Mass: Continuity Equation**

**2. Conservation of Momentum: Momentum Equation of Newton’s Second Law**

**3. Conservation of Energy: First Law of Thermodynamics or Energy Equation**

These principles state that mass, momentum and energy are stable constants within a closed system. Basically: What comes in, must also go out somewhere else.

The investigation of fluid flow with thermal changes relies on certain physical properties. The three unknowns which must be obtained simultaneously from these three basic conservation equations are the velocity v⃗

$\overrightarrow{v}$, pressure p

$p$and the absolute temperature T

$T$. Yet p

$p$and T

$T$are considered the two required independent thermodynamics variables. The final form of the conservation equations also contains four other thermodynamics variables; density ρ

$\rho $, the enthalpy h

$h$as well as viscosity μ

$\mu $and thermal conductivity k

$k$; the last two are also transport properties. Since p

$p$and T

$T$are considered two required independent thermodynamics variables, these four properties are uniquely determined by the value of p

$p$and T

$T$. Fluid flow should be analyzed to know vecv

$vecv$, p

$p$and T

$T$throughout every point of the flow regime. This is most important before designing any product which involves fluid flow. Furthermore, the method of fluid flow observation based on kinematic properties is a fundamental issue. Movement of fluid can be investigated with either Lagrangian or Eulerian methods. Lagrangian description of fluid motion is based on the theory to follow a fluid particle which is large enough to detect properties. Initial coordinates at time t0

${t}_{0}$and coordinates of the same particle at time t1

${t}_{1}$have to be examined. To follow millions of separate particles through the path is almost impossible. In the Eulerian method, any specific particle across the path is not followed, instead, the velocity field as a function of time and position is examined. This missile example precisely fits to emphasize the methods.

Langarian: We take up every point at the beginning of the domain and trace its path till it reaches the end. Eulerian: We consider a window (Control Volume) within the fluid and analyse the particle flow within this Volume.

Lagrangian formulation of motion is always time-dependent. As a

$a$, b

$b$and c

$c$are the initial coordinates of a particle; x

$x$, y

$y$, and z

$z$are coordinates of the same particle at time t

$t$. Description of motion for Lagrangian:

x=x(a,b,c,t)y=y(a,b,c,t)z=z(a,b,c,t)(1)

$$\begin{array}{}\text{(1)}& x=x(a,b,c,t)\phantom{\rule{1em}{0ex}}y=y(a,b,c,t)\phantom{\rule{1em}{0ex}}z=z(a,b,c,t)\end{array}$$

In the Eulerian method, u

$u$, v

$v$and w

$w$are the components of velocity at the point (x,y,z)

$(x,y,z)$at the time t

$t$. Thus, u

$u$, v

$v$and w

$w$are the unknowns which are functions of the independent variables x,y,z

$x,y,z$and t

$t$. Description of motion for Eulerian for any particular value of t

$t$:

u=u(x,y,z,t)v=v(x,y,z,t)w=w(x,y,z,t)(2)

$$\begin{array}{}\text{(2)}& u=u(x,y,z,t)\phantom{\rule{1em}{0ex}}v=v(x,y,z,t)\phantom{\rule{1em}{0ex}}w=w(x,y,z,t)\end{array}$$

Conservation of Mass is specified as equation below:

DρDt+ρ(∇⋅v⃗ )=0(3)

$$\begin{array}{}\text{(3)}& \frac{D\rho}{Dt}+\rho (\mathrm{\nabla}\cdot \overrightarrow{v})=0\end{array}$$

where ρ

$\rho $is the density, v⃗

$\overrightarrow{v}$the velocity and ∇

$\mathrm{\nabla}$the gradient operator.

∇⃗ =i⃗ ∂∂x+j⃗ ∂∂y+k⃗ ∂∂z(4)

$$\begin{array}{}\text{(4)}& \overrightarrow{\mathrm{\nabla}}=\overrightarrow{i}\frac{\mathrm{\partial}}{\mathrm{\partial}x}+\overrightarrow{j}\frac{\mathrm{\partial}}{\mathrm{\partial}y}+\overrightarrow{k}\frac{\mathrm{\partial}}{\mathrm{\partial}z}\end{array}$$

If the density is constant, the flow is assumed to be incompressible and then continuity reduces it to:

DρDt=0→∇⋅v⃗ =∂u∂x+∂v∂y+∂w∂z=0(5)

$$\begin{array}{}\text{(5)}& \frac{D\rho}{Dt}=0\to \mathrm{\nabla}\cdot \overrightarrow{v}=\frac{\mathrm{\partial}u}{\mathrm{\partial}x}+\frac{\mathrm{\partial}v}{\mathrm{\partial}y}+\frac{\mathrm{\partial}w}{\mathrm{\partial}z}=0\end{array}$$

**Conservation of Momentum** which can be specified as Navier-Stokes Equation:

∂∂t(ρv⃗ )I+∇⋅(ρv⃗ v⃗ )II=−∇pIII+∇⋅(τ¯¯¯¯¯¯)IV+ρg⃗ V(6)

$$\begin{array}{}\text{(6)}& \stackrel{I}{\stackrel{\u23de}{\frac{\mathrm{\partial}}{\mathrm{\partial}t}(\rho \overrightarrow{v})}}+\stackrel{II}{\stackrel{\u23de}{\mathrm{\nabla}\cdot (\rho \overrightarrow{v}\overrightarrow{v})}}=\stackrel{III}{\stackrel{\u23de}{-\mathrm{\nabla}p}}+\stackrel{IV}{\stackrel{\u23de}{\mathrm{\nabla}\cdot \left(\overline{\overline{\tau}}\right)}}+\stackrel{V}{\stackrel{\u23de}{\rho \overrightarrow{g}}}\end{array}$$

where static pressure p

$p$, viscous stress tensor τ¯¯¯¯¯¯

$\overline{\overline{\tau}}$and gravitational force ρg⃗

$\rho \overrightarrow{g}$.

**I: Local change with time**

**II: Momentum convection**

**III: Surface force**

**IV: Diffusion term**

**V: Mass force**

Viscous stress tensor τ¯¯¯¯¯¯

$\overline{\overline{\tau}}$can be specified as below in accordance with Stoke’s Hypothesis:

τij=μ∂vi∂xj+∂vj∂xi−23(∇⋅v⃗ )δij(7)

$$\begin{array}{}\text{(7)}& {\tau}_{ij}=\mu \frac{\mathrm{\partial}{v}_{i}}{\mathrm{\partial}{x}_{j}}+\frac{\mathrm{\partial}{v}_{j}}{\mathrm{\partial}{x}_{i}}-\frac{2}{3}(\mathrm{\nabla}\cdot \overrightarrow{v}){\delta}_{ij}\end{array}$$

If the fluid is assumed to be of constant density (can’t be compressed), the equations are greatly simplified that viscosity coefficient μ

$\mu $is assumed constant. Therefore, many terms vanished through equation results in a much simpler Navier-Stokes Equation:

ρDv⃗ Dt=−∇p+μ∇2v⃗ +ρg⃗ (8)

$$\begin{array}{}\text{(8)}& \rho \frac{D\overrightarrow{v}}{Dt}=-\mathrm{\nabla}p+\mu {\mathrm{\nabla}}^{2}\overrightarrow{v}+\rho \overrightarrow{g}\end{array}$$

**Conservation of Energy** is the first law of thermodynamics which states that the sum of the work and heat added to the system will result in the increase of the energy in the system:

dEt=dQ+dW(9)

$$\begin{array}{}\text{(9)}& d{E}_{t}=dQ+dW\end{array}$$

where dQ

$dQ$is the heat added to the system, dW

$dW$is the work done on the system and dEt

$d{E}_{t}$is the increment in the total energy of the system. One of the common types of an energy equation is:

ρ⎡⎣⎢⎢⎢∂h∂tI+∇⋅(hv⃗ )II⎤⎦⎥⎥⎥=−∂p∂tIII+∇⋅(k∇T)IV+ϕV(10)

$$\begin{array}{}\text{(10)}& \rho \left[\stackrel{I}{\stackrel{\u23de}{\frac{\mathrm{\partial}h}{\mathrm{\partial}t}}}+\stackrel{II}{\stackrel{\u23de}{\mathrm{\nabla}\cdot (h\overrightarrow{v})}}\right]=\stackrel{III}{\stackrel{\u23de}{-\frac{\mathrm{\partial}p}{\mathrm{\partial}t}}}+\stackrel{IV}{\stackrel{\u23de}{\mathrm{\nabla}\cdot (k\mathrm{\nabla}T)}}+\stackrel{V}{\stackrel{\u23de}{\varphi}}\end{array}$$

**I: Local change with time** **II: Convective term** **III: Pressure work** **IV: Heat flux** **V: Source term**

The Mathematical model merely gives us interrelation between the transport parameters which are involved in the whole process, either directly or indirectly. Even though every single term in those equations has relative effect on the physical phenomenon, changes in parameters should be considered simultaneously through the numerical solution which comprises differential equations, vector and tensor notations. A PDE comprises more than one variable and their derivation which is specified with “∂

$\mathrm{\partial}$” instead of “d

$d$”. If the derivation of the equation is conducted with “d

$d$”, these equations are called as Ordinary Differential Equations (ODE) that contains a single variable and its derivation. The PDEs are implicated to transform the differential operator (∂

$\mathrm{\partial}$) into an algebraic operator in order to get a solution. Heat transfer, fluid dynamics, acoustic, electronics and quantum mechanics are the fields that PDEs are highly used to generate solutions.

**Example of ODE:**

d2xdt2=x→x(t)where T is the single variable(11)

$$\begin{array}{}\text{(11)}& \frac{{d}^{2}x}{d{t}^{2}}=x\to x(t)\phantom{\rule{1em}{0ex}}\text{where T is the single variable}\end{array}$$

**Example of PDE:**

∂f∂x+∂f∂y=5→f(x,y)where both x and y are the variables(12)

$$\begin{array}{}\text{(12)}& \frac{\mathrm{\partial}f}{\mathrm{\partial}x}+\frac{\mathrm{\partial}f}{\mathrm{\partial}y}=5\to f(x,y)\phantom{\rule{1em}{0ex}}\text{where both x and y are the variables}\end{array}$$

What is the significance of PDEs to seeking a solution on governing equations? To answer this question, we initially examine the basic structure of some PDEs as to create connotation. For instance:

∂2f∂x2+∂2f∂y2=0→f(x,y)→Laplace Equation(13)

$$\begin{array}{}\text{(13)}& \frac{{\mathrm{\partial}}^{2}f}{\mathrm{\partial}{x}^{2}}+\frac{{\mathrm{\partial}}^{2}f}{\mathrm{\partial}{y}^{2}}=0\to f(x,y)\to \text{Laplace Equation}\end{array}$$

Comparison between equation (5) and equation (13) specifies the Laplace part of the continuity equation. What is the next step? What does this Laplace analogy mean? To start solving these enormous equations, the next step comes through discretization to ignite the numerical solution process. The numerical solution is a discretization-based method used in order to obtain approximate solutions to complex problems which cannot be solved with analytic methods because of complexity and ambiguities. As seen in Figure 3, solution processes without discretization merely give you an analytic solution which is exact but simple. Moreover, the accuracy of the numerical solution highly depends on the quality of the discretization. Broadly used discretization methods might be specified such as finite difference, finite volume, finite element, spectral (element) methods and boundary element.

Multitasking is one of the plagues of the century that generally ends up with procrastination or failure. Therefore, having planned, segmented and sequenced tasks is much more appropriate to achieving goals: this has also been working for CFD. In order to conduct an analysis, the solution domain is split into multiple sub-domains which are called cells. The combination of these cells in the computational structure is named **mesh**.

The mesh as simplification of the domain is needed, because it is only possible to solve the mathematical model under the assumption of linearity. This means that we need to ensure that the behavior of the variables we want to solve for can assumed to be linear within each cell. This requirement also implies that a finer mesh (generated via mesh refinement steps) is needed for areas in the domain where the physical properties to be predicted are suspected to be highly volatile.

Errors based on mesh structure are an often encountered issue which results in the failure of the simulation.

This might happen because the mesh is too coarse and doesn’t cover all effects that happen in this single element one by one, but rather cover multiple effects that then change as the mesh gets finer. Therefore, a study of independency needs to be carried out. The accuracy of the solution enormously depends on the mesh structure. To conduct accurate solutions and obtaining reliable results, the analyst has to be extremely careful on the type of cell, the number of cell and the computation time. The optimization of those restrictions is defined as mesh convergence which might be sorted as below:

- Generate a mesh structure that has a quite low number of elements and carries out analysis. Before, assure that the mesh quality and coverage of CAD model is reasonable to examination.
- Regenerate mesh structures with a higher number of elements. Conduct analysis again. Compare results in accordance with properties of examined case. For instance, if a case is an examination of internal flow through a channel, pressure drop at critical regions might be used as comparison.
- Keep on ascending to a number of elements where results converge satisfactorily with previous one(s).

Therefore, errors, based on mesh structure, can be eliminated and optimum value for number of elements might virtually be achieved as to optimize calculation time and necessary computation resources. An illustration is shown in Figure 4 that looks into static pressure change at imaginary region X through increase in number of elements. According to Figure 4, around 1,000,000 elements would have been sufficient to conduct a reliable study.

Creating a sculpture requires a highly talented artist with the ability to imagine the final product from the beginning. Yet a sculpture can be, for example, a simple piece of rock in the beginning, but might become an exceptional artwork in the end. A completely gradual processing throughout carving is an important issue to obtain the desired unique shape. Keep in mind that in every single process, some of the elements, such as stone particles, leftovers, are thrown away from the object. CFD also has a similar structure that relies on gradual processing during the analysis. In regions that are highly critical to the simulation results (for example a spoiler on a Formula 1 car) the mesh is refined into smaller elements to make the simulation more accurate.

Convergence is a major issue for computational analysis. The movement of fluid has a non-linear mathematical model with various complex models such as turbulence, phase change and mass transfer. Apart from the analytical solution, the numerical solution goes through an iterative scheme where results are obtained by the reduction of errors among previous stages. The differences between the last two values specify the error. When the absolute error is descending, the reliability of the result increases, which means that the result converges towards a stable solution.

The criteria for convergence vary with the mathematical models such as turbulence, multi-phase, etc.

How do analysts decide when the solution is converged? Convergence should go on and on until a steady-state condition has been obtained, even if the aimed case is transient, which indicates results change through time. Convergence has to be realized for each time-step as if they all are a steady-state process. What are the criteria for convergence? The rate of accuracy (acceptable error), complexity of the case and calculation time have to be considered as major topics to carry out an optimal process. The residuals of equations, like stone leftovers, change over each iteration. As iterations get down to the threshold value, convergence is achieved. For a transient case, those processes have to be achieved for each of the time steps. Furthermore, convergence might be diversified as follows below:

- Can be accelerated by parameters as initial conditions, under-relaxation and Courant number.
- Doesn’t always have to be correct, yet solution can converge, preferred mathematical model and mesh would be incorrect or have ambiguities.
- Can be stabilized within several methods like reasonable mesh quality, mesh refinement, using discretization schemes first- to second-order.
- Ensure that solution should be repeatable if necessary as to refrain ambiguity.

Where there is fluid, there is CFD. Having mentioned before, the initial stage to conduct a CFD simulation is specifying an appropriate mathematical model of reality. Rapprochements and assumptions give direction through solution processes to examine the case in the computational domain. For instance, fluid flow over a sphere / cylinder is a repetitive issue that has been taught by the lecturer as an example in fluid courses. The same phenomenon is virtually available in the movement of clouds in the atmosphere which is indeed tremendous (as seen in figure 6).

If compressibility becomes a non-negligible factor, this type of analysis helps you to find solutions in a very robust and accurate way. One example would be a Large Eddy Simulation of flow around a cylinder.

Different turbulence models play a role in this type of analysis. A lot of computing power is required to solve turbulence simulations and its complex numerical models. The difficulty of turbulence is the simulation of changes over time. The entire domain where the simulation takes place needs to be recalculated after every time step.

The analysis of a ball valve is one possible application of a turbulent flow analysis.

Mass transport simulations include smoke propagation, passive scalar transport or gas distributions. To solve these kinds of simulations, OpenFOAM solvers are used.

Heat exchanger simulations are one possible application.

Computational Fluid Dynamics tools diversify in accordance with mathematical models, numerical methods, computational equipment and post-processing facilities. As a physical phenomenon could be modeled with completely different mathematical approaches, it would also be integrated with unlike numerical methods simultaneously. Thus, a conscious rapprochement is the essential factor on the path to developing CFD tools. There are several license-required commercial software solutions, though there are also open source projects available. One of the most used open-source solvers for CFD is OpenFOAM18

${}^{18}$.

OpenFOAM is also one of the solvers integrated within the SimScale simulation platform.

Computational Fluid Dynamics (CFD) is the branch of CAE that allows you to simulate fluid motion using numerical approaches. The cloud-based CFD software component of SimScale allows the analysis of a wide range of problems related to laminar and turbulent flows, incompressible and compressible fluids, multiphase flows and more. Those engineering problems are solved using multiple integrated numerical solvers and technologies.