Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                

307 Ode Notes 2020 2021

Download as pdf or txt
Download as pdf or txt
You are on page 1of 148

Notes on Differential Equations

Tom Duchamp
February 11, 2021
Version: February 11, 2021

Department of Mathematics
University of Washington

duchamp@uw.edu
Preface

Here’s an outline of the course:

Part 1 For the first three and a half weeks, we’ll study first order differential equations.
We’ll begin with more general first order differential equations and end by concen-
trating on first order linear differential equations.
Part 2 For the next three and a half weeks, we’ll study second order linear differential
equations, beginning with homogeneous differential equations of the form
ay 00 + by 0 + cy = 0
and some applications, including the harmonic oscillator and concluding with non-
homogeneous differential equations of the form
ay 00 + by 0 + cy = f (t) .
The special case where f (t) = cos(ωt) is particularly important.
Part 3 During the final three weeks, we’ll study how to solve differential equations using
Laplace transforms.

By the end of the course, you should know how to do the following:

• Model simple systems involving first order differential equations.


• Visualize solutions using direction fields.
• Use Euler’s method to find approximate solutions to first order differential equations.
• Solve first order linear differential equations and initial value problems via integrating factors.
• Solve constant coefficient second order linear initial value problems using the method of unde-
termined coefficients.
• Calculate with complex numbers and the complex exponential function, compute derivatives
and integrals of the complex exponential function.
• Express the function y(t) = (a cos(ωt) + b sin(ωt))ect in the forms
 
y(t) = Aect cos(ωt + ϕ) and y(t) = Re Ce(c+iω)t

• Model simple mechanical and electrical systems with linear second order differential equations.
• Compute steady-state solution, its amplitude gain and its phase shift with sinusoidal forcing
function.
• Compute resonant frequency.
• Compute Laplace transforms and inverse Laplace transforms of commonly occurring functions.
• Solve constant coefficient linear initial value problems using the Laplace transform together
with tables of Laplace transforms.
• Use Laplace transforms to solve initial value problems when the forcing function is piecewise
continuous or involves the Dirac delta function.
iii
iv PREFACE

• Express the solution of constant coefficient second order differential equations in terms of the
convolution integral.

These notes differ from the book by Boyce and DiPrima in a number of ways.

• The notes give more emphasis on applications and less on theory than Boyce and DiPrima.
• Complex numbers are used more extensively than in Boyce and DiPrima. There are two reasons
for this increased emphasis:
(1) Using complex-valued functions often simplifies computations.
(2) They are routinely used in applications involving periodic behavior such as electrical
circuits, control theory, signal processing (including image processing), crystallography, etc.

Please let me know of any mistakes, including typographical errors, and of any places where the text is
confusing. Suggestions should be sent to me via email at duchamp@uw.edu.

Acknowledgments. Much of the material in these notes is based on material from my colleagues.
Several problems on first order differential equation were written by Neal Koblitz. The material on
complex numbers is based on notes written by Bob Phelps. The chapter on Laplace transforms is based
on notes written by John Palmieri. I also made heavy use of John Sylvester’s lecture notes for Math 307.
PREFACE v

Review Exercises. The prerequisites for Math 307 include high school algebra and trigonometry as
well as Calculus at the level of Math 125. Here are a few problems that you should do to check that
you are ready to take Math 307. If you have difficulty with some of these, it would be a good idea to
review the relevant material. But if you have difficult solving many of them, then you are probably not
yet ready to take Math 307.

Algebra Review Problems.


(1) Write down all values of r that are solutions of the quadratic equation mr2 + k = 0, where m
and k are both positive real numbers.
(2) Write down all values of r that are solutions to the quadratic equation mr2 + cr + k = 0, where
m, c and k are real numbers and m 6= 0.
1
AB
(3) Simplify the expression 1 1 , where A and B are non-zero real numbers.
A + B
1/3 −1/5
x x
(4) Simplify the expression , where x is a positive real number and a is any real number.
x−a
1
+a
(5) Solve the equation K
1 = e−rt for K in terms of the other quantities. Simplify as much as
K +b
possible.
(6) Solve the equation ln(x) − ln(y) = −2 ln(y) + ax + b for y, where x, a and b are positive real
numbers. Simplify as much as possible.
(7) Express some basic properties of the natural logarithm and its inverse, the exponential function,
by completing the following:
(a) ln xy =? (b) ex ey =? (c) eln x =? (d) ln ex =? (e) ln 1 =?
(8) Find counterexamples to each of the following “identities”; that is, find specific numbers x =
a, y = b such that equality FAILS for a and b. (For instance, to show that (x + y)2 6= x2 + y 2 ,
it would suffice to take x = 1, y = 1, since (1 + 1)2 = 4 6= 2 = 12 + 12 .)
(a) ln(x + y) = ln x + ln y, where x > 0, y > 0.
1 1 1
(b) + y = + (x, y 6= 0).
x
√ x√ y √
(c) x + y = x + y (x ≥ 0, y ≥ 0).
(d) ex+y = ex + ey .
Trigonometry Review Problems.

(9) Use the formula for the cosine of the sum of two angles to express f (t) = 3 sin(7 t) − cos(7 t)
in the form f (t) = a cos(bt + c), where a, b, and c are real numbers.
(10) The graph below is the graph of a function of the form y = A cos(ωt + φ) + b. Find the specific
values of A, ω, φ and b.

0
-4 -2 0 2 4 6 8 10
vi PREFACE

(11) Sketch
( the curves in the plane given by each of the following two parametric equations:
x = 4 cos(3 t)
(a) , 0 ≤ t ≤ π/2;
y = 3 sin(3 t)
(
x = e−0.5t cos(2π t + π)
(b) , 0 ≤ t ≤ 4.
y = e−0.5t sin(2π t + π)
Calculus Review Problems.
You’ll need to understand the chain rule for differentiation and several basic methods of
integration, like substitution, integration by parts, trigonometric substitutions, integration by
parts, and rational functions with quadratic denominator. Remember the necessity of adding
a constant of integration for indefinite integrals.
(12) Evaluate each of the following:

Z 1 Z ∞ Z Z
2 dx dx dx
(a) dx/(4 − x ); (b) 2
, b > 0; (c) , a 6= b; (d) 2
;
Z0 Z1 (x + bx) Z ∞(x − a)(x − b) Z 1+x
1 x−a
(e) 2
dx; (f) x cos x dx; (g) cos(t)e−at dt, a > 0; (h) dx;
Z ∞1 − x Z Z0 Z x−b
dx dx dx
(i) te−at dt, a > 0; (j) √ , r > 0; (k) √ , r > 0; (l) .
0 x 2 − r2 r 2 − x2 x2 + 6x + 25
Contents

Preface iii

Chapter 1. Introduction 1
1.1. Some Examples of Modeling: Falling Bodies, the Harmonic Oscillator, Epidemics, and
Electrical Circuits 2
1.2. What’s a differential equation and what does it mean to “solve” it? 9
1.3. What is an Initial Value Problem? 10

Part 1. First Order Differential Equations 13

Chapter 2. The Geometry of First Order Differential Equations 15


2.1. The Direction Field of a Differential Equation 15
2.2. Stability Analysis of Autonomous First Order Differential Equations 17
2.3. Euler’s Method 18

Chapter 3. Solving First Order Differential Equations 21


3.1. Separable Differential Equations 22
3.2. Linear First Order Differential Equations 24

Chapter 4. Modeling with First Order Differential Equations 31


4.1. Linear Models 31
4.2. The Logistic Equation 39
4.3. The Harmonic Oscillator and Conservation of Energy 43

Part 2. Second Order Differential Equations 47

Chapter 5. Complex Numbers 49


5.1. Complex Numbers 49
5.2. The Complex Plane 50
5.3. Polar Representation of Complex Numbers 52
5.4. Complex-valued Functions 53
5.5. The complex exponential function 54

Chapter 6. Introduction to Second Order Differential Equations 59


6.1. Special Cases 59
6.2. Linear Second Order Differential Equations 61

Chapter 7. Solving Homogeneous Linear Differential Equations 63


7.1. The Characteristic Polynomial 64
7.2. Distinct Real Roots of the Characteristic Polynomial 65
7.3. Repeated Roots of the Characteristic Polynomial 66
7.4. Complex Roots of the Characteristic Polynomial 67

Chapter 8. The Harmonic Oscillator 71


8.1. LC-circuits 74
8.2. The Damped Harmonic Oscillator 76
vii
viii CONTENTS

Chapter 9. Solving Nonhomogeneous Differential Equations 81


9.1. Undetermined Coefficients 83
9.2. Undetermined Coefficients Using Complex-valued Functions 87
Chapter 10. The Driven Harmonic Oscillator 89
10.1. Resonance 89
10.2. Forced Oscillations with Damping 91

Part 3. Laplace Transforms 99


Chapter 11. Laplace Transforms 101
11.1. Computing Laplace transforms 101
11.2. Properties of the Laplace transform 103
11.3. Computing the Inverse Laplace Transform 106
11.4. Initial Value Problems with Continuous Forcing Function 108
11.5. The Laplace Transform of Piecewise Continuous Functions 110
11.6. Initial Value Problems with Piecewise Continuous Forcing Functions 112
11.7. The Dirac Delta Function/Impulse Response 116
11.8. Modeling Examples 119
11.9. Convolutions 120

Part 4. Appendices 127


Appendices 128
A. Basic Formulas from Algebra, Trigonometry, and Calculus 128
B. Review of Partial Fractions 131
C. Table of Laplace Transforms 133
D. Answers to selected problems 134
Appendix. Index 139
CHAPTER 1

Introduction

Perhaps the most famous differential equation, dating back to 1686, is Newton’s second law of motion:
“Force equals mass times acceleration.” In the special case of an object of mass m moving along a
straight line, it can be written in the form
my 00 = F (t, y, y 0 ) , (1.1)
0
where y = y(t) is the position of the object at time t and where F (t, y, y ) is the force exerted on the
object at time t, which may also depend on the position y and velocity y 0 of the object. Equation (1.1)
gives a relation between the function y(t) and its first and second derivatives, but it does not give an
explicit formula for y(t). “Solving” this differential equation means finding the formula for y(t). Because
(1.1) expresses the second derivative y 00 in terms of t, y, and y 0 , it is called a second order differential
equation.

A good part of this course (more than half!) will be devoted to the study of the solutions of (1.1) in the
special case where the force is of the special form
F (t, y, y 0 ) = f (t) − ky − γy 0 ,
and Newton’s second law assumes the special form
my 00 + γy 0 + ky = f (t) . (1.2)
As we shall see, this differential equation applies to all sorts of mechanical problems such as free-fall
with drag taken into account, the simple pendulum, and struts on cars and airplanes. We will also see
that the same differential equation models certain electrical circuits (called RLC-circuits), where it is
usually written in the form
1
LV 00 + RV 0 + V = VS (t) , (1.3)
C
where V = V (t) is a voltage, L, R, and C are parameters associated with electronic components, and
VS (t) is an applied voltage (say from a battery or from radio waves).

Newton’s Law of Cooling, which Isaac Newton published in 1701, is another important differential equa-
tion:
T 0 = −k (T − TA (t)) .
Here, T = T (t) denotes the temperature of an object at time t, TA (t) denotes the “ambient temperature”
(the temperature of the environment of the object), and k > 0 is a constant that measures how well the
object is insulated from its environment. A nicer way to write the law of cooling is
T 0 + kT = kTA (t) . (1.4)
If you took Math 125 here at the UW, you’ve already studied this differential equation, and you may have
noticed that (apart from changes in symbols) the same differential equation appears in other modeling
problems, such as those involving radioactive decay, exponential population growth, repayment of loans,
and some “mixing problems.”
1
2 INTRODUCTION

Equations (1.2),(1.3), and (1.4) are all examples of linear differential equations, the most common class
of differential equations. Linear differential equations are differential equations of the form
ay 0 + by = f (t) or ay 00 + by + cy = f (t) ,
where a, b, and c are constants. From a purely mathematical point of view, we are going to spend most
of the time in this course studying these two differential equations from various points of view.

1.1. Some Examples of Modeling: Falling Bodies, the Harmonic Oscillator, Epidemics,
and Electrical Circuits

We mentioned two situations where a physical system can be modeled by a differential equation (Newton’s
Law of Cooling and Newton’s second law of motion). Let’s explore Newton’s second law in more detail
with two examples: an object thrown up in the air and an object attached to a spring.
Example 1.1. Suppose we want to construct a mathematical model for the motion of an object when
it is thrown up in the air. The first step it to decide exactly what we want to study. Let’s assume that
we only want to know how high the object gets when thrown.

We have to make some assumptions. Assume that the object has a mass m of 15 kilograms (so m = 15
kg). Let’s let y denote the height of the object above ground level, measured in meters. Let’s let t
denote the time, measured in seconds after the object is thrown. So y depends on t, which we indicate
by writing y = y(t). We could compute everything about the motion of the object if we knew the formula
for y(t). So our goal is to determine y(t).

If we believe Newton, then we believe that y(t) “satisfies” the differential equation
15y 00 = Force at time t .
To say that y(t) “satisfies” the differential equation means that if we knew the formula for y(t) and used
it to compute 15y 00 (t) then we would have computed the force on the object at time t.

But we don’t know y(t), so we have to work backwards: we need a formula for the forces on the object
and then we need to somehow determine the formula for y(t) from that. In reality, all sorts of forces
might act on the object: the wind might be blowing, rain might be falling on the object, if the object
is made of metal and there is a large magnet nearby it would pull on the object. So we have to make
simplifying assumptions!

Let’s assume that gravity is the only force acting on the object and that it is constant. The gravitational
2
field of the Earth then exerts a force Fgrav = −mg on the object, where g ≈ 9.8m/sec denotes the
2
acceleration due to gravity. (In the British system, g ≈ 32ft/sec ). The negative sign is necessary
because the gravitational force points down.

Ignoring all other forces exerted on the object, Newton’s second law of motion (“F = ma”) shows that
y = y(t) satisfies the differential equation
d2 y d2 y
15 2
= −15 × 9.8 or 2 = −9.8 .
dt dt
We now have a simple mathematical model for the motion that we can use to determine the height
reached by the object. We can do this in two steps: Let v(t) = y 0 (t) (the velocity in meters per second).
Then
v 0 (t) = y 00 (t) = −9.8 (meters per second)
1.1. SOME EXAMPLES OF MODELING: FALLING BODIES, THE HARMONIC OSCILLATOR, EPIDEMICS, AND ELECTRICAL CIRCUITS
3

Integration then yields the formula


Z
v(t) = −9.8 dt = −9.8 t + C1 ,

dy
where C1 is some constant. Since = v(t), another integration leads to a formula for y(t):
dt
Z
y(t) = v(t) dt = −4.9 t2 + C1 t + C2 ,

where C2 is another constant. At the maximum height,


y 0 (t) = −9.8t + C1 = 0 =⇒ t = C1 /9.8
So the maximum height is
−4.9(C1 /9.8)2 + C1 (C1 /9.8) + C2 = 0.153C12 + C2 .
This is not a particularly instructive answer, since we don’t know C1 and C3 ! Clearly, just knowing
Newton’s second law isn’t enough. We need more information. Specifically, we need to know the height
above ground of the object when it was thrown, and we need to know the velocity of the object when it
was thrown.

We could make up numbers for those, but it’s better to use symbols.

So let’s set
y(0) = y0 and y 0 (0) = v0
2
for the initial height and velocity. And it’s better to use the symbol g rather than it’s value (9.8 m/sec .
Since v(t) = −gt + C1 , we find that v(0) = v0 = C1 . So v(t) = −gt + v0 . Then
1
y(t) = − gt2 + v0 t + C2
2
1 2
So y(0) = C2 = y0 and we have y(t) = gt + v0 t + y0 . The maximum height is
2
 2  
1 v0 v0 1 2
− g + v0 + y0 = v + y0 .
2 g g 2g 0
We now have an expression for the maximum height in terms of the physically meaningful quantities y0
and v0 (initial height and initial velocity) rather than in terms of uninteresting constants. In addition,
by replacing 9.8 by g, we have a general formula that applies to an object thrown on Mars (where
2 2
g = 3.71 m/sec or on the Moon (where g = 1.625 m/sec .

Remark 1.1. (A note on units) In the British system, the unit of mass is the slug and the unit of
force is the pound . A mass of one slug has a weight of about 32 pounds. In general, if a body weighs w
pounds (so the downward force of gravity is w pounds) then its mass m is w/g slugs (this follows from
the formula mg = w = force of gravity). In the mks (meter-kilogram-second) system, the unit of mass is
the kilogram (kg) and the unit of force is the Newton (N). In the cgs (centimeter-gram-second) system ,
the unit of mass is the gram and the unit of force is the dyne. Here are some conversion factors: 1 slug
= 14.6 kilograms, 1 foot = 0.305 meter, 1 pound = 4.45 Newtons

Exercise 1.1. A boater and a motor boat together weigh 640 lbs. Suppose that the thrust of the motor
is equal to a constant force of 20 lb. in the direction of motion, and that the resistance of the water to
the motion is equal numerically to twice the speed in feet per second and that the boat is initially at
rest. Denote the speed of the boat at time t by v = v(t).
4 INTRODUCTION

(a) What is the mass of the boater and boat in slugs?


(b) Write down the differential equation satisfied by v.
dv
Hint:Write Newton’s second law in the form m = Force.
dt

Fspring = −kx

m x

6
x=0 x(t)

Figure 1.1. Hooke’s Law states that the force a spring exerts on an object is propor-
tional to the amount that the spring is stretched or compressed. The x axis is positioned
so that when x = 0 the spring is in its equilibrium position and exerts no force on the
object. For x > 0 the force points to the left (negative) and for x < 0 the force points
to the right.

Example 1.2. (The Harmonic Oscillator) Consider an object of mass m attached to a spring and
free to move to the right and left without friction, as illustrated in Figure 1.1. As we did in the previous
example, we model the motion of the object using Newton’s second law of motion. The only change is
the formula for the force on the object. Hooke’s Law states that the force Fspring that the spring exerts
on the object is proportional to the amount that the spring is stretched (or compressed) relative to its
equilibrium position1 If x = x(t) denotes the position of the object relative to its rest position, Hooke’s
law can be expressed as

Fspring = −kx .

The constant k > 0 is called the spring constant and measures the strength of the spring. The units of k
in the mks system are Newtons per meter and pounds per foot in the British system. In this situation,
Newton’s second law of motion takes the form

d2 x d2 x k
m 2
= −kx or 2
+ x = 0. (1.5)
dt dt m

d2 x 2 k
In the mks system, the units of 2
are meters/sec . It follows that the units of are 1/sec2 .
dt m

As you would suspect, the object will oscillate back and forth along the x-axis, which is why this
mechanical system is called the harmonic oscillator. It’s easy to check directly that the function
r
k
x(t) = C1 cos(ω0 t) + C2 sin(ω0 t) with ω0 =
m

1It it important to keep in mind that Hooke’s Law models an ideal spring and only approximately applies to actual
springs, where the force is only approximately proportional to the amount of stretching.
1.1. SOME EXAMPLES OF MODELING: FALLING BODIES, THE HARMONIC OSCILLATOR, EPIDEMICS, AND ELECTRICAL CIRCUITS
5

is a solution of (1.5) for any constants C1 and C2 . To show this we have to substitute the above formula
for x(t) into the left hand side of the differential equation and verify that it sums to 0. Let’s do it:
d2 x(t) k 00 k
2
+ x(t) = (C1 cos(ω0 t) + C2 sin(ω0 t)) + (C1 cos(ω0 t) + C2 sin(ω0 t))
dt m m
k
= −ω02 C1 cos(ω0 t) − ω02 C2 sin(ω0 t) + (C1 cos(ω0 t) + C2 sin(ω0 t)) .
m
k
= −ω02 (C1 cos(ω0 t) + C2 sin(ω0 t)) + (C1 cos(ω0 t) + C2 sin(ω0 t)) .
  m
k
= − ω02 (C1 cos(ω0 t) + C2 sin(ω0 t))
m
= 0,
p
where in the last step we used the identity ω0 = k/m.

Just as in the previous example, to determine C1 and C2 more information is needed. Suppose both
the position and the velocity of the object at a given time, say t = 0, are known. This initial data is
sufficient to uniquely determine the function x(t). In other words, the data
mx00 + kx = 0 , x(0) = x0 , x0 (t0 ) = v0 ,
comprised of a differential equation together with the position x(0) = x0 and the velocity x0 (0) = v0 of
the object at time t = 0, are sufficient to determine the position of the object for all t. This is easy to
see, for the initial conditions are
x(0) = C1 cos(0) + C2 sin(0) = C1 = x0 and x0 (0) = −C1 ω0 sin(0) + C2 ω0 cos(0) = C2 ω0 = v0 ,
which gives
v0
x(t) = x0 cos(ω0 t) +
sin(ω0 t) .
ω0
In this form, it is difficult to picture the motion. But we can use the phase-shift formula (see Appendix A),
to write the solution in the better form
x(t) = A cos(ω0 t + φ) ,
s  2
v0 v0 /ω0
q
where A = C12 + C22 = x20 +
, and tan(φ) = −C2 /C1 = − . With a little trigonometry,
ω0 x0
you can see the reasoning behind this formula. From high school trigonometry,
A cos(ω0 t + φ) = A cos(φ) cos(ω0 t) − A sin(φ) sin(ωo t)
p
So C1 = A cos(φ) and C2 = −A sin(φ). Think of (C1 , C2 ) as a point in the plane. Then A = C12 + C22
is the distance from the origin to the point and if −φ is the angle between the positive horizontal axis
and the line from the origin to the point (see Figure A.1) then C1 = A cos(−φ) and C2 = A sin(−φ). So
we can compute as follows:
x(t) = C1 cos(ω0 t) + C2 sin(ω0 t)
= (A cos(φ)) cos(ω0 t) − (A sin(φ)) sin(ω0 t)
= A (cos(φ) cos(ω0 t) − sin(φ) sin(ω0 t))
= A cos(ω0 t + φ) .
The units of ω0 are 1/sec, so the product ω0 t is dimensionless. Newton’s second law thus
s predicts that
r  2
2π m v0
the object will oscillate with period T = = 2π seconds and an amplitude A = x20 + =
ω0 k ω0
s
mv02
 
x20 + .
k
6 INTRODUCTION

Example 1.3. (Epidemics) Differential equations are also used to model epidemics. The most simple
model is a “two compartment” model where the population is divided into two populations:
x = the proportion susceptible to infection (“well”)
y = the proportion infected (“sick”)
We’ll make the following additional assumptions:

(a) The disease spreads through contact between sick individuals and well individuals, and the rate
of the spread dy/dt is proportional to the number of such contacts per unit of time.
(b) Members of both groups move about freely among each other, so the number of contacts per
unit time is proportional to the product of x and y.
(c) ’Sick’ individuals don’t recover and so do not become susceptible.

It follows from (a) and (b) that


dy
= αx · y ,
dt
where α is a positive constant related to the frequency of contact and the probability of infection upon
contact. Because everyone is assumed to be either well or sick, it follows that x + y = 1 (100% of the
population). Consequently, x = 1 − y and so
dy
= α (1 − y)y .
dt
If y(0) = y0 is the fraction of the total population that is initially infected, the spread of the epidemic
can be predicted by solving the initial value problem
dy
= α (1 − y)y , y(0) = y0 .
dt
The graphs below show the cumulative percent of the total population that is infected (= 100 y(t)) and
the rate of infection in percent of the total population per day (= 100 y 0 (t)) that the model predicts for
two values of α if initially 1% of the population is infected (that is, y0 = 0.01).

Cumulative infected 3.0 Rate of infection


100
= 0.05
2.5 = 0.10
rate (percent per day)

80
percent infected

2.0
60
1.5
40
1.0
20 = 0.05 0.5
= 0.10
0 0.0
0 50 100 150 200 0 50 100 150 200
day of epidemic) day of epidemic
The larger value of α = 0.10 leads to a maximum rate of inflection of around 2.5 percent per day, while
the smaller value of α = 0.05 lease to a maximum of around 1.25 percent per day, that is a “flatter
curve.” For a serious disease, the rate of infection is a measure of the daily demands on the hospital
system so the public is encouraged to behave in a way the yields a small value of α. Later in these notes,
we will discuss this model in more detail and show how we arrived at the graphs above.

The “two compartment” model is clearly limited, and (at best) only applies at the very beginning of
an epidemic and under limited conditions. More realistic “multi-compartment” models that divide the
1.1. SOME EXAMPLES OF MODELING: FALLING BODIES, THE HARMONIC OSCILLATOR, EPIDEMICS, AND ELECTRICAL CIRCUITS
7

population into suseptibles, exposed, infected, and recovered (SEIR models) were used early on in the
COVID-19 pandemic. Even more realistic models that further divide the population into age groups
and location exist. Such models are beyond the scope of these notes.
Example 1.4. (Electrical Circuits) Electrical circuits are also modeled using differential equa-
tions. An electrical circuit is a collection of electronic components connected by wires through which
an electrical current flows. The main components of electrical circuits are resistors, capacitors, and
inductors, together with external voltage sources, such as batteries, electric generators, and antennas
(which detect electromagnetic radiation, e.g. radio signals). Simple electrical circuits are a nice source
of examples of systems that are nicely modeled by differential equation. We will only consider very
simple circuits made from resistors, capacitors, and inductors. The website https://www.electronics-
tutorials.ws/accircuits/passive-components.html has a nice description of these:

• Resistors regulate, impede or set the flow of current through a particular path or
impose a voltage reduction in an electric circuit as a result of this current flow.
Resistance is denoted by R and is measured in Ohms (denoted by Ω).
• The capacitor is a component that has the ability or “capacity” to store energy
in the form of an electric charge like a small battery. Capacitance is denoted by
C and is measured in Farads (denoted by F) or micro2 Farads (denoted by µF).
• An inductor is a coil of wire that induces a magnetic field within itself or within
a central core as a direct result of current passing through the coil. Inductance3
is denoted by L and is measured in Henries. (denoted by H) or in micro Henries
(denoted by µH)

Figure 1.2. An assortment of inductors (left), resistors (center), and capacitors


(right). (Photograph of inductors by F. Dominec. Photograph of capacitors by Eric
Schrader.)

Figure 1.3 illustrates how a resistor (R), inductor (L), and capacitor (C) might be assembled to form an
electrical circuit called an RLC-circuit. By convention, if electrons are flowing counterclockwise in the
wires, then the current I(t) (measured in amperes) is considered to be flowing in the opposite direction,
i.e. clockwise in the figure. Negative charge will accumulate on one “side” of the capacitor and a positive
charge q(t) (measured in coulombs) will collect on the other side at the rate
q 0 (t) = I(t) , (1.6)
as illustrated in the schematic diagram shown in Figure 1.3.

The current in the circuit is related to the voltage source V (t), which acts as a pressure causing current
to flow along the wires of the circuit. For example, if the voltage source is a 9-volt battery, then

2Micro, denoted by µ, means 10−6 . For instance, 100µF denotes a capacitance of 100 × 10−6 = 10−4 Farads.
3The symbol ’L’ is used in the name of the physicist Heinrich Lenz, who studied inductance.
8 INTRODUCTION

V (t) = 9 Volts. The voltage source from an electrical receptacle in the U.S. is a 60 cycle per second 120
volt source:4

 

V (t) = 120 2 cos t volts.
60
Moving clockwise around the circuit, the voltage (“pressure”) drops across each component by an amount
that depends on the component. Denoting the voltage drops across the resistor, capacitor, and inductor
by VR (t), VC (t) and VL (t), respectively:
1 dI(t)
VR (t) = RI(t) VC (t) = q(t) VL (t) = L . (1.7)
C dt

If you are unfamiliar with electrical circuits, please do not be concerned. Eugene Khutoryansky has
made several elementary videos explaining the basics of simple electric circuits for people with little or
no background in physics. Here are links to four of his videos on YouTube: Battery Energy and Power,
Voltage and Current Laws, Ohms Law, Capacitors. These videos are all you need to understand. Please
take some time to view them (each one is only a few minutes long).
R C L
+ -
+ -
- + -
+ -
+ -
+ -
q(t)

V (t) ?

 I(t)

Figure 1.3. A schematic diagram of an RLC-circuit with an external (time dependent)


voltage source V (t).

In this course, we use electrical circuits only to illustrate applications of differential equations. All of
our applications use Kirchhoff ’s law , which states that the voltage drops around a closed circuit sum to
zero:
Kirchhoff’s law: VL (t) + VR (t) + VC (t) + (−V (t)) = 0 , (1.8)
where, because V (t) is a voltage increase, it becomes −V (t) when viewed as a drop.

Combining Equations (1.6), (1.7), and (1.8) leads to the following second order differential equation for
q(t):
1
L q 00 + R q 0 + q = V (t) , (1.9)
C
modeling an RLC-circuit. Because VC = q/C, the differential equation (1.9) can be rewritten as a
differential equation for voltage across the capacitor:
(LC) VC00 + (RC) VC0 + VC = V (t) ,
If we remove the resistor and voltage source from the circuit, then the differential equation for VC reduces
to
1
VC00 + VC = 0 ,
LC
which (apart from the change of symbols) is the same as Equation (1.5) for the harmonic oscillator. This
implies that, just as the position of the mass in the mass-spring system oscillates, so does the charge on
the capacitor in an LC-circuit.

4The maximum voltage is 120



2 ≈ 170 volts. The figure 120 is the “root mean square” of the voltage.
1.2. WHAT’S A differential equation AND WHAT DOES IT MEAN TO “SOLVE” IT? 9

Exercise 1.2. Suppose we remove both the capacitor and the voltage source from the circuit in Fig-
ure 1.3. Then the circuit becomes

I(t)

R
Assume that the inductor has an inductance of L = 10µ-Henries (= 10 × 10−6 Henries, and the resistor
has a resistor of R = 100 Ohms. Writing down the differential equation satisfied by the current I.
Hint: For this circuit, Kirchhoff ’s law says that the sum of the voltage drops across the inductor and
the resistor is zero. It might also be worthwhile to look closely at the formulas in (1.7).

1.2. What’s a differential equation and what does it mean to “solve” it?

We now have examples from physics, epidemiology, and engineering where differential equations are
used. It’s time now to isolate what these examples have in common from a mathematical perspective.
This will allow us to develop techniques that apply to many disciplines.

Suppose that t and y are two quantities where y depends on t. It is often useful to think of t as time and
y as a quantity that varies in time according to some rule. A first order ordinary differential equation
or simply a first order differential equation 5 is an equation of the form
y 0 = F (t, y)
where F (t, y) denotes a function of t and y. A solution of the differential equation is a function y = y(t)
that satisfies the identity
y 0 (t) = F (t, y(t)) .
on some interval.
2
Example 1.5. The function y(t) = e−t is a solution of the differential equation y 0 = −ty because
/2

 
2 −2t 2
y 0 (t) = e−t /2 = −te−t /2 = −ty(t) .
2
2
Another solution solution is y1 (t) = 5e−t /2
.

Similarly, a second order differential equation is an equation of the form


y 00 = F (t, y, y 0 ) ,
and a solution is a function y = y(t) that satisfies the equation
y 00 (t) = F (t, y(t), y 0 (t))

5Partial differential equations involve functions of more than one variable and partial derivatives. The word “ordinary”
refers to differential equations involving functions of only one variable. Since we do not consider partial differential equations
in these notes, we will usually drop the word “ordinary.”
10 INTRODUCTION

Example 1.6. The function y(t) = sin(2t) is a solution of the differential equation
y 00 + 4y = 0
because sin00 (2t) + 4 sin(2t) = −4 sin(2t) + 4 sin(2t) = 0. The function cos(2t) is also a solution. In fact,
any function of the form
y(t) = C1 cos(2t) + C2 sin(2t) , for C1 and C2 constants,
is a solution, as you can see by plugging this formula into the the expression y 00 (t) + 4y(t), computing
the second derivative, and simplifying. If you don’t make any algebra errors, you should end up with 0.
Example 1.7. It’s a fact that the solution of many differential equations can be written in terms of
the exponential function (i.e. ert ), sines and cosines (cos(ωt) and sin(ωt)), or a combination of these.
This will only become apparent later in the course. But for now, we can use this observation to guess
solutions to some differential equations.

For instance, the exponential function y = ert is a good candidate for the solution of the differential
equation
y 00 + 3y 0 + 2y = 0 .
rt
Substituting e into the differential equation gives
(ert )00 + 3(ert )0 + 2(ert ) = r2 ert + 3rert + 2ert = (r2 + 3r + 2)ert = (r − 2)(r − 1)ert = 0 .
This implies that r = 2 or r = 1. Therefore, y(t) = e2t and y(t) = et are both solutions. Armed with
these two solutions, one then finds that
y(t) = C1 et + C2 e2t
is also a solution for any two constants C1 and C2 , as you should check for yourself!
Exercise 1.3.
(a) For two values of r, find a solution of the differential equation y 00 + 4y 0 − 21y = 0 of the form ert .
(b) Find a solution of the differential equation y 00 + 4y = 24e2t of the form y = Aert . Hint:You have to
figure out both r and A.

1.3. What is an Initial Value Problem?

We seen that differential equations such as those above have many solutions. To narrow the possibilities,
we’ve seen that additional information is necessary in the form of “initial data.” We codify this in
the following definition: A (first order) initial value problem or IVP is given by a differential equation
together with the value of the solution at point of the form:
y 0 = F (t, y) and y(t0 ) = y0 . (1.10)
A solution of this initial value problem is a function y(t) that satisfied both the differential equation and
the initial condition. That is,
y 0 (t) = F (t, y(t)) for all t and y(t0 ) = y0
The initial condition is just the equation y(t0 ) = y0 , giving the value of the solution at a particular value
of t.
Example 1.8. Consider the initial value problem
y0 + y = 0 , y(1) = 4
−t
One checks that the function y(t) = Ce for C a constant is a solution of the differential equation. The
initial condition y(1) = Ce1 = 4 implies that C = 4e−1 . Consequently,
y(t) = 4e−1 et = 4et−1
1.3. WHAT IS AN INITIAL VALUE PROBLEM? 11

is the solution to the initial value problem.

A (second order) initial value problem consists of the following data:


y 00 = F (t, y, y 0 ) , y(t0 ) = y0 , y 0 (t0 ) = y00 . (1.11)
A solution of the initial value problem (1.11) is a function y = y(t) satisfying both the differential
equation and the initial conditions. That is,
y 00 (t) = F (t, y(t), y 0 (t)) , y(t0 ) = y0 , and y 0 (t0 ) = y00 .
Example 1.9. Find the solution of the initial value problem
y 00 + 3y 0 + 2y = 0 , y(0) = 2 , y 0 (0) = 3 .
Solution From Example 1.7, we know that the function
y(t) = C1 et + C2 e2t ,
where C1 and C2 are constants, is a solution of the differential equation. For this function, the initial
conditions are
y(0) = C1 + C2 = 2 and y 0 (0) = C1 + 2C2 = 3 .
These two algebraic equations can be solved for C1 and C2 using high school algebra to give C1 = 1 and
C2 = 1. The solution to the initial value problem is, therefore,
y(t) = et + e2t .
Example 1.10. Solve the initial value problem
y 00 + 4y = 0 , y(0) = 2 , y 0 (0) = 6 .
Solution By Example 1.6, the function y(t) = C1 cos(2t) + C2 sin(2t) is the solution of the differential
equation. The initial conditions then give
y(0) = C1 = 2 and y 0 (0) = 2C2 = 6 ,
which implies C2 = 3. Therefore, the function y(t) = 2 cos(2t) + 3 sin(2t) is the solution of the initial
value problem.

As we’ve already seen, when written in the form y(t) = 2 cos(2t) + 3 sin(2t), it isn’t clear what the graph
of the function y(t) looks like. A better way to visualize it is to express it in the form y(t) = A cos(2t+φ).
To do this use the “phase-shift formula” in Appendix A) to write y(t) as follows:
p
y(t) = 2 cos(2t) + 3 sin(2t) = 22 + 32 cos (2t − arctan(3/2)) ≈ 3.6 cos (2(t − 0.49)) .
In this form, the graph of y(t) is easily sketched (see Figure 1.4). It’s a cosine function of amplitude 3.6,

shifted to the left by 0.49 units, and of period T = ≈ 3.14.
2

Exercise 1.4. Find the solution of the initial value problem


y 0 + 3y = 0 , y(1) = 2 .
rt
Hint: Look for a solution of the form y(t) = Ce .
Exercise 1.5. Find the solution of the initial value problem
y 00 + 3y 0 + 2y = 0 , y(0) = 2 , y 0 (0) = 1 .
Hint: Look for a solution of the form y(t) = C1 er1 t + C2 er2 t .
12 INTRODUCTION

4 13cos(2t + )
13cos(2t)
2

y
0

4
1 0 1 2 3
t


Figure 1.4. The graph of y = 13 cos(2t − arctan(3/2)).
Part 1

First Order Differential Equations


CHAPTER 2

The Geometry of First Order Differential Equations

In this chapter, we begin a study of the geometry of first order differential equations. It introduces
the direction field of a differential equation, giving a way to visualize solutions of first order differential
equations and initial value problems. It ends with Euler’s method for finding approximate solutions of
the initial value problem
y 0 = F (t, y) , y(t0 ) = y0
in cases where we can’t find an explicit solution.

In the following chapters, we focus on two particular classes of first order differential equations (separable
and linear differential equations) where explicit methods for finding solutions are known. We conclude
our study of first order differential equations with some applications of the theory.

2.1. The Direction Field of a Differential Equation

In this section, we present a geometric description of the differential equation


dy
= F (t, y)
dt
that is useful for understanding the behavior of its solutions.

Fundamental Observation: Suppose we already know that y = y(t) is a solution to this differential
equation. We can evaluate the derivative y 0 (a) without differentiating:
y 0 (a) = F (a, y(a)) .
Therefore, if y(a) = b, then the slope m of the tangent line to the curve y = y(t) at (a, b) is m = y 0 (a) =
F (a, b); and the equation of the tangent line to y = y(t) at t − a is
y = m(t − a) + b where m = F (a, b).
We can encode this by drawing a short line segment of slope m = F (a, b) through the point (a, b). This
line segment is called a direction element or line element of the differential equation.
2
Example 2.1. For instance, suppose that y = y(t) is a solution of the differential equation y 0 = −y
t+1
2
and we know that y(1) = 2. Then y 0 (1) = − 2 = −1. The direction element for this differential
1+1
equation is, therefore, a line segment through the point (1, 2) of slope −1. The graph of solution is the
dark curve in Figure 2.1.

The direction field of the differential equation is the picture obtained by drawing a direction element
through each point in the (t, y)-plane. The effect of drawing lots of direction elements is a picture that
resembles a collection of iron filings in a magnetic field (the filings line up parallel to the magnetic field).
15
16 THE GEOMETRY OF FIRST ORDER DIFFERENTIAL EQUATIONS

4
3
2
y

1
0
1
0 1 2 3
t
2
Figure 2.1. The direction field of the differential equation y 0 = − y, together
t+1
with several integral curves.

By construction, if y = y(t) is a solution of the differential equation, then at every point (a, y(a) the
slope of the tangent line to the curve agrees with the slope of the line element F (a, b). This forces the
graphs of solutions to conform with the direction field of the differential equation (see Figure 2.1),

The graphs of solutions of a differential equation are called integral curves of the differential equation.
The fact that “nice” differential equations have unique solutions has a geometric interpretation: the
integral curves of a first order differential equation never cross; and there is a unique integral curve
through each point (t0 , y0 ) in the (t, y)-plane.
Exercise 2.1. The direction field of the differential equation v 0 = F (t, v) is shown in the figure below.
(a) On the figure, carefully sketch the solution to the initial value problem
v 0 = F (t, v) , v(0) = 0.5 .

2.0

1.5

1.0

0.5

0.0

0.5
0.5 0.0 0.5 1.0 1.5 2.0
2.2. STABILITY ANALYSIS OF AUTONOMOUS FIRST ORDER DIFFERENTIAL EQUATIONS 17

(b) Let y = y1 (t) be the solution of the initial value problem in part (a). What is the approximate value
of y1 (1.5)?
(c) Now sketch the solution of the initial value problem v 0 = F (t, v) , v(0) = 0. Let y = y2 (t) be the
solution of this initial value problem.
(d) Assume that the solutions y1 (t) and y2 (t) are defined for all values of t between 0 and 5. Is it possible
for the graphs of y1 (t) and y2 (t) to cross at t = 5? Explain your answer.

2.2. Stability Analysis of Autonomous First Order Differential Equations

A differential equation of the form


dy
= F (y) (F is independent of t) (2.1)
dt
is called an autonomous differential equation. As illustrated in Figure 2.2, the direction elements of
autonomous differential equations have constant slope along horizontal lines.

A point y = ye with F (ye ) = 0 is called an equilibrium point of the differential equation 2.1 (Such points
are also called critical points or fixed points.) If ye is a fixed point then the constant function y(t) = ye
is a solution of the differential equation. The differential equation whose direction field is pictured in
Figure 2.2 has three fixed points at y = a, y = b, and y = c..

y
6

y=c -

y=b -

y=a-
t
-
Figure 2.2. The direction field of an autonomous differential equation with three
fixed points y = a (stable), y = b (unstable) and y = c (semi-stable).

A fixed point of an autonomous differential equation that acts like an attractor is said to be a stable
equilibrium point. That is, ye is a stable equilibrium point if the solution of the initial value problem
approaches ye whenever the initial condition is sufficiently close to ye . The equilibrium point ye is said
to be semi-stable if ye is not a stable equilibrium point, but for some  > 0 the function F (y) is negative
for y in the interval (ye , ye + ) or F (y) is positive for all y in the interval (ye − , ye ). If the equilibrium
point ye is neither stable nor semi-stable, then it is said to be unstable.

There is a simple way to test the stability of fixed points:

Criterion for stability: If for some  > 0, the function F (y) is negative for y in the
interval (ye , ye + ) and positive for all y in the interval (ye − , ye ), then ye is a stable
equilibrium point.
18 THE GEOMETRY OF FIRST ORDER DIFFERENTIAL EQUATIONS

Figure 2.2 illustrates the three types of equilibrium points. You should verify for yourself that y = a
satisfies the criterion for stability.
Example 2.2. (a) The fixed points of the differential equation y 0 = (1 − y 2 ) are the points y = 1 and
y = −1. Because y 0 is negative for y < −1, positive for −1 < y < +1, and negative for y > 1, it follows
that y = −1 is an unstable fixed point and y = +1 is a stable fixed point.

(b) The fixed points of the differential equation y 0 = sin(πy) are the integers y = 0, ±1, ±2, . . . . Do you
see why the fixed points are unstable for y even and stable for y odd?

2.3. Euler’s Method

Although there are a number of techniques for solving special classes of differential equations, there is no
general algorithm for solving all differential equations. Consequently, mathematicians have developed
a number of numerical methods for finding approximate solutions of many differential equations that
appear in applications. Finding better numerical methods remains an active area of research. Of these,
Euler’s method is the simplest and the easiest to describe.

The method is based on the tangent line approximation. Suppose that y = y(t) is a differentiable
function of t and we know both the value of y(t) and the slope of the tangent line to y = y(t) at t = t0 .
The tangent line approximation of y(t) at t = t0 is the linear function
y = y0 + y 0 (t0 ) (t − t0 ) ,
which approximates t = y(t) for values of t near t0 (see Figure 2.3).
(t, y(t))
P
q
P
y(t)

y(t0 )

t0 t
Figure 2.3. The tangent line approximation
Example 2.3. To understand how to use the tangent line approximation to approximate the solution
of a differential equation, consider the following initial value problem:
y0 = y , y(0) = 1 .
Ignore for the moment that the solution is y(t) = et . Choose a small step size, say h = 0.1. We
will use the tangent line approximation to find approximate values for y(h) = y(0.1), y(2h) = y(0.2),
y(3h) = y(0.3), etc.

Because y 0 (t) = y(t), we know that y 0 (0) = y(0) = 1. The tangent line approximation then gives the
approximation
y(0.1) ≈ y(0) + y 0 (0)(0.1 − 0) = 1 + (1)(0.1) = 1.1 .
2.3. EULER’S METHOD 19

The tangent line approximation can be used again to approximate y(0.2): From the differential equation,
y 0 (0.1) = y(0.1) ≈ 1.1. Therefore,
y(0.2) ≈ y(0.1) + y 0 (0.1)(0.1) = 1.1 + (1.1)(0.1) = 1.21 .
We can repeat this as many times as we like. The following table summarizes the result for the first ten
iterations of this process:

n= 0 1 2 3 4 5 6 7 8 9 10
t= 0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0
yn = 1.000 1.100 1.210 1.331 1.464 1.611 1.772 1.949 2.144 2.358 2.594
y(t) = et = 1.000 1.105 1.221 1.349 1.492 1.649 1.922 2.014 2.226 2.460 2.718

3.0 10
y = et y = y(t) = (solution)
2.5 8 yn (Euler approximation)
yn
6
2.0
4
1.5 2
y

1.0 0
0.5 2
4
0.0
0.0 0.2 0.4 0.6 0.8 1.0 0 1 2 3 4 5
t t

Figure 2.4. The figure on the left shows Euler’s method applied to the initial value
problem y 0 = y, y(0) = 1.0, with step size h = 0.1. The figure on the right shows
the result of applying Euler’s method to the initial value problem y 0 + y = 10 cos(πt),
y(0) = 8.0, with step size h = 0.1.

The general method to find an approximate solution of the initial value problem y 0 = F (t, y), y(t0 ) =
y0 , proceed as follows:

(0) Choose a step size h > 0.


(1) Set n = 0.
(2) Set yn0 = F (tn , yn ).
(3) Set tn+1 = tn + h.
(4) Set yn+1 = yn + yn0 · h
(5) Increase n by one and go to step (2).
Exercise 2.2. Suppose that y = y(t) is the solution of the initial value problem
y 0 = t + cos(y) , y(0) = 1 .
Use Euler’s method with a step size of h = 0.2 to estimate y(1).
CHAPTER 3

Solving First Order Differential Equations

Euler’s method only gives approximate solutions to differential equations. In this chapter, we discuss
two classes of differential equations in which it is possible to obtain exact solutions: separable differential
equations and linear differential equations.

A (first order) separable differential equation is one of the form6


h(y)y 0 = g(t) , (3.1)
where g(t) and h(y) are continuous functions, is called a separable differential equation..

A (first order) linear differential equation is one of the form


y 0 + p(t)y = f (t) , where p(t) and f (t) are continuous (3.2)
In the special case when f (t) = 0, the differential equation is called a homogeneous linear differential
equation ; otherwise, it is said to be a nonhomogeneous differential equation. The function f (t) on the
right-hand side of a differential equationis called the forcing function

Example 3.1. Here’s an alarming example of an initial value problem that doesn’t have a unique
solution: consider the initial value problem
dy
= F (y) , y(0) = 0 ,
dt
p
where F (y) = 2|y|. For any real number a > 0, consider the function ya (t) defined as follows:
(
(t − a)2 /2 for t ≥ a
ya (t) =
0 for t ≤ a .
By construction, ya (t) satisfies the initial condition ya (0) = 0. It also satisfies the differential equation
ya0 (t) = F (ya (t)) for all t .
This is clear because
ya0 (t) = 0 = F (0) = F (ya (t)) for t ≤ a ,
and
d(t − a)2 /2 p
= (t − a) = 2(t − a)2 /2 = F (ya (t)) for t ≥ a .
dt
Remark 3.1. The previous example naturally leads to the following question:

What conditions on F (t, y) are sufficient to guarantee that the initial value problem
y 0 = F (t, y) , y(t0 ) = y0
has a unique solution?
6If you took Math 125 here at the UW, then you’ve already worked with separable differential equations, and much
of the material in the next section will be a review for you.

21
22 SOLVING FIRST ORDER DIFFERENTIAL EQUATIONS

Although this is a fascinating question, it will not be addressed here. Suffice it to say that if the
function F (t, y) is sufficiently nice7 (which is the case in virtually all differential equations encountered
in practice), then the initial value problem has a unique solution. That means two things: (1) there is
a solution, and (2) there is only one solution to the initial value problem.

This fact has an important geometric interpretation, which it is very important to keep in mind: (Pro-
vided F (t, y) is sufficiently nice)
the integral curves of a first order differential equation never cross.

To see this, we can argue as follows: If two integral curves crossed, say at the point (t0 , y0 ), then they
there would be at least two solutions of the initial value problem
y 0 = F (t, y) , y(t0 ) = y0 ,
which would contradict the claim that there is only one solution.

3.1. Separable Differential Equations

Consider the separable differential equation


h(y)y 0 = g(t) ,
where g(t) and h(y) are continuous functions. Our goal is to find a technique for solving it.

Start by assuming that the function y = y(t) is a solution of the differential equation. Then, by definition,
it satisfies the equation
h(y(t))y 0 (t) = g(t) ,
for all values of t in some interval, say a < t < b. It follows that the integral of the left-hand side differs
from the integral of the right-hand side by a constant:
Z Z
h(y(t))y 0 (t) dt = g(t) dt + C .

Let8 Z y Z t
H(y) = h(z) dz and G(t) = g(s) ds
be anti-derivatives of h(y) and g(t), respectively. Thus, the function y = y(t) is implicitly defined by the
equation
H(y) = G(t) + C . (3.3)

This process can be reversed. Suppose that y = y(t) satisfies (3.3). The computation
dH(y(t))
= H 0 (y(t)) y 0 (t) = h(y(t)) y 0 (t) = G0 (t) = g(t) .
dt
then shows that it is y(t) a solution of the differential equation (3.1), called the general solution of the
differential equation.
Remark 3.2. The function y = y(t) is said to be implicitly defined by (3.3) because for a given value
of t it is in general not clear how to determine y(t). Unfortunately, Equation (3.3) cannot always be
explicitly solved for y in terms of t. It is, however, best to obtain an explicit solution when possible.
7The function F (t, y) in Example 3.1 is not differentiable with respect to y at y = 0; it is not “nice.”
Z x Z x
8We use the notation f (s) ds to denote a specific anti-derivative of the function f (x). For instance, cos(s) ds =
sin(x) rather than sin(s) + C.
3.1. SEPARABLE DIFFERENTIAL EQUATIONS 23

dy
Example 3.2. Solve the differential equation = (1 + y 2 )et/2 .
dt

1 dy
Solution Rewrite the differential equation in the form = et/2 .
1 + y 2 dt
Integrate
Z y Z t
dz
= es/2 ds + C
1 + z2
to arrive at the implicit solution tan−1 (y) = 2et/2 + C, where C is an arbitrary constant.
In this case, it is possible to solve for y to obtain the explicit solution
 
y(t) = tan 2et/2 + C .

3.1.1. Solving Initial Value Problems. The solution of the initial value problem
h(y)y 0 = g(t) y(t0 ) = y0 ,
can be found by first finding the general solution:
H(y) = G(t) + C ,
0 0
where H (y) = h(y) and G (t) = g(t); and then setting y = y0 and t = t0 to solve for C:
H(y0 ) = G(t0 ) + C or C = H(y0 ) − G(t0 )
to obtain the solution
H(y) − H(y0 ) = G(t) − G(t0 ) . (3.4)

Example 3.3. Solve the initial value problem y 0 = (1 + y 2 )et , y(0) = 1.

y0
Solution Write the differential equation in the form = et .
1 + y2
Now integrate to get
tan−1 (y) − tan−1 (1) = et − e0 .
Since tan−1 (1) = π/4 and e0 = 1, it follows that
tan−1 (y) − π/4 = et − 1 .
Solving for y yields the final result:
y(t) = tan et − 1 + π/4 .


Exercise 3.1. Solve each of the following first order differential equations and initial value problems.
(Note that in some of these, the independent variable is x rather than t.

(a) y 0 = (1 − t)(2 − t), y(1) = 1.


(b) y 0 = (1 − t)(2 − y).
(c) y 0 = 2y(1 − y), y(0) = 2.
dy
(d) = ay(b − y), y(0) = y0 , where a > 0 and b > 0 are constants.
dt
0
(e) y = 1 − y 2 , y(0) = 0.
(f) y 0 = cos(x)(y 2 + 1).
dy p
(g) = x 4 − y2 .
dx
24 SOLVING FIRST ORDER DIFFERENTIAL EQUATIONS

3.2. Linear First Order Differential Equations

A linear first order differential equation is a differential equation that can be written in the form
y 0 + p(t)y = f (t) ,
where p(t) and f (t) are continuous or piecewise continuous on some interval. Remember also that when
f (t) = 0, the equation is said to be a homogeneous differential equation, otherwise, it is said to be
nonhomogeneous differential equation. The function f (t) is called the forcing function.
Examples 3.4. The following differential equations are all linear:
dy
+ 2y = 0 y 0 + 2y = et
dt
dy
+ ty = 0 y 0 + ry = k, r, k constant
dt
(1 + t2 )y 0 + y = 0 ty 0 = tet − y, t>0
0 −1 0 −1
y +t y = 1, t>0 y + y = sin (t), |t| < 1

1
Note: the equation (1 + t2 )y 0 + y = 0 is linear because it can we rewritten as y 0 + y = 0. Similarly,
1 + t2
1
the differential equation ty 0 = tet − y is linear because it can be rewritten as y 0 + y = et .
t

If a differential equation cannot be rewritten in the form y 0 + p(t)y = g(t), then we say that it is a
nonlinear differential equation. Here are some examples of nonlinear differential equations:
dy 1 dy
+ 2y 2 = 0 y 0 + 2 = et y + ty = 2
dt y dt

(y 0 )2 + y = t y0 + y = 0 y 0 + ty = (1 + y 2 )
Remark 3.3. Some differential equations are both linear and separable. Here are a few examples:
y0
y 0 + 5y = 3 can we rewritten as =1
3 − 5y
y0
y 0 + cos(t)y = 0 can be rewritten as = − cos(t)
y
y0
et y 0 + ty = 0 can be rewritten as = −te−t
y

In these cases, the differential equation can be solved either by separation of variable or by the method
we are about to explain.

3.2.1. Undetermined coefficients for first order differential equations. When p(t) = k, for
k a constant, the differential equation has the form
y 0 + ky = f (t) .
When, in addition, the forcing function f (t) is one of the following forms:
f (t) = a , aebt , atn , a cos(ωt) , or a sin(ωt) , (3.5)
where a, b, n, and ω are constants it is possible to quickly solve the differential equation, as we now
show.
3.2. LINEAR FIRST ORDER DIFFERENTIAL EQUATIONS 25

First notice that if y(t) is a solution than so is y(t) + Ce−kt , where C is a constant. We can see this
by computing. Suppose that y(t) is a solution. That means that y 0 (t) + ky(t) = f (t). Now compute as
follows:
0
y(t) + Ce−kt + k y(t) + Ce−kt = y 0 (t) − kCe−k + ky(t) + kCe−kt = y 0 (t) + ky(t) = f (t) ,


which shows that y(t) + Ce−kt is also a solution. Since this always happens, all we need to do if guess
a particular solution to the differential equation and add Ce−kt to it. To make this clear, I’ll denote a
particular solution by yp (t). The general solution of the differential equation y 0 + ky = f (t) is then
y(t) = yp (t) + Ce−kt .
(By “general solution” we mean that by choosing the appropriate value of C we can express any solution
this way.)
Example 3.5.
(a) Find the general solution of the differential equation y 0 + y = t.
(b) Find the solutions that satisfy each of the following initial conditions:
y(0) = −3, y(0) = 2, and y(0) = 0.
(c) Sketch the direction field for the differential equation along with the graphs of the three solutions you
found in part (b).

Solution (a) Try yp (t) = At + B. Then


yp0 (t) + yp (t) = A + (At + B) = At + (A + B) = t .
This forces A = 1 and B = −A = −1, so the general solution is
y(t) = t − 1 + Ce−t .
(b) Since y(0) = C − 1, the three initial conditions force C to have the values −2, 0, and 3, respectively.
So the solutions to the three initial values problems are
y(t) = (t − 1) − 2e−t , y(t) = t − 1 , and y(t) = t − 1 + 3e−t .
(c) To sketch the direction field, write the differential equation in the form y 0 = t − y. Notice that y 0 = 0
along the line y = t; y 0 < 0 above the line, and y 0 > 0 below the line. This alone is enough to give a
rough picture of the direction field. I’ve used computer software to generate the more detailed picture
along with the graphs of the three solutions shown below.

4
3
2
1
y

0
1
2
3
0.0 0.5 1.0 1.5 2.0 2.5 3.0
t

Now suppose that the forcing function is f (t) = aebt , with b 6= −k. We want to solve the differential
equation
y 0 + ky = aebt for b 6= −k.
26 SOLVING FIRST ORDER DIFFERENTIAL EQUATIONS

Substituting yp (t) = Ae−bt into the differential equation and computing as follows:
(Aebt )0 + k(Aebt ) = (b + k)Aebt = aebt
a 1 at
shows that A = k+b and, therefore yp (t) = e . So the general solution is
k+b
1 bt
y(t) = Ce−kt + e , for C a constant.
k+b
This solution is not valid when b = −k and Ae−kt is a solution of the homogeneous differential equation
y 0 + ky = 0. In this case, there is a particular solution of the form yp (t) = Ate−kt
Example 3.6. Let’s work out a concrete example:
(a) Find the general solution of the differential equation y 0 + 7y = 8e−3t .
(b) Solve the initial value problem y 0 + 7y = 8e−3t , y(0) = 6.
(c) Find the general solution of the differential equation y 0 + 7y = 3e−7t .

Solution (a) Let yp = Ae−3t , and compute as follows to find A:


(Ae−3t )0 + 7(Ae−3t ) = ((−3) + 7)Ae−3t = 4Ae−3t = 8e−3t .
So 4A = 8 or A = 2. Hence, a particular solution is yp (t) = 2e−3t and
y(t) = 2e−3t + Ce−7t
is the general solution of the differential equation.

(b) We have to find C. But y(0) = 2 + C = 6, so C = 4 and the solution of the initial value problem is
y(t) = 2e−3t + 4e−7t .

(c) Let yp (t) = Ate−7t , and compute as follows:


0
Ate−7t + 7 Ate−7t = A(1 − 7t)e−7t + 7Ate−7t = Ae−7t = 3e−7t .


So A = 3, and the general solution is y(t) = 3te−7t + Ce−7t = (3t + C)e−7t .

Another commonly occurring class of equations consists of differential equations of the form
y 0 + ky = a cos(ωt) + b sin(ωt) .
Example 3.7. Rather than deriving a general formula, it’s easier to work by example.
(a) Find the general solution of the differential equation y 0 + 2y = 4 cos(3t)
(b) Solve the initial value problem y 0 + 2y = 4 cos(3t), y(0) = 0. Graph the solution.
(c) Find the general solution of the differential equation y 0 + 2y = 4 cos(3t) + 2 sin(3t)

Solution (a) We know that the solution is of the form y(t) = yp (t) + Ce−2t , so we only need to find a
particular solution yp (t), which we are going to assume to be of the form
yp (t) = A cos(3t) + B sin(3t) ,
where A and B are real numbers that we have to find. Under this assumption, we can compute as
follows:
0
yp0 (t) + 2yp (t) = (A cos(3t) + B sin(3t)) + 2 (A cos(3t) + B sin(3t))
= −3A sin(3t) + 3B cos(3t) + 2A cos(3t) + 2B sin(3t)
= (−3A + 2B) sin(3t) + (2A + 3B) cos(3t)
= 0 sin(3t) + 4 cos(3t) = 4 cos(3t) .
3.2. LINEAR FIRST ORDER DIFFERENTIAL EQUATIONS 27

This shows that yp (t) is a solution provided we choose A and B to satisfy the equations
−3A + 2B = 0 and 2A + 3B = 4 .
This is a problem in high school algebra: From the first equation, B = 3A/2. Substituting this into the
second equation gives 2A + 3(3A/2) = (13/2)A = 4, which implies A = 8/13 and B = (3/2)(8/13) =
8 12
12/13. Therefore, yp (t) = cos(3t) + sin(3t), and
13 13
8 12
y(t) = cos(3t) + sin(3t) + Ce−2t
13 13
is the general solution of the differential equation.

(b) We have to find the value of C. But


8 12 8 8
y(0) = cos(0) + sin(0) + Ce0 = + C = 0 implies C = − .
13 13 13 13
So
8 12 8
y(t) = cos(3t) + sin(3t) − e−2t
13 13 13
is the solution of the initial value problem. Using the phase-shift formula, we can write the solution in
the alternate form
4 8
y(t) = √ cos 3t − tan−1 (3/2) − e−2t ≈ 1.109 cos(3t − 0.983) + 0.615 e−2t ,

13 13
in which it’s easier to visualize the graph of the solution, which is shown below.

y
1.0
0.5
t

3

3
π 4π
3
−0.5

−1.0

(c) The computation is almost the same as the one we did in part (a):
0
yp0 (t) + 2yp (t) = (A cos(3t) + B sin(3t)) + 2 (A cos(3t) + B sin(3t))
= −3A sin(3t) + 3B cos(3t) + 2A cos(3t) + 2B sin(3t)
= (−3A + 2B) sin(3t) + (2A + 3B) cos(3t)
= 2 sin(3t) + 4 cos(3t) .
So A and B must now satisfy the equations −3A + 2B = 2 and 2A + 3B = 4, from which we find that
2 16
A= and B = . The general solution is, therefore,
13 13
2 16
y(t) = cos(3t) + sin(3t) + Ce−2t .
13 13

3.2.2. The General Case. When p(t) is not a constant and/or when the forcing function f (t) is
more general than in the previous section, we have to adopt a more systematic approach that applies to
all initial value problems of the form
y 0 + p(t)y = f (t) , y(t0 ) = y0 , (3.6)
where p(t) and f (t) are continuous functions on an interval a < t < b and t0 is between a and b. (When
a and b are not explicitly given, we take the largest interval on which p(t) and f (t) are continuous.)
28 SOLVING FIRST ORDER DIFFERENTIAL EQUATIONS

In this approach, multiplying the differential equation by a so-called integrating factor transforms the
differential equation into one that can be solved by Riemann integration.

The computations are easier to understand in the constant coefficient case, where p(t) = k and where
t0 = 0:
y 0 + ky = f (t) , y(0) = y0 . (3.7)
Begin by assuming that the function y = y(t) is a solution of (3.7). Then, by definition, it satisfies the
equation
y 0 (t) + ky(t) = f (t) .
Multiply both sides of this equation by ekt (this is the “integrating factor”) to obtain the equation
ekt y 0 (t) + kekt y(t) = ekt f (t) ;
and notice that, by the product rule for differentiation,
0
ekt y(t) = ekt y 0 (t) + kekt y(t) .
This shows that the solution satisfies the equation
0
ekt y(t) = ekt f (t) ,
which can be integrated to obtain the equality
Z t Z t
ks
0
e y(s) ds = eks f (s) .
0 0
By the Fundamental Theorem of Calculus, the integral on the left can be explicitly evaluated to yield
the equation
Z t
ekt y(t) − y(0) = eks f (s) ds , (3.8)
0
which, in turn, can be solved for y(t) to yield a formula for y(t):
Z t 
y(t) = e−kt eks f (s) ds + y(0) . (3.9)
0

Finally, recall that y(t) satisfies the initial condition y(0) = y0 and simplify to obtain the formula
Z t
y(t) = e−kt eks f (s) ds + y0 e−kt . (3.10)
0

Remark 3.4. To can check directly that y(t) is a solution of the initial value problem, first notice that
the computation
Z 0
y(0) = e−k0 eks f (s) ds + y0 e−k0 = 0 + y0 = y0 ,
0
shows that y(t) satisfies the initial condition. Next notice that (by the Fundamental Theorem of Calcu-
lus):
Z t 
0 −kt
e f (s) ds + e−kt ekt f (t) − ky0 e−kt
ks

y (t) = −ke
0
 Z t  
−kt ks −kt
=−k e e f (s) ds + y0 e + f (t)
0
= −ky(t) + f (t) .
Consequently, y 0 (t) + ky(t) = (−ky(t) + f (t)) + ky(t) = f (t), showing that y(t) is, indeed, a solution of
the differential equation.

This analysis accomplished three goals:


3.2. LINEAR FIRST ORDER DIFFERENTIAL EQUATIONS 29

(i) It shows that the initial value problem (3.7) has a solution.
(ii) Because it started with an unknown solution y(t) and arrived at the formula (3.10), it shows
that there is only one solution.
(iii) The formula (3.10) gives an explicit algorithm for solving the initial value problem: to find
y(t), one need only evaluate one definite integral.

A similar trick applies to the general case,


y 0 + p(t)y = f (t) ,
but with one change: the function ekt must be replaced by a more complicated expression and the
computations are messier.

Z t
9
Let P (t) = p(s) ds, and replace the “integrating factor” ekt by the function eP (t) . Then, as before
we can compute as follows
 0
eP (t) (y 0 (t) + p(t)y(t)) = eP (t) y(t) = eP (t) f (t) ,

which can be integrated to yield the formula


Z t
P (t)
e y(t) = eP (s) f (s) ds + C .

This, in turn, can be solve for y(t) to obtain the formula


y(t) = yp (t) + Cyh (t) , (3.11a)
where Z t Z t
yh (t) = e−P (t) , yp (t) = e−P (t) eP (s) f (s) ds , and P (t) = p(s) , ds. (3.11b)

The value of the constant C is determined from the initial condition y(t0 ) = y0 by solving the equation
y(t0 ) = yp (t0 ) + Cyh (t0 ) = y0
for C.
Remark 3.5. If f (t) = 0, then yp (t) = 0, and so y = Cyh (t) is the general solution of the homogeneous
differential equation y 0 + p(t)y = 0. The function yp (t) is called a particular solution of the nonhomo-
geneous differential equation, since it does not involve any arbitrary constants. The function yh (t) is a
particular solution of the homogeneous differential equation.

Our computation began with the assumption that a solution y(t) existed and then solved for y(t). This
showed (1) that there is a solution and (2) that every solution of the differential equation is of the
form (3.11a). Since the initial condition y(t0 ) = y0 is sufficient to determine the constant C, it follows
that there is only one solution to the initial value problem. The only assumption that made in the
computations was that the two integrals
Z t Z t
p(s) ds and eP (s) g(s) ds

made sense. This is certainly the case if p(t) and g(t) are continuous (or even piecewise continuous)
functions. The following theorem summarizes the above discussion.
Z t Z t
9The expression p(s) ds denotes a specific anti-derivative of p(t). For instance sds = t2 /2 rather than the
tdt = t2 /2 + C.
R
indefinite integral
30 SOLVING FIRST ORDER DIFFERENTIAL EQUATIONS

Theorem 1. Let p(t) and g(t) be continuous functions defined on the interval a < t < b and suppose
that a < t0 < b. Then there is one and only one solution of the initial value problem
y 0 + p(t) y = f (t) , y(t0 ) = y0 .

2
Example 3.8. Solve the initial value problem y 0 + 3ty = tet , y(2) = 5.

Solution First solve the homogeneous equation: y 0 + 3ty = 0. Since P (t) = 3t2 /2 is an anti-derivative
2
of 3t, the function yh (t) = e−3t /2 is a solution of the homogeneous equation. Next set
2
yp = h(t)y1 (t) = h(t)e−3t /2 and plug into the nonhomogeneous differential equation to get
2 2 2
h0 (t)e−3t /2
= tet or h0 (t) = te5t /2

2
Integration gives h(t) = 51 e5t /2
, so the general solution is
 
1 5t2 /2 2 1 2 2
y(t) = e + C e−3t /2 = et + Ce−3t /2 .
5 5
1 2 2
The initial condition y(2) = 5 then determines C: e(2) + Ce−3(2) /2 = 5. Thus,
5
e10
 
2 1 2 1 2 2
C = e3(2) /2 5 − e(2) = 5e6 − ≈ −2388 and y(t) ≈ et − 2388e−3t /2 .
5 5 5

Exercise 3.2. Solve each of the following first order differential equations and initial value problems.

dy
(a) + y = 5e−3x
dx
dy
(b) (1 + t2 ) + 2ty = t(1 + t2 ) , y(1) = 1
dt 2
(c) w0 − 2tw = et
dz
(d) + 3z = sin(6x).
dx
0
(e) y − 3y = e2t .
(f) y 0 + 3y = e2t .
(g) y 0 + 3y = t2 (Hint: Let yp (t) = at2 + bt + c and solve for a,b, and c.)
(h) (i) Find the general solution of the differential equation 2y 0 + y = 6.
(ii) Find the solutions that satisfy each of the following initial conditions:
y(0) = 0, y(0) = 6, and y(0) = 10.
(iii) Sketch the direction field for the differential equation along with the graphs of the three
solutions you found in part (b).
CHAPTER 4

Modeling with First Order Differential Equations

We now have a geometric picture of first order differential equations (the direction field), and we have
techniques for solving separable and linear differential equations. In this chapter, we study a few appli-
cations of the theory.

4.1. Linear Models

We begin with applications of first order linear differential equations.

4.1.1. Radioactive decay. Our first application is to the decay of radioactive elements, such as
Carbon-14 or Strontium-90.

Each radioactive element decays (into lighter elements) at a rate proportional to the quantity remaining.
Letting k > 0 denote the constant of proportionality. Assume that we start with a quantity Q0 (measured
in grams, say) at time t = 0 years Then the quantity Q(t) after t years is then the solution of the initial
value problem
dQ
= −kQ , Q(0) = Q0 .
dt
This is a linear differential equation with solution
Q(t) = Q0 e−kt .
Remark 4.1. Rather than specifying k directly, it is traditional to express it indirectly in term of the
half-life th , which is a more intuitive measure of the rate of decay than the parameter k: The half-life of
a radioactive element is the time required for half of the element to decay into other (lighter) elements.

The decay rate k can be computed from the half-life as follows. Let Q0 be the amount of radioactive
material at some time, set to t = 0, and let Q(t) denote the amount of a radioactive material remaining
t years later. Then, by definition, Q(th )/Q0 = 1/2. On the other hand, Q(th ) = Q0 e−kth .

1
Therefore, Q0 e−kth = Q0 . Canceling the term Q0 , taking the natural logarithm, and solving for k
2
yields the formula
ln(2)
k= . (4.1)
th
Example 4.1. Suppose that a certain quantity of an unknown radioactive substance is placed in a con-
tainer and that after 10 years the amount has decreased by 0.01%. What percent of the original quantity
will remain after 25 years? What is the half-life of this radioactive substances?
31
32 MODELING WITH FIRST ORDER DIFFERENTIAL EQUATIONS

Solution The decay rate k can be determined from the amount of radioactive substance remaining
after 10 years:

Q(10) = Q0 e−k10 = (1 − 0.0001)Q0 = 0.9999 Q0 =⇒ e−k10 = 0.9999 .

Taking the natural logarithm of both sides gives


1
−k(10) = ln(0.9999) =⇒ k = − ln(0.9999) ≈ 0.00001 .
10
Substituting this value of k into the formula for Q(t) yields the formula Q(t) = Q0 e−0.00001t . It remains
only to compute Q(25) as a percent of Q0 :

Q(25)
× 100% = 100e−(0.00001)25 ≈ 99.975% .
Q0

The half-life of the substance can be found by solving Equation (4.1) for th :

ln(2) ln(2)
th = = = 69315 years.
k 0.00001

Example 4.2. You find a frozen animal and you determine by experiment that the concentration of C 14
in it is 22% of the amount found in live animals. How old is the animal?

Solution The concentration of C 14 in live animals depends on the concentration of C 14 in the atmo-
sphere, and is roughly independent10 of time. When an animal dies, it stops adsorbing carbon from its
environment, and so the concentration of C 14 decreases as the C 14 decays into Nitrogen 14. This is the
key fact behind C 14 dating.

To compute the age of the animal, let Q(t) denote the amount of C 14 in the animal t years after its
death and let t = T denote the value of t when you determined the concentration of C 14 . Solving the
differential equation Q0 = −kQ, gives
Q(t) = Q0 e−kt ,
where Q0 is the amount of C 14 in the animal at the time of death. The half-life of C 14 is 5568 years, so

ln(2)
k= ≈ 0.0001245 .
5568
Because Q(T ) = 0.22Q0 and Q(t) = Q0 e−kt , it follows that

0.22Q0 = Q0 e−kT ,

which can be solved for T :


ln(0.22) ln(0.22)
T =− =− ≈ 12, 163 years.
k ln(2)/5568

10In fact, to obtain more accurate estimates of the age of artifacts, archaeologists make allowance for changes in the
concentration of C 14 in the atmosphere over time by incorporating tree-ring data into their calculation of Q0 .
4.1. LINEAR MODELS 33

4.1.2. Mixing Problems. A mixing problem involves a quantity of a substance dissolved in a fluid
(a liquid or a gas) in a container. Fluid with a known concentration of the substance enters the container
at a certain rate, and fluid exits the container a another rate. The goal is to find an expression for either
the quantity or the concentration of substance in the container as a function of time by modeling the
process as a first order initial value problem.
Example 4.3. Suppose that a tank with a capacity of 300 gallons initially contains 100 gallons of pure
water. A salt solution containing 3 pounds of salt per gallon is allowed to run into the tank at a rate of
8 gal/min, and the mixture is then removed at a rate of 6 gal/min, as shown in the figure below. The
process is continued until the tank is filled. Determine the concentration of the salt solution in the tank
at the end of the process.

Fluid In

Mixture

Fluid Out

Solution To make any progress, we need to label the various quantities that we need to keep track
of. Let Q(t) denote the quantity (in pounds) of salt in the tank at time t, measured in minutes, with
t = 0 at the beginning of the process. Let V (t) be the volume of solution in the tank at time t. Then
Q(t)
the concentration of salt in the container at time t is C(t) = .
V (t)

Salt both enters and leaves the tank are certain rates. Let Rin (t) denote the rate that salt enters the
tank and let Rout (t) denote the rate that salt leaves the tank. Then the net rate that salt accumulates
in the tank is the difference. Since the tank is initially full of pure water, Q(0) = 0. We can now model
the process as an initial value problem:
dQ
= Rin (t) − Rout (t) , Q(0) = 0 .
dt
We need to figure out formulas for Rin (t) and Rout (t). The salt solution enters the tank at 8 gallons a
minute at a concentration of 3 pounds per gallon, so
gal pounds pounds
Rin (t) = 8 ×3 = 24 .
min gal min
The solution exits the tank at a rate of 6 gallons per minute. So if C(t) is the concentration of salt in
the tank
Q(t)
Rout (t) = 6 C(t) = 6 ,
V (t)
provided the salt is mixed uniformly in the tank. This is the so-called well-mixing assumption , which
we will make. Thus, Q(t) is the solution of the initial value problem
dQ Q
= 24 − 6 , Q(0) = 0 .
dt V (t)
It’s nicer to write this in the form
dQ 6
+ Q = 24 , (Q(0) = 0 ,
dt V (t)
which makes it clearer that the differential equation is linear.
34 MODELING WITH FIRST ORDER DIFFERENTIAL EQUATIONS

To solve this initial value problem, we have to find the formula for V (t). But fluid enters the tank at 8
gal/min and leaves at 6 gal/min and V (0) = 100 gals, so V satisfies another initial value problem:
dV
= 8 − 6 = 2 and V (0) = 100 .
dt
So V (t) = 2t + 100, and we now know that Q satisfies the initial value problem
dQ 6
+ Q = 24 , (Q(0) = 0 ,
dt 2t + 100
which we can now solve to find the formula for Q(t).

The integrating factor for the differential equation is


Z t 
6ds
µ(t) = exp = exp(3 ln(50 + t)) = (50 + t)3 .
100 + 2s
Thus, Z
3
(50 + t) Q(t) = 24(50 + t)3 dt = 6(50 + t)4 + c .

Using initial condition Q(0) = 0 (initially, the water is pure), gives c = −6(50)4 . Solving for Q, yields
the formula  3
50
Q(t) = 6(50 + t) − 300 lbs.
50 + t
To find the time when the tank is full, solve the equation
V (t) = 100 + 2t = 300
for t to find that t = (300 − 100)/2 = 100 min. The concentration of the salt solution at end of the
filling procedure is, therefore,
Q(100) 6(150) − 300(50/150)3
C(100) = = lb/ gal = (80/27) lb/ gal ≈ 2.963 lb/ gal.
V (100) 300

4.1.3. Falling bodies. The case of a falling body where air resistance is taken into account is more
complicated than the simple case discussed in the introduction where the forces due to air resistance were
ignored. For slowly moving bodies, the force caused by moving through air (called drag) is proportional
to the speed of the object and points in the direction opposite the motion:
drag = −kv , k > 0 ,
where k is a positive constant called the drag coefficient. In this situation, Newton’s second law of motion
assumes the form
dv
m = −mg − kv
dt
or better
dv k
+ v = −g ,
dt m
a linear differential equation, which we can solve by the method of undetermined coefficients:
mg
v(t) = − + C e−(k/m)t .
k
The initial condition v(0) = v0 determines C:
mg mg
− + C = v0 =⇒ C = v0 + ,,
k k
so
mg  mg  −(k/m)t
v(t) = − + v0 + e .
k k
4.1. LINEAR MODELS 35

As the speed increases, so does the drag. At a certain velocity the force of gravity will exactly cancel
with the drag. This velocity is called the terminal velocity:
v∞ = lim v(t) .
t→∞
To find v∞ , solve the equation −mg − kv∞ = 0 for v∞ to obtain the formula
mg
v∞ = − .
k
We can gain further insight into this by sketching the direction field (shown below for the differential
equation
dv
= −g − (k/m)v .
dt

v
t

v∞

Integrating the formula for v(t) yields an expression for y(t):


mg m mg  −kt/m
y(t) = − t− v0 + e +C.
k k k
The initial condition y(0) = y0 determines C:
m  gm 
C= + v 0 + y0 ,
k k
giving rise to the formula
mg m mg  −(k/m)t m  mg 
y(t) = − t− v0 + e + + v0 + y0 ,
k k k k k
which simplifies to
m gm2 
 
mg 
y(t) = y0 − t + v0 + 2 1 − e−(k/m)t ,
k k k
where y0 and v0 are the position and velocity, respectively, of the particle at time t = 0.
Remark 4.2. In the special case v0 = 0, the formulas for v(t) and y(t) simplify further to
mg   m2 g  
v(t) = − 1 − e−(k/m)t and y(t) = y0 + 2 1 − e−(k/m)t
k k
This can be thought of as a modification of the formulas
1
v(t) = −gt and y(t) = y0 − gt2
2
for free fall without air resistance. This can be seen by substituting the approximation,
k k k2 2 k3 3
e− m t ≈ 1 − t+ 2
t − t
m 2m 6m3
(which is valid for (k/m)t small) into the formulas for v(t) and y(t) when we included air resistance.
After some algebra, we obtain the approximate formulas
kg 2 1 kg 3
v(t) ≈ −gt + t and y(t) ≈ y0 − gt2 + t .
2m 2 6m
For k = 0, these formulas reduce to the formulas for v(t) and y(t) with no air resistance.
36 MODELING WITH FIRST ORDER DIFFERENTIAL EQUATIONS

Example 4.4. Suppose that a bag weighing 120 lb and having a coefficient of air resistance of 1 lb-sec/ft
falls out of an airplane. How close to the terminal velocity will it be after 30 seconds? How many feet
will the bag have fallen at that time?

0
v(t) = 120(1 e 0.2557t) y(t) = 120 + 450(1 e 0.2557t)
25 v(t) = 32t 0 y(t) = 16t 2
50
v (ft/sec)

1000

y (ft)
75
100 2000
125 3000
150
0 5 10 15 20 25 30 0 10 20 30 40
t (sec) t (sec)
Figure 4.1. Free fall with air resistance taken into account. The velocity asymp-
totically approaches a constant v(t) ≈ −120 ft/sec, and the height approaches a linear
function y(t) ≈ −120t + 450.

Solution For convenience, set y = 0 at the height of the airplane, so that −y(t) is the distance the
bag has fallen. The mass of the bag is
120
m= slugs = 3.75 slugs
32
The terminal velocity is, therefore,
mg
v∞ = −= −120 ft/ sec .
k
Substitution of these numerical values into the formulas for v(t) and y(t) gives
v(t) = −120(1 − e−0.2667t ) and y(t) = − (120) t + 450(1 − e−(0.2667t )
The following table shows the difference between free fall with and without air resistance:

no air air no air air


t v v y y
(sec) (ft/sec) (ft/sec) (ft) (ft)
0 0.0 0.0 0.0 0.0
1 -32.0 -28.1 -16.0 -14.67
2 -64 -49.6 -144.0 -112.2
5 -160.0 -88.4 -400.0 -268.6
10 -320.0 -111.7 -1600.0 -781.3
20 -640.0 -119.4 -6400.0 -1952.2
30 -960.0 -119.96 -14,400.0 -3150.2

After 30 seconds, the velocity will be −119.96 feet/sec, almost indistinguishable from the terminal
velocity; and the bag will have fallen 3150.2 feet.
4.1. LINEAR MODELS 37

4.1.4. Newton’s Law of Cooling. Newton’s law of cooling states that if an object is brought into
an environment, then the rate of cooling is proportional to the difference between the temperature of the
object and the temperature of the environment (the ambient temperature). This law can be reformulated
as an initial value problem as follows.

Let
T (t) = temperature of the object at time t,
T (0) =T0 = initial temperature of the object,
TA (t) = ambient temperature.
Then Newton’s law of cooling takes the form:
dT
= −k (T − TA (t)) , T (0) = T0 , (4.2)
dt
where k > 0 is the constant of proportionality, which depends on the thermal properties of the object.

The differential equation (4.2) can we written in the form


dT
+ kT = kTA (t)
dt
of a linear differential equation. Therefore, it can be solved by the method of integrating factors.
Remark 4.3. Newton’s law of cooling is only a rough model of how objects cool. It assumes that the
temperature of the object is the same at all points in the object. In most cases, this is not the case and
a more complex model, involving partial differential equations is needed.
Example 4.5. A cup of coffee at 200◦ F is brought out into a room that is kept at 60◦ F. Two minutes
later you measure the coffee’s temperature to be 180◦ . Find a formula for the coffee’s temperature at any
time t.

Solution Substituting T (0) = 200 and TA = 60 into Equation (??) gives rise to the equation
 
T − 60
ln = −kt .
200 − 60
To find k, substitute the values t = 2 and T = 180 in this formula to find
   
180 − 60 120 1 1
ln = ln = −2k =⇒ k = − ln(6/7) = ln(7/6) ≈ 0.077
200 − 60 140 2 2
Consequently,
T (t) ≈ 60 + 140e−0.077t .

Let’s consider a more complicated application of Newton’s Law of Cooling, where separation of variables
does not apply.
Example 4.6. Let t be time in hours (with t = 0 at noon on Jan 1. Suppose further that during a
◦ ◦
particularly cold month of January, the outside
 temperature in Seattle varies between −10 C and 10 C

according to the formula TA (t) = 10 cos t . Let T (t) be the temperature (in degrees C) inside a
24
container that was left outside. Then according to Newton’s law of cooling, the temperature inside the
container satisfies the differential equation11
dT dT
= −k (T − TA (t)) or + kT = kTA (t) ,
dt dt
11Because T (t) is the temperature around the container, it’s the ambient temperature or the temperature of the
A
environment around the container. That’s why I chose to use the symbol TA —”A” for “ambient.”
38 MODELING WITH FIRST ORDER DIFFERENTIAL EQUATIONS

where k is a measure of how well the container is insulated. Suppose further that T (0) = 0. Find a
formula for T (t). Next, find the largest value of k so that for large values of t, T (t) will stay between
−2◦ C and 2◦ C.

Solution To simplify the computations, set ω = π/12 and write the differential equation in the form
T 0 + kT = 10k cos (ωt) .
The function T (t) = A cos(ωt) + B sin(ωt) + Ce−kt is a solution for appropriate values of A,B, and C.
To see this, substitute T (t) into the differential equation and compute as follows:
T 0 (t) + kT (t) = ω {−A sin(ωt) + B cos(ωt)} + k {A cos(ωt) + B sin(ωt)}
= (kB − ωA) sin(ωt) + (ωB + kA) cos(ωt) = 10k cos(ωt)
For equality to hold, A and B must satisfy the equations
kB − ωA = 0 and ωB + kA = 10k .
Solving for A and B gives
10k 2 10ωk
A= and B = 2 .
k2 + ω2 k + ω2
Hence,
10k 2 10ωk
T (t) = 2 2
cos(ωt) + 2 sin(ωt) + Ce−kt .
k +ω k + ω2
Since T (0) = 0, it follows that that k210k
+ω 2 + C = 0, so

10k 2
C=− .
k2 + ω2
But it isn’t clear what the solution looks like! To obtain a better formula for T (t), employ the “phase-
shift” formula from Appendix A: Notice that
10k 2
  
10ωk 10k k ω
cos(ωt) + 2 sin(ωt) = √ √ cos(ωt) + √ sin(ωt)
k2 + ω2 k + ω2 k2 + ω2 k2 + ω2 k2 + ω2
π

Setting φ = − arctan(B/A) = arctan(ω/k) = − arctan 12k gives the formula
10k 2 −kt
 
10k
T (t) = √ cos(ωt + φ) − 2 e .
k2 + ω2 k + ω2
To determine the value of k, notice that “in the long run” (i.e. for t large) Ce−kt ≈ 0. Ignoring the
exponential term gives the approximation
 
10k
T (t) ≈ √ cos(ωt + φ) .
k2 + ω2
Because the exponential term vanishes quickly, it is called a transient; and remaining periodic term is
called the the steady state solution of the differential equation. Thus, for t large, T (t) is approximately
10k
a shifted “sine-wave” of amplitude √ , and T (t) will stay within 2◦ C of 0◦ C provided that we
k2 + ω2
choose k to satisfy the inequality
10k
√ ≤ 2.
k2 + ω2
Clearly, the maximum value of k is a solution of the equation √k10k 2 +ω 2
= 2. Squaring and clearing
denominators gives
r
2 2 2 2 2 4 π
100k = 4(k + ω ) =⇒ 96k = 4ω =⇒ k= ω = √ ≈ 0.0534
96 24 6
4.2. THE LOGISTIC EQUATION 39

Temperature ( C)
0

T = T(t)
transient
2 steady state solution
0 12 24 36
t (hours)
Figure 4.2. The graphs of the actual solution T (t) when k = 0.0534, together with
the transient Ce−kt and the steady state solution.

4.2. The Logistic Equation

The logistic differential equation is the autonomous differential equation

dy  y
=a 1− y, (4.3)
dt b
where a and b are positive constants. The logistic equation has applications to several disciplines, in-
cluding ecology, epidemiology, and medicine; and it’s solution occurs numerous other areas, including
machine learning, physics, and chemistry. After discussing its stability properties, we compute its solu-
tion and applications to epidemiology and population growth (where the logistic equation first appeared).

y=b-

y = 0-

dy
Figure 4.3. The direction field of the Logistic Equation differential equation =
dt
 y 
a 1− y. The fixed point y = 0 is unstable; the fixed point y = b is stable. The
b
graph of the solution of the logistic equation is shown in blue.
40 MODELING WITH FIRST ORDER DIFFERENTIAL EQUATIONS

As illustrated in Figure 4.3, the logistic equation has exactly two fixed points: an unstable fixed point at
y = 0 and a stable fixed point at y = b. It follows that for all y0 > 0, no matter how small, the solution
of the initial value problem
dy  y
=a 1− y , y(0) = y0
dt b
has limiting value lim y(t) = b.
t→∞

We can obtain a formula for the solution of the logistic equation using separation of variables:
Z Z
dy
= adt .
(1 − y/b)y
The left hand side can be integrated by partial fractions:
  Z Z Z
1 1 1 dy dy dy
= + =⇒ = +
(1 − y/b)y b−y y y(1 − y/b) b−y y
So Z Z Z
dy dy dy y
= + = − ln |b − y| + ln |y| + C = ln
+C
y(1 − y/b) b−y y b − y

y
= at + C =⇒ y = eat+C =⇒ y
= Aeat . where A = ±eC . Solving for y

Thus ln
b−y b−y b−y
yields an explicit formula for y(t):
b
y(t) = . (4.4)
1 + e−at /A
This function is called the logistic function. Its graph is the “S”-shaped curve sketched in Figure 4.3,
called the logistic curve.

Example 4.7. (Epidemics) As a first application of the logistic equation, we return to Example 1.3
modeling epidemics, which you should review before continuing.

The model the population is divided into two sub-populations:


x = the proportion susceptible to infection (“well”)
y = the proportion infected (“sick”)
so x + y = 1. The only meaningful values of x and y are those between 0 and 1, so only the region
0 ≤ y ≤ 1 in Figure ?? has any meaning.

If y(0) = y0 is the fraction of the total population that is initially infected, the spread of the epidemic
was modeled by the initial value problem
dy
= α (1 − y)y , y(0) = y0 .
dt
This is the logistic equation with a = α and b = 1, which we have just solved. We now have an explicit
formula to the portion of infected people at time t days after the start of the epidemic:
1
y(t) = .
1− e−αt /A
1 y0
From y(0) = y0 we find that y0 = , or A = . Substituting this into the formula for y(t)
1 − 1/A y0 − 1
gives
1 y0
y(t) = (y0 −1)e−αt
= .
1− y0 − (y0 − 1)e−αt
y0
4.2. THE LOGISTIC EQUATION 41

We can explicitly compute lim y(t) as follows:


t→∞
y0 y0
lim y(t) = lim − = 1,
t→∞ t→∞ y0 − (y0 − 1)e−αt y0
which we already knew based on our stability analysis. Thus, (under the assumptions of the model)
everyone will eventually become infected, even if initially only a small proportion of the population is
infected.
Example 4.8. (The Logistic Equation for Population Growth) The logistic equation first
appeared in 1838 in a paper by Pierre Verhulst, as a model of growth of population with limited resources.
The most naive model of population growth is given by the differential equation
dP
= rP ,
dt
where P denotes the size of a population of some organism, usually measured either by total biomass or
(for large numbers) by number of individuals. The solution
P (t) = P0 ert
is clearly unrealistic because it predicts arbitrarily large values of P as t gets large. Verhulst introduced
the logistic equation as the simplest model that takes limited resources into account.

In the late 1920’s Raymond Pearl analyzed data collected by to determine how well the logistic equation
predicted the population growth of yeast.12 In Carlson’s experiments, a small number of yeast cells were
placed into a jar containing sugar, and the approximate number of yeast cells were counted each hour.
Here is some of the data from the experiment:

t= 0 1 2 3 4 5 6 7 8 9
Y (t) = 10 18 19 47 71 119 175 257 351 441
t= 10 11 12 13 14 15 16 17 18
Y (t) = 513 560 595 629 641 651 656 660 661
Pearl conjectured that the number of yeast Y (t) after t hours obeyed a differential equation of the form
1 dY
= R(Y ) ,
Y dt
where R(Y ) is a function involving only the number of yeast. The left hand side is called the “fractional
rate of growth” (or the logarithmic growth rate). The right hand side is called the reproduction function.
The object of Pearl’s analysis was to determine R(Y ).

At any t, the derivative can be approximated by a “difference quotient” ∆Y /∆t. A better estimate can
be obtained by averaging successive quotients. For example, Y 0 (5) can be estimated by
 
1 Y (6) − Y (5) Y (5) − Y (4) Y (6) − Y (4)
Y 0 (5) ≈ + = .
2 1 1 2
The logarithmic growth rate is then
1 dY (5) 175 − 71
≈ = 0.437 .
Y (5) dt 2 · 119
Applying this approach to the data in the table above, and fitting a straight line to the data (see figure
below) gives the formula  
Y
R(Y ) = 0.53 − 0.00079Y = 0.53 1 −
671

12“The growth of populations” , Raymond Pearl, Quarterly Review of Biology, 2 (1927) 532–548.
42 MODELING WITH FIRST ORDER DIFFERENTIAL EQUATIONS

1.0
Carlson's data
0.8 R(Y) = 0.53(1 Y/671)
0.6

R(Y)
0.4
0.2
0.0
0 200 400 600 800
Y
1 dY
Figure 4.4. Carlson’s data (horizontal axis: Y , vertical axis: approximation of Y dt ),
together with best fitting line.

Given the initial population Y (0) = 10 yeast buds, the yeast population for t > 0, can be predicted by
solving the initial value problem
 
dY Y
= 0.53 1 − Y , Y (0) = 10 ,
dt 671
which is a special case of the logistic equation with a = 0.53 and b = 671. Figure 4.5 illustrates the
excellent agreement between Carslon’s data and the solution of the initial value problem.

800
logistic curve
Carlson's data
600
Y (num yeast)

400

200

0
0 5 10 15 20
t (hours)

Figure 4.5. Logistic curve fitted to the growth of the yeast. The data is from a 1927
experiment by G.F. Gause.

A number of conclusions can be drawn from this model:

(i) For Y is small, R(Y ) ≈ r = 0.53 (intrinsic rate of growth) Y (t) ≈ Y0 ert for Y small.
(ii) For Y > 671, R(Y ) is negative and the population decreases with time. The parameter b = 671
is called the carrying capacity of the environment.
(iii) For any initial value of Y , lim Y (t) = b ≈ 671.
t→∞

The book by G. Evelyn Hutchinson, An Introduction to Population Ecology, New Haven and London,
Yale University Press, 1978, pages 23–32, presents data suggesting that many animal and plant popula-
tions obey the logistic model of growth.
4.3. THE HARMONIC OSCILLATOR AND CONSERVATION OF ENERGY 43

4.3. The Harmonic Oscillator and Conservation of Energy

The harmonic oscillator discussed in Example 1.2 consists of an object of mass m attached to a spring
and free to move to the right and left without friction. If x denotes the amount the spring has stretched
relative to its equilibrium position, then by Hooke’s law (see Figure 1.1) the force on the object is −kx;
and Newton’s second law “F = ma” takes the form
d2 x
m = −kx . (4.5)
dt2

This differential equation is among the most important ones in physics and engineering, and it will play
a central role in this course. Some physicists would claim that it is the most important differential
equation in all of physics!

In any case, it’s worth studying. Equation (4.5) is a second order differential equation. Beginning in
Chapter 6, we will introduce techniques to solving second order differential equations directly, and in
Chapter 8 we will study the harmonic oscillator using those techniques. In this section, we view the
harmonic oscillator from a different perspective, using the principle of conservation of energy.

The first step is rewrite (4.5) in terms of velocity. Remember that both x and v are functions of t (time),
that is x = x(t) and v = v(t). (We can’t say more since we don’t yet know the formulae for x(t) and
dx(t) d2 x dv(t)
v(t).) Remember also that v(t) = . So 2 = , and we can therefore write (4.5) this way:
dt dt dt
dv(t)
m + kx(t) = 0 .
dt
dx(t)
Now comes a trick: Multiply by v(t) = dt to get
dv(t) dx(t)
mv(t) + kx(t) = 0.
dt dt
The terms on the left can we rewritten in a nicer form:
   
dv(t) d 1 2 dx(t) d 1 2
mv(t) = mv(t) and mx(t) = kx(t) .
dt dt 2 dt dt 2
Using this shows that v(t) and x(t) satisfy the identity
 
d 1 1
mv(t)2 + kx(t)2 = 0 .
dt 2 2
It follows that the quantity between the parentheses is constant:
1 1
mv 2 + kx2 = E , (4.6)
2 2
where E is some positive constant. If you took high school physics, you know that 12 mv 2 is the kinetic
1
energy of the mass. And if you took Math 125 and studied “work” you know that kx2 is the energy
2
stored in the spring, called the potential energy. So Equation (4.6) says that the sum of the kinetic
energy and the potential energy is constant. We have discovered a special case of the law of conservation
of energy!

Figure 4.6) gives a nice way to visualize how (x(t), v(t))are related: they trace out an ellipse in the
(x, v)-plane.
44 MODELING WITH FIRST ORDER DIFFERENTIAL EQUATIONS

v 1 1
mv 2 + kx2 = E
2 2

Figure 4.6. Conservation of energy states that curve (x(t), v(t)) in the (x, v)-plane
is an ellipse.

dx
But more is true! Remember that v = . So we can write (4.6) this way:
dt
 2
dx
m + kx2 = 2E .
dt
This is a first order differential equation that is satisfied by x = x(t). We have succeeded in turning a
second order differential equation into a first order differential equation, which we can try to solve by
separation of variables:
√ p
r
√ dx p 1 dx k
m = ± 2E − kx2 = ± k 2E/k − x2 =⇒ p =± .
dt 2E/k − x2 dt m
Integration yields r ! r
−1 k k
sin x =± t + φ,
2E m
where φ is a constant of integration. Solving for x yields the equation
r r !
2E k
x(t) = sin ± t+φ .
k m
r
k
So x(t) is a sine function with frequency ω0 = .
m
Remark 4.4. At this point, you should compare what we just found with Example 1.2 in the Introduc-
tion.
4.3. THE HARMONIC OSCILLATOR AND CONSERVATION OF ENERGY 45

Exercise 4.1. Suppose that the population of a certain species grows at the instantaneous rate of 2%
per year (i.e., its instantaneous rate of increase in number of individuals per year is 2% of the population
at the moment). Let y(t) stand for the population after t years.

(a) Write a differential equation for y(t).


(b) Write the general solution to the differential equation you found in part (a).
(c) If the present population is 1,000,000, what will the population be in 1 year? In 20 years? How
long will the population take to double?
Exercise 4.2. Assume that the population of the Earth changes at an instantaneous rate proportional
to the population. Assume further that at time t = 0 (1650 CE) its population was 250 million and at
time t = 300 (1950 CE) its population was 2.5 billion. Find an expression giving the population of the
Earth at any time. If the greatest population that the Earth can support is 25 billion when will this
limit be reached?
Exercise 4.3. At time t = 0 you buy a house, using a fixed-rate, fixed payment mortgage to pay for
most of it. Let y(t) be the amount you owe after t years. Thus, y(0) = y0 is the cost of the house minus
the down-payment.

(a) Write the differential equation for the amount y(t) you owe after t years.
(b) Solve the differential equation to find a formula for y(t)
(c) Suppose that the bank will give you a 30-year mortgage at 4% interest, but they only consider
you an acceptable credit risk if your monthly payments do not exceed one fourth of your $2,500
monthly salary. Compute the maximum mortgage they’ll give you.
Exercise 4.4. Newton’s law of cooling also applies when a colder object heats up in a warmer environ-
ment. Suppose water at 55◦ F is pumped into a swimming pool on a 90◦ summer day. After 2 hours the
temperature of the water is 60◦ . In how many hours (assuming the outside temperature remains 90◦ )
will the water reach a comfortable swimming temperature of 70◦ ?
Exercise 4.5. Consider a tank used in certain hydrodynamic experiments. After one experiment the
tank contains 200 gal of a dye solution with a concentration of 1 gm/gal. To prepare for the next
experiment, the tank is to be rinsed with fresh water flowing in at a rate of 2 gal/min, the well- stirred
solution flowing out at the same rate.

(a) Write a differential equation for y, the amount of dye in the tank after t minutes.
(b) Find y(t).
(c) What is the “half-life of y(t)?
(d) How much time elapses before the concentration of dye in the tank reaches 1% of its original
value?
Exercise 4.6. Suppose that a room containing 1200 cubic feet of air is originally free of carbon monoxide.
Beginning at time t = 0 cigarette smoke containing 4 percent carbon monoxide is introduced into the
room at a rate of 0.1ft3 /min and the well-circulated mixture is allowed to leave the room at the same
rate.

(a) Find an expression for the concentration of carbon monoxide in the room at any time t > 0.
(b) Extended exposure to a carbon monoxide concentration as low as 0.00012 (i.e. 0.012%) is
harmful to the human body. Find the time at which this concentration is reached.
Exercise 4.7. Unlike the case of an object moving at very low speeds, at higher speeds, the drag on an
object traveling in the atmosphere is proportional to the square of the speed. Suppose that such a jet
powered car is initially travelling in a straight line at 500 miles per hour when it’s engine stops; and 30
seconds later it is traveling at 200 miles per hour.
46 MODELING WITH FIRST ORDER DIFFERENTIAL EQUATIONS

(a) Write down the appropriate initial value problem and solve it.
(b) How fast is the projectile traveling after one minute?
(c) How far will it travel in the first minute?
 
dP P
Exercise 4.8. Consider the logistic population model = 2 1− P for a species of fish in a
dt 1000
lake, were t is measured in years and P (t) is the number of fish in the lake at time t. Suppose that it
is decided that fishing will be allowed in the lake, but it is unclear how many fishing licenses should be
issued. Suppose the average catch of a fisherman with a license is 5 fish per year.

(a) What is the largest number of licenses that can be issued if the fish are to have a chance to
survive in the lake?
(b) Suppose the number of fishing licenses in part (a) are issued. What will happen to the fish
population—that is, how does the behavior of the population depend on the initial population?
(c) The simple population model above can be thought of as a model of an ideal fish population
that is not subject to many of the environmental problems of an actual lake. For the actual fish
population, there will be occasional changes in the population that were not considered in the
building of the model. If the water level were high because of a heavy rainstorm, a few extra
fish might be able to swim down a usually dry stream bed to reach the lake; or the extra water
might wash toxic waste into the lake, killing a few fish. Given the possibility of unexpected
perturbation of the population, not included in the model, what do you think will happen to
the actual fish population if we fix the fishing level at the one determined in part (b)?
Exercise 4.9. Exercise 1.1 involved a boater and a motor boat, which together weighed 640 lbs. The
thrust of the motor was equal to a constant force of 20 lb. in the direction of motion, and the resistance
of the water to the motion was assumed to be equal numerically to twice the speed in feet per second.
The boat was initially at rest. (a) Under those assumptions, solve the differential equation you found in
1.1 to find the formula for the velocity v(t) of the boat at time t. (b) What is the limiting velocity?

y 6

y 0 = F (y)
0
y-

Figure 4.7. Flipping the graph of F (y) along the diagonal and aligning it with the
direction field illustrates the relation between the graph of F (y) and the direction field
of the differential equation.
Exercise 4.10. Consider the differential equation y 0 = F (y) where the graph of F (y) is shown in
Figure 4.7 Locate the equilibrium points in Figure 4.7 and determine which ones are stable and which
ones are not stable. It may help to sketch a few solution curves.
Part 2

Second Order Differential Equations


CHAPTER 5

Complex Numbers

Complex numbers are routinely used in electrical, mechanical, and aeronautical engineering applications,
as well as in physical chemistry, and almost all areas of physics. In particular, the techniques we are
going to introduce for solving linear second order differential equations depend on a good understanding
of complex numbers. In this chapter, we present only the relevant parts of complex arithmetic and
complex calculus that we need.

5.1. Complex Numbers

A complex number z is given by a pair of real numbers x and y and is written in the form13 z = x + yi,
where i satisfies i2 = −1. 14 If z = x + yi, then the term x is called the real part of z and written
x = Re z. The term y is called the imaginary part of z and written y = Im z. Thus,
Re (4 + 5i) = 4 and Im (4 + 5i) = 5 .
Remember: Im z is a real number!

Complex numbers are added in a natural way: If z1 = x1 + y1 i and z2 = x2 + y2 i, then


z1 + z2 = (x1 + x2 ) + (y1 + y2 )i (5.1)
For example, (4 + i) + (2 + 3i) = (6 + 4i). Complex numbers are also multiplied in a natural way:
z1 z2 = (x1 x2 − y1 y2 ) + (x1 y2 + x2 y1 )i (5.2)

Note that the product behaves exactly like the product of any two algebraic expressions, keeping in mind
that i2 = −1. Thus,
(2 + i)(−2 + 4i) = 2(−2) + 8i − 2i + 4i2 = −8 + 6i .

There is only one way to satisfy the equality z1 = z2 , namely, if x1 = x2 and y1 = y2 . An equivalent
statement (one that is important to keep in mind) is that z = 0 if and only if Re z = 0 and Im z = 0. If
a is a real number and z = x + iy is complex, then az = ax + iay (which is exactly what one would get
from the multiplication rule above if z2 were of the form z2 = a + i0).

Division is more complicated. To find z1 /z2 it suffices to find 1/z2 and then multiply by z1 . The rule
for finding the reciprocal of z = x + yi is given by:
1 1 x − yi x − yi x − yi
= · = = 2 (5.3)
x + yi x + yi x − yi (x + yi)(x − yi) x + y2
13At times, it is more convenient to write z = x + iy, rather than z = x + yi. Both forms are used in these notes.
14Electrical engineers (who make heavy use of complex numbers) reserve the letter i to denote electric current and

they use j for −1.

49
50 COMPLEX NUMBERS

For instance,
1 3 − 4i 3 4
= = − i.
3 + 4i 25 25 25
Using the formula for the product of complex numbers gives
 
3 4 9 + 16 (3)(−4) + 4(3)
(3 + 4i) − i = + = 1 + 0i = 1 ,
25 25 25 25
as one would expect!

The expression x − iy appears so often and is so useful that it is given a name. It is called the complex
conjugate of z = x + iy and a shorthand notation for it is z; that is, if z = x + iy, then z = x − iy. For
example, 3 + 4i = 3 − 4i, as illustrated in Figure 5.1(a). Note that z = z and z1 + z2 = z 1 + z 2 . Exercise
(3b) is to show that z1 z2 = z 1 z 2 .

Another important quantity associated with a given complex number z is its modulus
p 1/2
|z| = (zz)1/2 = x2 + y 2 = (Re z)2 + (Im z)2
√ √
Note that |z| is a real number. For example, |3 + 4i| = 32 + 42 = 25 = 5.

The modulus of a complex number is a generalization of the notion of the absolute value of a real number,
as the following example illustrates:
| − 3| = |(−3) + 0i| = ((−3)2 + (0)2 )1/2 = (9)1/2 = 3 .

5.2. The Complex Plane

The complex numbers, as well as various operations involving complex numbers have elegant geometric
descriptions. The complex numbers may be represented as points in the plane (sometimes called the
Argand diagram) or as vectors. The real number 1 is represented by the point (1, 0), and the complex
number i is represented by the point (0, 1). The x-axis is called the “real axis”, and the y-axis is called
the “imaginary axis”.

Complex conjugation is given by reflection about the real axis, as illustrated in Figure 5.1(a). Addition
of complex numbers is given by the parallelogram rule, as illustrated in Figure 5.1(b).

The geometric description of multiplication involves both a rotation and a stretch. As illustrated in
Figure 5.2, to visualize the product z1 z2 , construct a triangle with vertices 0, 1 and z1 (red triangle
at left of figure). Then construct a similar triangle where the ”base” edge from 0 to 1 is replaced by
the segment from 0 to z2 (red triangle at right of figure). Then the vertex opposite the base is the
product z1 z2 . By high school geometry, one can show that the coordinates of the product are given by
Equation (5.2).

Exercise 5.1.

 
x − iy
(1) Compute the product (x + iy) ,.
x2 + y 2
(2) Write each of the following in the form a + bi:
√ √ 1 + 2i 2 − i
(a) ( 2 − i) − i(1 − 2i) (b) +
3 − 4i 5i
5.2. THE COMPLEX PLANE 51

(a) (b)
r 3 + 4i 2 + 3i :r 6 + 4i

r 
3

7  







:r
4 + i

 
 


S
S
S
S
wr 3 − 4i
S

Figure 5.1. (a) The complex numbers 3 − 4i and 3 + 4i are complex conjugates of
one another. (b) The complex number 6 + 4i is the sum of 2 + 3i and 4 + i.

z1
z2 z1 z2 z2

θ1 + θ2
θ1
θ2

Figure 5.2. Geometric description of complex multiplication. The red triangles in


the figure are similar, with “bases” of lengths 1 and |z2 |, respectively. By high school
geometry, one can show that |z1 z2 | = |z1 |z2 |. The angle that the product z1 z2 makes
with the positive real axis is the sum of the angles that z1 and z2 make with the positive
real axis.

5
(c) (d) (1 − i)4
(1 − i)(2 − i)(3 − i)
(3) Prove the following:
(a) z + z = 2Re z and z is a real number if and only if z = z.
(b) z1 z2 = z 1 z 2 .
(4) Prove that |z1 z2 | = |z1 ||z2 | (Hint: Use (3b).)
(5) Find all complex numbers z = x + iy such that z 2 = 1 + i.
52 COMPLEX NUMBERS

5.3. Polar Representation of Complex Numbers

Points in the plane can be represented by both rectangular and polar coordinates. The relation between
the rectangular coordinates (x, y) and the polar coordinates (r, θ) is
x = r cos(θ) and y = r sin(θ)
p y
r = x2 + y 2 and tan(θ) =
x
Thus, (See Figure 5.3) the complex number z = x + iy can we written in the form:
z = r (cos(θ) + i sin(θ)) = reiθ , (Polar Representation), (5.4)
where p y
r= x2 + y 2 = |z| and tan(θ) = . (5.5)
x
The angle θ is called the argument of the complex number z. It is often denoted by arg(z).
p
Example 5.1. The complex number z = 8 + 6i may also be written as reiθ , where r = 82 + 62 = 10
and θ = arg(8 + 6i) = arctan(6/8) ≈ 0.64 radians.
Remark 5.1. In formula (5.4), we are defining eiθ to be cos(θ) + i sin(θ). We justify this definition later
in these notes.
Remark 5.2. (Caution) There is ambiguity in equation (5.5) about the inverse tangent, which can (and
must) be resolved by looking at the signs of x and y, respectively, in order to determine the quadrant
in which θ lies. If x > 0, then θ = arctan(y/x). If x < 0, then θ = arctan(y/x) ∓ π, depending on the
sign of y. When x = 0, then θ = ±π/2, depending on the sign of y. (If z = 0, then r = 0 and θ can be
anything.)

If x = 0, then the formula for θ makes no sense, but x = 0 simply means that z lies on the imaginary
axis and so θ must be π/2 or 3π/2 (depending on whether y is positive or negative).

x
p
Figure 5.3. The Polar Representation: x + yi = reiθ , where r = x2 + y 2 and
tan(θ) = y/x.
Remark 5.3. The conditions for equality of two complex numbers using polar coordinates are not quite
as simple as they were for rectangular coordinates. If z1 = r1 eiθ1 and z2 = r2 eiθ2 , then z1 = z2 if and
only if r1 = r2 and θ1 = θ2 + 2πk, k = 0, ±1, ±2, . . . .
Example 5.2. For instance, i = eiπ/2 = ei5π/2 , −1 = eπi = e3πi , and + 1 = e0i = e(0+2π)i = e2πi .
√ √ √
Example 5.3. If z = −4 + 4i, then r = 42 + 42 = 4 2 and θ = 3π/4, therefore z = 4 2e3πi/4 . Any
angle that differs from 3π/4 by an
√ integer multiple
√ of 2π will give us the same complex number. Thus,
−4 + 4i can also be written as 4 2e11πi/4 or as 4 2e−5πi/4 .
5.4. COMPLEX-VALUED FUNCTIONS 53

z3 = z1 z2 = 10eiθ3 y
6

√ 5
z2 = 20eiθ2
4

2 √
z1 = 5eiθ1
1
x
-8 -6 -4 -2 2

Figure 5.4. Complex multiplication in polar form.

As illustrated in Figure 5.2, complex multiplication involves both a stretch and a rotation. The polar
representation gives another way to describe of complex multiplication:

if z1 = r1 eiθ1 and z2 = r2 eiθ2 , then z1 z2 = r1 r2 ei(θ1 +θ2 ) . (5.6)

For example, let


√ √
z1 = 2 + i = 5eiθ1 , θ1 ≈ 0.464 and z2 = −2 + 4i = 20eiθ2 , θ2 ≈ 2.034

Then z3 = z1 z2 , where z3 = −8 + 6i = 100eiθ3 θ3 ≈ 2.498. (see Figure 5.4)

Exercise 5.2.

(1) Let z1 = 3i and z2 = 2 − 2i


(a) Plot the points z1 , z2 , z1 + z2 , z1 − z2 and z2 .
(b) Compute |z1 + z2 | and |z1 − z2 |.
(c) Express z1 and z2 in polar form.
(2) Let z1 = 6eiπ/3 and z2 = 2e−iπ/6 . Plot z1 , z2 , z1 z2 and z1 /z2 .
(3) Let z = reiθ . Show that z = re−iθ and z −1 = r−1 e−iθ .

5.4. Complex-valued Functions

Now suppose that w = w(t) is a complex-valued function of the real variable t. That is

w(t) = u(t) + iv(t) ,

where u(t) and v(t) are real-valued functions. A complex-valued function can be thought of a defining
a curve in the complex plane. The derivative of w(t) with respect to t is defined to be the function

dw(t)
w0 (t) = u0 (t) + iv 0 (t) =
dt
(This is just like the definition of the derivative of a vector-valued function—just differentiate the com-
ponents.) The derivative w0 (t) can be thought of as the tangent to that curve w(t).
54 COMPLEX NUMBERS

It is easily checked (just expand the left and right hand sides of each identity) that, just as in the case of
real-valued functions, the following formulas hold for complex-valued functions z = z(t) and w = w(t):
C 0 = 0 , where C = constant (5.7a)
0 0
(Cz) = Cz , where C = constant (5.7b)
0 0 0
(z + w) = z + w (the sum rule) (5.7c)
0 0 0
(zw) = z w + zw (the product rule) (5.7d)
 z 0 z 0 w − zw0
= (the quotient rule) (5.7e)
w w2
In other words, the derivatives of complex-valued functions behave the same as the derivatives of real
valued functions.
Example 5.4. The complex-valued function
f (t) = cos(t) + i sin(t)
is of particular interest. When viewed as a curve in the complex plane, it defines a circle. It has two
important properties:
(i)f (t)f (s) = f (t + s)
(ii)f 0 (t) = if (t) .
To verify (i), compute as follows using the sum of angle formulas from trigonometry:
f (t)f (s) = (cos(t) + i sin(t))(cos(s) + i sin(s))
= (cos(t) cos(s) − sin(t) sin(s)) + (cos(t) sin(s) + sin(t) cos(s))i
= cos(t + s) + sin(t + s)i = f (t + s) .
To verify (ii), compute as follows from the definition of the derivative:
z 0 (t) = − sin(t) + i cos(t) = i(cos(t) + i sin(t)) = iz(t) .
Because (i) and (ii) are also satisfied by the exponential function: ert :
ert est = e(r+s)t and (ert )0 = rert ,
the same notation is used here:
eit = cos(t) + i sin(t) . (5.8)
This is called Euler’s Formula. . With this notation (i) and (ii) assume the forms
0
eit eis = ei(t+s) and eit = i eit . (5.9)

5.5. The complex exponential function

One function is of particular interest to us: the complex exponential function. It is defined as follows:
e(ρ+iω)t = eρt eiωt = eρt (cos(ωt) + i sin(ωt)) = eρt cos(ωt) + ieρt sin(ωt) . (5.10)
Thought of as a curve in the complex plane, the complex exponential is the formula for a spiral curve
(Figure 5.5). The quantity ω is the angular velocity of the spiral (ω > 0 corresponds to a counterclockwise
spiral, ω < 0 to a clockwise one). The quantity ρ measures the rate at which the spiral expands outward
(ρ > 0) or contracts inward (ρ < 0).

As the following examples illustrate, functions of the form


f (t) = C1 eρt cos(ωt) + C2 eρt sin(ωt)
can be rewritten in terms of the complex exponential function.
5.5. THE COMPLEX EXPONENTIAL FUNCTION 55

(a) (b)
2 2

1 1

-2 -1 1 2 -2 -1 1 2

-1 -1

-2 -2

Figure 5.5. (a) z(t) = e(ρ+iω)t , ρ > 0, ω > 0. (b) z(t) = e(ρ+iω)t , ρ < 0, ω > 0.
 
Example 5.5. Show that 5e−4t cos(3t) + 3e−4t sin(3t) = Re (5 − 3i)e(−4+3i)t .

Solution By definition,
(5 − 3i)e(−4+3i)t = (5 − 3i)e−4t (cos(3t) + i sin(3t))
= e−4t ((5 cos(3t) + 3 sin(3t)) + i(5 sin(3t) + 3 cos(3t))) .

 
Hence, Re (5 − 3i)e(−4+3i)t = e−4t (5 cos(3t) + 3 sin(3t)).

Remark 5.4. In polar form 5 + 3i = 34 exp(arctan(3/5)i). Hence, we can compute as follows:
   
Re (5 − 3i)e(−4+3i)t = Re (5 + 3i)e(−4+3i)t
√ √ 
= 34e−4t Re 34e− arctan(3/5)i e3i)t

= 34e−4t Re (exp((3t − arctan(3/5))i))

= 34 e−4t cos (3t − arctan(3/5)) .
 
1 (6+4i)t
Example 5.6. Express Re e in the form Aeρt cos(ωt + φ).
3 + 3i


Solution Since 3 + 3i = 3 2e(π/4)i , it follows that
    6t
1 (6+4i)t 1 6t 4it e   1
Re e = Re √ e e √ Re e(4t−π/4)i = √ e6t cos (4t − π/4)
3 + 3i 3 2e (π/4)i 3 2 3 2

To find the derivative of the complex exponential function, compute the derivatives of the real and
imaginary parts and collecting terms to obtain the formula
 0
e(ρ+iω)t = (ρ + iω)e(ρ+iω)t .
In other words, even for r = ρ + iω, the formula
d rt
e = rert (5.11)
dt
holds!
56 COMPLEX NUMBERS

More generally, if z(t) = x(t) + iy(t) = Ce(ρ+iω)t , where C = C1 + iC2 , then clearly
z 0 (t) = C · (ρ + iω)e(ρ+iω)t and z 00 (t) = C · (ρ + iω)2 e(ρ+iω)t . .
On the other hand, from the definition of the derivative
z 0 (t) = x0 (t) + iy 0 (t) ,
gives a simple way to compute derivatives of
x(t) = Re (z(t)) = (C1 cos(ωt) − C2 sin(ωt))eρt (5.12a)

and

y(t) = Im (z(t)) = (C1 sin(ωt) + C2 cos(ωt))eρt (5.12b)


the real and imaginary parts of z(t):
   
x0 (t) = Re C · (ρ + iω)e(ρ+iω)t and y 0 (t) = Im C · (ρ + iω)e(ρ+iω)t . (5.12c)
   
x00 (t) = Re C · (ρ + ωi)2 e(ρ+iω)t and y 00 (t) = Im C · (ρ + ωi)2 e(ρ+iω)t . (5.12d)

Example 5.7. Consider the function


x(t) = (5 cos(2t) + 4 sin(2t))e−t/5 .
Graph x(t), then compute its first and second derivatives.

(−1/5+2i)t

√ with z(t)√= (5 − 4i)e
Solution Observe that x(t) = Re (z(t)) . To graph x(t), write z(t) in
2 2
polar form: (5 − 4i) = Ae , with A = 5 + 4 = 41 ≈ 6.40 and φ = − arctan(4/5) ≈ −0.67. Hence,
z(t) = Aeiφ e((1/5)+i2)t = Ae−t/5 e(2tφ)i
From this, it follows that
x(t) = Ae−t/5 cos(2t + φ) = Ae−t/5 cos(2(t + φ/2)) ≈ 6.40e−t/5 cos(2(t − 0.38)) ,
from which one can more easily visualize the graph (see Example A.1 in Appendix A).

0
x

10
0 5 10 15 20
t

Figure 5.6. The graph of x(t) = Ae−t/5 cos(2t + φ).

One could, of course, compute the first and second derivatives of x(t) directly from the original formula,
but that would be tedious. It’s easier, however, to first compute the derivatives of z(t) and then to take
the real part to obtain the derivatives of x(t). Here’s the computation:
5.5. THE COMPLEX EXPONENTIAL FUNCTION 57

Since
 
54
z 0 (t) = (5 − 4i)(−1/5 + 2i)e(−1/5+2i)t = 7+ i e(−1/5+2i)t ,
5
 
54
x0 (t) = 7 cos(2t) − sin(2t) e−t/t .
5
Since
 
296
z 00 (t) = (5 − 4i)(−1/5 + 2i)2 e(−1/5+2i)t = −23 + i e(−1/5+2i)t ,
25
 
296
x00 (t) = − 23 cos(2t) + sin(2t) e−t/t .
25
Z 1
Example 5.8. Evaluate the definite integral (3 cos(2t) − 4 sin(2t))e5t dt.
0

 
Solution Observe that (3 cos(2t) − 4 sin(2t))e5t = Re (3 + 4i)e(5+2i)t . We can now compute as
follows:
Z 1 Z 1 
(3 cos(2t) − 4 sin(2t))e5t dt = Re (3 + 4i)e(5+2i)t dt
0 0
1 !  
3 + 4i (5+2i)t 3 + 4i (5+2i)
= Re e = Re (e − 1)
5 + 2i 0 5 + 2i
  
23 14 5

= Re + i e (cos(2) + i sin(2)) − 1
29 29
  
23 14 5 5

= Re + i (e cos(2) − 1) + ie sin(2)
29 29
23 5 14
= (e cos(2) − 1) − e5 sin(2) ≈ −114.9
29 29
Exercise 5.3.

(1) Sketch the graph of the curve z(t) = (2 + 2i)e( 2 +π i)t for 0 ≤ t ≤ 3 in the complex plane.
1

(2) Write the function x(t) = 3e−2t cos(4t) + 5e−2t sin(4t) in each of the forms x(t) = Re Cert


and x(t) = Aeρ t cos(ω t + φ), where A, ω and φ are real numbers and C and r are complex
numbers.
(3) Using the complex exponential function, compute the second derivative of the function x(t) =
(2 cos(4t) − 3 sin(4t))e−t Check
Z your answer by also computing the second derivative directly.
π
(4) Evaluate the definite integral et/π sin(t) dt.
0
CHAPTER 6

Introduction to Second Order Differential Equations

A second order ordinary differential equation is an equation of the form


d2 y
 
dy
= F t, y, , (6.1)
dt2 dt
where F (t, y, y 0 ) is a function of t, y and y 0 . A solution is a function y = y(t) satisfying the equality
y 00 (t) = F (t, y(t), y 0 (t))
for all t in some interval.

As was the case for the general first order differential equation, second order differential equations have
many solutions. As mentioned in the introduction, differential equations have many solutions; additional
information is needed to determine a unique solution. Usually, this is in the form of initial conditions of
the form
y(t0 ) = y0 and y 0 (t0 ) = y00 ,
specifying the value of the solution and its derivative at a fixed time t = t0 . A function y = y(t) satisfying
the differential equation together with the initial conditions y(t0 ) = y0 , y 0 (t0 ) = y00 is a solution of the
initial value problem
d2 y
 
dy
= F t, y, , y(t0 ) = y0 , y 0 (t0 ) = y00 .
dt2 dt
The remainder of these notes is devoted to the development of techniques for solving second order
differential equations and initial value problems.

6.1. Special Cases

There are two cases where a second order differential equation can be solved by reducing it’s solution
to solving a sequence of two first order differential equations. In the first case, the second derivative is
independent of t, and the differential equation is of the form
d2 y
 
dy
= F y, . (6.2a)
dt2 dt
In the second case, the second derivative is independent of y and the differential equation is of the form
d2 y
 
dy
= F t, . (6.2b)
dt2 dt
To solve (6.2a), let v = dy/dt, and use the chain rule to write the second derivative in the form
d2 y dv dv dy dv
= = = v. Equation (6.2a) can now be rewritten as the first order differential equation
dt2 dt dy dt dy
in the independent variable y, rather than t:
dv
v = F (y, v) .
dy
59
60 INTRODUCTION TO SECOND ORDER DIFFERENTIAL EQUATIONS

Suppose that v = V (y, C1 ) is the solution. Then


dy
= v = V (y, C1 ) .
dt
This is another first order differential equation that can be solved by separation of variables:
Z
dy
= t + C2 .
V (y, C1 )
d2 y dv
Example 6.1. Consider the equation 2
= −ky. Let v = y 0 . Then, v = −ky, which we integrate
dt dy
1 k k
to get v 2 = − y 2 + C1 . To make the computations simpler, let C1 = A2 , where A > 0 is another
2 2 2
constant. Then v 2 = k(A2 − y 2 ). Solving for v gives
dt √ p 2
= k A − y2 ,
dt
which we can solve using separation of variables:
√ 
y(t) = A sin k(t + φ) ,

where A and φ are constants. We used a variant of this technique in Section 4.3 to study the harmonic
oscillator using the principle of conservation of energy.

dy
The approach to solving (6.2b) is similar. We again set v = dt . The equation now becomes
dv
= F (t, v) .
dt
This is a first order differential equation. If v = V (t, C1 ) is a solution, then
dy
= v = V (t, C1 ) ,
dt
which can be solved directly by integration:
Z
y(t) = V (t, C1 ) dt .

Example 6.2. To solve the differential equation y 00 + t(y 0 )2 = 0, let v = y 0 . Then v 0 + tv 2 = 0, which
can be solved by separation of variables:
t2
Z Z
dv 1 1 2
2
= − tdt =⇒ − = − + C1 =⇒ y 0 == 2 = 2 .
v v 2 t /2 + C1 t + 2C1
Consequently,
Z  
1 2 t
y(t) = 2 dt = √ arctan √ + C2
t2 + 2C1 2C1 2C1

Exercise 6.1. Consider a flat metal washer described in polar coordinates by 1 ≤ r ≤ 2. If the inner
boundary of the washer is held at temperature T = 50◦ C and the outer boundary at T = 100◦ C for a
long time so that the washer reaches thermal equilibrium, the temperature T of at a point in the washer
will depend only on the distance r from the center and it can be shown that it satisfies the second order
differential equation
d2 T 1 dT
+ = 0.
dr2 r dr
Find the temperature distribution T = T (r). Hint: Let y(r) = T 0 (r) and solve a first order differential
equation for y(r).
6.2. LINEAR SECOND ORDER DIFFERENTIAL EQUATIONS 61

6.2. Linear Second Order Differential Equations

The most common class of differential equations occurring in applications is the class of linear second
order differential equations. These are differential equations that can be written in the form
d2 y dy
2
+ p(t) + q(t) y = f (t) ,
dt dt
where the functions p(t), q(t) and f (t) are usually assumed to be continuous or piecewise continuous
on an interval a < t < b. The function f (t) is called a forcing function.When f (t) = 0, the differential
equation becomes
d2 y dy
+ p(t) + q(t) y = 0
dt2 dt
and the differential equation is called a homogeneous linear differential equation. When the forcing
function f (t) is not zero the equation is said to be nonhomogeneous..

Notice the similarity between the form of a linear second order differential equation and the form of a
linear first order differential equation:
dy
+ p(t) y = f (t) .
dt
This suggests that some of the techniques for solving first order linear differential equations might be
useful for solving second order differential equations.

(Notation) Rather than writing out the full (and rather long) expression
d2 y dy
2
+ p(t) + q(t) y ,
dt dt
it is often convenient to use the shorthand notation L[y] for the left-hand side:
d2 y dy
L[y] = + p(t) + q(t) y.
dt2 dt
For instance, if L[y] = y 00 + 4y. Then we write
L[sin(2t)] = 0
rather than
(sin(2t))00 + 4(sin(2t)) .
The object L is called a linear operator because it satisfies the identity
L[C1 y1 (t) + C2 y2 (t)] = C1 L[y1 (t)] + C2 L[y2 (t)] (6.3)
for any two functions y1 (t) and y2 (t) and any constants C1 and C2 .

This property of L is called the superposition principle. The superposition principle states that if y1 (t)
and y2 (t) are two solutions of the differential equation
y 00 + p(t)y 0 + q(t)y = 0
then so is the linear combination C1 y1 (t) + C2 y2 (t). This follows from Equation (6.3). For suppose
L[y1 (t)] = 0 and L[y2 (t)] = 0. Then
L[C1 y1 (t) + C2 y2 (t)] = C1 L[y1 (t)] + C2 L[y2 (t)] = C1 · (0) + C2 · (0) = 0 .
The superposition principle shows that by taking linear combinations we can build complicated solutions
out of simple solutions. This fact underlies many of the computations done in physics and engineering.
62 INTRODUCTION TO SECOND ORDER DIFFERENTIAL EQUATIONS

We can verify Equation (6.3) by computing:


L[C1 y1 (t) + C2 y2 (t)] = (C1 y1 (t) + C2 y2 (t))00 + p(t)(C1 y1 (t) + C2 y2 (t))0 + q(t)(C1 y1 (t) + C2 y2 (t))
= (C1 y100 (t) + C2 y200 (t)) + p(t)(C1 y10 (t) + C2 y20 (t)) + q(t)(C1 y1 (t) + C2 y2 (t))
Rearranging terms gives
= C1 (y100 (t) + p(t)y10 (t) + q(t)y1 (t)) + C2 (y200 (t) + p(t)y20 (t) + q(t)y2 (t))
= C1 L[y1 (t)] + C2 L[y2 (t)]

The following theorem is the main theoretical result about second order linear differential equations:
Theorem 2. Suppose that p(t), q(t) and f (t) are continuous on the interval a < t < b. Suppose further
that t0 is between a and b. Then the initial value problem
L[y] = y 00 + p(t)y 0 + q(t)y = f (t), y(t0 ) = y0 , y 0 (t0 ) = y00
has one and only one solution defined on the entire interval a < t < b.

Some bad news. This theorem does NOT tell us how to find the solution—it only confirms that
a solution exists and that it is unique. Even worse, unlike the first order linear differential equation,
there is no general formula for the solution of the most general second order initial value problem.

Some good news. There are general techniques for finding a solution in the most commonly occurring
case where p(t) and q(t) are constants and the differential equation assumes the special form
L[y] = y 00 + by 0 + cy = f (t) , y(t0 ) = y0 , y 0 (t0 ) = y00 , (6.4)
where b and c are constants.

The remainder of these notes is devoted to the study of initial value problems of the special form (6.4).
CHAPTER 7

Solving Homogeneous Linear Differential Equations

The goal of this chapter is to understand how to solve initial value problems of the form
L[y] = ay 00 + by 0 + cy = 0 , y(t0 ) = y0 , y 0 (t0 ) = y00 . (7.1)
Suppose that we have succeeded in finding two solutions of the equation L[y] = 0, say y1 (t) and y2 (t).
Then, by the superposition principal (see Equation (6.3)) the “linear combination”
y = C1 y1 (t) + C2 y2 (t)
is also a solution of L[y] = 0. Let’s verify that this is the case:
L[y] = L[C1 y1 + C2 y2 ]
= a(C1 y1 + C2 y2 )00 + b(C1 y1 + C2 y2 )0 + c(C1 y1 + C2 y2 )
= a(C1 y100 + C2 y200 ) + b(C1 y10 + C2 y20 ) + c(C1 y1 + C2 y2 )
= C1 (ay100 + by10 + cy1 ) + C2 (ay200 + by20 + cy2 )
= C1 L[y1 ] + C2 L[y2 ]
= C1 · 0 + C2 · 0 = 0
Therefore, once we have found two solutions y1 (t) and y2 (t), we can construct lots of solutions by taking
linear combinations. This fact is the basis for the following general strategy for solving any initial value
problem of the form
L[y] = 0 , y(t0 ) = y0 , y 0 (t0 ) = y00 .

(i) First find two independent solutions of the differential equation


L[y] = ay 00 + by 0 + cy = 0 .
Call them y1 (t) and y2 (t).
(ii) Form the general solution y(t) = C1 y1 (t) + C2 y2 (t)
(iii) Solve the system of equations
(
C1 y1 (t0 ) + C2 y2 (t0 ) = y0
(7.2)
C1 y10 (t0 ) + C2 y20 (t0 ) = y00
for the unknowns C1 and C2 .

In examples, it is usually easy to solve for C1 and C2 by hand. However, the formulas:
y0 y20 (t0 ) − y00 y2 (t0 ) y00 y1 (t0 ) − y0 y1 (t0 )
C1 = C2 =
y1 (t0 ) y20 (t0 ) − y2 (t0 ) y10 (t0 ) y1 (t0 ) y20 (t0 ) − y2 (t0 ) y10 (t0 )
for C1 and C2 are also occasionally useful. The denominator is called the Wronskian of y1 (t) and y2 (t).
Remark 7.1. The functions y1 (t) and y2 (t) found in step (i) cannot be scalar multiples of one another!
That is what we meant by the condition that the solutions y1 (t) and y2 (t) are independent solutions.
The pair y1 (t), y2 (t) is called a fundamental basis of solutions.
63
64 SOLVING HOMOGENEOUS LINEAR DIFFERENTIAL EQUATIONS

The fundamental basis is not unique! There are MANY fundamental bases of solutions for a given
homogeneous linear differential equation.
Example 7.1. Consider the differential equation
y 00 − y = 0 .
The functions et and e−t form a fundamental basis of solutions. But so do the functions
et − e−t et + e−t
sinh(t) = and cosh(t) = .
2 2
Yet another fundamental basis is the pair of functions
sinh(t − 3) and cosh(t − 3) .
Choosing the right fundamental system can often simplify the solution of initial value problems. For
instance, consider the IVP
y 00 − y = 0 y(3) = 11 y 0 (3) = 13 .
The function y(t) = C1 cosh(t − 3) + C2 sinh(t − 3) is the general solution of y 00 − y = 0. From this, it is
easy to determine C1 and C2 :
y(3) = C1 cosh(0) + C2 sinh(0) = C1 = 11
and
y 0 (3) = C1 sinh(0) + C2 cosh(0) = C2 = 13 .
Hence,
y(t) = 11 cosh(t − 3) + 13 sinh(t − 3) .
Of course, the function y(t) can also be expressed in terms of the fundamental system et and e−t as can
be seen by expanding as follows:
y(t) = 11 cosh(t − 3) + 13 sinh(t − 3)
11 t−3 13
= (e + e−t+3 ) + (et−3 − e−t+3 ) = 12e−3 et − e3 e−t .
2 2

7.1. The Characteristic Polynomial

To solve the homogeneous differential equation


L[y] = ay 00 + by 0 + cy = 0
we need to find two independent solutions. To do this, we will look for solutions of the special form
y = ert . Let’s compute L[ert ]:
L[ert ] = a(ert )00 + b(ert )0 + c(ert ) = (ar2 + br + c) ert .
This shows that ert is a solution of the differential equation if r is a solution of the quadratic equation
ar2 + br + c = 0 . (7.3)
We have reduced the problem of solving the differential equation to a problem in algebra. The polynomial
ar2 + br + c is called the characteristic polynomial of the differential equation, and the equation (7.3) is
called the characteristic equation.

Let r1 and r2 be the roots of the characteristic polynomial. There are three cases to consider:

(i) r1 and r2 are both real and r1 6= r2 (b2 > 4ac).


(ii) r1 = r2 (b2 = 4ac).
(iii) r1 and r2 are complex (b2 < 4ac).
7.2. DISTINCT REAL ROOTS OF THE CHARACTERISTIC POLYNOMIAL 65

In case (i), the two functions y1 (t) = er1 t and y2 (t) = er2 t clearly form a fundamental system of solutions.
But this fails in case (ii), where the characteristic polynomial has only one root. In case (iii), the roots
are complex. We consider each case separately.

7.2. Distinct Real Roots of the Characteristic Polynomial

This is the easiest case: the functions er1 t and er2 t are independent; and, therefore,
y(t) = C1 er1 t + C2 er2 t (7.4)
is the general solution of the differential equation.
Example 7.2. Solve the initial value problem
L[y] = y 00 − 3y 0 + 2y = 0 and y(0) = 0 , y 0 (0) = 1 .
Solution Substituting y = ert into the equation L[y] = 0 gives
(r2 − 3r + 2) · ert = 0 ,
This implies that r satisfies the quadratic equation
r2 − 3r + 2 = (r − 2)(r − 1) = 0 .
Therefore, y = et and y = e2t are two independent solutions of the differential equation and
y(t) = C1 et + C2 e2t
is the general solution. The initial conditions are
y(0) = C1 + C2 = 0
and
y 0 (0) = C1 + 2C2 = 1 .
It follows that C1 = −1 and C2 = 1. Therefore,
y(t) = −et + e2t .
Example 7.3. Solve the initial value problem
L[y] = y 00 − 4y = 0 , y(0) = 7 , y 0 (0) = 8 .
Solution First find the general solution of the differential equation by looking for solutions of the form
y = ert . Since L[ert ] = (r2 − 4) · ert , r = ±2 and the general solution is
y(t) = C1 e2t + C2 e−2t .
The initial conditions give
C1 + C2 = 7 and 2C1 − 2C2 = 8 ,
which are easily solved to give
11 3
C1 = and C2 = .
2 2
11 2t 3 −2t
Hence, y(t) = e + e .
2 2
Example 7.4. Solve the initial value problem:
y 00 − y = 0 y(3) = 11, y 0 (3) = 13 .

Solution The roots of the characteristic polynomial r2 − 1 are ±1, hence the general solution is
y = C1 et + C2 e−t .
66 SOLVING HOMOGENEOUS LINEAR DIFFERENTIAL EQUATIONS

The initial conditions give


y(3) = C1 e3 + C2 e−3 = 11 y 0 (3) = C1 e3 − C2 e−3 = 13 .
Solving for C1 and C2 gives:
C1 = 12e−3 and C2 = −e3 .
The solution of the initial value problem is, therefore,
y = (12e−3 ) et − e3 e−t = 12e(t−3) − e−(t−3) .
Exercise 7.1. Solve each of the following differential equations and initial value problems.

(1) y 00 − 4y = 0, y(0) = 1, y 0 (0) = 1.


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

7.3. Repeated Roots of the Characteristic Polynomial

Example 7.5. Consider the differential equation


y 00 + 2y 0 + y = 0 .
The characteristic polynomial is
r2 + 2r + 1 = (r + 1)2 ,
which has only one root r = −1. Therefore, the function e−t is a the only solution of the differential
equation of the form ert . We need a second independent solution.

Fortunately, one can check directly that te−t is also a solution:


L[te−t ] = (te−t )00 + 2(te−t )0 + (te−t )
(t − 2)e−t + 2(1 − t)e−t + te−t
(t − 2t + t)e−t + (−2 + 2)e−t = 0 .
Since te−t is not a constant multiple of e−t , the general solution is
y(t) = C1 e−t + C2 te−t = (C1 + C2 t)e−t .

This idea works in all cases where the characteristic polynomial has a double root. For suppose that the
characteristic polynomial factors has the double root r0 . Then
ar2 + br + c = a(r − r0 )2 = a(r2 − 2r0 r + r02 ) .
One solution of the differential equation is er0 t . To see that ter0 t is another, compute as follows:
L[ter0 t ] = a (ter0 t )00 − 2r0 (ter0 t )0 + r02 (ter0 t


= a (2r0 + r02 t)er0 t − a2r0 (er0 t + r0 ter0 t ) + r02 ter0 t




= a (r02 − 2r02 + r02 )ter0 t + (2r0 − 2r0 )er0 t = 0




Thus, the general solution is


y = C1 er0 t + C2 ter0 t = (C1 + C2 t) er0 t . (7.5)
7.4. COMPLEX ROOTS OF THE CHARACTERISTIC POLYNOMIAL 67

Example 7.6. Find the solution of the initial value problem.


y 00 − 6y 0 + 9y = 0 , y(2) = 3 , y 0 (2) = 0 .
Solution The characteristic polynomial factors as
r2 − 6r + 9 = (r − 3)2 .
So the general solution is y = (C1 + C2 t)e3t . The initial conditions give
(C1 + 2C2 )e6 = 3 , (3C1 + 7C2 )e6 = 0
Solving for C1 and C2 gives C1 = 21e−6 , C2 = −9e−6 . Hence,
y(t) = (21 − 9t)e3t−6 .
Exercise 7.2. Solve each of the following differential equations and initial value problems.

(1) y 00 + 6y 0 + 9y = 0, y(0) = 1, y 0 (0) = 1.


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

7.4. Complex Roots of the Characteristic Polynomial

It remains to consider case (iii) where the characteristic polynomial of the differential equation
L[y] = ay 00 + by 0 + cy = 0
has complex roots. Specifically, suppose b2 < 4ac, then the two complex roots are
√ !
4ac − b2
 
b
ρ ± ωi = − ±i .
2a 2a
Therefore, the pair of functions
e(ρ+ωi)t = eρt cos(ωt) + ieρt sin(ωt) , e(ρ−ωi)t = eρt cos(ωt) − ieρt sin(ωt)
forms a fundamental basis of solutions. The pair of functions
1 (ρ+ωi)t 1 (ρ−ωi)t 1 1
eρt cos(ωt) =
e + e , eρt sin(ωt) = e(ρ+ωi)t − e(ρ−ωi)t
2 2 2i 2i
also forms a fundamental basis. This implies that the general solution is
 
y(t) = eρt (C1 cos(ωt) + C2 sin(ωt)) = Re (C1 − C2 i)e(ρ+ωi)t .

Example 7.7. Find the solution of the initial value problem


y 00 − 4y 0 + 13y = 0 , y(0) = 1 , y 0 (0) = 4 .
Solution The characteristic polynomial is (completing the square)
r2 − 4r + 13 = (r − 2)2 − 4 + 13 = (r − 2)2 + 9 ,
whose roots are 2 ± 3i. Therefore, the general solution is
 
y(t) = Re (C1 − C2 i)e(2+3i)t = e2t (C1 cos(3t) + C2 sin(3t)) .

Since  
y 0 (t) = Re (C1 − C2 i)(2 + 3i)e(2+i3)t
68 SOLVING HOMOGENEOUS LINEAR DIFFERENTIAL EQUATIONS

the initial conditions are


y(0) = Re (C1 − C2 i) = C1 = 1
y 0 (0) = Re ((C1 − C2 i)(2 + 3i)) = 2C1 + 3C2 = 4 .
4 − 2C1 2
Hence, C1 = 1 and C2 = = . Therefore, the solution to the initial value problem is
3 3
   
2 2
y(t) = Re (1 − i)e(2+3i)t = cos(3t) + sin(3t) e2t .
3 3
7.4. COMPLEX ROOTS OF THE CHARACTERISTIC POLYNOMIAL 69

Exercise 7.3. Write the solution of the initial value problem


y 00 + 25y = 0 y(0) = 1 y 0 (0) = 2 .

in the form y(t) = Re Ce(ρ+iω)t . By converting C to polar form write the solution in the form
y(t) = Aeρt cos(ωt + φ) ,
where A and φ are real numbers determined by the initial conditions. Graph the solution.
Exercise 7.4. The function
y(t) = 2e−t cos(5t) + 3e−t sin(5t)
is the solution of the initial value problem
y 00 + 2y 0 + 26 = 0 y(0) = 2 , y 0 (0) = 13 .
In the form above, it is difficult to graph. Rewrite it in each of the two forms
y(t) = Re (Cert ) and y(t) = Ae−at cos(ωt + φ) ,
where C and r are complex numbers that you have to determine, and A, ω and φ are real numbers that
you also have to determine. Sketch the solution.
Exercise 7.5. Solve each of the following differential equations and initial value problems.

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


(2) y 00 − 4y 0 + 7y = 0, y(1) = 0, y 0 (1) = 1.
(3) y 00 + 4y 0 + 8y = 0.
(4) y 00 + 6y 0 + 13y = 0.
CHAPTER 8

The Harmonic Oscillator

The harmonic oscillator (see Example 1.2) is the mechanical system consisting of an object of mass m
attached to a spring with spring constant k. If x denotes the amount that the spring is stretched relative
to its equilibrium position, then by Newton’s second law of motion, the function x = x(t), t = time, is
a solution of the linear differential equation
mx00 + kx = 0 .
Because m and k are both positive,
r
00 k
x + ω02 x = 0 , where ω0 = . (8.1)
m

Fspring = −kx
m x
6
x=0 x(t)

Since ±ω0 i are the roots of the characteristic polynomial r2 + ω02 , the general solution is
r
iω0 t
 k
x(t) = Re Ce , where ω0 = .
m
If we write the complex number C in the polar form C = Aeiφ , the solution wan be written in the form
  φ
x(t) = Re Aei(ω0 t+φ) = A cos(ω0 t + φ) = A cos(ω0 (t − t0 )) . where t0 = − , (8.2)
ω0
in which it is easier to visualize the graph of x(t). (See Figure 8.1.) In particular, we can see that the

spring-mass system oscillates at frequency ω0 and period T = .
ω0

x = Acos( (t t0)
x = Acos( t)
6t0
-

A 6
? -

 -

T = ω0

Figure 8.1. The graph of x(t) = A cos(ω0 (t − t0 )), t0 > 0.

71
72 THE HARMONIC OSCILLATOR

Exercise 8.1. The graph below shows the motion of an harmonic oscillator. Determine the values of
A, ω0 , and φ. Choose −π < φ ≤ π.

3
2
1
0
1
2
3
0 1 2 3 4

Recall the law of conservation of energy, which we introduced in Section 4.3 to solve the harmonic
oscillator. It gives additional insight into the dynamics of the mass-spring system. The Energy of the
system is split between the kinetic energy of the object and the potential energy of the spring. In
Section 4.3, we showed that the sum of kinetic energy and potential energy
1 1
K.E. + P.E. = mv 2 + kx2
2 2
is constant. We can check this directly:
1 1 2 A2 2 2
K.E = mx0 (t)2 = m (−Aω0 sin(ω0 t + φ)) = k sin (ω0 t + φ)
2 2 2
1 1 2 A2 2
P.E = kx(t)2 = k (A cos(ω0 t + φ)) = k cos2 (ω0 t + φ)
2 2 2
So,
A2 2 2 A2 2
K.E. + P.E. = k sin (ω0 t + φ) + k cos2 (ω0 t + φ)
2 2
1 1
= A2 k 2 (sin2 (ω0 t + φ) + cos2 (ω0 t + φ)) = A2 k 2 ,
2 2
a constant. As the speed of the object increases, so does its kinetic energy; and conservation of energy
forces the potential energy of the spring to decrease; and as the speed of the object decreases, the
potential energy of the spring increases. Energy is therefore transferred back and forth between the
object and the spring, as shown in Figure 8.2.
P.E.
E6 K.E.

t
-

Figure 8.2. Conservation of energy for the Harmonic Oscillator. The potential energy
of the spring is the red curve. The kinetic energy of the object is the blue curve.
THE HARMONIC OSCILLATOR 73

Exercise 8.2. A weight of mass m = 5 kg is suspended from a spring with unknown spring constant
k. The weight is free to move up and down. Ignoring friction, its position relative to its equilibrium
position satisfies a differential equation of the form
mu00 + ku = 0 ,
where t denotes time measured in seconds. To find the spring constant, the spring is set in motion and
the graph of u(t) plotted. The result is shown in the following figure. The horizontal axis is t (measured
in seconds), vertical axis is u (measured in meters):

x = x(t)
1.0
0.5
0.0
x

0.5
1.0
1.5
0 1 2 3
t

(a) The function u = u(t) is the solution of an initial value problem. What are the initial condi-
tions? That is, what are the values of u(0) and u0 (0)?
(b) What is the period T measured in seconds?
(c) What is the spring constant k? (Your answer can most easily be expressed in terms of π.)
Exercise 8.3. A cylindrical log of radius 1/10 meter, 5 meters in length, and with a mass of 50
kilograms is placed vertically in a lake so that it is free to bob up and down. Assume that there is no
water resistance. A weight of 50 kilograms of negligible volume is attached to the bottom of the log so
that it remains vertical (so the total mass of the log and weight together is 100 kilograms). The mass
density of water is 1000 kilograms per cubic meter. (For convenience, assume that the acceleration due
to gravity is g = 10 meters per sec2 (It is actually closer to 9.81.)

There are two forces acting on the log: gravity and the buoyant force of the water. The buoyant force
can be computed from Archimedes’ principle:

An object that is completely or partially submerged in a fluid is acted on by an upward


(buoyant) force equal to the weight of the displaced fluid.

Let t be time in seconds and let d(t) denote the depth (in meters) of the bottom of the log .

(a) Compute the depth deq of the log in its equilibrium position, i.e. when the magnitude of the
buoyant force is exactly equal the combined weight (in Newtons) of the log plus the mass.
Hint: Draw a good picture!
(b) Write down a differential equation for d(t).
(c) Now let y(t) = d(t) − deq , the displacement of the log from its equilibrium position. Assuming
that y(0) = 1 meters and y 0 (0) = 0 meters/sec, write down an initial value problem for y.
(d) Solve the initial value problem you wrote down in part (c).
74 THE HARMONIC OSCILLATOR

Exercise 8.4. Consider a “U”-shaped tube filled with liquid Mercury as shown in the figure below. The
radius of the tube is 1 centimeter (so its diameter is 2 centimeters). There are 500 grams of Mercury
in the tube. Liquid Mercury has a mass density of 13.5 grams per cubic centimeter. The mercury in
the tube will oscillate with a certain period T , measured in seconds. Your task is to compute T by
completing the following steps:

(a) Let y(t) be the height above its equilibrium position of the
liquid surface at the left vertical segment of the tube. (At equi-
librium, both surfaces are at the same height above sea level
and y = 0. When y(t) < 0 the right surface is higher than the
left surface.) The only force acting on the mass of fluid in the
tube is due to gravity. Compute the total force on the fluid
y(t)
(vertical component only). 2y(t)
(b) Use formula you found in part (a) to find a linear, homo-
geneous, constant coefficient, second order differential equation
for y = y(t).
(c) Solve the differential equation you found in part (a).
(d) What is the period T ? Hints: Treat the fluid as a single
rigid body. The net force acting on the fluid is twice the weight
of the fluid above the equilibrium level (all other forces cancel).

Exercise 8.5. Consider a mechanical system consisting of a spring with spring constant k = 10 lb/ft
and a 100 pound weight that is free to move up and down. Assume that at time t = 0 sec the spring
is unstretched but taut and the velocity of the weight is 0 ft/sec. At time t = 0 sec the net force on
the weight is the 100 pound downward force due to gravity. Describe the subsequent motion of the
weight, particularly the period and frequency of the resulting periodic behavior and the amplitude of
the oscillations.

8.1. LC-circuits

The mass-spring system above is only one of many systems modeled on the differential equation (8.2).
The electrical circuit described here is another. The exercises at the end of this section present others.

Figure 8.3) shows an electrical circuit with two components: an inductor and a capacitor. As current
moves through the circuit, an electric charge q accumulates on the plates of the capacitor and forms an
electric field between the plates. At the same time, the current I in inductor, which is a coil of wire
wrapped around a metal core (see Figure 1.2) forms a magnetic field.

Recall that Kirchhoff’s law states that the sum of the voltage drops around a closed circuit sums to
zero, so applying the formulas (1.7) for the voltage drops across the inductor and the capacitor gives the
differential equation
1
Lq 00 + q = 0 , (8.3)
C
which governs the behavior of the charge q(t) on the capacitor. Apart from a change of symbols, the
differential equation (8.3) is the same as the differential equation (8.1). Therefore, the charge on the
capacitor is also modeled by a function of the form
q(t) = A cos(ω0 t + φ) ,
p
where in this case ω0 = 1/LC. Consequently, in an LC-circuit,
p the charge on the √
capacitor and the
voltage drop across it both oscillate with frequency ω0 = 1/LC and period T = 2π LC.
8.1. LC-CIRCUITS 75

 2
EL = 21 L dq
EC = 1 1 2 L
dt 2 Cq

I(t)

Figure 8.3. A current I = q 0 flowing in the circuit shown on the right flows through
the coil of the inductor (shown on the left) and generates a magnetic field. A charge q
accumulates on the plates of the capacitor, generating an electric field. The circuit is
called an LC-circuit.

As in the mass-spring system, energy is stored both in the electric field and in the magnetic field. The
energy stored in the electric field of the capacitor is given by the formula
11 2
EC = q
2C
where q is the charge on the plates of the capacitor; and the energy storied in the magnetic field of the
inductor is given by the formula
 2
1 1 dq
EL = LI 2 = L
2 2 dt
where L is the inductance of the inductor and I = q 0 is the current. As in the mass-spring system,
energy flows back and forth between the magnetic field and the electric field, with the sum of energies
 
dq 11 2
EL + EC = L + q
dt 2C
remaining constant.
Example 8.1. Suppose you want to design an LC-circuit in which the current oscillates at 60 Hertz
(cycles per second). Suppose further that you have only one inductor with inductance of 9100 µ H.
(µH = micro Henries) What capacitance should you choose for the capacitor?


Solution If the frequency is 60 Hertz, then ω0 = 2π · 60 = 120π sec−1 . Since ω0 = 1/ LC,
1 1
C= 2 = F ≈ 773.2µF ,
ω0 L (120π)2 (9100 × 10−6 )
(µ F = micro Farads)
76 THE HARMONIC OSCILLATOR

8.2. The Damped Harmonic Oscillator

We have ignored frictional forces in our discussion of the mass-spring system. Even under ideal condi-
tions, in actual mechanical systems (small) frictional forces dissipate energy, and cause the amplitude
of the oscillations to decay exponentially. In this section, we develop a more realistic model that takes
this into account.

The damped harmonic oscillator , is a mathematical model of a mechanical system consisting of an object
of mass m attached to a spring with spring constant k, and also to a damping mechanism. If x is the
amount by which the spring is stretched, then the motion of the damped harmonic oscillator is governed
by the differential equation
m x00 + γ x0 + k x = 0 . (8.4)
0
The term γ x models frictional forces.

Example 8.2. As a concrete example (pictured on the left) consider a weight of mass m hanging from
the end of a spring and under the influence of gravity. A rod connects the weight to a plunger which
moves in a thick fluid exerting a drag force on the weight.

Let y denote the position of the weight measured in meters


along a vertical coordinate axis pointing up Align the y-
axis so that y = 0 at the bottom end of the spring when
no mass is attached. There are three forces acting on the
weight:
• Fgravity = −gm, g = 9.8m/sec2 . 6
• Fspring = −ky, the spring force, where k is the Fspring = −ky
spring constant and where we have set y = 0 at y=0
the rest position of the spring. Hence, for y >
0 the spring is compressed and the force spring Fgravity = −mg x = 0, y = −mg/k
exerts on the weight is negative (pointing down);
and for y < 0, the spring is stretched and the ?
force is positive (pointing up).
• Fdamping = −γ dy Fdamping = −γy 0
dt , the damping force, where γ is
the damping coefficient.

Applying Newton’s second law of motion (“F = ma”) results in the differential equation
m y 00 = −g m − γ y 0 − k y, which is usually written in the form

m y 00 + γ y 0 + ky = −g m . (8.5)

The weight is in equilibrium when it has velocity zero (y 0 = 0) and the upward force of the spring cancels
with the downward force of gravity. At equilibrium
mg
−ky − mg = 0 or y = .
k
Let yeq = −mg/k (the value of y at equilibrium configuration). This suggests measuring the position of
the weight relative to its equilibrium position:

y = yeq + x .

The quantity x is the displacement of the weight from its equilibrium position y = yeq . The effect
of expressing the position of the weight in terms of its displacement from equilibrium is to turn the
nonhomogeneous equation (8.5) into (the equivalent) homogeneous equation (8.4).
8.2. THE DAMPED HARMONIC OSCILLATOR 77

We have shown that the motion of the weight under the influence of gravity is equivalent to its motion
without gravity—that is, centering the origin of the coordinate system at the equilibrium position has
the effect of eliminating gravity from the equation of motion.

The behavior of the damped harmonic oscillator depends on the numerical values of the parameters m,
γ, and k. As the damping constant increases, the rate of exponential decay of the oscillations increases
until at a certain critical value they disappear altogether. More precisely, the behavior depends on the
number and type of the roots of the characteristic polynomial mr2 + γr + k. There are four cases:

(i) γ = 0 (Undamped) The roots are pure imaginary.


(ii) γ 2 − 4mk < 0 (Under damped) The roots are complex conjugates of one another.
(iii) γ 2 − 4mk = 0 (Critically damped) There is a single double root.
(iv) γ 2 − 4mk > 0 (Over damped) The roots are both negative real numbers.

Figure 8.4 illustrates typical behaviors of the damped harmonic oscillator in each of these four cases.

x(t) = A cos (ω0 t + φ) Undamped Under damped


x

γ
x(t) = A e− 2m t cos (ωd t + φ)

t t

Critically damped Over damped


x

γ
x(t) =√ 2 √
γ 2 −4mk
x(t) = (A + Bt) e− 2m t
γ −4mk γ
(Ae 2m t + Be− 2m t )e− 2m t

t t

Figurer 8.4. The four behaviors of the damped harmonic


r oscillator. The frequency
 γ 2
k
ω0 = is called the natural frequency and ωd = ω02 − is called the quasi-
m 2m
frequency.
Exercise 8.6. Suppose m = 0.4 kg, γ = 2.0 kg/sec, and k = 4.0 kg/sec2 , the initial displacement is
2.0 meters and the initial velocity is −3.0 meters/sec. Find the solution of (8.4) that satisfies the initial
condition.
78 THE HARMONIC OSCILLATOR

Exercise 8.7. A 1 kilogram mass is suspended from the end of a spring with a spring constant of 1 N/n
(Newtons per meter). The mass is free to move up and down, y is the amount (measured in meters) that
the spring is stretched and there is no gravity. In addition, there is a damping mechanism that exerts a
force of −γ y 0 Newtons, where γ is a constant.
(a) What value of γ will make the system critically damped ?
(b) If at time t = 0 the spring is not stretched and the mass is moving at a rate of 0.5 m/sec (meters
per second), what is the formula for y(t). (Use the value of γ obtained in part a).
(c) What is the maximum amount by which the spring will be stretched?

A Note on Units. Because fundamental properties of the system, such as the criterion for critical
damping, do not depend on units, it is worthwhile to express properties in terms of dimensionless
quantities. Since ω0 t is dimensionless, the dimensions of ω0 are (time)−1 . Because the dimensions of
(γ/m)x0 are the dimensions of x00 , the dimensions of γ/m must agree with the dimensions of x00 /x0 , i.e.
(time)−1 . It follows that the quantity
γ/m
ζ=
2ω0
is dimensionless (that is, it is independent of units). In terms of ζ, the differential equation (8.4) can be
written in the form
x00 + 2ζω0 x0 + ω02 x = 0 , (8.6)
and the characteristic polynomial can we written (completing the square)
r2 + 2ζω0 r + ω02 = (r − ζω0 )2 − ω02 (ζ 2 − 1) .
Since the roots are
p r
−γ ± γ 2 − 4mk γ γ2 
2 = −ζ ±
p 
2−1 ω ,
r1 , r2 = =− ± − ω0 ζ 0
2m 2m 4m2
the four cases above can be expressed in the following dimensionless form:
ζ = 0 (undamped) , 0 < ζ < 1 (under damped) , ζ = 1 (critically damped) , ζ > 1 (over damped).
Estimating quantities from a graph. Engineers often describe under damped harmonic motion with
the formula
p
x(t) = A exp(−ζω0 t) cos(ωd t + φ) , where ωd = ζ − 1 ω0 ,
because both ζ and ωd can be measured in a straightforward way from two points on the graph of x(t).
To see this, suppose you measure the times and displacements, (t1 , x1 ) and (t2 , x2 ) at two consecutive

(t1 , x1 )
x6

(t2 , x2 )

t
-

Figure 8.5.
8.2. THE DAMPED HARMONIC OSCILLATOR 79

peaks of the graph of x(t). (See Figure 8.5). We can estimate ωd because of the approximately periodic
nature of x(t):
2π 2π
t2 − t1 = or ωd = .
ωd t2 − t1

The time difference T = t2 − t1 is called the quasi-period, and the frequency ωd = is called the
t2 − t1
quasi-frequency. Using this, we can compute as follows:
x1 A exp(−ζω0 t1 ) cos(ωd t1 + φ)
=
x2 A exp(−ζω0 t2 ) cos(ωd t2 + φ)
exp(−ζω0 t1 ) cos(ωd t1 + φ) exp(−ζω0 t1 )
= = = exp(ζω0 (t2 − t1 )) .
exp(−ζω0 t2 ) cos(ωd t1 + φ + 2π) exp(−ζω0 t2 )
Taking the natural logarithm gives a formula for ζω0 in terms of quantities that can be estimated from
the graph of x(t):    
x1 1 x1
∆ = ln = (t2 − t1 )ζω0 or ζω0 = ln .
x2 t2 − t1 x2
The quantity ∆ is called the logarithmic decrement. This gives a method for estimating the ratios γ/m
and k/m from the graph of the solution:
2π γ 2∆ k  γ 2
ωd = , = 2ζω0 = , and = ω02 = ωd2 − (8.7)
t2 − t1 m t2 − t1 m 2m

Exercise 8.8. The graph below shows the motion of an unforced damped harmonic oscillator, whose
solution can be written in the form x(t) = A exp(−ζω0 t) cos(ωd t + φ).

3 (0.7,2.96)
2

1
meters

(3.91,0.82)
0
(5.51,-0.43)
1

2
(2.3,-1.56)
0 2 4 6 8 10
seconds
(a) Use the measured values from the graph to find: ωd , ζ, and ω0 .
(b) Now write the differential equation that x(t) satisfies in the form x00 + (?) x0 + (?) x = 0, with the
appropriate numbers replacing the question marks.
(c) It is obvious from the graph that the solution satisfies the initial condition x(0) = 0. Use the original
formula, together with your measured values of (t1 , x1 ) to estimate A, and the initial condition x0 (0).
Exercise 8.9. Suppose that you are designing a new shock absorber for an automobile. The car has a
mass of 1000 kg (kilograms) and the combined effect of the springs in the suspension system is that of
a spring constant of 20000 N/m.

(a) Before a damping mechanism is installed in the car, when the car hits a bump it will bounce
up and down. How may bounces will a rider experience in the minute right after the car hits
a bump?
(b) Your job is to design a damping mechanism that eliminates oscillations when the car hits a
bump. What is the minimum value of the effective damping constant that can be used?
80 THE HARMONIC OSCILLATOR

(c) Suppose that at time t = 0 the car hits a bump. Immediately before that time the car was not
moving up and down and the effect of the bump is to add a vertical component to the speed of
the car of 1.0 meter/sec. How high will the car rise above its equilibrium position if you design
the system with the damping constant you found in part (b)?
CHAPTER 9

Solving Nonhomogeneous Differential Equations

The goal of this chapter is to develop a technique for finding the general solution to the nonhomogeneous
differential equation
L[y] = ay 00 + by 0 + cy = f (t) .
The technique is a generalization of the method of “undetermined coefficients” that we used in Chapter 3
to solve nonhomogeneous first order differential equations.

Before discussing the technique in general, it is instructive to work out an example.


Example 9.1. Consider the nonhomogeneous differential equation
L[y] = y 00 + 4y 0 + 3y = 10e7t .
We begin by looking for a particular solution of the form yp (t) = Ae7t . The computation
yp00 (t) + 4yp0 (t) + 3yp (t) = 72 Ae7t + 4 · 7Ae7t + 3Ae7t = (49 + 28 + 3)Ae7t = 80Ae7t = 10e7t
shows that A = 18 . So yp (t) = 18 e7t is a solution.

On the other hand, r2 + 4r + 3 = (r + 3)(r + 1) is the characteristic polynomial of the homogeneous


differential equation
L[y] = y 00 + 4y 0 + 3y = 0 .
Therefore,
yh (t) = C1 e−t + C2 e−3t
is the general solution of the homogeneous differential equation. But by the superposition principle (see
Equation (6.3))
L[yp (t) + yh (t)] = L[yp (t)] + L[yh (t)] = 10e7t + 0 = 10e7t .
Consequently, the function
1 7t
y(t) = e + C1 e−t + C2 e−3t
8
is the general solution.

For instance, to solve the initial value problem


L[y] = 10e7t , y(0) = 2 , y 0 (0) = 3 ,
choose C1 and C2 to satisfy the equations
1 7
y(0) = + C1 + C2 = 2 and y 0 (0) = − C1 − 3C2 = 3 .
8 8
This gives C1 = 31
8 and C2 = −2, so the function
1 7t 31 −t
y(t) = e + e − 2e−3t
8 8
solves the initial value problem.
81
82 SOLVING NONHOMOGENEOUS DIFFERENTIAL EQUATIONS

Computation similar to the ones we just did generalize. The general solution of the homogeneous
differential equation
L[y] = ay 00 + by 0 + cy = 0 .
is of the form
yh (t) = C1 y1 (t) + C2 y2 (t) ,
where y1 (t) and y2 (t) form a fundamental basis of solutions.

Now suppose that we have found a particular solution, say yp (t), of the nonhomogeneous differential
equation
L[y] = ay 00 + by 0 + cy = f (t). (9.1)
Then can then be written in the form
y(t) = yp (t) + yh (t) = yp (t) + C1 y1 (t) + C2 y2 (t) , (9.2)
where yp (t) is a particular solution of the nonhomogeneous differential equation.

To show this, assume that y(t) is any function with L[y(t)] = f (t). Then the difference y(t) − yp (t) is a
solution of the homogeneous differential equation as the following computation shows:
L[y(t) − yp (t)] = L[y(t)] − L[yp (t)] = f (t) − f (t) = 0 .
But every solution of the homogeneous differential equation is of the form yh (t). Consequently,
y(t) − yp (t) = C1 y1 (t) + C2 y2 (t) ,
for some choice of C1 and C2 . Hence, y(t) satisfies (9.2).

Solving the initial value problem


L[y] = f (t) , y(t0 ) = y0 , y 0 (t0 ) = y00 ,
then reduces to solving the following pair of equations:
C1 y1 (t0 ) + C2 y2 (t0 ) + yp (t0 ) = y0
C1 y10 (t0 ) + C2 y20 (t0 ) + yp0 (t0 ) = y00 .

The problem of finding y1 (t) and y2 (t) was addressed in the previous chapter. So we only need to find
techniques for finding a particular solution y = yp (t) of the nonhomogeneous equation
L[y] = ay 00 + by 0 + cy = f (t) .
Bu a particular solution, we mean a solution that does not involve any arbitrary constants like C1 and
C2 . This will become more clear as we work out more examples.

There are several approaches to finding a particular solution. Two will be addressed in these notes:

• Undetermined Coefficients
• Laplace Transforms.
Remark 9.1. There is a third approach, called variation of parameters. Because undetermined coeffi-
cients and Laplace transforms are sufficient in most cases, variation of parameters will not be included
in these notes. The interested reader can find a number of explanations of this method on the web.
9.1. UNDETERMINED COEFFICIENTS 83

9.1. Undetermined Coefficients

When the forcing function f (t) is of a special form, the method of undetermined coefficients reduces the
problem of finding a particular solution to a problem algebra. This method applies whenever f (t) is of
one of the forms
f (t) = p(t)ert
or
p(t) sin(ωt)ert + q(t) cos(ωt)ert ,
where p(t) and q(t) are polynomials or when f (t) is a sum of terms like these.

Here are some examples of differential equations where the method applies:

(1) y 00 + 2y 0 − y = (3t + 1)e2t


(2) y 00 + 4y = (1 − t3 ) cos(3t)
(3) y 00 − 2y 0 + y = (1 + t + t2 )e3t cos(3t) + te3t sin(3t)
(4) y 00 − y = (1 + 2t)et + (t2 sin(3t) + (2 − t + t2 ) cos(3t))
Example 9.2. Find a particular solution of the nonhomogeneous differential equation
L[y] = y 00 + 3y 0 + 2y = (t − 2) e2t .
Solution The function f (t) = (t − 2) e2t is of the form p(t)ert , where p(t) = t − 2, a polynomial of
degree 1, and r = 2. Let
yp (t) = (At + B)e2t ,
where A and B are to be determined. A direct computation gives:
L[yp ] = {12A t + (7A + 12B)} e2t .
Observe that yp will satisfy the equation
L[yp ] = (t − 2) e2t ,
provided that A and B satisfy the equation
{12A t + (7A + 12B)} e2t = (t − 2) e2t
for all t. Equating like terms results in two equations in two unknowns:
12A = 1 and 7A + 12B = −2 .
The first equation gives A = 1/12. Substituting this value into the second equation gives B = −31/144.
We conclude that  
1 31
yp (t) = t− e2t .
12 144
is a particular solution.
Example 9.3. Find a particular solution of
L[y] = y 00 + 3y 0 + 2y = 1 − 2t .
Solution Set
yp (t) = (At + B)e0t = (At + B) .
Comparing
L[yp ] = (3A + 2B) + 2A t .
with the function f (t) = 1 − 2t yields the two equations
3A + 2B = 1 and 2A = −2 .
84 SOLVING NONHOMOGENEOUS DIFFERENTIAL EQUATIONS

Solving the second equation gives A = −1 and substituting that value into the first equation gives B = 2.
Hence
yp = 2 − t .
Example 9.4. Find a particular solution of
L[y] = y 00 + 3y 0 + 2y = f (t) = (t2 − 2) e2t .

Solution In this case p(t) = t2 − 2, a polynomial of degree 2, so set


yp (t) = At2 + Bt + C e2t


L[yp ] = 12A t2 + (14A + 12B) t + (2A + 7B + 12C) e2t




and
L[yp ] = (t2 − 2) e2t .
Equating coefficients gives the three equations

 12A = 1

14A + 12B = 0

2A + 7B + 12C = −2 .

The first equation shows A = 1/12.


The second (together with A = 1/12) forces B = −7/72.
And the third (together with A = 1/12 and B = −7/12) forces C = −107/864.

Hence,
 
1 2 7 107
yp (t) = t − t− e2t .
12 72 864
Example 9.5. Find a particular solution of
L[y] = y 00 + 3y 0 + 2y = (t − 2) e−2t .
Solution In this case, the function yp (t) = (At + B)e−2t cannot be a particular solution. Indeed, a
simple computation gives
L[(At + B) e−2t ] = −Ae−2t ;
but
L[(At + B) e−2t ] = (t − 2) e−2t .
Clearly, no choice of A and B can yield (t − 2)e−2t . T The solution to this problem is to multiply by
the original guess by t:
yp (t) = t (At + B) e−2t .
Then
L[t(At + B) e−2t ] = {−2At + (2A − B)} e−2t .
The coefficients A and B can then be chosen to satisfy the equation
{−2At + (2A − B)} e−2t = (t − 2)e−2t .
Comparing terms as before yields two equations
−2A = 1 and 2A − B = −2 ;
and solving for A and B gives A = −1/2 and B = 1. Hence,
yp (t) = t(−t/2 + 1)e−2t = (t − t2 /2) e−2t .
9.1. UNDETERMINED COEFFICIENTS 85

Example 9.6. Find a particular solution to the differential equation


L[y] = y 00 − 6y 0 + 9y = (t − 2)e3t .
Solution Because r2 − 6r + 9 = (r − 3)2 ,
L[e3t ] = 0 and L[te3t ] = 0 .
Consequently, the function yp (t) = (At + B)e3t cannot be a solution. Neither can yp (t) = t(At + B)e3t
because
L[t(At + B)e3t ] = 2Ae3t
This suggests multiplying by t2 , and setting yp (t) = t2 (At + B)e3t . A short computation shows that
L[yp ] = (6At + 2B)e3t = (t − 2)e3t ,
Comparing coefficients shows that
yp (t) = t2 (t/6 − 1)e3t
is a particular solution.
Example 9.7. Find a particular solution for
L[y] = y 00 − 6y 0 + 13y = 5 cos(2t)e4t
Solution

The characteristic polynomial r2 − 6r + 13 has roots 3 ± 2 i. So the general solution of L[y] = f (t) has
the form
y(t) = yp (t) + {C1 cos(2t) + C2 sin(2t)} e3t .
Substituting
yp (t) = (A cos(2t) + B sin(2t)) e4t
into the differential equation yields (after a lengthy computation)
L[yp ] = {(A + 4B) cos(2t) + (−4A + B) sin(2t)} e4t
= 5 cos(2t) e4t .
Equating coefficients gives the system of equations
A + 4B = 5 and − 4A + B = 0
whose solution is A = 5/17 and B = 20/17. Hence, the function
 
5 20
yp (t) = cos(2t) + sin(2t) e4t
17 17
is a particular solution.
Example 9.8. Find the general solution of the differential equation
L[y] = y 00 − 6y 0 + 13y = 5 cos(2t)e4t − 2t sin(2t)e4t .
Solution Let yp (t) = (A + Bt)e4t cos(2t) + (C + Dt)e4t sin(2t). A lengthy computation gives
L[yp ] = {(A + 2B + 4C + 4D) + (B + 4D)t} cos(2t)e4t
+ {(−4A − 4B + C + 2D) + (−4B + D)t} sin(2t)e4t
Comparing coefficients leads to the following system of equations:

A + 2B + 4C + 4D


=5
B + 4D =0
−4A − 4B + C + 2D = 0


−4B + D = −2 .

86 SOLVING NONHOMOGENEOUS DIFFERENTIAL EQUATIONS

One finds (after some computation) that


67 8 344 2
A=− , B= , C= , D=−
289 17 289 17
and thus    
67 8 344 2
yp (t) = − + t cos(2t)e4t + − t sin(2t)e4t
289 17 289 17
The roots of the characteristic polynomial r2 − 6r + 13 are 3 ± 2i. Therefore, the general solution is
   
67 8 4t 344 2
y= − + t cos(2t)e + − t sin(2t)e4t
289 17 289 17
+ {C1 cos(2t) + C2 sin(2t)} e3t .

The general case. The approach presented in the above example can be distilled into a general
algorithm, called the method of undetermined coefficients. Consider the differential equation
L[y] = ay 00 + by 0 + cy = f (t) ,
(
p(t)er0 t
where the forcing function f (t) is one of the two forms f (t) = ,
{p(t) cos(ωt) + q(t) sin(ωt)} er0 t
with
p(t) = p0 + p1 t + p2 t2 + · · · + pn tn
q(t) = q0 + q1 t + q2 t2 + · · · + qn tn .

(1) Let r1 and r2 be the the roots of the characteristic polynomial ar2 + br + c.
(2) If f (t) = p(t)er0 t then let

r0 t
P (t)e
 if r0 6= r1 , r2
yp (t) = tP (t)er0 t if r0 = r1 and r0 6= r2

2
t P (t)er0 t if r0 = r1 = r2 (double root),
where P (t) = A0 + A1 t + A2 t2 + · · · + An tn .
If f (t) = {p(t) cos(ωt) + q(t) sin(ωt)} er0 t then set
(
{P (t) cos(ωt) + Q(t) sin(ωt)} er0 t if r0 + ω i 6= r1 , r2
yp (t) = r0 t
t {P (t) cos(ωt) + Q(t) sin(ωt)} e if r0 + ω i = r1 or r2
(
P (t) = A0 + A1 t + A2 t2 + · · · + An tn
where
Q(t) = B0 + B1 t + B2 t2 + · · · + Bn tn .

(3) Equate coefficients of powers of t in the equation L[yp (t)] = f (t) to get a linear system of
equations in the unknown coefficients Ai and Bi .
(4) Solve the system to get P (t) (and Q(t)), and thus yp (t).
(5) If
L[y] = f (t) = f1 (t) + f2 (t) ,
where f1 (t) and f2 (t) are both of the above form (but with different values of n, r0 and/or ω),
then set
yp (t) = yp1 (t) + yp2 (t) ,
where
L[yp1 ] = f1 (t) and L[yp2 ] = f2 (t) .
9.2. UNDETERMINED COEFFICIENTS USING COMPLEX-VALUED FUNCTIONS 87

9.2. Undetermined Coefficients Using Complex-valued Functions

When f (t) involves trig functions, the algebra involved in applying the method of undetermined coeffi-
cients can be messy. In such cases, using complex-valued functions often simplifies the computations.

Recall from Section 5 that the complex exponential function is the function
e(ρ+iω)t = (cos(ωt) + i sin(ωt))eρt ,
where ρ and ω are real numbers. Its derivative satisfies the identity
de(ρ+iω)t
= (ρ + ωi)e(ρ+iω)t .
dt
Consequently, its second derivative can be easily evaluated:
d2 e(ρ+iω)t
= (ρ + ωi)2 e(ρ+iω)t .
dt2
As already mentioned in Section sec:complex-functions, this fact greatly simplifies computations of
derivatives of functions of the form
x(t) = a cos(ωt)eρt + b sin(ωt)eρt .
Example 9.9. Find a particular solution of the differential equation
y 00 + y 0 + y = (cos(t) − sin(t))e2t
 
Solution Since (cos(t) − sin(t))e2t = Re (1 + i)e(2+i)t , there is a particular solution of the form
yp (t) = Re (zp (t)), where zp (t) is a particular solution solution of
z 00 + z 0 + z = (1 + i)e(2+i)t .
Set zp (t) = Ae(2+i)t . Then
zp00 (t) + zp0 (t) + zp (t) = (2 + i)2 + (2 + i) + 1 Ae(2+i)t


= (6 + 5i)Ae(2+i)t = (1 + i)e(2+i)t
Solving for A gives
1+i 11 1
A= = + i.
6 + 5i 61 61
Hence,
 
11 1
zp (t) = + i e(2+i)t .
61 61
Taking the real part of zp (t) gives a particular solution of the original differential equation:
 
11 1
yp (t) = Re (zp (t)) = cos(t) − sin(t) e2t .
61 61

Example 9.10. Solve the initial value problem


u00 + ω02 u = sin(ωt) , u(0) = u0 (0) = 0 ,
for ω 6= ω0 .

Solution The general solution of the corresponding homogeneous differential equation is


uh (t) = C1 cos(ω0 t) + C2 sin(ω0 t) ,
88 SOLVING NONHOMOGENEOUS DIFFERENTIAL EQUATIONS

so the general solution of the original differential equation is of the form


u(t) = C1 cos(ω0 t) + C2 sin(ω0 t) + up (t) .
iωt
Since sin(ωt) = Re (−ie ), let up (t) = Re (zp (t)), where zp (t) = Aeiωt is a solution of the complex
differential equation
z 00 + ω0 z = −i eiωt .
To find A substitute zp (t) into the complex differential equation:
zp00 (t) + ω02 zp (t) = (−ω 2 + ω02 )Aeiω t = −ieiωt
−i 1
If follows that A = and up (t) = Re (zp (t)) = 2 sin(ωt). The general solution is, therefore,
ω02 −ω 2 ω0 − ω 2
1
u(t) = C1 cos(ω0 t) + C2 sin(ω0 t) + 2 sin(ωt) .
ω0 − ω 2
The initial conditions
ω
u(0) = C1 = 0 and u0 (0) = ω0 C2 + =0
ω02 − ω 2
ω/ω0
force C1 = 0 and C2 = . Consequently,
(ω 2 − ω02 )
ω/ω0 1 1
u(t) = 2 sin(ω0 t) + 2 sin(ωt) = 2 ((ω/ω0 ) sin(ω0 t) − sin(ωt)) .
2
(ω − ω0 ) ω0 − ω 2 (ω − ω02 )
Example 9.11. Find a particular solution of the differential equation
u00 + ω02 u = sin(ω0 t) .
Solution Proceeding as before, the particular solution will be the real part of a particular solution of
the complex differential equation
z 00 + ω02 z = −ieω0 it .
The function zp (t) = Aeω0 it won’t work since zp00 (t) + ω02 zp (t) = 0. So try the next best thing: zp (t) =
Ateω0 it :
zp0 (t) = A(1 + ω0 it)eω0 it =⇒ zp00 (t) = A ((ω0 i) + (1 + ωo it)ω0 i) eω0 it = A 2ω0 i − 02 t eω0 it ,


Then
zp00 (t) + ω02 zP (t) = A 2ω0 i − ω02 t + ω02 t eω0 it = (2ω0 i)Aeω0 it = −ieωp it .

−i
Solving for A gives A = 2ω0 i = − 2ω1 0 . Hence, the function
 
1 ω0 it t
up (t) = Re − te =− cos(ω0 t)
2ω0 2ω0
is a particular solution.
Exercise 9.1. Solve each of the following differential equations and initial value problems.

(a) y 00 + 3y = t2 + 1.
(b) y 00 + y = 2 sin(t), y(0) = 0, y 0 (0) = 0.
(c) y 00 + y 0 + y = et sin(t).
(d) y 00 − y 0 = et
(e) y 00 − 4y = e2t , y(0) = 1, y 0 (0) = 1.
(f) y 00 − 4y 0 + 4y = e2t
(g) y 00 + 4y = 3 cos(t) + 4 sin(t), y(0) = 0, y 0 (0) = 0.
(h) y 00 + 4y = 12 cos(4t) − 12 sin(4t), y(0) = 0, y 0 (0) = 0.
(i) y 00 − 2y 0 + y = sin(2t)e−t .
CHAPTER 10

The Driven Harmonic Oscillator

In an earlier chapter, we studied the undriven harmonic oscillator. If there are additional time-dependent
(“external”) forces on the object, mechanical system is then modeled by the nonhomogeneous differential
equation
m x00 + γ x0 + k x = F (t) , (10.1)
where F (t) denotes the external “driving force.” The most important case is when F (t) is of the form
F (t) = F0 cos(ωt) ,
where the phenomenon of “resonance” occurs. Most of this chapter is devoted to understanding resonance
and applications where it occurs.

10.1. Resonance

Consider the special case where there is no damping. The mechanical system is then modeled on the
differential equation
F0
x00 + ω02 x = cos(ωt) . (10.2)
m
Figure 10.1 indicates how such an external force might be applied. As we are about to discover, when
the frequency ω of the driving force equals ω0 (the natural frequency), the external force adds energy
to the system, increasing the amplitude of the oscillations (see Figure 10.2). This is the phenomenon
called resonance.

Figure 10.1. A simple pendulum with a driving force. For small angles, θ satisfies a
differential equation of the form θ00 + ω02 θ = A cos(ωt).

Applying the techniques of the previous chapter, shows that the solution of (10.2) can we written in the
form
x(t) = xp (t) + xh (t) = xp (t) + A cos(ω0 t + φ),
where xp (t) is a particular solution. There are two cases consider: ω 6= ω0 and ω = ω0 :
89
90 THE DRIVEN HARMONIC OSCILLATOR


Case 1: ω 6= ω0 . Notice that (F0 /m) cos(ωt) = Re (F0 /m)eiωt , so try xp (t) = Re (zp (t)) where zp (t) is
a solution of
zp00 + ω02 zp = (F0 /m)eiωt
Substitute zp (t) = Ceiωt into the differential equation to get
zp00 + ω02 zp =(−ω 2 + ω02 )Ceiωt = (F0 /m)eiωt .
 
F0 /m F0 /m iωt F0 /m
Hence, C = 2 2
and xp (t) = Re 2 2
e = 2 cos(ωt).
ω0 − ω ω0 − ω ω0 − ω 2

Case 2: ω = ω0 . Try zp (t) = Cteiω0 t Then


zp00 + ω02 zp = (2ω0 i − ω02 t Ceiω0 t + ω02 Cteiω0 t = 2ω0 iCe−ω0 t = (F0 /m)eiω0 t

   
F0 /m F0 /m iω0 t F0 /m
Therefore, C = and xp (t) = Re te = t sin(ω0 t).
2ω0 i 2ω0 i 2ω0

This shows that the general solution of (10.2) is


F /m

 20
 cos(ωt) + A cos(ω0 + φ) for ω 6= ω0
 ω0 − ω 2


x(t) =   (10.3)
F /m

 0


 t sin(ω0 t) + A cos(ω0 + φ) for ω = ω0 .
2ω0
This shows that regardless of the initial conditions, if the frequency ω of the forcing function equals the
natural frequency ω0 of the system, then the amplitude of the oscillations of the system increase without
bound—this is he phenomenon on known as resonance

The special case where the system starts at rest at time t = 0 and a periodic force is applied is particularly
instructive. In this case, x(t) is the solution of the initial value problem:
F0
x00 + ω02 x = cos(ωt) , x(0) = 0 , x0 (0) = 0
m
When ω = ω0 ,
F0 /m
x(t) = t sin(ω0 t) + C1 cos(ω0 t) + C2 sin(ω0 t) .
2ω0
The initial condition x(0) = 0 implies C1 = 0 and x0 (0) = 0 implies C2 = 0. Hence,
F0 /m
x(t) = t sin(ω0 t)
2ω0
6 ω0 , the general solution of the differential equation is then
When ω =
 
F0 /m
x(t) = cos(ωt) + C1 cos(ω0 t) + C2 sin(ω0 t) .
ω02 − ω 2
F0 /m
The initial conditions x(0) = + C1 = 0 and x0 (0) = C2 = 0 together give
ω02 − ω 2
F0 /m
x(t) = (cos(ωt) − cos(ω0 t)) .
ω02 − ω 2
Applying a trig identity from Appendix A leads to the formula
     
2F0 /m ω0 − ω ω0 + ω
x(t) = sin t sin t .
ω02 − ω 2 2 2
When ω is close to ω0 , the term in braces corresponds to a slowly varying amplitude, and the term
(ω0 + ω)/2 ≈ ω0 corresponds to a high frequency. This leads to the phenomenon of beats, which is
10.2. FORCED OSCILLATIONS WITH DAMPING 91

illustrated in Figure 10.2 . As ω approaches ω0 the frequency of the beats decreases, leading to the
solution when ω = ω0 :
     
2F0 /m ω0 − ω ω0 + ω F0 /m
lim sin t sin t = t sin(ω0 t) .
ω→ω0 ω02 − ω 2 2 2 2ω0
To see this, apply l’Hôpital’s to the expression in braces:
 
(ω0 −ω)
(2F /m) sin t (F0 /m)t cos ω02−ω t
   
2F0 /m ω0 − ω 0 2 F0 /m
lim 2 2
sin t = lim = lim = t
ω→ω0 ω0 − ω 2 ω→ω 0 (ω0 + ω)(ω0 − ω) ω→ω 0 (ω0 + ω) 2ω0

8 8
6 x = x(t), = 1.8 6 x = x(t), = 1.9
4 4
2 2
0 0
x

2 x 2
4 4
6 6
8 8
10 10
0 10 20 30 40 50 60 70 80 90 0 10 20 30 40 50 60 70 80 90
t t
20 8
15 x = x(t), = 2.0 6 x = x(t), = 2.1
10 4
5 2
0 0
x

5 2
10 4
15 6
20 8
25 10
0 10 20 30 40 50 60 70 80 90 0 10 20 30 40 50 60 70 80 90
t t

Figure 10.2. Graphs of solutions of x00 + 4x = cos(ωt), x(0) = x0 (0) = 0 for various
values of ω. “Resonance” occurs when ω = 2.0.

10.2. Forced Oscillations with Damping

The analysis of a forced, damped harmonic oscillator is similar to the analysis of the forced (undamped)
harmonic oscillator. In this case, the system is modeled by the differential equation
m x00 + γ x0 + k x = F0 cos(ω t)
The general solution is of the form
x(t) = xp (t) + C1 x1 (t) + C2 x2 (t) ,
where x1 (t) and x2 (t) are solutions of the homogeneous differential equation and xp (t) is a particular
solution of the nonhomogeneous equation.
92 THE DRIVEN HARMONIC OSCILLATOR

For γ > 0 there are three cases, based on the number and type of the roots of the characteristic
polynomial mr2 + γr + k:
p r
−γ ± γ 2 − 4mk γ γ2
r1 , r2 = =− ± − ω02 ,
2m 2m 4m2
p
where ω0 = k/m (natural frequency). These case, however, only effect the form xh (t), In all three
cases, the term
xh (t) = C1 x1 (t) + C2 x2 (t)
has the property
lim xh (t) = 0 .
t→∞
The function xh (t) is called a transient because when t is large it can be ignored. For t sufficiently large
solution is approximately given by xp (t). That is
x(t) ≈ xp (t) for large t
Using the method of undetermined coefficients allows us to write xp (t) in the form
xp (t) = R cos(ωt + φ) .
The function xp (t) is called the steady state solution. The amplitude R of the oscillations caused by the
forcing function depends on ω, as does the phase shift φ. These two quantities characterize the response
of the mechanical system to the forcing function.

The computation of xp (t) proceeds as follows: Set xp (t) = Re (zp (t), where zp (t) = Ceiωt . Substitute
zp (t) into the equation mzp00 + γzp0 + kzp = F0 eiωt and note that k = mω02 to get
(m(iω)2 + γ(iω) + k)Ceiωt = (m(ω02 − ω 2 ) + iγω)Ceiωt = F0 eiωt .
Therefore,
(m(ω02 − ω 2 ) + iγω)C = F0 .
Putting the coefficient of C into polar form gives
q 
2 2 2 2 2 2 iδ
m (ω0 − ω ) + γ ω e ) C = F0 ,
γω
where tan(δ) = , 0 < δ < π Hence,
m(ω02− ω2 )
F0
C=p e−iδ .
(m2 (ω02 − ω 2 )2 + γ2)
Consequently,
!
F0 −iδ iωt F0
xp (t) = Re p e e =p cos(ωt − δ) (10.4a)
(m2 (ω02 − ω 2 )2 + γ2) 2
(m (ω0 − ω 2 )2 + γ 2 )
2

and
F0
R= p and φ = −δ (10.4b)
(m2 (ω02 − ω 2 )2 + γ 2 )

Resonant frequency. By analogy with the undamped case, it is useful to find the value of ω that
results in the maximum amplitude of the oscillations in xp (t). In other words, we seek the value of ω
that maximizes R. This is again called the resonant frequency.

To get a feel for what happens, we set m = 1, k = 1, and F0 = 1, and graph R for a increasing values
of the damping constant γ. As one would expect, the maximum value of R decreases as the damping
constant increases.
10.2. FORCED OSCILLATIONS WITH DAMPING 93

2.5 2.5 2.5


R = R( ), = 0.5 R = R( ), = 1.0 R = R( ), = 1.5
2.0 2.0 2.0
1.5 1.5 1.5
R

R
1.0 1.0 1.0
0.5 0.5 0.5
0.0 0.0 0.0
0.0 0.5 1.0 1.5 0.0 0.5 1.0 1.5 0.0 0.5 1.0 1.5

Figure 10.3. The amplitude R for three values of damping constant γ. As γ increases,
the value of ω maximizing R decreases and eventually becomes 0, corresponding to a
constant applied force.

The resonant frequency coincides with the value of ω at which the denominator
f (ω) = m2 (ω02 − ω 2 )2 + γ 2 ω 2 .
of R achieves its minimum. Differentiating with respect to ω gives
γ2
  
f 0 (ω) = 2ω γ 2 + 2m2 (ω 2 − ω02 ) = 4m2 ω ω 2 − ω02 −

.
2m2
r
γ2
The critical values of f (ω) are, therefore, ω = 0 and ω = ω02 − .
2m2
2
γ2

γ/m
Conclusion: If ω02 > or (equivalently) if < 2, the resonant frequency is
2m2 ω0
r s 2
2

2 γ 1 γ/m
ωmax = ω0 − = ω0 1 − .
2m2 2 ω0
Otherwise, the maximum amplitude is achieved for ω = 0, corresponding to a constant driving force.

y(t) = 5 cos(ωt) cm y(t) 25


y = 5cos( t)
5
0
20
k = 4 dynes/cm -5 x = Rcos( t + )
15
10
x, y (cm)

5
x(t)
m = 1 gram
0
-5 5
0
5
10
γ = 1 gram/sec
15
0 1 2 3 4 5 6 7 8 9
t (sec)
Figure 10.4. The oscillating plunger (dashed blue sine curve) causes the mass m to
oscillate (red sine curve).
94 THE DRIVEN HARMONIC OSCILLATOR

Example 10.1. Consider the mechanical system pictured in Figure 10.4. Assume that in its rest con-
figuration x = 0 and y = 0, where the forces exerted on the mass by gravity and the spring cancel. The
net force exerted on the mass by gravity, the spring, and the damping mechanism is then
F = −k(x − y(t) − γx0 .
Applying Newton’s second law of motion shows that the position of the mass x = x(t) satisfies the
differential equation
mx00 = −γ x0 − k(x − y(t)) or mx00 + γ x0 + k x = ky(t) .
Assume for simplicity that m = 1 gram, k = 4.0 dynes/cm, and γ = 1.0 grams/sec.

Finally assume that the plunger at the top of the figure moves up and down according to the rule
y(t) = 5 cos(ωt) cm; causing the mass to also move up and down. Ignoring transients, x(t) is of the form
x(t) = R cos(ωt + φ)
where both R and φ depend on ω. Find the value of ω that maximizes R.

Solution Set x(t) = Re (z(t)), where z(t) satisfies the differential equation
mz 00 + γ z 0 + k z = k 5eiωt .


Using the values of m, γ, and k above this simplifies to


z 00 + z 0 + 4z = 20 eiωt .
Substituting z(t) = Aeiωt into this equation gives
{(4 − ω 2 ) + iω}}A = 20 ,
whose polar form is
p ω
(4 − ω 2 )2 + ω 2 eαi A = 20 , where tan(α) = , and 0 < α < π .
4 − ω2
It follows that
20
z(t) = p e−iα eiωt
(4 − ω 2 )2 + ω 2
Consequently, setting φ = −α, gives
20
x(t) = R cos(ωt + φ) = p cos(ωt − α) .
(4 − ω 2 )2 + ω 2
To maximize R is suffices to minimize f (ω) = (4 − ω 2 )2 + ω 2 , which can be accomplished by solving
f 0 (ω) = −4(4 − ω 2 )ω + 2ω = 0
p
for ω. We can ignore the spurious solutions ω = 0, and ω = − 7/2. (Why?) Hence,
r  
7 20 ω
ω= ≈ 1.87sec−1 , R = p ≈ 10.33 and φ = − arctan ≈ −1.31.
2 (4 − 7/2)2 + (7/2) 4 − ω2
Thus, the amplitude of the oscillations in x is about twice the amplitude of the oscillations in y. (See
Figure 10.4.)

Example 10.2. (Automobile Struts) A similar analysis can be done for the mechanical system
modeling the struts on an automobile. Place the x-axis and the y-axis so that x = y = 0 at equilibrium,
so the forces of gravity and the spring cancel—for this reason we make no mention of the force of gravity.
Then, as shown in Figure 10.5, the spring force Fspr and the damping force Fdamp both depend on the
relative values of x and y. Newton’s second law of motion then implies that the function x = x(t) is a
solution of the differential equation
mx00 = −γ(x0 − y 0 (t)) − k(x − y(t)) or m x00 + γ x0 + k x = γ y 0 (y) + k y(t) .
10.2. FORCED OSCILLATIONS WITH DAMPING 95
x 6

m -
Fspr = −k (x − y(t))
Fdamp = −γ (x0 − y 0 (t))
γ y
k 6
1500
m= kg
4
- k = 50000 N/m
γ = 8660 kg/sec
=(twice critical damping)

Figure 10.5. Left: sketch of strut on an automobile. Right: Simplified model of the
system. The values of m, k, and γ in the figure are similar to those found in automobiles.
The mass is divided by four because the weight of an automobile is distributed over four
wheels.

Assume that the automobile is moving at a constant speed along a straight (but not flat!) road. For
simplicity, also assume that the rise and fall of the road is given by the sine function
y(t) = a cos(ωt) ,
where a > 0 is a constant and ω depends on the speed of the car. The steady-state solution is then
x(t) = aR cos(ωt + φ) ,
where both R and φ have yet to be determined. Since both R and φ are independent of a, there is no
loss of generality in setting a = 1.

1.4
1.2 1.2
1.15
1 1.1
1.05
0.8 1
R(ω)

0.95
0.6 0 0.5 1 1.5 2 2.5 3
0.4
0.2
0
0 10 20 30 40 50
ω/2π (frequency in Hz)

Figure 10.6. The maximum response is slightly above 1. This implies that the
amplitude of oscillations in the road is never significantly amplified by the struts, and,
in fact, it is reduced except at low frequencies below 2.7 Hz (cycles per second).

As in earlier examples, set x(t) = Re (z(t)), where z(t) = Aeiωt is a solution of the complex differential
equation
m z 00 + γ z 0 + kz = k eiωt + γ (eiωt )0 = (k + iγω)eiωt
Proceeding as above we arrive at the equation (−mω 2 + k) + γ ω i Aeiωt = (k + γ ωi)eiωt . Hence,


k+γωi ω 2 + (γ/m) ω i
z(t) = eiωt = 2 0 2 eiωt
m(ω02 2
− ω ) + γωi (ω0 − ω ) + (γ/m)ωi
96 THE DRIVEN HARMONIC OSCILLATOR

and
2
s
ω04 + (γ/m)2 ω 2

ω0 + (γ/m) ω i
R = 2 2
=
2 .
(ω − ω ) + (γ/m)ωi
0
(ω − ω 2 )2 + (γ/m)2 ω 2
0
Figure 10.6 shows the graph of R for the numerical values of m, γ, and k given in Figure 10.5.

m
γ k

m
k

m
k γ

x(t) y(t) = cos(ωt)

Figure 10.7. Three configurations of the driven damped oscillator. From top to
bottom: 
 ky(t) = k cos(ωt)

mx00 + γx0 + kx = f (t) = ky(t) + γy 0 (t) = k cos(ωt) − γω sin(ωt)
γy 0 (t) = −γω sin(ωt)


Example 10.1 above is an instance of the first configuration. Example 10.2 is an instance
of the second configuration.
10.2. FORCED OSCILLATIONS WITH DAMPING 97

Exercise 10.1. A weight of mass m = 5 kg is suspended from a spring with unknown spring constant
k. The weight is free to move up and down. Ignoring friction, its position relative to its equilibrium
position satisfies a differential equation of the form
mx00 + kx = 0 ,
where t denotes time measured in seconds and x denotes its position measured in meters. To find the
spring constant, the spring is set in motion and the graph of u(t) plotted. The result is shown in the
following figure (horizontal axis is t, vertical axis is x):

x = x(t)
1.0
0.5
0.0
x

0.5
1.0
1.5
0 1 2 3
t
In a subsequent experiment, an external force of the form F (t) = F0 cos(ωt) is applied to the mass so
that the function u(t) now obeys the differential equation
mx00 + kx = F0 cos(ωt) .
The graph of the position x(t) in that experiment is shown in the graph below.

0.08 x = x(t)
0.06
0.04
0.02
x

0.00
0.02
0.04
0.06
0.08
0 1 2 3
t
(a)Estimate the spring constant k. (Your answer can again most easily be expressed in terms of π.)
(b) Using your estimate of k, estimate as best you can the frequency ω of the applied force. (Your
answer can again most easily be expressed in terms of π.)
(c) Estimate as best you can the amplitude F0 of the applied force.
98 THE DRIVEN HARMONIC OSCILLATOR

Exercise 10.2. A simple pendulum of mass m and length L is hinged at a point P (see figure). If
the wheel at the left of the figure rotates at a rate of ω radians/second it forces the point P to move
periodically back and forth. For small angle θ (where sin(θ) ≈ θ) the angle θ satisfies the differential
equation
d2 θ
L 2 + gθ = Aω 2 cos(ωt) .
dt
2
Assume, for simplicity that L = 1 meter, A = 1 meter, ω = 1 sec−1 and g = 9.8 meter/sec . Find the
solution that satisfies the initial conditions θ(0) = θ0 (0) = 0.

θ L

Exercise 10.3. A ball of mass 1 kilogram moves in a viscous fluid. The viscous force on the ball is given
by −γv, where v is the speed of the ball measured in meters per second, and γ = 3 newton-sec/meter.
An external force is applied to the ball along a fixed axis and with magnitude
F (t) = 2 cos(t) N
(t is time measured in seconds.) Let y(t) be the displacement of the ball along the axis of the external
force and assume that at time t = 0 the ball is at rest and y = 0. Find y(t). Ignore gravity.

Exercise 10.4. A spring-mass system has spring constant 3 N/m (i.e. 3 Newtons per meter). A weight
of mass 2 kg is attached to the spring and the motion takes place in a viscous fluid that offers a resistance
(measured in Newtons) numerically equal to twice the magnitude of the instantaneous velocity (measured
in meters per second).

Let u denote the displacement of the weight from its equilibrium position. If the system is driven by an
external force of 3 cos(3t) − 2 sin(3t) N, determine the formula for u(t) ignoring all “transients,” i.e. u(t)
is the steady-state solution. Express your answer in the form u(t) = A cos(ωt + φ).

Exercise 10.5. Find the steady state solution x(t) = R cos(ωt + φ) for the bottom configuration shown
in Figure 10.7.
Part 3

Laplace Transforms
CHAPTER 11

Laplace Transforms

This chapter is an introduction to Laplace transforms, which provide an alternate way to solve initial
value problems of the form
(
L[y] = ay 00 + by 0 + cy = f (t) , a, b, c constant
(11.1)
y(0) = y0 , y 0 (0) = y00
that is particularly useful when the forcing function f (t) has discontinuities. The idea is to transform
the initial value problem into a algebraic equation, solve the algebraic equation for the transform of the
solution, and then inverse transform to obtain the solution of the initial value problem.

More precisely, the Laplace transform turns the initial value problem (11.1) into the equation
(as2 + bs + c)Y (s) = a y0 s + (b y0 + a y00 ) + F (s) , (11.2)
where Y (s) is the Laplace transform of y(t) and F (s) is the Laplace transform of f (t). Solving Equa-
tion (11.2) for Y (s) gives
a y0 s + (b y0 + a y00 ) F (s)
Y (s) = 2
+ 2 , (11.3)
as + bs + c as + bs + c
an explicit formula for the Laplace transform of the solution. Computing the inverse Laplace transform
then solves the initial value problem.

Putting this idea into practice requires knowing how to compute F (s) from f (t) and how to compute
y(t) from Y (s). In much the same way that derivatives and integrals are computed from a few basic
properties (e.g. the product rule and integration by parts) together with a table of integrals, so can
Laplace transforms and inverse Laplace transforms be computed from a few basic rules, together with a
table of Laplace transforms (see Appendix C).

11.1. Computing Laplace transforms

Suppose f (t) is a function defined for all t with 0 ≤ t < ∞. Its Laplace transform is the function
Z ∞ Z A
L {f } = F (s) = e−st f (t) dt = lim e−st f (t) dt (11.4)
0 A→∞ 0
15
provided this integral converges.
Remark 11.1. The values of f (t) for t < 0 have no effect on its Laplace transform. When we use
Laplace transforms, we are only interested in solving the initial value problem (11.1) for t ≥ 0, that is, in
the future. We get no information about the past. For all practical purposes, we might as well assume
that f (t) = 0 for t < 0.
15Convergence is only briefly discussed in these notes. For virtually all functions encountered in practice, the integral
converges when s is sufficiently large.

101
102 LAPLACE TRANSFORMS

Notation. The notation L {f } is awkward. It is often more convenient to denote the Laplace transform
of f (t) by F (s). Similarly, we write Y (s) = L {f }, G(s) = L {g} (s), etc. For instance, L {cos(t)} and
L {cos} both denote the Laplace transform of the function cos.

Example 11.1. Here are three cases where the Laplace transform can be directly computed from the
definition.

(a) If f (t) = 1, then


Z ∞ A A
−e−st
Z
1 1
F (s) = e−st dt = lim e−st dt = lim = lim −e−st + 1 = .
0 A→∞ 0 A→∞ s
0
A→∞ s s
Therefore,
1
L {1} =
s
The integral converges to 1/s for s > 0 and diverges for s < 0.
(b) If f (t) = eat , then
Z ∞ Z ∞
F (s) = e−st eat dt = e(−(s−a)t dt
0 0
A A
−e−(s−a)t
Z  1
−(s−a)t

−(s−a)t 1
= lim e dt = lim = lim −e + 1 =
A→∞ 0 A→∞ (s − a) A→∞ s−a s−a
0
Therefore,
1
L eat =

s−a
The integral converges to 1/(s − a) only for s > a and diverges for s < a.
(c) Finally,

1
. L {t} =
s2
Check this yourself. (Hint: use integration by parts.)
Example 11.2. Sometimes, using complex valued functions simplifies the computation of the Laplace
transform. Consider the following two cases:
Z ∞ Z ∞
−st
L {sin(at)} = e sin(at) dt and L {cos(at)} = e−st cos(at) dt .
0 0
Both integrals could be evaluated directly, but the computations are messy, involving integration by
parts twice. It’s easier to use complex-valued functions as follows:

Since eiat = cos(at) + i sin(at),


L eiat = L {cos(at)} + iL {sin(at)} .


Consequently,
Z ∞ Z ∞
−st iat
iat
e−(s−ia)t dt

L e = e e dt =
0 0

−e−(s−ia)t
=
s − ia 0
1 s a
= = 2 2
+i 2
s − ia s +a s + a2
Therefore,
s a
L {cos(at)} = and L {sin(at)} = 2 (11.5)
s2 + a2 s + a2
11.2. PROPERTIES OF THE LAPLACE TRANSFORM 103

A similar computation shows that


n o 1
L e(a+ib)t = (11.6)
s − (a + ib)
To see this, compute as before:
n o Z ∞
L e (a+bi)t
= e−st e(a+bi)t dt
0
Z ∞
= e−(s−(a+bi))t dt
0
A
−e−(s−(a+bi))t
= lim
A→∞ s − (a + bi)
0
1
= .
s − (a + bi)
Note that the last step is only valid for s > a.

1 s−a b
Because e(a+ib)t = eat cos(bt) + ieat sin(bt) and = +i , it follows
s − (a + ib) (s − a)2 + b2 (s − a)2 + b2
that
s−a b
L eat cos(bt) = and L eat sin(bt) =
 
.
(s − a)2 + b2 (s − a)2 + b2

11.2. Properties of the Laplace transform

Rather than continuing to derive Laplace transforms of specific functions, it is more efficient to find
general properties of the Laplace transform.

The Laplace transform is a linear operator. This means that if f (t) and g(t) are functions and a and b
are numbers, then
L {af (t) + bg(t)} = aF (s) + bG(s) , (11.7)
where F (s) and G(s) are the Laplace transforms of f (t) and g(t), respectively. Linearity follows imme-
diately from linearity of the definite integral:
Z ∞ Z ∞ Z ∞
L {af (t) + bg(t)} = e−st (af (t) + bg(t)) dt = a e−st f (t) dt + b e−st g(t) dt .
0 0 0
Because of linearity, we can decompose the Laplace transform of a sum of functions as a sum of the
Laplace transform of each of the summands.
Example 11.3. By linearity and the table of Laplace transforms,
1 4 5 12
L 5e−2t − 3 sin(4t) = 5L e−2t − 3L {sin(4t)} = 5
 
−3 2 = − .
s − (−2) s + 16 s + 2 s2 + 16

The next theorem shows that the Laplace transform of the derivatives of a function can be expressed in
terms of the Laplace transform of the function, itself.
Theorem 3. Suppose g(t) is a continuously differentiable with Laplace transform G(s), then
L {g 0 } = sG(s) − g(0).
If g(t) is has continuous second derivatives, then
L {g 00 } = s2 G(s) − sg(0) − g 0 (0) .
104 LAPLACE TRANSFORMS

Proof. In order for L {g} to exist, g(t) must be piecewise continuous (required for the integral to
exist) and it must be of exponential order: there are constants M and c so that y(t) ≤ M ect . This
implies that when s > c,
lim g(a)e−sa = 0.
a→∞
To compute Z ∞
0
L {g } = e−st g 0 (t) dt,
0
we use integration by parts: u = e−st , dv = g 0 (t)dt, so du = −se−st dt and v = g(t), so
Z ∞
0
L {g } = e−st g 0 (t) dt
0
Z ∞
−st

= e g(t) 0 + se−st g(t) dt
0
Z ∞
= −g(0) + s e−st g(t) dt
0
= sG(s) − g(0),
as desired.

If, in addition, g(t) has continuous second derivatives, apply the first part of the theorem, twice as
follows:
L {g 00 (t)} = sL {g 0 (t)} − g 0 (0) = s(sG(s) − g(0)) − g 0 (0) = s2 G(s) − sg(0) − g 0 (0) .


Linearity and Theorem 3 are key ingredients for solving initial value problems. For suppose we have a
linear constant coefficient differential equation
ay 00 + by 0 + cy = f (t) ,
together with the initial conditions y(0) = y0 and y 0 (0) = y00 . By linearity, applying L {−} to the
differential equation gives
aL {y 00 } + bL {y 0 } + cL {y} = L {f } = F (s).
By Theorem 3 applying L {−} to the terms L {y 00 } and L {y 0 } gives
a(s2 Y (s) − sy0 − y00 ) + b(sY (s) − y0 ) + cY (s) = F (s) ,
which simplifies to
(as2 + bs + c)Y (s) − (ay0 s + ay00 + by0 ) = F (s) . (11.8)
This equation can be solved for Y (s):
F (s) ay0 s + ay00 + by0
Y (s) = + . (11.9)
as2 + bs + c as2 + bs + c
Example 11.4. Consider the initial value problem y 00 − 3y 0 + 2y = 0, y(0) = 2, y 0 (0) = 1. Applying the
Laplace operator L {−}, the equation becomes
(s2 Y (s) − 2s − 1) − 3(sY (s) − 2) + 2Y (s) = 0,
or
(s2 − 3s + 2)Y (s) = 2s − 5.
Therefore,
2s − 5 2s − 5 3 −1
Y (s) = = = + .
s2 − 3s + 2 (s − 1)(s − 2) s−1 s−2
11.2. PROPERTIES OF THE LAPLACE TRANSFORM 105

We write L−1 {−} for the operator that undoes the Laplace transform: if Y (s) = L {y}, then L−1 {Y } (t) =
y(t). We call L−1 {−} the inverse Laplace transform. Using this notation,
     
3 −1 1 1
y(t) = L−1 + (t) = 3L−1 (t) − L−1 (t) = 3et − e2t ,
s−1 s−2 s−1 s−2
1
where we have used linearity of L {−} and (from Appendix C) the formula L eat =

.
s−a

In the above example, we implicitly assumed that Y (s) determines y(t). In fact, this is the case, as the
next theorem shows.
Theorem 4. Suppose that f and g are continuous. Let F (s) = L {f (t)} and G(s) = L {g(t)}. If for
some c > 0, F (s) = G(s) for all s > c, then f (t) = g(t) for all t > 0.
Remark 11.2. This theorem is not obvious, and in fact the proof is difficult and beyond the scope of
this course.

To compute the inverse Laplace transforms encountered in practice, we need a few more properties of
the Laplace transform.

If F (s) is the Laplace transform of f (t), then


L eat f (t) = F (s − a) (the exponential shift formula) .

(11.10)

Proof. Z ∞ Z ∞
L eat f (t) = e−st eat f (t) dt = e−(s−a)t f (t) dt = F (s − a) .

0 0

Example 11.5. Since L {cos(bt)} = s/(s2 + b2 ),
s−a
L eat cos(bt) =

.
(s − a)2 + b2
Similarly,
b
L eat sin(bt) =

.
(s − a)2 + b2

If F (s) is the Laplace transform of f (t), then


L {tf (t)}) = −F 0 (s) . (11.11)

Proof. It’s easiest to work backwards as follows:


Z ∞ Z ∞ Z ∞
d d −st
F 0 (s) = e−st f (t) dt = e−st tf (t)dt = −L {tf (t)} .

e f (t) dt = −
ds 0 0 ds 0

 0
1 1 1
Example 11.6. Since L {1} = , L {t} = − = 2.
s s s

 0
1 2
1
L t2 = L {t · t} −

Since L {t} = s2 , = .
s2 s3
106 LAPLACE TRANSFORMS

 0
(n − 1)! (n − 1)! (n)!
More generally, suppose L tn−1 = . Then, L {tn } = L t · tn−1 −
 
n
= .
s sn sn+1
Therefore, by mathematical induction,
(n)!
L {tn } = n+1 .
s
for all positive integers.
6
Example 11.7. Since, L t3 = 4 ,

s
6
L t3 e5t =

(s − 5)4
a
Example 11.8. Since, L {sin(at)} = ,
s2 + a2
 0
a (2as
L {t sin(at)} = − =
s + a2
2 (s2 + a2 )2
s
Similarly, since L {cos(at)} = ,
s2 + a2
0
(s2 − a2

s
L {t cos(at)} = − =
s2 + a2 (s2 + a2 )2

Suppose L {f (t)} = F (s), then


1
L {f (at)} = F (s/a) .
a

Proof. Compute as follows, using the “u-substitution” u = at, du = adt:


Z ∞ Z ∞
1 ∞ −(s/a)u
Z
−st −s(u/a) du 1
L {f (at)} = e f (at) dt = e f (u) = e f (u)du = F (s/a) .
0 0 a a 0 a

s
Example 11.9. Because L {cos(t)} = 2 , it follows that
s +1
1 (s/a) s
L {cos(at)} = 2
= 2 .
a (s/a) + 1 s + a2

11.3. Computing the Inverse Laplace Transform

Computing the inverse Laplace transform often involves the partial fraction expansion 16 of the Laplace
transform.
3s
Example 11.10. Find the inverse Laplace transform of F (s) = 2 .
s −s−6

Solution Compute the partial fractions expansion of F (s) as follows:


3s 3s A B A(s + 2) + B(s − 3)
= = + =
s2 − s − 6 (s − 3)(s + 2) s−3 s+2 (s − 3)(s + 2)

16This is a good time to read Appendix B, which presents a quick review of partial fractions.
11.3. COMPUTING THE INVERSE LAPLACE TRANSFORM 107

Comparing numerators gives 3s = A(s + 2) + B(s − 3). Set s = 3 to conclude that 9 = A(5) or A = 5/9.
Set s = −2 to conclude that −6 = B(−5) or B = 6/5. Hence
3s 5/9 6/5
= + .
s2 − s − 6 s−3 s+2
We can now use the table of Laplace transforms to compute as follows:
     
−1 3s 5 −1 1 6 −1 1 5 6
L = L + L = e3t + e−2t .
s2 − s − 6 9 s−3 5 s+2 9 5

8s2 − 4s + 12
Example 11.11. Find the inverse Laplace transform of F (s) = .
s(s2 + 4)

Solution First compute the partial fractions expansion of F (s):

8s2 − 4s + 12 A Bs + C A(s2 + 4) + s(Bs + C) (A + B)s2 + Cs + 4A


= + = =
s(s2 + 4) s s2 + 4 s(s2 + 4) s(s2 + 4)

Comparing coefficients of powers of s in the numerator, we find that


A = 3, C = −4 , and B = 9 − 3 = 5 .
Therefore,
     
3 5s − 4 1 s 4 2
F (s) = + 2 =3 +5 2 − .
s s +4 s s +4 2 s2 + 4
From the table of Laplace transforms, it now follows that
     
1 s 4 −1 2
f (t) = L−1 {F (s)} = 3L−1 + 5L−1 − L
s s2 + 4 2 s2 + 4
= 3 + 5 cos(2t) − 2 sin(2t) .

2s − 3
Example 11.12. Find the inverse Laplace transform of F (s) = .
s2 + 2s + 10

Solution The denominator has complex roots, so complete the square and rewrite F (s) as follows:

2s − 3 2s − 3 2(s + 1) − 5
= =
s2 + 2s + 10 2
(s + 1) + 9 (s + 1)2 + 9
Therefore,
   
(s + 1) 5 3
F (s) = 2 −
(s + 1)2 + 9 3 (s + 1)2 + 9
From the table of Laplace transforms, it now follows that the inverse Laplace transform of F (s) is
5
f (t) = 2e−t cos(3t) − e−t sin(3t)
3
108 LAPLACE TRANSFORMS

2s3 + s2 + 8s + 6
Example 11.13. Find the inverse Laplace transform of Y (s) = .
(s2 + 1)(s2 + 4)

Solution First compute the partial fractions expansion of Y (s):


2s3 + s2 + 8s + 6 As + B Cs + D
Y (s) = 2 2
= 2 + 2
(s + 1)(s + 4) s +1 s +4
2 2
(As + B)(s + 4) + (Cs + D)(s + 1) (A + C)s3 + (B + D)s2 + (4A + D)s + (4B + D)
= 2 2
=
(s + 1)(s + 4) (s2 + 1)(s2 + 4)
Comparing the coefficients of powers of s in numerators results in the system of four equations in four
unknowns
A + C = 2 , B + D = 1 , 4A + C = 8 , 4B + D = 6 ,
which we can solve to obtain A = 2, B = 5/3, C = 0, and D = −2/3. Therefore,
     
s 5 1 1 2
Y (s) = 2 2 + − .
s +1 3 s2 + 1 3 s2 + 4
Consequently, the inverse Laplace transform of Y (s) is
5 1
y(t) = 2 cos(t) + sin(t) − sin(2t) .
3 3

11.4. Initial Value Problems with Continuous Forcing Function

Below are some examples illustrating the use of Laplace transforms for solving initial value problems. All
of these examples could (sometimes more easily) be done using the method of undetermined coefficients.
The purpose of these examples is mainly to illustrate the method. In later sections, more interesting
examples are presented where the forcing function is not continuous and the method of undetermined
coefficients does not apply.
Example 11.14. Solve the initial value problem y 00 + 4y = cos(3t), y(0) = 0, y 0 (0) = 0.

Solution Applying L {−} gives


s s s/5 s/5
(s2 + 4)Y (s) = , or Y (s) = 2 = 2 − .
s2 + 9 (s + 4)(s2 + 9) s + 4 s2 + 9
From the table of Laplace transforms,
   
1 s 1 −1 s 1
y(t) = L−1 2
− L 2
= (cos(2t) − cos(3t)) .
5 s +4 5 s +9 5

Example 11.15. Solve the initial value problem y 00 + 4y = cos(2t), y(0) = 0, y 0 (0) = 0.

Solution Applying L {−} gives


s s
(s2 + 4)Y (s) = , or Y (s) = 2 .
s2 + 4 (s + 4)2
Using the table of Laplace transforms:
   
−1 s 1 −1 2·2·s 1
y(t) = L 2 2
= L 2 2 2
= t sin(2t).
(s + 4) 4 (s + 2 ) 4
11.4. INITIAL VALUE PROBLEMS WITH CONTINUOUS FORCING FUNCTION 109

Example 11.16. Laplace transforms can also be used to solve linear constant coefficient first order initial
value problems. For instance, consider the initial value problem
y 0 + 2y = cos(t) , y(0) = 1 .
Computing the Laplace transform of both sides gives
s
sY (s) − 1 + 2Y (s) = ,
s2 + 1
which can be solved for Y (s):
s 1 (2/5)s + (1/5) 2/5 1
Y (s) = 2
+ = 2
− +
(s + 2)(s + 1) s + 2 s +1 s+2 s+2
(2/5)s 1/5 3/5
= 2 + 2 + .
s +1 s +1 s+2
Hence,
     
2 −1 s 1 −1 1 3 −1 1
y(t) = L−1 {Y (s)} = L + L + L
5 s2 + 1 5 s2 + 1 5 s+2
2 1 3 −2t
= cos(t) + sin(t) + e
5 5 5

Example 11.17. Solve the initial value problem


y 00 − 3y 0 + 2y = 2e−3t , y(0) = 1 , y 0 (0) = 0 .
Solution Applying L {−} and setting Y (s) = L {y} yields the equations
2
(s2 Y (s) − s) − 3(sY (s) − 1) + 2Y (s) = ,
s+3
which simplifies to
2
(s2 − 3s + 2)Y (s) − s + 3 = .
s+3
Solving for Y (s) yields
2 s−3
Y (s) = + 2
(s + 3)(s2
− 3s + 2) s − 3s + 2
s2 − 7 3/2 −3/5 1/10
= = + + .
(s − 1)(s − 2)(s + 3) s−1 s−2 s+3
Consequently,
3 t 3 2t 1
y(t) = e − e + e−3t .
2 5 10

Example 11.18. Solve the initial value problem y 00 + 2y 0 + 2y = cos(2t), y(0) = 1, y 0 (0) = 0.

Solution Proceeding as in the previous example, apply L {−}, solve for Y (s), compute the partial
fractions expansion for Y (s), and finally, compute the inverse Laplace transform.

Here’s the (somewhat messy!) computation omitting some algebra:


s
(s2 Y (s) − s) + 2(sY (s) − 1) + 2Y (s) =
s2 +4
s
(s2 + 2s + 2)Y (s) = + s + 2.
s2 + 4
110 LAPLACE TRANSFORMS

Therefore,
s s+2
Y (s) = +
(s2
+ 4)(s2
+ 2s + 2) s2
+ 2s + 2
As + B C(s + 1) + D (s + 1) + 1
= 2 + 2
+ .
s +4 (s + 1) + 1 (s + 1)2 + 1
− 1 s + 10
4 1 3
(s + 1) − 10 (s + 1) + 1
= 102 + 10 2
+
s +4 (s + 1) + 1 (s + 1)2 + 1
1 s 2 2 11 s+1 7 1
=− + + + .
10 s2 + 4 10 s2 + 4 10 (s + 1)2 + 1 10 (s + 1)2 + 1

Using the table of Laplace transforms gives


1 1 11 7
y(t) = L−1 {Y (s)} = − cos(2t) + sin(2t) + e−t cos(t) + e−t sin(t).
10 5 10 10

11.5. The Laplace Transform of Piecewise Continuous Functions

The Laplace transform is a useful tool when the forcing function f (t) is piecewise continuous. Piece-
wise continuous forcing functions, such as those pictured in Figure 11.1, routinely occur in engineering
applications, particularly in engineering applications involving signal processing.

1.5 1.5 1.5


1.0
1.0 1.0
0.5
0.5 0.5
0.0
0.0 0.5 0.0

0.5 1.0 0.5


T 2T 3T T/2 T 3T/2 2T 5T/2 T/2 T 3T/2 2T 5T/2

Figure 11.1. From left to right: a sawtooth wave, a square wave, and a pulse wave.

The Heaviside step function, denoted by ua (t) is the basic building block for constructing piecewise
continuous function. It is defined as follows:
(
0 if t < a,
ua (t) =
1 if t ≥ a .

The difference ua (t) − ub (t), b > a, of two Heaviside step functions forms a pulse.

0
 if t < 1,
Example 11.19. Let f (t) be the function defined by f (t) = 2t − 1 if 1 ≤ t < 2, then

0 if t ≥ 2,

f (t) = (2t − 1)(u1 (t) − u2 (t)).
11.5. THE LAPLACE TRANSFORM OF PIECEWISE CONTINUOUS FUNCTIONS 111

f (t) = ua (t) f (t) = ua (t) − ub (t)


1 1

t t
a a b

Figure 11.2. The Heaviside step function ua (t) and its difference ua (t) − ub (t) are
the basic building blocks for constructing piecewise continuous functions.

3.0
2.5
2.0
1.5
y

1.0
0.5
0.0
0.0 0.5 1.0 1.5 2.0 2.5 3.0
t
Example 11.20. The Heaviside step function is particularly useful in representing waves commonly
found in engineering applications, such as sawtooth waves, square waves, and pulse waves., illustrated in
Figure 11.1. A sawtooth wave of period T and amplitude 1 can be represented as follows

t X
fsaw (t) = − ukT (t) ; (11.12a)
T
k=1

while a square wave of period T and amplitude 1 can be represented by



X
fsqr (t) = u0 (t) + 2 (−1)k ukT /2 (t) ; (11.12b)
k=1

and a pulse wave of period T and amplitude 1 can we represented by



X
fpulse (t) = u0 (t) + (−1)k ukT /2 (t) . (11.12c)
k=1

Proposition 5. The Laplace transform of ua (t) is e−as /s. If f (t) is a function with Laplace transform
F (s), then
L {ua (t)f (t − a)} = e−as F (s). (11.13)

Proof. The integral defining the Laplace transform is


Z ∞ Z ∞
−st
L {ua (t)f (t − a)} = e ua (t)f (t − a) dt = e−st f (t − a) dt.
0 a
Now make a change of variables: let w = t − a. When t = a, w = 0, and when t = ∞, w = ∞, so the
integral becomes
Z ∞ Z ∞ Z ∞
e−s(w+a) f (w) dw = e−sw e−sa f (w) dw = e−sa e−sw f (w) dw = e−sa L {f } .
0 0 0
112 LAPLACE TRANSFORMS

The formula for the Laplace transform of ua (t) is a special case: set f (t) = 1 and recall that 1/s is the
Laplace transform of 1, 

Example 11.21. If f (t) = u1 (t)(t − 1), then L {f } = e−s /s2 .


Example 11.22. Suppose f (t) = (u1 (t) − u2 (t))(2t − 1). To make use of Proposition 5, rewrite f (t) as
follows
f (t) = u1 (t)(2t − 1) − u2 (t))(2t − 1) = u1 (t)(2(t − 1) + 1) − u2 (t)(2(t − 2) + 3) .
   
−s 2 1 −2s 2 3
Proposition 5 then yields the formula L {f } = e + −e + .
s2 s s2 s
Example 11.23. The Laplace transforms of the sawtooth, square, and pulse waves are, respectively,

!
1 X
−kT s 1
Fsaw (s) = − e ,
T s2 s
k=1

!
1 X
−k(T /2)s 2
Fsqr (s) = + (−1)e ,
s s
k=1

and

!
1 X
k −k(T /2)s 1
Fsaw (s) = + (−1) e .
s s
k=1

Remark 11.3. The following variant of the formula (11.13) is occasionally useful:
L {ua (t)f (t)} = e−as L {f (t + a)} (11.14)
To show this, let g(t) = f (t + a). Then f (t) = g(t − a). Applying (11.13) to g(t) shows
L {ua (t)f (t)} = L {ua (t)g(t − a)} = e−as L {g(t)} = e−as L {f (t + a)} .
For instance,
L {u3 (t)(2t − 1)} = e−2s L {2(t + 3) − 1} = e−2s L {2t + 5}
 
−2s −2s 2 5
=e (2L {t} + 5L {1}) = e + .
s2 s

11.6. Initial Value Problems with Piecewise Continuous Forcing Functions

Consider the differential equation


ay 00 + by 0 + cy = f (t) ,
where f (t) is piecewise-continuous. What does it mean for y(t) to be a solution of an equation like
this? If f (t) is discontinuous at some point t = t0 , will y 00 (t) even be defined there? If not, how can the
equation be satisfied? To avoid these issues, declare a function y(t) to be a solution to an equation like
this if

• y(t) is continuous everywhere,


• y 0 (t) is continuous everywhere, and
• y(t) satisfies the differential equation at every point where the right-hand side f (t) is continuous.

Thus y 00 (t) need not be defined (and in practice usually won’t be defined) at points of discontinuity of
the right side; it will, however, be defined at all other points.
11.6. INITIAL VALUE PROBLEMS WITH PIECEWISE CONTINUOUS FORCING FUNCTIONS 113

Example 11.24. Solve the initial value problem


y 00 + 5y 0 + 4y = f (t), y(0) = 0, y 0 (0) = 0 ,
where f (t) = u1 (t) − u10 (t).

Solution Applying the Laplace transform yields the equation


e−s e−10s
(s2 + 5s + 4)Y (s) = − .
s s
Hence,
 
1 1/4 −1/3 1/12
Y (s) = e−s − e−10s = e−s − e−10s
 
+ + .
s(s + 1)(s + 4) s s+1 s+4
Let p(t) = 1/4 − 1/3e−t + 1/12e−4t , so that p(t) is the inverse Laplace transform of the last term on the
right. Then
y(t) = u1 (t)p(t − 1) − u10 (t)p(t − 10)
   
1 1 −t+1 1 −4t+4 1 1 −t+10 1 −4t+40
= u1 (t) − e + e + u10 (t) − e + e .
4 3 12 4 3 12
The solution is graphed below.

0.25
0.20
0.15
0.10
0.05
0.00
0 5 10 15 20

Example 11.25. Solve the initial value problem



0
 if t < 1,
y 00 + 3y 0 + 2y = f (t), 0
y(0) = 2, y (0) = 0 , where f (t) = t − 1 if 1 ≤ t < 2,

0 if t ≥ 2.

Solution In this case,


f (t) = u1 (t)(t − 1) − u2 (t)(t − 1) = u1 (t)(t − 1) − u2 (t)((t − 2) + 1).
Apply L {−} to the differential equation:
1 1
(s2 Y − 2s) − (3sY − 6) + 2Y = (e−s − e−2s )
2
− e−2s
s s
2 −s −2s 1 −2s 1
(s − 3s + 2)Y − 2s + 6 = (e − e ) 2 − e ,.
s s
Solving for Y (s) gives
2s − 6 1 1
+ e−s − e−2s 2 2 − e−2s 2

Y (s) = 2
s − 3s + 2 s (s − 3s + 2) s(s − 3s + 2)
   
4 −2 1/2 3/4 −1 1/4 1/2 −1 1/2
= + + (e−s − e−2s ) + + + − e −2s
+ + .
s−1 s−2 s2 s s−1 s−2 s s−1 s−2
114 LAPLACE TRANSFORMS

If we let p(t) denote the inverse Laplace transform of the sum of fractions in the left-hand parentheses,
and q(t) the the inverse Laplace transform of the terms in the right-hand set, then
1 3 1 1 1
p(t) = t + − et + e2t , q(t) = − et + e2t ,
2 4 4 2 2
and the solution y(t) can be written as follows:
y(t) = 4et − 2e2t + u1 (t)p(t − 1) − u2 (t)p(t − 2) − u2 (t)q(t − 2) .

After lots of algebra this reduces to



t 2t
4e − 2e
 if 0 ≤ t < 1,
y(t) = 4et − 2e2t + 21 (t − 1) + 43 − et−1 + 14 e2t−2 if 1 ≤ t < 2,
(4 − e − 2e−2 )et + −2 + 14 e−2 − 34 e−4 e2t
 
if t ≥ 2.

Example 11.26. Find the solution to the initial value problem y 00 + y = f (t) , y(0) = 0, y 0 (0) = 0,
where f (t) is the sawtooth wave with period T = 2π:

t X
f (t) = − u2kπ (t) .

k=1

Solution Applying the Laplace transform to this initial value problem and solving for Y (s), we find
that

!
1 1 X
−2kπs 1
Y (s) = − e
2πs2 (s2 + 1) s2 + 1 s
k=1

  !  
1 1 1 X
−2kπs 1 s
= − 2 − e − .
2π s2 s +1 s (s2 + 1)
k=1

4 y(t)
f(t)
2

2
2 4 6 8 10

The inverse transform of Y (s) is then



1 X
y(t) = (t − sin(t)) − u2kπ (t)h(t − 2kπ)

k=1
1 s
where h(t) = 1 − cos(t), the inverse Laplace transform of − 2 . The solution y(t) together with
s s +1
the forcing function f (t) are graphed above.
11.6. INITIAL VALUE PROBLEMS WITH PIECEWISE CONTINUOUS FORCING FUNCTIONS 115

(
100 sin(40t) when 0 ≤ t < 7,
Example 11.27. Suppose that f (t) is defined by f (t) =
0 when t ≥ 7.

Solve the initial value problem y 00 + 3y 0 + 2y = f (t), y(0) = 0, y 0 (0) = 0.

Solution In this case, it’s easier to work with complex-valued functions. Since f (t) = (1−u7 (t))100 sin(40t) =
100(1−u7 (t))Re (−iei40t ), the solution of the original initial value problem is the real part of the solution
of the initial value problem
z 00 + 3z 0 + 2z = g(t) , z(0) = 0, z 0 (0) = 0 ,
where g(t) = −100i(1 − u7 (t))ei40t . Applying the Laplace transform gives
G(s) G(s)
Z(s) = = .
s2 + 3s + 2 (s + 2)(s + 1)
The Laplace transform of g(t) is
  n o
G(s) = −100i L ei40t − e−7s L ei40(t+7) = −100i 1 − e280i e−7s L ei40t
 

 100i
= − 1 − e280i e−7s .
s − 40i
Therefore, (by a messy partial fractions computation, that can be skipped17)
(−100i)
Z(s) = 1 − e280i e−7s

(s − 40i)(s + 2)(s + 1)
 
 −0.00467 + 0.0622i 2.4938 + 0.1247i 2.498 + 0.06246i
= 1 − e280i e−7s − +
s − 40i s+2 s+1
280i −7s

= 1−e e L {h(t)}
where h(t) = (−0.00467 + 0.0622i)ei40t − (2.4938 + 0.1247i)e−2t + (2.498 + 0.06246i)e−t
Hence, z(t) = h(t) − e280i u7 (t)h(t − 7)
Finally,
(
−2.49e−2t + 2.50e−t − 0.0622 sin(40t) − 0.00467 cos(40t), if 0 ≤ t < 7,
y(t) = Re (z(t)) =
−2.25e−2(t−7) + 2.28e−(t−7) , if t ≥ 7.

0.6

0.4

0.2

0.0
0.0 2.5 5.0 7.5 10.0 12.5

17The computation without using complex-valued functions is worse!


116 LAPLACE TRANSFORMS

11.7. The Dirac Delta Function/Impulse Response

Laplace transform techniques are useful in cases where the forcing function f (t) represents “impulses”
of short duration.

As a motivating example, consider an object of mass m (in kilograms) free to move in a straight line.
Let x(t) be the position (in meters) of the object at time t seconds and let v(t) be its velocity. Suppose
also that x(0) = 0 and v(0) = 0.

Suppose that (as shown in Figure 11.3) at time t = a a positive force is exerted on the object for ε
seconds and vanishes for t > a + ε, where ε > 0 is assumed to be a small number. For instance, the
object could be a football or baseball suddenly struck by a foot or a bat.

Label this force fε (t), and assume that fε (t) satisfies the following condition:
Z a+ε
fε (t) dt = J ,
a
where J is a fixed constant. This integral is called an impulse and has the dimensions of momentum
(Newton-seconds or kilogram-meters/second).

fε (t) fε (t)

vε (t) vε (t)

J/m J/m

a| {z } a
ε

Figure 11.3. As ε approaches zero, yε (t) approaches (J/m)ua (t), a multiple of the
Heaviside step function.

In this situation, Newton’s second law of motion assumes the simple form
dv
m = f (t) , v(0) = 0 ,
dt
which we can integrate to find Z t
mv(t) = f (τ ) dτ .
0
It is useful to discuss the process as t increases: v(t) = 0 until t = a, at which time v(t) increases until
time t = a + ε. After that time, v(t) = J/m because no force is being exerted on the object after that
time.
11.7. THE DIRAC DELTA FUNCTION/IMPULSE RESPONSE 117

Imagine now what happens if the impulse J stays constant, but ε approaches zero. To keep J constant,
the values of fε (t) have to become large on the interval a ≤ t < a + ε. For very small values of ε,
the graph of v(t) will become almost indistinguishable from the graph of the step function (J/m)ua (t).
The specific choice of fε (t) is unimportant: we only need to insist that it vanishes outside the interval
a ≤ t < a + ε and that its integral remains equal to J.

To understand the behavior of the Laplace transform of fε (t) as ε approaches 0, assume for simplicity,
assume that m = 1, J = 1, and that fε (t) has the special form:

1 0
 t < a,
fε (t) = (ua (t) − ua+ε (t)) = 1/ε a ≤ t < a + ε,
ε 
0 t > a + ε.

The Laplace transform of fε (t) can then be computed as follows:


1 e−as e−(a+ε)s 1 − e−εs
   
1 −as
L {fε (t)} = (L {ua (t)} − L {ua+ε (t)}) = − =e .
ε ε s s εs
Using l’Hôpital’s rule, the limit as ε approaches zero of the Laplace transforms is easily found:
1 − e−εs
   −εs 
se
lim L {fε (t)} = e−as lim = e−as lim = e−as .
ε→0 ε→0 εs ε→0 s

Roughly speaking, the Dirac Delta Function δa (t) is defined by


δa (t) = lim+ fε (t) .
ε→0
18
Although this is not a well-defined function , it does have a well-defined Laplace transform:
L {δa (t)} = e−as . (11.15)
Remark 11.4. When a = 0, the subscript is dropped and the notation δ(t) is used. The identity (11.15)
then reduces to
L {δ(t)} = 1 .
An alternate notation for δa (t) is δ(t − a). Then the delta function satisfies the identity
L {δ(t − a)} = e−as L {δ(t)} = e−as 1 = e−as
which is consistent with the general formula L {ua (t)f (t − a)} = e−as L {f (t)}.

Example 11.28. Laplace transforms give a way to model the dynamics of a force that acts instanta-
neously on an object of mass m:
dv
m = lim fε (t) = Jδa (t) , v(0) = 0 .
dt ε→0

Taking Laplace transforms gives


e−as
msV (s) = Je−as =⇒ V (s) = (J/m) .
s
Therefore,
e−as
 
−1
v(t) = (J/m)L = (J/m)ua (t) .
s
Rather than solving for v(t), one can apply Newton’s second law of motion:
mx00 (t) = Jδa (t) , x(0) = 0 , x0 (0) = 0 .

18It is something called a “generalized function” or a “distribution,” not an actual function.


118 LAPLACE TRANSFORMS

Taking Laplace transforms gives X(s) = (J/m)e−as /s2 . Consequently,

x(t) = (J/m)L−1 e−as /s2 = (J/m)(t − a)ua (t) ,




as expected.

Example 11.29. Solve the initial value problem

y 00 + 2y 0 + 2y = δ1 (t), y(0) = 0, y 0 (0) = 0.

Solution Apply the Laplace transform and solve for Y (s):


1
(s2 + 2s + 2)Y (s) = e−s =⇒ Y (s) = e−s .
s2 + 2s + 2
Complete the square and write Y (s) in the form
1 1
Y (s) = e−s = e−s .
s2 + 2s + 2 (s + 1)2 + 1
Therefore
y(t) = L−1 {Y (s)} = u1 (t)h(t − 1) ,
where
 
1
h(t) = L−1 = e−t sin(t).
(s + 1)2 + 1
So
(
−(t−1) 0 if t < 1,
y(t) = u1 (t)e sin(t − 1) =
e−(t−1) sin(t − 1) if t ≥ 1.
Note that this function is continuous everywhere, but it is not differentiable at t = 1. This is not
surprising, because t = 1 is when the delta function is applied—this example models what happens in a
damped mass-spring system when you hit the mass with a hammer.

0.3

0.2

0.1

2 4 6 8

Figure 11.4. The graph of y(t) = u1 (t)e−(t−1) sin(t − 1).


11.8. MODELING EXAMPLES 119

2 2 2
1 1 1
0 0 0
1 1 1
2 2 2
0 1 2 3 4 5 6 7 8 9 010 1 2 3 4 5 6 7 8 9 010 1 2 3 4 5 6 7 8 9 10

Figure 11.5. From left to right the solution of the initial value problem (11.16) for
T = π, T = 2π, and T = 2.0. Resonance occurs when T = 2π, the natural frequency of
the oscillator.

11.8. Modeling Examples

Example 11.30. Consider a mass-spring system, with mass m = 1 kilogram and spring constant k = 1
Newton/meter. Suppose, in addition, the mass is repeatedly struck with a unit impulse every T seconds.
The following initial value problem models this situation:
y 00 + y = f (t) , y(0) = y 0 (0) = 0 , (11.16)

X
where f (t) = δjT (t), and T > 0. The natural frequency of this harmonic oscillator is 2π. Therefore,
j=0
we expect to observe some sort of resonance when T = 2π (see Figure 11.5).

Taking Laplace transforms gives



X e−jT s
Y (s) = .
j=0
s2 + 1

Taking inverse Laplace transforms yields the solution



X
y(t) = ujT (t) sin(t − jT ) .
j=0

Example 11.31. (A Mixing Problem) Suppose a large tank contains algae that grows exponentially
with a doubling time of 24 hours. The tank initially contains 100 kilograms of algae. Every 12 hours,
h kilograms are instantaneously removed. How large can h be so that this process can be repeated
indefinitely?

Solution. Let t denote time in hours and let y(t) denote the total mass of algae in the tank at time t.
Then y(t) is a solution of the initial value problem

X
y 0 = ky − h δ12j (t) , y(0) = 100 , (11.17)
j=1

where k and h are to be determined. Observe that we modeled instantaneously removing h kilograms
of algae at time t = 12j by the impulse −h δ12j (t).
120 LAPLACE TRANSFORMS

250
200
150
100 h = 35
50 h = 100( 2 1)
h = 45
0
0 20 40 60

Figure 11.6. The solution of the initial √ value problem (11.17) for values of h below,
at, and above the critical value h = 100( 2 − 1) ≈ 41.4 kilograms.

Taking the Laplace transform of the initial value problem gives


∞ ∞
X
−12js 100 X e−12js
(s − k)Y (s) − 100 = − he =⇒ Y (s) = −h .
j=1
s−k j=1
s−k

Taking the inverse Laplace transform gives



X
y(t) = 100ekt − h L−1 e−12jt /(s − k)

j=1
 

X ∞
X
= 100ekt − h u12j (t)ek(t−12j) = 100 − h u12j (t)e−12jk  ekt . (11.18)
j=1 j=1

If the term in parentheses ever became negative, then the tank would be empty, so the condition on h
is that the term in parentheses be positive for all t, no matter how large. Since u12j (t) = 1 for t large,
this amounts to the condition

X 100
100 − h e−12jk > 0 or h < P∞ −12jk .
j=1 j=1 e
P∞
Using the sum formula for the geometric series j=1 rj = 1−r r
, with r = e−12k , this can be rewritten as
100(1 − e−12k )
h< = 100(e12k − 1)
e−12k

Since the doubling time is 24 hours, e24k = 2, so k = ln(2)/24. Hence e12k = eln(2)/2 = 2. We conclude
that √
h < 100( 2 − 1) = 100(0.4121) ≈ 41.4 kilograms.

11.9. Convolutions

Equation (3.10) of Section 3.2.2, gave the formula


Z t
−kt
y(t) = e eku f (u) du + y0 e−kt
0
for the solution of the first order initial value problem
y 0 + ky = f (t) , y(0) = y0 , .
11.9. CONVOLUTIONS 121

If y(0) = 0, then the formula simplifies to


Z t Z t
y(t) = e−kt eku f (u) du = f (u)e−k(t−u) du .
0 0

Recall that the function e−kt is the solution of the initial value problem
y 0 + ky = 0 , y(0) = 1 .
There is a similar formula for the solution of the initial value problem
ay 00 + by 0 + cy = f (t) , y(0) = y 0 (0) = 0 :
Z t
y(t) = f (u)g(t − u) du , (11.19)
0
where g(t) is the solution of the initial value problem
ay 00 + by 0 + cy = 0 , y(0) = 0 , y 0 (0) = 1/a .
The right-hand side of Equation (11.19) is called the convolution of the functions f (t) and g(t).

More generally, if f (t) and g(t) are any two functions defined for t ≥ 0, then their convolution is defined
to be Z t
(f ∗ g)(t) = f (u)g(t − u) du . (11.20)
0
The asterisk ∗ does not mean ordinary multiplication: it is a new operation, convolution, defined by the
integral on the right side.)

As it applies to differential equations, the most important property of convolution is given by the
following theorem:
Theorem 6 (The Convolution Theorem). If L {f } = F (s) and L {g} = G(s), then
L {f ∗ g} = F (s)G(s).

Proof. (Skip this proof if you haven’t taken Math 126.) Compute as follows, using the definition
of the Laplace transform, followed by the formula for convolution:
Z ∞ Z ∞ Z t 
−st −st
L {f ∗ g} = e (f ∗ g) dt = e f (u)g(t − u)du dt
0 0 0
Z ∞ Z t  ZZ
= f (u)g(t − u)e−st du dt = f (u)g(t − u)e−st dudt .
0 0 R

R = {(u, t) : 0 ≤ t ≤ u}
u

Figure 11.7.
122 LAPLACE TRANSFORMS

This is a double integral over the infinite region R in Figure 11.7. Now change variables, letting v = t−u,
so t = u + v and dv = dt:
Z ∞Z ∞
L {f ∗ g} = f (u)g(v)e−s(u+v) dv du
0 0
Z ∞  Z ∞ 
−su −sv
= e f (u) du e g(v) dv = L {f } L {g} .
0 0


A number of properties of convolution follow immediately from The Convolution Theorem:


corollary 7. Let f (t), g(t), and h(t) be continuous functions. Then the following identities hold:
f ∗g =g∗f (11.21a)
(f ∗ g) ∗ h = f ∗ (g ∗ h) (11.21b)

Proof. By Theorem 4, to prove each identity, we need only show that the left-hand side and the
right-hand side have the same Laplace transform:
(i) L {f ∗ g} = F (s)G(s) = G(s)F (s) = L {g ∗ f }
(ii) L {(f ∗ g) ∗ h} = L {f ∗ g} L {h} = F (s)G(s)H(s)
L {f ∗ (g ∗ h)} = L {f } L {g ∗ h} = F (s)G(s)H(s) .


Equation (11.19) follows immediately from the Convolution Theorem. For, consider the initial value
problem
ay 00 + by 0 + cy = f (t) , y(0) = 0 , y 0 (0) = 0 .
Apply the Laplace operator to get
(as2 + bs + c)Y (s) = F (s) .
Therefore,
1
Y (s) = F (s)G(s) , where G(s) = .
as2 + bs + c
Let g(t) = L−1 {G(s)}. It then follows from The Convolution Theorem that
y(t) = (f ∗ g)(t) .
That g(t) is the solution of the initial value problem
ay 00 + by 0 + cy = 0 , y(0) = 0 , y 0 (0) = 1/a
follows by taking Laplace transforms of the initial value problem
a(s2 Y (s) − y 0 (0) − sy(0)) + b(sY (s) − y(0)) + cY (s) = 0 .
Solving for Y (s) and recalling that y(0) = 0 and y 0 (0) = 1/a, shows that Y (s) = G(s). Hence, the
solution is g(t) = L−1 {G(s)}.
Remark 11.5. The function g(t) is perhaps best viewed as the solution of the initial value problem
ay 00 + by 0 + cy = δ(t) , y(0) = y 0 (0) = 0 .
For taking the Laplace transform of this initial value problem also yields G(s):
1
(as2 + bs + c)Y (s) = 1 or Y (s) = = G(s) .
as2 + bs + c
11.9. CONVOLUTIONS 123

Example 11.32. Consider y 00 + 3y 0 + 2y = sin(t), y(0) = 0, y 0 (0) = 0. Then


1 1 1
G(s) = 2 = − ,
s + 3s + 2 s+1 s+2
So
g(t) = L−1 {G} (t) = e−t − e−2t ,
and the solution is, therefore, given by the convolution
y(t) = (e−t − e−2t ) ∗ sin(t).
Remark 11.6. The solution to the initial value problem
ay 00 + by 0 + cy = δ(t), y(0) = 0, y 0 (0) = 0. (11.22a)
is called the (unit) impulse response function; it is often denoted by g(t). Taking the Laplace transform
of (11.22a) shows that
1
G(s) = L {g(t)} = 2 . (11.22b)
as + bs + c
G(s) is called the transfer function.


b b2 − 4ac
There is a rather nice formula for g(t) in terms of the roots r1 , r2 = − ± of the characteristic
2a 2a
b
polynomial as2 + bs + c. Let ρ = .
2a
 −ρt √
e sinh(wt) 2 −4ac


 a , if b2 − 4ac > 0, w = b 2a ,


 w



 −ρt
e
g(t) = t, if b2 − 4ac = 0, (11.22c)


 a



−ρt √
e sin(ωt)

 2
if b2 − 4ac < 0, ω = 4ac−b

, 2a .
a ω


b2 − 4ac
Proof. (i) If b2 − 4ac > 0, let w = . Then
2a
 
1 1 1 1 1
G(s) = 2 = = − .
as + bs + c a(s + ρ + w)(s + ρ − w) 2aw s + ρ − w s + ρ + w
Hence,
1  −(ρ−w) t  e−ρt
g(t) = L−1 {G(s)} = e − e−(ρ+w) t = sinh(w t)
2aw aw
1
(ii) If b2 − 4ac = 0, then G(s) = . Therefore
a(s + ρ)2
 
1 −1 1 1
g(t) = L = te−ρt .
a s − (−ρ) a

4ac − b2
(iii) If b2 − 4ac < 0, let ω = . Then
2a
 
1 1 1 1 1
G(s) = 2 = = − .
as + bs + c a(s + (ρ + ωi)(s + ρ − ωi) 2aωi s + ρ − ωi s + ρ + ωi
Hence, by Equation (11.6),
1  −(ρ−ωi) t  e−ρt 
eiωt − e−iωt

e−ρt
g(t) = L−1 {G(s)} = e − e−(ρ+ωi) t = = sin(ωt) .
2aωi aω 2i aω

124 LAPLACE TRANSFORMS

The state-free solution is the solution to the initial value problem


ay 00 + by 0 + cy = f (t), y(0) = 0, y 0 (0) = 0. (11.23)
Taking Laplace transforms gives
Y (s) = G(s)F (s) . (11.24)
By The Convolution Theorem, the state-free solution is the function (f ∗ g)(t). The input-free solution
is the solution to
ay 00 + by 0 + cy = 0, y(0) = y0 , y 0 (0) = y00 . (11.25)
Proposition 8. The solution of the initial value problem
ay 00 + by 0 + cy = f (t) , y(0) = y0 , y 0 (0) = y00
is the sum of the state-free and input-free solutions:
y(t) = (f ∗ g)(t) + ay0 g 0 (t) + (ay00 + by0 ) g(t) . (11.26)

Proof. Taking the Laplace transform gives of the initial value problem gives the formula
Y (s) = F (s)G(s) + (ay0 s + (ay00 + by0 )G(s) .
for the Laplace transform of the solution. On the other hand, taking the Laplace transform of (11.26)
using the convolution theorem gives the same thing. Consequently, the two functions agree and (11.26)
is the solution of the initial value problem. 
Example 11.33. Consider y 00 + 4y = f (t), y(0) = 2, y 0 (0) = 3. Then g(t) = L−1 1/(s2 + 4) =


1/2 sin(2t). The state-free solution is


1 t 1 t
Z Z
1
sin(2t) ∗ f (t) = sin(2u)f (t − u) du = sin(2(t − u))f (u) du.
2 2 0 2 0
The input-free solution is
3
ay0 g 0 (t) + (ay00 + by0 )g(t) = 2 cos(2t) + sin(2t).
2
Therefore,
1 t
Z
3
y(t) = 2 cos(2t) + sin(2t) + sin(2(t − u))f (u) du.
2 2 0
11.9. CONVOLUTIONS 125

Exercises 1.

(1) Using Laplace Transforms, find the solution of each of the following initial value problems,
(a) y 00 − 3y 0 + 2y = 0, y(0) = 0, y 0 (0) = 0.
(b) y 00 − 3y 0 + 2y = t, y(0) = 0, y 0 (0) = 0.
(c) y 00 − 3y 0 + 2y = e2t , y(0) = 0, y 0 (0) = 0.
(2) Evaluate each of the following Laplace transforms or inverse Laplace transforms
(a) L {2t+ u2 cos(t − 2)}
s
(b) L−1
(s − 2)(s +
1)
−s

e
(c) L−1
s2 + 2s + 5
(d) L {t sin(2t)}
 
−1 2s + 1
(e) L 2
 4s + 4s + 5
2s + 1
(f) L−1 2
 s(s + 4) 
1
(g) L−1
s(s2 + 4s + 5)
(3) Solve the initial value problem y 00 − y = u4 (t) − u5 (t), y(0) = 1, y 0 (0) = 0.
(4) Consider the following initial value problem:
y 00 + 2y 0 + 5y = u2 (t) , y(0) = 0 , y 0 (0) = 0 .
(a) Let Y (s) denote the Laplace transform for the solution. Find Y (s).
(b) Find the solution y(t) by computing the inverse Laplace transform of Y (s).
(c) Give the numerical value of y(3). (Use a calculator for this part.)
(5) Compute y(7), where y(t) is the solution of the the initial value problem
y 00 − y = u4 (t) − u5 (t) + u6 (t) , y(0) = 0 , y 0 (0) = 0 .
(6) Compute y(10π), where y(t) is the solution of the the initial value problem
y 00 + y = δ(t − π)) − δ(t − 2π) + δ(t − 3π) , y(0) = 0 , y 0 (0) = 0 .
(7) Consider the initial value problem
y 00 + y = f (t) , y(0) = 0 , y 0 (0) = 0 ,
where

X
f (t) = 1 + 2 (−1)k ukπ (t)
k=1
(a) Draw the graph of f (t) for 0 ≤ t ≤ 6π.
(b) Find a formula for F (s), the Laplace transform of f (t).
(c) Find Y (s), the Laplace transform of the solution y(t). Express your answer in the form

X
Y (s) = H(s) e−kT s .
k=0

(d) Find h(t), the inverse Laplace transform of H(s) (from part (c)) and use this to find a
formula for the solution y(t).
(e) Graph y(t) for 0 ≤ t < 8π. (Although y(t) is expressed as an infinite series, most terms in
the series vanish for t < 8π.)
(8) Consider the initial value problem
y 00 + 0.2y 0 + y = f (t) , y(0) = 0 , y 0 (0) = 0 ,
where f (t) is the same as in the previous problem. Repeat steps (b)–(e) of that problem.
126 LAPLACE TRANSFORMS

(9) When making prescriptions for drugs that will be taken over a prolonged period of time it is
necessary to take into account the fact that the concentration of a drug in the bloodstream
grows after each subsequent dose. In this problem you derive a formula in standard use by
physicians.
Let c0 be the concentration of a drug immediately after the first dose (this is proportional
to the size of the dose and the weight of the patient and is information known for all commonly
used drugs). After t units of time the concentration will be given by the formula c = c0 e−rt
where r is a constant that depends on the drug (this is just the law of exponential decay and
again the value of r is known for all commonly used drugs).
Now suppose that the same dose is taken every T units of time (e.g. every 4 hours). Let
y(t) denote the concentration of the drug in the bloodstream t hours after the first dose. Then
y(t) is a solution of the following initial value problem

X
y 0 + ry = f (t) = c0 δ(t − kT ) , y(0) = 0
k=0
(a) Compute Y (s), the Laplace Transform of y(t). (Note: it is an infinite series.)
(b) Now compute the inverse Laplace Transform to obtain a formula for y(t) as another infinite
series.
(c) Use part (b) to find a formula for ck = y(kT ), the concentration of the drug right after a
dose is administered at time t = kT .
(d) Initially, ck will grow pretty rapidly, but it will eventually level off and approach
c∞ = lim ck .
k→∞
Use the formula for the sum of a geometric series to find a formula for c∞ .
(e) Find the value of r if the half-life of the drug in the bloodstream is 3 hours.
(f) Use the result of the previous parts of the problem to obtain a graph of the ratio c∞ /c0
as a function of T for a drug with a half-life of 3 hours. What is the time between doses
if the stable concentration is twice the initial concentration?
Part 4

Appendices
A. Basic Formulas from Algebra, Trigonometry, and Calculus

Algebra:

b b2
Completing the square: X 2 + bX + c = (X + )2 − + c.
2 √4
−b ± b2 − 4ac
Quadratic formula: roots of aX 2 + bX + c are
2a
b √
b c b+c a b−c b c bc 1/b
Exponents: a · a = a ; c = a ; (a ) = a ; a = b a
a a
Logarithms: ln(1) = 0; ln(e) = 1; ln(ab) = ln(a) + ln(b); ln = ln(a) − ln(b)
b

Geometry:

Circle: circumference = 2πr; area = πr2 ;


4
Sphere: vol = πr3 ; surface area = 4πr2
3
Cylinder: vol = πr2 h; lateral area = 2πrh; surface area = 2πrh + 2πr2 .
1 p p
Cone: vol = πr2 h; lateral area = πr r2 + h2 ; surface area = πr r2 + h2 +
3
πr2

Analytic geometry

Point-slope formula for straight line: y = y0 + m(x − x0 )


Equation for circle centered at (h, k): (x − h)2 + (y − k)2 = r2
(x − a)2 (y − k)2
Equation for ellipse centered at (h, k): 2
+ =1
a b2

Trigonometry

opposite adjacent opposite


sin = ; cos = ; tan = ;
hypotenuse hypotenuse adjacent
1 1 1 sin cos
sec = ; csc = ; cot = ; tan = ; cot = ;
cos  sin tan  cos sin
π π
sin(x) = cos − x ; cos(x) = sin −x
2 2
sin(x + π) = − sin(x); cos(x + π) = − cos(x)
sin(x + y) = sin(x) cos(y) + cos(x) sin(y) ; sin(x − y) = sin(x) cos(y) − cos(x) sin(y)
;
cos(x+y) = cos(x) cos(y)−sin(x) sin(y); cos(x−y) = cos(x) cos(y)+sin(x) sin(y);
       
x+y y−x x−y x+y
sin(x)+sin(y) = 2 sin cos sin(x)−sin(y) = 2 sin cos
 2   2   2   2 
x+y y−x x+y y−x
cos(x)+cos(y) = 2 cos cos cos(x)−cos(y) = 2 sin sin
2 2 2 2
sin2 (x) + cos2 (x) = 1; tan2 (x) + 1 = sec2 (x); 1 + cot2 (x) = csc2 (x).
1 − cos(2x) 1 + cos(2x)
sin2 x = ; cos2 x =
2 2
A. BASIC FORMULAS FROM ALGEBRA, TRIGONOMETRY, AND CALCULUS 129

θ = 0 π/6 π/4
√ √π/3 π/2
sin(θ) = 0 √1/2 1/√2 3/2 1
Values at common angles:
cos(θ) = 1 3/2
√ 1/ 2 1/2
√ 0
tan(θ) = 0 1/ 3 1 3 —
The phase-shift formula:
x(t) = C1 cos(ωt) + C2 sin(ωt) = A cos(ωt + φ) = A cos (ω(t − t0 )),
φ
q
where t0 = − ; A = C12 + C22 ,
ω
C1 C2 C2
cos(φ) = p 2 . sin(φ) = − p 2 , tan(φ) = −
C1 + C22 2
C1 + C2 C1

(C1 , C2 ) x = Acos( (t t0)


• x = Acos( t)
6 t0
6

-
A 6
A ? -
 -

T = ω
−φ
-

Figure A.1. The figure above illustrates how to graphp the function y(t) = C1 cos(ωt)+
C2 sin(ωt). It is a “cosine curve” of amplitude A = C12 + C22 , period T = 2π ω , shifted
φ
by t0 = − ω units. The angle φ is called the phase angle or phase shift. Notice, however,
that the actual time-shift is the quantity t0 = −φ/ω rather than φ. The curve is shifted
to the right. Therefore, φ < 0 and t0 > 0. When φ is positive, the curve is shifted to
the left.
Example A.1. Sketch the graph of the function y(t) = 2 e−0.3t cos (3 t − 4).

3 y = cos(3t 4) 3 2e 0.3tcos(3t 4)
y = cos(3t) cos(3t 4)
2 2 2e 0.3t
1 1
y

0 0
1 1
2 2
0 2 4 6 0 2 4 6
t t

Step 1: Graph the function f (t) = cos(3t), a cosine function with period 2π/3 ≈ 2.
Step 2: Graph the function f (t − 4/3) = cos(3 t − 4) = cos (3(t − 4/3)). This is the graph of cos(3t)
shifted to the right by 4/3 units.
Step 3: Next graph the functions g(t) = 2e−0.3 t and −g(t) = −2e−0,3 t .
Step 4: Finally graph y(t) = 2e−0.3t cos(3 t − 4), which is the product g(t) · f (t − 4/3) —a shifted cosine
function cos(3t − 4) with varying amplitude g(t) = 2e−0.3 t . In the right-hand figure below, the graph
of y(t) touches the graphs of g(t) and −g(t) (the dotted curves) when cos(3t − 4) = ±1, which is where
3t − 4 is an integer multiple of π:
4 π
3t − 4 = nπ ⇐⇒ t= +n .
3 3
130

Calculus

Basic differentiation formulas:


d du dv d dv du
(u + v) = + , (uv) = u +v .
dx dx
 dx dx  dx dx
d u
  1 du dv
= 2 v −u , for v 6= 0.
dx v v dx dx
Chain rule:
dz dz dy
= .
dx dy dx
Fundamental Theorem of Calculus:
Z g(x)
d
h(u) du = h (g(x)) g 0 (x) − h (f (x)) f 0 (x)
dx f (x)
Derivatives of specific functions:
dxn dex dln|x| 1
= nxn−1 ; = ex ; = ;
dx dx dx x
d sin(x) d cos(x) d tan(x)
= cos(x); = − sin(x); = sec2 (x);
dx dx dx
d arcsin(x) 1 d arctan(x) 1
=√ ; = .
dx 1−x 2 dx 1 + x2

Basic integration formulas:


Z Z Z Z Z
(u + v) dx = u dx + v dx; au dx = a u dx;

Substitution:
Z Z
f (u(x)) u0 (x) dx = F (u(x)) , where f (u)du = F (u);

Integration by parts:
Z Z
u dv = uv − v du;

Standard integrals:
xn+1
Z Z Z
dx
xn dx = + C (n 6= −1); = ln |x| + C; ex dx = ex + C;
n+1 x
Z Z Z
sin(x) dx = − cos(x) + C; cos(x) dx = sin(x) + C; tan(x) dx = − ln | cos(x)| + C;
Z Z
dx xdx p
√ = arcsin(x) + C; √ = − 1 − x2 + C;
1−x 2 1−x 2
Z Z
dx dx 1 1 + x
= arctan(x) + C; = ln + C;
1 + x2 1 − x2 2 1 − x
Z
x dx 1
2
= ln(1 + x2 ) + C
1+x 2
B. REVIEW OF PARTIAL FRACTIONS 131

B. Review of Partial Fractions

When computing integrals and inverse Laplace transforms, rational functions, i.e. ratios of polynomials,
arise:
P (s) pn sn + pn−1 sn−1 + · · · + p1 s + p0
R(s) = =
Q(s) qm sm + qm−1 sm−1 + · · · + q1 s + q0
It is useful to express R(s) as a sum of simple fractions, this is called the partial fractions expansion of
R(s). Here’s how to do that:

Step 0: If P (s) and Q(s) have common factors, cancel them. If degree P (s) ≥ degree Q(s), perform a
long division.

Example:
(s − 2)(s5 + 1) s5 + 1 2s3 + s − 1
4 2
= 4 2
=s− 4 .
(s − 2)(s + 2s + 1) s + 2s + 1 s + 2s2 + 1

Step 1: If Q(s) hasn’t already been factored, factor it.

Example:
2s3 + s − 1 2s3 + s − 1
− = − .
s4 + 2s2 + 1 (s2 + 1)2

Step 2: For each factor in the denominator of the form (s + a)p , with a real, include terms of the form
A1 A2 Ap
+ + ··· + ,
(s + a) (s + a)2 (s + a)p
and for each term in Q(s) of the form (s2 + bs + c)q , where19 c > b2 /4, include terms of the form
A1 (s + 2b ) + B1 A2 (s + 2b ) + B2 Ap (s + 2b ) + Bp
+ + . . .
(s2 + bs + c) (s2 + bs + c)2 (s2 + bs + c)q
in the partial fractions expansion.

Examples:
2s3 + s − 1 As + B Cs + D
− 2 2
= 2 + 2 ,
(s + 1) (s + 1) (s + 1)2
2s3 − s2 + 2s A B C(s + 21 ) + D
= + + ,
(s − 1)2 (s2 + s + 1) (s − 1) (s − 1)2 (s2 + s + 1)
3s4 + 3s3 − 3s2 − 2s + 4 A B C D(s + 1) + E
= + 2+ + 2 .
s2 (s − 1)(s2 + 2s + 2) s s (s − 1) (s + 2s + 2)
3s4 + 3s3 − 3s2 − 2s + 4 A B C D(s + 1) + E F (s + 1) + G
= + 2+ + 2 + 2 .
s2 (s − 1)(s2 + 2s + 2)2 s s (s − 1) (s + 2s + 2) (s + 2s + 2)2
Step 3: Determine the unknown constants. There are two methods:

• The first method proceeds by collecting the terms in the partial fractions expansion and equat-
ing the numerator of the result with the numerator of the original fraction. This yields a system
of equations that can be solved to determine the constants.
19These terms correspond to complex roots of Q(s).
132

Example:
−2s3 − s + 1 As + B Cs + D As3 + Bs2 + (A + C)s + (B + D)
= + = .
(s2 + 1)2 (s2 + 1) (s2 + 1)2 (s2 + 1)2
So A = −2 B = 0 , A + C = −1 , B + D = 1.
−2s3 − s + 1 −2s s+1
Hence, = 2 + .
(s2 + 1)2 (s + 1) (s2 + 1)2
• The second (and often simpler) method is the “cover-up” method, which is best understood by
example.
6s3 − 3s2 + 16s − 3 A B C(s − 1) + D
Example. = + +
(s − 1)(s + 3)(s2 − 2s + 5) s−1 s+3 (s − 1)2 + 4
To determine A, multiply both sides by (s − 1) to get
6s3 − 3s2 + 16s − 3
 
B C(s − 1) + D
= A + (s − 1) +
(s + 3)(s2 − 2s + 5) s+3 (s − 1)2 + 4
Set s = 1 to get
6(1)3 − 3(1)2 + 16(1) − 3 16
A= 2 3
= =1
15 − (1) + (1) + (1) 16
Similarly, to find B, multiply by (s + 3) and set s = −3 to get
6(−3)3 − 3(−3)2 + 16(−3) − 3 −240
B= = =3
(−1 + (−3))(5 − 2(−3) + (−3)2 −80
To find both C and D, multiply by (s − 1)2 + 4 and set s = 1 + 2i (one of the roots). The
terms involving A and B vanish, so:
6(1 + 2i)3 − 3(1 + 2i)2 + 16(1 + 2i) − 3 −44 + ii
C(2i) + D = = = 3 + 4i
(1 + 2i) − 1)((1 + 2i) + 3) −4 + 8i
Hence, C = 2 and D = 3.

2s3 − s2 + 4s − 4 A B Cs + D
Example. 2 2
= + 2+ 2 .
s (s + 4) s s s +4

To determine B, multiply by s2 and set s = 0:


2s3 − s2 + 4s − 4 Cs + D −4
2
= sA + B + s2 2 =⇒ B = = −1
(s + 4) s +4 4
To determine C and D, multiply by s2 + 4 and set s = 2i:
2s3 − s2 + 4s − 4
 
2 A B
= (s + 4) + 2 + Cs + D
s2 s s
=⇒ 2iC + D = 2i =⇒ C = 1 and D = 0 .
A 1 s 2s3 − s2 + 4s − 4
We now have − 2+ 2 = and we can determine A by setting s equal
s s s +4 s2 (s2 + 4)
1 1
to another value and solving for A. For instance, setting s = 1 gives A − 1 + = =⇒ A = 1.
5 5
C. TABLE OF LAPLACE TRANSFORMS 133

C. Table of Laplace Transforms

f (t) F (s) f (t) F (s)

1 1
1 ebt
s s−b
n! n!
tn , n = 1, 2, 3 . . . tn ebt
sn+1 (s − b)n+1
a s
sin(at) cos(at)
s2 + a2 s2 + a2

a (s − b)
ebt sin(at) ebt cos(at)
(s − b)2 + a2 (s − b)2 + a2

2as s2 − a2
t sin(at) t cos(at)
(s + a2 )2
2 (s2 + a2 )2
a s
sinh(at) cosh(at)
s2 − a2 s2 − a2

a (s − b)
ebt sinh(at) ebt cosh(at)
(s − b)2 − a2 (s − b)2 − a2

e−cs
uc (t) δ(t − c) e−cs
s

General Formulas

1
a f (t) + b g(t) a F (s) + b G(s) f (at) F (s/a)
a

ebt f (t) F (s − b) tn f (t) (−1)n F (n) (s)

uc (t)f (t − c) e−cs F (s) uc (t)f (t) e−cs L {f (t + c)}


Z t Z ∞
F (s) 1
f (u) du f (t) F (u) du
0 s t s

f 0 (t) sF (s) − f (0) f 00 (t) s2 F (s) − sf (0) − f 0 (0)


RT
t
e−st f (t) dt
Z
0
f ∗ g(t) = f (t − τ )g(τ ) dτ F (s)G(s) f (t + T ) = f (t)
0 1 − e−sT
134

D. Answers to selected problems 5 1


y(1) = + C = 1 =⇒ C = , so
6 6
t3 3t2 1
y(t) = − + 2t +
Solution (1.1): 3 2 2
6
640 dv (b) y(t) = 2 + Cet /2−t
(a) mass = = 20slugs. (b) 20 = 20 − 2v, 2e2t
32 dt (c) y(t) = 2t .
v(0) = 0ft/sec. 2e − 1
dI y0 beabt
Solution (1.2): 10−5 + 100I = 0 or (d) y(t) = .
dt b + y0 (eabt − 1
dI
+ (107 )I = 0. (f) y(x) = tan(sin(x) + C).
dt
Solution (1.3):
(a) r2 + 4r − 21 = (r + 7)(r − 3) = 0 so r = 3 and Solution (3.2):
r = −7. So two solutions are e3t and e−7t . 5
(a) y(x) = − e−3x + Ce−x
(b) If Aert is a solution then 2
(Aert )00 + 4(Aert ) = (r2 + 4)Aert = 24e2t . So t4 + 2t2 + 5
(b) y(t) =
r = 2 and (r2 + 4)A = 24. This implies that 4(t2 + 1)
2
24 (c) w(t) = (t + C)et
A= 2 = 3. So y = 3e2t is a solution. 1 2
2 + 4) (d) z(x) = sin(6x) − cos(6x) + Ce−3x
Solution (1.4): 15 15
(Cert )0 + 3(Cert ) = C(r + 3)ert = 0. So r = −3 (e) y(t) = −e2t + Ce3t
and y(t) = Ce−3t . But then y(1) = Ce−3 = 2, so 1
(f) y(t) = e2t + Ce−3t
C = 2e3 . Therefore, y(t) = 2e3 e−3t = 2e−3(t−1) is 5
1 2 2
the solution of the initial value problem. (g) y(t) = t2 − t + + Ce−3t .
3 9 27
Solution (1.5): (h) (i)y(t) = 6 + Ce−t/2 , (ii) 6(1 − e−t/2 ), 6,
First find r1 and r2 : 6 + 4e−t/2 .
(r2 + 3r + 2 = (r + 2)(r + 1) = 0, so r1 = −2,
r2 = −1; hence y(t) = C1 r−2t + C2 e−t . The initial
conditions force C1 + C2 = 2 and −2C1 − C2 = 1. Solution (4.1):
Adding the two equations gives −C1 = 3, so (a) y 0 = 0.02y, (b) y(t) = Ce0.02t , (c) In one year:
C1 = −3 and −3 + C2 = 2. Thus C2 = 5, and the 1, 020200, in 20 years: 1, 491, 820, doubles every
solution is y(t) = −3e−2t + 5e−t . 34.66 years.
Solution (2.1): Solution (4.2):
Let P (t) be the population of the Earth (in
2.0 billions) t years after 1650 CE. Under the
y = y1(t) assumptions of the problem, P satisfies the initial
1.5 y = y2(t) value problem
P 0 = kP , P (0) = 0.250 .
1.0
kt
So P (t) = 0.250e . Let T be the time when the
0.5 limit is reached. Then
25 ln(100)
0.0 0.250ekT = 25 =⇒ ekT = = 100 =⇒ T = .
0.25 k
0.5 To continue, we need to know the value of k. But
0.5 0.0 0.5 1.0 1.5 2.0
P (300) = 0.250ek300 = 
2.5 , so taking logarithms
2.5
gives 300k = ln = ln(10), so k = ln(10)
300 .
0.250
Solution (2.2): Therefore,
y(1) ≈ 1.706.
ln(100) 2 ln(10)
T = = 300 = 600 years,
ln(10)/300 ln(10)
Solution Z(3.1):
t3 3t2 or in the year 2250 CE.
(a) y(t) = (1 − t)(2 − t)dt = − + 2t + C Solution (4.3): (c) The maximum they will lend
3 2
is $131,026.
D. ANSWERS TO SELECTED PROBLEMS 135

Solution (4.4): After 7.26 hours. 2Re (z). (b) We need only check that the real and
Solution (4.5): (a) y 0 = − 100 1
y, imaginary parts of the left and right hand side
−t/100 agree.
(b) y(t) = 200e ,
(c) 69.315 minutes, left-hand side = z1 z2
(d) 460.5 minutes. = (x1 x2 − y1 y2 ) + (x1 y2 + x2 y1 )i
Solution (4.6): (a) 0.04(1 − exp(−8.3 × 10−5 t)), = (x1 x2 − y1 y2 ) − (x1 y2 + x2 y1 )i
(b) after 36.05 minutes. right-hand side = z1 z2
Solution (4.7): (a) Let v(t) denote the speed = (x1 − y1 i)(x2 − y2 i)
(so a positive number) in miles per hour, with t = (x1 x2 − y1 y2 ) − (x1 y√
2 + x2 y1 i.
the number of seconds after its speed was 500 (b) By definition p |z| = zz, so we can compute as

mph. Then v 0 = −kv 2 , v(0) = 500, where k is a follows:
√ |z1 z2 | =√ (z1√z2 )z1 z2 = z1 z2 z1 z2
constant. = z1 z1s z2 z2 = z1 z1 z2 z2 = |z1 |z2 |.
500
v(t) = 1+500kt , k = 100001 500
, so v(t) = 1+t/20 √
2+1 1
(c) 125 miles per hour (5) z = +p √ i and
2 2 2+2
(d) We have to convert miles per hour to miles s√
perZ second, then integrate. So distance traveled 2+1 1
60
1 500 z=− −p √ i.
= dt ≈ 3.85 miles. 2 2 2+2
0 3600 1 + t/20
Solution (4.8):
(a) Let L denote the number of licenses issued, Solution (5.2):
and assume that each license is used to catch 5 (1) (a)
z1 − z2 y
fish per year. Then the differential equation is now 5
4
z1
  3
z2
dP P 2
=2 1− − 5L 1
dt 1000 z1 + z2
x
-2 -1.5 -1 -0.5 0.5 1 1.5 2
-1
The maximum value of the right-hand side is -2 z2
attained when P = 500, when it assumes the √ √
(b) |z1 + z2 | = 5, |z1 √− z2 | = 29.
value 500 − 5L. If L is greater than 100, then dPdr (c) z1 = 3 eπi/2 , z2 = 2 2e−πi/4 .
will be negative no matter the value of P . So 100
(2)
is the absolute maximum number of licenses that y
z1 z1 z2
6
can be issued. 5
(b) If the fish population is 500 when these 4
z1 /z2
3
licenses are issued then if nothing happens to
2
decrease the population below 500, the fish 1

population will stay at 500. x


2 4 6 8 10
-1 z2
(c) If the fish population ever drops below 500
then the population will drop to zero. So in (3) z = r cos(θ) + ir sin(θ). So
reality, the number of licenses issued should be z = r cos(θ) − ir sin(θ) = r cos(−θ) + ir sin(−θ)
less than 100. = re−iθ .
r cos(θ) − ir sin(θ)
Solution (4.9): z −1 = 2 = r cos(θ)−ir
r2
sin(θ)

(a) v(t) = 10(1 − e−t/10 . (b) 10 miles per hour. r cos2 (θ) + r2 sin2 (θ)
= r−1 (cos(−θ) + i sin(−θ)) = r−1 e−iθ .
ln(2r)
Solution (6.1): T (r) = 50 . Solution (5.3): (1)
ln(2)
5
 
x−iy
Solution (5.1): (1) (x + iy) = 1.
x2 +y 2
-10 -5 5
2 1
(2)(a) −2i, (b)− , (c) i, (d) −4. -5
5 2
(3) (a) This is a computation:
z + z = (x + iy) + (x − iy) (2) x(t) = Re (3 − 5i)e(−2+4i)t
= (x + x) + (y − y)i = 2x, which, by definition is
136


= 34e−2t cos(4t − tan−1 (5/3)). y
(3) x(t) = Re (2 + 3i)e(−1+4i)t . 2
Therefore, x00 (t) = Re (2 + 3i)(−1 + 4i)2 e(−1+4i)t
= Re (−6 − 61i)e(−1+4i)t x
-0.5 0.5 1 1.5 2
−t
= (−6
Z cos(4t) + 61 sin(4t))e
π π -2
Z 
(4) et/π sin(t) dt = Im e(1/π+i)t dt
0
1 π  0 -4
(1/π+i)t
= Im e
 1/π + i 

0
1   
= Im e (1+πi)
−1 = Im − π(e+1)
1+πi
1/π + i Solution (7.5):
π 2 (e+1) √
  
= π2 +1 2
(1) y(t) = Re 1 − √ i e(−1+ 3i)t
3
√ √
 
1 3 2
Solution (7.1): (1) y(t) = e−2t + e2t or y(t) = cos( 3t) + √ sin( 3t) e−t
4 4 3
i (2+√3i)(t−1)
 
1 1
(2) y(t) = e3(t−1) − et−1 (2) y(t) = Re − √ e
2 2
(3) y(t) = C1 e−3t + C2 e−t√ 1 √3 
√ or y(t) = √ sin 3(t − 1) e2(t−1)
(4) y(t) = C1 e− 3t + C2 e 3t 3
Solution (7.2): (1) y(t) = (t + 4)e−3t

(3) y(t) = Re Ce(−2+2i)t
(2) y(t) = (t − 1)e2(t−1)
or y(t) = (C1 cos(2t) + C2sin(2t)) e−2t
(3) y(t) = (C1 t + C2 )e−2t 
(4) y(t) = (C1 t + C2 )et (4) y(t) = Re Ce(−3+2i)t
Solution (7.3): or y(t) = (C1 cos(2t) + C2 sin(2t)) e−3t
The roots of the characteristic polynomial are
0 ± 5i, so the general solution is Solution (8.1):
y(t) = Re Ce5it . (a) A = 3, (b) ω0 = π
The initial conditions are y(0) = Re (C) = 1 and (c) φ = π/2.
y 0 (0) = Re (5iC) = 2. From the first initial Solution (8.2):
condition, we find that C = 1 + C2 i. (a) u(0) = 1.0 meters, u0 (0) = 0 meters/sec.
2
Hence, Re (5iC) = −5C2 = 2, so C = 1 − i (b) T = 0.5 sec.
√ 5
29 − tan−1 (2/5)i (c) k = 80π 2 ≈ 789.6 Newtons/meter
In polar form C = e . Solution (8.3):
√5 (a) deq = 10
29 π ≈ 3.183 meter.
cos t − tan−1 (2/5)

Therefore, y(t) = (b) 100d00 + 100πd = 1000.
5
≈ 1.08 cos(5t − 0.38). (c) 100y 00 + 100πy 0
√ = 0, y(0) = 1, y (0) = 0.
y (d) y(t) = cos( π t).
1 Solution (8.4):
(a) Force = 83126.5y dynes.
0.5
(b) 500y 00 + 83126.5y = 0. (c)
x y(t) = A cos(12.894t + φ).
-1 -0.5 0.5 1 1.5 2 (d) T = 0.4873 seconds.
-0.5 Solution (8.5): √
The weight will oscillate with a
period of T = 25π ≈ 3.5124 seconds, a frequency
-1
  of √25π cycles per second, stretching to a
Solution (7.4): y(t) = Re (2 − 3i)e(−1+5i)t . maximum amount of 20 feet and returning to its
√ unstretched position, with an amplitude of 10 feet.
y(t) = 13 e−t cos 5t − tan−1 (3/2) .

Solution (8.6):
x(t) = 2e−2.5t (cos(1.936t) + 0.516 sin(1.936t)) or
x(t) = 2.25e−2.5t cos(1.936t − 0.477).
Solution (8.7):
D. ANSWERS TO SELECTED PROBLEMS 137

(a) γ = 2 N-sec/meter 4 2
(g) y(t) = cos(t) + sin(t) − cos(2t) − sin(2t)
1 3 3
(b) y() = te−t . (h) y(t) = sin(4t) − cos(4t) + cos(2t) − 2 sin(2t)
2
1 −1 e−t
(c) e ≈ 0.1839 meter. (i) y(t) = cos(2t) + (C1 t + C2 )et
2 8
Solution (8.8): Solution (10.1):
5
(a) ωd ≈ 1.96, ζ ≈ 0.2,ω0 (a) k = 16π 2 N-sec/meter

(b) x00 + 0.8x0 + 4x = 0 (b) ω = 5πsec−1


(c) x0 (0) ≈ 7.8 (c) F0 ≈ 14.4 N
Solution (8.9): Solution (10.2): √
(a) 43 bounces (the period is approx 1.40 seconds) cos(t) − cos( gt)
√ θ(t) = ≈
(b) 4000 5 ≈ 8944 N-sec/meter g−1
1 0.011(cos(t) − cos(3.13t)). Solution (10.3):
(c) √ ≈ 0.082 meters. 1
2 5e y(t) = (e−3t + 3 sin(t) − cos(t)).
Solution (9.1): (a) 5
t2 1 √ √ Solution√ (10.4):
y(t) = + + C1 cos( 3t) + C2 sin( 3t) 377
3 9 u(t) = cos(3t + tan−1 (16/11) − π)
 − t cos(t).
(b) y(t) = sin(t) 87
≈ 0.223 cos(3t − 2.173).

t 3 2
(c) y(t) = e − cos(t) + sin(t) Solution (10.5):
13 13
−t/2
 √ √  γ 2 ω 2 cos(ωt) − mγω(ω02 − ω 2 ) sin(ωt)
+e C1 cos( 3t/2) + C2 sin( 3t/2) x(t) =
m2 (ω02 − ω 2 )2 + γ 2 ω 2
(d) y(t) = tet + C1 et + C2 γω
t 5 11 or x(t) = p 2
cos (ωt + φ) ,
2 2 2 2 2
(e) y(t) = e2t + e−2t + e2t m (ω0 − ω ) ) + γ ω
4 16 16 m(ω02 − ω 2 )
t2 2t where φ = tan−1 .
(f) y(t) = e + (C1 t + C2 )e2t γω
2
Index

ampere, 7 half-life, 31
argument, 52 harmonic oscillator, 4, 71
autonomous, 17 harmonic oscillator, driven, 89
Heaviside step function, 110
beats, 90 Henry, 7
British system, 3 homogeneous differential equation, 24
homogeneous differential equation, 61
carrying capacity, 42
cgs (centimeter-gram-second) system, 3 homogeneous linear differential equation, 21
characteristic polynomial, 64 Hooke’s Law, 4
complex conjugate, 50
imaginary part, 49
complex exponential function, 54
impulse, 116
conservation of energy, 43
impulse response function, 123
convolution, 121
independent solutions, 63
Convolution Theorem, 121
inductance, 7
coulomb, 7
initial value problem, 59
critical point, 17
initial condition, 10, 11, 59
damped harmonic oscillator, 76 initial value problem, 11
damping coefficient, 76 input-free solution, 124
Dirac Delta Function, 117 integral curve, 16
direction element, 15 integrating factor, 28
direction field, 15 intrinsic rate of growth, 42
drag, 34 inverse Laplace transform, 101, 105
drag coefficient, 34
driven harmonic oscillator, 89 kilogram (kg), 3
dyne (dyn), 3 Kirchhoff’s law, 8

electrical circuit, 7 Laplace transform, 101


equilibrium point, 17 line element, 15
Euler’s Formula, 54 linear differential equation, 21, 24
Euler’s method, 18 linear operator, 61
existence, 30, 62 linear second order differential equation, 61
exponential order, 104 logarithmic growth rate, 41
exponential shift formula, 105 logistic function, 40
logistic curve, 40, 42
Farad, 7 logistic equation, 39
first order differential equation, 9
fixed point, 17 micro Henries (µH), 7
forcing function, 21, 24, 61 mixing problems, 33
fundamental basis, 63 mks (meter-kilogram-second) system, 3
modulus, 50
G.F. Gause, 42
general solution, 63, 82 natural frequency, 89
139
140 INDEX

Newton (N), 3 second order differential equation, 9, 59


nonhomogeneous, 24 separable differential equation, 22
nonhomogeneous differential equation, 21 separable differential equation, 21
nonhomogeneous differential equation, 61 slug, 3
nonlinear differential equation, 24 solution, 9, 59
square wave, 111
ohm Ω, 7 stable equilibrium point, 17
state-free solution, 124
partial fractions expansion, 106, 131
steady state solution, 38, 92
particular solution, 29, 82
superposition principle, 61, 81
phase-shift formula, 129
piecewise continuous, 104 T. Carlson, 41
pound, 3 tangent line approximation, 18
pulse wave, 111 terminal velocity, 35
transfer function, 123
rational functions, 131 transient, 92
Raymond Pearl, 41
reproduction function, 41 undetermined coefficients, 83
resonance, 89 unique solution, 21, 22, 30, 62
resonant frequency, 92 unit of mass, 3
RLC-circuit, 7
well-mixing assumption, 33
sawtooth wave, 111 Wronskian, 63

You might also like