“ALLEN`S” METHOD - Personal.psu.edu

advertisement
“ALLEN’S” METHOD
Introduction
Assume we have an equation where both the first and second derivative are
present
a (x)
d 2T
dT
 b( x )
 c( x ) T  d ( x )
2
dx
dx

A, b, c and d are piecewise continuous in the interval

The differential equation is non-homogeneous
The solution is composed of a particular solution and the solution to the
homogeneous equation.
Homogeneous Solution
a (x)
d 2T
dT
 b( x )
 c( x )T  0
2
dx
dx
TC  K1f1 ( x)  K 2 f 2 ( x)
where K1 and K2 are integration constants.
Particular Solution
T = TP
Complete Solution
T  TP  K1 f1 ( x)  K2 f 2 ( x)
For our application we will assume that d(x) is a constant (call it C). And to focus on
diffusion equations, I’ll take a(x)=1, b(x)=0, and c(x)=0. The particular solution may be
written as: T p 
Cx 2
. Assuming this solution is valid between mesh points xi-1 and xi+1,
2
we can determine the values of C, K1, and K2, by evaluating the solution at mesh points i1, i, and i+1
Ti 1  K1 f1 ( xi 1 )  K 2 f 2 ( xi 1 ) 
Cx
Ti  K1 f1 ( xi )  K 2 f 2 ( xi )  i
2
Cxi 1
2
2
2
Ti 1  K1 f1 ( xi 1 )  K 2 f 2 ( xi 1 ) 
Cxi 1
2
2
These three expressions are used to form a finite difference equation at point i.
Example: Laplace Equation in Cartesian coordinates
 2T  2T

0
x 2 y 2
Define  and  as

 2T
x 2

 2T
y 2
So the Laplace equation is +=0.
Treat  as constant about a point of evaluation at xo from the point at xo-x
(denoted xW ) to the the point at xo+x (denoted xE ). The solution of the
equation:
 2T

x 2
is
T ( x) 
x 2
 Ax  B
2
The solution at the three grid points is:
TE 
x E 2
 AxE  B
2
1)
TO 
xO 2
 AxO  B
2
2)
TW 
x w 2
 Axw  B
2
3)
Subtract (3) from (2)
TO  TW 


4)

5)

xO 2  x w 2  A( xO  x w )
2
Subtract (2) from (1)
TE  TO 


x E 2  xO 2  A( x E  xO )
2
Subtract (4) from (5)
TE  2TO  TW 


x E 2 2x O 2  x W 2
2

 


Note x E 2 2 xO 2  xW 2  xO  x   2 xo2  xO  x   2x 2
So

2
TE  2TO  TW
x 2
Likewise it can be shown that

TN  2TO  TS
y 2
The finite difference equation is
TN  2TO  TS TE  2TO  TW
+
O
y 2
x 2
2
Example: Laplace Equation in Cylindrical coordinates
D.E.  2 T  O
1  2 T  2 T 1 T


O
r 2  2 r 2 r r
 O
Define

d 2 T 1 dT

dr 2 r dr
One integration gives:
dT A 2r
 
dr
r
4
r 2
Solution is T  B  A Inr 
4
Expand Ti , j1  B  A In rj1 
Ti , j  B  A In r j 
(rj1 ) 2
4
(r j ) 2
Ti, j1  B  A In rj-1 
4
(rj1 ) 2
4
Solve the equations simultaneously
  r j1 
 rj

 ln  r j  Ti , j1  Ti , j  ln  r j1  Ti , j1  Ti , j



  4 
 rj

  r j1 
2
2
2
2
 ln  r j  r j1 r j  ln  r j1  r j1 r j







Now solve for the azimuthal operator







1 d 2T
r 2 d 2
Solution can be taken directly for the Cartesian example.
T ( r )  
( r ) 2
 C ( r )  D
2
following the Cartesian example, we evaluate this at three consecutive points
giving:

Ti 1, j  2Ti , j  Ti 1, j
(rO ) 2
The resulting expressions are substituted into
 O
Note that this approach does not automatically provide an error estimate. That is
obtained by substituting Taylor expansions for the off-center points into the final
difference equations, and inspecting the results.
Summary
When we use the Taylor Series method to form the finite difference equations we also
obtained an expression for the error introduced. At the present time, we have used the
error term to identify the “order” of the approximation. Can we do anything more with
the information contained in the expression for the error term?
Download