+ All Categories
Home > Documents > Finite Volume Discretization MMVN05 - StrΓΆmningsteknikΒ Β· Convection-Diffusion problems in 1D W P...

Finite Volume Discretization MMVN05 - StrΓΆmningsteknikΒ Β· Convection-Diffusion problems in 1D W P...

Date post: 09-Sep-2019
Category:
Upload: others
View: 11 times
Download: 0 times
Share this document with a friend
46
Finite Volume Discretization MMVN05 ROBERT SZASZ
Transcript
Page 1: Finite Volume Discretization MMVN05 - StrΓΆmningsteknikΒ Β· Convection-Diffusion problems in 1D W P E w e Dx dx Pe d WP dx PE 𝑒 π‘’πœ™π‘’βˆ’ πœ™ =π·π‘’πœ™πΈβˆ’πœ™π‘ƒβˆ’π·

Finite Volume Discretization

MMVN05ROBERT SZASZ

Page 2: Finite Volume Discretization MMVN05 - StrΓΆmningsteknikΒ Β· Convection-Diffusion problems in 1D W P E w e Dx dx Pe d WP dx PE 𝑒 π‘’πœ™π‘’βˆ’ πœ™ =π·π‘’πœ™πΈβˆ’πœ™π‘ƒβˆ’π·

Goal & Outline

β€’ 1D Cartesian

– Diffusion

– Source

– Convection

– Time dependent

β€’ 2D Cartesian

β€’ 2D Unstructured

Partial Differential

Equation(s)

Set of Algebraic

Equations

Page 3: Finite Volume Discretization MMVN05 - StrΓΆmningsteknikΒ Β· Convection-Diffusion problems in 1D W P E w e Dx dx Pe d WP dx PE 𝑒 π‘’πœ™π‘’βˆ’ πœ™ =π·π‘’πœ™πΈβˆ’πœ™π‘ƒβˆ’π·

The Finite Volume Method

β€’ Generic transport equation

β€’ Integrate over a control volume

πœ•πœŒπœ™

πœ•π‘‘+ 𝑑𝑖𝑣 πœŒπ‘’ πœ™ = 𝑑𝑖𝑣 Ξ“π‘”π‘Ÿπ‘Žπ‘‘ πœ™ + 𝑆

Time

evolutionConvection Diffusion Source

term

𝑉

πœ•πœŒπœ™

πœ•π‘‘π‘‘π‘‰ +

𝑉

𝑑𝑖𝑣 πœŒπ‘’ πœ™ 𝑑𝑉 = 𝑉

𝑑𝑖𝑣 Ξ“π‘”π‘Ÿπ‘Žπ‘‘ πœ™ 𝑑𝑉 + 𝑉

𝑆 𝑑𝑉

Page 4: Finite Volume Discretization MMVN05 - StrΓΆmningsteknikΒ Β· Convection-Diffusion problems in 1D W P E w e Dx dx Pe d WP dx PE 𝑒 π‘’πœ™π‘’βˆ’ πœ™ =π·π‘’πœ™πΈβˆ’πœ™π‘ƒβˆ’π·

Discretization in 1D

Control volume boundaries

Control volume

P EWew

Dx

dxPe

dxPEdxWP

Page 5: Finite Volume Discretization MMVN05 - StrΓΆmningsteknikΒ Β· Convection-Diffusion problems in 1D W P E w e Dx dx Pe d WP dx PE 𝑒 π‘’πœ™π‘’βˆ’ πœ™ =π·π‘’πœ™πΈβˆ’πœ™π‘ƒβˆ’π·

Diffusion problems in 1D

𝑑𝑖𝑣 Ξ“π‘”π‘Ÿπ‘Žπ‘‘ πœ™ + 𝑆 = 0

𝑉

𝑑𝑖𝑣 Ξ“π‘”π‘Ÿπ‘Žπ‘‘ πœ™ 𝑑𝑉 + 𝑉

𝑆 𝑑𝑉 = 0

P EWew

DxdxPe

dxPEdxWP

𝐴

𝑛. Ξ“π‘”π‘Ÿπ‘Žπ‘‘ πœ™ 𝑑𝐴 + 𝑉

𝑆 𝑑𝑉 = 0

Ξ“π΄πœ•πœ™

πœ•π‘₯𝑒

βˆ’ Ξ“π΄πœ•πœ™

πœ•π‘₯𝑀

+ 𝑆𝑉 = 0

Ξ“π‘’π΄π‘’πœ•πœ™

πœ•π‘₯𝑒

βˆ’ Ξ“π‘€π΄π‘€πœ•πœ™

πœ•π‘₯𝑀

+ Su + Spπœ™P = 0

Linear approximation

Page 6: Finite Volume Discretization MMVN05 - StrΓΆmningsteknikΒ Β· Convection-Diffusion problems in 1D W P E w e Dx dx Pe d WP dx PE 𝑒 π‘’πœ™π‘’βˆ’ πœ™ =π·π‘’πœ™πΈβˆ’πœ™π‘ƒβˆ’π·

Diffusion problems in 1D

P EWew

DxdxPe

dxPEdxWP

Ξ“π‘’π΄π‘’πœ•πœ™

πœ•π‘₯𝑒

βˆ’ Ξ“π‘€π΄π‘€πœ•πœ™

πœ•π‘₯𝑀

+ Su + Spπœ™P = 0

πœ™π‘ƒΞ“π‘’π΄π‘’π›Ώπ‘₯𝑃𝐸

+Γ𝑀𝐴𝑀𝛿π‘₯π‘Šπ‘ƒ

βˆ’ 𝑆𝑃 = πœ™π‘ŠΞ“π‘€π΄π‘€π›Ώπ‘₯π‘Šπ‘ƒ

+ πœ™πΈΞ“π‘’π΄π‘’π›Ώπ‘₯𝑃𝐸

+ 𝑆𝑒

Γ𝑒 =Ξ“π‘Š+Γ𝑃

2, Γ𝑀 =

Γ𝐸+Γ𝑃

2, πœ•πœ™

πœ•π‘₯ 𝑒=πœ™πΈβˆ’πœ™π‘ƒ

𝛿π‘₯𝑃𝐸, πœ•πœ™

πœ•π‘₯ 𝑀=πœ™π‘ƒβˆ’πœ™π‘Š

𝛿π‘₯π‘Šπ‘ƒ

These are usually stored

πœ™π‘ƒπ‘Žπ‘ƒ = πœ™π‘Šπ‘Žπ‘Š + πœ™πΈπ‘ŽπΈ + 𝑆𝑒

Page 7: Finite Volume Discretization MMVN05 - StrΓΆmningsteknikΒ Β· Convection-Diffusion problems in 1D W P E w e Dx dx Pe d WP dx PE 𝑒 π‘’πœ™π‘’βˆ’ πœ™ =π·π‘’πœ™πΈβˆ’πœ™π‘ƒβˆ’π·

Boundaries

P Eew

DxdxPe

dxPE

Case 1: is knownπœ™π‘€ = 𝐹𝑀

Ξ“π‘’π΄π‘’πœ•πœ™

πœ•π‘₯𝑒

βˆ’ Ξ“π‘€π΄π‘€πœ•πœ™

πœ•π‘₯𝑀

+ Su + Spπœ™P = 0

πœ•πœ™

πœ•π‘₯𝑀

=πœ™π‘ƒ βˆ’ 𝐹𝑀𝛿π‘₯𝑀𝑃

Case 2: is known

Eastern boundary similarly

πœ•πœ™

πœ•π‘₯𝑀

= 𝐺𝑀

πœ™π‘ƒπ‘Žπ‘ƒ = πœ™πΈπ‘ŽπΈ + 𝑆𝑒

Page 8: Finite Volume Discretization MMVN05 - StrΓΆmningsteknikΒ Β· Convection-Diffusion problems in 1D W P E w e Dx dx Pe d WP dx PE 𝑒 π‘’πœ™π‘’βˆ’ πœ™ =π·π‘’πœ™πΈβˆ’πœ™π‘ƒβˆ’π·

Building the system of equations

1 2 N

πœ™π‘ƒπ‘Žπ‘ƒ = πœ™π‘Šπ‘Žπ‘Š + πœ™πΈπ‘ŽπΈ + 𝑆𝑒

πœ™1π‘Ž1,1 = πœ™2π‘Ž2,1 + 𝑆1

3

Page 9: Finite Volume Discretization MMVN05 - StrΓΆmningsteknikΒ Β· Convection-Diffusion problems in 1D W P E w e Dx dx Pe d WP dx PE 𝑒 π‘’πœ™π‘’βˆ’ πœ™ =π·π‘’πœ™πΈβˆ’πœ™π‘ƒβˆ’π·

Building the system of equations

1 2 N

πœ™π‘ƒπ‘Žπ‘ƒ = πœ™π‘Šπ‘Žπ‘Š + πœ™πΈπ‘ŽπΈ + 𝑆𝑒

πœ™1π‘Ž1,1 = πœ™2π‘Ž2,1 + 𝑆1

πœ™2π‘Ž2,2 = πœ™1π‘Ž1,2 + πœ™3π‘Ž3,2 + 𝑆2

3

Page 10: Finite Volume Discretization MMVN05 - StrΓΆmningsteknikΒ Β· Convection-Diffusion problems in 1D W P E w e Dx dx Pe d WP dx PE 𝑒 π‘’πœ™π‘’βˆ’ πœ™ =π·π‘’πœ™πΈβˆ’πœ™π‘ƒβˆ’π·

Building the system of equations

1 2 N

πœ™π‘ƒπ‘Žπ‘ƒ = πœ™π‘Šπ‘Žπ‘Š + πœ™πΈπ‘ŽπΈ + 𝑆𝑒

πœ™1π‘Ž1,1 = πœ™2π‘Ž2,1 + 𝑆1

πœ™2π‘Ž2,2 = πœ™1π‘Ž1,2 + πœ™3π‘Ž3,2 + 𝑆2

3

πœ™3π‘Ž3,3 = πœ™2π‘Ž2,3 + πœ™4π‘Ž4,3 + 𝑆3

Page 11: Finite Volume Discretization MMVN05 - StrΓΆmningsteknikΒ Β· Convection-Diffusion problems in 1D W P E w e Dx dx Pe d WP dx PE 𝑒 π‘’πœ™π‘’βˆ’ πœ™ =π·π‘’πœ™πΈβˆ’πœ™π‘ƒβˆ’π·

Building the system of equations

1 2 N

πœ™π‘ƒπ‘Žπ‘ƒ = πœ™π‘Šπ‘Žπ‘Š + πœ™πΈπ‘ŽπΈ + 𝑆𝑒

πœ™1π‘Ž1,1 = πœ™2π‘Ž2,1 + 𝑆1

πœ™2π‘Ž2,2 = πœ™1π‘Ž1,2 + πœ™3π‘Ž3,2 + 𝑆2

3

πœ™3π‘Ž3,3 = πœ™2π‘Ž2,3 + πœ™4π‘Ž4,3 + 𝑆3

πœ™π‘π‘Žπ‘,𝑁 = πœ™π‘βˆ’1π‘Žπ‘βˆ’1,𝑁 + 𝑆𝑁

Page 12: Finite Volume Discretization MMVN05 - StrΓΆmningsteknikΒ Β· Convection-Diffusion problems in 1D W P E w e Dx dx Pe d WP dx PE 𝑒 π‘’πœ™π‘’βˆ’ πœ™ =π·π‘’πœ™πΈβˆ’πœ™π‘ƒβˆ’π·

Convection-Diffusion problems in 1D

𝑑𝑖𝑣 πœŒπ‘’ πœ™ = 𝑑𝑖𝑣 Ξ“π‘”π‘Ÿπ‘Žπ‘‘ πœ™

𝑉

𝑑𝑖𝑣 πœŒπ‘’ πœ™ 𝑑𝑉 = 𝑉

𝑑𝑖𝑣 Ξ“π‘”π‘Ÿπ‘Žπ‘‘ πœ™ 𝑑𝑉

𝐴

𝑛. πœŒπœ™π‘’ 𝑑𝐴 = 𝐴

𝑛. Ξ“π‘”π‘Ÿπ‘Žπ‘‘ πœ™ 𝑑𝐴

P EWew

DxdxPe

dxPEdxWP

𝑒𝑒𝑒𝑀

(source terms not considered for simplicity)

πœŒπ‘’π΄πœ™ 𝑒 βˆ’ πœŒπ‘’π΄πœ™ 𝑀 = Ξ“π΄πœ•πœ™

πœ•π‘₯𝑒

βˆ’ Ξ“π΄πœ•πœ™

πœ•π‘₯𝑀

Assume Ae=Aw=A and denote fluxes as:

𝐹𝑀 = πœŒπ‘’ 𝑀 𝐹𝑒 = πœŒπ‘’ 𝑒 𝐷𝑀 =Γ𝑀𝛿π‘₯π‘Šπ‘ƒ

𝐷𝑒=Γ𝑒𝛿π‘₯𝑃𝐸

πΉπ‘’πœ™π‘’ βˆ’ πΉπ‘€πœ™π‘€ = 𝐷𝑒 πœ™πΈ βˆ’ πœ™π‘ƒ βˆ’ 𝐷𝑀(πœ™π‘ƒ βˆ’ πœ™π‘Š)

Page 13: Finite Volume Discretization MMVN05 - StrΓΆmningsteknikΒ Β· Convection-Diffusion problems in 1D W P E w e Dx dx Pe d WP dx PE 𝑒 π‘’πœ™π‘’βˆ’ πœ™ =π·π‘’πœ™πΈβˆ’πœ™π‘ƒβˆ’π·

Convection-Diffusion problems in 1D

πœ•(πœŒπ‘’)

πœ•π‘₯= 0

The continuity equation must be also fullfilled:

P EWew

DxdxPe

dxPEdxWP

𝑒𝑒𝑒𝑀

πœŒπ‘’π΄ 𝑒 βˆ’ πœŒπ‘’π΄ 𝑀 = 0

𝐹𝑒 βˆ’ 𝐹𝑀 = 0

Page 14: Finite Volume Discretization MMVN05 - StrΓΆmningsteknikΒ Β· Convection-Diffusion problems in 1D W P E w e Dx dx Pe d WP dx PE 𝑒 π‘’πœ™π‘’βˆ’ πœ™ =π·π‘’πœ™πΈβˆ’πœ™π‘ƒβˆ’π·

Convection-Diffusion problems in 1D

P EWew

DxdxPe

dxPEdxWP

𝑒𝑒𝑒𝑀

πΉπ‘’πœ™π‘’ βˆ’ πΉπ‘€πœ™π‘€= 𝐷𝑒 πœ™πΈ βˆ’ πœ™π‘ƒ βˆ’ 𝐷𝑀(πœ™π‘ƒ βˆ’ πœ™π‘Š)

How to estimate fe, fw?

Central difference scheme:πœ™π‘’ =

πœ™π‘ƒ + πœ™πΈ2

πœ™π‘€ =πœ™π‘Š + πœ™π‘ƒ

2

𝐷𝑀 +𝐹𝑀2+ 𝐷𝑒 βˆ’

𝐹𝑒2πœ™π‘ƒ = 𝐷𝑀 +

𝐹𝑀2πœ™π‘Š + 𝐷𝑒 βˆ’

𝐹𝑒2πœ™πΈ

π‘Žπ‘ƒπœ™π‘ƒ = π‘Žπ‘Šπœ™π‘Š + π‘ŽπΈπœ™πΈ

Page 15: Finite Volume Discretization MMVN05 - StrΓΆmningsteknikΒ Β· Convection-Diffusion problems in 1D W P E w e Dx dx Pe d WP dx PE 𝑒 π‘’πœ™π‘’βˆ’ πœ™ =π·π‘’πœ™πΈβˆ’πœ™π‘ƒβˆ’π·

Fig. 5.4. N=5, u=0.1 m/s, F=0.1, D=0.5 Fig.5.5. N=5, u=2.5 m/s, F=2.5, D=0.5

Fig.5.6. N=20, u=2.5 m/s, F=2.5, D=2.0

WHY?

Page 16: Finite Volume Discretization MMVN05 - StrΓΆmningsteknikΒ Β· Convection-Diffusion problems in 1D W P E w e Dx dx Pe d WP dx PE 𝑒 π‘’πœ™π‘’βˆ’ πœ™ =π·π‘’πœ™πΈβˆ’πœ™π‘ƒβˆ’π·

Properties of discretization schemes

β€’ Conservativeness

– Estimate the fluxes in a consistent manner!

Fig.5.7

Fig.5.8

Page 17: Finite Volume Discretization MMVN05 - StrΓΆmningsteknikΒ Β· Convection-Diffusion problems in 1D W P E w e Dx dx Pe d WP dx PE 𝑒 π‘’πœ™π‘’βˆ’ πœ™ =π·π‘’πœ™πΈβˆ’πœ™π‘ƒβˆ’π·

Properties of discretization schemes

β€’ Boundedness

– In the absence of sources, the value of a property

should be bounded by its boundary values

– Requirements:

Β» All coefficients the same sign

Β»βˆ‘ π‘Žπ‘›π‘

π‘Žπ‘β€²β‰€ 1 π‘Žπ‘‘ π‘Žπ‘™π‘™ π‘›π‘œπ‘‘π‘’π‘ , < 1 π‘Žπ‘‘ π‘œπ‘›π‘’ π‘›π‘œπ‘‘π‘’ π‘Žπ‘‘ π‘™π‘’π‘Žπ‘ π‘‘

Page 18: Finite Volume Discretization MMVN05 - StrΓΆmningsteknikΒ Β· Convection-Diffusion problems in 1D W P E w e Dx dx Pe d WP dx PE 𝑒 π‘’πœ™π‘’βˆ’ πœ™ =π·π‘’πœ™πΈβˆ’πœ™π‘ƒβˆ’π·

Properties of discretization schemes

β€’ Transportiveness

– Where is the information transported?

Fig.5.9

Page 19: Finite Volume Discretization MMVN05 - StrΓΆmningsteknikΒ Β· Convection-Diffusion problems in 1D W P E w e Dx dx Pe d WP dx PE 𝑒 π‘’πœ™π‘’βˆ’ πœ™ =π·π‘’πœ™πΈβˆ’πœ™π‘ƒβˆ’π·

Assessment of the central differencing

scheme

β€’ Conservativeness: OK

β€’ Boundedness:

ae<0 for Pee=Fe/De>2 !!!

β€’ Transportiveness: Not OK!

β€’ Accuracy: 2nd order

𝐷𝑀 +𝐹𝑀2+ 𝐷𝑒 βˆ’

𝐹𝑒2πœ™π‘ƒ = 𝐷𝑀 +

𝐹𝑀2πœ™π‘Š + 𝐷𝑒 βˆ’

𝐹𝑒2πœ™πΈ

Page 20: Finite Volume Discretization MMVN05 - StrΓΆmningsteknikΒ Β· Convection-Diffusion problems in 1D W P E w e Dx dx Pe d WP dx PE 𝑒 π‘’πœ™π‘’βˆ’ πœ™ =π·π‘’πœ™πΈβˆ’πœ™π‘ƒβˆ’π·

Upwind differencing scheme

β€’ Compute the convective term depending on the flow

direction:

P EWew

DxdxPe

dxPEdxWP

𝑒𝑒𝑒𝑀

πœ™π‘’ = πœ™π‘ƒ πœ™π‘€= πœ™π‘Š

P EWew

DxdxPe

dxPEdxWP

𝑒𝑒𝑒𝑀

πœ™π‘’ = πœ™πΈ πœ™π‘€= πœ™π‘ƒ

Page 21: Finite Volume Discretization MMVN05 - StrΓΆmningsteknikΒ Β· Convection-Diffusion problems in 1D W P E w e Dx dx Pe d WP dx PE 𝑒 π‘’πœ™π‘’βˆ’ πœ™ =π·π‘’πœ™πΈβˆ’πœ™π‘ƒβˆ’π·

Upwind differencing scheme

β€’ Assessment:

– Conservativeness: OK

– Boundedness: OK

– Transportiveness: OK

– Accuracy: 1st order

Fig.5.15

Page 22: Finite Volume Discretization MMVN05 - StrΓΆmningsteknikΒ Β· Convection-Diffusion problems in 1D W P E w e Dx dx Pe d WP dx PE 𝑒 π‘’πœ™π‘’βˆ’ πœ™ =π·π‘’πœ™πΈβˆ’πœ™π‘ƒβˆ’π·

Hybrid differencing scheme

β€’ Combine schemes:

– Central for Pe=F/D < 2

– Upwind for Pe > 2

β€’ Assessment:

– Conservativeness: OK

– Boundedness: OK

– Transportiveness: OK

– Accuracy: 1st order

Page 23: Finite Volume Discretization MMVN05 - StrΓΆmningsteknikΒ Β· Convection-Diffusion problems in 1D W P E w e Dx dx Pe d WP dx PE 𝑒 π‘’πœ™π‘’βˆ’ πœ™ =π·π‘’πœ™πΈβˆ’πœ™π‘ƒβˆ’π·

Power-law scheme

β€’ More accurate than hybrid

β€’ Diffusion set to 0 for Pe>10

β€’ For Pe < 10 polynomial expression is used to evaluate

the fluxes

Page 24: Finite Volume Discretization MMVN05 - StrΓΆmningsteknikΒ Β· Convection-Diffusion problems in 1D W P E w e Dx dx Pe d WP dx PE 𝑒 π‘’πœ™π‘’βˆ’ πœ™ =π·π‘’πœ™πΈβˆ’πœ™π‘ƒβˆ’π·

The QUICK scheme

β€’ Quadratic Upstream Interpolation for Convective Kinetics

β€’ Higher order & Upwind

β€’ Face values of f obtained from quadratic functions

β€’ Diffusion terms can be evaluated from the gradient

of the parabola

β€’ For uw>0

β€’ For ue>0

πœ™π‘€ =6

8πœ™π‘Š +

3

8πœ™π‘ƒ βˆ’

1

8πœ™π‘Šπ‘Š

πœ™π‘’ =6

8πœ™π‘ƒ +

3

8πœ™πΈ βˆ’

1

8πœ™π‘Š

Fig.5.17

Page 25: Finite Volume Discretization MMVN05 - StrΓΆmningsteknikΒ Β· Convection-Diffusion problems in 1D W P E w e Dx dx Pe d WP dx PE 𝑒 π‘’πœ™π‘’βˆ’ πœ™ =π·π‘’πœ™πΈβˆ’πœ™π‘ƒβˆ’π·

The QUICK scheme

β€’ Generic form:

β€’ Issues at boundaries: no second neighbours

– Create virtual β€˜mirror nodes’ by linear extrapolation

π‘Žπ‘ƒπœ™π‘ƒ = π‘Žπ‘Šπœ™π‘Š + π‘ŽπΈπœ™πΈ + π‘Žπ‘Šπ‘Šπœ™π‘Šπ‘Š + π‘ŽπΈπΈπœ™πΈπΈ

Fig.5.18

Page 26: Finite Volume Discretization MMVN05 - StrΓΆmningsteknikΒ Β· Convection-Diffusion problems in 1D W P E w e Dx dx Pe d WP dx PE 𝑒 π‘’πœ™π‘’βˆ’ πœ™ =π·π‘’πœ™πΈβˆ’πœ™π‘ƒβˆ’π·

The QUICK scheme

β€’ Assessment

– Conservativeness: OK

– Boundedness:

Β» Only conditionnaly stable!

– Reformulated versions

to improve stability

– Transportiveness: OK

– Accuracy: better formal

accuracy than upwind

– Possible over/undershoots

Fig.5.20

Page 27: Finite Volume Discretization MMVN05 - StrΓΆmningsteknikΒ Β· Convection-Diffusion problems in 1D W P E w e Dx dx Pe d WP dx PE 𝑒 π‘’πœ™π‘’βˆ’ πœ™ =π·π‘’πœ™πΈβˆ’πœ™π‘ƒβˆ’π·

General upwind-biased schemes

β€’ β€˜Pure’ upwind:

β€’ Linear upwind differencing:

β€’ QUICK:

β€’ Central differencing:

β€’ General:

πœ™π‘’ = πœ™π‘ƒ

πœ™π‘’ = πœ™π‘ƒ +1

2(πœ™π‘ƒ βˆ’ πœ™π‘Š)

πœ™π‘’ = πœ™π‘ƒ +1

8(3πœ™πΈ βˆ’ 2πœ™π‘ƒ βˆ’ πœ™π‘Š)

πœ™π‘’ = πœ™π‘ƒ +1

2(πœ™πΈ βˆ’ πœ™π‘ƒ)

πœ™π‘’ = πœ™π‘ƒ +1

2πœ“(πœ™πΈ βˆ’ πœ™π‘ƒ)

Page 28: Finite Volume Discretization MMVN05 - StrΓΆmningsteknikΒ Β· Convection-Diffusion problems in 1D W P E w e Dx dx Pe d WP dx PE 𝑒 π‘’πœ™π‘’βˆ’ πœ™ =π·π‘’πœ™πΈβˆ’πœ™π‘ƒβˆ’π·

General upwind-biased schemes

β€’ UD

β€’ CD

β€’ LUD

β€’ QUICKπœ™π‘’ = πœ™π‘ƒ +

1

2πœ“(πœ™πΈ βˆ’ πœ™π‘ƒ)

πœ“ = πœ“(π‘Ÿ)

π‘Ÿ =πœ™π‘ƒ βˆ’ πœ™π‘Šπœ™πΈ βˆ’ πœ™π‘ƒ

πœ“ π‘Ÿ = 0

πœ“ π‘Ÿ = 1

πœ“ π‘Ÿ = π‘Ÿ

πœ“ π‘Ÿ = (3 + π‘Ÿ)/4

Fig.5.21

Page 29: Finite Volume Discretization MMVN05 - StrΓΆmningsteknikΒ Β· Convection-Diffusion problems in 1D W P E w e Dx dx Pe d WP dx PE 𝑒 π‘’πœ™π‘’βˆ’ πœ™ =π·π‘’πœ™πΈβˆ’πœ™π‘ƒβˆ’π·

TVD schemes

β€’ Total Variation Diminishing

β€’ Criteria:

– Upper limit for TVD:

f1

f2

f3

f4

f5

𝑇𝑉 πœ™= πœ™2 βˆ’ πœ™1 + πœ™3 βˆ’ πœ™2+ πœ™4 βˆ’ πœ™3 + |πœ™5 βˆ’ πœ™4|

Fig.5.23

πœ“ π‘Ÿ ≀ 2π‘Ÿ π‘Ÿ ≀ 1

πœ“ π‘Ÿ ≀ 2 π‘Ÿ > 1

Page 30: Finite Volume Discretization MMVN05 - StrΓΆmningsteknikΒ Β· Convection-Diffusion problems in 1D W P E w e Dx dx Pe d WP dx PE 𝑒 π‘’πœ™π‘’βˆ’ πœ™ =π·π‘’πœ™πΈβˆ’πœ™π‘ƒβˆ’π·

TVD

β€’ For second order:

– Must go through (1,1)

– Limited by CD and LUD

β€’ To treat forward and

backward differencing

consistently: symmetry

property:

β€’ Flux limiters

πœ“ π‘Ÿ

r= πœ“(1/π‘Ÿ)

Fig.5.24

Fig.5.25

Page 31: Finite Volume Discretization MMVN05 - StrΓΆmningsteknikΒ Β· Convection-Diffusion problems in 1D W P E w e Dx dx Pe d WP dx PE 𝑒 π‘’πœ™π‘’βˆ’ πœ™ =π·π‘’πœ™πΈβˆ’πœ™π‘ƒβˆ’π·

Unsteady flows

πœ•πœŒπœ™

πœ•π‘‘+ 𝑑𝑖𝑣 πœŒπ‘’ πœ™ = 𝑑𝑖𝑣 Ξ“π‘”π‘Ÿπ‘Žπ‘‘ πœ™ + 𝑆

𝑉

πœ•πœŒπœ™

πœ•π‘‘π‘‘π‘‰ +

𝑉

𝑑𝑖𝑣 πœŒπ‘’ πœ™ 𝑑𝑉 = 𝑉

𝑑𝑖𝑣 Ξ“π‘”π‘Ÿπ‘Žπ‘‘ πœ™ 𝑑𝑉 + 𝑉

𝑆 𝑑𝑉

𝑑

𝑑+Δ𝑑

𝑉

πœ•πœŒπœ™

πœ•π‘‘π‘‘π‘‰π‘‘π‘‘ +

𝑑

𝑑+Δ𝑑

𝑉

𝑑𝑖𝑣 πœŒπ‘’ πœ™ 𝑑𝑉 𝑑𝑑

= 𝑑

𝑑+Δ𝑑

𝑉

𝑑𝑖𝑣 Ξ“π‘”π‘Ÿπ‘Žπ‘‘ πœ™ 𝑑𝑉 𝑑𝑑 + 𝑑

𝑑+Δ𝑑

𝑉

𝑆 𝑑𝑉𝑑𝑑

Page 32: Finite Volume Discretization MMVN05 - StrΓΆmningsteknikΒ Β· Convection-Diffusion problems in 1D W P E w e Dx dx Pe d WP dx PE 𝑒 π‘’πœ™π‘’βˆ’ πœ™ =π·π‘’πœ™πΈβˆ’πœ™π‘ƒβˆ’π·

Unsteady 1D heat conduction

β€’ c – specific heat [J/(kg K)]

πœŒπ‘πœ•π‘‡

πœ•π‘‘=πœ•

πœ•π‘₯π‘˜πœ•π‘‡

πœ•π‘₯+ 𝑆

P EWew

DxdxPe

dxPEdxWP

𝑑

𝑑+Δ𝑑

𝑉

πœŒπ‘πœ•π‘‡

πœ•π‘‘π‘‘π‘‰π‘‘π‘‘ =

𝑑

𝑑+Δ𝑑

𝑉

πœ•

πœ•π‘₯π‘˜πœ•π‘‡

πœ•π‘₯𝑑𝑉𝑑𝑑 +

𝑑

𝑑+Δ𝑑

𝑉

𝑆𝑑𝑉𝑑𝑑

𝑉

𝑑

𝑑+Δ𝑑

πœŒπ‘πœ•π‘‡

πœ•π‘‘π‘‘π‘‘π‘‘π‘‰ =

𝑑

𝑑+Δ𝑑

π‘˜π΄πœ•π‘‡

πœ•π‘₯𝑒

βˆ’ π‘˜π΄πœ•π‘‡

πœ•π‘₯𝑀

𝑑𝑑 + 𝑑

𝑑+Δ𝑑

𝑆Δ𝑉𝑑𝑑

Page 33: Finite Volume Discretization MMVN05 - StrΓΆmningsteknikΒ Β· Convection-Diffusion problems in 1D W P E w e Dx dx Pe d WP dx PE 𝑒 π‘’πœ™π‘’βˆ’ πœ™ =π·π‘’πœ™πΈβˆ’πœ™π‘ƒβˆ’π·

Unsteady 1D heat conduction

𝑉

𝑑

𝑑+Δ𝑑

πœŒπ‘πœ•π‘‡

πœ•π‘‘π‘‘π‘‘π‘‘π‘‰ =

𝑑

𝑑+Δ𝑑

π‘˜π΄πœ•π‘‡

πœ•π‘₯𝑒

βˆ’ π‘˜π΄πœ•π‘‡

πœ•π‘₯𝑀

𝑑𝑑 + 𝑑

𝑑+Δ𝑑

𝑆Δ𝑉𝑑𝑑

πœŒπ‘ 𝑇𝑃 βˆ’ 𝑇𝑃0 Ξ”V =

𝑑

𝑑+Δ𝑑

π‘˜π΄π‘‡πΈ βˆ’ 𝑇𝑃𝛿π‘₯𝑃𝐸

βˆ’ π‘˜π΄π‘‡π‘ƒ βˆ’ π‘‡π‘Šπ›Ώπ‘₯π‘Šπ‘ƒ

𝑑𝑑 + 𝑑

𝑑+Δ𝑑

𝑆Δ𝑉𝑑𝑑

Assume uniform T

In control volume

and use backward

differencing

Use central

differencing

How do TE,TW and TP vary in time? Assume

a linear function:@ t+Dt @ t

𝐼𝑇 = 𝑑

𝑑+Δ𝑑

𝑇𝑑𝑑 = πœƒπ‘‡ + 1 βˆ’ πœƒ 𝑇0 Δ𝑑

Page 34: Finite Volume Discretization MMVN05 - StrΓΆmningsteknikΒ Β· Convection-Diffusion problems in 1D W P E w e Dx dx Pe d WP dx PE 𝑒 π‘’πœ™π‘’βˆ’ πœ™ =π·π‘’πœ™πΈβˆ’πœ™π‘ƒβˆ’π·

Unsteady 1D heat conduction

πœŒπ‘ 𝑇𝑃 βˆ’ 𝑇𝑃0 Ξ”V =

𝑑

𝑑+Δ𝑑

π‘˜π΄π‘‡πΈ βˆ’ 𝑇𝑃𝛿π‘₯𝑃𝐸

βˆ’ π‘˜π΄π‘‡π‘ƒ βˆ’ π‘‡π‘Šπ›Ώπ‘₯π‘Šπ‘ƒ

𝑑𝑑 + 𝑑

𝑑+Δ𝑑

𝑆Δ𝑉𝑑𝑑

Divide by A and Dt:

πœŒπ‘ 𝑇𝑃 βˆ’ 𝑇𝑃0Ξ”π‘₯

Δ𝑑

= πœƒ π‘˜π‘‡πΈ βˆ’ 𝑇𝑃𝛿π‘₯𝑃𝐸

βˆ’ π‘˜π‘‡π‘ƒ βˆ’ π‘‡π‘Šπ›Ώπ‘₯π‘Šπ‘ƒ

+ (1 βˆ’ πœƒ) π‘˜π‘‡πΈ0 βˆ’ 𝑇𝑃

0

𝛿π‘₯π‘ƒπΈβˆ’ π‘˜

𝑇𝑃0 βˆ’ π‘‡π‘Š

0

𝛿π‘₯π‘Šπ‘ƒ+ 𝑆Δπ‘₯

π‘Žπ‘ƒπ‘‡π‘ƒ= π‘Žπ‘Š πœƒπ‘‡π‘Š + 1 βˆ’ πœƒ π‘‡π‘Š

0 + π‘ŽπΈ πœƒπ‘‡πΈ + 1 βˆ’ πœƒ 𝑇𝐸0

+ π‘Žπ‘ƒ0 βˆ’ 1 βˆ’ πœƒ π‘Žπ‘Š βˆ’ 1 βˆ’ πœƒ π‘ŽπΈ 𝑇𝑃

0 + 𝑏

Page 35: Finite Volume Discretization MMVN05 - StrΓΆmningsteknikΒ Β· Convection-Diffusion problems in 1D W P E w e Dx dx Pe d WP dx PE 𝑒 π‘’πœ™π‘’βˆ’ πœ™ =π·π‘’πœ™πΈβˆ’πœ™π‘ƒβˆ’π·

Explicit scheme

πœƒ = 0

π‘Žπ‘ƒπ‘‡π‘ƒ = π‘Žπ‘Šπ‘‡π‘Š0 + π‘ŽπΈπ‘‡πΈ

0 + π‘Žπ‘ƒ0 βˆ’ π‘Žπ‘Š βˆ’ π‘ŽπΈ + 𝑆𝑃 𝑇𝑃

0 + 𝑆𝑒

TP can be directly computed

First order

Can be negative! To assure stability:

Δ𝑑 < πœŒπ‘Ξ”π‘₯ 2

2π‘˜

Very small timesteps when the grid is refined!

Page 36: Finite Volume Discretization MMVN05 - StrΓΆmningsteknikΒ Β· Convection-Diffusion problems in 1D W P E w e Dx dx Pe d WP dx PE 𝑒 π‘’πœ™π‘’βˆ’ πœ™ =π·π‘’πœ™πΈβˆ’πœ™π‘ƒβˆ’π·

Implicit scheme

πœƒ = 1

π‘Žπ‘ƒπ‘‡π‘ƒ = π‘Žπ‘Šπ‘‡π‘Š + π‘ŽπΈπ‘‡πΈ + π‘Žπ‘ƒ0𝑇𝑃0 + 𝑆𝑒

Several unknowns -> System of equations

Unconditionally stable

First order

Page 37: Finite Volume Discretization MMVN05 - StrΓΆmningsteknikΒ Β· Convection-Diffusion problems in 1D W P E w e Dx dx Pe d WP dx PE 𝑒 π‘’πœ™π‘’βˆ’ πœ™ =π·π‘’πœ™πΈβˆ’πœ™π‘ƒβˆ’π·

Crank-Nicolson scheme

πœƒ =1

2

π‘Žπ‘ƒπ‘‡π‘ƒ = π‘Žπ‘Šπ‘‡π‘Š + π‘‡π‘Š

0

2+ π‘ŽπΈ

𝑇𝐸 + 𝑇𝐸0

2+ π‘Žπ‘ƒ

0 βˆ’π‘Žπ‘Š2βˆ’π‘ŽπΈ2+𝑆𝑃2𝑇𝑃0 + 𝑆𝑒

System of equations

To assure stability:

Δ𝑑 < πœŒπ‘Ξ”π‘₯ 2

π‘˜

Very small timesteps when the grid is refined!

Second order

Page 38: Finite Volume Discretization MMVN05 - StrΓΆmningsteknikΒ Β· Convection-Diffusion problems in 1D W P E w e Dx dx Pe d WP dx PE 𝑒 π‘’πœ™π‘’βˆ’ πœ™ =π·π‘’πœ™πΈβˆ’πœ™π‘ƒβˆ’π·

Unsteady 1D convection-diffusion

β€’ Similarly to unsteady diffusion

β€’ Additional stability limits due to convection

πœ•πœŒπœ™

πœ•π‘‘+πœ•πœŒπ‘’πœ™

πœ•π‘₯=πœ•

πœ•π‘₯Ξ“πœ•πœ™

πœ•π‘₯+ 𝑆

Page 39: Finite Volume Discretization MMVN05 - StrΓΆmningsteknikΒ Β· Convection-Diffusion problems in 1D W P E w e Dx dx Pe d WP dx PE 𝑒 π‘’πœ™π‘’βˆ’ πœ™ =π·π‘’πœ™πΈβˆ’πœ™π‘ƒβˆ’π·

Finite volume method for 2D Cartesian

grids

β€’ E.g. diffusion problem:

Fig.4.12

πœ•

πœ•π‘₯Ξ“πœ•πœ™

πœ•π‘₯+πœ•

πœ•π‘¦Ξ“πœ•πœ™

πœ•π‘¦+ 𝑆 = 0

Δ𝑉

πœ•

πœ•π‘₯Ξ“πœ•πœ™

πœ•π‘₯𝑑𝑉 +

Δ𝑉

πœ•

πœ•π‘¦Ξ“πœ•πœ™

πœ•π‘¦π‘‘π‘‰

+ Δ𝑉

𝑆𝑑𝑉 = 0

Ξ“π‘’π΄π‘’πœ™πΈ βˆ’ πœ™π‘ƒπ›Ώπ‘₯𝑃𝐸

βˆ’ Ξ“π‘€π΄π‘€πœ™π‘ƒ βˆ’ πœ™π‘Šπ›Ώπ‘₯π‘Šπ‘ƒ

+ Ξ“π‘›π΄π‘›πœ™π‘ βˆ’ πœ™π‘ƒπ›Ώπ‘¦π‘ƒπ‘

βˆ’ Ξ“π‘ π΄π‘ πœ™π‘ƒ βˆ’ πœ™π‘†π›Ώπ‘¦π‘†π‘ƒ

+ 𝑆Δ𝑉 = 0

π‘Žπ‘ƒπœ™π‘ƒ = π‘Žπ‘Šπœ™π‘Š + π‘ŽπΈπœ™πΈ + π‘Žπ‘†πœ™π‘† + π‘Žπ‘πœ™π‘ + 𝑆𝑒 = 0

Page 40: Finite Volume Discretization MMVN05 - StrΓΆmningsteknikΒ Β· Convection-Diffusion problems in 1D W P E w e Dx dx Pe d WP dx PE 𝑒 π‘’πœ™π‘’βˆ’ πœ™ =π·π‘’πœ™πΈβˆ’πœ™π‘ƒβˆ’π·

Finite Volume Method on unstructured

grids

P

ni

DA

𝑉

πœ•πœŒπœ™

πœ•π‘‘π‘‘π‘‰ +

𝑉

𝑑𝑖𝑣 πœŒπ‘’ πœ™ 𝑑𝑉

= 𝑉

𝑑𝑖𝑣 Ξ“π‘”π‘Ÿπ‘Žπ‘‘ πœ™ 𝑑𝑉 + 𝑉

𝑆 𝑑𝑉

πœ•

πœ•π‘‘

𝑉

πœŒπœ™ 𝑑𝑉 + 𝐴

𝑛. πœŒπ‘’ πœ™ 𝑑𝐴 = 𝐴

𝑛. Ξ“π‘”π‘Ÿπ‘Žπ‘‘ πœ™ 𝑑𝐴 + 𝑉

𝑆 𝑑𝑉

πœ•

πœ•π‘‘

𝑉

πœŒπœ™π‘‘π‘‰ + βˆ‘ Δ𝐴𝑖

𝑛𝑖 . πœŒπ‘’ πœ™ 𝑑𝐴 = βˆ‘ Δ𝐴𝑖

𝑛𝑖 . Ξ“π‘”π‘Ÿπ‘Žπ‘‘ πœ™ 𝑑𝐴 + 𝑉

𝑆 𝑑𝑉

β€’ ni can be computed based on grid topology

Page 41: Finite Volume Discretization MMVN05 - StrΓΆmningsteknikΒ Β· Convection-Diffusion problems in 1D W P E w e Dx dx Pe d WP dx PE 𝑒 π‘’πœ™π‘’βˆ’ πœ™ =π·π‘’πœ™πΈβˆ’πœ™π‘ƒβˆ’π·

Diffusion term

β€’ Central differencing

β€’ Only true if the grid is

orthogonal

Δ𝐴𝑖

𝑛𝑖 . Ξ“π‘”π‘Ÿπ‘Žπ‘‘ πœ™ 𝑑𝐴 β‰ˆ

𝑛𝑖 . Ξ“π‘”π‘Ÿπ‘Žπ‘‘ πœ™ Δ𝐴𝑖 β‰ˆ

Ξ“πœ™π΄ βˆ’ πœ™π‘ƒΞ”πœ‰

Δ𝐴𝑖

Fig.11.15

Page 42: Finite Volume Discretization MMVN05 - StrΓΆmningsteknikΒ Β· Convection-Diffusion problems in 1D W P E w e Dx dx Pe d WP dx PE 𝑒 π‘’πœ™π‘’βˆ’ πœ™ =π·π‘’πœ™πΈβˆ’πœ™π‘ƒβˆ’π·

Non-orthogonal grids

β€’ Can be computed as:

n. gradπœ™Ξ”π΄π‘–

=𝑛. 𝑛Δ𝐴𝑖𝑛. π‘’πœ‰

πœ™π΄ βˆ’ πœ™π‘ƒΞ”πœ‰

βˆ’π‘’πœ‰ . π‘’πœ‚ Δ𝐴𝑖

𝑛. π‘’πœ‰

πœ™π‘ βˆ’ πœ™π‘ŽΞ”πœ‚

Fig.11.17

Page 43: Finite Volume Discretization MMVN05 - StrΓΆmningsteknikΒ Β· Convection-Diffusion problems in 1D W P E w e Dx dx Pe d WP dx PE 𝑒 π‘’πœ™π‘’βˆ’ πœ™ =π·π‘’πœ™πΈβˆ’πœ™π‘ƒβˆ’π·

Non-orthogonal grids

β€’ Compare to:

n. gradπœ™ Δ𝐴𝑖 =𝑛. 𝑛Δ𝐴𝑖𝑛. π‘’πœ‰

πœ™π΄ βˆ’ πœ™π‘ƒΞ”πœ‰

βˆ’π‘’πœ‰ . π‘’πœ‚ Δ𝐴𝑖

𝑛. π‘’πœ‰

πœ™π‘ βˆ’ πœ™π‘ŽΞ”πœ‚

Direct gradient Cross-diffusion

Known Interpolated

Can be (pre)computed (and stored) based on grid topology.

n. gradπœ™ Δ𝐴𝑖 =πœ™π΄ βˆ’ πœ™π‘ƒΞ”πœ‰

Δ𝐴𝑖

Page 44: Finite Volume Discretization MMVN05 - StrΓΆmningsteknikΒ Β· Convection-Diffusion problems in 1D W P E w e Dx dx Pe d WP dx PE 𝑒 π‘’πœ™π‘’βˆ’ πœ™ =π·π‘’πœ™πΈβˆ’πœ™π‘ƒβˆ’π·

Convective term

β€’ Approximate as:

Δ𝐴𝑖

𝑛𝑖 . πœŒπœ™π‘’ 𝑑𝐴 β‰ˆ

πœ™π‘– Δ𝐴𝑖

𝑛𝑖 . πœŒπ‘’ 𝑑𝐴 β‰ˆ πœ™π‘–πΉπ‘–

Fi = Convective flux

normal to the surface

element.

Usually stored.Fig.11.15

Page 45: Finite Volume Discretization MMVN05 - StrΓΆmningsteknikΒ Β· Convection-Diffusion problems in 1D W P E w e Dx dx Pe d WP dx PE 𝑒 π‘’πœ™π‘’βˆ’ πœ™ =π·π‘’πœ™πΈβˆ’πœ™π‘ƒβˆ’π·

fi

β€’ Upwind differencing

– Fi>0 fi=fP

– Fi<0 fi=fA

β€’ Linear upwind differencing

β€’ QUICK

β€’ TVD

β€’ …

πœ™π‘– = πœ™π‘ƒ + π›»πœ™π‘ƒ . Ξ”π‘Ÿ

Needs to be computed!

Page 46: Finite Volume Discretization MMVN05 - StrΓΆmningsteknikΒ Β· Convection-Diffusion problems in 1D W P E w e Dx dx Pe d WP dx PE 𝑒 π‘’πœ™π‘’βˆ’ πœ™ =π·π‘’πœ™πΈβˆ’πœ™π‘ƒβˆ’π·

Recommended