0% found this document useful (0 votes)
14 views22 pages

Numerical Methods in Energy Engineering

The document provides an overview of Computational Fluid Dynamics (CFD), highlighting its applications in various engineering fields such as heat transfer, aerodynamics, and chemical processes. It discusses the limitations of CFD, including reliance on physical models and numerical errors, and outlines the process of CFD analysis from mathematical modeling to post-processing of results. Additionally, it covers discretization methods, important variables in fluid dynamics, and the governing equations that form the basis of CFD.

Uploaded by

عمرو نور
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPT, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
14 views22 pages

Numerical Methods in Energy Engineering

The document provides an overview of Computational Fluid Dynamics (CFD), highlighting its applications in various engineering fields such as heat transfer, aerodynamics, and chemical processes. It discusses the limitations of CFD, including reliance on physical models and numerical errors, and outlines the process of CFD analysis from mathematical modeling to post-processing of results. Additionally, it covers discretization methods, important variables in fluid dynamics, and the governing equations that form the basis of CFD.

Uploaded by

عمرو نور
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPT, PDF, TXT or read online on Scribd
You are on page 1/ 22

Numerical methods in

Energy Engineering (2)

Dr. Eng. Hamada Mohamed Abdelmotalib


Mechanical Power & Energy Dep.
Faculty of Engineering, Minia University
Introduction
Fluid flow is commonly studied in one of three ways:
– Experimental fluid dynamics.
– Theoretical fluid dynamics.
– Numerically: computational fluid dynamics (CFD).
Computational fluid dynamics (CFD)
CFD is the science of predicting fluid flow, heat transfer, mass transfer,
chemical reactions, and related phenomena by solving the mathematical
equations which govern these processes using a numerical process.
• The result of CFD analyses is relevant engineering data used in:
– Conceptual studies of new designs.
– Detailed product development.
– Troubleshooting.
– Redesign.

Dr. Eng. Hamada M. Abdelmotalib 2


Introduction
Applications of CFD
– 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.

Dr. Eng. Hamada M. Abdelmotalib 3


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 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.
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.

Dr. Eng. Hamada M. Abdelmotalib 4


Dr. Eng. Hamada M. Abdelmotalib 5
CFD - how it works
• Analysis begins with a mathematical model of a physical problem.
• Conservation of matter, momentum, and energy must be satisfied throughout
the region of interest.
• Fluid properties are modeled empirically.
• Simplifying assumptions are made in order to make the problem tractable
(e.g., steady-state, incompressible, inviscid, two-dimensional).
• Provide appropriate initial and boundary conditions for the problem
• CFD applies numerical methods (called discretization) to develop
approximations of the governing equations of fluid mechanics in the fluid region
of interest.
• Governing differential equations: algebraic.
• The collection of cells is called the grid.
• The set of algebraic equations are solved numerically (on a computer) for the
flow field variables at each node or cell.
• System of equations are solved simultaneously to provide solution.
• The solution is post-processed to extract quantities of interest (e.g., lift, drag,
torque, heat transfer, separation, pressure loss, etc.).

Dr. Eng. Hamada M. Abdelmotalib 6


Discretization
• Domain is discretized into a finite set of control volumes or cells. The
discretized domain is called the “grid” or the “mesh.”
• General conservation (transport) equations for mass, momentum, energy, etc.,
are discretized into algebraic equations.
• All equations are solved to render flow field.
• For simple geometries, quad/hex meshes can provide high-quality solutions
with fewer cells than a comparable tri/tet mesh.
• For complex geometries, quad/hex meshes show no numerical advantage, and
you can save meshing effort by using a tri/tet mesh.

Dr. Eng. Hamada M. Abdelmotalib 7


Modeling
-Flow conditions
• Based on the physics of the fluids phenomena, CFD can be distinguished into
different categories using different criteria
• Viscous vs. inviscid (Re: Reynolds No.)
• External flow or internal flow (wall bounded or not)
• Turbulent vs. laminar (Re)
• Incompressible vs. compressible (Ma: Mach No.)
• Single- vs. multi-phase (Ca: Cavitation No.)
• Thermal/density effects (Pr: Prandtl No., γ, Gr: Grashof No.,Ec)
Initial conditions
Initial conditions (ICS, steady/unsteady flows)
• ICs should not affect final results and only affect convergence path, i.e.
number of iterations (steady) or time steps (unsteady) need to reach converged
solutions.
• More reasonable guess can speed up 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
8
Modeling(boundary conditions)
•Boundary conditions: No-slip or slip-free on walls, periodic, inlet (velocity
inlet, mass flow rate, constant pressure, etc.), outlet (constant pressure, velocity
convective, numerical beach, zero-gradient), and nonreflecting (for
compressible flows, such as acoustics), etc.

Periodic boundary conditions are a set of boundary conditions which are often
chosen for approximating a large system by using a small part called a unit cell.
PBCs are often used in computer simulations and mathematical models 9
Modeling (selection of models)
• CFD codes typically designed for solving certain fluid phenomenon by
applying different models
• Viscous vs. inviscid (Re)
• Turbulent vs. laminar (Re, Turbulent models)
• Incompressible vs. compressible (Ma, 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)
• Free-surface flow (Fr, level-set & surface tracking model) and surface tension
(We, bubble dynamic model)
• Chemical reactions and combustion (Chemical reaction model)

1
0
Modeling (Turbulence and free surface models)
• 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 region.
• LES: accurate in separation region and unaffordable for resolving BL
• DES: RANS inside BL, LES in separated regions.
• Free-surface models:
• Surface-tracking method: mesh moving to capture free surface, limited to
small and medium wave slopes
• Single/two phase level-set and volume-of-fluid (VOF) methods:
mesh fixed and level-set/VOF functions used to capture the gas/liquid interface,
capable of studying steep or breaking waves.

1
1
Numerical methods
• The continuous Initial Boundary Value Problems (IBVPs) are discretized into
algebraic equations using numerical methods. Assemble the system of
algebraic equations and solve the system to get approximate solutions
• Numerical methods include:
1. Discretization methods
2. Solvers and numerical parameters
3. Grid generation and transformation
4. High Performance Computation (HPC) and postprocessing

1
2
Discretization methods
• Finite difference methods (straightforward to apply, usually for regular grid)
and finite volumes and finite element methods (usually for irregular 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)
• Explicit methods can be easily applied but yield conditionally stable Finite
Different Equations (FDEs), which are restricted by the time step; Implicit
methods are unconditionally stable, but need efforts on efficiency.
• Usually, higher-order temporal discretization is used when the spatial
discretization is also of higher order.
• Stability: A discretization method is said to be stable if it does not magnify the
errors that appear in the course of numerical solution process. 1
3
• Pre-conditioning method is used when the matrix of the linear algebraic system
is ill-posed, such as multi-phase flows, flows with a broad range of Mach
numbers, etc.
• Selection of discretization methods should consider efficiency, accuracy and
special requirements, such as shock wave tracking.

1
4
Important variables
• Pressure and fluid velocities are always calculated in conjunction. Pressure
can be used to calculate forces on objects, e.g., for the prediction of drag of a
car. Fluid velocities can be visualized to show flow structures.
• From the flow field we can derive other variables such as shear and vorticity.
Shear stresses may relate to erosion of solid surfaces. Deformation of fluid
elements is important in mixing processes. Vorticity describes the rotation of
fluid elements.
• In turbulent flows, turbulent kinetic energy and dissipation rate are important
for such processes as heat transfer and mass transfer in boundary layers.
• For non-isothermal flows, the temperature field is important. This may govern
evaporation, combustion, and other processes.
• In some processes, radiation is important.

1
5
Post-processing
• Results are usually reviewed in one of two ways:
graphically or alphanumerically.
• Graphically:
– Vector plots.
– Contours.
– Iso-surfaces.
– Flowlines.
– Animation.
• Alphanumerics:
– Integral values.
– Drag, lift, torque calculations.
– Averages, standard deviations.
– Minima, maxima.
– Compare with experimental data.

1
6
Streamlines
• Streamlines are curves that are everywhere tangent to the velocity vector U.
• The animation shows streamlines for a steady state 3-D flow.
• For 3-D flow fields, instead of streamlines one usually visualizes streaklines or
pathlines, which for steady flow are the same.
Pathlines
• A pathline is the trajectory followed by an individual particle.
• The pathline depends on the location where the particle was injected in the
flow field and, in unsteady flows, also on the time when it was injected.
• In unsteady flows, pathlines may be difficult to follow and not easy to create
experimentally.

1
7
1
8
The Governing Equations
In this section, we discuss fundamental principles in fluid dynamics and derive
their governing equations, their physical meaning, and their mathematical
forms
particularly appropriate in CFD.
The fundamental equations of fluid dynamics
In modeling fluid motion, there are always following philosophy we need to
consider. First is to choose the appropriate fundamental physical principles
from
the law of physics that are:
(a) Mass is conserved,
(b) F = ma (Newton’s second law), and
(c) energy is conserved.

Dr. Eng. Hamada M. Abdelmotalib 19


2
0
21
Dr. Eng. Hamada M. Abdelmotalib
2
2

You might also like