Set #9

advertisement
EGR 599 (Spring 2005)
____ _________________
LAST NAME, FIRST
Problem set #9
1. The Laplace’s equation
  2u  2u 
 2  2  = 0
y 
 x
is given with the following boundary conditions
and
u(0,y) = u(a,y) = 0
u(x,0) = 0
u(x,b) = f2(x)
0<y<b
0<x<a
0<x<a
Use the method of separation of variables to obtain the solution (show all your work)

u(x,y) =

n 1
Bn =
 n 
 n 
x  sinh 
y  , where
Bnsin 
 a 
 a 
2
 n b 
a sinh 

 a 

a
0
f 2 ( x ) sin(
n x
)dx
a
Apply this solution to a 11 square plate where one side is at 100 and the other three sides are
held at 0. Use Matlab pdetool to solve this problem numerically and provide the solution in a 3D graph.
Solution
We assume that u(x,t) can be separated into X(x), a function of x alone, and Y(y), a function of y
alone.
u(x,t) = X(x) Y(y)
From the following relations
dX
u
=T
x
dx

d2X
 2u
=
T
x 2
dx 2
u
dY
=T
y
dy

 2u
d 2Y
=
T
y 2
dy 2
The original PDE becomes
Y
d2X
d 2Y
=0

X
dx 2
dy 2
Divide the above equation by XY to obtain
1 d2X
1 d 2Y
=

=  2 = constant
2
2
X dx
Y dy
Since the LHS depends on x only, and the RHS depends on y only, they must equal to a constant
 2. The constant must be negative for non-trivial solution. The separation constant should be
negative for the direction with both homogeneous boundary conditions. For this problem, xdirection has the homogeneous boundary condition at both ends.
The boundary conditions on u(x,t) are changed to the boundary condition on X(x)
u(0,y) = 0  X(0) Y(y) = 0  X(0) = 0
u(a,y) = 0  X(a) Y(y) = 0  X(a) = 0
The ODE with respect to x is
d2X
=  2X  X = C1cos(x) + C2sin(x)
dx 2
The constant C1 can be determined from the boundary condition at x = 0
At x = 0, X = 0 = C1(1) + C2(0)  C1 = 0
At x = a, X = 0 = C2sin(a)
To avoid the trivial solution, C2  0 and
sin(a) = 0  a = n  n =
n
a
The solution with respect to x is
 n 
x  , n = 1, 2, 3, …
X = Xn = C2sin 
 a 
The ODE with respect to y is
1 d 2Y
= 2  Y = An’cosh(ny) + Bn’sinh(ny)
Y dy 2
The constant An’ can be determined from the boundary condition at y = 0,
Y(0) = 0 = An’  Y = Bn’sinh(ny)
The product solution is then
 n 
 n 
x  sinh 
y
un(x,t) = Bnsin 
 a 
 a 
The general solution for the steady two dimensional heat equation is

u(x,y) =

n 1
 n 
 n 
x  sinh 
y
Bnsin 
 a 
 a 
The constants Bn can be determined from the boundary condition at y = b
 n 
 n 
x  sinh 
b
Bnsin 
 a 
 a 

u(x,b) = f2(x) =

n 1
 n 
b  are then obtained from the Fourier sine series expansion of f2(x)
The coefficients Bn sinh 
 a 
Bn =
2
 n b 
a sinh 

 a 

a
0
f 2 ( x ) sin(
n x
)dx
a
For a 11 square plate where one side is at 100 and the other three sides are held at 0, a = 1, b =
1, f2(x) = 100.

u(x,y) =

Bnsin nx  sinh ny 
n 1
Bn =
1
200
200
(1- cos(n))
sin( nx)dx =

sinh n  0
n sinh( n )
For n even Bn = 0, for n odd Bn =
u(x,y) =
400



k 1
400
n sinh( n )
sin( 2k  1)x sinh( 2k  1)y
sinh( 2k  1)
( 2k  1)
Color: u Height: u
100
90
100
80
80
70
60
60
40
50
40
20
30
0
1
20
0.8
1
0.6
0.8
0.6
0.4
10
0.4
0.2
0.2
0
0
Matlab solution for a 11 square plate where one side is at 100.
0
2. Use the method of separation of variables to obtain the solution of the wave equation
2
 2u
 2u 
2 u
=
c


 x 2 y 2  , where c = 1/
t 2


where u(x,y, t) = 0 on the boundary of a 11 square membrane, u(x,y, 0) = x(x – 1)y(y – 1), and
the initial velocity is zero. Use Matlab pdetool to solve this problem numerically and provide
the solution in a 3-D graph at t = 2, 4, 6, 8, and 10.
Solution
u(x,y, t) =
 
n odd m odd

64
sin mx  sin ny  cos m 2  n 2 t
 m 3n 3
6

Time=2 Color: u Height: u
0
-0.01
0
-0.01
-0.02
-0.02
-0.03
-0.03
-0.04
-0.05
-0.04
-0.06
-0.07
1
-0.05
0.8
1
0.6
0.8
0.6
0.4
0.4
0.2
0.2
0
0
-0.06
Time=4 Color: u Height: u
0.045
0.04
0.05
0.035
0.04
0.03
0.03
0.025
0.02
0.02
0.01
0.015
0
1
0.01
0.8
1
0.6
0.8
0.005
0.6
0.4
0.4
0.2
0.2
0
0
0
Time=6 Color: u Height: u
0
-0.005
-0.01
-0.015
-0.0126
-0.02
-0.025
-0.03
1
0.8
1
0.6
0.8
0.6
0.4
0.4
0.2
0.2
0
0
-0.0251
Time=8 Color: u Height: u
4.5
x 10
-3
4
5
3.5
4
3
3
2.5
2
2
1
1.5
0
1
-1
1
0.5
0.8
1
0.6
0.8
0
0.6
0.4
0.4
0.2
0.2
0
0
-0.5
3. Three edges of a thin 1- by 2-m plate are held at 0oC, while the fourth edge, at y = 1 m, is
held at 100oC. The steady state temperature distribution in the plate is

T(x, y) =
 A n sin( Bn x )exp( C n y)  exp( C n y)
n 1
where An = ________________ Bn = _______________
Cn = __________________
Solution
Solution: (From Don Phillippi)
Hand calculation:
Based on conditions noted above the following is concluded:
a  2 ,b  1
f 2 x  100
and
and
Bn equation should be used
(page 5-53 class notes)

 nπ 
 nπ 
u x , y    Bn sin  x  sinh 
y
 a 
 a 
n 1
Basic equation is:
modify the basic equation to fit the problem statement yielding:

nπ nπ
 nπ 
 nπ 

u x , y    An sin  x  sinh 
y  where Bn equals
a
2
 a 
 a 
n 1


C y
C y
nπ nπ
 nπ  e n  e n

note that sinh 
therefore C n equals
y 
a
2
2
 a 
therefore Bn (from page 5-53) in basic equation equals An in problem statement
Begin by solving the basic equation, then put it is the specified form to find the
requested unknowns:
2
2
 nπ 
 nπ 
f 2 x  sin  x dx =
100 sin  x dx


 nπb  0
 nπb  0
 a 
 a 
a sinh 
2 sinh 


 a 
 a 
a
An 
a
100
2
200
 nπ 
 nπ 
cos x 
An 
sin  x dx =

 nπ  nπ
 nπ 
 2 
 2 
sinh  
2 sinh   0
 2 
 2 
2
2
0
An 
200
1  cos nπ 
 nπ 
nπ sinh  
 2 

An 

200
n
1   1
 nπ 
nπ sinh  
 2 

3. (continued):
T(x, y) =


200  1   1
 nπx 
 nπy 
sin 
 sinh 


π n1
2 
 nπ 
 2 
n sinh   
 2 
n
replace sinh terms with e terms to match problem statement:
200 
T(x, y) =

π n 1
T(x, y) =
1   1 
n
n
e

Cn
e
2
Cn



C y
C y
 nπx  e n  e n
sin 

2
 2 
200  1   1
 nπx  Cn y
C y
sin 
 e e n

Cn
Cn
π n 1 n e  e
2


n





since subscript implies “n” terms, leave in terms of “n”
An 



nπ
2
nπ
Note: could input C n 
, but it looks nicer this way
2
200
n
1   1
C n
nπ e  e
Cn
where C n 
and from above:
Bn 
nπ
2
and
Cn 
nπ
2
%Prob9_1 MATLAB program to plot u(x,y,t)
x=[0:.02:2];
y=[0:.02:1];
[X,Y]=meshgrid(x,y);
n1=length(X);n2=51;
uxy=zeros(n2,n1);
%t=infinity, steady state problem
for n=1:200
Cn=n*pi./2;
uxy=(1-(-1)^n)*sin(n*pi./2*X).*sinh(Cn*Y)./n/(sinh(Cn))+uxy;
end
uxy=200*uxy/pi;
mesh(X,Y,uxy)
%End M-file
3. (continued):
4. Use d’Alembert’s formula to solve the following boundary value problem
2
 2u
2 u
= c
t 2
x 2
c = 1, L= 1
B.C. : u(0,t) = 0
u(L,t) = 0, for t  0
and
 2 x if 0  x  1 / 2
I.C. : u(x,0) = f(x) = 
2(1  x ) if 1 / 2  x  1
u
(x,0) = g(x) = x, for 0  x  L
t
and
Solution: (From Don Phillippi)
Hand calculation:
(from pages 5-23 through 5-25 notes)
Initial conditions:
and:
ux,0  f x  2x
0 x
ux,0  f x  21  x
1
 x 1
2
1
2
therefore: F x  Gx  f x
for:
u
x ,0  g x   x
t
u u α u β


t α t β t
α
β
 c and
 c
α  x  ct and β  x  ct 
t
t
u
x ,0  c dF  c dG  c dF  c dG where dα  dβ  dx
t
dα
dβ
dx
dx
u α ,β   F α   Gβ  
u
x ,0  c dF  c dG  cF' x   cG' x   g x   x
t
dx
dx
dividing through by “c” and integrating both sides with respect to x yields:
x
x
x
1 *
x0 F' xdx  x0G' xdx  c x0 g s ds
where “s” is a dummy
variable
x
1
F x   Gx   F x0   Gx0    g * s ds
c x0
let:
k  x0   F  x0   G  x0 
4. (continued):
F  x   G  x   k  x0  
x
1 *
g s ds
c x0
using:
F x  Gx  f x
therefore:
F x    f x   F x   k x0  
yielding:
2 F  x   f  x   k  x0  
F x  
Gx  f x  F x
or
x
1 *
g s ds
c x0
x
1 *
g s ds
c x0
x
1
1
1
f  x   k  x0  
g * s ds
2
2
2c x0
Gx  f x  F x putting in above yields:
x
1

1
1

G x   f x    f x   k x0  
g * s ds 

2
2c x 0
2

x
or:
1
1
1
G  x   f  x   k  x0  
g * s ds

2
2
2c x0
replace x by x + ct for F(x) and x by x – ct for G(x), yielding:
1
1
1
F x  ct   f x  ct   k x0  
2
2
2c
Gx  ct  
1
1
1
f x  ct   k x0  
2
2
2c
x  ct
 g s ds
*
x0
x ct
 g s ds
*
x0
inverting integral:
x
1
1
1 0 *
f x  ct   k x0  
g s ds
2
2
2c x ct
adding F(x+ct) and G(x-ct):
Gx  ct  
ux,t   F x  ct   Gx  ct  or:
u  x ,t  

x  ct

1 *
1
f x  ct   f * x  ct  
g * s ds
2
2c x ct
since c = 1 (given in problem statement):


x t
1
1
ux ,t   f * x  t   f * x  t    g * s ds
2
2 x t
4. (continued):
x t
1
1
g * s ds  Gx  t   Gx  t 

2 x t
2
where g * s  an odd 2-periodic extension and G is the anti-derivative of g * s 
x
let:
x
1
1
G  x    g *  z dz   zdz  x 2 
2
2
1
1
x t
1
1
g * s ds  Gx  t   Gx  t 

2 x t
2
consolidating:
u  x ,t  
where:
and:


1 *
1
f x  t   f * x  t   G x  t   G x  t 
2
2
 2 x if 0  x  1 / 2
f * x  = 
2( 1  x ) if 1 / 2  x  1
1 2 1
 x 
if  1  x  1
2
 G( x  2 ) otherwise
G(x) =  2
5. Determine the first time the strings returns to its initial shape for the string of unit length with
boundary conditions u(0,t) = 0 and u(L,t) = 0, and initial conditions:
a) f(x) = sin x, g(x) = 0, c =
1

Ans: t =2
 2 x if 0  x  1 / 2
b) f(x) = 
, g(x) = x, c = 1
2(1  x ) if 1 / 2  x  1
Ans: t =2
6. Consider the following boundary value problem
2
 2u
2 u
= c
t 2
x 2
B.C. : u(0,t) = 0
c = 1, L= 1
and
u(L,t) = 0, for t  0
4x 0  x  1/ 4

u

I.C. : u(x,0) = f(x) = 4(1 / 2  x ) if 1 / 4  x  1 / 2 ,
(x,0) = g(x) = 0

t

0 if 1 / 2  x  1

a) Use d’Alembert’s method to plot the string at time t = 0, ¼, ½.
1
0.5
0.5
f(x-.5)
f(x-.25)
1
0
-0.5
-0.5
0
0.2
0.4
0.6
0.8
-1
1
1
1
0.5
0.5
f(x+.5)
f(x+.25)
-1
0
-0.5
-1
0.2
0.4
0.6
0.8
1
0
0.2
0.4
0.6
0.8
1
0
0.2
0.4
0.6
0.8
1
-0.5
0
0.2
0.4
0.6
0.8
-1
1
1
1
0.5
0.5
0
-0.5
-1
0
0
u(t=.5)
u(t=.25)
0
0
-0.5
0
0.2
0.4
0.6
0.8
1
-1
x
x
b) For t = ¼, identify the points on the string that are still in rest position.
Ans: .75 < x  1
c) Take a point x on the string with zero initial displacement (1/2  x  1). How long does it take
before the point x starts to vibrate?
1
Ans: t > x 
2
d) What is the answer in (c) for an arbitrary string constant c > 0?
Ans: t >
7. Solve
x 1/ 2
c
u
 2u
= c2 2
t
x
B.C. : u(0,t) = 0
c = 1, L= 
and
u(L,t) = 0, for t  0
33x if 0  x   / 2

I.C. : u(x,0) = f(x) = 
33(  x ) if
 /2  x 
( 1) k e  ( 2 k 1) sin( 2k  1) x
Ans: u(x,t) =

 k 0
(2k  1) 2
132

2
Download