Professional Documents
Culture Documents
Rimon Arieli
Faculty of Aerospace Engineering TECHNION Israel Institute of Technology Haifa, , Israel 32000
Outline
1. 1 2. 3. 4. 5. What, What why and where of CFD? Modeling Numerical methods Types yp of CFD codes CFD Process
Spring 2009
AE-086376
What is CFD?
CFD is the simulation of fluids engineering systems using modeling (mathematical physical problem formulation) and numerical methods (discretization methods, solvers, numerical parameters and grid generations, parameters, generations etc.) etc ) Historically only Analytical Fluid Dynamics (AFD) and Experimental Fluid Dynamics (EFD). CFD made possible by the advent of digital computer and advancing with improvements of computer resources (500 flops, 194720 teraflops, 2003)
Spring 2009
AE-086376
Spring 2009
AE-086376
Biomedical
F18 Store Separation
Temperature and natural convection ti currents t in i the th eye following laser heating.
Spring 2009
AE-086376
Chemical Processing
Hydraulics
Spring 2009
AE-086376
Spring 2009
AE-086376
Modeling
Modeling is the mathematical physics problem formulation
in terms of a continuous initial boundary value problem (IBVP) IBVP is in the form of Partial Differential Equations (PDEs) with appropriate boundary conditions and initial conditions. Modeling includes: 1. Geometry and domain 2 Coordinates 2. 3. Governing equations 4. Flow conditions 5. Initial and boundary conditions 6. Selection of models for different applications
Spring 2009
AE-086376
Spring 2009
AE-086376
Modeling (coordinates)
z Cartesian (x,y,z) z Cylindrical (r,,z) z y x x r y x r y z Spherical (r,,)
Spring 2009
2w 2w 2w w w w w p + u + v + w = + 2 + 2 + 2 y z z y z t x x
Local acceleration
Convection
Viscous terms
( u ) ( v ) ( w ) + + + = 0 Continuity equation t x y z
p = RT
Equation of state
Spring 2009
AE-086376
11
convergence path, i.e. number of iterations (steady) or time steps p (unsteady) ( y) need to reach converged g solutions. More reasonable g guess can speed p up p the convergence ??? For complicated unsteady flow problems, CFD codes are usually run in the steady mode for a few iterations for getting a better initial conditions
Spring 2009
AE-086376
12
v=0, dp/dr=0,du/dr=0
Axisymmetric
Spring 2009 AE-086376 13
different categories using different criteria, and designed for solving certain fluid phenomenon by applying different models:
(Re)
Turbulent vs. laminar (Re, Turbulent models) Incompressible vs. compressible (M, equation of state) Single- vs. multi-phase (Ca, cavitation model, two-fluid model) Thermal/density effects and energy equation
(Pr, , Gr, Ec, conservation of energy)
Turbulent models:
DNS: most accurately solve NS equations, but too expensive for turbulent flows RANS: predict mean flow structures, efficient inside BL but excessive diffusion in
the separated p region. g
Spring 2009
AE-086376
15
Spring 2009
AE-086376
16
Numerical methods
The continuous Initial Boundary Value Problems (IBVPs)
are discretized di i d into i algebraic l b i equations i using i numerical i l methods. Assemble the system of algebraic equations and solve the system to get approximate solutions Numerical methods include:
1. 1 2. 3. 4. Discretization methods Solvers and numerical parameters Grid generation and transformation High Performance Computation (HPC) and post-processing
Spring 2009
AE-086376
17
Discretization methods
Finite difference methods (straightforward to apply, usually for regular
grid) Finite volumes and finite element methods ( (usually y for irregular g meshes) Each type of methods above yields the same solution if the grid is fine enough. However, some methods are more suitable to some cases than others Finite difference methods for spatial derivatives with different order of accuracies can be derived using Taylor expansions, such as 2nd order upwind scheme, central differences schemes, etc. Higher order numerical methods usually predict higher order of accuracy for CFD, but more likely unstable due to less numerical dissipation Temporal derivatives can be integrated either by the
explicit method (Euler, Runge-Kutta, etc.) or implicit method (e.g. Beam-Warming method)
Spring 2009
AE-086376
18
u v =0 + x y
(L-1,m)
(L,m)
u u p 2u +v = + 2 u x e x y y
l u um l l 1 u u u = m m x x
(L,m-1)
L-1
2u l l l 2= 2 u u u 2 + m m m + 1 1 y y
l FD Sign( vm )<0
l u vm l l = v u u m +1 m y y l vm l l = u u m m 1 y
BD Sign( v l )>0 m
st
20
l l l l 1 B1um + B u + B u = B u 1 2 m 3 m +1 4 m
B2 B 1 0 0
B3 B2 0 0
0 B3 0 0
0 0 0 0
0 0 0 0
0 0 B1 0
0 0 B2 B1
l p / e ( )m x
l um l 1 = um ( p / e)lm x x
B4
AE-086376
21
Spring 2009
AE-086376
22
unstructured
Spring 2009
23
Transform
o Physical domain
o Computational domain
f f f f f = + = x + x x x x
f f f f f = + = y +y y y y
and computational ( , , ) domains, domains important for body-fitted grids. The partial derivatives at these two domains have the relationship p (2D ( as an example) p )
Spring 2009
AE-086376
24
CFDSHIPIOWA
Spring 2009 AE-086376 25
CFD Process
Purposes of CFD codes will be different for different applications:
investigation of bubble-fluid interactions for bubbly flows, study of wave induced massively separated flows for free-surface, free surface, etc. Depend on the specific purpose and flow conditions of the problem, different CFD codes can be chosen for different applications (aerospace, marines, combustion, multi-phase flows, etc.) Once purposes and CFD codes chosen, CFD process is the steps to set up the IBVP problem and run the code: y 1. Geometry 2. Physics 3. Mesh 4 Solve 4. 5. Reports 6. Post processing
Spring 2009
AE-086376
26
CFD Process
Geometry Physics Mesh Solve Reports PostProcessing
Contours Select Geometry Heat Transfer ON/OFF Unstructured (automatic/ manual) Steady/ Unsteady Forces Report
(lift/drag, shear stress, etc)
Geometry Parameters
Compressible ON/OFF
Iterations/ Steps
XY Plot
Vectors
Flow properties
Convergent Limit
Verification
Streamlines
Viscous Model
Validation
Boundary Conditions
Numerical Scheme
Initial Conditions
Spring 2009
AE-086376
27
Geometry
Selection of an appropriate coordinate Determine the domain size and shape Any simplifications needed? What kinds of shapes p needed to be used to best resolve the geometry? (lines, circular, ovals, etc.) For commercial code, geometry is usually created using i commercial i l software ft (either ( ith separated t d from f the commercial code itself, like Gambit, or combined together, like FlowLab) For research code, commercial software (e.g. Gridgen) is used.
Spring 2009 AE-086376 28
Physics
Flow conditions and fluid properties
1. Flow conditions: inviscid, viscous, laminar, or turbulent, etc. 2. Fluid properties: density, viscosity, and thermal conductivity, y, etc. 3. Flow conditions and properties usually presented in dimensional form in industrial commercial CFD software, , whereas in non-dimensional variables for research codes. Selection of models: different models usually fixed by codes, opt options o s for o use user to c choose oose Initial and Boundary Conditions: not fixed by codes, user needs specify them for different applications.
AE-086376 29
Spring 2009
Mesh
Meshes should be well designed to resolve important
flow features which are dependent upon flow condition parameters (e.g., Re), such as the grid refinement inside the wall boundary layer Mesh h can be b generated d by b either h commercial l codes d (Gridgen, Gambit, etc.) or research code (using algebraic vs vs. PDE based based, conformal mapping mapping, etc.) etc ) The mesh, together with the boundary conditions need to be exported p from commercial software in a certain format that can be recognized by the research CFD code or other commercial CFD software software.
Spring 2009 AE-086376 30
Solve
Setup appropriate numerical parameters Choose Ch appropriate i Solvers S l Solution procedure (e.g. incompressible flows) S l the Solve th momentum, t pressure P Poisson i equations and get flow field quantities, such as velocity turbulence intensity velocity, intensity, pressure and integral quantities (lift, drag forces)
Spring 2009
AE-086376
31
Reports
Reports saved the time history of the residuals
of the velocity, pressure and temperature, etc. Report the integral quantities, such as total pressure drop, friction factor (pipe flow), lift and drag coefficients (airfoil flow), flow) etc etc. XY plots could present the centerline velocity/pressure distribution, friction factor distribution (pipe flow), flow) pressure coefficient distribution (airfoil flow). AFD or EFD data can be imported p and put p on top of the XY plots for validation
Spring 2009
AE-086376
32
Post-processing
Analysis and visualization
Vorticity Wall
Spring 2009
AE-086376
33
Spring 2009
AE-086376
34
Grid refinement ratio: uniform ratio of grid spacing between meshes meshes.
Spring 2009
AE-086376
35
(a)
UI =
1 ( SU S L ) 2
Iteration i history: hi (a). ( ) Solution l i change h (b) magnified ifi d view i of f total l resistance i over last l two periods of oscillation (Oscillatory iterative convergence)
Spring 2009 AE-086376 36
Spring 2009
AE-086376
37
Grid need to be refined near the foil surface f to resolve l the h boundary b d layer l
Spring 2009 AE-086376 38
Spring 2009
AE-086376
39
Spring 2009
AE-086376
40
Spring 2009
AE-086376
41