0% found this document useful (0 votes)
30 views131 pages

CFD2

CFD2
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
30 views131 pages

CFD2

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

‫جامعة مصراتة ‪ /‬كلية اهلندسة ‪ /‬قسم اهلندسة امليكانيكية ‪ /‬ربيع ‪2024‬‬

‫ديناميكا املوائع احلسابية املتقدمة‬


‫‪Advanced COMPUTATIONAL FLUID DYNAMICS‬‬
‫‪CFD‬‬
‫بعض املراجع املقرتحة ‪..‬‬
Finite Difference Methods
1
X
schema schema
aval
aval
Solution
The solution is a little more complicated in that
it is now required to invert the matrix

calculation of

Storage of results

*There are a large number of methods dedicated to matrix inversion.


Schema truncation error applied to the resolution of a PDE

Let's go back to our model equation

Thus the TE is defined as:


According to the definition given to TE, this means that the exact solution
solution u(x) does not satisfy the discrete finite difference equation (FDE)
but a modified difference equation including the truncation error.

The TE can be seen as the residual of the discrete equation when


we use the exact equation in its evaluation.
A digital scheme is said to be consistent if its truncation
error tends towards zero when all the discretization
steps t, x, y,..tend towards zero.

For Heat Equation:

The truncation error was

The schemes used to solve this PDE, which lead to this TE,
are consistent.
schema
Stability

This notion is closely linked with that of convergence.

When the PDE involves a temporal description (i.e. a


temporal derivative, this notion takes on its full meaning.

Numerical stability is therefore a concept specific to


evolutionary problems.

What guarantees that the last calculation time step (n-1) ⇒n


will be carried out under conditions similar to calculation
time step 1⇒2?
A numerical schema is stable if the errors, whatever
their origins (truncation, rounding errors, etc.) do not
increase at each time step of the sequential problem.

The stability of a schema is more difficult to establish


than consistency, but when possible it is generally
expressed by a condition linking the time step t to the
space step x.
schema

Lax's Theorem
Von Neumann Stability Analysis
This analysis method comes from spectral analysis.
Let be the error between the exact solution the numerical solution

satisfy the discrete finite difference equation

And as:

We have:
The solution will be stable if and only if decreases as the
solution progresses over time.
In other terms we must check that:

Considering that the solution of a transient diffusion problem is often


exponential in time and that its temporal dependence obeys the
expression of a Fourrier series, it is reasonable to assume that the
same will be true for the error.

Where the k are the wavenumbers can be real or complex?


Substituting this expression into leads to:

or as

thus

where G is the amplification factor


Thus

which leads to the following stability condition:


Pure advection equation

explicit upstream schema


we wish to show that
the associated stability condition is
For predominantly convective equations, the CFL condition imposes

For a space step and a speed given the distance


traveled by the information during the time step must be less than
Finite Differences for Hyperbolic
equations

There are more than 20 numerical schemes dedicated to this type of equation!!!

Downstream/centered schemes

Downstream

centered

These two schemes are unconditionally unstable


Upwind schemes

Upstream

with

i.e. the term must be approximated by


Thus we can consider that the upwind scheme is equivalent to the centered
Scheme + a numerical diffusion (numerical viscosity) term which stabilizes the
scheme

This scheme is stable when the condition

The upstream scheme is less precise than the centered scheme


and introduces the“ digital diffusion“ dellac osla ,”false diffusion ”
or “artificial viscosity.”
The numerical diffusion has the effect of smoothing the solution
By switching by

This scheme is stable under the condition


• The simplest scheme of 2ed order in time
• 3 time levels ⇨more storage + 2 initial conditions
• disadvantage does not depend on

This scheme is stable under the condition


2-step schema of

• 1st step we apply


• 2ed step we apply

This scheme is stable under the condition


This scheme uses a Taylor series expansion combined with an
equation allowing the temporal derivative to be replaced by a
spatial derivative.

which leads to:


When we apply a centered scheme for the first and second
derivatives, we finally obtain:

Like the upwind scheme, the Lax-Wendroff scheme is an


attempt to stabilize the centered scheme by adding numerical
diffusion.
In the case of the upwind scheme:

In the case of the Lax-Wendroff scheme


Predictor/corrector scheme

Predictor step

Corrector step

It may be advantageous to “switch” in the 2 steps from upwind to


downwind.
This scheme is stable under the condition
Scheme in 3 steps

This scheme is stable under 2 conditions:


Implicit treatment

explicit treatment

Implicit treatment
Finite Differences for Elliptic Equations
A centered second order scheme gives

Which can be written in the form of a linear system of the type:

To simplify we use a regular mesh in both directions.


schemes
In 1D
• A centered second-order scheme will give a tri-diagonal matrix.

•A fourth order centered scheme will give a penta-diagonal


matrix.

In 3D
•A fourth order centered scheme will give
a 13-diagonal matrix.
The solution now requires inverting the matrix

Gauss Seidel method

Equation (1) is re-written:

We introduce an iterative process to solve equation)2(

k is not an index characterizing the temporal evolution.


for and
implementation of boundary conditions

stopping criterion test


Boundary conditions
If we write equation (3) for i=1 and j=2 we have:

is given by the boundary condition


are already known from the previous iteration

The concepts of boundary conditions and their implementation will


be developed later.
Numerical Experience
We consider the SS heat equation with source term.

When we remove the temporal term

We obtain the Poisson equation

which can be discretized and solved with the previous techniques


The problem is defined on a square

We maintain zero temperature on the borders

The additional source term at the center is

We use a uniform mesh in both directions


We carry out 4 different calculations, each time increasing the number of nodes in
the mesh.
We represent 10 iso-contours
of the temperature field.
Finite Differences for Parabolic Equations

This scheme is stable under the condition


unconditionally stable

+
Combined scheme or Teta scheme

is

Unconditionally Stable for

conditionally stable for if


In 1D we must specify BC on
the two nodes belonging to
each boundary node.

In 2D we must specify BC In 3D we must specify BC


on the nodes belonging to on the nodes belonging to
each boundary segment. each boundary surface.
Boundary Condition type
of

Written for Leads to

Written for Leads to


of

BC

BC
Downwind

Upwind

Written for
With the value of Leads to

Written for
With the value of Leads to
Downwind

Upwind
BC

BCs

BC

BC
BCs
BCs

BC

Implementing Of BC
BC

BC

BC PDE
BC

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy