Sunteți pe pagina 1din 26

Introduction to Computational

Fluid Dynamics
Course Notes
Venkatesh Ramakrishnan, M.E,
Assistant Professor-Thermal, Fluids & Energy
Science Stream,
Department of Mechanical Engineering
Sandwich,
PSG College Of
Technology,Peelamedu,Coimbatore641004. Tamilnadu, India.

What is CFD/FD ?
CFD is a branch of Fluid dynamics
So what really is Engineering Fluid Dynamics in the first place? Lets
look at some examples:
We are interested in the forces (pressure , viscous stress
etc.) acting on surfaces (Example: In an airplane, we are interested
in the lift, drag, power, pressure distribution etc)
We would like to determine the velocity field (Example: In a
race car, we are interested in the local flow streamlines, so that we
can design for less drag)
We are interested in knowing the temperature distribution
(Example: Heat transfer in the vicinity of a computer chip)
Roughly put, in Engineering fluid dynamics, we would like to
determine certain flow properties in a certain region of interest, so
that the information can be used to predict the behaviour of
systems, to design more efficient systems etc..

Fluid Dynamics

Theoretical
Most important branch of fluid dynamics. Crucial in
understanding concepts (Example: L = U), Usually good in
predicting trends (Example: ~ Re-1/2)
Can obtain a lot of information using simplifying assumptions,
sometimes enough for detailed design (Example: the SR-71
Blackbird was designed completely using theoretical ideas)
However, doesnt always provide sufficient information
Experimental
Only way to obtain reliable data in many situations. However,
costly, difficult to achieve exact conditions, difficult to isolate effects,
sometimes difficult to assess error, sometimes not repeatable
Computational (CFD)
Becoming important as computers are getting faster and
cheaper. Potential to provide tremendous amount of data at a
fraction of the cost of experiments. But sometimes unreliable
because of numerical/modeling/human errors. Sometimes more
expensive than experiments
Very important to validate with theory/experiments

Sample Application 1
[Simulation to understand physics]
Flow over F-16 at
45o angle of
attack
Surface Pressure
contours and
streamtraces
Courtesy: Kyle
Squires, ASU

Sample Application -2
[Validation with Experiment]

Experiment

Computation

Flow over fixed wing Expt. vs CFD of velocity contours

Sample Application -3
[Simulation to aid theoretical understanding]
Merger of co-rotating
vortices due to
Elliptical instability
(Movie)
Courtesy: CERFACS

Procedures in CFD
Identification of right approximation (Viscous/Inviscid,
Laminar/Turbulent, Incompressible / compressible, Singlephase/multi-phase)
Identification of right solution method (Finite Element /
Difference/Volume, Structured/Unstructured mesh, Order of accuracy)
Pre-processing (Generate computational grid, assign boundary
conditions, set initial conditions, compile code, prepare input
parameters)
Solution (Run the code, monitor the solution)
Post-processing (Collect and organize data, analyze results)
Verification (Do the results make sense? Are the trends right? Does it
agree with previous calculations on similar configurations?)
Validation (Does the result (or an aspect of the result)) agree with
theory/experiment?)
At every step, good understanding of theoretical fluid dynamics is
essential!!!

Example: Flow over a pitching


airfoil
Problem: Predict the loads acting on an airfoil pitching in a wind
tunnel under the following conditions: =10o + 10o sin(w t), Re =
3.8x106, M = 0.3, w = 0.06
Identification of right approximation : Viscous, Turbulent,
compressible, Single-phase
Identification of right solution method (Finite Volume, Structured
mesh, second order accurate)

Governing Equations of fluid


dynamics
Assumptions: Continuum flow, Newtonian fluid
Lets restrict ourselves to single phase, single species, perfect gases
(this way, incompressible flow is a special case)
Ignore body forces
Unknowns: Density (), Velocity (u,v,w), Pressure (p)
Dynamics of fluids is then given by
Conservation of Mass (Continuity equation) [Law of common
sense]
Conservation of Momentum (Navier-Stokes equations)
[Newtons second law]
Conservation of Energy (Energy equation) [First law of
thermodynamics]
5 equations to determine 5 unknowns.
All of fluid dynamics is contained in these equations

Governing equations
How to derive these equations?
Integral form
Differential form
Reynolds transport theorem:
Rate of change of stuff inside a control volume = Net flux of stuff
entering/leaving the boundaries + generation of stuff destruction
of stuff
In addition, need some more info (such as stress-strain relation,
temperature-heat flux relation etc.)

The stuff U is nothing but mass,


momentum and energy

Applications

Aerospace
Automobile and Engine Applications
Appliances
Boats
Computers

How Does a CFD Code Work?


CFD codes are structured around the
numerical algorithms that can tackle fluid
flow problems
Three main elements:

1.Pre Processor
2.Solver
3.Post Processor

1) Pre-Processor
Consists of the input
of
a flow problem to CFD
User Activities:
define geometry &
generate grid (50%
time)
selection of
phenomena to be
modeled
definition of fluid
properties

2) Solver
Three primary numerical solution techniques
finite difference, finite element, finite control volume

The numerical method performs the following:


Approximates the unknown variables by simple functions
Discretization by substitution of the approx-imations into
the governing flow equations and subsequent
mathematical manipulations
Solution of the algebraic equations

Solver - Finite Difference Method


Finite difference methods describe the unknowns of the
flow problems by means of point samples at the node
points of a grid co-ordinate lines

Truncated Taylor series expan-sions are


used to generate finite difference
approximations of the derivatives of in terms
of point samples of at each grid point and its
immediate neighbors

Solver - Finite Volume Method


Based on control volume formulation of analytical fluids
The domain is divided into a number of control volumes
(aka cells, elements) - the variable of interest is located at
the centroid of the control volume.
The differential form of the governing equations are
integrated over each control volume.
Finite difference approximations are substituted for the terms
in the integrated equations (discretization) converts the
integral equations into a system of algebraic equations.
Set of algebraic equations are solved by an iterative
method.

3) Post Processor
Provides a user friendly (??) way to look at
the results of a simulation
Domain geometry and grid display
Vector Plots
Contour Plots
Particle Tracking

Problem Solving With CFD


Results of CFD are at best as good as the physics
embedded in it as at worst as good a its operator
THESE PROBLEMS ARE COMPLEX
Prior to running a simulation there is a stage of identification
and formulation of the flow problem in terms of the physical
and chemical phenomena that need to be considered.
A successful simulation has
converged solution
grid independence

Applications of CFD
Applications of CFD are numerous!
Flow and heat transfer in industrial processes (boilers, heat
exchangers, combustion equipment, pumps, blowers, piping,
etc.).
Aerodynamics of ground vehicles, aircraft, missiles.
Film coating, thermoforming in material processing
applications.
Flow and heat transfer in propulsion and power generation
systems.
Ventilation, heating, and cooling flows in buildings.
Chemical vapor deposition (CVD) for integrated circuit
manufacturing.
Heat transfer for electronics packaging applications.
And many, many more!

Advantages of CFD
Relatively low cost.

Using physical experiments and


tests to get essential engineering
data for design can be expensive.
CFD simulations are relatively
inexpensive, and costs are likely to
decrease as computers become more
powerful.

Advantages of CFD
Speed.
CFD simulations can be executed in a short period of
time.
Quick turnaround means engineering data can be
introduced early in
the design process.
Ability to simulate real conditions.
Many flow and heat transfer processes can not be
(easily) tested,
e.g. hypersonic flow.
CFD provides the ability to theoretically simulate any
physical condition.

Advantages of CFD
Ability to simulate ideal conditions.

CFD allows great control over the physical


process, and provides the
ability to isolate specific phenomena for study.
Example: a heat transfer process can be
idealized with adiabatic,
constant heat flux, or constant temperature
boundaries.
region of interest, and yields a comprehensive
set of flow parameters for examination.

Advantages of CFD
Comprehensive information.
Experiments only permit data to be
extracted at a limited number of
locations in the system (e.g. pressure and
temperature probes, heat
flux gauges, LDV, etc.).
CFD allows the analyst to examine a
large number of locations in the

Limitations of CFD
Physical models.
CFD solutions rely upon physical models of real world
processes
(e.g. turbulence, compressibility, chemistry, multiphase flow,
etc.).
The CFD solutions can only be as accurate as the physical
models
on which they are based.
Numerical errors.
Solving equations on a computer invariably introduces
numerical

Limitations of CFD
ERRORS.
Round-off error: due to finite word size
available on the computer.
Round-off errors will always exist (though
they can be small in most cases).
Truncation error: due to approximations
in the numerical models.
Truncation errors will go to zero as the
grid is refined. Mesh
refinement is one way to deal with
truncation error.

Limitations of CFD
Boundary conditions.
As with physical models, the accuracy of the CFD
solution is only as
good as the initial/boundary conditions provided to the
numerical model.
Example: flow in a duct with sudden expansion. If flow
is supplied to
domain by a pipe, you should use a fully-developed
profile for
velocity rather than assume uniform conditions.

S-ar putea să vă placă și