Advective - Diffusive Equation (Steady - State)

SS : not accumulating or generating any more source effects

Conservation + Constitutive = PDE  2   q  0 q  D u  V u D  u  V u  0 (D, V constant) (V, D > 0) 2 d u d u 1  D : D 2  V  0 d x d x

Dimensionless Form : x / L

 1        1     x L x  x  L

d 2 u d u  P e  0 V L  d  P e  "Peclet #" d  D ratio of advection to diffusion effects

FD form :

2 x U i 2  P e  ?   0 h    x / L h

ME 515 - Numerical Solution of PDEs - Sullivan, Lec # 9 1 U  U  i) Centered : P i 1 i 1 ; multiplying the FD form e 2 h by h 2 :

1 + P e h - 2 1 - P e h = 0 2 2 P h Note: Diag. Dominance when e  1 i.e. P h  2 2 e (Weak Form) A 2nd order linear constant coeff. soln => exp( )

Exact Solution of Difference Equations :

 P e h   P e h  U i 1  1    2 U i  U i 1  1    2   2 

U i  U i 1 Try i ; solve for  U i   2 U i 1   U i 1

 P e h   P e h   1    2    1   2  0  2   2  1 2   P e h   P e h  2   4  4  1    1   2  2        P e h  2  1    2 

ME 515 - Numerical Solution of PDEs - Sullivan, Lec # 9 2  2     P e h   1   1   1        2     P h 1  e 2

P h 1  e 2   P h 1  e 2 1  1 C o n s t a n t 

 P e h   1    2  2   P e h   1    2 

i U i  A  B 2 Exact Soln to PDE : 2  e x p P e h  U  C  D e x p P e 

------

The following soln satisfies the governing equation: V L  V x  e x p    e x p    D   D  U  V L e x p    1  D 

ME 515 - Numerical Solution of PDEs - Sullivan, Lec # 9 3 V L e x p    D   1 C  D  V L  V L  let e x p    1 e x p    1  D   D  V x L U  C  D e x p    C  D e x p P   D L  e

i U i  A  B 2  C  D e x p P e  or 2  e x p P e h  i 2  e x p P e i h   e x p P e 

------

P h 1  e 2 P e h   l e t   2 P h 2 1  e 2 1 2  1  1  

Binomial Expansion

Centered Formualtion gives: 2 3  2 3  2  1  1          1  2   2   2  

2 3 2  2  4 e x p 2   1  2       1  2   2 2  3   2 ! 3 ! 3

ME 515 - Numerical Solution of PDEs - Sullivan, Lec # 9 4 Ex. BC's U = 1  = 1 , U = 0

C o n s t .

U e x p ( P e  P e

0 

Numerical : Accuracy depends on agreement between and exp (Peh)

As h  0 : convergence with 0( ? ) (student try it)

As h  large : becomes negative! " S p u r i o u s U i O s c i l l a t i o n " w h e n F D P e h > 1 A n a l y t i c 2

i . e . P e h > 2

0 1 

ME 515 - Numerical Solution of PDEs - Sullivan, Lec # 9 5 V x P h  "Cell Peclet #" e D

d u ii) Alternative : "Upstream Weighting" of d  i.e. backward F.D.

2 x U i  U i  U i 1   P e    0 h 2  h 

1 + P e h - 2 - P e h 1 = 0

Note: Always - (Weak) Diagonal Dominance

Difference Equations :

2 1  P e h   2  P e h      0

2 2  P e h  2 P e h   4 1  P e h    2

2  P h  P h   e e 2

ME 515 - Numerical Solution of PDEs - Sullivan, Lec # 9 6 1  1 (Constant) and 2  1  P e h (Never Negative)

Or in terms of : upstream 2  1  2 

 Upstream Weighting  no spurious oscillation Accuracy : 2 v e r s u s e x p P e h 

d u iii) Alternative : "Downstream Weighting" of d  i.e forward Finite difference  x U i  U i 1  U i   P e    0 h 2  h 

1 - 2 + P e h 1 - P e h = 0

2 1  2  P e h    1  P e h    0

1 1  1 and 2  ---> 1  P e h

Same order approx. to e x p P e h  as case ii (upstream weighting) again in terms of : 2 3  downstream 2  1  2   4   8  

ME 515 - Numerical Solution of PDEs - Sullivan, Lec # 9 7 But : P e h  1  Oscillations

Summary:

Upstream P e h   ; 0 h  2 Centered P e h  2 ; 0 h  Downstream P e h  1 ; 0 h 

ME 515 - Numerical Solution of PDEs - Sullivan, Lec # 9 8 Wave Equation 2 U 2 U   0 t 2  E l l i p t i c i n S p a c e   H y p e r b o l i c O v e r a l l

U x , t   V x   e j t Periodic Solution:  A m p l i t u d e

Helmholtz Equation : will always work for a linear hyperbolic eqn.

2 2 2 2 2 2  V   V  0  x V i , j  y V i , j   h V i , j  0 E l l i p t i c

2 - D Molecule :

1

- 4 1 2 h 2 1

1 = 0

ME 515 - Numerical Solution of PDEs - Sullivan, Lec # 9 9

Diagonal Dominance:

- lost as h  0 Cannot converge to PDE w/ D.D. - available only when

2 h 2  4  4 2 h 2  8

 h  Poor accuracy ; for ~ 1% , need 1 0 2  L    s o t h i s i s h    L 2 0 

Recall a U x x  b U x y  c U y y  d U x  e U y  f U  g a U  c U  f U  g x x y y and assumed f  0 & for f < 0 speed convergence Telegraph Equation

2 U U 2 U    c 2  0 t 2 t x 2

is dampening or frictions factor which is necessary It allows initial conditions to decay

ME 515 - Numerical Solution of PDEs - Sullivan, Lec # 9 10