Computational fluid dynamics

From Wikipedia, the free encyclopedia

A computer simulation of high velocity air flow around the Space Shuttle during re-entry.
Enlarge
A computer simulation of high velocity air flow around the Space Shuttle during re-entry.

Computational Fluid Dynamics (CFD) is one of the branches of fluid mechanics that uses numerical methods and algorithms to solve and analyze problems that involve fluid flows. Computers are used to perform the millions of calculations required to simulate the interaction of fluids and gases with the complex surfaces used in engineering. However, even with simplified equations and high speed supercomputers, only approximate solutions can be achieved in many cases. More accurate codes that can accurately and quickly simulate even complex scenarios such as supersonic or turbulent flows are an ongoing area of research.

Contents

[edit] Background and history

A simulation of the Hyper-X scramjet vehicle in operation at Mach-7
Enlarge
A simulation of the Hyper-X scramjet vehicle in operation at Mach-7

The fundamental basis of any CFD problem is the Navier-Stokes equations, which define any single-phase fluid flow. These equations can be simplified by removing terms describing viscosity to yield the Euler equations. Further simplification, by removing terms describing vorticity yields the Full Potential equations. Finally, these equations can be linearized to yield the Linearized Potential equations.

Historically, methods were first developed to solve the Linearized Potential equations. Two-dimensional methods, using conformal transformations of the flow about a cylinder to the flow about an airfoil were developed in the 1930s. The computer power available paced development of three-dimensional methods. The first paper on a practical three-dimensional method to solve the Linearized Potential equations was published by John Hess and A.M.O. Smith of Douglas Aircraft in 1966. This method discretized the surface of the geometry with panels, giving rise to this class of programs being called Panel Methods. Their method itself was simplified, in that it did not include lifting flows and hence was mainly applied to ship hulls and aircraft fuselages. The first lifting Panel Code (A230) was described in a paper written by Paul Rubbert and Gary Saaris of Boeing Aircraft in 1968. In time, more advanced three-dimensional Panel Codes were developed at Boeing (PANAIR, A502), Lockheed (Quadpan), Douglas (HESS), McDonnell Aircraft (MACAERO), NASA (PMARC) and Analytical Methods (WBAERO, USAERO and VSAERO). Some (PANAIR, HESS and MACAERO) were higher order codes, using higher order distributions of surface singularities, while others (Quadpan, PMARC, USAERO and VSAERO) used single singularities on each surface panel. The advantage of the lower order codes was that they ran much faster on the computers of the time. Today, VSAERO has grown to be a multi-order code and is the most widely used program of this class. This program has been used in the development of many submarines, surface ships, automobiles, helicopters and aircraft. Its sister code, USAERO is an unsteady panel method that has also been used for modeling such things as high speed trains and racing yachts. The NASA PMARC code was developed from an early version of VSAERO and a derivative of PMARC, named CMARC, is also commercially available.

In the two-dimensional realm, quite a number of Panel Codes have been developed for airfoil analysis and design. These codes typically have a boundary layer analysis included, so that viscous effects can be modeled. Professor Richard Eppler of the University of Stuttgart developed the PROFIL code, partly with NASA funding, which became available in the early 1980s. This was soon followed by MIT Professor Mark Drela's Xfoil code. Both PROFIL and Xfoil incorporate two-dimensional panel codes, with coupled boundary layer codes for airfoil analysis work. PROFIL uses a conformal transformation method for inverse airfoil design, while Xfoil has both a conformal transformation and a inverse panel method for airfoil design. Both codes are widely used.

An intermediate step between Panel Codes and Full Potential codes were codes that used the Transonic Small Disturbance equations. In particular, the three-dimensional WIBCO code, developed by Charlie Boppe of Grumman Aircraft in the early 1980s has seen heavy use.

Developers next turned to Full Potential codes, as panel methods could not calculate the non-linear flow present at transonic speeds. The first description of a means of using the Full Potential equations was published by Earll Murman and Julian Cole of Boeing in 1970. Frances Bauer, Paul Garabedian and David Korn of the Courant Institute at New York University (NYU) wrote a series of two-dimensional Full Potential airfoil codes that were widely used, the most important being named Program H. A further growth of Progam H was developed by Bob Melnik and his group at Grumman Aerospace as Grumfoil. Antony Jameson, originally at Grumman Aircraft and the Courant Institute of NYU, worked with David Caughey to develop the important three-dimensional Full Potential code FLO22 in 1975. Many Full Potential codes emerged after this, culminating in Boeing's Tranair (A633) code, which still sees heavy use.

The next step was the Euler equations, which promised to provide more accurate solutions of transonic flows. The methodology used by Jameson in his three-dimensional FLO57 code (1981) was used by others to produce such programs as Lockheed's TEAM program and IAI/Analytical Methods' MGAERO program. MGAERO is unique in being a structured cartesian mesh code, while most other such codes use structured body-fitted grids (with the exception of NASA's TIGER/CART3D code, Lockheed's SPLITFLOW code and Georgia Tech's NASCART-GT, which is in fact a Navier-Stokes solver). Antony Jameson also developed the three-dimensional AIRPLANE code (1985) which made use of unstructured tetrahedral grids.

In the two-dimensional realm, Mark Drela and Michael Giles, then graduate students at MIT, developed the ISES Euler program (actually a suite of programs) for airfoil design and analysis. This code first became available in 1986 and has been further developed to design, analyze and optimize single or multi-element airfoils, as the MSES program. MSES sees wide use throughout the world. A derivative of MSES, for the design and analysis of airfoils in a cascade, is MISES, developed by Harold "Guppy" Youngren while he was a graduate student at MIT.

The Navier-Stokes equations were the ultimate target of developers. Two-dimensional codes, such as NASA Ames' ARC2D code first emerged. A number of three-dimensional codes were developed, leading to numerous commercial packages.

[edit] Technicalities

The most fundamental consideration in CFD is how one treats a continuous fluid in a discretized fashion on a computer. One method is to discretize the spatial domain into small cells to form a volume mesh or grid, and then apply a suitable algorithm to solve the equations of motion (Euler equations for inviscid, and Navier-Stokes equations for viscous flow). In addition, such a mesh can be either irregular (for instance consisting of triangles in 2D, or pyramidal solids in 3D) or regular; the distinguishing characteristic of the former is that each cell must be stored separately in memory. Where shocks or discontinuities are present, high resolution, total variation diminishing numerical schemes are needed to avoid spurious oscillations in the solution. Lastly, if the problem is highly dynamic and occupies a wide range of scales, tcally modified in time, as in adaptive mesh refinement methods.

If one chooses not to proceed with a mesh-based method, a number of alternatives exist, notably :

It is possible to directly solve the Navier-Stokes equations for laminar flow cases and for turbulent flows when all of the relevant length scales can be contained on the grid (a Direct numerical simulation). In general however, the range of length scales appropriate to the problem is larger than even today's massively parallel computers can model. In these cases, turbulent flow simulations require the introduction of a turbulence model. Large eddy simulations and the RANS formulation (Reynolds-averaged Navier-Stokes equations), with the k-ε model or the Reynolds stress model, are two techniques for dealing with these scales.

In many instances, other equations (mostly convective-diffusion equations) are solved simultaneously with the Navier-Stokes equations. These other equations can include those describing species concentration, chemical reactions, heat transfer, etc. More advanced codes allow the simulation of more complex cases involving multi-phase flows (eg, liquid/gas, solid/gas, liquid/solid) or non-Newtonian fluids (such as blood).

[edit] Methodology

In all of these approaches the same basic procedure is followed.

  1. The geometry (physical bounds) of the problem is defined.
  2. The volume occupied by the fluid is divided into discrete cells (the mesh).
  3. The physical modelling is defined - for example, the equations of motions + enthalpy + species conservation
  4. Boundary conditions are defined. This involves specifying the fluid behaviour and properties at the boundaries of the problem. For transient problems, the initial conditions are also defined.
  5. The equations are solved iteratively as a steady-state or transient.
  6. Analysis and visualization of the resulting solution.

[edit] Discretization methods

The stability of the chosen discretization is generally established numerically rather than analytically as with simple linear problems. Special care must also be taken to ensure that the discretization handles discontinuous solutions gracefully. The Euler equations and Navier-Stokes equations both admit shocks, and contact surfaces.

Some of the discretization methods being used are:

  • Finite volume method. This is the "classical" or standard approach used most often in commercial software and research codes. The governing equations are solved on discrete control volumes. This integral approach yields a method that is inherently conservative (i.e., quantities such as density remain physically meaningful):
\frac{\partial}{\partial t}\iiint Q dV + \iint F d\mathbf{A} = 0,
Where Q is the vector of conserved variables, F is the vector of fluxes (see Euler equations or Navier-Stokes equations), V is the cell volume, and \mathbf{A} is the cell surface area.
  • Finite element method. This method is popular for structural analysis of solids, but is also applicable to fluids. The FEM formulation requires, however, special care to ensure a conservative solution. The FEM formulation has been adapted for use with the Navier-Stokes equations. In this method, a weighted residual equation is formed:
R_i = \iiint W_iQdV^e
Where Ri is the equation residual at an element vertex i , Q is the conservation equation expressed on an element basis, Wi is the weight factor and Ve is the volume of the element.


  • Finite difference method. This method has historical importance and is simple to program. It is currently only used in few specialized codes. Modern finite difference codes make use of an embedded boundary for handling complex geometries making these codes highly efficient and accurate. Other ways to handle geometries are using overlapping-grids, where the solution is interpolated across each grid.
\frac{\partial Q}{\partial t}+ \frac{\partial F}{\partial x}+ \frac{\partial G}{\partial y}+ \frac{\partial H}{\partial z}=0
Where Q is the vector of conserved variables, and F, G, and H are the fluxes in the x, y, and z directions respectively.
  • Boundary element method. The boundary occupied by the fluid is divided into surface mesh.
  • High resolution schemes are used where shocks or discontinuities are present. To capture sharp changes in the solution requires the use of second or higher order numerical schemes that do not introduce spurious oscillations. This usually necesitates the application of flux limiters to ensure that the solution is total variation diminishing.

[edit] Turbulence models

[edit] Direct numerical simulation

Direct numerical simulation (DNS) captures all of the relevant scales of turbulent motion, so no model is needed for the smallest scales. This approach is extremely expensive, if not intractable, for complex problems on modern computing machines, hence the need for models to represent the smallest scales of fluid motion.

[edit] Reynolds-averaged Navier-Stokes

Reynolds-averaged Navier-Stokes equations (RANS) is the oldest approach to turbulence modeling. An ensemble version of the governing equations is solved, which introduces new apparent stresses known as Reynolds stress. This adds a second order tensor of unknowns for which various models can provide different levels of closure. It is a common misconception that the RANS equations do not apply to flows with a time-varying mean flow because these equations are 'time-averaged'. In fact, statistically unsteady (or non-stationary) flows can equally be treated. This is sometimes referred to as URANS. There is nothing inherent in Reynolds averaging to preclude this, but the turbulence models used to close the equations are valid only as long as the time over which these changes in the mean occur is large compared to the time scales of the turbulent motion containing most of the energy.

RANS models can be divided into two broad approaches:

Bousinesq Hypothesis: This method involves using an algebraic equation for the Reynolds stresses which include determining the turbulent viscosity, and depending on the level of sophistication of the model, solving transport equations for determining the turbulent kinetic energy and dissipation. Models include k-ε (Spalding), Mixing Length Model (Prandtl) and Zero Equation (Chen). The models available in this approach are often reffered to by the number of transport equations they include, for example the Mixing Length model is a "Zero Equation" model because no transport equations are solved, and the k-ε on the other hand is a "Two Equation" model because two transport equations are solved.

Reynolds stresses Model (RSM): This approach attempts to actually solve transport equations for the Reynolds stresses. This means introduction of several transport equations for all the Reynolds Stresses and hence this approach is much more costly in CPU effort.

[edit] Large eddy simulation

Large eddy simulations (LES) is a technique in which the smaller eddies are filtered and are modeled using a sub-grid scale model, while the larger energy carrying eddies are simulated. This method generally requires a more refined mesh than a RANS model, but a far coarser mesh than a DNS solution.

[edit] Detached eddy simulation

Detached eddy simulations (DES) is a modification of a RANS model in which the model switches to a subgrid scale formulation in regions fine enough for LES calculations. Regions near solid boundaries and where the turbulent length scale is less than the maximum grid dimension are assigned the RANS mode of solution. As the turbulent length scale exceeds the grid dimension, the regions are solved using the LES mode. Therefore the grid resolution is not as demanding as pure LES, thereby considerably cutting down the cost of the computation. Though DES was initially formulated for the Spalart-Allmaras model (Spalart et al, 1997), it can be implemented with other RANS models (Strelets, 2001), by appropriately modifying the length scale which is explicitly or implicitly involved in the RANS model. So while Spalart-Allamaras model based DES acts as LES with a wall model, DES based on other models (like two equation models) behave as a hybrid RANS-LES model. Grid generation is more complicated than for a simple RANS or LES case due to the RANS-LES switch. DES is a non-zonal approach and provides a single smooth velocity field across the RANS and the LES regions of the solutions.

[edit] Vortex method

The Vortex method is a grid-free technique for the simulation of turbulent flows. It uses vortices as the computational elements, mimicking the physical structures in turbulence. Vortex methods were developed as a grid-free methodology that would not be limited by the fundamental smoothing effects associated with grid-based methods. To be practical, however, vortex methods require means for rapidly computing velocities from the vortex elements – in other words they require the solution to a particular form of the N-body problem (in which the motion of N objects is tied to their mutual influences). A long-sought breakthrough came in the late 1980’s with the development of the Fast Multipole Method (FMM), an algorithm that has been heralded as one of the top ten advances in numerical science of the 20th century. This breakthrough paved the way to practical computation of the velocities from the vortex elements and is the basis of successful algorithms.

Software based on the Vortex method offer the engineer a new means for solving tough fluid dynamics problems with minimal user intervention. All that is required is specification of problem geometry and setting of boundary and initial conditions. Among the significant advantages of this modern technology;

  • It is practically grid-free, thus eliminating numerous iterations associated with RANS and LES.
  • All problems are treated identically. No modeling or calibration inputs are required.
  • Time-series simulations, which are crucial for correct analysis of acoustics, are possible.
  • The small scale and large scale are accurately simulated at the same time.

[edit] Solution algorithms

The basic solution of the system of equations arising after discretization is accomplished by many of the familiar algorithms of numerical linear algebra. One can either use a stationary iterative method, like symmetric Gauss-Seidel or successive overrelaxation, or a Krylov subspace method. In the latter, the solution residual is minimized on an orthogonal basis for a subspace of the non-linear operator. Krylov subspace methods are generally used with a preconditioner and an inner Newton iteration. Unfortunately for non-linear problems, the orthogonal basis can not be constructed with short recurrences (as in the plain conjugate gradient method) and the entire sequence of vectors must be stored.
In recent years so-called Multigrid algorithms have become very popular, because of their efficiency for larger systems of equation, i.e. finer discretization meshes. This technique avoids the disadvantage of the above mentioned iterative solvers, that information travels slowly from one point of the grid to another by changing to coarser grids and later interpolating back to the fine grid.

[edit] Motivation

The techniques are widely used by engineers designing or analysing devices that interact with fluid, such as vehicles, pumps, chemical apparatus or ventilation systems.

There are numerous commercial software packages to solve the Navier Stokes Equations. Examples of such commercial packages include the following (alphabetically listed): AVL FIRE, CFD-ACE+ and CFD-FASTRAN by ESI GROUP, CFdesign by Blue Ridge Numerics, CFX by ANSYS Inc., Coolit, COSMOSFloWorks by SolidWorks, EFD.Lab; EFD.Pro; EFD;V5 by NIKA GmbH & Flomerics, FLOW-3D, FLUENT, KIVA, NUMECA, Phoenics, STAR-CD by CD-adapco, CFDExpert by Zeus Numerix. Other software packages serve as add-ons or complementary products to CFD tools. These include EnSight or FIELDVIEW or Tecplot for post-processing and KINetics for solving detailed chemical kinetics.

The major problem faced by the CFD industry today is a shortage of skilled human resource. CFD development requires blend of technologist and programmer. Likewise CFD analysis needs good insight in the physics of the problem, understanding of numerical methods used along with expertise in commercial CFD software packages.

More recently, there has been a shift away from the numerical expert usage of CFD tools. This shift takes advantage of the engineer’s knowledge of the physical phenomena and employs intelligent solution controls to handle numerical nuances automatically based on common engineering input data. This new shift has been entitled “Upfront CFD” and is designed to be used by a wider audience of engineers in the concept stage of the design cycle.

[edit] Software

  • [1] Homepage for Analytical Methods, Inc., developers and marketers of VSAERO, MGAERO, VLAERO, USAERO, NSAERO, SDAERO, CAMRAD II and other CFD software
  • cfs.dccm An easy to use code for 3-D Simulation of diffusion flames with detailed chemistry.
  • MultiElement Airfoils Modern MS Windows based multi-element airfoil analysis software based on the compressible Euler equations for simulating 2-D compressible flows. Arbitrary placement of airfoils is handled by an automatic cartesian grid scheme.
  • FLUENT World's most widely used commercial CFD code for a wide range of industrial flow applications
  • NASCART-GT Solution adaptive, Cartesian-grid based flow solver.
  • STAR-CD The most used CFD code in the Automotive industry, also strong usage across industries. Reputation for polyhedral meshing and Computational Continuum Mechanics
  • CFX Popular CFD-solver embedded within the ANSYS Workbench environment
  • OpenFOAM a former commercial code that is now under GPL
  • OpenFlower an open source 3-D and 2-D flow solver.
  • OpenFVM an open source 1-D, 2D and 3-D unstructured finite volume flow solver with focus on multiphase flows.
  • HyperXtrude Commercial CFD code for metal extrusion and similar problems
  • GOTM General Ocean Turbulence Model, freely available, published under GPL.
  • GETM GETM is a 3D numerical model simulating the most important hydrodynamic and thermodynamic processes in natural waters, freely available, published under GPL.
  • COSMOSFloWorks COSMOSFloWorks is an easy to use and intuitive CFD software that is fully integrated inside SolidWorks. It employs Finite Volume technique to efficiently solve fluid flow and heat transfer problems in engineering.
  • MultiSurface Aerodynamics Wing Analysis Software using Vortex Lattice CFD method.
  • Dolfyn an Open Source unstructured Finite Volume Method code
  • Edge Unstructured Finite-Volume CFD-code from FOI featuring DES, LES, aeroelasticity, shape optimization (adjoint solver). Binaries are freely distributed.
  • CFdesign CFdesign® turns a standard MCAD workstation into a fully interactive flow bench, thermal test rig, and wind tunnel, using a Finite Element technique.
  • MFIX is an open source multiphase CFD software developed at NETL.
  • NIKA EFD.Lab
  • NASA provides CFD software to residents in the US through The Open Channel Foundation
  • GERRIS is a GPL incompressible flow solver
  • Featflow is an Open Source 2-D and 3-D Finite Element Method incompressible flow solver
  • Femwater is a freely downloadable(including source) finite element code developed by the EPA to calculate chemical transport through fluids. The EPA site does not include source code(use previous link) but it does provide an executable as well as a description of Femwater.
  • Typhon is an open source multiphysics solver (includes compressible flow and heat transfer)
  • Piping Systems FluidFlow has a fully functional demo which uses sample fluids for evaluations available for download
  • Atmos
  • WANDA WL|Delft Hydraulics transient flow simulation of pipeline networks, including extensive boundary conditions (pumps, valves, etc.), water hammer, free surface flow and control simulation
  • Stoner Pipeline Simulator transient flow simulation of natural gas or oil transmission systems
  • SynerGEE general purpose-modeling tool for piping networks including natural gas and water
  • PipelineStudio Steady-state and transient flow simulation for gas or liquid pipeline networks, evaluation download available (~ 132 M)
  • Olga 2000
  • CFD Studio Educational program to study CFD Problems
  • Hysys
  • Comet commercial Finite Volume Method
  • Channelflow Channelflow uses "spectral method" (GPL)
  • Net-Pipe
  • NEKTON "Spectral Element Method (SEM)"
  • PowerFLOW from Exa Commercial "Lattice Boltzmann Method" for high Reynolds number, low Mach number flows
  • Enzo is an open-source cosmological simulation code that uses an adaptive mesh.
  • FLASH is a free for non-commercial use, adaptive mesh, compressible solver for astrophysical flows
  • Daat Research Corp. makers Coolit and CoolitPCB CFD software for electronics cooling applications
  • CFD-ACE+ CFD code for wide range of multiphysics applications
  • CFD-FASTRAN CFD code for aerodynamic/aerospace applications
  • CFD-CADalyzer CFD code for simulation based design (links with CAD)
  • FLOW-3D CFD code especially for free surface flow applications
  • ICEM CFD Engineering - Involved in various CFD products mainly Mesh Generation products like ICEMCFD HEXA. Acquired by ANSYS Inc. in 1998.
  • ParaView an open-source, parallel visualization application
  • FIELDVIEW™ commercial post-processing and visualization for commercial and proprietary CFD solver data.
  • EnSight™ commercial post-processing and visualization for commercial and proprietary CFD, FEA, and FSI solver data particularly large, transient models.
  • Tecplot CFD post-processing, plotting, graphing and visualization software.
  • COSILAB - software and CFD add-ins for chemistry in laminar and turbulent flows
  • Reaction Design - software for chemical kinetics and CFD add-ins
  • FLOTHERM commercial CFD software for electronics cooling, from Flomerics
  • FLOVENT commercial CFD software for the built environment, from Flomerics
  • FLOPCB collaborative design software for conceptual PCB design by product marketing, electrical and mechanical engineers, from Flomerics
  • COMSOL Multiphysics (aka FEMLAB) commercial finite element package for multiphysics including CFD
  • TAU Unstructured Finite-Volume CFD-code from DLR for aircraft and rotorcraft
  • FLOWer Structured Finite-Volume CFD-code from DLR for aircraft and rotorcraft
  • NaSt2D-2.0 open source 2D-Navier-Stokes solver for viscous, unsteady, incompressible, laminar and turbulent flows
  • NaSt3DGP a parallel 3D flow solver for the incompressible Navier-Stokes equations
  • MOUSE a C++ library for finite volume computations, distributed under the GNU General Public License
  • Moldex3D commercial CAE software for injection molding
  • Pointwise - makers of Gridgen
  • Metacomp Technologies, Inc. - makers of CFD++
  • Tdyn is a fluid dynamic (CFD) simulation environment based on the stabilized Finite Element Method
  • NIST Fire Dynamics Simulator (FDS)is a CFD model for low-speed, thermally-driven fluid flow with an emphasis on smoke and heat transport from fires
  • PASSAGE Software by Technalysis Passage® software is a collection of 3D and 1D finite element programs solving complex flow, heat transfer and other related problems in product design and manufacturing
  • Moldflow Plastics Insight - Plastics flow analysis software
  • PHOENICS CFD from CHAM - 3D, time dependent Navier-Stokes finite volume solver. First commercial solver, still being extended. Shareware older versions available.
  • Zeus Numerix Located at the Technology Business Incubator of the Indian Institute of Technology (Bombay), the Zeus group has developed CFDExpert & CFDTutor, GridZ & FlowZ. Zeus Numerix also undertakes Commercial R&D of their customers and delivers customised solution that has not been attempted by other commercial packages.
  • Javafoil - A small java applet for calculating properties of aerofoil sections
  • RPMTurbo - makers of TurboSolve, parallelized finite-volume 3D CFD flow solver including a linearized solver
  • VorCat Commercial code for the simulation of High-Reynolds number, turbulent flows based on an innovative, patented vortex method
  • AeroSoft makers of GASP

[edit] External links

[edit] See Also

Visualization, Blade element theory, Finite Element Analysis