Presenter
Professor Andrew Garrard MEng(hons) PhD CEng FIMechE PFHEA
Details
MAC118
8 August 2026
What we will learn today
By the end of this lecture you will be able to:
Outline how CFD developed into its current state of the art
Explain why and how CFD is used alongside experiment and theory
Describe the steps involved in simulating a fluid flow numerically
Relate broad CFD concepts to the applications in the tutorials
Introduction
CFD stands for
C - Computational
F - Fluid
D - Dynamics
Computational fluid dynamics (CFD) is a branch of both fluid mechanics and computational physics that uses numerical analysis and data structures to analyze and solve problems that involve flows.
From the 17th to the 19th century, fluid mechanics was split into two disciplines.
Early CFD
CFD arrives, and it is not well defined as either theory or experiment.
A third way
Three fields of fluid mechanics, of equal importance, each informing the others.
Driving and bottlenecking CFD progress
Moore's law. Via Wikimedia Commons.
Commercial computers
A Cray Y-MP. ~1988: ~2.5 GFLOPS, ~20 million USD, ~55 million now USD. NASA Goddard, via Wikimedia Commons.
A Dell Latitude D630. Core 2 Duo PC, ~2008: ~25 GFLOPS, ~1,000 USD, ~1,500 USD now. Via Wikimedia Commons.
Pushing boundaries in fluid mechanics
A Lockheed Martin hypersonic vehicle.
Pushing boundaries in fluid mechanics
A flow visualization of NASA’s X‑59 supersonic, low-boom aircraft concept. This computational fluid dynamics simulation, produced on the Pleiades supercomputer using the NAS-developed Launch Ascent and Vehicle Aerodynamics (LAVA) code, will be used to help determine which components contribute to the pressure signatures below the aircraft that create the sonic boom in flight. Red and blue represent high and low pressure, respectively; the symmetry plane—which bisects the vehicle along its center line—is colored by Mach number. James Jensen, NASA/Ames.
The JF-22 hypersonic wind tunnel at the Chinese Academy of Aerodynamics. Pandaily, https://pandaily.com/jf22-hypersonic-wind-tunnel-10km-jul2026, obtained 2026-09-11.
A couple of issues with wind tunnels
Power
The JF-22 uses 15 GW of power.
180 × Trent XWB engines.5 × Iron Men.
Scale
The JF-22 has a working section of 4 m.
Real planes are bigger than 4 m across.
$$Re = \frac{\rho V L}{\mu}$$
The run time is less than 120 ms.
Why use CFD?
Cheaper
Safer
Unphysical problems
Complete dataset
Data after experiment
Increasingly automated
But...
No exact solution
No idea if the answer is correct – "black box engineering"
Good for some situations, not for others - this requires some wisdom
Why I like CFD
I can work independently
Easy "what if" scenarios
Work from anywhere
Numerical experiment
CFD can be a portable, cheap wind tunnel.
Numerical experiment
Used to test a model, theory or hypothesis.
Fewer factors are outside your control than in a physical experiment, but not none.
Error will occur and has to be understood and accounted for.
Good experimental design needs to be performed before starting.
Experiments should adhere to the scientific method.
Focus should always be maintained on the reasons for conducting the experiment.
Something for everyone
The CFD stack: every answer rests on six layers the engineer never sees.
Some of my work
Simulation of a "personal cloud"
Prediction of smoke ingress and movement in offshore installations
GRP spraying of boat hulls
Electric motor cooling
Fuel cell electrochemical modelling
Cooling and windage loss in a switched reluctance motor.
Swirl in a fuel cell stack manifold.
Commercial software
In the recent past
Dedicated CFD platforms
Fluent
CFX
STAR-CD
COMSOL (general)
OpenFOAM (open source)
Now
Large multiphysics packages
Ansys (Synopsys)
Dassault Systèmes
CAD bolt-ons (not very good)
COMSOL (general)
OpenFOAM (open source)
At Sheffield we use Ansys Fluent.
Fluent started in Sheffield
Joe Scarborough's painting of Fluent Europe's Sheffield, commissioned in 2000.
Mass is conserved. The mass entering across the boundary minus the mass leaving across it is the mass accumulated inside.
Momentum is also conserved in the same way, but has a third route in: forces on the boundary.
Discretising
Typical CFD simulation workflow
The steps of running a CFD simulation.
The more holistic CFD simulation workflow
Running the simulation is one step of six in a CFD study.
The complete CFD simulation workflow
The whole simulation pipeline is one box in the study.
Geometry creation
This is basically CAD. But the fluid needs to be created, not (necessarily) the solid.
To predict drag, mesh the air surrounding the rocket. The rocket’s surface forms a boundary of the fluid domain.
Meshing
Meshing is the task of dividing the geometry into many small "elements".
A tetrahedral mesh around a sphere, with inflation layers at its surface.
The quality of the mesh has a dramatic impact on the results produced by the simulation.
Meshing is becoming an increasingly automated process.
Pre-processing
The mesh divides the fluid into cells. We now set up the calculation:
Which physics? Turbulence, heat transfer, chemical reactions.
Which fluid? Air, water, and its material properties.
What happens at the boundaries? Flow entering, flow leaving, solid walls.
How should the calculation run? Solution methods and solver settings.
Each of these decisions will have an impact on the result of the simulation.
The same mesh can be used for different calculations by changing these choices.
Solved by numerical methods
Some equations can be solved analytically.
Any question where the function of the unknown variable produces a known result can be solved numerically.
For example
$$x = \cos x$$
$$\cos x-x = 0$$
Use a "predictor-corrector" method.
$$r_n = \cos x_n - x_n$$
where $r_n$ is the residual.
Predictor-corrector
Start between $0$ and $1$; keep the half with a sign change. Angles are in radians.
Guess
Calculation
Residual
New guess
$0.5$
$\cos(0.5) - 0.5 =$
$+0.3776$
$0.75$
$0.75$
$\cos(0.75) - 0.75 =$
$-0.0183$
$0.625$
$0.625$
$\cos(0.625) - 0.625 =$
$+0.1860$
$0.6875$
$0.6875$
$\cos(0.6875) - 0.6875 =$
$+0.0853$
$0.71875$
$0.71875$
$\cos(0.71875) - 0.71875 =$
$+0.0339$
$0.734375$
$0.734375$
$\cos(0.734375) - 0.734375 =$
$+0.0079$
$0.742188$
$0.742188$
$\cos(0.742188) - 0.742188 =$
$-0.0052$
$0.738281$
$0.738281$
$\cos(0.738281) - 0.738281 =$
$+0.0013$
$0.740234$
For most practical flows, the Navier–Stokes equations have no known analytical solution, so we solve them approximately using numerical methods.
Residuals
Residuals fall as the solver iterates, then level off at different magnitudes.
Post-processing
What you think a valuable result from CFD is
Pictures: streamlines and surface colouring for flow past a sphere.
What an actually valuable result from CFD is
Numbers: Fluent's force report, with the total drag on the sphere circled.
Validation
Validation checks whether the simulation gives the right answer.
But what does “right” mean?
The answer predicts what would happen if the simulated conditions existed in the real world.
Simulations consist of assumptions, estimations, decisions (Mesh, models, physics and numerics) which all influence the answer.
The simulation will merrily and convincingly generate you an answer.
Just like analytical calculations, web searches, AI output, you need to check what is being produced is correct.
A convincing answer still needs validation.
You are liable.
THE ENTIRE RISK ARISING OUT OF THEIR USE REMAINS WITH THE RECIPIENT. IN NO EVENT SHALL ANSYS AND/OR ITS RESPECTIVE SUPPLIERS BE LIABLE FOR ANY DIRECT, CONSEQUENTIAL, INCIDENTAL, SPECIAL, PUNITIVE OR OTHER DAMAGES WHATSOEVER (INCLUDING WITHOUT LIMITATION, DAMAGES FOR LOSS OF BUSINESS PROFITS, BUSINESS INTERRUPTION, OR LOSS OF BUSINESS INFORMATION), EVEN IF ANSYS HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES.