You are on page 1of 25

Lecture 17:

Flux Limiters
Implementation Issues
Boundary Conditions for Convection-
Diffusion Problems
Last Time…

z Developed a set of limiter functions


z Second order accurate
This Time…

z Examine physical rationale for limiter functions


z Application to unstructured meshes
z Examine how to implement higher-order schemes
z Complete discussion of boundary conditions
Recall Higher-Order Scheme for φe

z Consider finding face value using a second-order


scheme with the gradient found at the upwind cell:

∆x (φP − φW )
φe = φ P + Ψ (re )
2 ∆x

φE − φP
z Recall: re =
φP − φW

z What is the limiter function trying to do?


Limiter Functions

Ψ=2r
Physical Interpretation

z The value of r can be thought of as the ratio of two


gradients:
Downwind
φE − φP cell gradient
re =
φP − φW
Upwind cell gradient

z Limiter chooses gradient adaptively to avoid creating


extrema

ww
Case (a): Linear φ Variation

r=1 z Since:
φE − φP
r=
φP − φW

z If variation is a straight
line, on a uniform mesh,
r=1
z From our limiter function
range,Ψ=1 for r=1
z Can use either gradient
and get the right value at e
Case (b): 2>r>1

z r>1 means

(φE − φP ) > (φP − φW )

z If we used Ψ=1, we
would not create
overshoot
z In fact we can use Ψ
up to r and not create
φe > φ E
Case (b): 2>r>1 (Cont’d)

z Consider case when re >1, i.e., φ E − φ P > φ P − φW


z Say we choose the Ψ=re line
z When Ψ=re : φ = φ + Ψ (r ) ∆x (φP − φW )
∆x
e P e
2
( φE − φ P ) 1
= φP + (φP − φW )
(φP − φW ) 2
= φP +
( φE − φP )
2
1 1
= φP + φE
2 2
≤ φE
Case (b’): r>2

z Consider case when re >2, i.e., φ E − φ P > φ P − φW


z For re>2, say we choose the Ψ=2 line
∆x (φP − φW )
z When Ψ=2: φe = φP + Ψ (re )
2 ∆x
= φP + (φ P − φW )

= φP +
( φE − φP )
re
⎛ 1⎞ ⎛1⎞
= ⎜1 − ⎟ φP + ⎜ ⎟ φE
⎝ re ⎠ ⎝ re ⎠
≤ φE
Case (c): 0< r<1

z If r<1:

(φE − φP ) < (φP − φW )


Case (c): 0<r<1 (Cont’d)

z Consider case when 0<re <1, i.e.,φE − φP < φP − φW


z Say we choose Ψ=re
∆x (φP − φW )
z When Ψ=re : φe = φP + Ψ (re ) 2 ∆x
( φE − φ P ) 1
= φP + (φP − φW )
(φP − φW ) 2
= φP +
( φE − φP )
2
1 1
= φP + φE
2 2
≤ φE
Case (d): r<0

z When r<0, this implies


local extremum
z Our limiter has Ψ =0 for
r<0
z This implies

φe = φ P
Defaults to first
order upwind
scheme
Unstructured Meshes

z Find face value using:

φ f = φ0 + Ψ (rf )∆r0 f ⋅ ( ∇φ )0
z No easy way to define rf

U ∆r
0f f
∆r C1
01 C0 ∆r
01
Unstructured Meshes

• Create fictitious point U


•Find value at U by using
cell gradient
•Hence define rf

∆r
φ1 − φ0
U
0f f
rf = ∆r C1

− ( ∇φ )0 ⋅ ∆r0 f
01 C0 ∆r
01
Implementation Issues

z Higher order schemes lead to diagonal dominance


z Easiest way to implement higher order schemes is by
deferred corrections
z Any higher-order scheme can be written as
φHO = φUpwind + (φHO − φUpwind )
*

( )
*
φHO ,e = φP + φ HO ,e
− φP
z Put starred terms in b
z Coefficient matrix contains upwind coefficients
Implementation (Cont’d)

z For QUICK scheme, for example, the face convective


flux is given by:

Upwind
QUICK - Upwind

z Need to iterate just like in non-linear problems


Discrete Equation

z Here

z term Note extra


flow rate in aP

b = Sc ∆VP − Fe ∆φho
*
,e + Fw ∆ φ *
ho , w − Fn ∆ φ *
ho , n + Fs ∆ φ *
ho , s

Higher-order contribution –
needs iteration
Boundary Conditions: Inflow BC

z Consider a boundary where flow is entering the


domain
Inflow BC

z At the boundary, we have both convection and


diffusion:

Diffusion term
Known
same as for
values
Dirichlet BC
Outflow BC

z Flow points out of domain


z Typically we would not know φ on
the outflow boundary
» Value determined by what is
happening inside domain
z Ignore diffusion on outflow face
» Infinite face Peclet number
assumption
» Use first-order upwind scheme
z Other faces of near-boundary cell
treated like all other interior faces
Outflow BC (Cont’d)

z Set boundary diffusion flux to zero:

z Thus, boundary flux is:

z Using first-order upwind scheme:


When Can Outflow Condition be Used?

z Outflow bc cuts off domain from downstream locations


z Typically this is true only if convection dominates
diffusion
» Pef >>1
z Boundary should not cut through recirculation regions
Geometric Boundaries

z Typically “natural” boundaries of domain


» Walls
z On walls

» No convective flux
z Boundary flux has only diffusion:
z Can have Dirichlet/Neumann/mixed bc just as in pure
diffusion problems
Closure

In this lecture, we
z Considered the physical meaning of the limiter
function
z Saw that it was an adaptive way to choose either an
upwind or a downwind gradient to find face value
z Looked at difficulties in implementing for unstructured
meshes
z Looked at implementation issues

You might also like