Least – Squares Finite Element Methods for Large...

35
Least – Squares Finite Element Methods for Large Scale Incompressible Flows by Tate T. H. Tsang Department of Chemical & Materials Engineering University of Kentucky Lexington, KY 40506 [email protected] A presentation to honor Prof. Thomas F. Edgar on his 65 th birthday in the AIChE Annual Meeting, Salt Lake City, 2010.

Transcript of Least – Squares Finite Element Methods for Large...

Page 1: Least – Squares Finite Element Methods for Large …utw10249.utweb.utexas.edu/edgar_group/documents/birthday/tsang.pdf · Least – Squares Finite Element Methods for Large ...

Least – Squares Finite Element Methods for Large ‐ Scale Incompressible Flows 

by

Tate T. H. TsangDepartment of Chemical & Materials Engineering

University of Kentucky Lexington, KY [email protected]

A presentation to honor Prof. Thomas F. Edgar on his 65th birthday in the AIChE Annual Meeting, Salt Lake City, 2010. 

Page 2: Least – Squares Finite Element Methods for Large …utw10249.utweb.utexas.edu/edgar_group/documents/birthday/tsang.pdf · Least – Squares Finite Element Methods for Large ...

A Transport  Equation has 4 terms,

Accumulation + Convection = Diffusion + Source/Sink

• It is relatively easy to obtain numerical solution for Diffusion/Conduction terms  (leading to Sparse, Symmetric Linear System)

• It is quite challenging to deal with the Convectionterms (leading to Sparse, Non‐symmetric LinearSystem)

Page 3: Least – Squares Finite Element Methods for Large …utw10249.utweb.utexas.edu/edgar_group/documents/birthday/tsang.pdf · Least – Squares Finite Element Methods for Large ...

Example:          0C Cut x

∂ ∂+ =

∂ ∂

0 0.2 0.4 0.6 0.8 1 1.2 1.4-0.2

0

0.2

0.4

0.6

0.8

1

1.2

1.4

X

Con

c.

GFEM creates Spurious  Oscillations

Upwind Differencing creates Numerical Diffusion

Page 4: Least – Squares Finite Element Methods for Large …utw10249.utweb.utexas.edu/edgar_group/documents/birthday/tsang.pdf · Least – Squares Finite Element Methods for Large ...

0 0.5 1 1.5 2 2.5-0.2

0

0.2

0.4

0.6

0.8

1

1.2

X

Con

c.

Page 5: Least – Squares Finite Element Methods for Large …utw10249.utweb.utexas.edu/edgar_group/documents/birthday/tsang.pdf · Least – Squares Finite Element Methods for Large ...

• No perfect numerical method for Convection

• Choose Least‐Squares Finite Element Method (LSFEM)as a compromise between the GalerkinFinite Element Method and Upwind Differencing

• Prof. Graham Carey and his former student (UT Austin),Dr. Bonan Jiang developed the LSFEM in 80’

• Dr. Jiang introduced LSFEM to me in 1990

Page 6: Least – Squares Finite Element Methods for Large …utw10249.utweb.utexas.edu/edgar_group/documents/birthday/tsang.pdf · Least – Squares Finite Element Methods for Large ...

Applications of LSFEM8 2D Stokes Flows8 2D Lid‐Driven Cavity Flows8 2D Flows over an Obstacle8 2D Flows over a Backward Facing Steps8 2D Von‐Karman Vortex Shedding behind a Cylinder8 2D Thermally Stratified Flows8 2D Natural Convection8 2D Rayleigh‐Benard Convection Cells8 2D Doubly‐Diffusive Flows8 2D Atmospheric Transport and Chemistry for Air Pollution Modeling8 3D Lid‐Driven Cavity Flows8 3D Natural Convection8 3D Thermocapillary Flows8 3D Atmospheric Transport and Chemistry for Air Pollution Modeling8 Large Eddy Simulations of Turbulent Flows8 Large Eddy Simulations of Pollutant Dispersion in the Atmospheric

Convective Boundary Layers8 Domain Decomposition based LSFEM for Large Scale Parallel

Computations

Page 7: Least – Squares Finite Element Methods for Large …utw10249.utweb.utexas.edu/edgar_group/documents/birthday/tsang.pdf · Least – Squares Finite Element Methods for Large ...

LSFEM FORMULATIONS FOR THE NAVIER ‐ STOKES EQUATIONS

(1) Velocity – Vorticity ‐ Pressure Formulation: 7 unknowns, 8 equations

1Re

0

i i kj ijk

j i j

j

j

u u Put x x x

ux

ωε∂ ∂ ∂∂+ = − −

∂ ∂ ∂ ∂

∂=

0

ki ijk

j

j

j

ux

x

ω ε

ω

∂=

∂=

Page 8: Least – Squares Finite Element Methods for Large …utw10249.utweb.utexas.edu/edgar_group/documents/birthday/tsang.pdf · Least – Squares Finite Element Methods for Large ...

LSFEM  FORMULATIONS(2) Velocity‐Stress‐Pressure Formulation: 10 unknowns, 10 equations.

2Re

0

12

iji ij

j i j

j

j

jiij

j i

Su u Put x x x

ux

uuSx x

∂∂ ∂ ∂+ = − +

∂ ∂ ∂ ∂

∂=

⎛ ⎞∂∂= +⎜ ⎟⎜ ⎟∂ ∂⎝ ⎠

Page 9: Least – Squares Finite Element Methods for Large …utw10249.utweb.utexas.edu/edgar_group/documents/birthday/tsang.pdf · Least – Squares Finite Element Methods for Large ...

LSFEM   FORMULATION

{ } { }x y zu v w P ω ω ω=V

Time Discretization (nth time level) and linearization (mth Newton’s step)Leads to,

{ } { } { } { }( )

{ } { }( )

( ) ( 1, ) !, 1

!, 1

n n m n m

n m

R f g

b

+ + +

+ +

= + −

= −

V

V

L

L

Objective Function: { } { } { }( 1, 1) Tn mI R R d+ +

Ω

⎡ ⎤ = ⋅ Ω⎣ ⎦ ∫V

Minimization leads to,

{ } { } { } { } { }e e

T T

e ed b d

Ω Ω

Φ ⋅ Φ Ω = Φ ⋅ Ω⎡ ⎤ ⎡ ⎤ ⎡ ⎤ ⎡ ⎤⎣ ⎦ ⎣ ⎦ ⎣ ⎦ ⎣ ⎦∑ ∑∫ ∫VL L L

A x b=

Page 10: Least – Squares Finite Element Methods for Large …utw10249.utweb.utexas.edu/edgar_group/documents/birthday/tsang.pdf · Least – Squares Finite Element Methods for Large ...

Least‐Squares Finite Element Methods (LSFEM)8 First‐Order Formulations

Tang and Tsang, Int. J. Numerical Methods Fluids, 21(1995), 413‐432.Ding and Tsang, Int. J. Comp. Fluid Dynamics, 17 (2003), 183‐197.

8 LSFEM leads to Symmetric Positive Definite Linear System of Equations

A x = b

8 Robust Preconditioned Conjugate Gradient Methods (iterative methods for 3D problems) can be used to obtain Numerical Solution for the above SPD Linear System

8Matrix‐freeMethod (no need to assemble A) can be used to greatly reduce Memory Requirement. This allows us to simulate very large problems

8 LSFEM has been used Successfully for a variety of Laminar and TurbulentFlowsDing and Tsang, Int. J. Numerical Methods Fluids, 37(2001), 297‐319.

Page 11: Least – Squares Finite Element Methods for Large …utw10249.utweb.utexas.edu/edgar_group/documents/birthday/tsang.pdf · Least – Squares Finite Element Methods for Large ...
Page 12: Least – Squares Finite Element Methods for Large …utw10249.utweb.utexas.edu/edgar_group/documents/birthday/tsang.pdf · Least – Squares Finite Element Methods for Large ...

Application : Lid‐driven Cavity Flow (LDCF)8 Re = 1000; 500,000 elements; 3,500,000 unknowns

Ding and Tsang, International Journal of Computational Fluid Dynamics, 17(2003), 183.

Page 13: Least – Squares Finite Element Methods for Large …utw10249.utweb.utexas.edu/edgar_group/documents/birthday/tsang.pdf · Least – Squares Finite Element Methods for Large ...
Page 14: Least – Squares Finite Element Methods for Large …utw10249.utweb.utexas.edu/edgar_group/documents/birthday/tsang.pdf · Least – Squares Finite Element Methods for Large ...
Page 15: Least – Squares Finite Element Methods for Large …utw10249.utweb.utexas.edu/edgar_group/documents/birthday/tsang.pdf · Least – Squares Finite Element Methods for Large ...
Page 16: Least – Squares Finite Element Methods for Large …utw10249.utweb.utexas.edu/edgar_group/documents/birthday/tsang.pdf · Least – Squares Finite Element Methods for Large ...

Application : 3‐D Rayleigh‐Benard Convection

Ra = 8000; 50,400 elements; 613,965 unknownsTang and Tsang, Computer Methods in Applied Mechanics & Engineering, 

140 (1997) 201‐219.

Page 17: Least – Squares Finite Element Methods for Large …utw10249.utweb.utexas.edu/edgar_group/documents/birthday/tsang.pdf · Least – Squares Finite Element Methods for Large ...
Page 18: Least – Squares Finite Element Methods for Large …utw10249.utweb.utexas.edu/edgar_group/documents/birthday/tsang.pdf · Least – Squares Finite Element Methods for Large ...

ColorfulFluidDynamics

Page 19: Least – Squares Finite Element Methods for Large …utw10249.utweb.utexas.edu/edgar_group/documents/birthday/tsang.pdf · Least – Squares Finite Element Methods for Large ...

Application : Large Eddy Simulation of Turbulent Flows

Page 20: Least – Squares Finite Element Methods for Large …utw10249.utweb.utexas.edu/edgar_group/documents/birthday/tsang.pdf · Least – Squares Finite Element Methods for Large ...

Subgrid Scale Modeling

8Smagorinsky Model8Dynamic Subgrid Scale Model (Germano, Lilly)

( )2t sC Sυ = Δ

Page 21: Least – Squares Finite Element Methods for Large …utw10249.utweb.utexas.edu/edgar_group/documents/birthday/tsang.pdf · Least – Squares Finite Element Methods for Large ...

Application : Transitional LDCF,   use LES8Re = 3,200;  216,000 elements; 2,269,810 unknowns

Page 22: Least – Squares Finite Element Methods for Large …utw10249.utweb.utexas.edu/edgar_group/documents/birthday/tsang.pdf · Least – Squares Finite Element Methods for Large ...

Application : Turbulent Channel Flow 

Page 23: Least – Squares Finite Element Methods for Large …utw10249.utweb.utexas.edu/edgar_group/documents/birthday/tsang.pdf · Least – Squares Finite Element Methods for Large ...

Application : Turbulent Channel Flows on Cruncher8Re = 3,240; 0 < t < 12; 65,536 elements; 707,850 unknowns8Large Eddy Simulation (LSFEM), Dynamic Subgrid‐Scale Model8This simulation takes about 1,454 sec. on 8 Processors

Application : Turbulent Channel Flows on Cruncher

8Re = 3,240; 2,097,152 elements; 21,466,890 unknowns8This simulation takes about 3 hr. on 16 Processors

Page 24: Least – Squares Finite Element Methods for Large …utw10249.utweb.utexas.edu/edgar_group/documents/birthday/tsang.pdf · Least – Squares Finite Element Methods for Large ...
Page 25: Least – Squares Finite Element Methods for Large …utw10249.utweb.utexas.edu/edgar_group/documents/birthday/tsang.pdf · Least – Squares Finite Element Methods for Large ...
Page 26: Least – Squares Finite Element Methods for Large …utw10249.utweb.utexas.edu/edgar_group/documents/birthday/tsang.pdf · Least – Squares Finite Element Methods for Large ...

Our Cluster Building Experience

8Cruncher (a 16‐node AMD 1.2/1.33 GHz, DDR Cluster)

Page 27: Least – Squares Finite Element Methods for Large …utw10249.utweb.utexas.edu/edgar_group/documents/birthday/tsang.pdf · Least – Squares Finite Element Methods for Large ...

Domain Decomposition based Least‐Squares Finite Element Methodfor Large Scale Parallel Computations

8Non‐Overlapping Domain Decomposition8Each Processor uses LSFEM to Simulate Fluid Flow in each Subdomain

Ding, Jiang and Tsang,  Ind & Eng Chem Research  (2010) 

Page 28: Least – Squares Finite Element Methods for Large …utw10249.utweb.utexas.edu/edgar_group/documents/birthday/tsang.pdf · Least – Squares Finite Element Methods for Large ...

Parallel Computations: Lid‐driven Cavity Flow (LDCF)8 Case 1: Re = 400; tf = 40, 64x64x32, 131,072 elements; 975,975 unknowns8 Case 2: Re = 400; tf = 40, 96x96x48, 442,368 elements; 3,227,287 unknowns8 Case 3: Re = 400; tf = 40, 128x128x64, 1,048,576 elements; 7,571,655 unknowns8 Case 4: Re = 1000; tf = 50, 128x128x64, 1,048,576 elements; 7,571,655 unknowns8 Case 5: Re = 1000; tf = 50, 192x192x96, 3,538,944 elements; 25,292,071 unknowns  

IBM  Intel  EM64T Linux Cluster, 2 Dual Core Intel Xeon 5160 CPUs (3GHz) per  Blade IB SDX 4X Interconnect between Blades   

Page 29: Least – Squares Finite Element Methods for Large …utw10249.utweb.utexas.edu/edgar_group/documents/birthday/tsang.pdf · Least – Squares Finite Element Methods for Large ...

# CPU Case 1 Case 2 Case 3 Case 4 Case 5

1 1516(1.00/100) 4838(1.00/100) 12926(1.00/100) 17356(1.00/100) 79193(1.00/100)

2 917(1.65/83) 3088(1.57/78) 7954(1.63/81) 10857(1.6/80) 50346(1.57/78)

4 441(3.43/86) 1600(3.02/75) 4148(3.11/78) 5665(3.06/77) 25866(3.06/77)

8 217(6.98/87) 837(5.78/72) 2176(5.94/74) 3049(5.69/71) 13798(5.74/72)

16 119(12.8/80) 453(10.7/67) 1225(10.6/66) 1642(10.6/66) 7604(10.4/65)

CPU times in seconds, Speedups and Efficiencies based on the # of CPUs

The Speedup and the efficiency (in percentage) values are given in parentheses

Page 30: Least – Squares Finite Element Methods for Large …utw10249.utweb.utexas.edu/edgar_group/documents/birthday/tsang.pdf · Least – Squares Finite Element Methods for Large ...
Page 31: Least – Squares Finite Element Methods for Large …utw10249.utweb.utexas.edu/edgar_group/documents/birthday/tsang.pdf · Least – Squares Finite Element Methods for Large ...

# Blades Case 1 Case 2 Case 3 Case 4 Case 5

1 917(1.00/100) 3088(1.00/100) 7954(1.00/100) 10857(1.00/100) 50346(1.00/100)

2 441(2.08/104) 1600(1.93/97) 4148(1.92/96) 5665(1.92/96) 25866(1.95/97)

4 217(4.22/106) 837(3.69/92) 2176(3.66/91) 3049(3.56/89) 13798(3.65/91)

8 119(7.71/96) 453(6.82/85) 1225(6.49/81) 1642(6.61/83) 7604(6.62/83)

CPU times in seconds, Speedups and Efficiencies based on the # of Blades

The Speedup and the efficiency (in percentage) values are given in parentheses

Page 32: Least – Squares Finite Element Methods for Large …utw10249.utweb.utexas.edu/edgar_group/documents/birthday/tsang.pdf · Least – Squares Finite Element Methods for Large ...

1 2 3 4 5 6 7 81

2

3

4

5

6

7

8Sppedups based on the # of Blades

# of Blades

Spe

edup

LinearCase 1Case 2Case 3Case 5

Page 33: Least – Squares Finite Element Methods for Large …utw10249.utweb.utexas.edu/edgar_group/documents/birthday/tsang.pdf · Least – Squares Finite Element Methods for Large ...

Conclusions

• LSFEM leads to SPD linear systems of equations

• The large SPD system can be solved efficiently byMatrix – free Conjugated Gradient Method 

• LSFEM does not use any adjusting parameter for its numerical solutions

• Non‐overlapping, Domain Decomposition techniqueallows LSFEM to solve larger flow problems

Page 34: Least – Squares Finite Element Methods for Large …utw10249.utweb.utexas.edu/edgar_group/documents/birthday/tsang.pdf · Least – Squares Finite Element Methods for Large ...

Acknowledgement

8 National Science Foundation8 U. S. Environmental Protection Agency

Laura BurrellLynne FosberryJamie WrightL. Q. TangBiswanath ChowdhuryX. DingQ. Y. Jiang

Page 35: Least – Squares Finite Element Methods for Large …utw10249.utweb.utexas.edu/edgar_group/documents/birthday/tsang.pdf · Least – Squares Finite Element Methods for Large ...

“Last but far from the least, Dear Professor Edgar, as

a practical way to honor you, I am going to use 

your new book for my Process Control course. 

Congratulation on your 65th Birthday.” 

“May you live ten thousands years long, and ten 

thousands times ten thousands years long.”