63
Introduction to Simulation - Lecture 19 Thanks to Deepak Ramaswamy, Michal Rewienski, and Karen Veroy, Jaime Peraire and Tony Patera Laplace’s Equation – FEM Methods Jacob White

Laplace’s Equation – FEM Methods - MIT … to Simulation - Lecture 19 Thanks to Deepak Ramaswamy, Michal Rewienski, and Karen Veroy, Jaime Peraire and Tony Patera Laplace’s Equation

  • Upload
    dongoc

  • View
    221

  • Download
    2

Embed Size (px)

Citation preview

Page 1: Laplace’s Equation – FEM Methods - MIT … to Simulation - Lecture 19 Thanks to Deepak Ramaswamy, Michal Rewienski, and Karen Veroy, Jaime Peraire and Tony Patera Laplace’s Equation

Introduction to Simulation - Lecture 19

Thanks to Deepak Ramaswamy, Michal Rewienski, and Karen Veroy, Jaime Peraire and Tony Patera

Laplace’s Equation – FEM Methods

Jacob White

Page 2: Laplace’s Equation – FEM Methods - MIT … to Simulation - Lecture 19 Thanks to Deepak Ramaswamy, Michal Rewienski, and Karen Veroy, Jaime Peraire and Tony Patera Laplace’s Equation

SMA-HPC ©2003 MIT

Outline for Poisson Equation Section

• Why Study Poisson’s equation– Heat Flow, Potential Flow, Electrostatics

– Raises many issues common to solving PDEs.

• Basic Numerical Techniques– basis functions (FEM) and finite-differences

– Integral equation methods

• Fast Methods for 3-D– Preconditioners for FEM and Finite-differences

– Fast multipole techniques for integral equations

Page 3: Laplace’s Equation – FEM Methods - MIT … to Simulation - Lecture 19 Thanks to Deepak Ramaswamy, Michal Rewienski, and Karen Veroy, Jaime Peraire and Tony Patera Laplace’s Equation

SMA-HPC ©2003 MIT

Outline for Today

• Why Poisson Equation– Reminder about heat conducting bar

• Finite-Difference And Basis function methods– Key question of convergence

• Convergence of Finite-Element methods– Key idea: solve Poisson by minimization

– Demonstrate optimality in a carefully chosen norm

Page 4: Laplace’s Equation – FEM Methods - MIT … to Simulation - Lecture 19 Thanks to Deepak Ramaswamy, Michal Rewienski, and Karen Veroy, Jaime Peraire and Tony Patera Laplace’s Equation

SMA-HPC ©2003 MIT

Drag Force Analysis of Aircraft

• Potential Flow Equations– Poisson Partial Differential Equations.

Page 5: Laplace’s Equation – FEM Methods - MIT … to Simulation - Lecture 19 Thanks to Deepak Ramaswamy, Michal Rewienski, and Karen Veroy, Jaime Peraire and Tony Patera Laplace’s Equation

SMA-HPC ©2003 MIT

Engine Thermal Analysis

• Thermal Conduction Equations– The Poisson Partial Differential Equation.

Page 6: Laplace’s Equation – FEM Methods - MIT … to Simulation - Lecture 19 Thanks to Deepak Ramaswamy, Michal Rewienski, and Karen Veroy, Jaime Peraire and Tony Patera Laplace’s Equation

SMA-HPC ©2003 MIT

Capacitance on a microprocessor Signal Line

• Electrostatic Analysis– The Laplace Partial Differential Equation.

Page 7: Laplace’s Equation – FEM Methods - MIT … to Simulation - Lecture 19 Thanks to Deepak Ramaswamy, Michal Rewienski, and Karen Veroy, Jaime Peraire and Tony Patera Laplace’s Equation

Heat Flow 1-D Example

( )0T ( )1T

Unit Length RodNear End

TemperatureFar End

Temperature

Question: What is the temperature distribution along the bar

x

T

Incoming Heat

( )0T ( )1T

Page 8: Laplace’s Equation – FEM Methods - MIT … to Simulation - Lecture 19 Thanks to Deepak Ramaswamy, Michal Rewienski, and Karen Veroy, Jaime Peraire and Tony Patera Laplace’s Equation

Heat Flow 1-D Example

Discrete Representation

(0)T (1)T

1) Cut the bar into short sections

1T 2T NT1NT −

2) Assign each cut a temperature

Page 9: Laplace’s Equation – FEM Methods - MIT … to Simulation - Lecture 19 Thanks to Deepak Ramaswamy, Michal Rewienski, and Karen Veroy, Jaime Peraire and Tony Patera Laplace’s Equation

Heat Flow 1-D Example

Constitutive Relation

iT

Heat Flow through one section

1iT +

x∆

1,i ih +

11, heat flow i i

i iT Th

xκ +

+−

= =∆

0( )lim ( )xT xh xx

κ∆ →∂

=∂

Limit as the sections become vanishingly small

Page 10: Laplace’s Equation – FEM Methods - MIT … to Simulation - Lecture 19 Thanks to Deepak Ramaswamy, Michal Rewienski, and Karen Veroy, Jaime Peraire and Tony Patera Laplace’s Equation

Heat Flow 1-D Example

Conservation Law

1iT −

Two Adjacent Sections

iT 1iT +1,i ih +, 1i ih −

x∆

“control volume”

1, , 1i i i sih hh x+ −− = − ∆Heat Flows into Control Volume Sums to zero

Incoming Heat ( )sh

Page 11: Laplace’s Equation – FEM Methods - MIT … to Simulation - Lecture 19 Thanks to Deepak Ramaswamy, Michal Rewienski, and Karen Veroy, Jaime Peraire and Tony Patera Laplace’s Equation

Heat Flow 1-D Example

Conservation Law

1, , 1i i i sih hh x+ −− = − ∆

Heat Flows into Control Volume Sums to zero

1iT − iT 1iT +1,i ih +, 1i ih −

x∆

Incom ing H eat ( )sh

0( ) ( )lim ( )x sh x T xh xx x x

κ∆ →∂ ∂ ∂

= =∂ ∂ ∂

Limit as the sections become vanishingly small

Heat in from left

Heat out from right

Incoming heat per unit length

Page 12: Laplace’s Equation – FEM Methods - MIT … to Simulation - Lecture 19 Thanks to Deepak Ramaswamy, Michal Rewienski, and Karen Veroy, Jaime Peraire and Tony Patera Laplace’s Equation

SMA-HPC ©2003 MIT

Heat Flow 1-D Example

Circuit Analogy

+-

+-

1R x

κ=∆

ssi xh= ∆(0)sv T= (1)sv T=

Temperature analogous to VoltageHeat Flow analogous to Current

1T NT

Page 13: Laplace’s Equation – FEM Methods - MIT … to Simulation - Lecture 19 Thanks to Deepak Ramaswamy, Michal Rewienski, and Karen Veroy, Jaime Peraire and Tony Patera Laplace’s Equation

1-D Example

Normalized 1-D Equation

Normalized Poisson Equation

2

2

( ) ( ) ( )sT x u xh f x

x x xκ∂ ∂ ∂

= − ⇒ − =∂ ∂ ∂

Heat Flow

( ) ( )xxu x f x− =

Page 14: Laplace’s Equation – FEM Methods - MIT … to Simulation - Lecture 19 Thanks to Deepak Ramaswamy, Michal Rewienski, and Karen Veroy, Jaime Peraire and Tony Patera Laplace’s Equation

SMA-HPC ©2003 MIT

Page 15: Laplace’s Equation – FEM Methods - MIT … to Simulation - Lecture 19 Thanks to Deepak Ramaswamy, Michal Rewienski, and Karen Veroy, Jaime Peraire and Tony Patera Laplace’s Equation

SMA-HPC ©2003 MIT

Page 16: Laplace’s Equation – FEM Methods - MIT … to Simulation - Lecture 19 Thanks to Deepak Ramaswamy, Michal Rewienski, and Karen Veroy, Jaime Peraire and Tony Patera Laplace’s Equation

SMA-HPC ©2003 MIT

Residual EquationUsing Basis Functions

2

2

u fx∂

− =∂

Partial Differential Equation form

(0) 0 (1) 0u u= =

Basis Function Representation

Plug Basis Function Representation into the Equation

( ) ( ) ( )2

21

ni

ii

d xR x f x

dxϕ

ω=

= +∑

( ) ( ) ( )1 Basis Functions

n

h i ii

u x u x xω ϕ=

≈ =∑

Page 17: Laplace’s Equation – FEM Methods - MIT … to Simulation - Lecture 19 Thanks to Deepak Ramaswamy, Michal Rewienski, and Karen Veroy, Jaime Peraire and Tony Patera Laplace’s Equation

SMA-HPC ©2003 MIT

Using Basis Functions

( ) is a weighted sum of basis func o s nu tih x⇒

The basis functions define a space

3ϕ 5ϕ

4ϕ 6ϕ“Hat” basis functions Piecewise linear Space

Example1

| for some 's n

h h i i ii

X v X v β ϕ β=

= ∈ =

( ) ( ) ( )1 Basis Functions

Introduce basis representation n

h i ii

u x u x xω ϕ=

≈ =∑

Example Basis functions

Page 18: Laplace’s Equation – FEM Methods - MIT … to Simulation - Lecture 19 Thanks to Deepak Ramaswamy, Michal Rewienski, and Karen Veroy, Jaime Peraire and Tony Patera Laplace’s Equation

SMA-HPC ©2003 MIT

Basis WeightsUsing Basis functions

Galerkin Scheme

Generates n equations in n unknowns

( ) ( ) ( )21

210

0n

il i

i

d xx f x dx

dxϕ

ϕ ω=

+ =

∑∫

Force the residual to be “orthogonal” to the basis functions

1,...,l n∈

( ) ( )1

0

0l x R x dtϕ =∫

Page 19: Laplace’s Equation – FEM Methods - MIT … to Simulation - Lecture 19 Thanks to Deepak Ramaswamy, Michal Rewienski, and Karen Veroy, Jaime Peraire and Tony Patera Laplace’s Equation

SMA-HPC ©2003 MIT

Basis WeightsUsing Basis Functions Galerkin with integration by

parts

Only first derivatives of basis functions

( ) ( )( ) ( )1

1 1

0 0

0

n

i iil

i

xdd xdx x f x dx

dx dx

ωϕϕϕ= − =

∑∫ ∫

1,...,l n∈

Page 20: Laplace’s Equation – FEM Methods - MIT … to Simulation - Lecture 19 Thanks to Deepak Ramaswamy, Michal Rewienski, and Karen Veroy, Jaime Peraire and Tony Patera Laplace’s Equation

SMA-HPC ©2003 MIT

Convergence Analysis

huuThe question is

How does decrease with refinement?h

error

u u−123

• This time – Finite-element methods• Next time – Finite-difference methods

Page 21: Laplace’s Equation – FEM Methods - MIT … to Simulation - Lecture 19 Thanks to Deepak Ramaswamy, Michal Rewienski, and Karen Veroy, Jaime Peraire and Tony Patera Laplace’s Equation

SMA-HPC ©2003 MIT

Convergence AnalysisHeat Equation

Overview of FEM

2

2

u fx∂

− =∂

Partial Differential Equation form

(0) 0 (1) 0u u= =

“Nearly” Equivalent weak form

Introduced an abstract notation for the equation u must satisfy

for all

( , ) ( )

u v dx f v dx vx xa u v l v

Ω Ω

∂ ∂=

∂ ∂∫ ∫14243 14243

( , ) ( )a u v l v= for all v

Page 22: Laplace’s Equation – FEM Methods - MIT … to Simulation - Lecture 19 Thanks to Deepak Ramaswamy, Michal Rewienski, and Karen Veroy, Jaime Peraire and Tony Patera Laplace’s Equation

SMA-HPC ©2003 MIT

Convergence AnalysisHeat Equation

Overview of FEM

( ) is a weighted sum of basis func o s nu tih x⇒

The basis functions define a space

3ϕ 5ϕ

4ϕ 6ϕ“Hat” basis functions Piecewise linear Space

Example1

| for some 's n

h h i i ii

X v X v β ϕ β=

= ∈ =

( ) ( ) ( )1 Basis Functions

Introduce basis representation n

h i ii

u x u x xω ϕ=

≈ =∑

Page 23: Laplace’s Equation – FEM Methods - MIT … to Simulation - Lecture 19 Thanks to Deepak Ramaswamy, Michal Rewienski, and Karen Veroy, Jaime Peraire and Tony Patera Laplace’s Equation

SMA-HPC ©2003 MIT

Convergence AnalysisHeat Equation

Overview of FEM

Using the norm properties, it is possible to show

Key Idea

( , ) ( )h i ia u lIf ϕ ϕ=

min

Prh hh w X hu u u w

ojectionSolutionError E

Then

rror

∈− = −14243 14243

U is restricted to be 0 at 0 and1!!

1 2, ,..for all .,i nϕ ϕ ϕ ϕ∈

defines a nor( , ) ( , )ma u u a u u u≡

Page 24: Laplace’s Equation – FEM Methods - MIT … to Simulation - Lecture 19 Thanks to Deepak Ramaswamy, Michal Rewienski, and Karen Veroy, Jaime Peraire and Tony Patera Laplace’s Equation

SMA-HPC ©2003 MIT

Convergence AnalysisHeat Equation

Overview of FEM

huu

The question is only

How well can you fit u with a member of XhBut you must measure the error in the ||| ||| norm

1h

error

u u On

− = 14243

For piecewise linear:

Page 25: Laplace’s Equation – FEM Methods - MIT … to Simulation - Lecture 19 Thanks to Deepak Ramaswamy, Michal Rewienski, and Karen Veroy, Jaime Peraire and Tony Patera Laplace’s Equation

SMA-HPC ©2003 MIT

Page 26: Laplace’s Equation – FEM Methods - MIT … to Simulation - Lecture 19 Thanks to Deepak Ramaswamy, Michal Rewienski, and Karen Veroy, Jaime Peraire and Tony Patera Laplace’s Equation

SMA-HPC ©2003 MIT

Page 27: Laplace’s Equation – FEM Methods - MIT … to Simulation - Lecture 19 Thanks to Deepak Ramaswamy, Michal Rewienski, and Karen Veroy, Jaime Peraire and Tony Patera Laplace’s Equation

SMA-HPC ©2003 MIT

Page 28: Laplace’s Equation – FEM Methods - MIT … to Simulation - Lecture 19 Thanks to Deepak Ramaswamy, Michal Rewienski, and Karen Veroy, Jaime Peraire and Tony Patera Laplace’s Equation

SMA-HPC ©2003 MIT

Page 29: Laplace’s Equation – FEM Methods - MIT … to Simulation - Lecture 19 Thanks to Deepak Ramaswamy, Michal Rewienski, and Karen Veroy, Jaime Peraire and Tony Patera Laplace’s Equation

SMA-HPC ©2003 MIT

Page 30: Laplace’s Equation – FEM Methods - MIT … to Simulation - Lecture 19 Thanks to Deepak Ramaswamy, Michal Rewienski, and Karen Veroy, Jaime Peraire and Tony Patera Laplace’s Equation

SMA-HPC ©2003 MIT

Page 31: Laplace’s Equation – FEM Methods - MIT … to Simulation - Lecture 19 Thanks to Deepak Ramaswamy, Michal Rewienski, and Karen Veroy, Jaime Peraire and Tony Patera Laplace’s Equation

SMA-HPC ©2003 MIT

Page 32: Laplace’s Equation – FEM Methods - MIT … to Simulation - Lecture 19 Thanks to Deepak Ramaswamy, Michal Rewienski, and Karen Veroy, Jaime Peraire and Tony Patera Laplace’s Equation

SMA-HPC ©2003 MIT

Page 33: Laplace’s Equation – FEM Methods - MIT … to Simulation - Lecture 19 Thanks to Deepak Ramaswamy, Michal Rewienski, and Karen Veroy, Jaime Peraire and Tony Patera Laplace’s Equation

SMA-HPC ©2003 MIT

Page 34: Laplace’s Equation – FEM Methods - MIT … to Simulation - Lecture 19 Thanks to Deepak Ramaswamy, Michal Rewienski, and Karen Veroy, Jaime Peraire and Tony Patera Laplace’s Equation

SMA-HPC ©2003 MIT

Page 35: Laplace’s Equation – FEM Methods - MIT … to Simulation - Lecture 19 Thanks to Deepak Ramaswamy, Michal Rewienski, and Karen Veroy, Jaime Peraire and Tony Patera Laplace’s Equation

SMA-HPC ©2003 MIT

Page 36: Laplace’s Equation – FEM Methods - MIT … to Simulation - Lecture 19 Thanks to Deepak Ramaswamy, Michal Rewienski, and Karen Veroy, Jaime Peraire and Tony Patera Laplace’s Equation

SMA-HPC ©2003 MIT

Page 37: Laplace’s Equation – FEM Methods - MIT … to Simulation - Lecture 19 Thanks to Deepak Ramaswamy, Michal Rewienski, and Karen Veroy, Jaime Peraire and Tony Patera Laplace’s Equation

SMA-HPC ©2003 MIT

Page 38: Laplace’s Equation – FEM Methods - MIT … to Simulation - Lecture 19 Thanks to Deepak Ramaswamy, Michal Rewienski, and Karen Veroy, Jaime Peraire and Tony Patera Laplace’s Equation

SMA-HPC ©2003 MIT

Page 39: Laplace’s Equation – FEM Methods - MIT … to Simulation - Lecture 19 Thanks to Deepak Ramaswamy, Michal Rewienski, and Karen Veroy, Jaime Peraire and Tony Patera Laplace’s Equation

SMA-HPC ©2003 MIT

Page 40: Laplace’s Equation – FEM Methods - MIT … to Simulation - Lecture 19 Thanks to Deepak Ramaswamy, Michal Rewienski, and Karen Veroy, Jaime Peraire and Tony Patera Laplace’s Equation

SMA-HPC ©2003 MIT

Page 41: Laplace’s Equation – FEM Methods - MIT … to Simulation - Lecture 19 Thanks to Deepak Ramaswamy, Michal Rewienski, and Karen Veroy, Jaime Peraire and Tony Patera Laplace’s Equation

SMA-HPC ©2003 MIT

Page 42: Laplace’s Equation – FEM Methods - MIT … to Simulation - Lecture 19 Thanks to Deepak Ramaswamy, Michal Rewienski, and Karen Veroy, Jaime Peraire and Tony Patera Laplace’s Equation

SMA-HPC ©2003 MIT

Page 43: Laplace’s Equation – FEM Methods - MIT … to Simulation - Lecture 19 Thanks to Deepak Ramaswamy, Michal Rewienski, and Karen Veroy, Jaime Peraire and Tony Patera Laplace’s Equation

SMA-HPC ©2003 MIT

Page 44: Laplace’s Equation – FEM Methods - MIT … to Simulation - Lecture 19 Thanks to Deepak Ramaswamy, Michal Rewienski, and Karen Veroy, Jaime Peraire and Tony Patera Laplace’s Equation

SMA-HPC ©2003 MIT

Page 45: Laplace’s Equation – FEM Methods - MIT … to Simulation - Lecture 19 Thanks to Deepak Ramaswamy, Michal Rewienski, and Karen Veroy, Jaime Peraire and Tony Patera Laplace’s Equation

SMA-HPC ©2003 MIT

Page 46: Laplace’s Equation – FEM Methods - MIT … to Simulation - Lecture 19 Thanks to Deepak Ramaswamy, Michal Rewienski, and Karen Veroy, Jaime Peraire and Tony Patera Laplace’s Equation

SMA-HPC ©2003 MIT

Page 47: Laplace’s Equation – FEM Methods - MIT … to Simulation - Lecture 19 Thanks to Deepak Ramaswamy, Michal Rewienski, and Karen Veroy, Jaime Peraire and Tony Patera Laplace’s Equation

SMA-HPC ©2003 MIT

Page 48: Laplace’s Equation – FEM Methods - MIT … to Simulation - Lecture 19 Thanks to Deepak Ramaswamy, Michal Rewienski, and Karen Veroy, Jaime Peraire and Tony Patera Laplace’s Equation

SMA-HPC ©2003 MIT

Page 49: Laplace’s Equation – FEM Methods - MIT … to Simulation - Lecture 19 Thanks to Deepak Ramaswamy, Michal Rewienski, and Karen Veroy, Jaime Peraire and Tony Patera Laplace’s Equation

SMA-HPC ©2003 MIT

Page 50: Laplace’s Equation – FEM Methods - MIT … to Simulation - Lecture 19 Thanks to Deepak Ramaswamy, Michal Rewienski, and Karen Veroy, Jaime Peraire and Tony Patera Laplace’s Equation

SMA-HPC ©2003 MIT

Page 51: Laplace’s Equation – FEM Methods - MIT … to Simulation - Lecture 19 Thanks to Deepak Ramaswamy, Michal Rewienski, and Karen Veroy, Jaime Peraire and Tony Patera Laplace’s Equation

SMA-HPC ©2003 MIT

Page 52: Laplace’s Equation – FEM Methods - MIT … to Simulation - Lecture 19 Thanks to Deepak Ramaswamy, Michal Rewienski, and Karen Veroy, Jaime Peraire and Tony Patera Laplace’s Equation

SMA-HPC ©2003 MIT

Page 53: Laplace’s Equation – FEM Methods - MIT … to Simulation - Lecture 19 Thanks to Deepak Ramaswamy, Michal Rewienski, and Karen Veroy, Jaime Peraire and Tony Patera Laplace’s Equation

SMA-HPC ©2003 MIT

Page 54: Laplace’s Equation – FEM Methods - MIT … to Simulation - Lecture 19 Thanks to Deepak Ramaswamy, Michal Rewienski, and Karen Veroy, Jaime Peraire and Tony Patera Laplace’s Equation

SMA-HPC ©2003 MIT

Page 55: Laplace’s Equation – FEM Methods - MIT … to Simulation - Lecture 19 Thanks to Deepak Ramaswamy, Michal Rewienski, and Karen Veroy, Jaime Peraire and Tony Patera Laplace’s Equation

SMA-HPC ©2003 MIT

Page 56: Laplace’s Equation – FEM Methods - MIT … to Simulation - Lecture 19 Thanks to Deepak Ramaswamy, Michal Rewienski, and Karen Veroy, Jaime Peraire and Tony Patera Laplace’s Equation

SMA-HPC ©2003 MIT

Page 57: Laplace’s Equation – FEM Methods - MIT … to Simulation - Lecture 19 Thanks to Deepak Ramaswamy, Michal Rewienski, and Karen Veroy, Jaime Peraire and Tony Patera Laplace’s Equation

SMA-HPC ©2003 MIT

Page 58: Laplace’s Equation – FEM Methods - MIT … to Simulation - Lecture 19 Thanks to Deepak Ramaswamy, Michal Rewienski, and Karen Veroy, Jaime Peraire and Tony Patera Laplace’s Equation

SMA-HPC ©2003 MIT

Page 59: Laplace’s Equation – FEM Methods - MIT … to Simulation - Lecture 19 Thanks to Deepak Ramaswamy, Michal Rewienski, and Karen Veroy, Jaime Peraire and Tony Patera Laplace’s Equation

SMA-HPC ©2003 MIT

Page 60: Laplace’s Equation – FEM Methods - MIT … to Simulation - Lecture 19 Thanks to Deepak Ramaswamy, Michal Rewienski, and Karen Veroy, Jaime Peraire and Tony Patera Laplace’s Equation

SMA-HPC ©2003 MIT

Page 61: Laplace’s Equation – FEM Methods - MIT … to Simulation - Lecture 19 Thanks to Deepak Ramaswamy, Michal Rewienski, and Karen Veroy, Jaime Peraire and Tony Patera Laplace’s Equation

SMA-HPC ©2003 MIT

Page 62: Laplace’s Equation – FEM Methods - MIT … to Simulation - Lecture 19 Thanks to Deepak Ramaswamy, Michal Rewienski, and Karen Veroy, Jaime Peraire and Tony Patera Laplace’s Equation

SMA-HPC ©2003 MIT

Page 63: Laplace’s Equation – FEM Methods - MIT … to Simulation - Lecture 19 Thanks to Deepak Ramaswamy, Michal Rewienski, and Karen Veroy, Jaime Peraire and Tony Patera Laplace’s Equation

SMA-HPC ©2003 MIT

Summary

• Why Poisson Equation– Reminder about heat conducting bar

• Finite-Difference And Basis function methods– Key question of convergence

• Convergence of Finite-Element methods– Key idea: solve Poisson by minimization

– Demonstrate optimality in a carefully chosen norm