11odes.mws

Partial Differential Equations PowerTool

by Dr. Jim Herod

Section 3.1: Ordinary Differential Equations Review

Maple Packages in Section 3.1

>    restart;

>   

 

    In order that ideas from ordinary differential equations will be fresh when we begin a discussion of partial differential equations, we review pertinent ideas from ordinary differential equations in this Section.

We make our review by asking six questions.

Question 1.  Suppose lambda  > 0. Which of these is a pair of linearly independent solutions for Y '' - lambda^2  Y = 0 on [0, pi ]?

A. exp( lambda  x) and exp( - lambda  x),      C. sinh( lambda  x ) and cosh( lambda  x),

B. sin( lambda  x) and cos( lambda  x ),         D. sinh( lambda  x ) and sinh( lambda  ( pi  - x)).

Answer Using Maple

Regarding Part A

The functions exp( lambda   x ) and exp( -lambda   x ) are linearly independent. We ask if they are solutions for the differential equation.

>    Y1:=x->exp(lambda*x);
Y2:=x->exp(-lambda*x);

Y1 := proc (x) options operator, arrow; exp(lambda*x) end proc

Y2 := proc (x) options operator, arrow; exp(-lambda*x) end proc

>    diff(Y1(x),x,x)-lambda^2*Y1(x);
diff(Y2(x),x,x)-lambda^2*Y2(x);

0

0

We see that these functions solve the differential equation.

Regarding Part B

The functions sin( lambda   x ) and cos( lambda   x ) are linearly independent. We ask if they are solutions for the differential equation.

>    Y1:=x->sin(lambda*x);
Y2:=x->cos(lambda*x);

Y1 := proc (x) options operator, arrow; sin(lambda*x) end proc

Y2 := proc (x) options operator, arrow; cos(lambda*x) end proc

>    diff(Y1(x),x,x)-lambda^2*Y1(x);
diff(Y2(x),x,x)-lambda^2*Y2(x);

-2*sin(lambda*x)*lambda^2

-2*cos(lambda*x)*lambda^2

We see that these functions do not solve the differential equation.

Regarding Part C

The functions sinh( lambda   x ) and cosh( lambda   x ) are linearly independent. We ask if they are solutions for the differential equation.

>    Y1:=x->sinh(lambda*x);
Y2:=x->cosh(lambda*x);

Y1 := proc (x) options operator, arrow; sinh(lambda*x) end proc

Y2 := proc (x) options operator, arrow; cosh(lambda*x) end proc

>    diff(Y1(x),x,x)-lambda^2*Y1(x);
diff(Y2(x),x,x)-lambda^2*Y2(x);

0

0

We see that these functions solve the differential equation.

Regarding Part D

The functions sinh( lambda   x ) and sinh( lambda  ( Pi  - x )  linearly independent. We ask if they are solutions for the differential equation.

>    Y1:=x->sinh(lambda*x);
Y2:=x->sinh(lambda*(Pi-x));

Y1 := proc (x) options operator, arrow; sinh(lambda*x) end proc

Y2 := proc (x) options operator, arrow; sinh(lambda*(Pi-x)) end proc

>    diff(Y1(x),x,x)-lambda^2*Y1(x);
diff(Y2(x),x,x)-lambda^2*Y2(x);

0

0

We see that these functions solve the differential equation. In time, we will see that an advantage for this pair of solutions of the differential equation not shared by the other two pair of solutions is that one function is zero at 0 and the other is zero at Pi .

Ask Maple

Let's see what solutions Maple will give.

>    dsolve(diff(Y(x),x,x)-lambda^2*Y(x)=0,Y(x));

Y(x) = _C1*exp(lambda*x)+_C2*exp(-lambda*x)

>    dsolve(diff(Y(x),x,x)-lambda^2*Y(x)=0,Y(x),method=laplace);

Y(x) = Y(0)*cosh(lambda*x)+D(Y)(0)/lambda*sinh(lambda*x)

>   

What solutions you get depends on what methods are used.

Question 2.  Suppose lambda  > 0. Which of these is a pair of linearly independent solutions for Y '' + lambda^2  Y = 0 on [0, pi ]?

A. exp( lambda  x) and exp( - lambda  x),      C. sinh( lambda  x ) and cosh( lambda  x),

B. sin( lambda  x) and cos( lambda  x ),         D. sin( lambda  x ) and sin( lambda  ( pi  - x)).

Answer Using Maple

Regarding Part A

The functions exp( lambda   x ) and exp( -lambda   x ) are linearly independent. We ask if they are solutions for the differential equation.

>    Y1:=x->exp(lambda*x);
Y2:=x->exp(-lambda*x);

Y1 := proc (x) options operator, arrow; exp(lambda*x) end proc

Y2 := proc (x) options operator, arrow; exp(-lambda*x) end proc

>    diff(Y1(x),x,x)+lambda^2*Y1(x);
diff(Y2(x),x,x)+lambda^2*Y2(x);

2*lambda^2*exp(lambda*x)

2*lambda^2*exp(-lambda*x)

We see that these functions do not solve the differential equation.

Regarding Part B

The functions sin( lambda   x ) and cos( lambda   x ) are linearly independent. We ask if they are solutions for the differential equation.

>    Y1:=x->sin(lambda*x);
Y2:=x->cos(lambda*x);

Y1 := proc (x) options operator, arrow; sin(lambda*x) end proc

Y2 := proc (x) options operator, arrow; cos(lambda*x) end proc

>    diff(Y1(x),x,x)+lambda^2*Y1(x);
diff(Y2(x),x,x)+lambda^2*Y2(x);

0

0

We see that these functions do solve the differential equation.

Regarding Part C

The functions sinh( lambda   x ) and cosh( lambda   x ) are linearly independent. We ask if they are solutions for the differential equation.

>    Y1:=x->sinh(lambda*x);
Y2:=x->cosh(lambda*x);

Y1 := proc (x) options operator, arrow; sinh(lambda*x) end proc

Y2 := proc (x) options operator, arrow; cosh(lambda*x) end proc

>    diff(Y1(x),x,x)+lambda^2*Y1(x);
diff(Y2(x),x,x)+lambda^2*Y2(x);

2*sinh(lambda*x)*lambda^2

2*cosh(lambda*x)*lambda^2

We see that these functions do not solve the differential equation.

Regarding Part D

The functions sin( lambda   x ) and sin( lambda  ( Pi  - x )  linearly independent. We ask if they are solutions for the differential equation.

>    Y1:=x->sin(lambda*x);
Y2:=x->sin(lambda*(Pi-x));

Y1 := proc (x) options operator, arrow; sin(lambda*x) end proc

Y2 := proc (x) options operator, arrow; sin(lambda*(Pi-x)) end proc

>    diff(Y1(x),x,x)+lambda^2*Y1(x);
diff(Y2(x),x,x)+lambda^2*Y2(x);

0

0

We see that these functions solve the differential equation. In Question 5, we will see that an advantage for this pair of solutions of the differential equation not shared by the other pair of solutions is that one function is zero at 0 and the other is zero at Pi .

Ask Maple

Let's see what solutions Maple will give

>    dsolve(diff(Y(x),x,x)+lambda^2*Y(x)=0,Y(x),output=basis);

[sin(lambda*x), cos(lambda*x)]

>   

Question 3.  Suppose lambda  > 0. Which of these is a bounded solution for Y '' - lambda^2  Y = 0 on [0, infinity )?

A. exp( lambda  x)    B. exp(- lambda  x)     C. sinh( lambda  x)      D. cosh( lambda  x)

There are two issues here: which is a solution and which is bounded on the specified interval.

Answer Using Maple

We have already seen that each of these is a solution for the differential equation. The only question that remains is which is bounded. Using lambda  = 1, we sketch all the graph in colors red, blue, green, and black, respectively.

>    plot([exp(x),exp(-x),sinh(x),cosh(x)],x=0..2,
            color=[red,blue,green,black]);

[Maple Plot]

>   

Question 4.  Which of these is a bounded solution on the interval [0, 5] of the differential equation

           r^2  R ''(r) + r R '(r) - 9 R(r) = 0?

A. exp(3 r)       B. r^3        C. sin(3 r)       D. exp(-3 r)       E. 1/ r^3        F. cosh(3 r)

Answer Using Maple

It is easy enough to find what are the solutions for the differential equation.

>    dsolve(r^2*diff(R(r),r,r)+r*diff(R(r),r)-9*R(r)=0,R(r),
           output=basis);

[1/(r^3), r^3]

We have left only to check which of these is bounded on [0,1]. Is this clear? We plot both these.

>    plot([1/r^3,r^3],r=0..1,R=0..5,color=[black,red]);

[Maple Plot]

>   

Question 5.  If  u(x,y) = sum(a[p]*sin(p*x)*sinh(p*y))  + sum(b[p]*sin(p*x)*sinh(p*(Pi-y)))   and

                           u(x,0) = 0, u(x, pi ) = sin(2 x)

what are the a[p]  's   and     b[p]  's?

Answer Using Maple

We define the function u as specified in the question.

>    u:=(x,y)->sum(a[p]*sin(p*x)*sinh(p*y),p=1..infinity)+
             sum(b[p]*sin(p*x)*sinh(p*(Pi-y)),p=1..infinity);

u := proc (x, y) options operator, arrow; sum(a[p]*sin(p*x)*sinh(p*y),p = 1 .. infinity)+sum(b[p]*sin(p*x)*sinh(p*(Pi-y)),p = 1 .. infinity) end proc

We have two pieces of information.

>    0=u(x,0);

0 = sum(b[p]*sin(p*x)*sinh(p*Pi),p = 1 .. infinity)

>    sin(2*x)=u(x,Pi);

sin(2*x) = sum(a[p]*sin(p*x)*sinh(p*Pi),p = 1 .. infinity)

Before we determine the a 's and b 's, note how convenient it was that sin( p y )=0 at y  = 0 and that sin( p  ( Pi   -y ))=0 at y  = Pi .

As you can see by looking at the next to last equation above, the first two pieces of information implies that all the b[p] 's are zero, and the second piece gives the last equation above, which implies that all the a[p] 's is zero except the second one -- p  = 2 -- and a[2]  =  1/sinh( 2*pi ). Thus here is a graph for u.

>    plot3d(1/sinh(2*Pi)*sin(2*x)*sinh(2*y), x=0..Pi,y=0..Pi,axes=NORMAL);

[Maple Plot]

>   

Question 6.  If u(r, theta ) = sum(a[p]*sin(p*theta)*r^p,p)  + sum(b[p]*cos(p*theta)*r^p,p)   and

     u(1, theta ) = 1 + 3 cos(3 theta ) + 5 sin( 2 theta )

then what is u(r, theta ), u(0,0), and u(1/2, pi /4)?

Answer Using Maple

This problem is similar to the one above. First, define u as above.

>    u:=(r,theta)->sum(a[p]*sin(p*theta)*r^p,p=1..infinity) +
                  sum(b[p]*cos(p*theta)*r^p,p=0..infinity);

u := proc (r, theta) options operator, arrow; sum(a[p]*sin(p*theta)*r^p,p = 1 .. infinity)+sum(b[p]*cos(p*theta)*r^p,p = 0 .. infinity) end proc

The information that is given specifies u  when r  = 1.

>    1+3*cos(3*theta)+5*sin(2*theta)=u(1,theta);

1+3*cos(3*theta)+5*sin(2*theta) = sum(a[p]*sin(p*theta),p = 1 .. infinity)+sum(b[p]*cos(p*theta),p = 0 .. infinity)

This implies that all a[p] 's and b[p] 's are zero except b[0]  = 1, b[3]  = 3, and a[2]  = 5.

We give u ( r , theta ), u (0,0), and u(1/2, pi /4).

>    u:=(r,theta)->5*sin(2*theta)*r^2+1+3*cos(3*theta)*r^3;

u := proc (r, theta) options operator, arrow; 5*sin(2*theta)*r^2+1+3*cos(3*theta)*r^3 end proc

>    u(0,0);

1

>    u(1/2,Pi/4);

9/4-3/16*2^(1/2)

Finally, we sketch the graph.

>    plot3d([r,theta,u(r,theta)],r=0..1,theta=-Pi..Pi,
             coords=cylindrical,axes=normal,orientation=[20,40],
             numpoints=2000, lightmodel=light1, style=patchnogrid);

[Maple Plot]

>   

In this Section 3.1, we have looked at some of the simple differential equations that will arise in obtaining solutions for partial differential equations. In getting solutions, one sometimes must choose among all the solutions available to make the computations easier.

>   

>   

EMAIL: herod@math.gatech.edu   or   jherod@tds.net

URL: http://www.math.gatech.edu/~herod

Copyright ©  2003  by James V. Herod

All rights reserved