You are on page 1of 39

Ordinary Differential Equations Lecture Notes

Dr E.T. Ngarakana-Gwasira1†1
Department of Mathematics,

University of Zimbabwe, P. O. Box MP 167,Mount Pleasant, Harare, Zimbabwe1 ,

1† Email address: ethelngarakana@gmail.com; Phone 0733 797 047


Course Outline

Ordinary Differential Equations Section


Duration : 4 Weeks

1. Basic techniques for the solution of first order ODE’s.

2. Basic techniques for the solution of second order ODE’s. Methods of undetermined coefficients,
reduction of order, and method of variation of parameters.

3. Series solutions of linear ODE’s, solutions near ordinary points, singular points, Euler equa-
tions.

4. Laplace transform methods for solving initial value problem (IVP), Laplace transform of the
elementary functions, properties of Laplace transform, inverse Laplace transform. Solution of
IVP.

1
Chapter 1

First Order Equations

Definition 1.0.1. An ordinary differential equation is an equation which expresses a relationship


between the derivatives of an unknown function, the independent variable, and the unknown function
itself. If there is only one independent variable, then it is an ordinary differential equation.

The adjective ordinary means that only ordinary derivatives appear in the equation; there are no
partial derivatives appearing in the equation. The order of a differential equation is the order of
the highest derivative appearing in it. The following equations for y(x) are first, second and third
order, respectively.
dy
y0 = = xy 2 , (1.0.1)
dx
y 00 + 3xy 0 + 2y = x2 , (1.0.2)
y 000 = y 00 y. (1.0.3)
A solution to the differential equation is a function y, which satisfies it identically (where t lies in
some interval). for example
y(t) = 3 cos t + sin 2t
is a solution of
y 00 + y = −3 sin 2t.
Example 1.0.1. Consider the following differential equation for a culture of bacteria which is
growing rapidly.
d
N (t) = κN (t)
dt
for all t > 0 where κ is the proportionality constant (birth rate).

The following apply to the above equation

1. The equation above is an ordinary differential equation because the equation expresses
a relationship between the unknown function N (t) and its derivative.

2
2. The equation is a first order differential equation because only the first derivative of the
unknown function N (t) appears in the equation.
3. The equation has constant coefficients because the unknown function N (t) and its deriva-
tives are multiplied only by constants, not by functions of the independent variable t.
4. The equation is linear because the unknown function N (t) and its derivatives appear only to
the first power.
5. The equation is also homogeneous because the function N (t) which is identically 0 for all t
satisfies the equation.
Definition 1.0.2. A differential equation is homogeneous if it has no terms that are functions of
the independent variable alone. Thus an inhomogeneous equation is one in which there are terms
that are functions of the independent variables alone.

y 00 + xy + y = 0 is a homogeneous equation.

y 0 + y + x2 = 0 is an inhomogeneous equation.

Exercise 1.0.1. Let y(t) be the unknown. Identify the order and linearity, of the following equations

1. (y + t)y 0 + y = 1
2. 3y 0 + (t + 4)y = t2 + y 00
3. y 000 = cos(2ty)

4. y (4) + ty 000 + cos t = ey

1.1 Methods of solution

1.1.1 Separation of variables technique

1. Isolate the derivative of the unknown function on one side of the equation.
2. Divide by the quantity on the other side of the equation.
3. Integrate both sides of the resulting equation making use of the Fundamental Theorem of
Calculus and the initial condition.

Exercise 1.1.1. Solve the following equations

dy
1. dt
= et+y

3
dy
2. dt
= tey
dy
3. dt
= ty + y + 2t + 2

4. (1 + ey ) dy
dt
= 1, y(0) = 1
dy 2
5. dt
= e−y+t , y(0) = 1

1.1.2 Integrating factor method

Another method of solving the general first order linear non homogeneous differential equations is
the integrating factor method. The following steps are to be followed in using the integrating factor
technique to solve first order non homogeneous, non autonomous equations.

1. Rearrange the given equation as necessary to be in the form


d
x(t) + a(t)x(t) = b(t).
dt
The coefficient of the derivative term must always be 1.
R
a(t)dt
2. Compute the integrating factor e .

3. Multiply both sides of the equation obtained in step 1 by the integrating factor. The result
is guaranteed to be of the form
d R R
[x(t)e a(t)dt ] = b(t)e a(t)dt
dt

4. Integrate both sides and solve for the unknown function. Make use of the initial conditions
and the fundamental theorem of calculus.
Example 1.1.1. Solve the I.V.P.
π √ π
cos(x)y 0 + sin(x)y = 2 cos3 (x)Sin(x) − 1, y( ) = 3 2, 0 ≤ x <
4 2
Solution
Rewriting the d.e to get the coefficient of the derivative to one we have
sin(x) 1
y0 + y = 2 cos2 (x) sin(x) − .
cos(x) cos(x)
This equation can be expressed as

y 0 + tan(x)y = 2 cos2 (x) sin(x) − sec(x).

The integrating factor (I.F) is


R
I.F = e tan xdx
= eln | sec x| = sec x

4
Multiplying through the rearranged d.e by the integrating factor we have

sec(x)y 0 + sec(x) tan(x)y = sec(x) cos2 (x) sin(x) − sec2 (x),

which is
[sec(x)y]0 = 2 cos(x) sin(x) − sec2 (x).
Integrating both sides we have
Z
sec(x)y = [2 cos(x) sin(x) − sec2 (x)]dx,
Z
= [sin(2x) − sec2 (x)]dx,

1
= − cos(2x) − tan(x) + c.
2
Thus
1
y(x) = − cos(x) cos(2x) − sin(x) + c cos(x).
2
After applying initial conditions, the result will be
1
y(x) = − cos(x) cos(2x) − sin(x) + 7 cos(x).
2
Exercise 1.1.2. Find the solution to the following I.V.P
1
ty 0 + 2y = t2 − t + 1, y(1) =
2

1.1.3 Exact first order differential equations

From calculus, if a function U (x, y) has continuous partial derivatives, its total or exact differential
is
∂u ∂u
dU (x, y) = dx + dy.
∂x ∂y
It then follows that if we have a function of two variables x and y being equal to a constant, then
its exact differential is zero. Solving any equation that can be reduced to the form
d
U (x, y) = 0, (1.1.1)
dx
dy
for someR function U gives U (x, y) = constant. Evidently the equation dx
= g(x) is equivalent to
d
dx
[y − g(x)dx] = 0.
dy
Any equation M (x, y) + N (x, y) dx = 0 can be written in the form (??) if and only if the function
U is such that
∂U ∂U
= M (x, y), and = N (x, y).
∂x ∂y
Given an equation of the form (1) when does such a function exist.

5
Theorem 1.1.1. Suppose M (x, y) and N (x, y) are continuous with continuous partial derivatives.
Then there exists a function U such that
∂U ∂U ∂M ∂N
= M (x, y), = N (x, y) iff = .
∂x ∂y ∂y ∂x
∂M ∂N
Definition 1.1.1. The d.e. M (x, y)dx + N (x, y)dy = 0 is exact iff ∂y
= ∂x

Note that in this case by theorem 1 there exists a function


∂U ∂U
U: = M (x, y) and = N (x, y)
∂x ∂y
∂U ∂U dy d
The d.e. M (x, y)dx + N (x, y)dy = 0 then becomes ∂x
+ ∂y dx
= 0 or dx
[U (x, y)] = 0.

Thus if the equation is exact, its solution is simply U (x, y) = constant

Example 1.1.2. Solve the d.e (x3 + 3xy 2 )dx + (3x2 y + y 3 )dy = 0

M (x, y) = x3 + 3xy 2 ⇒ ∂M∂y


= 6xy
N (x, y) = 3x2 y + y 3 ⇒ ∂N
∂x
= 6xy
The equation is exact and therefore there exist a function U such that
∂U ∂U
= M = x3 + 3xy 2 , = 3x2 y + y 3 N =
∂x ∂y
R R
Now U = M dx + h(y) = [x3 + 3xy 2 ]dx + h(y)
4 2
U (x, y) = x4 + 3x2 y 2 + h(y) to find h(y), differentiate the above equation w.r.t. y and use ∂U
∂y
=N
y4
to obtain h(y) = 4
.
y4
U (x, y) = 41 (x4 + 6x y +
2 2
4
) = constant

6
Tutorial 1. 1. Find the general solution of the following:
dy dy
(a) dt
= et+y (l) dt
= yt , y(0) = −1
dy dy
(b) dt
= tey (m) dt
= −2ty, y(0) = 2
dy dy (1+y 2 )
(c) dt
= ty + y + 2t + 2 (n) dt
= 1+t2
, y(0) = −1
(d) (1 + ey ) dy
dt
= 1, y(0) = 1 (o) dy
dt
= y sin2 t, y(0) = 1
dy dy
(e) dt
= ty (p) dt
= 4 + y2, y(0) = 0
dy dy cos t π
(f ) dt
= ty − 3y + 5t − 15 (q) dt
= cos y
, y(0) = 6
dy
(g) dt
= et−y (r) dy
dt
= 7y + 14, y(0) = 1
dy dy 1
(h) dt
= y(1 − y) (s) dt
= y 5 sin t, y(0) = 2
dy dy 2t
(i) dt
= ty + 3t + 2y + 6 (t) dt
= y
, y(0) = −1
dy dy 2
(j) dt
= −2ty 3 (u) dt
= ey+t , y(1) = 1
dy y dy 2
(k) dt
= t
(v) dt
= e−y+t , y(0) = 1

2. Find the general solution of the following:


dy dy
(a) = te−t (g) t = t2 cos t
dt dt
dy dy
(b) t + 3y − t2 − 4t = 0 (h) = −y + et
dt dt
dy dy
(c) t + 2y = sin t (i) = 2y + e2t
dt dt
dy dy
(d) t = y + t3 (j) = −y tan t + sec t
dt dt
dy dy 2y
(e) t = −y + t3 (k) =3+
dt dt 1 − t2
dy y dy
(f ) = +1+t (l) = −y cot t + 6 cos2 t
dt t dt

3. Find the general solution of the following:

(a) 2t + 3y + (3t − y) dy
dt
=0 (e) y 2 + t + (2ty + 1) dy
dt
=0
(b) 6ty + 2y 2 − 1 + (3t2 + 4ty + 2) dy
dt
=0 (f ) 2ty + t + (t2 + y) dy
dt
=0
(c) (y 2 + 1) cos t + 2y sin t dy
dt
=0 (g) y sec2 t + (tan t + 2y) dy
dt
=0
(d) 2t − 1y −1 − (2y + et ) dy
dt
=0 (h) 2ty 3 − y 2 + (3t2 y 2 − 2ty) dy
dt
=0

4. Find the values of constants n and m for which the equation


(xy n + x2 )dx + (x2 y m + y 3 )dy = 0 is exact.

5. Newton’s law of cooling states that if an object is hotter than the ambient temperature, then
the rate of cooling of the object is proportional to the temperature difference. A brick initially

7
at temperature 20o C is placed in an oven whose temperature at time t is (70 + 5t)o C. Find
the temperature of the brick at time t, assuming the proportionality constant in Newtons Law
of Cooling is 1.

6. Show that the differential equation


dy tan y − y − 2xy
=
dx sec y − x tan2 y + x2 + 2
2

is an exact equation and solve it.

7. Solve the differential equation



= −a sin θ − bψ

subject to the condition that ψ = 0 when θ = π3 .

8. (a) If I(x, y) is an integrating factor of

M (x, y)dx + N (x, y)dy = 0.

Show that  
∂M ∂N ∂I(x, y) ∂I(x, y)
I(x, y) − =N −M
∂y ∂x ∂x ∂x
and determine I(x, y), given that I(x, y) = I(y) (i.e a function of y alone).
(b) Hence, solve
ydx + (2x − yey )dy = 0.

8
Chapter 2

Second order differential equations

A second order d.e is linear if it can be written in the form

y 00 + p(x)y 0 + q(x)y = r(x).

The equation is linear in the unknown function y and its derivatives, whereas p(x), q(x) and r(x)
may be any given functions of x.

Superposition principle
If y1 (x) and y2 (x) are any two solutions of a linear homogeneous differential equation

y 00 + p(x)y 0 + q(x)y = 0,

then c1 y( x)+c2 y2 (x) is also a solution to the differential equation for any constants c1 and c2 . Linear
independence and dependence of solutions Two solutions y1 and y2 to the homogeneous
differential equation are linearly dependent if there exists c1 and c2 (6= 0) such that

c1 y1 + c2 y2 = 0

otherwise they are linearly independent.

Example 2.0.3. Show that y1 = cos x and y2 = sin x are linearly independent solutions (form a
basis of solutions) of the D.E. y 00 + y = 0

We now look at a condition under which y1 and y2 are linearly independent.

9
2.0.4 The wronskian

Suppose the functions y1 and y2 are differentiable on [a, b], the wronskian of y1 and y2 is the
determinant
y1 (x) y2 (x)
W (x) = 0 = y1 y20 − y10 y2
y1 (x) y20 (x)

2.1 Homogeneous second order equations

In order to solve the linear homogeneous D.E. with constant coefficients, the general method is as
follows:

• Try a solution of the form emx . This produces the characteristic equation (a quadratic eqn in
this case) to be solved for m.

• Solve the characteristic equation.

• The general solution of the D.E is obtained from the roots of the characteristic equation.

• Make use of initial conditions to determine the unknown constants in the general solution.
d2 x dx
Example 2.1.1. Solve 2
= −4 − 3x
dt dt
Let x(t) = emt , then, x0 (t) = memt , x00 (t) = m2 emt , substituting in the D.E we have
m2 emt + 4memt + 3emt = 0
(m2 + 4m + 3)emt = 0, −→ (m2 + 4m + 3) = 0
m = 3 orm = −1
hence the general solution is
x(t) = c1 e−3t + c2 e−t .

As we have noted, the characteristic equation is quadratic and so will have two roots, m1 and m2 .
The roots will have three possible forms. These are

1. Real, distinct roots, m1 6= m2 .

2. Complex roots, m1,2 = a ± bi.

3. Double roots,m1 = m2 = m.

10
2.1.1 Case 1 Real, distinct roots, m1 6= m2 .

Example 2.1.2. Solve the following IVP. y 00 + 11y 0 + 24y = 0, y(0) = 0, y 0 (0) = −7
Solution
The characteristic equation is
m2 + 11y 0 + 24y = (m + 8)(m + 3) = 0
whose roots arem1 = −8 and m2 = −3 and so the general solution is
y(t) = c1 e−8t + c2 e−3t and its derivative is
y 0 (t) = −8c1 e−8t − 3c2 e−3t
Now, plug in the initial conditions to get the following system of equations.
0 = y(0) = C1 + C2
(2.1.1)
−7 = y 0 (0) = −8C1 − 3C2

giving C1 = 7/5 and C2 = −7/5.


The actual solution to the differential equation is then

y(t) = 7/5e−8t − 7/5e−3t

Exercise 2.1.1. Solve the following initial value problems

1. y 00 + 3y 0 − 10y = 0 y(0) = 4, y 0 (0) = 2.

2. 3y 00 + 2y 0 − 8y = 0 y(0) = −6, y 0 (0) = −18.

3. 4y 00 − 5y 0 = 0 y(−2) = 0, y 0 (2) = 7.

2.1.2 Case 2 Complex roots, m1,2 = a ± bi.

Consider the D.E


ay 00 + by 0 + cy = 0
whose characteristic equation is am2 + bm + c = 0, whose roots are complex in the form

m1,2 = λ ± µi

the general solution to the D.E is

y(t) = C1 eλt cos µt + C2 eλt sin(µt).

Example 2.1.3. Solve the I.V.P y 00 − 4y 0 + 9y = 0, y(0) = 0, y 0 (0 = −8) √


The characteristic equation for this D.E is m2 − 4m + 9 = 0 whose roots are m1,2 = 2 ± i 5.
The general solution to the D.E is then
√ √
y(t) = C1 e2t cos( 5t) + C2 e2t sin( 5t)
−8 √
After applying initial conditions show that √ e2t sin( 5t)
5

11
Exercise 2.1.2. Solve

1. y 00 − 8y 0 + 17y = 0, y(0) = −4, y 0 (0) = −1

2. 4y 00 + 24y 0 + 37y = 0, y(π) = 1, y 0 (π) = 0

2.1.3 Case 3 Repeated roots, m1 = m2 = m.

Consider the D.E


ay 00 + by 0 + cy = 0
whose characteristic equation is am2 + bm + c = 0, whose roots are complex in the form

m1 = m2 = m

. This leads to a problem however. Recall that the solutions are

y1 (t) = em1 t = emt , y2 (t) = em2 t = emt

Then the general solution is


y(t) = c1 emt + c2 temt .

Example 2.1.4. Solve the I.V.P y 00 − 4y 0 + 4y = 0, y(0) = 12, y 0 (0) = −3


Show that the general solution is y(t) = c1 e2t + c2 te2t and hence y(t) = 12e2t − 27te2t

Exercise 2.1.3. Solve

9
1. 16y 00 − 40y 0 + 25y = 0, y(0) = 3, y 0 (0) = −
4
2. y 00 + 14y 0 + 49y = 0, y(−4) = −1, y 0 (−4) = 5

2.2 Reduction of Order

Finding solutions to non-constant coefficient, second order D.Es of the form

p(t)y 00 + q(t)y 0 + r(t)y = 0.

In general, finding solutions to these kinds of differential equations can be much more difficult than
finding solutions to constant coefficient differential equations. Reduction of order requires that a
solution be known. Without this known solution wo will not be able to do reduction of order.

12
Example 2.2.1. Find the general solution to 2t2 y 00 + ty 0 − 3y = 0 given that t−1 is a solution.
Once we have a first solution we will then assume that a second solution will have the form

y2 (t) = v(t)y1 (t)

for a proper choice of v(t). To determine the proper choice, we plug the guess into the differential
equation and get a new differential equation that can be solved for v(t). So, let’s do that for this
problem. Here is the form of the second solution as well as the derivatives that we’ll need.

y2 (t) = t−1 v(t), y20 (t) = −t−2 v + t−1 v 0 , y200 (t) = 2t−3 v − 2t−2 v 0 + t−1 v 00

Plugging these into the D.E. gives

2t2 (2t−3 v − 2t−2 v 0 + t−1 v 00 ) + t(−t−2 v + t−1 v 0 ) − 3(t−1 v(t) = 0

Rearranging and simplifying gives

2tv 00 + (−4 + 1)v 0 + (4t−1 − t−1 − 3t−1)v = 0

2tv 00 − 3v 0 = 0
Note that upon simplifying, the only terms remaining are those involving the derivatives of v. The
term involving v drops out. If you’ve done all of your work correctly this should always happen.
Sometimes, as in the repeated roots case, the first derivative term will also drop out. So in order
for y2 (t) = v(t)y1 (t) to be a solution then v must satisfy

2tv 00 − 3v 0 = 0 (2.2.1)

This appears to be a problem. In order to find a solution to a second order non-constant coefficient
differential equation we need to solve a different second order non-constant coefficient differential
equation. However, this isn’t the problem that it appears to be. Because the term involving the v
drops out we can actually solve (??) and we can do it with the knowledge that we already have at
this point. We will solve this by making the following change of variable.

w = v0, w0 = v 00

with this change of variable, (??) becomes

2tw0 − 3w = 0

and this is a linear, first order D.E. that we can solve. This also explains the name of this method.
We’ve managed to reduce a second order differential equation down to a first order differential
equation.
3
w(t) = Ct 2
Recall our change of variable
v0 = w
with this we can easily solve for v(t)
Z Z
3 2 5
v(t) = wdt = Ct 2 = Ct 2 + k
5

13
This is the most general possible v(t) that we can use to get a second solution. So, just as we did
in the repeated roots section, we can choose the constants to be anything we want so choose them to
clear out all the extraneous constants. In this case we can use
5
C= , k=0
2
Using these gives the following for v(t) and for the second solution.
5
v(t) = t 2
5 3
y2 (t) = t−1 (t 2 ) = t 2
The general solution will then be
3
y(t) = C1 t−1 + C2 t 2 .
Exercise 2.2.1. Find the general solution to

t2 y 00 + 2ty 0 − 2y = 0

given that y1 (t) = t is a solution.

2.3 Non-homogeneous Second order linear equations

2.3.1 Method of undetermined coefficients

Consider
y 00 + p(x)y 0 + q(x)y = r(x)

1. First find the general solution of the corresponding homogeneous equation yc .

2. Find the solution of the non-homogeneous equation, call this yp .

3. The general solution of the original non-homogeneous equation is then y = yc + yp .


Example 2.3.1. Solve y 00 + 3y 0 + 2y = 1 + 6x
Solution
We first find the complimentary solution yc which is the general solution to the homogeneous D.E.

y 00 + 3y 0 + 2y = 0

The characteristic equation is

m2 + 3m + 2 = 0 giving us (m + 2)(m + 1) = 0 impliying m1 = −2, m2 = −1

which leads to the solution


yc = c1 e−2x + c2 e−x

14
Now we want to find the particular solution yp . Since r(x) is a polynomial of order 1, choose
yp = A + Bx, yp0 = B, yp00 = 0
Substituting into the original equation we have
0 + 3B + 2(A + Bx) = 1 + 6x
3B + 2A = 1
2B = 6
B=1 (2.3.1)
9 − 1 = −2A
A = −4
yp = −4 + 3x
y = yc + yp = c1 e−2x + c2 e−x − 4 + 3x
Example 2.3.2. Solve y 00 + 6y 0 + 9y = 27x2 , y(0) = 2, y 0 (0) = 1
Solution
For the homogeneous equation, the characteristic equation is
m2 + 6m + 9 = 0, (m + 3)(m + 3) = 0 hence m = −3 twice
yc = c1 e−3x + c2 xe−3x
For the particular solution choose
yp = A + Bx + Cx2
yp0 = B + 2Cx (2.3.2)
yp00 = 2C
Substitute in the original equation we have
2C + 6(B + 2Cx) + 9(A + bx + Cx2 ) = 27x2
2C + 6B + 9A = 0
12C + 9B = 0
(2.3.3)
9C = 27, implying C = 3
B = −4 and A = 2
yp = 2 − 4x + 3x2
y(x) = c1 e−3x + c2 xe−3x + 2 − 4x + 3x2 .
Now make use of initial conditions to find c1 and c2 .
Example 2.3.3. Solve y 00 + 4y = 8e−2t , y(0) = 0, y 0 (0) = 2
Solution
For the complimentary solution, m = ±2i
yc = c1 cos(2t) + c2 sin(2t)
Choose
yp = M e−2t , such that yp0 = −2M e−2t , yp00 = 4M e−2t
Substitute in D.E we have
4M e−2t + 4M e−2t = 8e−2t , hence M = 1
y = c1 cos(2t) + c2 sin(2t) + e−2t
Applying initial conditions
y(t) = 2 sin 2t − cos 2t + e−3t

15
Note that r(x) is a trig function e.g. y 00 − 4y = 13 cos 3x, then choose yp = A cos 3x + B sin 3x
If r(x) takes a combination of polynomials and trig functions, also choose yp as a combination of
those.

2.3.2 Method of variation of parameters

The technique of undetermined coefficients has severe limitations. It can only be used when the
coefficients p(x) and q(x) are constants, and even then, it only works if r(x) takes a particular
simple form. We now develop a more powerful method that always works regardless of the nature
of p, q, and r, provided the general solution of the corresponding homogeneous equation

y 00 + p(x)y 0 + q(x)y = 0 is already known.

We assume that in some way, the general solution of the corresponding homogeneous equation has
been found. Lets say
y(x) = c1 y1 (x) + c2 y2 (x) (2.3.4)
We then replace c1 and c2 by unknown functions v1 (x) and v2 (x) and attempt to determine v1 and
v2 in such a manner that
y = v1 y1 + v2 y2 (2.3.5)
will be a solution to
y 00 + p(x)y 0 (x) + q(x)y(x) = r(x). (2.3.6)
With two unknown functions (v1 and v2 ) to find, we need two equations relating these functions.
One of these is obtained by requiring that (??) be a solution to (??). We will later see what the
second equation should be. We begin by computing the derivative of (??) arranged as follows:

y 0 = (v1 y10 + v2 y20 ) + (v10 y1 + v20 y2 ) (2.3.7)

Another differentiation will introduce second derivatives of unknowns v1 and v2 . We avoid the
second expression of (??) by letting
v10 y1 + v20 y2 = 0 (2.3.8)
This leads to
y 0 = v1 y10 + v2 y20 (2.3.9)
00
y = v1 y100 + v10 y10 + v2 y200 + v20 y20 (2.3.10)
Substituting (??), (??) and (??) into (??) and rearranging we get

v1 (y100 + py10 + qy1 ) + v2 (y200 + py20 + qy2 ) + v10 y10 + v20 y20 = r(x) (2.3.11)

Since y1 and y2 are solutions to the homogeneous equation, we have

v10 y10 + v20 y20 = r(x) (2.3.12)

Taking (??) and (??), we have two equations in 2 unknowns v10 and v20 i.e

v10 y1 + v20 y2 = 0
(2.3.13)
v10 y10 + v20 y20 = r(x)

16
v10 y20 −y2
    
1 0
=
v20 −y10 y1

r(x)
y10 y20

y1 y2
This gives
−y2 r(x) y1 r(x)
v10 = and v20 = (2.3.14)
W (y1 , y2 ) W (y1 , y2 )
The above formulae are legitimate, for the Wronskian is non-zero by the linear independence of y1
and y2 .
Next we integrate (??) to find v1 and v2
−y2 r(x)
Z Z
y1 r(x)
v1 dx and v2 = dx
W W
Putting everything together we have
−y2 r(x)
Z Z
y1 r(x)
y = y1 dx + y2 dx
W W
is the particular solution to (??).
Example 2.3.4. Find the general solution to y 00 + y = tan x
Solution
The complimentary function is
yc = c1 cos x + c2 sin x
Set up yp = v1 cos x + v2 sin x

yp0 = v10 cos x − v1 sin x + v20 sin x + v2 sin x


but v10 cos x + v20 sin x = 0
hence yp0 = −v10 sin x + v2 sin x
yp00 = −v1 sin x − v1 cos x + v20 sin x + v2 cos x
Substituting in y 00 + y = tan x we have
−v1 sin x − v1 cos x + v2 sin x − v2 sin x + v1 cos x + v2 sin x = tan x
−v10 sin x + v2 cos x = tan x
Thus we have   0   
cos x sin x v1 0
=
− sin x cos x v20 tan x

cos x sin x
In this case the Wronskian W = =1
− sin x cos x
2 cos2 x−1
v10 = − sin x1 tan x = sin x
= = cos x − sec x
0
cos x cos x (2.3.15)
v2 = cos x tan x = sin x
Integrating we have
v1 = sin x − ln | sec x + tan x|
(2.3.16)
v2 = − cos x
T husy(x) = c1 cos x + c2 sin x − cos x ln | sec x + tan x|

17
Exercise 2.3.1. Solve

1. y 00 + 5y 0 + 6y = x2 + 2x
ex
2. y 00 − 2y 0 + y = x
, y(1) = 0, y 0 (1) = 0

Tutorial 2. Answer all questions

d2
1. Solve the equation dt2
A(t) = 6t + 8 with A(0) = 4 and A0 (0) = 9.
2
2. Suppose dtd 2 x(t) = −4x(t) + e−t . What is the solution of the equation if the initial displacement
is 1 and the initial velocity is 0?

3. Find the general solution of the equation A00 (t) + A(t) = et .

4. Find the general solution of the equation A00 (t) + A(t) = sint
d2
5. Solve the equation dt2
x(t) + 9x(t) = 5 with initial conditions x(0) = 1 and x0 (0) = 0.
d2
6. Solve the equation dt2
x(t) + 9x(t) = t2 + t with initial conditions x(0) = 1 and x0 (0) = 0.
d
7. Solve the equation dt
x(t) = 4x(t) + t using the method of undetermined coefficients.
2
8. Solve dtd 2 x(t) = −4x(t) + sin2t. Hint: For the undetermined coefficients method try Atcos2t +
Btsin2t.

9. Using the method of variation of parameters, solve the following


ex
(a) y 00 + 5y 0 + 6y = x2 + 2x (b) y 00 − 2y 0 + y = x
, y(1) = 0, y 0 (1) = 1

10. Consider the following equation


2 2
y 00 − y 0 + 2 y = x sin x, x ∈ [0, ∞)
x x
Given that y1 (x) = x and y2 (x) = x2 are linearly independent solutions of the homogeneous
equation on (1, ∞), find the particular solution using the method of variation of parameters.

Tutorial 3. 1. Find the general solutions of the following

(a) y 00 + y = cot t
(b) y 00 + y = csc t
(c) y 00 − 3y 0 + 2y = et /(1 + et )
(d) y 00 + y = sec 2t
(e) y 00 + y = sec t tan t
(f ) y 00 − 2y 0 + y = e2t (et + 1)−2
(g) y 00 − y = e− 2t sin e−t

18
(h) y 00 + y = sec2 t

2. Find the general solution of

t2 y 00 − 6ty 0 + 10 = 0
by setting y = k t . Hence use the method of variation of parameters to find the general solution
of
t2 y 000 − 6ty 0 + 10y = 3t4 + 6t3 .

3. (a)Find one solution to the equation

t2 y 00 t(t + 2)y 0 + (t + 2)y = 0

by inspection.
(b)Find another independent solution by reduction of order
(c) Use the method of variation of parameters

t2 y 00 − t(t + 2)y 0 + (t + 2)y = t3

19
Chapter 3

Series solutions to ODEs

In this chapter we will finally be looking at nonconstant coefficient differential equations. While we
won’t cover all possibilities in this chapter we will be looking at two of the more common methods
for dealing with this kind of differential equation.

The first method that we’ll be taking a look at, series solutions, will actually find a series repre-
sentation for the solution instead of the solution itself. You first saw something like this when you
looked at Taylor series in your Calculus class. As we will see however, these won’t work for every
differential equation.

The second method that we’ll look at will only work for a special class of differential equations.
This special case will cover some of the cases in which series solutions can’t be used.

3.0.3 Review: Power Series

Before looking at series solutions to a differential equation we will first need to do a cursory review
of power series. A power series is a series in the form,

X
f (x) = an (x − x0 )n (3.0.1)
n=0

where, x0 and an are numbers. We can see from this that a power series is a function of x. The
function notation is not always included, but sometimes it is so we put it into the definition above.

Before proceeding with our review we should probably first recall just what series really are. Recall
that series are really just summations. One way to write our power series is then,

f (x) = ∞ n
P
n=0 an (x − x0 ) (3.0.2)
= a0 + a1 (x − x0 ) + a21(x − x0 )2 + a3 (x − x0 )3 + ...

20
Notice as well that if we needed to for some reason we could always write the power series as,

f (x) = ∞ n
P
n=0 an (x − x0 )
2 3
= a0 + a 1 (x − x0 ) + a21(x − x0 ) + a3 (x − x0 ) + ...
= a0 + ∞ n
P
n=1 an (x − x0 )

All that we’re doing here is noticing that if we ignore the first term (corresponding to n = 0 ) the
remainder is just a series that starts at n = 1. When we do this we say that we’ve stripped out the
n = 0 , or first, term. We don’t need to stop at the first term either. If we strip out the first three
terms we’ll get,

X ∞
X
n +
an (x − x0 ) = a0 + a1 (x − x0 ) + a2 (x − x0 ) an (x − x0 )n
n=0 n31

There are times when we’ll want to do this so make sure that you can do it.

Now, since power series are functions of x and we know that not every series will in fact exist,
it then makes sense to ask if a power series will exist for all x. This question is answered by looking
at the convergence of the power series. We say that a power series converges for x = c if the series,

X
an (c − x0 )n
n=0

converges. Recall that this series will converge if the limit of partial sums,
N
X
lim an (c − x0 )n
N →∞
n=0

exists and is finite. In other words, a power series will converge for x=c if

X
an (c − x0 )n
n=0

is a finite number.

Note that a power series will always converge if x = x0 . In this case the power series will become

X
an (x − x0 )n = a0
n=0

With this we now know that power series are guaranteed to exist for at least one value of x. We
have the following fact about the convergence of a power series.
Fact
Given a power series, (1), there will exist a number 0 ≤ ρ ≤ ∞ so that the power series will converge
for |x − x0 | < ρ and diverge for |x − x0 | > ρ . This number is called the radius of convergence.

Determining the radius of convergence for most power series is usually quite simple if we use the
ratio test.

21
3.0.4 Ratio Test

Given a power series compute,


an+1
L = |x − x0 | lim | |
n→∞ an
then,
L < 1 ⇒ the series converges
L > 1 ⇒ the series diverges
L = 1 ⇒ the series may converge or diverge
Let’s take a quick look at how this can be used to determine the radius of convergence.
Example 3.0.5. Determine the radius of convergence for the following power series.

X (−3)n
(x − 5)n
n=0
n7n+1
Solution So, in this case we have,
(−3)n (−3)n+1
an = an+1 =
n7n+1 (n + 1)7n+2
Remember that to compute an+1 all we do is replace all the n’s in an with n + 1. Using the ratio
test then gives,
L = |x − 5| limn→∞ | an+1
an
|
(−3)n+1 n7n+1
= |x − 5| limn→∞ | (n+1)7n+2 (−3)n |
−3 n
= |x − 5| limn→∞ | (n+1)7 1
|
3
= 7 |x − 5|
Now we know that the series will converge if,
3 7
|x − 5| < 1 ⇒ |x − 5| <
7 3
and the series will diverge if,
3 7
|x − 5| > 1 ⇒ |x − 5| >
7 3
In other words, the radius of the convergence for this series is,
7
ρ=
3

As this last example has shown, the radius of convergence is found almost immediately upon
using the ratio test.

So, why are we worried about the convergence of power series? Well in order for a series solution
to a differential equation to exist at a particular x it will need to be convergent at that x. If it’s
not convergent at a given x then the series solution won’t exist at that x. So, the convergence of
power series is fairly important.

Next we need to do a quick review of some of the basics of manipulating series. We’ll start with
addition and subtraction.

22
3.1 addition and subtraction of series

There really isn’t a whole lot to addition and subtraction. All that we need to worry about is that
the two series start at the same place and both have the same exponent of the x − x0 . If they do
then we can perform addition and/or subtraction as follows,

X ∞
X ∞
X
n n
an (x − x0 ) ± bn (x − x0 ) = (an ± bn )(x − x0 )n
n=n0 n=n0 n=n0

In other words all we do is add or subtract the coefficients and we get the new series.
One of the rules that we’re going to have when we get around to finding series solutions to differential
equations is that the only x that we want in a series is the x that sits in (x − x0 )n .
This means that we will need to be able to deal with series of the form,

X
c
(x − x0 ) an (x − x0 )n
n=0

where c is some constant. These are actually quite easy to deal with.

(x − x0 )c ∞ n c 2
P
n=0 an (x − x0 ) = (x − x0 ) (a0 + a1 (x − x0 ) + a2 (x − x0 ) + ...)
c 1+c 2+c
=a 0 (x − x0 ) + a1 (x − x0 ) + a2 (x − x0 ) + ...
= ∞ n+c
P
a
n=0 n (x − x 0 )

So, all we need to do is to multiply the term in front into the series and add exponents. Also note
that in order to do this both the coefficient in front of the series and the term inside the series must
be in the form x − x0 . If they are not the same we can’t do this, we will eventually see how to deal
with terms that aren’t in this form.

3.2 Differentiation of power series

By looking at (3.2) it should be fairly easy to see how we will differentiate a power series. Since
a series is just a giant summation all we need to do is differentiate the individual terms. The
derivative of a power series will be,

f 0 (x)
P∞= a1 + 2a2 (x −n−1 x0 ) + 3a3 (x − x0 )2 + ...
= Pn=1 nan (x − x0 )
= ∞ n=0 nan (x − x0 )
n−1

So, all we need to do is just differentiate the term inside the series and we’re done. Notice as well
that there are in fact two forms of the derivative. Since the n = 0 term of the derivative is zero it
won’t change the value of the series and so we can include it or not as we need to. In our work we
will usually want the derivative to start at n = 1, however there will be the occasion problem were
it would be more convenient to start it at n = 0.

23
Following how we found the first derivative it should make sense that the second derivative is,
P∞
f 00 (x)
P∞= n=2 n(n − 1)an (xn−2 − x0 )n−2
= Pn=1 n(n − 1)an (x − x0 )
= ∞ n=0 n(n − 1)an (x − x0 )
n−2

In this case since the n = 0 and n = 1 terms are both zero we can start at any of three possible
starting points as determined by the problem that we’re working.

3.3 Index shifting

As we will see eventually we are going to want our power series written in terms of (x − x0 ) and
they often won’t, initially at least, be in that form. To get them into the form we need we will need
to perform an index shift.
Index shifts themselves really aren’t concerned with the exponent on the x term, they instead are
concerned with where the series starts as the following example shows.

Example 3.3.1. Write the following as a series that starts at n=0 instead of n=3.

X
n2 an−1 (x + 4)n+2
n=3

Solution
An index shift is a fairly simple manipulation to perform. First we will notice that if we define
i = n − 3 then when n=3 we will have i=0. So what we?ll do is rewrite the series in terms of i
instead of n. We can do this by noting that n = i + 3. So, everywhere we see an n in the actual
series term we will replace it with an i + 3. Doing this gives,
P∞ 2 n+2
P∞ 2 i+3+2
n=3 n a n−1 (x + 4) = i=0 (i + 3) ai+3−1 (x + 4)
P ∞ 2 i+5
= i=0 (i + 3) ai+2 (x + 4)

The upper limit won’t change in this process since infinity minus three is still infinity.
The final step is to realize that the letter we use for the index doesn’t matter and so we can just
switch back to n’s. ∞ ∞
X X
2 n+2
n an−1 (x + 4) = (n − 2)2 an−3 (x + 4)n
n=3 n=5

Now, we usually don’t go through this process to do an index shift. All we do is notice that we
dropped the starting point in the series by 3 and everywhere else we saw an n in the series we
increased it by 3. In other words, all the n’s in the series move in the opposite direction that we
moved the starting point.

Example 3.3.2. Write the following as a series that starts at n = 5 instead of n = 3.



X
n2 an−1 (x + 4)n+2
n=3

24
Solution
To start the series to start at n = 5 all we need to do is notice that this means we will increase the
starting point by 2 and so all the other n’s will need to decrease by 2. Doing this for the series in
the previous example would give,

X ∞
X
2 n+2
n an−1 (x + 4) = (n − 2)2 an−3 (x + 4)n
n=3 n=5

Now, as we noted when we started this discussion about index shift the whole point is to get our
series into terms of (x − x0 )n . We can see in the previous example that we did exactly that with an
index shift. The original exponent on the (x + 4) was n + 2. To get this down to an n we needed to
decrease the exponent by 2. This can be done with an index that increases the starting point by 2.

Let’s take a look at a couple of more examples of this.

Example 3.3.3. Write each of the following as a single series in terms of (x − x0 )n .

1. (x + 2)2 ∞ n−4
− ∞ n+1
P P
n=3 nan (x + 2) n=1 nan (x + 2)

2. x ∞ 2 n+3
P
n=0 (n − 5) bn+1 (x − 3)

There is one final fact that we need take care of before moving on. Before giving this fact for power
series let’s notice that the only way for

a + bx + cx2 = 0

to be zero for all x is to have a = b = c = 0.


We’ve got a similar fact for power series.
FACT
If ∞
X
an (x − x0 )n = 0
n=0

for all x, then


an = 0, n = 0, 1, 2, 3, ...
This fact will be key to our work with differential equations so don’t forget it.

3.4 Review: Taylor Series

We are not going to be doing a whole lot with Taylor series once we get out of the review, but
they are a nice way to get us back into the swing of dealing with power series. Remembering how

25
Taylor series work will be a very convenient way to get comfortable with power series before we
start looking at differential equations.

Taylor Series
If f (x) is an infinitely differential function then the Taylor Series of f (x) about x = x0 is,

X f (n) (x0 )
f (x) = (x − x0 )n
n=0
n!

Recall that
f (0) (x) = f (x) f (n) (x) = nth derivative of f (x)
Example 3.4.1. Determine the Taylor series for f (x) = ex about x = 0.
Solution
This is probably one of the easiest functions to find the Taylor series for. We just need to recall
that,
f (n) (x) = ex , n = 0, 1, 2...
and so we get,
f (n) (0) = 1, n = 0, 1, 2...
The Taylor series for this example is then,

x
X xn
e =
n=0
n!

Of course, it’s often easier to find the Taylor series about x=0 but we don’t always do that.
Example 3.4.2. Determine the Taylor series of f (x) = ex about x = −4
Solution
This problem is virtually identical to the previous problem. In this case we just need to notice that,
f (n) (−4) = e−4 , n = 0, 1, 2...
The Taylor series for this example is then,

x
X e−4
e = (x + 4)n
n=0
n!

Let’s now do a Taylor series that requires a little more work.


Example 3.4.3. Determine the Taylor series for f (x) = cos(x) about x = 0.
Solution
This time there is no formula that will give us the derivative for each n so let’s start taking derivatives
and plugging in x = 0.
f (0) (x) = cos(x) f (0) (0) = 1
f (1) (x) = − sin(x) f (1) (0) = 0
f (2) (x) = − cos(x) f (2) (0) = −1
f (3) (x) = sin(x) (3)
f (0) = 0
f (4) (x) = cos(x) f (4) (0) = 1

26
Once we reach this point it’s fairly clear that there is a pattern emerging here. Just what this pattern
is has yet to be determined, but it does seem fairly clear that a pattern does exist.
Let’s plug what we’ve got into the formula for the Taylor series and see what we get.

f (n) (0) n
cos(x) = ∞
P
n=0 n!
x
f (0) (0) f (1) (0) f (2) (0) 2 (3)
= 0! + 1! x + 2! x + f 3!(0) x3 + ...
2 4 6 8
= 0!1 + 0 − x2! + 0 + x4! + 0 − x6! + 0 + x8! + ...
So, every other term is zero.
We would like to write this in terms of a series, however finding a formula that is zero every other
term and gives the correct answer for those that aren’t zero would be unnecessarily complicated.
So, let’s rewrite what we’ve got above and while were at it renumber the terms as follows,
1 x2 x 4 x6 x8
cos(x) = − + − + + ...
0! 2! 4! 6! 8!
corresponding to n = 0, 1, 2, 3, 4, .... With this ”renumbering” we can fairly easily get a formula for
the Taylor series of the cosine function about x = 0.

X (−1)n x2n
cos(x) =
n=0
(2n)!

For practice you might want to see if you can verify what the Taylor series for the sine function
about x = 0 is.
Example 3.4.4. Determine the Taylor series for f (x) = 3x2 − 8x + 2 about x = 2.
Solution

f (x) = 3x2 − 8x + 2 f (2) = −2


f 0 (x) = 6x − 8 0
f (2) = 4
f 00 (x) = 6 f 00 (2) = 0, n ≥ 3
So, in this case the derivatives will all be zero after a certain order. That happens occasionally and
will make our work easier. Setting up the Taylor series then gives,
f (n) (2)
3x2 − 8x + 2 = ∞ (x − 2)n
P
n=0 n!
(0) (1) (2) (3)
= f 0!(2) + f 1!(2) (x − 2) + f n!(2) (x − 2)2 + f 3!(2) (x − 2)3 + ...
= −2 + 4(x − 2) + 26 (x − 2)2 + 0
= 2 + 4(x − 2) + 3(x − 2)2

In this case the Taylor series terminates and only had three terms. Note that since we are after the
Taylor series we do not multiply the 4 through on the second term or square out the third term. All
the terms with the exception of the constant should contain an x − 2.

Note in this last example that if we were to multiply the Taylor series we would get our original
polynomial. This should not be too surprising as both are polynomials and they should be equal.
We now need a quick definition that will make more sense to give here rather than in the next
section were we actually need it since it deals with Taylor series.

27
Definition 3.4.1. A function, f (x), is called analytic at x = a if the Taylor series for f (x) about
x = a has a positive radius of convergence and converges to f (x).

We need to give one final note before proceeding into the next section. We started this section
out by saying that we weren’t going to be doing much with Taylor series after this section. While
that is correct it is only correct because we are going to be keeping the problems fairly simple. For
more complicated problems we would also be using quite a few Taylor series.

Before we get into finding series solutions to differential equations we need to determine when we
can find series solutions to differential equations. So, let’s start with the differential equation,

p(x)y 00 + q(x)y 0 + r(x)y = 0 (3.4.1)

This time we really do mean non constant coefficients. To this point we’ve only dealt with constant
coefficients. However, with series solutions we can now have non constant coefficient differential
equations. Also, in order to make the problems a little nicer we will be dealing only with polynomial
coefficients.
Now, we say that x = x0 is an ordinary point if provided both
q(x) r(x)
and
p(x) p(x)
are analytic at x = x0 . That is to say that these two quantities have Taylor series around x = x0 .
We are going to be only dealing with coefficients that are polynomials so this will be equivalent to
saying that
p(x0 ) 6= 0
for most of the problems.
If a point is not an ordinary point we call it a singular point.

3.5 Solving problems

The basic idea to finding a series solution to a differential equation is to assume that we can write
the solution as a power series in the form,

X
y(x) = an (x − x0 )n (3.5.1)
n=0

and then try to determine what the an’s need to be. We will only be able to do this if the point
x = x0 , is an ordinary point. We will usually say that (??) is a series solution around x = x0 .
Let’s start with a very basic example of this. In fact it will be so basic that we will have constant
coefficients. This will allow us to check that we get the correct solution.
Example 3.5.1. Determine a series solution for the following differential equation about x0 = 0.
Solution

28
Notice that in this case p(x) = 1 and so every point is an ordinary point. We will be looking for a
solution in the form,
X∞
y(x) = an x n
n=0

We will need to plug this into our differential equation so we’ll need to find a couple of derivatives.

X ∞
X
0 n−1 00
y (x) = nan x y (x) = n(n − 1)an xn−2
n=1 n=2

Recall from the power series review section on power series that we can start these at n = 0 if we
need to, however it’s almost always best to start them where we have here. If it turns out that it
would have been easier to start them at n = 0 we can easily fix that up when the time comes around.
So, plug these into our differential equation. Doing this gives,

X ∞
X
n−2
n(n − 1)an x + an x n = 0
n=2 n=0

The next step is to combine everything into a single series. To do this requires that we get both
series starting at the same point and that the exponent on the x be the same in both series.
We will always start this by getting the exponent on the x to be the same. It is usually best to get
the exponent to be an n. The second series already has the proper exponent and the first series will
need to be shifted down by 2 in order to get the exponent up to an n. If you don’t recall how to do
this take a quick look at the first review section where we did several of these types of problems.
Shifting the first power series gives us,

X ∞
X
(n + 2)(n + 1)an+2 xn + an x n = 0
n=0 n=0

Notice that in the process of the shift we also got both series starting at the same place. This won’t
always happen, but when it does we’ll take it. We can now add up the two series. This gives,

X
[ (n + 2)(n + 1)an+2 + an ]xn = 0
n=0

Now recalling the fact from the power series review section we know that if we have a power series
that is zero for all x (as this is) then all the coefficients must have been zero to start with. This
gives us the following,

(n + 2)(n + 1)an+2 + an = 0, n = 0, 1, 2, ...

This is called the recurrence relation and notice that we included the values of n for which it must
be true. We will always want to include the values of n for which the recurrence relation is true
since they won’t always start at n = 0 as it did in this case.
Now let’s recall what we were after in the first place. We wanted to find a series solution to the
differential equation. In order to do this we needed to determine the values of the an’s. We are
almost to the point where we can do that. The recurrence relation has two different an’s in it so we
can’t just solve this for an and get a formula that will work for all n. We can however, use this to
determine what all but two of the an’s are.

29
To do this we first solve the recurrence relation for the an that has the largest subscript. Doing this
gives,
an
an+2 = − n = 0, 1, 2, ...
(n + 2)(n + 1)
Now, at this point we just need to start plugging in some value of n and see what happens,
−a0 −a1
n=0 a2 = (2)(1)
n = 1 a3 = (3)(2)
a0 a1
n=2 a4 = (4)(3)(2)(1)
n = 3 a5 = (5)(4)(3)(2)
−a0 −a1
n=4 a6 = (6)(5)(4)(3)(2)(1)
n = 5 a7 = (7)(6)(5)(4)(3)(2)
. .
. .
. .
(−1)k a0 ka
a2k = (2k)!
, k = 1, 2, ... a2k+1 = (−1) 1
(2k+1)!
, k = 1, 2, ...

Notice that at each step we always plugged back in the previous answer so that when the subscript
was even we could always write the an in terms of a0 and when the coefficient was odd we could
always write the an in terms of a1 . Also notice that, in this case, we were able to find a general
formula for an’s with even coefficients and an’s with odd coefficients. This won’t always be possible
to do.
There’s one more thing to notice here. The formulas that we developed were only for k = 1, 2, ?
however, in this case again, the will also work for k=0. Again, this is something that won’t always
work, but does here.
Do not get excited about the fact that we don’t know what a0 and a1 are. As you will see, we actually
need these to be in the problem to get the correct solution.
Now that we’ve got formulas for the an’s let’s get a solution. The first thing that we’ll do is write
out the solution with a couple of the an’s plugged in.

y(x) = ∞ n
P
n=0 an x
= a0 + a1 x + a2 x2 + a3 x3 + ... + a2k x2k + a2k+1 x2k+1 + ... (3.5.2)
a0 2 a1 3 (−1)k a0 2k (−1)k+1 a1 2k+1
= a0 + a1 x − 2! x − 3! x + ... + (2k)! x + (2k+1)! x + ...

The next step is to collect all the terms with the same coefficient in them and then factor out that
coefficient.
2 k 3 k+1
y(x) = a0 {1 − x2! ... + (−1) a0 2k
(2k)!
x } + a1 {x = x3! + ... + (−1) a1 2k+1
(2k+1)!
x + ...}
P∞ (−1)k a0 2k 3 (−1)k+1 a (3.5.3)
= a0 n=0 (2k)! x } + a1 {x = x3! + a1 (2k+1)! 1 x2k+1

Before working another problem let’s take a look at the solution to the previous example. First,
we started out by saying that we wanted a series solution of the form,

X
y(x) = an x n
n=0

and we didn’t get that. We got a solution that contained two different power series. Also, each
of the solutions had an unknown constant in them. This is not a problem. In fact, it’s what we

30
want to have happen. From our work with second order constant coefficient differential equations
we know that the solution to the differential equation in the last example is,

y(x) = c1 cos(x) + c2 sin(x)

Solutions to second order differential equations consist of two separate functions each with an
unknown constant in front of them that are found by applying any initial conditions. So, the form
of our solution in the last example is exactly what we want to get. Also recall that the following
Taylor series,
∞ ∞
X (−1)n x2n X (−1)n x2n+1
cos(x) = sin(x) =
n=0
(2n)! n=0
(2n + 1)!
Recalling these we very quickly see that what we got from the series solution method was exactly
the solution we got from first principles, with the exception that the functions were the Taylor series
for the actual functions instead of the actual functions themselves.
Now let’s work an example with nonconstant coefficients since that is where series solutions are
most useful.

Example 3.5.2. 1. Find a series solution around x0 = 0 for the following differential equation.

y 00 − xy = 0

2. Find the first four terms in each portion of the series solution around x0 = −2 for the following
differential equation.
y 00 − xy = 0

3. Find the first four terms in each portion of the series solution around x0 = 0 for the following
differential equation.
(x2 + 1)y 00 − 4xy 0 + 6x = 0

31
Chapter 4

Laplace Transforms

Definition 4.0.1. Given a function f (t), t ≥ 0, its Laplace transform F (s) is defined as
Z ∞
L {f (t)} = e−st f (t) dt (4.0.1)
0

Example 4.0.3.
f (t) = 1
Z ∞
1 −st ∞ 1 1
L (f (t)) = = − e = − [0 − 1] =
0 s 0 s s
Example 4.0.4.
f (t) = et
Z ∞ Z ∞
1 −(s−1) ∞ 1
F (0) = L (f (t)) = e −st
dt = e−(s−1) dt = − e = (s > 1)
0 0 s−1 0 s−1
Example 4.0.5.
f (t) = eat
Z ∞ Z ∞
1 −(s−a)t ∞ 1
L (e ) =
at −st at
e e dt = e−(s−a)t
dt = − e = (s > a)
0 0 s−a 0 1−s
Example 4.0.6. Z ∞ Z ∞
1 −st ∞ 1
L (t) = −st
e tdt = t( e ) − (− )e−st dt
0 s 0 0 s
 ∞
1 1
=0+ − e−st
s s 0
1
s2
Example 4.0.7.
f (t) = sin(at)
Z ∞
L (sin at) = e−st sin atdt
0

32
Intergrate by parts
1 −st ∞ s Z ∞
= − e cos at − e−st cos atdt

a 0 a 0
Z ∞
1 s −st ∞ s2

= − 2 e sin at − 2 e−st sin atdt
a a 0 a 0
1 s2
= − L (sin at)
a a2
s2 1
(1 + 2 )L (sin at) =
a a
a
L (sin at) = 2
s + a2

1. As on exercise , find L (cos at)

4.1 Laplace transforms of the first and second deriva-


tive of functions
Z ∞
L f (t) = e−st f (t)dt
0
1 −st ∞ 1 −st 0
= f (t)(− e − e f (t)dt
s 0 s
f (0) 1
L f (t) = + L f 0 (t)
s s
L f (t) = sL f (t) − f (0)
0

Now show that


L f 00 (t) = s2 L (f ) − sf (0) − f 0 90)

4.2 Properties of Laplace Transform


1. Linearly
L c1 f (t) + c2 g(t) = c1 L f (t) + c2 L g(t)
Proof Z ∞
L c1 (f ) + c2 g(t) = e−st [c1 f (t) + c2 g(t)]dt
0
Z ∞ Z ∞
−st
= c1 e f (t)dt + c2 e−st f ()dt
0 0

= c1 L f (t) + c2 L g(t)

33
2. L ea tf (t) = F (s − a)
Proof Z ∞
L e f (t) =
at
e−st eat f (t)dt
0
Z ∞
e−(s−a)t f (t)dt
0

L f (t)(s − a)

3. L tf (t) = −F 0 (s) Z ∞
F (s) = e−st f (t)dt
0
Z ∞
d d
[f (s)] = [ e−st f (t)dt]
ds ds 0
Z ∞
d −st
[e ]f (t)dt
0 ds
Z ∞
e−st (−t)f (t)dt
0

(−1)L tf (t)

n
As an exercise, show that L tn f (t) = (−1)n dsnd[f (s)

Exercise 4.2.1. Using the properties of Laplace Transforms


find

1. L (5e−2t − 3 sin 4t)

2. L (e2t t)

3. L (e−3t sin t)

4. L (t2 sin bt)

4.3 Transforms of Some Basic Functions


1
• L {1} = .
s
n!
• L {tn } = , n = 1, 2, 3, . . .
sn+1
1
• L {eat } = .
s−a

34
k
• L {sin kt} = .
s2
+ k2
s
• L {cos kt} = 2 .
s + k2

4.4 Inverse Transform

In the proceeding section, we were concerned with the problem of transforming a function f (t) into
another function F (s). We now turn to the problem around, namely, given F (s), find the function
f (t) corresponding to this transform. We say f (t) is the inverse Laplace transform of F (s) and
write
f (t) = L −1 {F (s)}.

4.4.1 Some Inverse Transforms


 
1
• 1=L −1
.
s
 
n!
• t =L
n −1
, n = 1, 2, 3, . . .
sn+1
 
1
• e =L
at −1
.
s−a
 
k
• sin kt = L −1
.
s2 + k 2

4.4.2 L −1 is a Linear Transform

We assume that the inverse Laplace transform is itself a linear transform, that is, for constants α
and β,
L −1 {αF (s) + βG(s)} = αL −1 {F (s)} + βL −1 {G(s)}
where F and G are the transforms of some functions f and g.
 
1
Example 4.4.1. Evaluate L −1
.
s5

Solution: It follows    
1 1 4! 1 4
L −1
= L −1 = t.
s5 4! s5 24

35
 
3s + 5
Example 4.4.2. Evaluate L −1
.
s2 + 7

Solution: The given function of s can be written as two expressions by means of term-wise division
3s + 5 3s 5
2
= 2 + 2 .
s +7 s +7 s +7
From the linearity property of the inverse Laplace transform, we then have
    ( √ )
3s + 5 s 5 7
L −1 2
= 3L −1 2
+ √ L −1 2
s +7 s +7 7 s +7
√ 5 √
= 3 cos 7t + √ sin 7t.
7

4.4.3 Partial Fractions

Partial fractions play an important role in finding inverse Laplace transforms.


 
s+1
Example 4.4.3. Evaluate L −1
.
s2 (s + 2)3

Solution: Assume
s+1 A B C D E
= + + + +
s2 (s + 2)3 s s2 s + 2 (s + 2)2 s + 2)3
1 1 1 1
so that A = − , B = , C = , D = 0 and E = − . Hence
16 8 16 4
   
s+1 1/16 1/8 1/16 1/4
L −1
= L −1
− + 2 + −
s2 (s + 2)3 s s s + 2 (s + 2)3
     
1 −1 1 1 −1 1 1 −1 1 1 −1 2
= − L + L + L { }− L
16 s 8 s2 16 s+2 8 (s + 2)3
1 1 1 1
= − + t + e−2t − t2 e−2t .
16 8 16 8
 
3s − 2
Example 4.4.4. Class Exercise: Evaluate L −1
.
s3 (s2 + 4)

4.5 Solving Equations

Consider the initial value problem consisting of the second order linear differential equation

36
d2 y
1. dt2
+ 2 dy
dt
= 1, y(0) = 0, y 0 (0) = 10
solution
Taking Laplace transforms
L {y 00 } + 2L {y 0 } = L {1}
1
s2 L {y} − sy(0) − y 0 (0) + 2 [sL {y} − y(0)] =
5
1
s2 L {y} − 10 + 2sL {y} =
5
1
(s2 + 2s)L {y} = 10 +
5
10 1
L {y} = +
s2 + 2s s2 (s + 2)
   
10 1
y(t) = L −1 +L
s(5 + 2 s2 (s + 2)
1 1 t 1
y(t) = 10( − −2t + + (1 − e−2t )
2 2e 2 4
19 t
y(t) = (1 − e−2t +
4 2

2. y 00 − y 0 − 2y = e2t y(0) = 0 y 0 (0) = 1

L {y 00 } − L {y 0 } − L {2y} = L e2t


1
−1 + s2 L {y} − sL {y} − 2L {y} =
5−2
1 s−1
(s2 − 5 − 2)L {y} = +1=
s−2 s−2
s−1 s−2
L {y} = 2
=
(s − 2)(s − s − 2) (s − 2)2 (s + 1)
s−1 A B C
3. Using Partial fractions (s−2)2 (s+1)
= s+1
+ s−2
+ (s−2)2

2 1 2
A=− , C= , B=
9 3 9
     
2 1 2 1 1 1
L {y} = − + +
9 s+1 9 s−2 3 (s − 2)2
2 2 1
y(t) = − e−t + e2t + te2t
9 9 3

37
4. y 00 + y = cos 2t y(0) y 0 (0) = 1

L {y 00 } + {y} = L {cos 2t}


s
s2 L {y} − 2s − 1 + L {y} = L {cos 2t} =
s2 + 4
s 2s3 + s2 + 9s + 4
(s2 + 1)L {y} = 2 + 2s + 1 =
s +4 s2 + 4
2s3 + s62 + 9s + 4 As + B Cs + D
L {y} = = + 2
(s2 + 4)(s2 + 1) s2 + 1 s +4
Comparing numerators , we get

2s3 + s2 + 9s + 4 = (As + B)(s2 + 4) + (CsD)(s2 + 1)


7 1
A= B=1 C=− D=0
3 3
   
7 s 1 1 s
L {y} = + −
3 s2 + 1 s2 + 1 3 s2 + 4
7 1
y(t) = cos t + sin t − cos 2t
3 3
5. Solving Equations
Solve y 00 + y = sin 2t y(0) = 2 y 0 (0) = 1
Solution
L {y 00 + y} = L {sin 2t}
L {y 00 } + L {y} = L {sin 2t}
2
s2 L {y} − sy(0) − y 0 (0) + sL {y} − y(0) =
s2 + 4
2
(s2 + s)L {y} − 2s − 1 − 1 =
s2 +4
2
(s2 + s)L {y} = + 2s + 2
+4 s2
2 2s 2
L {y} = 2
+ +
s(s + 1)(s + 4) s(s + 1) s(s + 1)
2 2 2
+ +
s(s + 1)(s2 + 4) s + 1 s(s + 1)

38

You might also like