2.29 Numerical Fluid Mechanics Spring 2015 · 2.29 Numerical Fluid Mechanics Spring 2015 –Lecture...
Transcript of 2.29 Numerical Fluid Mechanics Spring 2015 · 2.29 Numerical Fluid Mechanics Spring 2015 –Lecture...
PFJL Lecture 16, 1Numerical Fluid Mechanics2.29
2.29 Numerical Fluid Mechanics
Spring 2015 – Lecture 16
REVIEW Lecture 15:
• Finite Volume Methods
– Integral and conservative forms of the cons. laws
– Introduction
– Approximations needed and basic elements of a FV scheme
• Grid generation ⇒ Time-Marching
• FV grids: Cell centered (Nodes or CV-faces) vs. Cell vertex; Structured vs. Unstructured
• Approximation of surface integrals (leading to symbolic formulas)
• Approximation of volume integrals (leading to symbolic formulas)
• Summary: Steps to step-up a FV scheme
– One Dimensional examples
• Generic equation:
• Linear Convection (Sommerfeld eqn): convective fluxes
– 2nd order in space
1/ 2
1/ 21/ 2 1/ 2 ( , )j
j
xjj j x
d xf f s x t dx
dt
PFJL Lecture 16, 2Numerical Fluid Mechanics2.29
TODAY (Lecture 16):
FINITE VOLUME METHODS
• Summary: Steps to step-up a FV scheme
• Examples: One Dimensional examples
– Generic equations
– Linear Convection (Sommerfeld eqn): convective fluxes
• 2nd order in space, 4th order in space, links to CDS
– Unsteady Diffusion equation: diffusive fluxes
• Two approaches for 2nd order in space, links to CDS
• Approximation of surface integrals and volume integrals revisited
• Interpolations and differentiations
– Upwind interpolation (UDS)
– Linear Interpolation (CDS)
– Quadratic Upwind interpolation (QUICK)
– Higher order (interpolation) schemes
PFJL Lecture 16, 3Numerical Fluid Mechanics2.29
References and Reading Assignments
• Chapter 29.4 on “The control-volume approach for elliptic equations” of “Chapra and Canale, Numerical Methods for Engineers, 2014/2010/2006.”
• Chapter 4 on “Finite Volume Methods” of “J. H. Ferziger and M. Peric, Computational Methods for Fluid Dynamics. Springer, NY, 3rd edition, 2002”
• Chapter 5 on “Finite Volume Methods” of “H. Lomax, T. H. Pulliam, D.W. Zingg, Fundamentals of Computational Fluid Dynamics (Scientific Computation). Springer, 2003”
• Chapter 5.6 on “Finite-Volume Methods” of T. Cebeci, J. P. Shao, F. Kafyeke and E. Laurendeau, Computational Fluid Dynamics for Engineers. Springer, 2005.
PFJL Lecture 16, 4Numerical Fluid Mechanics2.29
One-Dimensional Example I
Linear Convection (Sommerfeld) Eqn, Cont’d
• The resultant linear algebraic system is circulant tri-diagonal (for
periodic BCs)
• This is as the 2nd order CDS!, except that it is written in terms of
cell averaged values instead of values at FD nodes/points
– It is also 2nd order in space
– Has same properties as classic CDS for
• Non-dissipative (check Fourier analysis or eigenvalues of BP which are
imaginary), but can provide oscillatory errors
• Stability (recall tables for FD schemes, linear convection eqn.) of time-marching
– If centered in time, centered in space, explicit: stable with CFL condition:
– If implicit in time: unconditionally stable for all
( 1,0,1) 02 P
d cdt x
Φ B Φ
1c tx
,t x
( , ) ( , ) 0x t c x tt x
PFJL Lecture 16, 5Numerical Fluid Mechanics2.29
One-Dimensional Example IILinear Convection (Sommerfeld) Eqn: 4th order approx.
• 1D exact integral equation still
• Use 4th order accurate surface/volume integrals
– Replace piecewise-constant approx. to (x) with piece-wise quadratic
approx (ξ= x – xj ): (note defined over more than 1 cell)
– Satisfy (average) constraints, i.e. choose a, b, c so that:
– This gives:
– Next, we need to evaluate the values of (x) at the boundaries so as to
compute the advective fluxes at these boundaries:
1/ 2 1/ 2 0j
j j
d xf f
dt
2( ) a b c
'P s
/ 2 / 2 3 / 2
1 13 / 2 / 2 / 2
1 1 1( ) , ( ) , ( )x x x
j j jx x xd d d
x x x
1 1 1 1 1 12
2 26, ,
2 2 24j j j j j j j ja b c
x x
1/ 2 1/ 2 1/ 2 1/ 2, , ,L R L Rj j j jf f f f
j-1/2 j+1/2∆ x
j-2 j-1 j j+1 j+2
L R L R
x
21
Image by MIT OpenCourseWare.
PFJL Lecture 16, 6Numerical Fluid Mechanics2.29
One-Dimensional Example IILinear Convection (Sommerfeld) Eqn: 4th order approx.
• Since f = c compute at edges:
• Resolve flux discontinuity again, use average values
• Done with “integrals” we can substitute in 1D conv. eqn:
• For periodic domains:
1 2 1 11/ 2 1/ 2
1 1 2 11/ 2 1/ 2
2 5 2 5, ,
6 65 2 5 2
,6 6
j j j j j jL Lj j
j j j j j jR Rj j
1/ 2 1/ 2 1/ 2 1/ 21/ 2
2 1 11/ 2
ˆ2 2
7 7ˆ12
L R L Rj j j j
j
j j j jj
f f c cf
f c
1/ 2 1/ 2 1/ 2 1/ 21/ 2
1 1 21/ 2
ˆ2 2
7 7ˆ12
L R L Rj j j j
j
j j j jj
f f c cf
f c
2 1 1 21/ 2 1/ 2 1/ 2 1/ 2
8 8ˆ ˆ 012
j j j j j j jj j j j
d x d x df f f f x c
dt dt dt
( 1, 8,0,8,1) 012 P
d cdt x
Φ B Φ
j-1/2 j+1/2∆ x
j-2 j-1 j j+1 j+2
L R L R
x
21
Image by MIT OpenCourseWare.
PFJL Lecture 16, 7Numerical Fluid Mechanics2.29
Centered
Differences
(from Lecture 10)
PFJL Lecture 16, 8Numerical Fluid Mechanics2.29
One-Dimensional Example III
2nd order approx. of diffusion equation:
• 1D exact integral equation same form!
but with:
• Approximation of surface (flux) integral: Approach 1
– Direct: we know that to second-order (from CDS and from )
– Substitute into integral equation:
– In the matrix form, with Dirichlet BCs:
• Semi-discrete FV scheme is as CDS in space,
but in terms of cell-averaged data
1/ 2 1/ 2 0j
j j
d xf f
dt
2
2
( , ) ( , )x t x tt x
fx
1 1 121/ 2 1/ 2 1/ 2
1/ 2
ˆ ˆ( ) and j j j j j jj j j
j
f O x f fx x x x
2( )j j O x
1 11/ 2 1/ 2
2ˆ ˆ 0j j j j jj j
d x df f x
dt dt x
2 (1, 2,1) ( )ddt x
Φ B Φ bc
j-1/2 j+1/2∆ x
j-2 j-1 j j+1 j+2
L R L R
x
21
Image by MIT OpenCourseWare.
PFJL Lecture 16, 9Numerical Fluid Mechanics2.29
One-Dimensional Example III
2nd order approx. of diffusion equation:
• Approximation of surface (flux) integral: Approach 2
– Use a piece-wise quadratic approx.:
• Note that a, b, c remain as before, they are set by the volume average constraints
• Since a, b are “symmetric”:
• There are no flux discontinuities in this case
– Substitute into integral equation:
– In the matrix form, with Dirichlet BCs:
• Semi-discrete FV scheme is as CDS in space,
but in terms of cell-averaged data
2
2
( , ) ( , )x t x tt x
1 21/ 2 1/ 2
1/ 2
1 21/ 2 1/ 2
1/ 2
( )
( )
j jR Lj j
j
j jR Lj j
j
f f O xx x
f f O xx x
1 11/ 2 1/ 2
2ˆ ˆ 0j j j j jj j
d x df f x
dt dt x
2( ) 2a b c a bx
2 (1, 2,1) ( )ddt x
Φ B Φ bc
Expressing fluxes at the surface based on cell-averaged (nodal)
values: Summary of Two Approaches and Boundary Conditions
• Set-up of surface/volume integrals: 2 approaches (do things in opposite order)
1. (i) Evaluate integrals using classic rules (symbolic evaluation); (ii) Then, to obtain the unknown symbolic values, interpolate based on cell-averaged (nodal) values
Similar for other integrals:
2. (i) Select shape of solution within CV (piecewise approximation); (ii) impose volume constraints to express coefficients in terms of nodal values; and (iii) then integrate. (this approach was used in the examples).
Similar for higher dimensions:
• Boundary conditions:
– Directly imposed for convective fluxes
– One-sided differences for diffusive fluxes
2.29 Numerical Fluid Mechanics PFJL Lecture 16, 10
( ) ( ) ( )( ) ( )( ) ( )
( ' )
( )
i i
i Pi
P
Pe
a a
aa P
e PV
e S
i x xx xii x
F s
iii F f dA
( ) ( ) ( )i i
( ) ( ) ( )i i
( ) ( ) ( )( ) ( ) ( )a a( ) ( ) ( )i ia ai i
( ) ( ) ( )i i
( ) ( ) ( )a a( ) ( ) ( )i i
( ) ( ) ( )( ) ( ) ( )i x x( ) ( ) ( )( ) ( ) ( )a a( ) ( ) ( )i x x( ) ( ) ( )a a( ) ( ) ( )
( ' )e P( ' )e P( ' )( ' )F s( ' )( ' )e P( ' )F s( ' )e P( ' )F s( ' )F s( ' )e PF se P( ' )e P( ' )F s( ' )e P( ' )( ' )( ' )e Pe P( ' )e P( ' )( ' )e P( ' )( ' )F s( ' )( ' )F s( ' )( ' )e P( ' )F s( ' )e P( ' )( ' )e P( ' )F s( ' )e P( ' )
1( , , )V V
S s dV dV etcV
( ) ( )( ' )
( ) ( ' ) ( ' )e
e e eSe P
e P P
i F f dA FF s
ii s s
( )e e( )e e( )( )( )e ee e( )e e( )( )e e( )
( ' )e P( ' )e P( ' )( ' )F s( ' )( ' )e P( ' )F s( ' )e P( ' )F s( ' )F s( ' )e PF se P( ' )e P( ' )F s( ' )e P( ' )( ' )( ' )e Pe P( ' )e P( ' )( ' )e P( ' )( ' )F s( ' )( ' )F s( ' )( ' )e P( ' )F s( ' )e P( ' )( ' )e P( ' )F s( ' )e P( ' )
( ) ( ' ) ( ' )e P P( ) ( ' ) ( ' )P( ) ( ' ) ( ' )( ) ( ' ) ( ' )s s( ) ( ' ) ( ' )( ) ( ' ) ( ' )P( ) ( ' ) ( ' )s s( ) ( ' ) ( ' )P( ) ( ' ) ( ' ) ( ) ( ' ) ( ' ) ( ) ( ' ) ( ' )e P e P( ) ( ' ) ( ' )e P( ) ( ' ) ( ' ) ( ) ( ' ) ( ' )e P( ) ( ' ) ( ' )( ) ( ' ) ( ' )s s( ) ( ' ) ( ' ) ( ) ( ' ) ( ' )s s( ) ( ' ) ( ' )( ) ( ' ) ( ' )P( ) ( ' ) ( ' )s s( ) ( ' ) ( ' )P( ) ( ' ) ( ' ) ( ) ( ' ) ( ' )P( ) ( ' ) ( ' )s s( ) ( ' ) ( ' )P( ) ( ' ) ( ' )( ) ( ' ) ( ' ) ( ) ( ' ) ( ' ) ( ) ( ' ) ( ' ) ( ) ( ' ) ( ' )( ) ( ' ) ( ' )e P( ) ( ' ) ( ' ) ( ) ( ' ) ( ' )e P( ) ( ' ) ( ' ) ( ) ( ' ) ( ' )e P( ) ( ' ) ( ' ) ( ) ( ' ) ( ' )e P( ) ( ' ) ( ' )( ) ( ' ) ( ' )s s( ) ( ' ) ( ' ) ( ) ( ' ) ( ' )s s( ) ( ' ) ( ' ) ( ) ( ' ) ( ' )s s( ) ( ' ) ( ' ) ( ) ( ' ) ( ' )s s( ) ( ' ) ( ' )
( , ) ( , );
( , ) ;i
i
a
a P P P
x y x y etc
x y etc
( , ) ( , );iax y x y etc( , ) ( , );x y x y etc( , ) ( , );i
x y x y etci
( , ) ( , );i
( , ) ( , );x y x y etc( , ) ( , );i
( , ) ( , );ax y x y etca( , ) ( , );a( , ) ( , );x y x y etc( , ) ( , );a( , ) ( , );
Approach 1: Evaluate integrals symbolically, then
interpolate based on neighboring cell-averages
• Surface/Volume integrals: Approach 1
(i) Evaluate integrals based on classic rules (symbolic evaluation)
(ii) Then, to obtain the unknown symbolic values, interpolate based on
neighboring cell-averaged (nodal) values
• If we utilize this approach 1
– Symbolic evaluation:
• To evaluate total surface fluxes (convective + diffusive),
values of and its gradient normal to the cell face at one or more locations on
that face are needed. They have to be expressed as a function of nodal values
• Similar for volume integrals
– Next is interpolation:
• Express the ’s as a function of nodal values. Numerous possibilities. We
already saw some of the most common, provided again next.
2.29 Numerical Fluid Mechanics PFJL Lecture 16, 11
. ( . ) .S S S
F n dA v n dA q n dA
To evaluate total surface fluxes (convective + diffusive),
F n dA v n dA q n dA F n dA v n dA q n dA. ( . ) .F n dA v n dA q n dA. ( . ) . . ( . ) .F n dA v n dA q n dA. ( . ) .F n dA v n dA q n dAF n dA v n dA q n dA F n dA v n dA q n dAF n dA v n dA q n dAF n dA v n dA q n dA. ( . ) .F n dA v n dA q n dA. ( . ) .. ( . ) .F n dA v n dA q n dA. ( . ) .. ( . ) .F n dA v n dA q n dA. ( . ) .. ( . ) .F n dA v n dA q n dA. ( . ) . . ( . ) .F n dA v n dA q n dA. ( . ) .. ( . ) .F n dA v n dA q n dA. ( . ) . . ( . ) .F n dA v n dA q n dA. ( . ) . . ( . ) .F n dA v n dA q n dA. ( . ) . . ( . ) .F n dA v n dA q n dA. ( . ) .. ( . ) .F n dA v n dA q n dA. ( . ) .. ( . ) .F n dA v n dA q n dA. ( . ) . . ( . ) .F n dA v n dA q n dA. ( . ) .. ( . ) .F n dA v n dA q n dA. ( . ) . . ( . ) .F n dA v n dA q n dA. ( . ) .. ( . ) .F n dA v n dA q n dA. ( . ) . . ( . ) .F n dA v n dA q n dA. ( . ) .. ( . ) .F n dA v n dA q n dA. ( . ) .To evaluate total surface fluxes (convective + diffusive),
F n dA v n dA q n dA. ( . ) .F n dA v n dA q n dA. ( . ) . F n dA v n dA q n dA F n dA v n dA q n dA. ( . ) .F n dA v n dA q n dA. ( . ) . . ( . ) .F n dA v n dA q n dA. ( . ) .. ( . ) .F n dA v n dA q n dA. ( . ) .. ( . ) .F n dA v n dA q n dA. ( . ) . . ( . ) .F n dA v n dA q n dA. ( . ) .. ( . ) .F n dA v n dA q n dA. ( . ) .. ( . ) .F n dA v n dA q n dA. ( . ) . . ( . ) .F n dA v n dA q n dA. ( . ) . . ( . ) .F n dA v n dA q n dA. ( . ) . . ( . ) .F n dA v n dA q n dA. ( . ) .. ( . ) .F n dA v n dA q n dA. ( . ) .. ( . ) .F n dA v n dA q n dA. ( . ) . . ( . ) .F n dA v n dA q n dA. ( . ) .. ( . ) .F n dA v n dA q n dA. ( . ) . . ( . ) .F n dA v n dA q n dA. ( . ) .. ( . ) .F n dA v n dA q n dA. ( . ) . . ( . ) .F n dA v n dA q n dA. ( . ) .. ( . ) .F n dA v n dA q n dA. ( . ) .
PFJL Lecture 16, 12Numerical Fluid Mechanics2.29
Approx. of Surface/Volume Integrals:
Classic symbolic formulas
• Surface Integrals
– 2D problems (1D surface integrals)
• Midpoint rule (2nd order):
• Trapezoid rule (2nd order):
• Simpson’s rule (4th order):
– 3D problems (2D surface integrals)
• Midpoint rule (2nd order):
• Higher order more complicated to implement in 3D
• Volume Integrals:
– 2D/3D problems, Midpoint rule (2nd order):
– 2D, bi-quadratic (4th order, Cartesian):
2( ) ( )2e
ne see eS
f fF f dA S O y
4( 4 ) ( )6e
ne e see eS
f f fF f dA S O y
ee S
F f dA
2 2( , )e
e e eSF f dA S f O y z
P P PVS s dV s V s V
16 4 4 4 436P P s n w e se sw ne nwx yS s s s s s s s s s
1,V V
S s dV dVV
(summary from Lecture 15)
2( )e
e e e e e e eSF f dA f S f S O y f S
yj+1
xi-1 xi xi+1
yj-1
y
ji
x
yj
NW
WW W
SW S SE
E EE
N NE
∆y
∆x
nw
s
nw neneP
sw se
e
yj+1
xi-1 xi xi+1
yj-1
y
ji
x
yj
NW
WW W
SW S SE
E EE
N NE
∆y
∆x
nw
s
nw neneP
sw se
e
Notation used for a Cartesian 2D and 3D grid.Image by MIT OpenCourseWare.
Interpolations and Differentiations
(to obtain fluxes “F ” as a function of cell-average values)e
• Upwind Interpolation (UDS) for convective fluxes
– Approximates by its value at the node upstream of e“e”. This is equivalent to using backward or forward-
difference approx for a first derivative (depends on
direction of flow) => Upwind Differencing
– This approximation never yields oscillatory solutions (boundedness criterion), but it is numerically diffusive:
• Taylor expansion about xP:
• UDS retains only first term: 1st order scheme in space
• Leading truncation error is “diffusive”, it has the form of a diffusive flux
• The numerical diffusion is (has 2 components when flow is oblique to the grid)2.29 Numerical Fluid Mechanics PFJL Lecture 16, 13
Scheme,
which is also called Donor-cell.
if . 0
if . 0P e
eE e
v n
v n
if . 0 if . 0 if . 0 v n if . 0 if . 0 if . 0
if . 0 if . 0
if . 0 if . 0 e if . 0 v n if . 0
if . 0 v n if . 0
if . 0 if . 0
if . 0 if . 0
2 2
22
( )( )2
e Pe P e P
P P
x xx x Rx x
ˆ. . . ...e e e P xe e eP
f v n f v n v n xx
UDS retains only first term: 1 order scheme in space
ˆ ˆ f v n f v n . f v n f v n . f v n f v n . f v n f v n . e P f v n f v n e P
f v n f v n f v n f v n e P f v n f v n e P e P f v n f v n e P
f v n f v n f v n f v n . f v n f v n . . f v n f v n . e P f v n f v n e P e P f v n f v n e P v n x v n x v n x v n x . v n x . . v n x .
.e
v n x
Leading truncation error is “diffusive”, it has the form of a diffusive
The numerical diffusion is (has 2 components when flow is oblique to the grid) The numerical diffusion is (has 2 components when flow is oblique to the grid) The numerical diffusion is (has 2 components when flow is oblique to the grid)The numerical diffusion is (has 2 components when flow is oblique to the grid)v n xThe numerical diffusion is (has 2 components when flow is oblique to the grid)The numerical diffusion is (has 2 components when flow is oblique to the grid) The numerical diffusion is (has 2 components when flow is oblique to the grid)v n xThe numerical diffusion is (has 2 components when flow is oblique to the grid) The numerical diffusion is (has 2 components when flow is oblique to the grid)The numerical diffusion is (has 2 components when flow is oblique to the grid) The numerical diffusion is (has 2 components when flow is oblique to the grid).The numerical diffusion is (has 2 components when flow is oblique to the grid) The numerical diffusion is (has 2 components when flow is oblique to the grid)v n xThe numerical diffusion is (has 2 components when flow is oblique to the grid) The numerical diffusion is (has 2 components when flow is oblique to the grid).The numerical diffusion is (has 2 components when flow is oblique to the grid) The numerical diffusion is (has 2 components when flow is oblique to the grid)The numerical diffusion is (has 2 components when flow is oblique to the grid)The numerical diffusion is (has 2 components when flow is oblique to the grid)The numerical diffusion is (has 2 components when flow is oblique to the grid)v n xThe numerical diffusion is (has 2 components when flow is oblique to the grid)The numerical diffusion is (has 2 components when flow is oblique to the grid)v n xThe numerical diffusion is (has 2 components when flow is oblique to the grid)
yj+1
xi-1 xi xi+1
yj-1
y
ji
x
yj
NW
WW W
SW S SE
E EE
N NE
∆y
∆x
nw
s
nw neneP
sw se
e
Notation used for a Cartesian 2D and 3D grid.Image by MIT OpenCourseWare.
PFJL Lecture 16, 14Numerical Fluid Mechanics2.29
Interpolations and Differentiations
(to obtain fluxes “Fe” as a function of cell-average values)
• Linear Interpolation (CDS) for convective fluxes
– Approximates e (value at face center) by its linear
interpolation between two nearest nodes:
• e is the interpolation factor
– This approx. is 2nd order accurate (for convective fluxes):
• Use Taylor exp. of E about xP to eliminate 1st derivative in Taylor exp. of e (previous slide)
• Truncation error is proportional to square of grid spacing, on uniform/non-uniform grids.
• As all approximations of order higher than one, this scheme can provide oscillatory
solutions
• Corresponds to central differences, hence its CDS name (gives avg. if uniform grid spacing)
(1 ) where e Pe E e P e e
E P
x xx x
2 2 22
22 2
2 2 2
2 22 2
( ) ( )( )2 2
( ) ( )( )( ) (1 ) '2 2
E P E P E PE P E P
P P E P E PP P
e P e P E ee P e P E e P e
P P P
x x x x Rx x Rx x x x x x x x
x x x x x xx x R Rx x x
yj+1
xi-1 xi xi+1
yj-1
y
ji
x
yj
NW
WW W
SW S SE
E EE
N NE
∆y
∆x
nw
s
nw neneP
sw se
e
Notation used for a Cartesian 2D and 3D grid.Image by MIT OpenCourseWare.
PFJL Lecture 16, 15Numerical Fluid Mechanics2.29
– Approximation is 2nd order accurate if e is midway between P and E (e.g. uniform
grid)
– When the grid is non-uniform, the formal accuracy is 1st order, but error reduction
when grid is refined is asymptotically 2nd order
Interpolations and Differentiations
(to obtain fluxes “Fe” as a function of cell-average values)
• Linear Interpolation (CDS) for diffusive fluxes
– Linear profile between two nearest nodes leads to simplest approx. of
gradient (diffusive fluxes)
– Taylor expansions of ’s around xe, one obtains:
2 2 2 3 3 3
32 3
( ) ( ) ( ) ( )2 ( ) 6 ( )
e P E e e P E ex
E P E Pe e
x x x x x x x x Rx x x x x x
E P
e E Px x x
(1 )E P
P
E P
x xx x
yj+1
xi-1 xi xi+1
yj-1
y
ji
x
yj
NW
WW W
SW S SE
E EE
N NE
∆y
∆x
nw
s
nw neneP
sw se
e
Notation used for a Cartesian 2D and 3D grid.Image by MIT OpenCourseWare.
PFJL Lecture 16, 16Numerical Fluid Mechanics2.29
– Coefficients in terms of nodal coordinates:
– Uniform grids: coefficients of ’s are 3/8 for node D, 6/8 for node U and -1/8 for node UU
– Somewhat more complex scheme than CDS (larger computational molecules by one node in
each direction)
– Approximation is 3nd order accurate on both uniform and non-uniform grids. For uniform grids:
• But, when this interpolation scheme is used with midpoint rule for surface integral, becomes 2nd order
Interpolations and Differentiations
(to obtain fluxes “Fe” as a function of cell-average values)
• Quadratic Upwind Interpolation (QUICK), convective fluxes
– Approx. by quadratic profile between two nearest nodes.
– In accord with convection, third point chosen on upstream side:
• i.e. chose W if flow is from P to E, or EE if flow from E to P.
This gives:
where D, U and UU denote the downstream, first upstream and second
upstream, respectively
3 3
33
6 3 1 38 8 8 48e U D UU
U
x Rx
1 2( ) ( )e U D U U UUg g
1 2( ) ( ) ( ) ( );( ) ( ) ( ) ( )
e U e UU e U D e
D U D UU U UU D UU
x x x x x x x xg gx x x x x x x x
yj+1
xi-1 xi xi+1
yj-1
y
ji
x
yj
NW
WW W
SW S SE
E EE
N NE
∆y
∆x
nw
s
nw neneP
sw se
e
Notation used for a Cartesian 2D and 3D grid.Image by MIT OpenCourseWare.
PFJL Lecture 16, 17Numerical Fluid Mechanics2.29
= Symmetric formula for e: no need for “upwind” as with 0th or 2nd order polynomials (donor-cell & QUICK)
– With (x), one can insert e= (xe) in symbolic integral formula. For a uniform Cartesian grid:
• Convective Fluxes: (similar formulas used for ϕ values at corners)
• For Diffusive Fluxes (1st derivative):
– This FV approximation often called a 4th-order CDS (linear poly. interpol. was 2nd-order CDS)
– Polynomials of higher-degree or of multi-dimensions can be used, as well as cubic splines (to
ensure continuity of first two derivatives at the boundaries). This increases the cost.
Interpolations and Differentiations(to obtain fluxes “Fe= f (e)” as a function of cell-average values)
• Higher Order Schemes (for convective/diffusive fluxes)
– Interpolations of order higher than 3 make sense if integrals are
yj+1
xi-1 xi xi+1
yj-1
y
ji
x
yj
NW
WW W
SW S SE
E EE
N NE
∆y
∆x
nw
s
nw neneP
sw se
ealso approximated with higher order formulas
– In 1D problems, if Simpson’s rule (4th order error) is used for the integral, a polynomial interpolation of order 3 can be used:
=> 4 unknowns, hence 4 nodal values (W, P, E and EE) needed
2 30 1 2 3( )x a a x a x a x
21 2 3
27 272 3 for a uniform Cartesian grid: 24
E P W EE
e e
a a x a xx x x
27 27 3 348
P E W EEe
( Note: higher-order,
approach 1 →≈ approach 2 ! )
Notation used for a Cartesian 2D and 3D grid.Image by MIT OpenCourseWare.
PFJL Lecture 16, 18Numerical Fluid Mechanics2.29
– Ex. 2: use a parabola, fit the values on either side of the cell face and the derivative on the
upstream side (equivalent to the QUICK scheme, 3rd order)
– Similar schemes are obtained for derivatives (diffusive fluxes), see Ferziger and Peric (2002)
• Other Schemes: more complex and difficult to program
– Large number of approximations used for “convective” fluxes: Linear Upwind Scheme,
Skewed Upwind schemes, Hybrid. Blending schemes to eliminate oscillations at higher order.
Interpolations and Differentiations(to obtain fluxes “Fe= f (e)” as a function of cell-average values)
• Compact Higher Order Schemes
– Polynomial of higher order lead too large computational
molecules => use deferred-correction schemes and/or
compact (Pade’) schemes
– Ex. 1: obtain the coefficients of by
yj+1
xi-1 xi xi+1
yj-1
y
ji
x
yj
NW
WW W
SW S SE
E EE
N NE
∆y
∆x
nw
s
nw neneP
sw se
e
fitting two values and two 1st derivatives at the two nodes on
either side of the cell face. With evaluation at xe:
• 4th order scheme:
• If we use CDS to approximate derivatives, result retains 4th order:
2 30 1 2 3( )x a a x a x a x
3 1 x+ 4 4 4e U D
Ux
4( )2 8
P Ee
P E
x O xx x
4( )2 16
P E P E W EEe O x
Notation used for a Cartesian 2D and 3D grid.Image by MIT OpenCourseWare.
MIT OpenCourseWarehttp://ocw.mit.edu
2.29 Numerical Fluid MechanicsSpring 2015
For information about citing these materials or our Terms of Use, visit: http://ocw.mit.edu/terms.