Documenti di Didattica
Documenti di Professioni
Documenti di Cultura
Section A - CFD
SOLUTIONS
Solution 1
[5 marks]
div( u) 0 [2 marks]
t
Momentum Conservation
( u ) ( p xx ) yx zx
div ( uu) S Mx
t x y z [3 marks]
Momentum Conservation
Newtons second law states that the rate of change of momentum of a fluid particle
equals the sum of the forces on the particle.
Set the rate of change of momentum of the fluid particle equal to the total force on the
element due to surface stresses plus the rate of increase of momentum due to sources.
The body forces can be described by a source term, SM , of momentum per unit
volume per unit time. p denotes pressure and denotes the viscous stresses.
[10 marks]
b)
(i) The inclusion of more terms in the Taylor series improves the accuracy of the
value for y(x0 + x). From a practical point of view it is important to have an estimate
of the error incurred by truncating the series after a given number of terms. Truncating
the series after the nth term yields an error in y(x0 + x) that is less than.
y n 1 x n 1
max
( n 1)!
y n 1
Where max
is the largest absolute value of the n+1 derivative in the interval
x
Unfortunately we do not know this value and we can only say that the magnitude of
the error varies as xn+1. We estimate that the error is of the order of xn+1 and
designate it as (xn+1)
[4 marks]
In order to identify the values let us say that x0 corresponds to i and the point x0 + x
corresponds to i+1.
yi 1 yi yix (x 2 )
yi 1 yi
f ( xi , yi ) OR yi 1 yi x f ( xi , yi )
x
This is the explicit formulation.
The value for yi+1 can be determined directly from the values for x and y at location i,
that is (xi and yi).
We can proceed with the numerical solution by starting with the initial conditions and
use the above equation step by step until the desired range of x is covered. This
approach is known as Eulers Method.
[10 marks]
The backward difference scheme combined with the forward difference scheme above
may be used to formulate a central difference scheme.
If the backward formulation of the derivative is used, the finite difference equation
becomes
yi yi 1
f ( xi , yi ) OR yi f ( xi , yi ) x yi 1
x
Subtracting the second equation from the first, and then solving for yi gives:
x 3
yi 1 yi 1 2 yi x yi ....
3
y yi 1 x 2 y yi 1
yi i 1 yi OR yi i 1 ( x 2 )
2x 3 2 x
[5 marks]
The accuracy of the finite difference formulation can be improved by using central
differencing instead of forward or backward differencing. This finite difference
representation is second-order accurate. It is equivalent to fitting a parabola through
the three points yi-1, yi and yi+1 and taking the slope of the parabola at location i.
[5 marks]
[TOTAL 50 MARKS]
Solution 2
v
v y
y
u
u u x
x
y
v
[5marks]
The finite volume method can in some ways be thought of as a combination of the
finite difference and finite element methods.
If we consider a simple finite volume, or cell, where the centroid of the cell is point P
is the reference point at which we wish to find a numerical analogue of the partial
differential equation.
Face w Face e
U uE uP U u P uW
and
x e xE xP x w xP xW
[5 marks]
(ii) The flow problem may contain a wide variety of features (vortices, boundary
layers, regions of rapid velocity / pressure change, separation regions, etc.) which
need to be modelled by the CFD simulation.
We must be aware of regions where these features may occur so that we can adjust the
mesh accordingly.
If the flow varies rapidly in space, a fine grid of points will be needed to describe the
variation accurately.
This is a consequence of the numerical discretisation techniques, which assume that
the variables vary in some simple way (e.g. linearly) between points or within an
element or volume.
[5 marks]
In some cases a mesh can be modified in such a way as to produce a more realistic
CFD solution.
Some adapt the original mesh to obtain a better fit on the geometry of the flow
problem, this can speed up computational solution of the flow.
Others solve using the original grid then modify the mesh in light of these initial
results, this requires considerable experience.
The two mesh modification strategies are:
Mesh enrichment additional points are placed in the domain at locations where they
are needed.
Mesh adaptation the mesh points are moved so that the density of points is increased
where required.
Clean up CAD geometry and for body fitted grids check that the surface grid
conforms to the CAD geometry.
When using periodic boundary conditions ensure high precision of the interface.
Avoid highly skewed cells, in particular for hexahedral cells or prisms the included
angles between the grid lines should be optimised in such a way that the angles are
approximately 90 degrees. Angles with less than 40 or more than 140 degrees often
show a deterioration in the results or lead to numerical instabilities, especially in the
case of transient simulations.
The angle between the grid lines and the boundary of the computational domain (the
wall or the inlet- and outlet-boundaries) should be close to 90 degrees. This
requirement is stronger than the requirement for the angles in the flow field far away
from the domain boundaries.
Avoid the use of tetrahedral elements in boundary layers.
Away from boundaries, ensure that the aspect ratio (the ratio of the sides of the
elements) is not too large. This aspect ratio should be typically not larger than 20.
Near walls this restriction may be relaxed and indeed can be beneficial.
The code requirements of mesh stretching or expansion ratios (rates of change of cell
size for adjacent cells) should be observed. The change in mesh spacing should be
continuous and mesh size discontinuities be avoided, particularly in regions of high
gradients.
The mesh should be finer in critical regions with high flow gradients, such as regions
with high shear, and where there are significant changes in geometry or where
suggested by error estimators. Make use of local refinement of the mesh in these
regions, in accordance with the selected turbulence wall modelling. The location of a
refinement interface should be away from high flow gradients.
Check the assumption of regions of high flow gradients assumed for the grid with the
result of the computation and rearrange grid points if found to be necessary.
A nalyse the suitability of the mesh by a grid dependency study (this could be local)
where you use at least three different grid resolutions. If this is not feasible try to
compare different order of spatial discretisations on the same mesh
Use the global topology of the mesh to help satisfy the above guidelines.
[10 marks]
b)
(i) A typical discussion on Errors and Uncertainties would include the following:
Typical known errors are the round-off errors in a digital computer and the
convergence error in an iterative numerical scheme. In these cases, the CFD analyst
has a reasonable chance of estimating the likely magnitude of the error.
Unacknowledged errors include mistakes and blunders, either in the input data or in
the implementation of the code itself, and there are no methods to estimate their
magnitude.
Uncertainties arise because of incomplete knowledge of a physical characteristic, such
as the turbulence structure at the inlet to a flow domain or because there is uncertainty
in the validity of a particular flow model being used.
An error is something that can be removed with appropriate care, effort and
resources, whereas an uncertainty cannot be removed as it is rooted in lack of
knowledge.
Sources of errors and uncertainties in results from simulations can be divided into two
distinct sources -- modeling and numerical.
Modeling errors and uncertainties are due to assumptions and approximations in the
mathematical representation of the physical problem (such as geometry, mathematical
equation, coordinate transformation, boundary conditions, turbulence models, etc.)
and incorporation of previous data (such as fluid properties) into the model.
In addition to the source of errors and uncertainty that are introduced by the numerical
model, the CFD engineer can also introduce errors and uncertainties. The process of
performing a CFD calculation is itself complex and requires the engineer to perform a
number of different activities. These typically include:
definition of the problem;
selection of the solution strategy;
development of the computational model;
analysis and interpretation of the results.
All of these steps are potentially error prone or subject to some degree of uncertainty.
[15 marks]
[10 marks]
[TOTAL 50 MARKS]