# Introduction to Computational Fluid Dynamics

Document Sample

```					Introduction to Computational
Fluid Dynamics
Course Notes (CFD 4)

Karthik Duraisamy
Department of Aerospace Engineering
University of Glasgow
Contents
• Introduction (1.5)
• Classification of PDE, Model equations (1.5)
• Finite difference methods:
 Spatial discretization (3)
 Temporal discretization (2)
 Convergence, Consistency, Stability (2)
• Grids/Boundary conditions (1)
• Euler equations (1)
• RANS Equations and Turbulence modeling (2)
• DNS/LES (1)
• Best practices in CFD (1)
• Case studies/Demonstrations (3)

(.) – Approximate number of lectures
Grids
Introduction
• Solution of PDEs require spatial and temporal discretization
• Typically, the spatially-discretized domain is called the grid
• The PDE (originally on a continuous domain) is solved on a discrete
set of grid points
• Typically, the PDE is reduced to a set of algebraic equations (that
might or might not involve matrix inversion)
• Types of grids:
 Structured grid
 Unstructured grid
 Hybrid grids
Examples

Structured grid              Unstructured grid
Structured grids
• Can be Cartesian or curvilinear
• Cartesian grids cannot be used for complex geometries and hence,
body-fitted curvilinear grids are used
• Curvilinear grids: Equations need to be transformed from physical
(x,y,z) space to computational (ξ,η,ζ) space
• Need boundary conditions on each of the “boundaries”
• Elements are usually quadrilaterals / hexahedra
• Example of airfoil grid / boundary conditions
• Since we are Aerospace Engineers, we might be interested in airfoil
grids – C grid, O grid,
• Block structured grid
• Chimera grid [ease of mesh generation, relative motion]
• Good structured grids are orthogonal and smooth.
C-O Mesh for wing
Block structured grid

Courtesy, Pointwise Inc.
Chimera Grid
Chimera grids
Chimera Grid
Overset Grid Solution
Compute solution in interior points and apply BCs
1. Determine chimera points (C1) of inner grid
2. Find donor cells (D2) in outer grid that contain C1
3. Interpolate from D2 to C1
4. Find a water tight chain of points (C2) in the outer grid enclosing the
solid surface in the inner grid.
5.    „Blank out‟ points in outer grid that lie inside the boundary formed
by connecting C2. These are hole point (H2) and wont be solved
for
6.    Just as in step 2, find donor cells (D1) in inner grid that contain C2
7.    Interpolate from D1 to C2.
Unstructured grids
• Unlike structured grid, do not have definite data structure
• Elements are usually triangular/tetrahedral
• Gives a lot of flexibility in mesh generation (multi-blocking not
• Unstructured solvers are more expensive than structured solvers and
getting high order of accuracy is more difficult.
• Equations are solved in integral form (so no derivatives are required)
Unstructured grid

Courtesy, MetaComp Tech
Unstructured grid

Courtesy, MetaComp Tech
• Accuracy goes as (dx)^n. Therefore, to get higher accuracy, either
reduce dx or increase n. usually, it is hard to get very high order
accurate methods to work properly (convergence, stability, software
issues). Therefore, dx is reduced. This is called mesh adaptation.
• Mesh adaptation is either done visually, or by identifying a variable in
the solution. Example, shear layer  good idea might be to track
vorticity.
Transonic flow over Onera M6 wing

Grid generation methods
• Structured Grids:
 Conformal mapping [complex variable transformations,
restricted to 2D]
 Algebraic [polynomials, trigonometric functions]
 PDE Methods:
 Step 1: Determine the grid point distribution on the
boundaries of the physical space.
 Step 2:Assume the interior grid point is specified by a
differential equation that satisfies the grid point distributions specified
on the boundaries and yields an acceptable interior grid point
distribution.
• Unstructured grids
 Octree
 Delaunay