View
108
Download
18
Tags:
Embed Size (px)
Citation preview
Introduction to DifferentialEquations
Lecture notes for MATH 2351/2352
Jeffrey R. Chasnov
The Hong Kong University of
Science and Technology
The Hong Kong University of Science and TechnologyDepartment of MathematicsClear Water Bay, Kowloon
Hong Kong
Copyright cβ 2009β2013 by Jeffrey Robert Chasnov
This work is licensed under the Creative Commons Attribution 3.0 Hong Kong License.
To view a copy of this license, visit http://creativecommons.org/licenses/by/3.0/hk/
or send a letter to Creative Commons, 171 Second Street, Suite 300, San Francisco,
California, 94105, USA.
Preface
What follows are my lecture notes for a first course in differential equations,taught at the Hong Kong University of Science and Technology. Included inthese notes are links to short tutorial videos posted on YouTube.
Much of the material of Chapters 2-6 and 8 has been adapted from thewidely used textbook βElementary differential equations and boundary valueproblemsβ by Boyce & DiPrima (John Wiley & Sons, Inc., Seventh Edition,cβ2001). Many of the examples presented in these notes may be found in thisbook. The material of Chapter 7 is adapted from the textbook βNonlineardynamics and chaosβ by Steven H. Strogatz (Perseus Publishing, cβ1994).
All web surfers are welcome to download these notes, watch the YouTubevideos, and to use the notes and videos freely for teaching and learning. Iwelcome any comments, suggestions or corrections sent by email [email protected].
iii
Contents
0 A short mathematical review 1
0.1 The trigonometric functions . . . . . . . . . . . . . . . . . . . . . 1
0.2 The exponential function and the natural logarithm . . . . . . . 1
0.3 Definition of the derivative . . . . . . . . . . . . . . . . . . . . . 2
0.4 Differentiating a combination of functions . . . . . . . . . . . . . 2
0.4.1 The sum or difference rule . . . . . . . . . . . . . . . . . . 2
0.4.2 The product rule . . . . . . . . . . . . . . . . . . . . . . . 2
0.4.3 The quotient rule . . . . . . . . . . . . . . . . . . . . . . . 2
0.4.4 The chain rule . . . . . . . . . . . . . . . . . . . . . . . . 3
0.5 Differentiating elementary functions . . . . . . . . . . . . . . . . 3
0.5.1 The power rule . . . . . . . . . . . . . . . . . . . . . . . . 3
0.5.2 Trigonometric functions . . . . . . . . . . . . . . . . . . . 3
0.5.3 Exponential and natural logarithm functions . . . . . . . 3
0.6 Definition of the integral . . . . . . . . . . . . . . . . . . . . . . . 3
0.7 The fundamental theorem of calculus . . . . . . . . . . . . . . . . 4
0.8 Definite and indefinite integrals . . . . . . . . . . . . . . . . . . . 5
0.9 Indefinite integrals of elementary functions . . . . . . . . . . . . . 5
0.10 Substitution . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6
0.11 Integration by parts . . . . . . . . . . . . . . . . . . . . . . . . . 6
0.12 Taylor series . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7
0.13 Complex numbers . . . . . . . . . . . . . . . . . . . . . . . . . . 8
1 Introduction to odes 11
1.1 The simplest type of differential equation . . . . . . . . . . . . . 11
2 First-order odes 13
2.1 The Euler method . . . . . . . . . . . . . . . . . . . . . . . . . . 13
2.2 Separable equations . . . . . . . . . . . . . . . . . . . . . . . . . 14
2.3 Linear equations . . . . . . . . . . . . . . . . . . . . . . . . . . . 17
2.4 Applications . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20
2.4.1 Compound interest with deposits or withdrawals . . . . . 20
2.4.2 Chemical reactions . . . . . . . . . . . . . . . . . . . . . . 21
2.4.3 The terminal velocity of a falling mass . . . . . . . . . . . 23
2.4.4 Escape velocity . . . . . . . . . . . . . . . . . . . . . . . . 24
2.4.5 The logistic equation . . . . . . . . . . . . . . . . . . . . . 26
v
vi CONTENTS
3 Second-order odes, constant coefficients 293.1 The Euler method . . . . . . . . . . . . . . . . . . . . . . . . . . 293.2 The principle of superposition . . . . . . . . . . . . . . . . . . . . 303.3 The Wronskian . . . . . . . . . . . . . . . . . . . . . . . . . . . . 303.4 Homogeneous odes . . . . . . . . . . . . . . . . . . . . . . . . . . 31
3.4.1 Real, distinct roots . . . . . . . . . . . . . . . . . . . . . . 323.4.2 Complex conjugate, distinct roots . . . . . . . . . . . . . 343.4.3 Repeated roots . . . . . . . . . . . . . . . . . . . . . . . . 36
3.5 Inhomogeneous odes . . . . . . . . . . . . . . . . . . . . . . . . . 373.6 First-order linear inhomogeneous odes revisited . . . . . . . . . . 413.7 Resonance . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 423.8 Damped resonance . . . . . . . . . . . . . . . . . . . . . . . . . . 44
4 The Laplace transform 474.1 Definition and properties . . . . . . . . . . . . . . . . . . . . . . . 474.2 Solution of initial value problems . . . . . . . . . . . . . . . . . . 514.3 Heaviside and Dirac delta functions . . . . . . . . . . . . . . . . . 54
4.3.1 Heaviside function . . . . . . . . . . . . . . . . . . . . . . 544.3.2 Dirac delta function . . . . . . . . . . . . . . . . . . . . . 56
4.4 Discontinuous or impulsive terms . . . . . . . . . . . . . . . . . . 57
5 Series solutions 615.1 Ordinary points . . . . . . . . . . . . . . . . . . . . . . . . . . . . 615.2 Regular singular points: Cauchy-Euler equations . . . . . . . . . 65
5.2.1 Real, distinct roots . . . . . . . . . . . . . . . . . . . . . . 675.2.2 Complex conjugate roots . . . . . . . . . . . . . . . . . . 675.2.3 Repeated roots . . . . . . . . . . . . . . . . . . . . . . . . 67
6 Systems of equations 696.1 Determinants and the eigenvalue problem . . . . . . . . . . . . . 696.2 Coupled first-order equations . . . . . . . . . . . . . . . . . . . . 71
6.2.1 Two distinct real eigenvalues . . . . . . . . . . . . . . . . 716.2.2 Complex conjugate eigenvalues . . . . . . . . . . . . . . . 756.2.3 Repeated eigenvalues with one eigenvector . . . . . . . . . 77
6.3 Normal modes . . . . . . . . . . . . . . . . . . . . . . . . . . . . 79
7 Nonlinear differential equations 837.1 Fixed points and stability . . . . . . . . . . . . . . . . . . . . . . 83
7.1.1 One dimension . . . . . . . . . . . . . . . . . . . . . . . . 837.1.2 Two dimensions . . . . . . . . . . . . . . . . . . . . . . . 84
7.2 One-dimensional bifurcations . . . . . . . . . . . . . . . . . . . . 877.2.1 Saddle-node bifurcation . . . . . . . . . . . . . . . . . . . 877.2.2 Transcritical bifurcation . . . . . . . . . . . . . . . . . . . 887.2.3 Supercritical pitchfork bifurcation . . . . . . . . . . . . . 887.2.4 Subcritical pitchfork bifurcation . . . . . . . . . . . . . . 897.2.5 Application: a mathematical model of a fishery . . . . . . 92
7.3 Two-dimensional bifurcations . . . . . . . . . . . . . . . . . . . . 947.3.1 Supercritical Hopf bifurcation . . . . . . . . . . . . . . . . 947.3.2 Subcritical Hopf bifurcation . . . . . . . . . . . . . . . . . 95
CONTENTS vii
8 Partial differential equations 978.1 Derivation of the diffusion equation . . . . . . . . . . . . . . . . . 978.2 Derivation of the wave equation . . . . . . . . . . . . . . . . . . . 988.3 Fourier series . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1008.4 Fourier cosine and sine series . . . . . . . . . . . . . . . . . . . . 1028.5 Solution of the diffusion equation . . . . . . . . . . . . . . . . . . 104
8.5.1 Homogeneous boundary conditions . . . . . . . . . . . . . 1048.5.2 Inhomogeneous boundary conditions . . . . . . . . . . . . 1088.5.3 Pipe with closed ends . . . . . . . . . . . . . . . . . . . . 109
8.6 Solution of the wave equation . . . . . . . . . . . . . . . . . . . . 1128.6.1 Plucked string . . . . . . . . . . . . . . . . . . . . . . . . 1128.6.2 Hammered string . . . . . . . . . . . . . . . . . . . . . . . 1148.6.3 General initial conditions . . . . . . . . . . . . . . . . . . 114
8.7 The Laplace equation . . . . . . . . . . . . . . . . . . . . . . . . 1158.7.1 Dirichlet problem for a rectangle . . . . . . . . . . . . . . 1158.7.2 Dirichlet problem for a circle . . . . . . . . . . . . . . . . 116
viii CONTENTS
Chapter 0
A short mathematicalreview
A basic understanding of calculus is required to undertake a study of differentialequations. This zero chapter presents a short review.
0.1 The trigonometric functions
The Pythagorean trigonometric identity is
sin2 π₯+ cos2 π₯ = 1,
and the addition theorems are
sin(π₯+ π¦) = sin(π₯) cos(π¦) + cos(π₯) sin(π¦),
cos(π₯+ π¦) = cos(π₯) cos(π¦)β sin(π₯) sin(π¦).
Also, the values of sinπ₯ in the first quadrant can be remembered by the rule ofquarters, with 0β = 0, 30β = π/6, 45β = π/4, 60β = π/3, 90β = π/2:
sin 0β =
β0
4, sin 30β =
β1
4, sin 45β =
β2
4,
sin 60β =
β3
4, sin 90β =
β4
4.
The following symmetry properties are also useful:
sin(π/2β π₯) = cosπ₯, cos(π/2β π₯) = sinπ₯;
andsin(βπ₯) = β sin(π₯), cos(βπ₯) = cos(π₯).
0.2 The exponential function and the naturallogarithm
The transcendental number π, approximately 2.71828, is defined as
π = limπββ
(1 +
1
π
)π
.
1
2 CHAPTER 0. A SHORT MATHEMATICAL REVIEW
The exponential function exp (π₯) = ππ₯ and natural logarithm lnπ₯ are inversefunctions satisfying
πln π₯ = π₯, ln ππ₯ = π₯.
The usual rules of exponents apply:
ππ₯ππ¦ = ππ₯+π¦, ππ₯/ππ¦ = ππ₯βπ¦, (ππ₯)π = πππ₯.
The corresponding rules for the logarithmic function are
ln (π₯π¦) = lnπ₯+ ln π¦, ln (π₯/π¦) = lnπ₯β ln π¦, lnπ₯π = π lnπ₯.
0.3 Definition of the derivative
The derivative of the function π¦ = π(π₯), denoted as π β²(π₯) or ππ¦/ππ₯, is definedas the slope of the tangent line to the curve π¦ = π(π₯) at the point (π₯, π¦). Thisslope is obtained by a limit, and is defined as
π β²(π₯) = limββ0
π(π₯+ β)β π(π₯)
β. (1)
0.4 Differentiating a combination of functions
0.4.1 The sum or difference rule
The derivative of the sum of π(π₯) and π(π₯) is
(π + π)β² = π β² + πβ².
Similarly, the derivative of the difference is
(π β π)β² = π β² β πβ².
0.4.2 The product rule
The derivative of the product of π(π₯) and π(π₯) is
(ππ)β² = π β²π + ππβ²,
and should be memorized as βthe derivative of the first times the second plusthe first times the derivative of the second.β
0.4.3 The quotient rule
The derivative of the quotient of π(π₯) and π(π₯) is(π
π
)β²
=π β²π β ππβ²
π2,
and should be memorized as βthe derivative of the top times the bottom minusthe top times the derivative of the bottom over the bottom squared.β
0.5. DIFFERENTIATING ELEMENTARY FUNCTIONS 3
0.4.4 The chain rule
The derivative of the composition of π(π₯) and π(π₯) is(π(π(π₯)
))β²= π β²(π(π₯)) Β· πβ²(π₯),
and should be memorized as βthe derivative of the outside times the derivativeof the inside.β
0.5 Differentiating elementary functions
0.5.1 The power rule
The derivative of a power of π₯ is given by
π
ππ₯π₯π = ππ₯πβ1.
0.5.2 Trigonometric functions
The derivatives of sinπ₯ and cosπ₯ are
(sinπ₯)β² = cosπ₯, (cosπ₯)β² = β sinπ₯.
We thus say that βthe derivative of sine is cosine,β and βthe derivative of cosineis minus sine.β Notice that the second derivatives satisfy
(sinπ₯)β²β² = β sinπ₯, (cosπ₯)β²β² = β cosπ₯.
0.5.3 Exponential and natural logarithm functions
The derivative of ππ₯ and lnπ₯ are
(ππ₯)β² = ππ₯, (lnπ₯)β² =1
π₯.
0.6 Definition of the integral
The definite integral of a function π(π₯) > 0 from π₯ = π to π (π > π) is definedas the area bounded by the vertical lines π₯ = π, π₯ = π, the x-axis and the curveπ¦ = π(π₯). This βarea under the curveβ is obtained by a limit. First, the area isapproximated by a sum of rectangle areas. Second, the integral is defined to bethe limit of the rectangle areas as the width of each individual rectangle goes tozero and the number of rectangles goes to infinity. This resulting infinite sumis called a Riemann Sum, and we defineβ« π
π
π(π₯)ππ₯ = limββ0
πβπ=1
π(π+ (πβ 1)β
)Β· β, (2)
where π = (π β π)/β is the number of terms in the sum. The symbols on theleft-hand-side of (2) are read as βthe integral from π to π of f of x dee x.β The
4 CHAPTER 0. A SHORT MATHEMATICAL REVIEW
Riemann Sum definition is extended to all values of π and π and for all valuesof π(π₯) (positive and negative). Accordingly,
β« π
π
π(π₯)ππ₯ = ββ« π
π
π(π₯)ππ₯ and
β« π
π
(βπ(π₯))ππ₯ = ββ« π
π
π(π₯)ππ₯.
Also, if π < π < π, then
β« π
π
π(π₯)ππ₯ =
β« π
π
π(π₯)ππ₯+
β« π
π
π(π₯)ππ₯,
which states (when π(π₯) > 0) that the total area equals the sum of its parts.
0.7 The fundamental theorem of calculus
view tutorial
Using the definition of the derivative, we differentiate the following integral:
π
ππ₯
β« π₯
π
π(π )ππ = limββ0
β« π₯+β
ππ(π )ππ β
β« π₯
ππ(π )ππ
β
= limββ0
β« π₯+β
π₯π(π )ππ
β
= limββ0
βπ(π₯)
β
= π(π₯).
This result is called the fundamental theorem of calculus, and provides a con-nection between differentiation and integration.
The fundamental theorem teaches us how to integrate functions. Let πΉ (π₯)be a function such that πΉ β²(π₯) = π(π₯). We say that πΉ (π₯) is an antiderivative ofπ(π₯). Then from the fundamental theorem and the fact that the derivative of aconstant equals zero,
πΉ (π₯) =
β« π₯
π
π(π )ππ + π.
Now, πΉ (π) = π and πΉ (π) =β« π
ππ(π )ππ + πΉ (π). Therefore, the fundamental
theorem shows us how to integrate a function π(π₯) provided we can find itsantiderivative: β« π
π
π(π )ππ = πΉ (π)β πΉ (π). (3)
Unfortunately, finding antiderivatives is much harder than finding derivatives,and indeed, most complicated functions cannot be integrated analytically.
We can also derive the very important result (3) directly from the definitionof the derivative (1) and the definite integral (2). We will see it is convenient
0.8. DEFINITE AND INDEFINITE INTEGRALS 5
to choose the same β in both limits. With πΉ β²(π₯) = π(π₯), we haveβ« π
π
π(π )ππ =
β« π
π
πΉ β²(π )ππ
= limββ0
πβπ=1
πΉ β²(π+ (πβ 1)β)Β· β
= limββ0
πβπ=1
πΉ (π+ πβ)β πΉ(π+ (πβ 1)β
)β
Β· β
= limββ0
πβπ=1
πΉ (π+ πβ)β πΉ(π+ (πβ 1)β
).
The last expression has an interesting structure. All the values of πΉ (π₯) eval-uated at the points lying between the endpoints π and π cancel each other inconsecutive terms. Only the value βπΉ (π) survives when π = 1, and the value+πΉ (π) when π = π , yielding again (3).
0.8 Definite and indefinite integrals
The Riemann sum definition of an integral is called a definite integral. It isconvenient to also define an indefinite integral byβ«
π(π₯)ππ₯ = πΉ (π₯),
where F(x) is the antiderivative of π(π₯).
0.9 Indefinite integrals of elementary functions
From our known derivatives of elementary functions, we can determine somesimple indefinite integrals. The power rule gives usβ«
π₯πππ₯ =π₯π+1
π+ 1+ π, π = β1.
When π = β1, and π₯ is positive, we haveβ«1
π₯ππ₯ = lnπ₯+ π.
If π₯ is negative, using the chain rule we have
π
ππ₯ln (βπ₯) =
1
π₯.
Therefore, since
|π₯| ={
βπ₯ if π₯ < 0;π₯ if π₯ > 0,
we can generalize our indefinite integral to strictly positive or strictly negativeπ₯: β«
1
π₯ππ₯ = ln |π₯|+ π.
6 CHAPTER 0. A SHORT MATHEMATICAL REVIEW
Trigonometric functions can also be integrated:β«cosπ₯ππ₯ = sinπ₯+ π,
β«sinπ₯ππ₯ = β cosπ₯+ π.
Easily proved identities are an addition rule:β« (π(π₯) + π(π₯)
)ππ₯ =
β«π(π₯)ππ₯+
β«π(π₯)ππ₯;
and multiplication by a constant:β«π΄π(π₯)ππ₯ = π΄
β«π(π₯)ππ₯.
This permits integration of functions such asβ«(π₯2 + 7π₯+ 2)ππ₯ =
π₯3
3+
7π₯2
2+ 2π₯+ π,
and β«(5 cosπ₯+ sinπ₯)ππ₯ = 5 sinπ₯β cosπ₯+ π.
0.10 Substitution
More complicated functions can be integrated using the chain rule. Since
π
ππ₯π(π(π₯)
)= π β²(π(π₯)) Β· πβ²(π₯),
we have β«π β²(π(π₯)) Β· πβ²(π₯)ππ₯ = π
(π(π₯)
)+ π.
This integration formula is usually implemented by letting π¦ = π(π₯). Then onewrites ππ¦ = πβ²(π₯)ππ₯ to obtainβ«
π β²(π(π₯))πβ²(π₯)ππ₯ =
β«π β²(π¦)ππ¦
= π(π¦) + π
= π(π(π₯)
)+ π.
0.11 Integration by parts
Another integration technique makes use of the product rule for differentiation.Since
(ππ)β² = π β²π + ππβ²,
we haveπ β²π = (ππ)β² β ππβ².
Therefore, β«π β²(π₯)π(π₯)ππ₯ = π(π₯)π(π₯)β
β«π(π₯)πβ²(π₯)ππ₯.
0.12. TAYLOR SERIES 7
Commonly, the above integral is done by writing
π’ = π(π₯) ππ£ = π β²(π₯)ππ₯
ππ’ = πβ²(π₯)ππ₯ π£ = π(π₯).
Then, the formula to be memorized isβ«π’ππ£ = π’π£ β
β«π£ππ’.
0.12 Taylor series
A Taylor series of a function π(π₯) about a point π₯ = π is a power series rep-resentation of π(π₯) developed so that all the derivatives of π(π₯) at π match allthe derivatives of the power series. Without worrying about convergence here,we have
π(π₯) = π(π) + π β²(π)(π₯β π) +π β²β²(π)
2!(π₯β π)2 +
π β²β²β²(π)
3!(π₯β π)3 + . . . .
Notice that the first term in the power series matches π(π), all other termsvanishing, the second term matches π β²(π), all other terms vanishing, etc. Com-monly, the Taylor series is developed with π = 0. We will also make use of theTaylor series in a slightly different form, with π₯ = π₯* + π and π = π₯*:
π(π₯* + π) = π(π₯*) + π β²(π₯*)π+π β²β²(π₯*)
2!π2 +
π β²β²β²(π₯*)
3!π3 + . . . .
Another way to view this series is that of π(π) = π(π₯* + π), expanded aboutπ = 0.
Taylor series that are commonly used include
ππ₯ = 1 + π₯+π₯2
2!+
π₯3
3!+ . . . ,
sinπ₯ = π₯β π₯3
3!+
π₯5
5!β . . . ,
cosπ₯ = 1β π₯2
2!+
π₯4
4!β . . . ,
1
1 + π₯= 1β π₯+ π₯2 β . . . , for |π₯| < 1,
ln (1 + π₯) = π₯β π₯2
2+
π₯3
3β . . . , for |π₯| < 1.
A Taylor series of a function of several variables can also be developed. Here,all partial derivatives of π(π₯, π¦) at (π, π) match all the partial derivatives of thepower series. With the notation
ππ₯ =ππ
ππ₯, ππ¦ =
ππ
ππ¦, ππ₯π₯ =
π2π
ππ₯2, ππ₯π¦ =
π2π
ππ₯ππ¦, ππ¦π¦ =
π2π
ππ¦2, etc.,
we have
π(π₯, π¦) = π(π, π) + ππ₯(π, π)(π₯β π) + ππ¦(π, π)(π¦ β π)
+1
2!
(ππ₯π₯(π, π)(π₯β π)2 + 2ππ₯π¦(π, π)(π₯β π)(π¦ β π) + ππ¦π¦(π, π)(π¦ β π)2
)+ . . .
8 CHAPTER 0. A SHORT MATHEMATICAL REVIEW
0.13 Complex numbers
view tutorial: Complex Numbersview tutorial: Complex Exponential Function
We define the imaginary number π to be one of the two numbers that satisfiesthe rule (π)2 = β1, the other number being βπ. Formally, we write π =
ββ1. A
complex number π§ is written as
π§ = π₯+ ππ¦,
where π₯ and π¦ are real numbers. We call π₯ the real part of π§ and π¦ the imaginarypart and write
π₯ = Re π§, π¦ = Im π§.
Two complex numbers are equal if and only if their real and imaginary partsare equal.
The complex conjugate of π§ = π₯+ ππ¦, denoted as π§, is defined as
π§ = π₯β ππ¦.
Using π§ and π§, we have
Re π§ =1
2(π§ + π§) , Im π§ =
1
2π(π§ β π§) .
Furthermore,
π§π§ = (π₯+ ππ¦)(π₯β ππ¦)
= π₯2 β π2π¦2
= π₯2 + π¦2;
and we define the absolute value of π§, also called the modulus of π§, by
|π§| = (π§π§)1/2
=βπ₯2 + π¦2.
We can add, subtract, multiply and divide complex numbers to get newcomplex numbers. With π§ = π₯+ ππ¦ and π€ = π + ππ‘, and π₯, π¦, π , π‘ real numbers,we have
π§ + π€ = (π₯+ π ) + π(π¦ + π‘); π§ β π€ = (π₯β π ) + π(π¦ β π‘);
π§π€ = (π₯+ ππ¦)(π + ππ‘)
= (π₯π β π¦π‘) + π(π₯π‘+ π¦π );
π§
π€=
π§οΏ½οΏ½
π€οΏ½οΏ½
=(π₯+ ππ¦)(π β ππ‘)
π 2 + π‘2
=(π₯π + π¦π‘)
π 2 + π‘2+ π
(π¦π β π₯π‘)
π 2 + π‘2.
0.13. COMPLEX NUMBERS 9
Furthermore,
|π§π€| =β(π₯π β π¦π‘)2 + (π₯π‘+ π¦π )2
=β(π₯2 + π¦2)(π 2 + π‘2)
= |π§||π€|;
and
π§π€ = (π₯π β π¦π‘)β π(π₯π‘+ π¦π )
= (π₯β ππ¦)(π β ππ‘)
= π§οΏ½οΏ½.
Similarly π§π€
=
|π§||π€|
, (π§
π€) =
π§
οΏ½οΏ½.
Also, π§ + π€ = π§ + π€. However, |π§ + π€| β€ |π§| + |π€|, a theorem known as thetriangle inequality.
It is especially interesting and useful to consider the exponential function ofan imaginary argument. Using the Taylor series expansion of an exponentialfunction, we have
πππ = 1 + (ππ) +(ππ)2
2!+
(ππ)3
3!+
(ππ)4
4!+
(ππ)5
5!. . .
=
(1β π2
2!+
π4
4!β . . .
)+ π
(π β π3
3!+
π5
5!+ . . .
)= cos π + π sin π.
Therefore, we havecos π = Re πππ, sin π = Im πππ.
Since cosπ = β1 and sinπ = 0, we derive the celebrated Eulerβs identity
πππ + 1 = 0,
that links five fundamental numbers, 0, 1, π, π and π, using three basic mathe-matical operations, addition, multiplication and exponentiation, only once.
Using the even property cos (βπ) = cos π and the odd property sin (βπ) =β sin π, we also have
πβππ = cos π β π sin π;
and the identities for πππ and πβππ results in the frequently used expressions,
cos π =πππ + πβππ
2, sin π =
πππ β πβππ
2π.
The complex number π§ can be represented in the complex plane with Re π§as the π₯-axis and Im π§ as the π¦-axis. This leads to the polar representation ofπ§ = π₯+ ππ¦:
π§ = ππππ,
where π = |π§| and tan π = π¦/π₯. We define arg π§ = π. Note that π is not unique,though it is conventional to choose the value such that βπ < π β€ π, and π = 0when π = 0.
10 CHAPTER 0. A SHORT MATHEMATICAL REVIEW
Useful trigonometric relations can be derived using πππ and properties of theexponential function. The addition law can be derived from
ππ(π₯+π¦) = πππ₯πππ¦.
We have
cos(π₯+ π¦) + π sin(π₯+ π¦) = (cosπ₯+ π sinπ₯)(cos π¦ + π sin π¦)
= (cosπ₯ cos π¦ β sinπ₯ sin π¦) + π(sinπ₯ cos π¦ + cosπ₯ sin π¦);
yielding
cos(π₯+ π¦) = cosπ₯ cos π¦ β sinπ₯ sin π¦, sin(π₯+ π¦) = sinπ₯ cos π¦ + cosπ₯ sin π¦.
De Moivreβs Theorem derives from ππππ = (πππ)π, yielding the identity
cos(ππ) + π sin(ππ) = (cos π + π sin π)π.
For example, if π = 2, we derive
cos 2π + π sin 2π = (cos π + π sin π)2
= (cos2 π β sin2 π) + 2π cos π sin π.
Therefore,cos 2π = cos2 π β sin2 π, sin 2π = 2 cos π sin π.
With a little more manipulation using cos2 π + sin2 π = 1, we can derive
cos2 π =1 + cos 2π
2, sin2 π =
1β cos 2π
2,
which are useful formulas for determiningβ«cos2 π ππ =
1
4(2π + sin 2π) + π,
β«sin2 π ππ =
1
4(2π β sin 2π) + π,
from which follows β« 2π
0
sin2 π ππ =
β« 2π
0
cos2 π ππ = π.
Chapter 1
Introduction to odes
A differential equation is an equation for a function that relates the values ofthe function to the values of its derivatives. An ordinary differential equation(ode) is a differential equation for a function of a single variable, e.g., π₯(π‘), whilea partial differential equation (pde) is a differential equation for a function ofseveral variables, e.g., π£(π₯, π¦, π§, π‘). An ode contains ordinary derivatives and apde contains partial derivatives. Typically, pdeβs are much harder to solve thanodeβs.
1.1 The simplest type of differential equation
view tutorialThe simplest ordinary differential equations can be integrated directly by findingantiderivatives. These simplest odes have the form
πππ₯
ππ‘π= πΊ(π‘),
where the derivative of π₯ = π₯(π‘) can be of any order, and the right-hand-sidemay depend only on the independent variable π‘. As an example, consider a massfalling under the influence of constant gravity, such as approximately found onthe Earthβs surface. Newtonβs law, πΉ = ππ, results in the equation
ππ2π₯
ππ‘2= βππ,
where π₯ is the height of the object above the ground, π is the mass of theobject, and π = 9.8 meter/sec2 is the constant gravitational acceleration. AsGalileo suggested, the mass cancels from the equation, and
π2π₯
ππ‘2= βπ.
Here, the right-hand-side of the ode is a constant. The first integration, obtainedby antidifferentiation, yields
ππ₯
ππ‘= π΄β ππ‘,
11
12 CHAPTER 1. INTRODUCTION TO ODES
with π΄ the first constant of integration; and the second integration yields
π₯ = π΅ +π΄π‘β 1
2ππ‘2,
with π΅ the second constant of integration. The two constants of integration π΄and π΅ can then be determined from the initial conditions. If we know that theinitial height of the mass is π₯0, and the initial velocity is π£0, then the initialconditions are
π₯(0) = π₯0,ππ₯
ππ‘(0) = π£0.
Substitution of these initial conditions into the equations for ππ₯/ππ‘ and π₯ allowsus to solve for π΄ and π΅. The unique solution that satisfies both the ode andthe initial conditions is given by
π₯(π‘) = π₯0 + π£0π‘β1
2ππ‘2. (1.1)
For example, suppose we drop a ball off the top of a 50 meter building. Howlong will it take the ball to hit the ground? This question requires solution of(1.1) for the time π it takes for π₯(π ) = 0, given π₯0 = 50 meter and π£0 = 0.Solving for π ,
π =
β2π₯0
π
=
β2 Β· 509.8
sec
β 3.2sec.
Chapter 2
First-order differentialequations
Reference: Boyce and DiPrima, Chapter 2
The general first-order differential equation for the function π¦ = π¦(π₯) is writtenas
ππ¦
ππ₯= π(π₯, π¦), (2.1)
where π(π₯, π¦) can be any function of the independent variable π₯ and the depen-dent variable π¦. We first show how to determine a numerical solution of thisequation, and then learn techniques for solving analytically some special formsof (2.1), namely, separable and linear first-order equations.
2.1 The Euler method
view tutorialAlthough it is not always possible to find an analytical solution of (2.1) forπ¦ = π¦(π₯), it is always possible to determine a unique numerical solution givenan initial value π¦(π₯0) = π¦0, and provided π(π₯, π¦) is a well-behaved function.The differential equation (2.1) gives us the slope π(π₯0, π¦0) of the tangent lineto the solution curve π¦ = π¦(π₯) at the point (π₯0, π¦0). With a small step sizeΞπ₯, the initial condition (π₯0, π¦0) can be marched forward in the x-coordinateto π₯ = π₯0 +Ξπ₯, and along the tangent line using Eulerβs method to obtain they-coordinate
π¦(π₯0 +Ξπ₯) = π¦(π₯0) + Ξπ₯π(π₯0, π¦0).
This solution (π₯0 +Ξπ₯, π¦0 +Ξπ¦) then becomes the new initial condition and ismarched forward in the x-coordinate another Ξπ₯, and along the newly deter-mined tangent line. For small enough Ξπ₯, the numerical solution converges tothe exact solution.
13
14 CHAPTER 2. FIRST-ORDER ODES
2.2 Separable equations
view tutorial
A first-order ode is separable if it can be written in the form
π(π¦)ππ¦
ππ₯= π(π₯), π¦(π₯0) = π¦0, (2.2)
where the function π(π¦) is independent of π₯ and π(π₯) is independent of π¦. Inte-gration from π₯0 to π₯ results inβ« π₯
π₯0
π(π¦(π₯))π¦β²(π₯)ππ₯ =
β« π₯
π₯0
π(π₯)ππ₯.
The integral on the left can be transformed by substituting π’ = π¦(π₯), ππ’ =π¦β²(π₯)ππ₯, and changing the lower and upper limits of integration to π¦(π₯0) = π¦0and π¦(π₯) = π¦. Therefore, β« π¦
π¦0
π(π’)ππ’ =
β« π₯
π₯0
π(π₯)ππ₯,
and since π’ is a dummy variable of integration, we can write this in the equivalentform β« π¦
π¦0
π(π¦)ππ¦ =
β« π₯
π₯0
π(π₯)ππ₯. (2.3)
A simpler procedure that also yields (2.3) is to treat ππ¦/ππ₯ in (2.2) like a fraction.Multiplying (2.2) by ππ₯ results in
π(π¦)ππ¦ = π(π₯)ππ₯,
which is a separated equation with all the dependent variables on the left-side,and all the independent variables on the right-side. Equation (2.3) then resultsdirectly upon integration.
Example: Solve ππ¦ππ₯ + 1
2π¦ = 32 , with π¦(0) = 2.
We first manipulate the differential equation to the form
ππ¦
ππ₯=
1
2(3β π¦), (2.4)
and then treat ππ¦/ππ₯ as if it was a fraction to separate variables:
ππ¦
3β π¦=
1
2ππ₯.
We integrate the right-side from the initial condition π₯ = 0 to π₯ and the left-sidefrom the initial condition π¦(0) = 2 to π¦. Accordingly,β« π¦
2
ππ¦
3β π¦=
1
2
β« π₯
0
ππ₯. (2.5)
2.2. SEPARABLE EQUATIONS 15
0 1 2 3 4 5 6 70
1
2
3
4
5
6
x
y
dy/dx + y/2 = 3/2
Figure 2.1: Solution of the following ode: ππ¦ππ₯ + 1
2π¦ = 32 .
The integrals in (2.5) need to be done. Note that π¦(π₯) < 3 for finite π₯ or theintegral on the left-side diverges. Therefore, 3β π¦ > 0 and integration yields
β ln (3β π¦)]π¦2=
1
2π₯]π₯0,
ln (3β π¦) = β1
2π₯,
3β π¦ = πβ12π₯,
π¦ = 3β πβ12π₯.
Since this is our first nontrivial analytical solution, it is prudent to check ourresult. We do this by differentiating our solution:
ππ¦
ππ₯=
1
2πβ
12π₯
=1
2(3β π¦);
and checking the initial conditions, π¦(0) = 3 β π0 = 2. Therefore, our solutionsatisfies both the original ode and the initial condition.
Example: Solve ππ¦ππ₯ + 1
2π¦ = 32 , with π¦(0) = 4.
This is the identical differential equation as before, but with different initialconditions. We will jump directly to the integration step:β« π¦
4
ππ¦
3β π¦=
1
2
β« π₯
0
ππ₯.
16 CHAPTER 2. FIRST-ORDER ODES
Now π¦(π₯) > 3, so that π¦ β 3 > 0 and integration yields
β ln (π¦ β 3)]π¦4=
1
2π₯]π₯0,
ln (π¦ β 3) = β1
2π₯,
π¦ β 3 = πβ12π₯,
π¦ = 3 + πβ12π₯.
The solution curves for a range of initial conditions is presented in Fig. 2.1.All solutions have a horizontal asymptote at π¦ = 3 at which ππ¦/ππ₯ = 0. Forπ¦(0) = π¦0, the general solution can be shown to be π¦(π₯) = 3+(π¦0β3) exp(βπ₯/2).
Example: Solve ππ¦ππ₯ = 2 cos 2π₯
3+2π¦ , with π¦(0) = β1. (i) For what values of
π₯ > 0 does the solution exist? (ii) For what value of π₯ > 0 is π¦(π₯)maximum?
Notice that the solution of the ode may not exist when π¦ = β3/2, since ππ¦/ππ₯ ββ. We separate variables and integrate from initial conditions:
(3 + 2π¦)ππ¦ = 2 cos 2π₯ ππ₯β« π¦
β1
(3 + 2π¦)ππ¦ = 2
β« π₯
0
cos 2π₯ ππ₯
3π¦ + π¦2]π¦β1
= sin 2π₯]π₯0
π¦2 + 3π¦ + 2β sin 2π₯ = 0
π¦Β± =1
2[β3Β±
β1 + 4 sin 2π₯].
Solving the quadratic equation for π¦ has introduced a spurious solution thatdoes not satisfy the initial conditions. We test:
π¦Β±(0) =1
2[β3Β± 1] =
{-1;-2.
Only the + root satisfies the initial condition, so that the unique solution to theode and initial condition is
π¦ =1
2[β3 +
β1 + 4 sin 2π₯]. (2.6)
To determine (i) the values of π₯ > 0 for which the solution exists, we require
1 + 4 sin 2π₯ β₯ 0,
or
sin 2π₯ β₯ β1
4. (2.7)
Notice that at π₯ = 0, we have sin 2π₯ = 0; at π₯ = π/4, we have sin 2π₯ = 1;at π₯ = π/2, we have sin 2π₯ = 0; and at π₯ = 3π/4, we have sin 2π₯ = β1 Wetherefore need to determine the value of π₯ such that sin 2π₯ = β1/4, with π₯ inthe range π/2 < π₯ < 3π/4. The solution to the ode will then exist for all π₯between zero and this value.
2.3. LINEAR EQUATIONS 17
0 0.5 1 1.5β1.6
β1.4
β1.2
β1
β0.8
β0.6
β0.4
β0.2
0
x
y
(3+2y) dy/dx = 2 cos 2x, y(0) = β1
Figure 2.2: Solution of the following ode: (3 + 2π¦)π¦β² = 2 cos 2π₯, π¦(0) = β1.
To solve sin 2π₯ = β1/4 for π₯ in the interval π/2 < π₯ < 3π/4, one needs torecall the definition of arcsin, or sinβ1, as found on a typical scientific calculator.The inverse of the function
π(π₯) = sinπ₯, βπ/2 β€ π₯ β€ π/2
is denoted by arcsin. The first solution with π₯ > 0 of the equation sin 2π₯ = β1/4places 2π₯ in the interval (π, 3π/2), so to invert this equation using the arcsinewe need to apply the identity sin (π β π₯) = sinπ₯, and rewrite sin 2π₯ = β1/4 assin (π β 2π₯) = β1/4. The solution of this equation may then be found by takingthe arcsine, and is
π β 2π₯ = arcsin (β1/4),
or
π₯ =1
2
(π + arcsin
1
4
).
Therefore the solution exists for 0 β€ π₯ β€ (π + arcsin (1/4)) /2 = 1.6971 . . . ,where we have used a calculator value (computing in radians) to find arcsin(0.25) =0.2527 . . . . At the value (π₯, π¦) = (1.6971 . . . ,β3/2), the solution curve ends andππ¦/ππ₯ becomes infinite.
To determine (ii) the value of π₯ at which π¦ = π¦(π₯) is maximum, we examine(2.6) directly. The value of π¦ will be maximum when sin 2π₯ takes its maximumvalue over the interval where the solution exists. This will be when 2π₯ = π/2,or π₯ = π/4 = 0.7854 . . . .
The graph of π¦ = π¦(π₯) is shown in Fig. 2.2.
2.3 Linear equations
view tutorial
18 CHAPTER 2. FIRST-ORDER ODES
The first-order linear differential equation (linear in π¦ and its derivative) can bewritten in the form
ππ¦
ππ₯+ π(π₯)π¦ = π(π₯), (2.8)
with the initial condition π¦(π₯0) = π¦0. Linear first-order equations can be inte-grated using an integrating factor π(π₯). We multiply (2.8) by π(π₯),
π(π₯)
[ππ¦
ππ₯+ π(π₯)π¦
]= π(π₯)π(π₯), (2.9)
and try to determine π(π₯) so that
π(π₯)
[ππ¦
ππ₯+ π(π₯)π¦
]=
π
ππ₯[π(π₯)π¦]. (2.10)
Equation (2.9) then becomes
π
ππ₯[π(π₯)π¦] = π(π₯)π(π₯). (2.11)
Equation (2.11) is easily integrated using π(π₯0) = π0 and π¦(π₯0) = π¦0:
π(π₯)π¦ β π0π¦0 =
β« π₯
π₯0
π(π₯)π(π₯)ππ₯,
or
π¦ =1
π(π₯)
(π0π¦0 +
β« π₯
π₯0
π(π₯)π(π₯)ππ₯
). (2.12)
It remains to determine π(π₯) from (2.10). Differentiating and expanding (2.10)yields
πππ¦
ππ₯+ πππ¦ =
ππ
ππ₯π¦ + π
ππ¦
ππ₯;
and upon simplifying,ππ
ππ₯= ππ. (2.13)
Equation (2.13) is separable and can be integrated:β« π
π0
ππ
π=
β« π₯
π₯0
π(π₯)ππ₯,
lnπ
π0=
β« π₯
π₯0
π(π₯)ππ₯,
π(π₯) = π0 exp
(β« π₯
π₯0
π(π₯)ππ₯
).
Notice that since π0 cancels out of (2.12), it is customary to assign π0 = 1. Thesolution to (2.8) satisfying the initial condition π¦(π₯0) = π¦0 is then commonlywritten as
π¦ =1
π(π₯)
(π¦0 +
β« π₯
π₯0
π(π₯)π(π₯)ππ₯
),
with
π(π₯) = exp
(β« π₯
π₯0
π(π₯)ππ₯
)the integrating factor. This important result finds frequent use in applied math-ematics.
2.3. LINEAR EQUATIONS 19
Example: Solve ππ¦ππ₯ + 2π¦ = πβπ₯, with π¦(0) = 3/4.
Note that this equation is not separable. With π(π₯) = 2 and π(π₯) = πβπ₯, wehave
π(π₯) = exp
(β« π₯
0
2ππ₯
)= π2π₯,
and
π¦ = πβ2π₯
(3
4+
β« π₯
0
π2π₯πβπ₯ππ₯
)= πβ2π₯
(3
4+
β« π₯
0
ππ₯ππ₯
)= πβ2π₯
(3
4+ (ππ₯ β 1)
)= πβ2π₯
(ππ₯ β 1
4
)= πβπ₯
(1β 1
4πβπ₯
).
Example: Solve ππ¦ππ₯ β 2π₯π¦ = π₯, with π¦(0) = 0.
This equation is separable, and we solve it in two ways. First, using an inte-grating factor with π(π₯) = β2π₯ and π(π₯) = π₯:
π(π₯) = exp
(β2
β« π₯
0
π₯ππ₯
)= πβπ₯2
,
and
π¦ = ππ₯2
β« π₯
0
π₯πβπ₯2
ππ₯.
The integral can be done by substitution with π’ = π₯2, ππ’ = 2π₯ππ₯:β« π₯
0
π₯πβπ₯2
ππ₯ =1
2
β« π₯2
0
πβπ’ππ’
= β1
2πβπ’
]π₯2
0
=1
2
(1β πβπ₯2
).
Therefore,
π¦ =1
2ππ₯
2(1β πβπ₯2
)=
1
2
(ππ₯
2
β 1).
20 CHAPTER 2. FIRST-ORDER ODES
Second, we integrate by separating variables:
ππ¦
ππ₯β 2π₯π¦ = π₯,
ππ¦
ππ₯= π₯(1 + 2π¦),β« π¦
0
ππ¦
1 + 2π¦=
β« π₯
0
π₯ππ₯,
1
2ln (1 + 2π¦) =
1
2π₯2,
1 + 2π¦ = ππ₯2
,
π¦ =1
2
(ππ₯
2
β 1).
The results from the two different solution methods are the same, and the choiceof method is a personal preference.
2.4 Applications
2.4.1 Compound interest with deposits or withdrawals
view tutorialThe equation for the growth of an investment with continuous compoundingof interest is a first-order differential equation. Let π(π‘) be the value of theinvestment at time π‘, and let π be the annual interest rate compounded afterevery time interval Ξπ‘. We can also include deposits (or withdrawals). Let π bethe annual deposit amount, and suppose that an installment is deposited afterevery time interval Ξπ‘. The value of the investment at the time π‘+Ξπ‘ is thengiven by
π(π‘+Ξπ‘) = π(π‘) + (πΞπ‘)π(π‘) + πΞπ‘, (2.14)
where at the end of the time interval Ξπ‘, πΞπ‘π(π‘) is the amount of interestcredited and πΞπ‘ is the amount of money deposited (π > 0) or withdrawn(π < 0). As a numerical example, if the account held $10,000 at time π‘, andπ = 6% per year and π = $12,000 per year, say, and the compounding anddeposit period is Ξπ‘ = 1 month = 1/12 year, then the interest awarded afterone month is πΞπ‘π = (0.06/12) Γ $10,000 = $50, and the amount deposited isπΞπ‘ = $1000.
Rearranging the terms of (2.14) to exhibit what will soon become a deriva-tive, we have
π(π‘+Ξπ‘)β π(π‘)
Ξπ‘= ππ(π‘) + π.
The equation for continuous compounding of interest and continuous depositsis obtained by taking the limit Ξπ‘ β 0. The resulting differential equation is
ππ
ππ‘= ππ + π, (2.15)
which can solved with the initial condition π(0) = π0, where π0 is the initialcapital. We can solve either by separating variables or by using an integrating
2.4. APPLICATIONS 21
factor; I solve here by separating variables. Integrating from π‘ = 0 to a finaltime π‘, β« π
π0
ππ
ππ + π=
β« π‘
0
ππ‘,
1
πln
(ππ + π
ππ0 + π
)= π‘,
ππ + π = (ππ0 + π)πππ‘,
π =ππ0π
ππ‘ + ππππ‘ β π
π,
π = π0πππ‘ +
π
ππππ‘(1β πβππ‘
), (2.16)
where the first term on the right-hand side of (2.16) comes from the initialinvested capital, and the second term comes from the deposits (or withdrawals).Evidently, compounding results in the exponential growth of an investment.
As a practical example, we can analyze a simple retirement plan. It iseasiest to assume that all amounts and returns are in real dollars (adjusted forinflation). Suppose a 25 year-old plans to set aside a fixed amount every year ofhis/her working life, invests at a real return of 6%, and retires at age 65. Howmuch must he/she invest each year to have $8,000,000 at retirement? We needto solve (2.16) for π using π‘ = 40 years, π(π‘) = $8,000,000, π0 = 0, and π = 0.06per year. We have
π =ππ(π‘)
πππ‘ β 1,
π =0.06Γ 8,000,000
π0.06Γ40 β 1,
= $47,889 yearβ1.
To have saved approximately one million US$ at retirement, the worker wouldneed to save about HK$50,000 per year over his/her working life. Note that theamount saved over the workerβs life is approximately 40Γ$50,000 = $2,000,000,while the amount earned on the investment (at the assumed 6% real return) isapproximately $8,000,000β $2,000,000 = $6,000,000. The amount earned fromthe investment is about 3Γ the amount saved, even with the modest real returnof 6%. Sound investment planning is well worth the effort.
2.4.2 Chemical reactions
Suppose that two chemicals π΄ and π΅ react to form a product πΆ, which we writeas
π΄+π΅πβ πΆ,
where π is called the rate constant of the reaction. For simplicity, we will usethe same symbol πΆ, say, to refer to both the chemical πΆ and its concentration.The law of mass action says that ππΆ/ππ‘ is proportional to the product of theconcentrations π΄ and π΅, with proportionality constant π; that is,
ππΆ
ππ‘= ππ΄π΅. (2.17)
22 CHAPTER 2. FIRST-ORDER ODES
Similarly, the law of mass action enables us to write equations for the time-derivatives of the reactant concentrations π΄ and π΅:
ππ΄
ππ‘= βππ΄π΅,
ππ΅
ππ‘= βππ΄π΅. (2.18)
The ode given by (2.17) can be solved analytically using conservation laws. Weassume that π΄0 and π΅0 are the initial concentrations of the reactants, and thatno product is initially present. From (2.17) and (2.18),
π
ππ‘(π΄+ πΆ) = 0 =β π΄+ πΆ = π΄0,
π
ππ‘(π΅ + πΆ) = 0 =β π΅ + πΆ = π΅0.
Using these conservation laws, (2.17) becomes
ππΆ
ππ‘= π(π΄0 β πΆ)(π΅0 β πΆ), πΆ(0) = 0,
which is a nonlinear equation that may be integrated by separating variables.Separating and integrating, we obtainβ« πΆ
0
ππΆ
(π΄0 β πΆ)(π΅0 β πΆ)= π
β« π‘
0
ππ‘
= ππ‘. (2.19)
The remaining integral can be done using the method of partial fractions. Wewrite
1
(π΄0 β πΆ)(π΅0 β πΆ)=
π
π΄0 β πΆ+
π
π΅0 β πΆ. (2.20)
The cover-up method is the simplest method to determine the unknown coeffi-cients π and π. To determine π, we multiply both sides of (2.20) by π΄0 βπΆ andset πΆ = π΄0 to find
π =1
π΅0 βπ΄0.
Similarly, to determine π, we multiply both sides of (2.20) by π΅0 β πΆ and setπΆ = π΅0 to find
π =1
π΄0 βπ΅0.
Therefore,
1
(π΄0 β πΆ)(π΅0 β πΆ)=
1
π΅0 βπ΄0
(1
π΄0 β πΆβ 1
π΅0 β πΆ
),
and the remaining integral of (2.19) becomes (using πΆ < π΄0, π΅0)β« πΆ
0
ππΆ
(π΄0 β πΆ)(π΅0 β πΆ)=
1
π΅0 βπ΄0
(β« πΆ
0
ππΆ
π΄0 β πΆββ« πΆ
0
ππΆ
π΅0 β πΆ
)
=1
π΅0 βπ΄0
(β ln
(π΄0 β πΆ
π΄0
)+ ln
(π΅0 β πΆ
π΅0
))=
1
π΅0 βπ΄0ln
(π΄0(π΅0 β πΆ)
π΅0(π΄0 β πΆ)
).
2.4. APPLICATIONS 23
Using this integral in (2.19), multiplying by (π΅0 β π΄0) and exponentiating, weobtain
π΄0(π΅0 β πΆ)
π΅0(π΄0 β πΆ)= π(π΅0βπ΄0)ππ‘.
Solving for πΆ, we finally obtain
πΆ(π‘) = π΄0π΅0π(π΅0βπ΄0)ππ‘ β 1
π΅0π(π΅0βπ΄0)ππ‘ βπ΄0,
which appears to be a complicated expression, but has the simple limits
limπ‘ββ
πΆ(π‘) =
{π΄0 if π΄0 < π΅0,
π΅0 if π΅0 < π΄0,
= min(π΄0, π΅0).
Hence, the reaction stops after one of the reactants is depleted; and the finalconcentration of product is equal to the initial concentration of the depletedreactant.
2.4.3 The terminal velocity of a falling mass
view tutorial
Using Newtonβs law, we model a mass π free falling under gravity but withair resistance. We assume that the force of air resistance is proportional to thespeed of the mass and opposes the direction of motion. We define the π₯-axis topoint in the upward direction, opposite the force of gravity. Near the surfaceof the Earth, the force of gravity is approximately constant and is given byβππ, with π = 9.8m/s2 the usual gravitational acceleration. The force of airresistance is modeled by βππ£, where π£ is the vertical velocity of the mass andπ is a positive constant. When the mass is falling, π£ < 0 and the force of airresistance is positive, pointing upward and opposing the motion. The total forceon the mass is therefore given by πΉ = βππβππ£. With πΉ = ππ and π = ππ£/ππ‘,we obtain the differential equation
πππ£
ππ‘= βππ β ππ£. (2.21)
The terminal velocity π£β of the mass is defined as the asymptotic velocity afterair resistance balances the gravitational force. When the mass is at terminalvelocity, ππ£/ππ‘ = 0 so that
π£β = βππ
π. (2.22)
The approach to the terminal velocity of a mass initially at rest is obtained bysolving (2.21) with initial condition π£(0) = 0. The equation is both linear and
24 CHAPTER 2. FIRST-ORDER ODES
separable, and I solve by separating variables:
π
β« π£
0
ππ£
ππ + ππ£= β
β« π‘
0
ππ‘,
π
πln
(ππ + ππ£
ππ
)= βπ‘,
1 +ππ£
ππ= πβππ‘/π,
π£ = βππ
π
(1β πβππ‘/π
).
Therefore, π£ = π£β(1β πβππ‘/π
), and π£ approaches π£β as the exponential term
decays to zero.As an example, a skydiver of mass π = 100 kg with his parachute closed
may have a terminal velocity of 200 km/hr. With
π = (9.8m/s2)(10β3 km/m)(60 s/min)2(60min/hr)2 = 127, 008 km/hr
2,
one obtains from (2.22), π = 63, 504 kg/hr. One-half of the terminal velocityfor free-fall (100 km/hr) is therefore attained when (1 β πβππ‘/π) = 1/2, or π‘ =π ln 2/π β 4 sec. Approximately 95% of the terminal velocity (190 km/hr ) isattained after 17 sec.
2.4.4 Escape velocity
view tutorialAn interesting physical problem is to find the smallest initial velocity for amass on the Earthβs surface to escape from the Earthβs gravitational field, theso-called escape velocity. Newtonβs law of universal gravitation asserts that thegravitational force between two massive bodies is proportional to the product ofthe two masses and inversely proportional to the square of the distance betweenthem. For a mass π a position π₯ above the surface of the Earth, the force onthe mass is given by
πΉ = βπΊππ
(π + π₯)2,
where π and π are the mass and radius of the Earth and πΊ is the gravitationalconstant. The minus sign means the force on the mass π points in the directionof decreasing π₯. The approximately constant acceleration π on the Earthβssurface corresponds to the absolute value of πΉ/π when π₯ = 0:
π =πΊπ
π 2,
and π β 9.8 m/s2. Newtonβs law πΉ = ππ for the mass π is thus given by
π2π₯
ππ‘2= β πΊπ
(π + π₯)2
= β π
(1 + π₯/π )2, (2.23)
where the radius of the Earth is known to be π β 6350 km.
2.4. APPLICATIONS 25
A useful trick allows us to solve this second-order differential equation asa first-order equation. First, note that π2π₯/ππ‘2 = ππ£/ππ‘. If we write π£(π‘) =π£(π₯(π‘))βconsidering the velocity of the mass π to be a function of its distanceabove the Earthβwe have using the chain rule
ππ£
ππ‘=
ππ£
ππ₯
ππ₯
ππ‘
= π£ππ£
ππ₯,
where we have used π£ = ππ₯/ππ‘. Therefore, (2.23) becomes the first-order ode
π£ππ£
ππ₯= β π
(1 + π₯/π )2,
which may be solved assuming an initial velocity π£(π₯ = 0) = π£0 when the massis shot vertically from the Earthβs surface. Separating variables and integrating,we obtain β« π£
π£0
π£ππ£ = βπ
β« π₯
0
ππ₯
(1 + π₯/π )2.
The left integral is 12 (π£
2 β π£20), and the right integral can be performed usingthe substitution π’ = 1 + π₯/π , ππ’ = ππ₯/π :β« π₯
0
ππ₯
(1 + π₯/π )2= π
β« 1+π₯/π
1
ππ’
π’2
= β π
π’
]1+π₯/π
1
= π β π 2
π₯+π
=π π₯
π₯+π .
Therefore,1
2(π£2 β π£20) = β ππ π₯
π₯+π ,
which when multiplied by π is an expression of the conservation of energy (thechange of the kinetic energy of the mass is equal to the change in the potentialenergy). Solving for π£2,
π£2 = π£20 β2ππ π₯
π₯+π .
The escape velocity is defined as the minimum initial velocity π£0 such thatthe mass can escape to infinity. Therefore, π£0 = π£escape when π£ β 0 as π₯ β β.Taking this limit, we have
π£2escape = limπ₯ββ
2ππ π₯
π₯+π
= 2ππ .
With π β 6350 km and π = 127, 008 km/hr2, we determine π£escape =
β2ππ β
40 000 km/hr. In comparison, the muzzle velocity of a modern high-performancerifle is 4 300 km/hr, almost an order of magnitude slower.
26 CHAPTER 2. FIRST-ORDER ODES
2.4.5 The logistic equation
Let π = π(π‘) be the size of a population at time π‘ and let π be the growthrate. The Malthusian growth model (Thomas Malthus, 1766-1834), similar toa compound interest model, is given by
ππ
ππ‘= ππ.
Under a Malthusian growth model, a population grows exponentially like
π(π‘) = π0πππ‘,
where π0 is the initial population size. However, when the population growthis constrained by limited resources, a heuristic modification to the Malthusiangrowth model results in the Verhulst equation,
ππ
ππ‘= ππ
(1β π
πΎ
), (2.24)
where πΎ is called the carrying capacity of the environment. Making (2.24)dimensionless using π = ππ‘ and π₯ = π/πΎ leads to the logistic equation,
ππ₯
ππ= π₯(1β π₯),
where we may assume the initial condition π₯(0) = π₯0 > 0. Separating variablesand integrating β« π₯
π₯0
ππ₯
π₯(1β π₯)=
β« π
0
ππ.
The integral on the left-hand-side can be done using the method of partialfractions:
1
π₯(1β π₯)=
π
π₯+
π
1β π₯
=π+ (πβ π)π₯
π₯(1β π₯);
and equating the coefficients of the numerators proportional to π₯0 and π₯1, wehave π = π = 1. Therefore,β« π₯
π₯0
ππ₯
π₯(1β π₯)=
β« π₯
π₯0
ππ₯
π₯+
β« π₯
π₯0
ππ₯
(1β π₯)
= lnπ₯
π₯0β ln
1β π₯
1β π₯0
= lnπ₯(1β π₯0)
π₯0(1β π₯)
= π.
2.4. APPLICATIONS 27
Solving for π₯, we first exponentiate both sides and then isolate π₯:
π₯(1β π₯0)
π₯0(1β π₯)= ππ ,
π₯(1β π₯0) = π₯0ππ β π₯π₯0π
π ,
π₯(1β π₯0 + π₯0ππ ) = π₯0π
π ,
π₯ =π₯0
π₯0 + (1β π₯0)πβπ. (2.25)
We observe that for π₯0 > 0, we have limπββ π₯(π) = 1, corresponding to
limπ‘ββ
π(π‘) = πΎ.
The population, therefore, grows in size until it reaches the carrying capacity ofits environment.
28 CHAPTER 2. FIRST-ORDER ODES
Chapter 3
Second-order lineardifferential equations withconstant coefficients
Reference: Boyce and DiPrima, Chapter 3
The general second-order linear differential equation with independent variableπ‘ and dependent variable π₯ = π₯(π‘) is given by
οΏ½οΏ½+ π(π‘)οΏ½οΏ½+ π(π‘)π₯ = π(π‘), (3.1)
where we have used the standard physics notation οΏ½οΏ½ = ππ₯/ππ‘ and οΏ½οΏ½ = π2π₯/ππ‘2.A unique solution of (3.1) requires initial values π₯(π‘0) = π₯0 and οΏ½οΏ½(π‘0) = π’0.The equation with constant coefficientsβon which we will devote considerableeffortβassumes that π(π‘) and π(π‘) are constants, independent of time. Thesecond-order linear ode is said to be homogeneous if π(π‘) = 0.
3.1 The Euler method
view tutorialIn general, (3.1) cannot be solved analytically, and we begin by deriving analgorithm for numerical solution. We write the second-order ode as a pair offirst-order odes by defining π’ = οΏ½οΏ½, and writing the first-order system as
οΏ½οΏ½ = π’, (3.2)
οΏ½οΏ½ = π(π‘, π₯, π’), (3.3)
whereπ(π‘, π₯, π’) = βπ(π‘)π’β π(π‘)π₯+ π(π‘).
The first ode, (3.2), gives the slope of the tangent line to the curve π₯ = π₯(π‘);the second ode, (3.3), gives the slope of the tangent line to the curve π’ = π’(π‘).Beginning at the initial values (π₯, π’) = (π₯0, π’0) at the time π‘ = π‘0, we movealong the tangent lines to determine π₯1 = π₯(π‘0 +Ξπ‘) and π’1 = π’(π‘0 +Ξπ‘):
π₯1 = π₯0 +Ξπ‘π’0,
π’1 = π’0 +Ξπ‘π(π‘0, π₯0, π’0).
29
30 CHAPTER 3. SECOND-ORDER ODES, CONSTANT COEFFICIENTS
The values π₯1 and π’1 at the time π‘1 = π‘0+Ξπ‘ are then used as new initial valuesto march the solution forward to time π‘2 = π‘1 + Ξπ‘. As long as π(π‘, π₯, π’) is awell-behaved function, the numerical solution converges to the unique solutionof the ode as Ξπ‘ β 0.
3.2 The principle of superposition
view tutorialConsider the second-order linear homogeneous ode:
οΏ½οΏ½+ π(π‘)οΏ½οΏ½+ π(π‘)π₯ = 0; (3.4)
and suppose that π₯ = π1(π‘) and π₯ = π2(π‘) are solutions to (3.4). We considera linear combination of π1 and π2 by letting
π(π‘) = π1π1(π‘) + π2π2(π‘), (3.5)
with π1 and π2 constants. The principle of superposition states that π₯ = π(π‘)is also a solution of (3.4). To prove this, we compute
οΏ½οΏ½ + ποΏ½οΏ½ + ππ = π1οΏ½οΏ½1 + π2οΏ½οΏ½2 + π(π1οΏ½οΏ½1 + π2οΏ½οΏ½2
)+ π (π1π1 + π2π2)
= π1
(οΏ½οΏ½1 + ποΏ½οΏ½1 + ππ1
)+ π2
(οΏ½οΏ½2 + ποΏ½οΏ½2 + ππ2
)= π1 Γ 0 + π2 Γ 0
= 0,
since π1 and π2 were assumed to be solutions of (3.4). We have therefore shownthat any linear combination of solutions to the second-order linear homogeneousode is also a solution.
3.3 The Wronskian
view tutorialSuppose that having determined that two solutions of (3.4) are π₯ = π1(π‘) andπ₯ = π2(π‘), we attempt to write the general solution to (3.4) as (3.5). We mustthen ask whether this general solution will be able to satisfy the two initialconditions given by
π₯(π‘0) = π₯0, οΏ½οΏ½(π‘0) = π’0. (3.6)
Applying these initial conditions to (3.5), we obtain
π1π1(π‘0) + π2π2(π‘0) = π₯0,
π1οΏ½οΏ½1(π‘0) + π2οΏ½οΏ½2(π‘0) = π’0, (3.7)
which is observed to be a system of two linear equations for the two unknownsπ1 and π2. Solution of (3.7) by standard methods results in
π1 =π₯0οΏ½οΏ½2(π‘0)β π’0π2(π‘0)
π, π2 =
π’0π1(π‘0)β π₯0οΏ½οΏ½1(π‘0)
π,
3.4. HOMOGENEOUS ODES 31
where π is called the Wronskian and is given by
π = π1(π‘0)οΏ½οΏ½2(π‘0)β οΏ½οΏ½1(π‘0)π2(π‘0). (3.8)
Evidently, the Wronskian must not be equal to zero (π = 0) for a solution toexist.
For examples, the two solutions
π1(π‘) = sinππ‘, π2(π‘) = π΄ sinππ‘,
have a zero Wronskian at π‘ = π‘0, as can be shown by computing
π = (sinππ‘0) (π΄π cosππ‘0)β (π cosππ‘0) (π΄ sinππ‘0)
= 0;
while the two solutions
π1(π‘) = sinππ‘, π2(π‘) = cosππ‘,
with π = 0, have a nonzero Wronskian at π‘ = π‘0,
π = (sinππ‘0) (βπ sinππ‘0)β (π cosππ‘0) (cosππ‘0)
= βπ.
When the Wronskian is not equal to zero, we say that the two solutionsπ1(π‘) and π2(π‘) are linearly independent. The concept of linear independenceis borrowed from linear algebra, and indeed, the set of all functions that satisfy(3.4) can be shown to form a two-dimensional vector space.
3.4 Second-order linear homogeneous ode withconstant coefficients
view tutorialWe now study solutions of the homogeneous, constant coefficient ode, writtenas
ποΏ½οΏ½+ ποΏ½οΏ½+ ππ₯ = 0, (3.9)
with π, π, and π constants. Such an equation arises for the charge on a capacitorin an unpowered RLC electrical circuit, or for the position of a freely-oscillatingfrictional mass on a spring. Our solution method finds two linearly independentsolutions to (3.9), multiplies each of these solutions by a constant, and addsthem. The two free constants can then be used to satisfy whatever initialconditions are given.
Because of the differential properties of the exponential function, a naturalansatz, or educated guess, for the form of the solution to (3.9) is π₯ = πππ‘, whereπ is a constant to be determined. Successive differentiation results in οΏ½οΏ½ = ππππ‘
and οΏ½οΏ½ = π2πππ‘, and substitution into (3.9) yields
ππ2πππ‘ + πππππ‘ + ππππ‘ = 0. (3.10)
Our choice of exponential function is now rewarded by the explicit cancelationof πππ‘ in (3.10). The result is a quadratic equation for the unknown constant π:
ππ2 + ππ + π = 0. (3.11)
32 CHAPTER 3. SECOND-ORDER ODES, CONSTANT COEFFICIENTS
Our ansatz has thus converted a differential equation into an algebraic equation.Equation (3.11) is called the characteristic equation of (3.9). Using the quadraticformula, the two solutions of the characteristic equation (3.11) are given by
πΒ± =1
2π
(βπΒ±
βπ2 β 4ππ
).
There are three cases to consider: (1) if π2 β 4ππ > 0, then the two roots aredistinct and real; (2) if π2β4ππ < 0, then the two roots are distinct and complexconjugates of each other; (3) if π2 β 4ππ = 0, then the two roots are degenerateand there is only one real root. We will consider these three cases in turn.
3.4.1 Real, distinct roots
When π+ = πβ are real roots, then the general solution to (3.9) can be writtenas a linear superposition of the two solutions ππ+π‘ and ππβπ‘; that is,
π₯(π‘) = π1ππ+π‘ + π2π
πβπ‘.
The unknown constants π1 and π2 can then be determined by the initial condi-tions π₯(π‘0) = π₯0 and οΏ½οΏ½(π‘0) = π’0. We now present two examples.
Example 1: Solve οΏ½οΏ½ + 5οΏ½οΏ½ + 6π₯ = 0 with π₯(0) = 2, οΏ½οΏ½(0) = 3, and find themaximum value attained by π₯.
view tutorialWe take as our ansatz π₯ = πππ‘ and obtain the characteristic equation
π2 + 5π + 6 = 0,
which factors to(π + 3)(π + 2) = 0.
The general solution to the ode is thus
π₯(π‘) = π1πβ2π‘ + π2π
β3π‘.
The solution for οΏ½οΏ½ obtained by differentiation is
οΏ½οΏ½(π‘) = β2π1πβ2π‘ β 3π2π
β3π‘.
Use of the initial conditions then results in two equations for the two unknownconstant π1 and π2:
π1 + π2 = 2,
β2π1 β 3π2 = 3.
Adding three times the first equation to the second equation yields π1 = 9; andthe first equation then yields π2 = 2β π1 = β7. Therefore, the unique solutionthat satisfies both the ode and the initial conditions is
π₯(π‘) = 9πβ2π‘ β 7πβ3π‘
= 9πβ2π‘
(1β 7
9πβπ‘
).
3.4. HOMOGENEOUS ODES 33
Note that although both exponential terms decay in time, their sum increasesinitially since οΏ½οΏ½(0) > 0. The maximum value of π₯ occurs at the time π‘π whenοΏ½οΏ½ = 0, or
π‘π = ln (7/6) .
The maximum π₯π = π₯(π‘π) is then determined to be
π₯π = 108/49.
Example 2: Solve οΏ½οΏ½β π₯ = 0 with π₯(0) = π₯0, οΏ½οΏ½(0) = π’0.
Again our ansatz is π₯ = πππ‘, and we obtain the characteristic equation
π2 β 1 = 0,
with solution πΒ± = Β±1. Therefore, the general solution for π₯ is
π₯(π‘) = π1ππ‘ + π2π
βπ‘,
and the derivative satisfies
οΏ½οΏ½(π‘) = π1ππ‘ β π2π
βπ‘.
Initial conditions are satisfied when
π1 + π2 = π₯0,
π1 β π2 = π’0.
Adding and subtracting these equations, we determine
π1 =1
2(π₯0 + π’0) , π2 =
1
2(π₯0 β π’0) ,
so that after rearranging terms
π₯(π‘) = π₯0
(ππ‘ + πβπ‘
2
)+ π’0
(ππ‘ β πβπ‘
2
).
The terms in parentheses are the usual definitions of the hyperbolic cosine andsine functions; that is,
cosh π‘ =ππ‘ + πβπ‘
2, sinh π‘ =
ππ‘ β πβπ‘
2.
Our solution can therefore be rewritten as
π₯(π‘) = π₯0 cosh π‘+ π’0 sinh π‘.
Note that the relationships between the trigonometric functions and the complexexponentials were given by
cos π‘ =πππ‘ + πβππ‘
2, sin π‘ =
πππ‘ β πβππ‘
2π,
so thatcosh π‘ = cos ππ‘, sinh π‘ = βπ sin ππ‘.
Also note that the hyperbolic trigonometric functions satisfy the differentialequations
π
ππ‘sinh π‘ = cosh π‘,
π
ππ‘cosh π‘ = sinh π‘,
which though similar to the differential equations satisfied by the more com-monly used trigonometric functions, is absent a minus sign.
34 CHAPTER 3. SECOND-ORDER ODES, CONSTANT COEFFICIENTS
3.4.2 Complex conjugate, distinct roots
view tutorialWe now consider a characteristic equation (3.11) with π2β4ππ < 0, so the rootsoccur as complex conjugate pairs. With
π = β π
2π, π =
1
2π
β4ππβ π2,
the two roots of the characteristic equation are π + ππ and π β ππ. We havethus found the following two complex exponential solutions to the differentialequation:
π1 = πππ‘ππππ‘, π2 = πππ‘πβπππ‘.
Applying the principle of superposition, any linear combination of π1 and π2
is also a solution to the second-order ode, and we can form two different linearcombinations that are real. They are given by
π1(π‘) =π1 + π2
2
= πππ‘(ππππ‘ + πβπππ‘
2
)= πππ‘ cosππ‘,
and
π2(π‘) =π1 β π2
2π
= πππ‘(ππππ‘ β πβπππ‘
2π
)= πππ‘ sinππ‘.
Having found the two real solutions π1(π‘) and π2(π‘), we can then apply theprinciple of superposition again to determine the general solution π₯(π‘) to be
π₯(π‘) = πππ‘ (π΄ cosππ‘+π΅ sinππ‘) . (3.12)
It is best to memorize this result. The real part of the roots of the characteristicequation goes into the exponential function; the imaginary part goes into theargument of cosine and sine.
Example 1: Solve οΏ½οΏ½+ π₯ = 0 with π₯(0) = π₯0 and οΏ½οΏ½(0) = π’0.
view tutorialThe characteristic equation is
π2 + 1 = 0,
with rootsπΒ± = Β±π.
The general solution of the ode is therefore
π₯(π‘) = π΄ cos π‘+π΅ sin π‘.
3.4. HOMOGENEOUS ODES 35
The derivative is
οΏ½οΏ½(π‘) = βπ΄ sin π‘+π΅ cos π‘.
Applying the initial conditions:
π₯(0) = π΄ = π₯0, οΏ½οΏ½(0) = π΅ = π’0;
so that the final solution is
π₯(π‘) = π₯0 cos π‘+ π’0 sin π‘.
Recall that we wrote the analogous solution to the ode οΏ½οΏ½ β π₯ = 0 as π₯(π‘) =π₯0 cosh π‘+ π’0 sinh π‘.
Example 2: Solve οΏ½οΏ½+ οΏ½οΏ½+ π₯ = 0 with π₯(0) = 1 and οΏ½οΏ½(0) = 0.
The characteristic equation is
π2 + π + 1 = 0,
with roots
πΒ± = β1
2Β± π
β3
2.
The general solution of the ode is therefore
π₯(π‘) = πβ12 π‘
(π΄ cos
β3
2π‘+π΅ sin
β3
2π‘
).
The derivative is
οΏ½οΏ½(π‘) = β1
2πβ
12 π‘
(π΄ cos
β3
2π‘+π΅ sin
β3
2π‘
)
+
β3
2πβ
12 π‘
(βπ΄ sin
β3
2π‘+π΅ cos
β3
2π‘
).
Applying the initial conditions π₯(0) = 1 and οΏ½οΏ½(0) = 0:
π΄ = 1,
β1
2π΄+
β3
2π΅ = 0;
or
π΄ = 1, π΅ =
β3
3.
Therefore,
π₯(π‘) = πβ12 π‘
(cos
β3
2π‘+
β3
3sin
β3
2π‘
).
36 CHAPTER 3. SECOND-ORDER ODES, CONSTANT COEFFICIENTS
3.4.3 Repeated roots
view tutorialFinally, we consider the characteristic equation,
ππ2 + ππ + π = 0,
with π2 β 4ππ = 0. The degenerate root is then given by
π = β π
2π,
yielding only a single solution to the ode:
π₯1(π‘) = exp
(β ππ‘
2π
). (3.13)
To satisfy two initial conditions, a second independent solution must be found,and apparently this second solution is not of the form of our ansatz π₯ = exp (ππ‘).
One method to determine this missing second solution is to try the ansatz
π₯(π‘) = π¦(π‘)π₯1(π‘), (3.14)
where π¦(π‘) is an unknown function that satisfies the differential equation ob-tained by substituting (3.14) into (3.9). This general technique is called thereduction of order method and enables one to find a second solution of a ho-mogeneous linear differential equation if one solution is known. If the originaldifferential equation is of order π, the differential equation for π¦ = π¦(π‘) reducesto one of order πβ 1.
Here, however, we will determine this missing second solution through alimiting process. We start with the solution obtained for complex roots of thecharacteristic equation, and then arrive at the solution obtained for degenerateroots by taking the limit π β 0.
Now, the general solution for complex roots was given by (3.12), and toproperly limit this solution as π β 0 requires first satisfying the specific initialconditions π₯(0) = π₯0 and οΏ½οΏ½(0) = π’0. Solving for π΄ and π΅, the general solutiongiven by (3.12) becomes the specific solution
π₯(π‘;π) = πππ‘(π₯0 cosππ‘+
π’0 β ππ₯0
πsinππ‘
).
Here, we have written π₯ = π₯(π‘;π) to show explicitly that π₯ depends on π.Taking the limit as π β 0, and using limπβ0 π
β1 sinππ‘ = π‘, we have
limπβ0
π₯(π‘;π) = πππ‘(π₯0 + (π’0 β ππ₯0)π‘
).
The second solution is observed to be a constant, π’0 β ππ₯0, times π‘ times thefirst solution, πππ‘. Our general solution to the ode (3.9) when π2 β 4ππ = 0 cantherefore be written in the form
π₯(π‘) = (π1 + π2π‘)πππ‘,
where π is the repeated root of the characteristic equation. The main result tobe remembered is that for the case of repeated roots, the second solution is π‘times the first solution.
3.5. INHOMOGENEOUS ODES 37
Example: Solve οΏ½οΏ½+ 2οΏ½οΏ½+ π₯ = 0 with π₯(0) = 1 and οΏ½οΏ½(0) = 0.
The characteristic equation is
π2 + 2π + 1 = (π + 1)2
= 0,
which has a repeated root given by π = β1. Therefore, the general solution tothe ode is
π₯(π‘) = π1πβπ‘ + π2π‘π
βπ‘,
with derivativeοΏ½οΏ½(π‘) = βπ1π
βπ‘ + π2πβπ‘ β π2π‘π
βπ‘.
Applying the initial conditions:
π1 = 1,
βπ1 + π2 = 0,
so that π1 = π2 = 1. Therefore, the solution is
π₯(π‘) = (1 + π‘)πβπ‘.
3.5 Second-order linear inhomogeneous ode
We now consider the general second-order linear inhomogeneous ode (3.1):
οΏ½οΏ½+ π(π‘)οΏ½οΏ½+ π(π‘)π₯ = π(π‘), (3.15)
with initial conditions π₯(π‘0) = π₯0 and οΏ½οΏ½(π‘0) = π’0. There is a three-step solutionmethod when the inhomogeneous term π(π‘) = 0. (i) Find the general solutionof the homogeneous equation
οΏ½οΏ½+ π(π‘)οΏ½οΏ½+ π(π‘)π₯ = 0. (3.16)
Let us denote the homogeneous solution by
π₯β(π‘) = π1π1(π‘) + π2π2(π‘),
where π1 and π2 are linearly independent solutions of (3.16), and π1 and π2are as yet undetermined constants. (ii) Find any particular solution π₯π of theinhomogeneous equation (3.15). A particular solution is readily found whenπ(π‘) and π(π‘) are constants, and when π(π‘) is a combination of polynomials,exponentials, sines and cosines. (iii) Write the general solution of (3.15) as thesum of the homogeneous and particular solutions,
π₯(π‘) = π₯β(π‘) + π₯π(π‘), (3.17)
and apply the initial conditions to determine the constants π1 and π2. Note thatbecause of the linearity of (3.15),
οΏ½οΏ½+ ποΏ½οΏ½+ ππ₯ =π2
ππ‘2(π₯β + π₯π) + π
π
ππ‘(π₯β + π₯π) + π(π₯β + π₯π)
= (οΏ½οΏ½β + ποΏ½οΏ½β + ππ₯β) + (οΏ½οΏ½π + ποΏ½οΏ½π + ππ₯π)
= 0 + π
= π,
38 CHAPTER 3. SECOND-ORDER ODES, CONSTANT COEFFICIENTS
so that (3.17) solves (3.15), and the two free constants in π₯β can be used tosatisfy the initial conditions.
We will consider here only the constant coefficient case. We now illustratethe solution method by an example.
Example: Solve οΏ½οΏ½β 3οΏ½οΏ½β 4π₯ = 3π2π‘ with π₯(0) = 1 and οΏ½οΏ½(0) = 0.
view tutorialFirst, we solve the homogeneous equation. The characteristic equation is
π2 β 3π β 4 = (π β 4)(π + 1)
= 0,
so thatπ₯β(π‘) = π1π
4π‘ + π2πβπ‘.
Second, we find a particular solution of the inhomogeneous equation. The formof the particular solution is chosen such that the exponential will cancel out ofboth sides of the ode. The ansatz we choose is
π₯(π‘) = π΄π2π‘, (3.18)
where π΄ is a yet undetermined coefficient. Upon substituting π₯ into the ode,differentiating using the chain rule, and canceling the exponential, we obtain
4π΄β 6π΄β 4π΄ = 3,
from which we determine π΄ = β1/2. Obtaining a solution for π΄ independent ofπ‘ justifies the ansatz (3.18). Third, we write the general solution to the ode asthe sum of the homogeneous and particular solutions, and determine π1 and π2that satisfy the initial conditions. We have
π₯(π‘) = π1π4π‘ + π2π
βπ‘ β 1
2π2π‘;
and taking the derivative,
οΏ½οΏ½(π‘) = 4π1π4π‘ β π2π
βπ‘ β π2π‘.
Applying the initial conditions,
π1 + π2 β1
2= 1,
4π1 β π2 β 1 = 0;
or
π1 + π2 =3
2,
4π1 β π2 = 1.
This system of linear equations can be solved for π1 by adding the equationsto obtain π1 = 1/2, after which π2 = 1 can be determined from the first equa-tion. Therefore, the solution for π₯(π‘) that satisfies both the ode and the initial
3.5. INHOMOGENEOUS ODES 39
conditions is given by
π₯(π‘) =1
2π4π‘ β 1
2π2π‘ + πβπ‘
=1
2π4π‘(1β πβ2π‘ + 2πβ5π‘
),
where we have grouped the terms in the solution to better display the asymptoticbehavior for large π‘.
We now find particular solutions for some relatively simple inhomogeneousterms using this method of undetermined coefficients.
Example: Find a particular solution of οΏ½οΏ½β 3οΏ½οΏ½β 4π₯ = 2 sin π‘.
view tutorialWe show two methods for finding a particular solution. The first more directmethod tries the ansatz
π₯(π‘) = π΄ cos π‘+π΅ sin π‘,
where the argument of cosine and sine must agree with the argument of sine inthe inhomogeneous term. The cosine term is required because the derivative ofsine is cosine. Upon substitution into the differential equation, we obtain
(βπ΄ cos π‘βπ΅ sin π‘)β 3 (βπ΄ sin π‘+π΅ cos π‘)β 4 (π΄ cos π‘+π΅ sin π‘) = 2 sin π‘,
or regrouping terms,
β (5π΄+ 3π΅) cos π‘+ (3π΄β 5π΅) sin π‘ = 2 sin π‘.
This equation is valid for all π‘, and in particular for π‘ = 0 and π/2, for whichthe sine and cosine functions vanish. For these two values of π‘, we find
5π΄+ 3π΅ = 0, 3π΄β 5π΅ = 2;
and solving for π΄ and π΅, we obtain
π΄ =3
17, π΅ = β 5
17.
The particular solution is therefore given by
π₯π =1
17(3 cos π‘β 5 sin π‘) .
The second solution method makes use of the relation πππ‘ = cos π‘+ π sin π‘ toconvert the sine inhomogeneous term to an exponential function. We introducethe complex function π§(π‘) by letting
π§(π‘) = π₯(π‘) + ππ¦(π‘),
and rewrite the differential equation in complex form. We can rewrite the equa-tion in one of two ways. On the one hand, if we use sin π‘ = Re{βππππ‘}, then thedifferential equation is written as
π§ β 3οΏ½οΏ½ β 4π§ = β2ππππ‘; (3.19)
40 CHAPTER 3. SECOND-ORDER ODES, CONSTANT COEFFICIENTS
and by equating the real and imaginary parts, this equation becomes the tworeal differential equations
οΏ½οΏ½β 3οΏ½οΏ½β 4π₯ = 2 sin π‘, π¦ β 3οΏ½οΏ½ β 4π¦ = β2 cos π‘.
The solution we are looking for, then, is π₯π(π‘) = Re{π§π(π‘)}.On the other hand, if we write sin π‘ = Im{πππ‘}, then the complex differential
equation becomesπ§ β 3οΏ½οΏ½ β 4π§ = 2πππ‘, (3.20)
which becomes the two real differential equations
οΏ½οΏ½β 3οΏ½οΏ½β 4π₯ = 2 cos π‘, π¦ β 3οΏ½οΏ½ β 4π¦ = 2 sin π‘.
Here, the solution we are looking for is π₯π(π‘) = Im{π§π(π‘)}.We will proceed here by solving (3.20). As we now have an exponential
function as the inhomogeneous term, and we can make the ansatz
π§(π‘) = πΆπππ‘,
where we now expect πΆ to be a complex constant. Upon substitution into theode (3.20) and using π2 = β1:
βπΆ β 3ππΆ β 4πΆ = 2;
or solving for πΆ:
πΆ =β2
5 + 3π
=β2(5β 3π)
(5 + 3π)(5β 3π)
=β10 + 6π
34
=β5 + 3π
17.
Therefore,
π₯π = Im{π§π}
= Im
{1
17(β5 + 3π)(cos π‘+ π sin π‘)
}=
1
17(3 cos π‘β 5 sin π‘).
Example: Find a particular solution of οΏ½οΏ½+ οΏ½οΏ½β 2π₯ = π‘2.
view tutorialThe correct ansatz here is the polynomial
π₯(π‘) = π΄π‘2 +π΅π‘+ πΆ.
Upon substitution into the ode
2π΄+ 2π΄π‘+π΅ β 2π΄π‘2 β 2π΅π‘β 2πΆ = π‘2,
3.6. FIRST-ORDER LINEAR INHOMOGENEOUS ODES REVISITED 41
or
β2π΄π‘2 + 2(π΄βπ΅)π‘+ (2π΄+π΅ β 2πΆ)π‘0 = π‘2.
Equating powers of π‘,
β2π΄ = 1, 2(π΄βπ΅) = 0, 2π΄+π΅ β 2πΆ = 0;
and solving,
π΄ = β1
2, π΅ = β1
2, πΆ = β3
4.
The particular solution is therefore
π₯π(π‘) = β1
2π‘2 β 1
2π‘β 3
4.
3.6 First-order linear inhomogeneous odes re-visited
The first-order linear ode can be solved by use of an integrating factor. Here Ishow that odes having constant coefficients can be solved by our newly learnedsolution method.
Example: Solve οΏ½οΏ½+ 2π₯ = πβπ‘ with π₯(0) = 3/4.
Rather than using an integrating factor, we follow the three-step approach: (i)find the general homogeneous solution; (ii) find a particular solution; (iii) addthem and satisfy initial conditions. Accordingly, we try the ansatz π₯β(π‘) = πππ‘
for the homogeneous ode οΏ½οΏ½+ 2π₯ = 0 and find
π + 2 = 0, or π = β2.
To find a particular solution, we try the ansatz π₯π(π‘) = π΄πβπ‘, and upon substi-tution
βπ΄+ 2π΄ = 1, or π΄ = 1.
Therefore, the general solution to the ode is
π₯(π‘) = ππβ2π‘ + πβπ‘.
The single initial condition determines the unknown constant π:
π₯(0) =3
4= π+ 1,
so that π = β1/4. Hence,
π₯(π‘) = πβπ‘ β 1
4πβ2π‘
= πβπ‘
(1β 1
4πβπ‘
).
42 CHAPTER 3. SECOND-ORDER ODES, CONSTANT COEFFICIENTS
3.7 Resonance
view tutorial
Resonance occurs when the frequency of the inhomogeneous term matches thefrequency of the homogeneous solution. To illustrate resonance in its simplestembodiment, we consider the second-order linear inhomogeneous ode
οΏ½οΏ½+ π20π₯ = π cosππ‘, π₯(0) = π₯0, οΏ½οΏ½(0) = π’0. (3.21)
Our main goal is to determine what happens to the solution in the limit π β π0.
The homogeneous equation has characteristic equation
π2 + π20 = 0,
so that πΒ± = Β±ππ0. Therefore,
π₯β(π‘) = π1 cosπ0π‘+ π2 sinπ0π‘. (3.22)
To find a particular solution, we note the absence of a first-derivative term,and simply try
π₯(π‘) = π΄ cosππ‘.
Upon substitution into the ode, we obtain
βπ2π΄+ π20π΄ = π,
or
π΄ =π
π20 β π2
.
Therefore,
π₯π(π‘) =π
π20 β π2
cosππ‘.
Our general solution is thus
π₯(π‘) = π1 cosπ0π‘+ π2 sinπ0π‘+π
π20 β π2
cosππ‘,
with derivative
οΏ½οΏ½(π‘) = π0(π2 cosπ0π‘β π1 sinπ0π‘)βππ
π20 β π2
sinππ‘.
Initial conditions are satisfied when
π₯0 = π1 +π
π20 β π2
,
π’0 = π2π0,
so that
π1 = π₯0 βπ
π20 β π2
, π2 =π’0
π0.
3.7. RESONANCE 43
Therefore, the solution to the ode that satisfies the initial conditions is
π₯(π‘) =
(π₯0 β
π
π20 β π2
)cosπ0π‘+
π’0
π0sinπ0π‘+
π
π20 β π2
cosππ‘
= π₯0 cosπ0π‘+π’0
π0sinπ0π‘+
π(cosππ‘β cosπ0π‘)
π20 β π2
,
where we have grouped together terms proportional to the forcing amplitude π .Resonance occurs in the limit π β π0; that is, the frequency of the inhomo-
geneous term (the external force) matches the frequency of the homogeneoussolution (the free oscillation). By LβHospitalβs rule, the limit of the term pro-portional to π is found by differentiating with respect to π:
limπβπ0
π(cosππ‘β cosπ0π‘)
π20 β π2
= limπβπ0
βππ‘ sinππ‘
β2π
=ππ‘ sinπ0π‘
2π0.
(3.23)
At resonance, the term proportional to the amplitude π of the inhomogeneousterm increases linearly with π‘, resulting in larger-and-larger amplitudes of oscil-lation for π₯(π‘). In general, if the inhomogeneous term in the differential equationis a solution of the corresponding homogeneous differential equation, then thecorrect ansatz for the particular solution is a constant times the inhomogeneousterm times π‘.
To illustrate this same example further, we return to the original ode, nowassumed to be exactly at resonance,
οΏ½οΏ½+ π20π₯ = π cosπ0π‘,
and find a particular solution directly. The particular solution is the real partof the particular solution of
π§ + π20π§ = ππππ0π‘,
and because the inhomogeneous term is a solution of the corresponding homo-geneous equation, we take as our ansatz
π§π = π΄π‘πππ0π‘.
We have
οΏ½οΏ½π = π΄πππ0π‘ (1 + ππ0π‘) , π§π = π΄πππ0π‘(2ππ0 β π2
0π‘);
and upon substitution into the ode
π§π + π20π§π = π΄πππ0π‘
(2ππ0 β π2
0π‘)+ π2
0π΄π‘πππ0π‘
= 2ππ0π΄πππ0π‘
= ππππ0π‘.
Therefore,
π΄ =π
2ππ0,
44 CHAPTER 3. SECOND-ORDER ODES, CONSTANT COEFFICIENTS
and
π₯π = Re{ ππ‘
2ππ0πππ0π‘}
=ππ‘ sinπ0π‘
2π0,
the same result as (3.23).
Example: Find a particular solution of οΏ½οΏ½β 3οΏ½οΏ½β 4π₯ = 5πβπ‘ .
view tutorialIf we naively try the ansatz
π₯ = π΄πβπ‘,
and substitute this into the inhomogeneous differential equation, we obtain
π΄+ 3π΄β 4π΄ = 5,
or 0 = 5, which is clearly nonsense. Our ansatz therefore fails to find a solution.The cause of this failure is that the corresponding homogeneous equation hassolution
π₯β = π1π4π‘ + π2π
βπ‘,
so that the inhomogeneous term 5πβπ‘ is one of the solutions of the homogeneousequation. To find a particular solution, we should therefore take as our ansatz
π₯ = π΄π‘πβπ‘,
with first- and second-derivatives given by
οΏ½οΏ½ = π΄πβπ‘(1β π‘), οΏ½οΏ½ = π΄πβπ‘(β2 + π‘).
Substitution into the differential equation yields
π΄πβπ‘(β2 + π‘)β 3π΄πβπ‘(1β π‘)β 4π΄π‘πβπ‘ = 5πβπ‘.
The terms containing π‘ cancel out of this equation, resulting in β5π΄ = 5, orπ΄ = β1. Therefore, the particular solution is
π₯π = βπ‘πβπ‘.
3.8 Damped resonance
view tutorialA more realistic study of resonance assumes an additional damping term. Theforced, damped harmonic oscillator equation may be written as
ποΏ½οΏ½+ πΎοΏ½οΏ½+ ππ₯ = πΉ cosππ‘, (3.24)
where π > 0 is the oscillatorβs mass, πΎ > 0 is the damping coefficient, π >0 is the spring constant, and πΉ is the amplitude of the external force. Thehomogeneous equation has characteristic equation
ππ2 + πΎπ + π = 0,
3.8. DAMPED RESONANCE 45
so that
πΒ± = β πΎ
2πΒ± 1
2π
βπΎ2 β 4ππ.
When πΎ2 β 4ππ < 0, the motion of the unforced oscillator is said to be under-damped; when πΎ2 β 4ππ > 0, overdamped, and; when πΎ2 β 4ππ = 0, criticallydamped. For all all three types of damping, the roots of the characteristic equa-tion satisfy Re(πΒ±) < 0. Therefore, both linearly independent homogeneoussolutions decay exponentially to zero, and the long-time asymptotic solutionof (3.24) reduces to the (non-decaying) particular solution. Since the initialconditions are satisfied by the free constants multiplying the (decaying) homo-geneous solutions, the long-time asymptotic solution is independent of the initialconditions.
If we are only interested in the long-time asymptotic solution of (3.24), wecan proceed directly to the determination of a particular solution. As before,we consider the complex ode
ππ§ + πΎοΏ½οΏ½ + ππ§ = πΉππππ‘,
with π₯π = Re(π§π). With the ansatz π§π = π΄ππππ‘, we have
βππ2π΄+ ππΎππ΄+ ππ΄ = πΉ,
or
π΄ =πΉ
(π βππ2) + ππΎπ.
To simplify, we define π0 =βπ/π, which corresponds to the natural frequency
of the undamped oscillator, and define Ξ = πΎπ/π and π = πΉ/π. Therefore,
π΄ =π
(π20 β π2) + πΞ
=
(π
(π20 β π2)2 + Ξ2
)((π2
0 β π2)β πΞ).
(3.25)
To determine π₯π, we utilize the polar form of a complex number. The complexnumber π§ = π₯+ ππ¦ can be written in polar form as π§ = ππππ, where π₯ = π cosπ,π¦ = π sinπ, and π =
βπ₯2 + π¦2, tanπ = π¦/π₯. We therefore write
(π20 β π2)β πΞ = ππππ,
with
π =β
(π20 β π2)2 + Ξ2, tanπ =
Ξ
(π2 β π20).
Using the polar form, π΄ in (3.25) becomes
π΄ =
(πβ
(π20 β π2)2 + Ξ2
)πππ,
and π₯π = Re(π΄ππππ‘) becomes
π₯π =
(πβ
(π20 β π2)2 + Ξ2
)Re(ππ(ππ‘+π)
)=
(πβ
(π20 β π2)2 + Ξ2
)cos (ππ‘+ π).
(3.26)
46 CHAPTER 3. SECOND-ORDER ODES, CONSTANT COEFFICIENTS
The particular solution given by (3.26), with π20 = π/π, Ξ = πΎπ/π, π = πΉ/π,
and tanπ = πΎπ/π(π2 βπ20), is the long-time asymptotic solution of the forced,
damped, harmonic oscillator equation (3.24).We conclude with a couple of observations about (3.26). First, if the forcing
frequency π is equal to the natural frequency π0 of the undamped oscillator, thenπ΄ = βππΉ/πΎπ0, and π₯π = (πΉ/πΎπ0) sinπ0π‘. The oscillator position is observedto be π/2 out of phase with the external force, or in other words, the velocityof the oscillator, not the position, is in phase with the force. Second, the valueof the forcing frequency ππ that maximizes the amplitude of oscillation is thevalue of π that minimizes the denominator of (3.26). To determine ππ we thusminimize the function π(π2) with respect to π2, where
π(π2) = (π20 β π2)2 +
πΎ2π2
π2.
Taking the derivative of π with respect to π2 and setting this to zero to determineππ yields
2(π2π β π2
0) +πΎ2
π2= 0,
or
π2π = π2
0 βπΎ2
2π2.
We can interpret this result by saying that damping lowers the βresonanceβfrequency of the undamped oscillator.
Chapter 4
The Laplace transformReference: Boyce and DiPrima, Chapter 6
The Laplace transform is most useful for solving linear, constant-coefficientodeβs when the inhomogeneous term or its derivative is discontinuous. Althoughodeβs with discontinuous inhomogeneous terms can also be solved by adoptingalready learned methods, we will see that the Laplace transform technique pro-vides a simpler, more elegant solution.
4.1 Definitions and properties of the forwardand inverse Laplace transforms
view tutorialThe main idea is to Laplace transform the constant-coefficient differential equa-tion for π₯(π‘) into a simpler algebraic equation for the Laplace-transformed func-tion π(π ), solve this algebraic equation, and then transform π(π ) back intoπ₯(π‘). The correct definition of the Laplace transform and the properties thatthis transform satisfies makes this solution method possible.
An exponential ansatz is used in solving homogeneous constant-coefficientodes, and the exponential function correspondingly plays a key role in definingthe Laplace transform. The Laplace transform of π(π‘), denoted by πΉ (π ) =β{π(π‘)}, is defined by the integral transform
πΉ (π ) =
β« β
0
πβπ π‘π(π‘)ππ‘. (4.1)
The improper integral given by (4.1) diverges if π(π‘) grows faster than ππ π‘ forlarge π‘. Accordingly, some restriction on the range of π may be required toguarantee convergence of (4.1), and we will assume without further elaborationthat these restrictions are always satisfied.
The Laplace transform is a linear transformation. We have
β{π1π1(π‘) + π2π2(π‘)} =
β« β
0
πβπ π‘(π1π1(π‘) + π2π2(π‘)
)ππ‘
= π1
β« β
0
πβπ π‘π1(π‘)ππ‘+ π2
β« β
0
πβπ π‘π2(π‘)ππ‘
= π1β{π1(π‘)}+ π2β{π2(π‘)}.
47
48 CHAPTER 4. THE LAPLACE TRANSFORM
π(π‘) = ββ1{πΉ (π )} πΉ (π ) = β{π(π‘)}
1. πππ‘π(π‘) πΉ (π β π)
2. 11
π
3. πππ‘1
π β π
4. π‘ππ!
π π+1
5. π‘ππππ‘π!
(π β π)π+1
6. sin ππ‘π
π 2 + π2
7. cos ππ‘π
π 2 + π2
8. πππ‘ sin ππ‘π
(π β π)2 + π2
9. πππ‘ cos ππ‘π β π
(π β π)2 + π2
10. π‘ sin ππ‘2ππ
(π 2 + π2)2
11. π‘ cos ππ‘π 2 β π2
(π 2 + π2)2
12. π’π(π‘)πβππ
π
13. π’π(π‘)π(π‘β π) πβππ πΉ (π )
14. πΏ(π‘β π) πβππ
15. οΏ½οΏ½(π‘) π π(π )β π₯(0)
16. οΏ½οΏ½(π‘) π 2π(π )β π π₯(0)β οΏ½οΏ½(0)
Table 4.1: Table of Laplace Transforms
4.1. DEFINITION AND PROPERTIES 49
There is also a one-to-one correspondence between functions and their Laplacetransforms. A table of Laplace transforms can therefore be constructed and usedto find both Laplace and inverse Laplace transforms of commonly occurringfunctions. Such a table is shown in Table 4.1 (and this table will be distributedwith the exams). In Table 4.1, π is a positive integer. Also, the cryptic entriesfor π’π(π‘) and πΏ(π‘β π) will be explained later in S4.3.
The rows of Table 4.1 can be determined by a combination of direct inte-gration and some tricks. We first compute directly the Laplace transform ofπππ‘π(π‘) (line 1):
β{πππ‘π(π‘)} =
β« β
0
πβπ π‘πππ‘π(π‘)ππ‘
=
β« β
0
πβ(π βπ)π‘π(π‘)ππ‘
= πΉ (π β π).
We also compute directly the Laplace transform of 1 (line 2):
β{1} =
β« β
0
πβπ π‘ππ‘
= β1
π πβπ π‘
]β0
=1
π .
Now, the Laplace transform of πππ‘ (line 3) may be found using these two results:
β{πππ‘} = β{πππ‘ Β· 1}
=1
π β π.
(4.2)
The transform of π‘π (line 4) can be found by successive integration by parts. Amore interesting method uses Taylor series expansions for πππ‘ and 1/(π βπ). Wehave
β{πππ‘} = β
{ ββπ=0
(ππ‘)π
π!
}
=
ββπ=0
ππ
π!β{π‘π}.
(4.3)
Also, with π > π,
1
π β π=
1
π (1β ππ )
=1
π
ββπ=0
(ππ
)π=
ββπ=0
ππ
π π+1.
(4.4)
50 CHAPTER 4. THE LAPLACE TRANSFORM
Using (4.2), and equating the coefficients of powers of π in (4.3) and (4.4), resultsin line 4:
β{π‘π} =π!
π π+1.
The Laplace transform of π‘ππππ‘ (line 5) can be found from line 1 and line 4:
β{π‘ππππ‘} =π!
(π β π)π+1.
The Laplace transform of sin ππ‘ (line 6) may be found from the Laplace transformof πππ‘ (line 3) using π = ππ:
β{sin ππ‘} = Im{β{ππππ‘}
}= Im
{1
π β ππ
}= Im
{π + ππ
π 2 + π2
}=
π
π 2 + π2.
Similarly, the Laplace transform of cos ππ‘ (line 7) is
β{cos ππ‘} = Re{β{ππππ‘}
}=
π
π 2 + π2.
The transform of πππ‘ sin ππ‘ (line 8) can be found from the transform of sin ππ‘(line 6) and line 1:
β{πππ‘ sin ππ‘} =π
(π β π)2 + π2;
and similarly for the transform of πππ‘ cos ππ‘:
β{πππ‘ cos ππ‘} =π β π
(π β π)2 + π2.
The Laplace transform of π‘ sin ππ‘ (line 10) can be found from the Laplace trans-form of π‘πππ‘ (line 5 with π = 1) using π = ππ:
β{π‘ sin ππ‘} = Im{β{π‘ππππ‘}
}= Im
{1
(π β ππ)2
}= Im
{(π + ππ)2
(π 2 + π2)2
}=
2ππ
(π 2 + π2)2.
Similarly, the Laplace transform of π‘ cos ππ‘ (line 11) is
β{π‘ cos ππ‘} = Re{β{π‘ππππ‘}
}= Re
{(π + ππ)2
(π 2 + π2)2
}=
π 2 β π2
(π 2 + π2)2.
4.2. SOLUTION OF INITIAL VALUE PROBLEMS 51
We now transform the inhomogeneous constant-coefficient, second-order, lin-ear inhomogeneous ode for π₯ = π₯(π‘),
ποΏ½οΏ½+ ποΏ½οΏ½+ ππ₯ = π(π‘),
making use of the linearity of the Laplace transform:
πβ{οΏ½οΏ½}+ πβ{οΏ½οΏ½}+ πβ{π₯} = β{π}.
To determine the Laplace transform of οΏ½οΏ½(π‘) (line 15) in terms of the Laplacetransform of π₯(π‘) and the initial conditions π₯(0) and οΏ½οΏ½(0), we define π(π ) =β{π₯(π‘)}, and integrate β« β
0
πβπ π‘οΏ½οΏ½ππ‘
by parts. We let
π’ = πβπ π‘ ππ£ = οΏ½οΏ½ππ‘
ππ’ = βπ πβπ π‘ππ‘ π£ = π₯.
Therefore, β« β
0
πβπ π‘οΏ½οΏ½ππ‘ = π₯πβπ π‘]β0
+ π
β« β
0
πβπ π‘π₯ππ‘
= π π(π )β π₯(0),
where assumed convergence of the Laplace transform requires
limπ‘ββ
π₯(π‘)πβπ π‘ = 0.
Similarly, the Laplace transform of οΏ½οΏ½(π‘) (line 16) is determined by integratingβ« β
0
πβπ π‘οΏ½οΏ½ππ‘
by parts and using the just derived result for the first derivative. We let
π’ = πβπ π‘ ππ£ = οΏ½οΏ½ππ‘
ππ’ = βπ πβπ π‘ππ‘ π£ = οΏ½οΏ½,
so that β« β
0
πβπ π‘οΏ½οΏ½ππ‘ = οΏ½οΏ½πβπ π‘]β0
+ π
β« β
0
πβπ π‘οΏ½οΏ½ππ‘
= βοΏ½οΏ½(0) + π (π π(π )β π₯(0)
)= π 2π(π )β π π₯(0)β οΏ½οΏ½(0),
where similarly we assume limπ‘ββ οΏ½οΏ½(π‘)πβπ π‘ = 0.
4.2 Solution of initial value problems
We begin with a simple homogeneous ode and show that the Laplace transformmethod yields an identical result to our previously learned method. We thenapply the Laplace transform method to solve an inhomogeneous equation.
52 CHAPTER 4. THE LAPLACE TRANSFORM
Example: Solve οΏ½οΏ½βοΏ½οΏ½β2π₯ = 0 with π₯(0) = 1 and οΏ½οΏ½(0) = 0 by two differentmethods.
view tutorial
The characteristic equation of the ode is determined from the ansatz π₯ = πππ‘
and is
π2 β π β 2 = (π β 2)(π + 1) = 0.
The general solution of the ode is therefore
π₯(π‘) = π1π2π‘ + π2π
βπ‘.
To satisfy the initial conditions, we must have 1 = π1 + π2 and 0 = 2π1 β π2,requiring π1 = 1
3 and π2 = 23 . Therefore, the solution to the ode that satisfies
the initial conditions is given by
π₯(π‘) =1
3π2π‘ +
2
3πβπ‘. (4.5)
We now solve this example using the Laplace transform. Taking the Laplacetransform of both sides of the ode, using the linearity of the transform, andapplying our result for the transform of the first and second derivatives, we find
[π 2π(π )β π π₯(0)β οΏ½οΏ½(0)]β [π π(π )β π₯(0)]β [2π(π )] = 0,
or
π(π ) =(π β 1)π₯(0) + οΏ½οΏ½(0)
π 2 β π β 2.
Note that the denominator of the right-hand-side is just the quadratic from thecharacteristic equation of the homogeneous ode, and that this factor arises fromthe derivatives of the exponential term in the Laplace transform integral.
Applying the initial conditions, we find
π(π ) =π β 1
(π β 2)(π + 1). (4.6)
We have thus determined the Laplace transformed solution π(π ) = β{π₯(π‘)}.We now need to compute the inverse Laplace transform π₯(π‘) = ββ1{π(π )}.
However, direct inversion of (4.6) by searching Table 4.1 is not possible, buta partial fraction expansion may be useful. In particular, we write
π β 1
(π β 2)(π + 1)=
π
π β 2+
π
π + 1. (4.7)
The cover-up method can be used to solve for π and π. We multiply both sidesof (4.7) by π β 2 and put π = 2 to isolate π:
π =π β 1
π + 1
]π =2
=1
3.
4.2. SOLUTION OF INITIAL VALUE PROBLEMS 53
Similarly, we multiply both sides of (4.7) by π + 1 and put π = β1 to isolate π:
π =π β 1
π β 2
]π =β1
=2
3.
Therefore,
π(π ) =1
3Β· 1
π β 2+
2
3Β· 1
π + 1,
and line 3 of Table 4.1 gives us the inverse transforms of each term separatelyto yield
π₯(π‘) =1
3π2π‘ +
2
3πβπ‘,
identical to (4.5).
Example: Solve οΏ½οΏ½ + π₯ = sin 2π‘ with π₯(0) = 2 and οΏ½οΏ½(0) = 1 by Laplacetransform methods.
Taking the Laplace transform of both sides of the ode, we find
π 2π(π )β π π₯(0)β οΏ½οΏ½(0) +π(π ) = β{sin 2π‘}
=2
π 2 + 4,
where the Laplace transform of sin 2π‘ made use of line 6 of Table 4.1. Substi-tuting for π₯(0) and οΏ½οΏ½(0) and solving for π(π ), we obtain
π(π ) =2π + 1
π 2 + 1+
2
(π 2 + 1)(π 2 + 4).
To determine the inverse Laplace transform from Table 4.1, we perform a partialfraction expansion of the second term:
2
(π 2 + 1)(π 2 + 4)=
ππ + π
π 2 + 1+
ππ + π
π 2 + 4. (4.8)
By inspection, we can observe that π = π = 0 and that π = βπ. A quickcalculation shows that 3π = 2, or π = 2/3. Therefore,
π(π ) =2π + 1
π 2 + 1+
2/3
π 2 + 1β 2/3
(π 2 + 4)
=2π
π 2 + 1+
5/3
π 2 + 1β 2/3
(π 2 + 4).
From lines 6 and 7 of Table 4.1, we obtain the solution by taking inverse Laplacetransforms of the three terms separately, where π = 1 in the first two terms, andπ = 2 in the third term:
π₯(π‘) = 2 cos π‘+5
3sin π‘β 1
3sin 2π‘.
54 CHAPTER 4. THE LAPLACE TRANSFORM
4.3 Heaviside and Dirac delta functions
The Laplace transform technique becomes truly useful when solving odes withdiscontinuous or impulsive inhomogeneous terms, these terms commonly mod-eled using Heaviside or Dirac delta functions. We will discuss these functionsin turn, as well as their Laplace transforms.
4.3.1 Heaviside function
view tutorial
The Heaviside or unit step function, denoted here by π’π(π‘), is zero for π‘ < π andis one for π‘ β₯ π; that is,
π’π(π‘) =
{0, π‘ < π;1, π‘ β₯ π.
(4.9)
The precise value of π’π(π‘) at the single point π‘ = π shouldnβt matter.
The Heaviside function can be viewed as the step-up function. The step-down functionβone for π‘ < π and zero for π‘ β₯ πβis defined as
1β π’π(π‘) =
{1, π‘ < π;0, π‘ β₯ π.
(4.10)
The step-up, step-down functionβzero for π‘ < π, one for π β€ π‘ < π, and zerofor π‘ β₯ πβis defined as
π’π(π‘)β π’π(π‘) =
β§β¨β© 0, π‘ < π;1, π β€ π‘ < π;0, π‘ β₯ π.
(4.11)
The Laplace transform of the Heaviside function is determined by integra-tion:
β{π’π(π‘)} =
β« β
0
πβπ π‘π’π(π‘)ππ‘
=
β« β
π
πβπ π‘ππ‘
=πβππ
π ,
and is given in line 12 of Table 4.1.
The Heaviside function can be used to represent a translation of a functionπ(π‘) a distance π in the positive π‘ direction. We have
π’π(π‘)π(π‘β π) =
{0, π‘ < π;
f(t-c), π‘ β₯ π.
4.3. HEAVISIDE AND DIRAC DELTA FUNCTIONS 55
t
xx=f(t)
Figure 4.1: A linearly increasing function which turns into a sinusoidal function.
The Laplace transform is
β{π’π(π‘)π(π‘β π)} =
β« β
0
πβπ π‘π’π(π‘)π(π‘β π)ππ‘
=
β« β
π
πβπ π‘π(π‘β π)ππ‘
=
β« β
0
πβπ (π‘β²+π)π(π‘β²)ππ‘β²
= πβππ
β« β
0
πβπ π‘β²π(π‘β²)ππ‘β²
= πβππ πΉ (π ),
where we have changed variables to π‘β² = π‘βπ. The translation of π(π‘) a distanceπ in the positive π‘ direction corresponds to the multiplication of πΉ (π ) by theexponential πβππ . This result is shown in line 13 of Table 4.1.
Piecewise-defined inhomogeneous terms can be modeled using Heavisidefunctions. For example, consider the general case of a piecewise function definedon two intervals:
π(π‘) =
{π1(π‘), if π‘ < π‘*;π2(π‘), if π‘ β₯ π‘*.
Using the Heaviside function π’π‘* , the function π(π‘) can be written in a singleline as
π(π‘) = π1(π‘) +(π2(π‘)β π1(π‘)
)π’π‘*(π‘).
This example can be generalized to piecewise functions defined on multipleintervals.
As a concrete example, suppose the inhomogeneous term is represented bya linearly increasing function, which then turns into a sinusoidal function for
56 CHAPTER 4. THE LAPLACE TRANSFORM
π‘ > π‘*, as sketched in Fig. 4.1. Explicitly,
π(π‘) =
{ππ‘, if π‘ < π‘*;ππ‘* + π sin
(π(π‘β π‘*)
), if π‘ β₯ π‘*.
We can rewrite π(π‘) using the Heaviside function π’π‘*(π‘):
π(π‘) = ππ‘+
(π sin
(π(π‘β π‘*)
)β π(π‘β π‘*)
)Β· π’π‘*(π‘).
This specific form of π(π‘) enables a relatively easy Laplace transform. We canwrite
π(π‘) = ππ‘+ β(π‘β π‘*)π’π‘*(π‘),
where we have defined
β(π‘) = π sinππ‘β ππ‘.
Using line 13, the Laplace transform of π(π‘) is
πΉ (π ) = πβ{π‘}+ β{β(π‘β π‘*)π’π‘*(π‘)}= πβ{π‘}+ πβπ‘*π β{β(π‘)},
and where using lines 4 and 6,
β{π‘} =1
π 2, β{β(π‘)} =
ππ
π 2 + π2β π
π 2.
4.3.2 Dirac delta function
view tutorialThe Dirac delta function, denoted as πΏ(π‘), is defined by requiring that for anyfunction π(π‘), β« β
ββπ(π‘)πΏ(π‘)ππ‘ = π(0).
The usual view of the shifted Dirac delta function πΏ(π‘ β π) is that it is zeroeverywhere except at π‘ = π, where it is infinite, and the integral over the Diracdelta function is one. The Dirac delta function is technically not a function,but is what mathematicians call a distribution. Nevertheless, in most cases ofpractical interest, it can be treated like a function, where physical results areobtained following a final integration.
There are many ways to represent the Dirac delta function as a limit of awell-defined function. For our purposes, the most useful representation makesuse of the step-up, step-down function of (4.11):
πΏ(π‘β π) = limπβ0
1
2π(π’πβπ(π‘)β π’π+π(π‘)).
Before taking the limit, the well-defined step-up, step-down function is zeroexcept over a small interval of width 2π centered at π‘ = π, over which it takesthe large value 1/2π. The integral of this function is one, independent of thevalue of π.
4.4. DISCONTINUOUS OR IMPULSIVE TERMS 57
The Laplace transform of the Dirac delta function is easily found by inte-gration using the definition of the delta function:
β{πΏ(π‘β π)} =
β« β
0
πβπ π‘πΏ(π‘β π)ππ‘
= πβππ .
This result is shown in line 14 of Table 4.1.
4.4 Discontinuous or impulsive inhomogeneousterms
We now solve some more challenging odeβs with discontinuous or impulsiveinhomogeneous terms.
Example: Solve 2οΏ½οΏ½+ οΏ½οΏ½+ 2π₯ = π’5(π‘)β π’20(π‘), with π₯(0) = οΏ½οΏ½(0) = 0
The inhomogeneous term here is a step-up, step-down function that is unityover the interval (5, 20) and zero elsewhere. Taking the Laplace transform ofthe ode using Table 4.1,
2(π 2π(π )β π π₯(0)β οΏ½οΏ½(0)
)+ π π(π )β π₯(0) + 2π(π ) =
πβ5π
π β πβ20π
π .
Using the initial values and solving for π(π ), we find
π(π ) =πβ5π β πβ20π
π (2π 2 + π + 2).
To determine the solution for π₯(π‘) we now need to find the inverse Laplacetransform. The exponential functions can be dealt with using line 13 of Table4.1. We write
π(π ) = (πβ5π β πβ20π )π»(π ),
where
π»(π ) =1
π (2π 2 + π + 2).
Then using line 13, we have
π₯(π‘) = π’5(π‘)β(π‘β 5)β π’20(π‘)β(π‘β 20), (4.12)
where β(π‘) = ββ1{π»(π )}.To determine β(π‘) we need the partial fraction expansion of π»(π ). Since the
discriminant of 2π 2 + π + 2 is negative, we have
1
π (2π 2 + π + 2)=
π
π +
ππ + π
2π 2 + π + 2,
yielding the equation
1 = π(2π 2 + π + 2) + (ππ + π)π ;
58 CHAPTER 4. THE LAPLACE TRANSFORM
or after equating powers of π ,
2π+ π = 0, π+ π = 0, 2π = 1,
yielding π = 12 , π = β1, and π = β 1
2 . Therefore,
π»(π ) =1/2
π β
π + 12
2π 2 + π + 2
=1
2
(1
π β
π + 12
π 2 + 12π + 1
).
Inspecting Table 4.1, the first term can be transformed using line 2, and thesecond term can be transformed using lines 8 and 9, provided we complete thesquare of the denominator and then massage the numerator. That is, first wecomplete the square:
π 2 +1
2π + 1 =
(π +
1
4
)2
+15
16;
and next we write
π + 12
π 2 + 12π + 1
=
(π + 1
4
)+ 1β
15
β1516(
π + 14
)2+ 15
16
.
Therefore, the function π»(π ) can be written as
π»(π ) =1
2
ββ1
π β
(π + 1
4
)(π + 1
4 )2 + 15
16
β(
1β15
) β1516
(π + 14 )
2 + 1516
ββ .
The first term is transformed using line 2, the second term using line 9 and thethird term using line 8. We finally obtain
β(π‘) =1
2
(1β πβπ‘/4
(cos (
β15π‘/4) +
1β15
sin (β15π‘/4)
)), (4.13)
which when combined with (4.12) yields the rather complicated solution forπ₯(π‘).
We briefly comment that it is also possible to solve this example withoutusing the Laplace transform. The key idea is that both π₯ and οΏ½οΏ½ are continuousfunctions of π‘. Clearly from the form of the inhomogeneous term and the initialconditions, π₯(π‘) = 0 for 0 β€ π‘ β€ 5. We then solve the ode between 5 β€ π‘ β€ 20with the inhomogeneous term equal to unity and initial conditions π₯(5) = οΏ½οΏ½(5) =0. This requires first finding the general homogeneous solution, next finding aparticular solution, and then adding the homogeneous and particular solutionsand solving for the two unknown constants. To simplify the algebra, note thatthe best ansatz to use to find the homogeneous solution is π₯(π‘) = ππ(π‘β5), andnot π₯(π‘) = πππ‘. Finally, we solve the homogeneous ode for π‘ β₯ 20 using asboundary conditions the previously determined values π₯(20) and οΏ½οΏ½(20), wherewe have made use of the continuity of π₯ and οΏ½οΏ½. Here, the best ansatz to useis π₯(π‘) = ππ(π‘β20). The student may benefit by trying this as an exercise andattempting to obtain a final solution that agrees with the form given by (4.12)and (4.13).
4.4. DISCONTINUOUS OR IMPULSIVE TERMS 59
Example: Solve 2οΏ½οΏ½+ οΏ½οΏ½+ 2π₯ = πΏ(π‘β 5) with π₯(0) = οΏ½οΏ½(0) = 0
Here the inhomogeneous term is an impulse at time π‘ = 5. Taking the Laplacetransform of the ode using Table 4.1, and applying the initial conditions,
(2π 2 + π + 2)π(π ) = πβ5π ,
so that
π(π ) =1
2πβ5π
(1
π 2 + 12π + 1
)=
1
2πβ5π
(1
(π + 14 )
2 + 1516
)
=1
2
β16
15πβ5π
βββ
1516
(π + 14 )
2 + 1516
ββ .
The inverse Laplace transform may now be computed using lines 8 and 13 ofTable 4.1:
π₯(π‘) =2β15
π’5(π‘)πβ(π‘β5)/4 sin
(β15(π‘β 5)/4
). (4.14)
It is interesting to solve this example without using a Laplace transform.Clearly, π₯(π‘) = 0 up to the time of impulse at π‘ = 5. Furthermore, after theimpulse the ode is homogeneous and can be solved with standard methods. Theonly difficulty is determining the initial conditions of the homogeneous ode atπ‘ = 5+.
When the inhomogeneous term is proportional to a delta-function, the solu-tion π₯(π‘) is continuous across the delta-function singularity, but the derivativeof the solution οΏ½οΏ½(π‘) is discontinuous. If we integrate the second-order ode acrossthe singularity at π‘ = 5 and consider π β 0, only the second derivative term ofthe left-hand-side survives, and
2
β« 5+π
5βπ
οΏ½οΏ½ππ‘ =
β« 5+π
5βπ
πΏ(π‘β 5)ππ‘
= 1.
And as π β 0, we have οΏ½οΏ½(5+)β οΏ½οΏ½(5β) = 1/2. Since οΏ½οΏ½(5β) = 0, the appropriateinitial conditions immediately after the impulse force are π₯(5+) = 0 and οΏ½οΏ½(5+) =1/2. This result can be confirmed using (4.14).
60 CHAPTER 4. THE LAPLACE TRANSFORM
Chapter 5
Series solutions ofsecond-order linearhomogeneous differentialequations
Reference: Boyce and DiPrima, Chapter 5
We consider the second-order linear homogeneous differential equation for π¦ =π¦(π₯):
π (π₯)π¦β²β² +π(π₯)π¦β² +π (π₯)π¦ = 0, (5.1)
where π (π₯), π(π₯) and π (π₯) are polynomials or convergent power series (aroundπ₯ = π₯0), with no common polynomial factors (that could be divided out). Thevalue π₯ = π₯0 is called an ordinary point of (5.1) if π (π₯0) = 0, and is called asingular point if π (π₯0) = 0. Singular points will later be further classified asregular singular points and irregular singular points. Our goal is to find twoindependent solutions of (5.1), valid in a neighborhood about π₯ = π₯0.
5.1 Ordinary points
If π₯0 is an ordinary point of (5.1), then it is possible to determine two powerseries solutions (i.e., Taylor series) for π¦ = π¦(π₯) that converge in a neighborhoodof π₯ = π₯0. We illustrate the method of solution by solving two examples.
Example: Find the general solution of π¦β²β² + π¦ = 0.
view tutorial
By now, you should know that the general solution is π¦(π₯) = π0 cosπ₯+ π1 sinπ₯,with π0 and π1 constants. To find a power series solution about the point π₯ = 0,we write
π¦(π₯) =
ββπ=0
πππ₯π;
61
62 CHAPTER 5. SERIES SOLUTIONS
and upon differentiating term-by-term
π¦β²(π₯) =
ββπ=1
ππππ₯πβ1,
and
π¦β²β²(π₯) =
ββπ=2
π(πβ 1)πππ₯πβ2.
Substituting the power series for π¦ and its derivatives into the differential equa-tion to be solved, we obtain
ββπ=2
π(πβ 1)πππ₯πβ2 +
ββπ=0
πππ₯π = 0. (5.2)
The power-series solution method requires combining the two sums on the left-hand-side of (5.2) into a single power series in π₯. To shift the exponent of π₯πβ2
in the first sum upward by two to obtain π₯π, we need to shift the summationindex downward by two; that is,
ββπ=2
π(πβ 1)πππ₯πβ2 =
ββπ=0
(π+ 2)(π+ 1)ππ+2π₯π.
We can then combine the two sums in (5.2) to obtain
ββπ=0
((π+ 2)(π+ 1)ππ+2 + ππ
)π₯π = 0. (5.3)
For (5.3) to be satisfied, the coefficient of each power of π₯must vanish separately.(This can be proved by setting π₯ = 0 after successive differentiation.) Wetherefore obtain the recurrence relation
ππ+2 = β ππ(π+ 2)(π+ 1)
, π = 0, 1, 2, . . . .
We observe that even and odd coefficients decouple. We thus obtain two inde-pendent sequences starting with first term π0 or π1. Developing these sequences,we have for the sequence beginning with π0:
π0,
π2 = β1
2π0,
π4 = β 1
4 Β· 3π2 =
1
4 Β· 3 Β· 2π0,
π6 = β 1
6 Β· 5π4 = β 1
6!π0;
and the general coefficient in this sequence for π = 0, 1, 2, . . . is
π2π =(β1)π
(2π)!π0.
5.1. ORDINARY POINTS 63
Also, for the sequence beginning with π1:
π1,
π3 = β 1
3 Β· 2π1,
π5 = β 1
5 Β· 4π3 =
1
5 Β· 4 Β· 3 Β· 2π1,
π7 = β 1
7 Β· 6π5 = β 1
7!π1;
and the general coefficient in this sequence for π = 0, 1, 2, . . . is
π2π+1 =(β1)π
(2π+ 1)!π1.
Using the principle of superposition, the general solution is therefore
π¦(π₯) = π0
ββπ=0
(β1)π
(2π)!π₯2π + π1
ββπ=0
(β1)π
(2π+ 1)!π₯2π+1
= π0
(1β π₯2
2!+
π₯4
4!β . . .
)+ π1
(π₯β π₯3
3!+
π₯5
5!β . . .
)= π0 cosπ₯+ π1 sinπ₯,
as expected.
In our next example, we will solve the Airyβs Equation. This differentialequation arises in the study of optics, fluid mechanics, and quantum mechanics.
Example: Find the general solution of π¦β²β² β π₯π¦ = 0.
view tutorial
With
π¦(π₯) =
ββπ=0
πππ₯π,
the differential equation becomes
ββπ=2
π(πβ 1)πππ₯πβ2 β
ββπ=0
πππ₯π+1 = 0. (5.4)
We shift the first sum to π₯π+1 by shifting the exponent up by three, i.e.,
ββπ=2
π(πβ 1)πππ₯πβ2 =
ββπ=β1
(π+ 3)(π+ 2)ππ+3π₯π+1.
When combining the two sums in (5.4), we separate out the extra π = β1 termin the first sum given by 2π2. Therefore, (5.4) becomes
2π2 +
ββπ=0
((π+ 3)(π+ 2)ππ+3 β ππ
)π₯π+1 = 0. (5.5)
64 CHAPTER 5. SERIES SOLUTIONS
Setting coefficients of powers of π₯ to zero, we first find π2 = 0, and then obtainthe recursion relation
ππ+3 =1
(π+ 3)(π+ 2)ππ. (5.6)
Three sequences of coefficientsβthose starting with either π0, π1 or π2βdecouple.In particular the three sequences are
π0, π3, π6, π9, . . . ;
π1, π4, π7, π10, . . . ;
π2, π5, π8, π11 . . . .
Since π2 = 0, we find immediately for the last sequence
π2 = π5 = π8 = π11 = Β· Β· Β· = 0.
We compute the first four nonzero terms in the power series with coefficientscorresponding to the first two sequences. Starting with π0, we have
π0,
π3 =1
3 Β· 2π0,
π6 =1
6 Β· 5 Β· 3 Β· 2π0,
π9 =1
9 Β· 8 Β· 6 Β· 5 Β· 3 Β· 2π0;
and starting with π1,
π1,
π4 =1
4 Β· 3π1,
π7 =1
7 Β· 6 Β· 4 Β· 3π1,
π10 =1
10 Β· 9 Β· 7 Β· 6 Β· 4 Β· 3π1.
The general solution for π¦ = π¦(π₯), can therefore be written as
π¦(π₯) = π0
(1 +
π₯3
6+
π₯6
180+
π₯9
12960+ . . .
)+ π1
(π₯+
π₯4
12+
π₯7
504+
π₯10
45360+ . . .
)= π0π¦0(π₯) + π1π¦1(π₯).
Suppose we would like to graph the solutions π¦ = π¦0(π₯) and π¦ = π¦1(π₯)versus π₯ by solving the differential equation π¦β²β² β π₯π¦ = 0 numerically. Whatinitial conditions should we use? Clearly, π¦ = π¦0(π₯) solves the ode with initialvalues π¦(0) = 1 and π¦β²(0) = 0, while π¦ = π¦1(π₯) solves the ode with initial valuesπ¦(0) = 0 and π¦β²(0) = 1.
The numerical solutions, obtained using MATLAB, are shown in Fig. 5.1.Note that the solutions oscillate for negative π₯ and grow exponentially for posi-tive π₯. This can be understood by recalling that π¦β²β² + π¦ = 0 has oscillatory sineand cosine solutions and π¦β²β² β π¦ = 0 has exponential hyperbolic sine and cosinesolutions.
5.2. REGULAR SINGULAR POINTS: CAUCHY-EULER EQUATIONS 65
β10 β8 β6 β4 β2 0 2β2
β1
0
1
2
y 0
Airyβs functions
β10 β8 β6 β4 β2 0 2β2
β1
0
1
2
x
y 1
Figure 5.1: Numerical solution of Airyβs equation.
5.2 Regular singular points: Cauchy-Euler equa-tions
view tutorialThe value π₯ = π₯0 is called a regular singular point of the ode
(π₯β π₯0)2π¦β²β² + π(π₯)(π₯β π₯0)π¦
β² + π(π₯)π¦ = 0, (5.7)
if π(π₯) and π(π₯) have convergent Taylor series about π₯ = π₯0, i.e., π(π₯) and π(π₯)can be written as a power-series in (π₯β π₯0):
π(π₯) = π0 + π1(π₯β π₯0) + π2(π₯β π₯0)2 + . . . ,
π(π₯) = π0 + π1(π₯β π₯0) + π2(π₯β π₯0)2 + . . . ,
with ππ and ππ constants, and π0 = 0 so that (π₯ β π₯0) is not a common factorof the coefficients. Any point π₯ = π₯0 that is not an ordinary point or a regularsingular point is called an irregular singular point. Many important differentialequations of physical interest have regular singular points, and their solutionsgo by the generic name of special functions, with specific names associatedwith now famous mathematicians like Bessel, Legendre, Hermite, Laguerre andChebyshev.
Here, we will only consider the simplest ode with a regular singular point atπ₯ = 0. This ode is called an Cauchy-Euler equation, and has the form
π₯2π¦β²β² + πΌπ₯π¦β² + π½π¦ = 0, (5.8)
66 CHAPTER 5. SERIES SOLUTIONS
with πΌ and π½ constants. Note that (5.7) reduces to an Cauchy-Euler equation(about π₯ = π₯0) when one considers only the leading-order term in the Taylorseries expansion of the functions π(π₯) and π(π₯). In fact, taking π(π₯) = π0 andπ(π₯) = π0 and solving the associated Cauchy-Euler equation results in at leastone of the leading-order solutions to the more general ode (5.7). Often, thisis sufficient to obtain initial conditions for numerical solution of the full ode.Students wishing to learn how to find the general solution of (5.7) can consultBoyce & DiPrima.
An appropriate ansatz for (5.8) is π¦ = π₯π, when π₯ > 0 and π¦ = (βπ₯)π whenπ₯ < 0, (or more generally, π¦ = |π₯|π for all π₯), with π constant. After substitutioninto (5.8), we obtain for both positive and negative π₯
π(π β 1)|π₯|π + πΌπ|π₯|π + π½|π₯|π = 0,
and we observe that our ansatz is rewarded by cancelation of |π₯|π. We thusobtain the following quadratic equation for π:
π2 + (πΌβ 1)π + π½ = 0, (5.9)
which can be solved using the quadratic formula. Three cases immediatelyappear: (i) real distinct roots, (ii) complex conjugate roots, (iii) repeated roots.Students may recall being in a similar situation when solving the second-orderlinear homogeneous ode with constant coefficients. Indeed, it is possible todirectly transform the Cauchy-Euler equation into an equation with constantcoefficients so that our previous results can be used.
The appropriate transformation for π₯ > 0 is to let π₯ = ππ and π¦(π₯) = π (π),so that the ansatz π¦(π₯) = π₯π becomes the ansatz π (π) = πππ, appropriate if π (π)satisfies a constant coefficient ode. If π₯ < 0, then the appropriate transformationis π₯ = βππ, since ππ > 0. We need only consider π₯ > 0 here and subsequentlygeneralize our result by replacing π₯ everywhere by its absolute value.
We thus transform the differential equation (5.8) for π¦ = π¦(π₯) into a differ-ential equation for π = π (π), using π₯ = ππ, or equivalently, π = lnπ₯. By thechain rule,
ππ¦
ππ₯=
ππ
ππ
ππ
ππ₯
=1
π₯
ππ
ππ
= πβπ ππ
ππ,
so that symbolically,π
ππ₯= πβπ π
ππ.
The second derivative transforms as
π2π¦
ππ₯2= πβπ π
ππ
(πβπ ππ
ππ
)= πβ2π
(π2π
ππ2β ππ
ππ
).
5.2. REGULAR SINGULAR POINTS: CAUCHY-EULER EQUATIONS 67
Upon substitution of the derivatives of π¦ into (5.8), and using π₯ = ππ, we obtain
π2π(πβ2π (π β²β² β π β²)
)+ πΌππ
(πβππ β²)+ π½π = π β²β² + (πΌβ 1)π β² + π½π
= 0.
As expected, the ode for π = π (π) has constant coefficients, and with π = πππ,the characteristic equation for π is given by (5.9). We now directly transferprevious results obtained for the constant coefficient second-order linear homo-geneous ode.
5.2.1 Real, distinct roots
This simplest case needs no transformation. If (πΌβ 1)2 β 4π½ > 0, then with πΒ±the real roots of (5.9), the general solution is
π¦(π₯) = π1|π₯|π+ + π2|π₯|πβ .
5.2.2 Complex conjugate roots
If (πΌ β 1)2 β 4π½ < 0, we can write the complex roots of (5.9) as πΒ± = π Β± ππ.Recall the general solution for π = π (π) is given by
π (π) = πππ (π΄ cosππ +π΅ sinππ) ;
and upon transformation, and replacing π₯ by |π₯|,
π¦(π₯) = |π₯|π(π΄ cos (π ln |π₯|) +π΅ sin (π ln |π₯|)
).
5.2.3 Repeated roots
If (πΌ β 1)2 β 4π½ = 0, there is one real root π of (5.9). The general solution forπ is
π (π) = πππ (π1 + π2π) ,
yieldingπ¦(π₯) = |π₯|π (π1 + π2 ln |π₯|) .
We now give examples illustrating these three cases.
Example: Solve 2π₯2π¦β²β² + 3π₯π¦β² β π¦ = 0 for 0 β€ π₯ β€ 1 with two-pointboundary condition π¦(0) = 0 and π¦(1) = 1.
Since π₯ > 0, we try π¦ = π₯π and obtain the characteristic equation
0 = 2π(π β 1) + 3π β 1
= 2π2 + π β 1
= (2π β 1)(π + 1).
Since the characteristic equation has two real roots, the general solution is givenby
π¦(π₯) = π1π₯12 + π2π₯
β1.
68 CHAPTER 5. SERIES SOLUTIONS
We now encounter for the first time two-point boundary conditions, which canbe used to determine the coefficients π1 and π2. Since y(0)=0, we must haveπ2 = 0. Applying the remaining condition π¦(1) = 1, we obtain the uniquesolution
π¦(π₯) =βπ₯.
Note that π₯ = 0 is called a singular point of the ode since the general solutionis singular at π₯ = 0 when π2 = 0. Our boundary condition imposes that π¦(π₯) isfinite at π₯ = 0 removing the singular solution. Nevertheless, π¦β² remains singularat π₯ = 0. Indeed, this is why we imposed a two-point boundary condition ratherthan specifying the value of π¦β²(0) (which is infinite).
Example: Find the general solution of π₯2π¦β²β² + π₯π¦β² + π¦ = 0 for π₯ > 0.
With the ansatz π¦ = π₯π, we obtain
0 = π(π β 1) + π + 1
= π2 + 1,
so that π = Β±π. Therefore, with π = lnπ₯, we have π (π) = π΄ cos π +π΅ sin π, andour solution for π¦(π₯) is
π¦(π₯) = π΄ cos (lnπ₯) +π΅ sin (lnπ₯).
Example: Find the general solution of π₯2π¦β²β² + 5π₯π¦β² + 4π¦ = 0 for π₯ > 0.
With the ansatz π¦ = π₯π, we obtain
0 = π(π β 1) + 5π + 4
= π2 + 4π + 4
= (π + 2)2,
so that there is a repeated root π = β2. With π = lnπ₯, we have π (π) =(π1 + π2π)π
β2π, so that
π¦(π₯) =π1 + π2 lnπ₯
π₯2.
Chapter 6
Systems of first-order linearequations
Reference: Boyce and DiPrima, Chapter 7
Systems of coupled linear equations can result, for example, from linear stabilityanalyses of nonlinear equations, and from normal mode analyses of coupled os-cillators. Here, we will consider only the simplest case of a system of two coupledfirst-order, linear, homogeneous equations with constant coefficients. These twofirst-order equations are in fact equivalent to a single second-order equation, andthe methods of Chapter 3 could be used for solution. Nevertheless, viewing theproblem as a system of first-order equations introduces the important conceptof the phase space, and can easily be generalized to higher-order linear systems.
6.1 Determinants and the eigenvalue problem
We begin by reviewing some basic linear algebra. For the simplest 2 Γ 2 case,let
A =
(π ππ π
), x =
(π₯1
π₯2
), (6.1)
and consider the homogeneous equation
Ax = 0. (6.2)
When does there exist a nontrivial (not identically zero) solution for x? Toanswer this question, we solve directly the system
ππ₯1 + ππ₯2 = 0,
ππ₯1 + ππ₯2 = 0.
Multiplying the first equation by π and the second by π, and subtracting thesecond equation from the first, results in
(ππβ ππ)π₯1 = 0.
Similarly, multiplying the first equation by π and the second by π, and subtract-ing the first equation from the second, results in
(ππβ ππ)π₯2 = 0.
69
70 CHAPTER 6. SYSTEMS OF EQUATIONS
Therefore, a nontrivial solution of (6.2) exists only if ππ β ππ = 0. If we definethe determinant of the 2Γ 2 matrix A to be detA = ππβ ππ, then we say thata nontrivial solution to (6.2) exists provided detA = 0.
The same calculation may be repeated for a 3Γ 3 matrix. If
A =
ββ π π ππ π ππ β π
ββ , x =
ββ π₯1
π₯2
π₯3
ββ ,
then there exists a nontrivial solution to (6.2) provided detA = 0, wheredetA = π(ππ β πβ) β π(ππ β ππ) + π(πβ β ππ). The definition of the deter-minant can be further generalized to any πΓ π matrix, and is typically taughtin a first course on linear algebra.
We now consider the eigenvalue problem. For A an πΓ π matrix and v anπΓ 1 column vector, the eigenvalue problem solves the equation
Av = πv (6.3)
for eigenvalues ππ and corresponding eigenvectors vπ. We rewrite the eigenvalueequation (6.3) as
(Aβ πI)v = 0, (6.4)
where I is the πΓπ identity matrix. A nontrivial solution of (6.4) exists provided
det (Aβ πI) = 0. (6.5)
Equation (6.5) is an π-th order polynomial equation in π, and is called thecharacteristic equation of A. The characteristic equation can be solved forthe eigenvalues, and for each eigenvalue, a corresponding eigenvector can bedetermined directly from (6.3).
We can demonstrate how this works for the 2 Γ 2 matrix A of (6.1). Wehave
0 = det (Aβ πI)
=
πβ π ππ πβ π
= (πβ π)(πβ π)β ππ
= π2 β (π+ π)π+ (ππβ ππ).
This characteristic equation can be more generally written as
π2 β TrAπ+ detA = 0, (6.6)
where TrA is the trace, or sum of the diagonal elements, of the matrix A. Ifπ is an eigenvalue of A, then the corresponding eigenvector v may be found bysolving (
πβ π ππ πβ π
)(π£1π£2
)= 0,
where the equation of the second row will always be a multiple of the equationof the first row. The eigenvector v has arbitrary normalization, and we mayalways choose for convenience π£1 = 1.
In the next section, we will see several examples of an eigenvector analysis.
6.2. COUPLED FIRST-ORDER EQUATIONS 71
6.2 Two coupled first-order linear homogeneousdifferential equations
With A a 2Γ 2 constant matrix and x a 2Γ 1 column vector, we now considerthe system of differential equations given by
x = Ax. (6.7)
We will consider by example three cases separately: (i) eigenvalues of A are realand there are two linearly independent eigenvectors; (ii) eigenvalues of A arecomplex conjugates, and; (iii) A has only one linearly independent eigenvector.These three cases are completely analogous to the cases considered previouslywhen solving the second-order, linear, constant-coefficient, homogeneous equa-tion.
6.2.1 Two distinct real eigenvalues
We illustrate the solution method by example.
Example: Find the general solution of οΏ½οΏ½1 = π₯1 + π₯2, οΏ½οΏ½2 = 4π₯1 + π₯2.
view tutorialThe equation to be solved may be rewritten in matrix form as
π
ππ‘
(π₯1
π₯2
)=
(1 14 1
)(π₯1
π₯2
),
or using vector notation, written as (6.7). We take as our ansatz x(π‘) = vπππ‘,where v and π are independent of π‘. Upon substitution into (6.7), we obtain
πvπππ‘ = Avπππ‘;
and upon cancelation of the exponential, we obtain the eigenvalue problem
Av = πv. (6.8)
Finding the characteristic equation using (6.6), we have
0 = det (Aβ πI)
= π2 β 2πβ 3
= (πβ 3)(π+ 1).
Therefore, the two eigenvalues are π1 = 3 and π2 = β1.To determine the corresponding eigenvectors, we substitute the eigenvalues
successively into (A β πI)v = 0. We will write the corresponding eigenvectorsv1 and v2 using the matrix notation
(v1 v2
)=
(π£11 π£12π£21 π£22
),
where the components of v1 and v2 are written with subscripts correspondingto the first and second columns of a 2Γ 2 matrix.
72 CHAPTER 6. SYSTEMS OF EQUATIONS
For π1 = 3, and unknown eigenvector v1, we have
β2π£11 + π£21 = 0,
4π£11 β 2π£21 = 0.
Clearly, the second equation is just the first equation multiplied by β2, so onlyone equation is linearly independent. This will always be true, so for the 2Γ 2case we need only consider the first row of the matrix. The first eigenvectortherefore satisfies π£21 = 2π£11. Recall that an eigenvector is only unique up tomultiplication by a constant: we may therefore take π£11 = 1 for convenience.For π2 = β1, and eigenvector v2 = (π£12, π£22)
π , we have
2π£12 + π£22 = 0,
so that π£22 = β2π£12. Here, we take π£12 = 1. Therefore, our eigenvalues andeigenvectors are given by
π1 = 3, v1 =
(12
); π2 = β1, v2 =
(1
β2
).
Using the principle of superposition, the general solution to the ode is therefore
x(π‘) = π1v1ππ1π‘ + π2v2π
π2π‘,
or explicitly writing out the components,
π₯1(π‘) = π1π3π‘ + π2π
βπ‘,
π₯2(π‘) = 2π1π3π‘ β 2π2π
βπ‘.
We can obtain a new perspective on the solution by drawing a phase-spacediagram, shown in Fig. 6.1, with βx-axisβ π₯1 and βy-axisβ π₯2. Each curve corre-sponds to a different initial condition, and represents the trajectory of a particlefor both positive and negative π‘ with velocity given by the differential equation.The dark lines represent trajectories along the direction of the eigenvectors. Ifπ2 = 0, the motion is along the eigenvector v1 with π₯2 = 2π₯1 and motion isaway from the origin (arrows pointing out) since the eigenvalue π1 = 3 > 0.If π1 = 0, the motion is along the eigenvector v2 with π₯2 = β2π₯1 and motionis towards the origin (arrows pointing in) since the eigenvalue π2 = β1 < 0.When the eigenvalues are real and of opposite signs, the origin is called a saddlepoint. Almost all trajectories (with the exception of those with initial conditionsexactly satisfying π₯2(0) = β2π₯1(0)) eventually move away from the origin as π‘increases.
The current example can also be solved by converting the system of twofirst-order equations into a single second-order equation. Consider again thesystem of equations
οΏ½οΏ½1 = π₯1 + π₯2,
οΏ½οΏ½2 = 4π₯1 + π₯2.
We differentiate the first equation and proceed to eliminate π₯2 as follows:
οΏ½οΏ½1 = οΏ½οΏ½1 + οΏ½οΏ½2
= οΏ½οΏ½1 + 4π₯1 + π₯2
= οΏ½οΏ½1 + 4π₯1 + οΏ½οΏ½1 β π₯1
= 2οΏ½οΏ½1 + 3π₯1.
6.2. COUPLED FIRST-ORDER EQUATIONS 73
β2 β1.5 β1 β0.5 0 0.5 1 1.5 2β2
β1.5
β1
β0.5
0
0.5
1
1.5
2
x1
x 2
phase space diagram
Figure 6.1: Phase space diagram for example with two real eigenvalues of oppo-site sign.
Therefore, the equivalent second-order linear homogeneous equation is given by
οΏ½οΏ½1 β 2οΏ½οΏ½1 β 3π₯1 = 0.
If we had eliminated π₯1 instead, we would have found an identical equation forπ₯2:
οΏ½οΏ½2 β 2οΏ½οΏ½2 β 3π₯2 = 0.
The corresponding characteristic equation is π2 β 2πβ 3 = 0, which is identicalto the characteristic equation of the matrix A. In general, a system of π first-order linear homogeneous equations can be converted into an equivalent π-thorder linear homogeneous equation. Numerical methods usually require theconversion in reverse; that is, a conversion of an π-th order equation into asystem of π first-order equations.
Example: Find the general solution of οΏ½οΏ½1 = β3π₯1 +β2π₯2, οΏ½οΏ½2 =
β2π₯1 β
2π₯2.
The equations in matrix form are
π
ππ‘
(π₯1
π₯2
)=
(β3
β2β
2 β2
)(π₯1
π₯2
).
The ansatz x = vπππ‘ leads to the eigenvalue problem Av = πv, with A thematrix above. The eigenvalues are determined from
0 = det (Aβ πI)
= π2 + 5π+ 4
= (π+ 4)(π+ 1).
74 CHAPTER 6. SYSTEMS OF EQUATIONS
β2 β1.5 β1 β0.5 0 0.5 1 1.5 2β2
β1.5
β1
β0.5
0
0.5
1
1.5
2
x1
x 2
phase space diagram
Figure 6.2: Phase space diagram for example with two real eigenvalues of samesign.
Therefore, the eigenvalues of A are π1 = β4, π2 = β1. Proceeding to determinethe associated eigenvectors, for π1 = β4,
π£11 +β2π£21 = 0;
and for π2 = β1,
β2π£12 +β2π£22 = 0.
Taking the normalization π£11 = 1 and π£12 = 1, we obtain for the eigenvaluesand associated eigenvectors
π1 = β4, v1 =
(1
ββ2/2
); π2 = β1, v2 =
(1β2
).
The general solution to the ode is therefore(π₯1
π₯2
)= π1
(1
ββ2/2
)πβ4π‘ + π2
(1β2
)πβπ‘.
We show the phase space plot in Fig. 6.2. If π2 = 0, the motion is alongthe eigenvector v1 with π₯2 = β(
β2/2)π₯1 with eigenvalue π1 = β4 < 0. If
π1 = 0, the motion is along the eigenvector v2 with π₯2 =β2π₯1 with eigenvalue
π2 = β1 < 0. When the eigenvalues are real and have the same sign, the originis called a node. A node may be attracting or repelling depending on whetherthe eigenvalues are both negative (as is the case here) or positive. Observe thatthe trajectories collapse onto the v2 eigenvector since π1 < π2 < 0 and decay ismore rapid along the v1 direction.
6.2. COUPLED FIRST-ORDER EQUATIONS 75
6.2.2 Complex conjugate eigenvalues
Example: Find the general solution of οΏ½οΏ½1 = β 12π₯1 + π₯2, οΏ½οΏ½2 = βπ₯1 β 1
2π₯2.
view tutorialThe equations in matrix form are
π
ππ‘
(π₯1
π₯2
)=
(β 1
2 1β1 β 1
2
)(π₯1
π₯2
).
The ansatz x = vπππ‘ leads to the equation
0 = det (Aβ πI)
= π2 + π+5
4.
Therefore, π = β1/2Β±π; and we observe that the eigenvalues occur as a complexconjugate pair. We will denote the two eigenvalues as
π = β1
2+ π and οΏ½οΏ½ = β1
2β π.
Now, for A a real matrix, if Av = πv, then Av = οΏ½οΏ½v. Therefore, the eigen-vectors also occur as a complex conjugate pair. The eigenvector v associatedwith eigenvalue π satisfies βππ£1 + π£2 = 0, and normalizing with π£1 = 1, we have
v =
(1π
).
We have therefore determined two independent complex solutions to the ode,that is,
vπππ‘ and vποΏ½οΏ½π‘,
and we can form a linear combination of these two complex solutions to constructtwo independent real solutions. Namely, if the complex functions π§(π‘) and π§(π‘)are written as
π§(π‘) = Re{π§(π‘)}+ πIm{π§(π‘)}, π§(π‘) = Re{π§(π‘)} β πIm{π§(π‘)},
then two real functions can be constructed from the following linear combina-tions of π§ and π§:
π§ + π§
2= Re{π§(π‘)} and
π§ β π§
2π= Im{π§(π‘)}.
Thus the two real vector functions that can be constructed from our two complexvector functions are
Re{vπππ‘} = Re
{(1π
)π(β
12+π)π‘
}= πβ
12 π‘Re
{(1π
)(cos π‘+ π sin π‘)
}= πβ
12 π‘
(cos π‘
β sin π‘
);
76 CHAPTER 6. SYSTEMS OF EQUATIONS
β2 β1.5 β1 β0.5 0 0.5 1 1.5 2β2
β1.5
β1
β0.5
0
0.5
1
1.5
2
x1
x 2
phase space diagram
Figure 6.3: Phase space diagram for example with complex conjugate eigenval-ues.
and
Im{vπππ‘} = πβ12 π‘Im
{(1π
)(cos π‘+ π sin π‘)
}= πβ
12 π‘
(sin π‘cos π‘
).
Taking a linear superposition of these two real solutions yields the general so-lution to the ode, given by
x = πβ12 π‘
(π΄
(cos π‘
β sin π‘
)+π΅
(sin π‘cos π‘
)).
The corresponding phase space diagram is shown in Fig. 6.3. We say theorigin is a spiral point. If the real part of the complex eigenvalue is negative,as is the case here, then solutions spiral into the origin. If the real part of theeigenvalue is positive, then solutions spiral out of the origin.
The direction of the spiralβhere, it is clockwiseβcan be determined usinga concept from physics. If a particle of unit mass moves along a phase spacetrajectory, then the angular momentum of the particle about the origin is equalto the cross product of the position and velocity vectors: L = x Γ x. Withboth the position and velocity vectors lying in the two-dimensional phase spaceplane, the angular momentum vector is perpendicular to this plane. With
x = (π₯1, π₯2, 0), x = (οΏ½οΏ½1, οΏ½οΏ½2, 0),
thenL = (0, 0, πΏ), with πΏ = π₯1οΏ½οΏ½2 β π₯2οΏ½οΏ½1.
By the right-hand-rule, a clockwise rotation corresponds to πΏ < 0, and a coun-terclockwise rotation to πΏ > 0.
6.2. COUPLED FIRST-ORDER EQUATIONS 77
The computation of πΏ in our present example proceeds from the differentialequations as follows:
π₯1οΏ½οΏ½2 β π₯2οΏ½οΏ½1 = π₯1(βπ₯1 β1
2π₯2)β π₯2(β
1
2π₯1 + π₯2)
= β(π₯21 + π₯2
2)
< 0.
And since πΏ < 0, the spiral rotation is clockwise, as shown in Fig. 6.3.
6.2.3 Repeated eigenvalues with one eigenvector
Example: Find the general solution of οΏ½οΏ½1 = π₯1 β π₯2, οΏ½οΏ½2 = π₯1 + 3π₯2.
view tutorial
The equations in matrix form are
π
ππ‘
(π₯1
π₯2
)=
(1 β11 3
)(π₯1
π₯2
). (6.9)
The ansatz x = vπππ‘ leads to the characteristic equation
0 = det (Aβ πI)
= π2 β 4π+ 4
= (πβ 2)2.
Therefore, π = 2 is a repeated eigenvalue. The associated eigenvector is foundfrom βπ£1 β π£2 = 0, or π£2 = βπ£1; and normalizing with π£1 = 1, we have
π = 2, v =
(1
β1
).
We have thus found a single solution to the ode, given by
x1(π‘) = π1
(1
β1
)π2π‘,
and we need to find the missing second solution to be able to satisfy the initialconditions. An ansatz of π‘ times the first solution is tempting, but will fail. Here,we will cheat and find the missing second solution by solving the equivalentsecond-order, homogeneous, constant-coefficient differential equation.
We already know that this second-order differential equation for π₯1(π‘) has acharacteristic equation with a degenerate eigenvalue given by π = 2. Therefore,the general solution for π₯1 is given by
π₯1(π‘) = (π1 + π‘π2)π2π‘.
To determine π₯2, we first compute
οΏ½οΏ½1 =(2π1 + (1 + 2π‘)π2
)π2π‘,
78 CHAPTER 6. SYSTEMS OF EQUATIONS
β2 β1.5 β1 β0.5 0 0.5 1 1.5 2β2
β1.5
β1
β0.5
0
0.5
1
1.5
2
x1
x 2
phase space diagram
Figure 6.4: Phase space diagram for example with only one eigenvector.
so that from the first first-order differential equation, we have
π₯2 = π₯1 β οΏ½οΏ½1
= (π1 + π‘π2)π2π‘ β
(2π1 + (1 + 2π‘)π2
)π2π‘
= βπ1π2π‘ + π2(β1β π‘)π2π‘.
Combining our results for π₯1 and π₯2, we have therefore found(π₯1
π₯2
)= π1
(1
β1
)π2π‘ + π2
[(0
β1
)+
(1
β1
)π‘
]π2π‘.
Our missing linearly independent solution is thus determined to be
x(π‘) = π2
[(0
β1
)+
(1
β1
)π‘
]π2π‘. (6.10)
The second term of (6.10) is just π‘ times the first solution; however, this isnot sufficient. Indeed, the correct ansatz to find the second solution directly isgiven by
x = (w + π‘v) πππ‘, (6.11)
where π and v is the eigenvalue and eigenvector of the first solution, and wis an unknown vector to be determined. To illustrate this direct method, wesubstitute (6.11) into x = Ax, assuming Av = πv . Canceling the exponential,we obtain
v + π (w + π‘v) = Aw + ππ‘v.
Further canceling the common term ππ‘v and rewriting yields
(Aβ πI)w = v. (6.12)
6.3. NORMAL MODES 79
If A has only a single linearly independent eigenvector v, then (6.12) can besolved for w (otherwise, it cannot). Using A, π and v of our present example,(6.12) is the system of equations given by(
β1 β11 1
)(π€1
π€2
)=
(1
β1
).
The first and second equation are the same, so that π€2 = β(π€1+1). Therefore,
w =
(π€1
β(π€1 + 1)
)= π€1
(1
β1
)+
(0
β1
).
Notice that the first term repeats the first found solution, i.e., a constant timesthe eigenvector, and the second term is new. We therefore take π€1 = 0 andobtain
w =
(0
β1
),
as before.The phase space diagram for this ode is shown in Fig. 6.4. The dark line is
the single eigenvector v of the matrixA. When there is only a single eigenvector,the origin is called an improper node.
There is a definite counterclockwise rotation to the phase space trajectories,and this can be confirmed from the calculation
πΏ = π₯1οΏ½οΏ½2 β π₯2οΏ½οΏ½1
= π₯1(π₯1 + 3π₯2)β π₯2(π₯1 β π₯2)
= π₯21 + 2π₯1π₯2 + π₯2
2
= (π₯1 + π₯2)2
> 0.
6.3 Normal modes
view tutorial, Part 1 view tutorial, Part 2We now consider an application of the eigenvector analysis to the coupled mass-spring system shown in Fig. 6.5. The position variables π₯1 and π₯2 are measuredfrom the equilibrium positions of the masses. Hookeβs law states that the springforce is linearly proportional to the extension length of the spring, measuredfrom equilibrium. By considering the extension of the spring and the sign of theforce, we write Newtonβs law πΉ = ππ separately for each mass:
ποΏ½οΏ½1 = βππ₯1 βπΎ(π₯1 β π₯2),
ποΏ½οΏ½2 = βππ₯2 βπΎ(π₯2 β π₯1).
Further rewriting by collecting terms proportional to π₯1 and π₯2 yields
ποΏ½οΏ½1 = β(π +πΎ)π₯1 +πΎπ₯2,
ποΏ½οΏ½2 = πΎπ₯1 β (π +πΎ)π₯2.
80 CHAPTER 6. SYSTEMS OF EQUATIONS
Figure 6.5: Coupled harmonic oscillators.
The equations for the coupled mass-spring system form a system of two second-order linear homogeneous odes. In matrix form, πx = Ax, or explicitly,
ππ2
ππ‘2
(π₯1
π₯2
)=
(β(π +πΎ) πΎ
πΎ β(π +πΎ)
)(π₯1
π₯2
). (6.13)
In analogy to a system of first-order equations, we try the ansatz x = vπππ‘, andupon substitution into (6.13) we obtain the eigenvalue problem Av = ππ2v.The values of ππ2 are determined by solving the characteristic equation
0 = det (Aβππ2I)
=
β(π +πΎ)βππ2 πΎ
πΎ β(π +πΎ)βππ2
= (ππ2 + π +πΎ)2 βπΎ2.
The solution for mπ2 isππ2 = βπ βπΎ Β±πΎ,
and the two eigenvalues are
π21 = βπ/π, π2
2 = β(π + 2πΎ)/π.
Since π21, π
22 < 0, both values of π are imaginary, and π₯1(π‘) and π₯2(π‘) oscillate
with angular frequencies π1 = |π1| and π2 = |π2|, where
π1 =βπ/π, π2 =
β(π + 2πΎ)/π.
The positions of the oscillating masses in general contain time dependencies ofthe form sinπ1π‘, cosπ1π‘, and sinπ2π‘, cosπ2π‘.
It is of further interest to determine the eigenvectors, or so-called normalmodes of oscillation, associated with the two distinct angular frequencies. Withspecific initial conditions proportional to an eigenvector, the mass will oscillatewith a single frequency. The eigenvector associated with ππ2
1 satisfies
βπΎπ£11 +πΎπ£12 = 0,
so that π£11 = π£12. The normal mode associated with the frequency π1 =βπ/π thus follows a motion where π₯1 = π₯2. Referring to Fig. 6.5, during this
motion the center spring length does not change, and the two masses oscillateas if the center spring was absent (which is why the frequency of oscillation isindependent of πΎ).
6.3. NORMAL MODES 81
Next, we determine the eigenvector associated with ππ22:
πΎπ£21 +πΎπ£22 = 0,
so that π£21 = βπ£22. The normal mode associated with the frequency π2 =β(π + 2πΎ)/π thus follows a motion where π₯1 = βπ₯2. Again referring to
Fig. 6.5, during this motion the two equal masses symmetrically push or pullagainst each side of the middle spring.
A general solution for x(π‘) can be constructed from the eigenvalues andeigenvectors. Our ansatz was x = vπππ‘, and for each of two eigenvectors v,we have a pair of complex conjugate values for π. Accordingly, we first applythe principle of superposition to obtain four real solutions, and then apply theprinciple again to obtain the general solution. With π1 =
βπ/π and π2 =β
(π + 2πΎ)/π, the general solution is given by(π₯1
π₯2
)=
(11
)(π΄ cosπ1π‘+π΅ sinπ1π‘) +
(1
β1
)(πΆ cosπ2π‘+π· sinπ2π‘) ,
where the now real constants π΄, π΅, πΆ, and π· can be determined from the fourindependent initial conditions, π₯1(0), π₯2(0), οΏ½οΏ½1(0), and οΏ½οΏ½2(0).
82 CHAPTER 6. SYSTEMS OF EQUATIONS
Chapter 7
Nonlinear differentialequations and bifurcationtheory
Reference: Strogatz, Sections 2.2, 2.4, 3.1, 3.2, 3.4, 6.3, 6.4, 8.2
We now turn our attention to nonlinear differential equations. In particular, westudy how small changes in the parameters of a system can result in qualita-tive changes in the dynamics. These qualitative changes in the dynamics arecalled bifurcations. To understand bifurcations, we first need to understand theconcepts of fixed points and stability.
7.1 Fixed points and stability
7.1.1 One dimension
view tutorialConsider the one-dimensional differential equation for π₯ = π₯(π‘) given by
οΏ½οΏ½ = π(π₯). (7.1)
We say that π₯* is a fixed point, or equilibrium point, of (7.1) if π(π₯*) = 0. Atthe fixed point, οΏ½οΏ½ = 0. The terminology fixed point is used since the solution to(7.1) with initial condition π₯(0) = π₯* is π₯(π‘) = π₯* for all time π‘.
A fixed point, however, can be stable or unstable. A fixed point is said to bestable if a small perturbation of the solution from the fixed point decays in time;it is said to be unstable if a small perturbation grows in time. We can determinestability by a linear analysis. Let π₯ = π₯* + π(π‘), where π represents a smallperturbation of the solution from the fixed point π₯*. Because π₯* is a constant,οΏ½οΏ½ = οΏ½οΏ½; and because π₯* is a fixed point, π(π₯*) = 0. Taylor series expanding aboutπ = 0, we have
οΏ½οΏ½ = π(π₯* + π)
= π(π₯*) + ππ β²(π₯*) + . . .
= ππ β²(π₯*) + . . . .
83
84 CHAPTER 7. NONLINEAR DIFFERENTIAL EQUATIONS
The omitted terms in the Taylor series expansion are proportional to π2, andcan be made negligible over a short time interval with respect to the kept term,proportional to π, by taking π(0) sufficiently small. Therefore, at least over shorttimes, the differential equation to be considered, οΏ½οΏ½ = π β²(π₯*)π, is linear and hasby now the familiar solution
π(π‘) = π(0)ππβ²(π₯*)π‘.
The perturbation of the fixed point solution π₯(π‘) = π₯* thus decays exponentiallyif π β²(π₯*) < 0, and we say the fixed point is stable. If π β²(π₯*) > 0, the perturbationgrows exponentially and we say the fixed point is unstable. If π β²(π₯*) = 0, wesay the fixed point is marginally stable, and the next higher-order term in theTaylor series expansion must be considered.
Example: Find all the fixed points of the logistic equation οΏ½οΏ½ = π₯(1βπ₯)and determine their stability.
There are two fixed points at which οΏ½οΏ½ = 0, given by π₯* = 0 and π₯* = 1. Stabilityof these equilibrium points may be determined by considering the derivative ofπ(π₯) = π₯(1 β π₯). We have π β²(π₯) = 1 β 2π₯. Therefore, π β²(0) = 1 > 0 so thatπ₯* = 0 is an unstable fixed point, and π β²(1) = β1 < 0 so that π₯* = 1 is a stablefixed point. Indeed, we have previously found that all solutions approach thestable fixed point asymptotically.
7.1.2 Two dimensions
view tutorial
The idea of fixed points and stability can be extended to higher-order systemsof odes. Here, we consider a two-dimensional system and will need to make useof the two-dimensional Taylor series expansion of a function πΉ (π₯, π¦) about theorigin. In general, the Taylor series of πΉ (π₯, π¦) is given by
πΉ (π₯, π¦) = πΉ + π₯ππΉ
ππ₯+ π¦
ππΉ
ππ¦+
1
2
(π₯2 π
2πΉ
ππ₯2+ 2π₯π¦
π2πΉ
ππ₯ππ¦+ π¦2
π2πΉ
ππ¦2
)+ . . . ,
where the function πΉ and all of its partial derivatives on the right-hand-side areevaluated at the origin. Note that the Taylor series is constructed so that allpartial derivatives of the left-hand-side match those of the right-hand-side atthe origin.
We now consider the two-dimensional system given by
οΏ½οΏ½ = π(π₯, π¦), οΏ½οΏ½ = π(π₯, π¦). (7.2)
The point (π₯*, π¦*) is said to be a fixed point of (7.2) if π(π₯*, π¦*) = 0 andπ(π₯*, π¦*) = 0. Again, the local stability of a fixed point can be determined bya linear analysis. We let π₯(π‘) = π₯* + π(π‘) and π¦(π‘) = π¦* + πΏ(π‘), where π and πΏare small independent perturbations from the fixed point. Making use of thetwo dimensional Taylor series of π(π₯, π¦) and π(π₯, π¦) about the fixed point, or
7.1. FIXED POINTS AND STABILITY 85
equivalently about (π, πΏ) = (0, 0), we have
οΏ½οΏ½ = π(π₯* + π, π¦* + πΏ)
= π + πππ
ππ₯+ πΏ
ππ
ππ¦+ . . .
= πππ
ππ₯+ πΏ
ππ
ππ¦+ . . . .
οΏ½οΏ½ = π(π₯* + π, π¦* + πΏ)
= π + πππ
ππ₯+ πΏ
ππ
ππ¦+ . . .
= πππ
ππ₯+ πΏ
ππ
ππ¦+ . . . ,
where in the Taylor series π , π and all their partial derivatives are evaluated atthe fixed point (π₯*, π¦*). Neglecting higher-order terms in the Taylor series, wethus have a system of odes for the perturbation, given in matrix form as
π
ππ‘
(ππΏ
)=
(ππππ₯
ππππ¦
ππππ₯
ππππ¦
)(ππΏ
). (7.3)
The two-by-two matrix in (7.3) is called the Jacobian matrix at the fixed point.An eigenvalue analysis of the Jacobian matrix will typically yield two eigenvaluesπ1 and π2. These eigenvalues may be real and distinct, complex conjugate pairs,or repeated. The fixed point is stable (all perturbations decay exponentially)if both eigenvalues have negative real parts. The fixed point is unstable (someperturbations grow exponentially) if at least one of the eigenvalues has a positivereal part. Fixed points can be further classified as stable or unstable nodes,unstable saddle points, stable or unstable spiral points, or stable or unstableimproper nodes.
Example: Find all the fixed points of the nonlinear system οΏ½οΏ½ = π₯(3βπ₯β 2π¦), οΏ½οΏ½ = π¦(2β π₯β π¦), and determine their stability.
view tutorialThe fixed points are determined by solving
π(π₯, π¦) = π₯(3β π₯β 2π¦) = 0, π(π₯, π¦) = π¦(2β π₯β π¦) = 0.
There are four fixed points (π₯*, π¦*): (0, 0), (0, 2), (3, 0) and (1, 1). The Jacobianmatrix is given by(
ππππ₯
ππππ¦
ππππ₯
ππππ¦
)=
(3β 2π₯β 2π¦ β2π₯
βπ¦ 2β π₯β 2π¦
).
Stability of the fixed points may be considered in turn. With J* the Jacobianmatrix evaluated at the fixed point, we have
(π₯*, π¦*) = (0, 0) : J* =
(3 00 2
).
86 CHAPTER 7. NONLINEAR DIFFERENTIAL EQUATIONS
0 0.5 1 1.5 2 2.5 3 3.50
0.5
1
1.5
2
2.5
x
y
phase space diagram
Figure 7.1: Phase space plot for two-dimensional nonlinear system.
The eigenvalues of J* are π = 3, 2 so that the fixed point (0, 0) is an unstablenode. Next,
(π₯*, π¦*) = (0, 2) : J* =
(β1 0β2 β2
).
The eigenvalues of J* are π = β1,β2 so that the fixed point (0, 2) is a stablenode. Next,
(π₯*, π¦*) = (3, 0) : J* =
(β3 β60 β1
).
The eigenvalues of J* are π = β3,β1 so that the fixed point (3, 0) is also astable node. Finally,
(π₯*, π¦*) = (1, 1) : J* =
(β1 β2β1 β1
).
The characteristic equation of J* is given by (β1 β π)2 β 2 = 0, so that π =β1Β±
β2. Since one eigenvalue is negative and the other positive the fixed point
(1, 1) is an unstable saddle point. From our analysis of the fixed points, one canexpect that all solutions will asymptote to one of the stable fixed points (0, 2)or (3, 0), depending on the initial conditions.
It is of interest to sketch the phase space diagram for this nonlinear system.The eigenvectors associated with the unstable saddle point (1, 1) determine thedirections of the flow into and away from this fixed point. The eigenvectorassociated with the positive eigenvalue π1 = β1 +
β2 can determined from the
first equation of (J* β π1I)v1 = 0, or
ββ2π£11 β 2π£12 = 0,
so that π£12 = β(β2/2)π£11. The eigenvector associated with the negative eigen-
value π1 = β1ββ2 satisfies π£22 = (
β2/2)π£21. The eigenvectors give the slope
7.2. ONE-DIMENSIONAL BIFURCATIONS 87
of the lines with origin at the fixed point for incoming (negative eigenvalue) andoutgoing (positive eigenvalue) trajectories. The outgoing trajectories have neg-ative slope β
β2/2 and the incoming trajectories have positive slope
β2/2. A
rough sketch of the phase space diagram can be made by hand (as demonstratedin class). Here, a computer generated plot obtained from numerical solution ofthe nonlinear coupled odes is presented in Fig. 7.1. The curve starting fromthe origin and at infinity, and terminating at the unstable saddle point is calledthe separatrix. This curve separates the phase space into two regions: initialconditions for which the solution asymptotes to the fixed point (0, 2), and initialconditions for which the solution asymptotes to the fixed point (3, 0).
7.2 One-dimensional bifurcations
A bifurcation occurs in a nonlinear differential equation when a small change ina parameter results in a qualitative change in the long-time solution. Examplesof bifurcations are when fixed points are created or destroyed, or change theirstability.
We now consider four classic bifurcations of one-dimensional nonlinear differ-ential equations: saddle-node bifurcation, transcritical bifurcation, supercriticalpitchfork bifurcation, and subcritical pitchfork bifurcation. The correspondingdifferential equation will be written as
οΏ½οΏ½ = ππ(π₯),
where the subscript π represents a parameter that results in a bifurcation whenvaried across zero. The simplest differential equations that exhibit these bifur-cations are called the normal forms, and correspond to a local analysis (i.e.,Taylor series expansion) of more general differential equations around the fixedpoint, together with a possible rescaling of π₯.
7.2.1 Saddle-node bifurcation
view tutorialThe saddle-node bifurcation results in fixed points being created or destroyed.The normal form for a saddle-node bifurcation is given by
οΏ½οΏ½ = π + π₯2.
The fixed points are π₯* = Β±ββπ. Clearly, two real fixed points exist when
π < 0 and no real fixed points exist when π > 0. The stability of the fixedpoints when π < 0 are determined by the derivative of π(π₯) = π + π₯2, given byπ β²(π₯) = 2π₯. Therefore, the negative fixed point is stable and the positive fixedpoint is unstable.
Graphically, we can illustrate this bifurcation in two ways. First, in Fig. 7.2(a),we plot οΏ½οΏ½ versus π₯ for the three parameter values corresponding to π < 0, π = 0and π > 0. The values at which οΏ½οΏ½ = 0 correspond to the fixed points, andarrows are drawn indicating how the solution π₯(π‘) evolves (to the right if οΏ½οΏ½ > 0and to the left if οΏ½οΏ½ < 0). The stable fixed point is indicated by a filled circleand the unstable fixed point by an open circle. Note that when π = 0, solutionsconverge to the origin from the left, but diverge from the origin on the right.
88 CHAPTER 7. NONLINEAR DIFFERENTIAL EQUATIONS
β β β
r<0
β β
r=0 r>0
dx/dt
x
(a)
(b) x*
r
Figure 7.2: Saddlenode bifurcation. (a) οΏ½οΏ½ versus π₯; (b) bifurcation diagram.
Second, in Fig. 7.2(b), we plot a bifurcation diagram illustrating the fixed pointπ₯* versus the bifurcation parameter π. The stable fixed point is denoted by asolid line and the unstable fixed point by a dashed line. Note that the two fixedpoints collide and annihilate at π = 0, and there are no fixed points for π > 0.
7.2.2 Transcritical bifurcation
view tutorialA transcritical bifurcation occurs when there is an exchange of stabilities be-tween two fixed points. The normal form for a transcritical bifurcation is givenby
οΏ½οΏ½ = ππ₯β π₯2.
The fixed points are π₯* = 0 and π₯* = π. The derivative of the right-hand-side isπ β²(π₯) = π β 2π₯, so that π β²(0) = π and π β²(π) = βπ. Therefore, for π < 0, π₯* = 0is stable and π₯* = π is unstable, while for π > 0, π₯* = π is stable and π₯* = 0is unstable. The two fixed points thus exchange stability as π passes throughzero. The transcritical bifurcation is illustrated in Fig. 7.3.
7.2.3 Supercritical pitchfork bifurcation
view tutorialThe pitchfork bifurcations occur in physical models where fixed points appearand disappear in pairs due to some intrinsic symmetry of the problem. Pitchforkbifurcations can come in one of two types. In the supercritical bifurcation, apair of stable fixed points are created at the bifurcation (or critical) point and
7.2. ONE-DIMENSIONAL BIFURCATIONS 89
β β β
r<0
dx/dt
x
(a)
β β
r=0
ββ β
r>0
x*
r
(b)
Figure 7.3: Transcritical bifurcation. (a) οΏ½οΏ½ versus π₯; (b) bifurcation diagram.
exist after (super) the bifurcation. In the subcritical bifurcation, a pair ofunstable fixed points are created at the bifurcation point and exist before (sub)the bifurcation.
The normal form for the supercritical pitchfork bifurcation is given by
οΏ½οΏ½ = ππ₯β π₯3.
Note that the linear term results in exponential growth when π > 0 and thenonlinear term stabilizes this growth. The fixed points are π₯* = 0 and π₯* =Β±βπ, the latter fixed points existing only when π > 0. The derivative of π is
π β²(π₯) = π β 3π₯2 so that π β²(0) = π and π β²(Β±βπ) = β2π. Therefore, the fixed
point π₯* = 0 is stable for π < 0 and unstable for π > 0 while the fixed pointsπ₯ = Β±
βπ exist and are stable for π > 0. Notice that the fixed point π₯* = 0
becomes unstable as π crosses zero and two new stable fixed points π₯* = Β±βπ
are born. The supercritical pitchfork bifurcation is illustrated in Fig. 7.4.
7.2.4 Subcritical pitchfork bifurcation
view tutorial
In the subcritical case, the cubic term is destabilizing. The normal form (toorder π₯3) is
οΏ½οΏ½ = ππ₯+ π₯3.
The fixed points are π₯* = 0 and π₯* = Β±ββπ, the latter fixed points existing
only when π β€ 0. The derivative of the right-hand-side is π β²(π₯) = π + 3π₯2 sothat π β²(0) = π and π β²(Β±
ββπ) = β2π. Therefore, the fixed point π₯* = 0 is stable
90 CHAPTER 7. NONLINEAR DIFFERENTIAL EQUATIONS
β β
r<0
dx/dt
x
(a)
β β
r=0
ββ β β
r>0
x*
r
(b)
Figure 7.4: Supercritical pitchfork bifurcation. (a) οΏ½οΏ½ versus π₯; (b) bifurcationdiagram.
for π < 0 and unstable for π > 0 while the fixed points π₯ = Β±ββπ exist and are
unstable for π < 0. There are no stable fixed points when π > 0.
The absence of stable fixed points for π > 0 indicates that the neglect ofterms of higher-order in π₯ than π₯3 in the normal form may be unwarranted.Keeping to the intrinsic symmetry of the equations (only odd powers of π₯) wecan add a stabilizing nonlinear term proportional to π₯5. The extended normalform (to order π₯5) is
οΏ½οΏ½ = ππ₯+ π₯3 β π₯5,
and is somewhat more difficult to analyze. The fixed points are solutions of
π₯(π + π₯2 β π₯4) = 0.
The fixed point π₯* = 0 exists for all π, and four additional fixed points can befound from the solutions of the quadratic equation in π₯2:
π₯* = Β±β
1
2(1Β±
β1 + 4π).
These fixed points exist only if π₯* is real. Clearly, for the inner square-root tobe real, π β₯ β1/4. Also observe that 1 β
β1 + 4π becomes negative for π > 0.
We thus have three intervals in π to consider, and these regions and their fixed
7.2. ONE-DIMENSIONAL BIFURCATIONS 91
x*
r
Figure 7.5: Subcritical pitchfork bifurcation.
points are
π < β1
4: π₯* = 0 (one fixed point);
β1
4< π < 0 : π₯* = 0, π₯* = Β±
β1
2(1Β±
β1 + 4π) (five fixed points);
π > 0 : π₯* = 0, π₯* = Β±β
1
2(1 +
β1 + 4π) (three fixed points).
Stability is determined from π β²(π₯) = π+3π₯2 β 5π₯4. Now, π β²(0) = π so π₯* = 0 isstable for π < 0 and unstable for π > 0. The calculation for the other four rootscan be simplified by noting that π₯* satisfies π + π₯2
* β π₯4* = 0, or π₯4
* = π + π₯2*.
Therefore,
π β²(π₯*) = π + 3π₯2* β 5π₯4
*
= π + 3π₯2* β 5(π + π₯2
*)
= β4π β 2π₯2*
= β2(2π + π₯2*).
With π₯2* = 1
2 (1Β±β1 + 4π), we have
π β²(π₯*) = β2
(2π +
1
2(1Β±
β1 + 4π)
)= β
((1 + 4π)Β±
β1 + 4π
)= β
β1 + 4π
(β1 + 4π Β± 1
).
Clearly, the plus root is always stable since π β²(π₯*) < 0. The minus root existsonly for β 1
4 < π < 0 and is unstable since π β²(π₯*) > 0. We summarize the
92 CHAPTER 7. NONLINEAR DIFFERENTIAL EQUATIONS
stability of the various fixed points:
π < β1
4: π₯* = 0 (stable);
β1
4< π < 0 : π₯* = 0, (stable)
π₯* = Β±β
1
2(1 +
β1 + 4π) (stable);
π₯* = Β±β
1
2(1β
β1 + 4π) (unstable);
π > 0 : π₯* = 0 (unstable)
π₯* = Β±β
1
2(1 +
β1 + 4π) (stable).
The bifurcation diagram is shown in Fig. 7.5, and consists of a subcriticalpitchfork bifurcation at π = 0 and two saddle-node bifurcations at π = β1/4. Wecan imagine what happens to π₯ as π increases from negative values, supposingthere is some small noise in the system so that π₯ = π₯(π‘) will diverge fromunstable fixed points. For π < β1/4, the equilibrium value of π₯ is π₯* = 0. Asπ increases into the range β1/4 < π < 0, π₯ will remain at π₯* = 0. However, acatastrophe occurs as soon as π > 0. The π₯* = 0 fixed point becomes unstableand the solution will jump up (or down) to the only remaining stable fixed point.Such behavior is called a jump bifurcation. A similar catastrophe can happenas π decreases from positive values. In this case, the jump occurs as soon asπ < β1/4.
Since the stable equilibrium value of π₯ depends on whether we are increasingor decreasing π, we say that the system exhibits hysteresis. The existence ofa subcritical pitchfork bifurcation can be very dangerous in engineering appli-cations since a small change in a problemβs parameters can result in a largechange in the equilibrium state. Physically, this can correspond to a collapse ofa structure, or the failure of a component.
7.2.5 Application: a mathematical model of a fishery
view tutorialWe illustrate the utility of bifurcation theory by analyzing a simple model of afishery. We utilize the logistic equation (see S2.4.5) to model a fish populationin the absence of fishing. To model fishing, we assume that the government hasestablished fishing quotas so that at most a total of πΆ fish per year may becaught. We assume that when the fish population is at the carrying capacityof the environment, fisherman can catch nearly their full quota. When the fishpopulation drops to lower values, fish may be harder to find and the catch ratemay fall below πΆ, eventually going to zero as the fish population diminishes.Combining the logistic equation together with a simple model of fishing, wepropose the mathematical model
ππ
ππ‘= ππ
(1β π
πΎ
)β πΆπ
π΄+π, (7.4)
where π is the fish population size, π‘ is time, π is the maximum potential growthrate of the fish population, πΎ is the carrying capacity of the environment, πΆ is
7.2. ONE-DIMENSIONAL BIFURCATIONS 93
x*
c
1
0Ξ± (1+Ξ±)2/4
Figure 7.6: Fishery bifurcation diagram.
the maximum rate at which fish can be caught, and π΄ is a constant satisfyingπ΄ < πΎ that is used to model the idea that fish become harder to catch whenscarce.
We nondimensionalize (7.4) using π₯ = π/πΎ, π = ππ‘, π = πΆ/ππΎ, πΌ = π΄/πΎ:
ππ₯
ππ= π₯(1β π₯)β ππ₯
πΌ+ π₯. (7.5)
Note that 0 β€ π₯ β€ 1, π > 0 and 0 < πΌ < 1. We wish to qualitatively describethe equilibrium solutions of (7.5) and the bifurcations that may occur as thenondimensional catch rate π increases from zero. Practically, a governmentwould like to issue each year as large a catch quota as possible without adverselyaffecting the number of fish that may be caught in subsequent years.
The fixed points of (7.5) are π₯* = 0, valid for all π, and the solutions toπ₯2 β (1β πΌ)π₯+ (πβ πΌ) = 0, or
π₯* =1
2
[(1β πΌ)Β±
β(1 + πΌ)2 β 4π
]. (7.6)
The fixed points given by (7.6) are real only if π < 14 (1 +πΌ)2. Furthermore, the
minus root is greater than zero only if π > πΌ. We therefore need to considerthree intervals over which the following fixed points exist:
0 β€ π β€ πΌ : π₯* = 0, π₯* =1
2
[(1β πΌ) +
β(1 + πΌ)2 β 4π
];
πΌ < π <1
4(1 + πΌ)2 : π₯* = 0, π₯* =
1
2
[(1β πΌ)Β±
β(1 + πΌ)2 β 4π
];
π >1
4(1 + πΌ)2 : π₯* = 0.
94 CHAPTER 7. NONLINEAR DIFFERENTIAL EQUATIONS
The stability of the fixed points can be determined with rigor analytically orgraphically. Here, we simply apply biological intuition together with knowledgeof the types of one dimensional bifurcations. An intuitive argument is madesimpler if we consider π decreasing from large values. When π is large, thatis π > 1
4 (1 + πΌ)2, too many fish are being caught and our intuition suggeststhat the fish population goes extinct. Therefore, in this interval, the singlefixed point π₯* = 0 must be stable. As π decreases, a bifurcation occurs atπ = 1
4 (1 + πΌ)2 introducing two additional fixed points at π₯* = (1 β πΌ)/2. Thetype of one dimensional bifurcation in which two fixed points are created as asquare root becomes real is a saddlenode bifurcation, and one of the fixed pointswill be stable and the other unstable. Following these fixed points as π β 0,we observe that the plus root goes to one, which is the appropriate stable fixedpoint when there is no fishing. We therefore conclude that the plus root is stableand the minus root is unstable. As π decreases further from this bifurcation,the minus root collides with the fixed point π₯* = 0 at π = πΌ. This appears tobe a transcritical bifurcation and assuming an exchange of stability occurs, wemust have the fixed point π₯* = 0 becoming unstable for π < πΌ. The resultingbifurcation diagram is shown in Fig. 7.6.
The purpose of simple mathematical models applied to complex ecologicalproblems is to offer some insight. Here, we have learned that overfishing (inthe model π > 1
4 (1 + πΌ)2) during one year can potentially result in a suddencollapse of the fish catch in subsequent years, so that governments need to beparticularly cautious when contemplating increases in fishing quotas.
7.3 Two-dimensional bifurcations
All the one-dimensional bifurcations can also occur in two-dimensions alongone of the directions. In addition, a new type of bifurcation can also occurin two-dimensions. Suppose there is some control parameter π. Furthermore,suppose that for π < 0, a two-dimensional system approaches a fixed point byexponentially-damped oscillations. We know that the Jacobian matrix at thefixed point with π < 0 will have complex conjugate eigenvalues with negative realparts. Now suppose that when π > 0 the real parts of the eigenvalues becomepositive so that the fixed point becomes unstable. This change in stabilityof the fixed point is called a Hopf bifurcation. The Hopf bifurcation comesin two types: supercritical Hopf bifurcation and subcritical Hopf bifurcation.For the supercritical Hopf bifurcation, as π increases slightly above zero, theresulting oscillation around the now unstable fixed point is quickly stabilized atsmall amplitude. This stable orbit is called a limit cycle. For the subcriticalHopf bifurcation, as π increases slightly above zero, the limit cycle immediatelyjumps to large amplitude.
7.3.1 Supercritical Hopf bifurcation
A simple example of a supercritical Hopf bifurcation can be given in polarcoordinates:
οΏ½οΏ½ = ππ β π3,
π = π + ππ2,
7.3. TWO-DIMENSIONAL BIFURCATIONS 95
where π₯ = π cos π and π¦ = π sin π. The parameter π controls the stability of thefixed point at the origin, the parameter π is the frequency of oscillation nearthe origin, and the parameter π determines the dependence of the oscillationfrequency at larger amplitude oscillations. Although we include π for generality,our qualitative analysis of these equations will be independent of π.
The equation for the radius is of the form of the supercritical pitchforkbifurcation. The fixed points are π* = 0 and π* =
βπ (note that π > 0), and
the former fixed point is stable for π < 0 and the latter is stable for π > 0. Thetransition of the eigenvalues of the Jacobian from negative real part to positivereal part can be seen if we transform these equations to cartesian coordinates.We have using π2 = π₯2 + π¦2,
οΏ½οΏ½ = οΏ½οΏ½ cos π β ππ sin π
= (ππ β π3) cos π β (π + ππ2)π sin π
= ππ₯β (π₯2 + π¦2)π₯β ππ¦ β π(π₯2 + π¦2)π¦
= ππ₯β ππ¦ β (π₯2 + π¦2)(π₯+ ππ¦);
οΏ½οΏ½ = οΏ½οΏ½ sin π + ππ cos π
= (ππ β π3) sin π + (π + ππ2)π cos π
= ππ¦ β (π₯2 + π¦2)π¦ + ππ₯+ π(π₯2 + π¦2)π₯
= ππ₯+ ππ¦ β (π₯2 + π¦2)(π¦ β ππ₯).
The stability of the origin is determined by the Jacobian matrix evaluated atthe origin. The nonlinear terms in the equation vanish and the Jacobian matrixat the origin is given by
π½ =
(π βππ π
).
The eigenvalues are the solutions of (π β π)2 + π2 = 0, or π = π Β± ππ. Asπ increases from negative to positive values, exponentially damped oscillationschange into exponentially growing oscillations. The nonlinear terms in the equa-tions stabilize the growing oscillations into a limit cycle.
7.3.2 Subcritical Hopf bifurcation
The analogous example of a subcritical Hopf bifurcation is given by
οΏ½οΏ½ = ππ + π3 β π5,
π = π + ππ2.
Here, the equation for the radius is of the form of the subcritical pitchforkbifurcation. As π increases from negative to positive values, the origin becomesunstable and exponentially growing oscillations increase until the radius reachesa stable fixed point far away from the origin. In practice, it may be difficultto tell analytically if a Hopf bifurcation is supercritical or subcritical from theequations of motion. Computational solution, however, can quickly distinguishbetween the two types.
96 CHAPTER 7. NONLINEAR DIFFERENTIAL EQUATIONS
Chapter 8
Partial differentialequations
Reference: Boyce and DiPrima, Chapter 10
Differential equations containing partial derivatives with two or more inde-pendent variables are called partial differential equations (pdes). These equa-tions are of fundamental scientific interest but are substantially more difficultto solve, both analytically and computationally, than odes. In this chapter, wewill derive two fundamental pdes and show how to solve them.
8.1 Derivation of the diffusion equation
view lecture
To derive the diffusion equation in one spacial dimension, we imagine a stillliquid in a long pipe of constant cross sectional area. A small quantity of dyeis placed in a cross section of the pipe and allowed to diffuse up and down thepipe. The dye diffuses from regions of higher concentration to regions of lowerconcentration.
We define π’(π₯, π‘) to be the concentration of the dye at position π₯ along thepipe, and we wish to find the pde satisfied by π’. It is useful to keep track ofthe units of the various quantities involved in the derivation and we introducethe bracket notation [π] to mean the units of π. Relevant dimensional unitsused in the derivation of the diffusion equation are mass π, length π, and timeπ‘. Assuming that the dye concentration is uniform in every cross section of thepipe, the dimensions of concentration used here are [π’] = π/π.
The mass of dye in the infinitesimal pipe volume located between positionπ₯1 and position π₯2 at time π‘, with π₯1 < π₯ < π₯2, is given to order Ξπ₯ = π₯2 β π₯1
by
π = π’(π₯, π‘)Ξπ₯.
The mass of dye in this infinitesimal pipe volume changes by diffusion into andout of the cross sectional ends situated at position π₯1 and π₯2 (Figure 8.1).We assume the rate of diffusion is proportional to the concentration gradient,a relationship known as Fickβs law of diffusion. Fickβs law of diffusion assumesthe mass flux π½ , with units [π½ ] = π/π‘ across a cross section of the pipe is given
97
98 CHAPTER 8. PARTIAL DIFFERENTIAL EQUATIONS
J (x2)J (x1)
X1 X2
Figure 8.1: Derivation of the diffusion equation.
byπ½ = βπ·π’π₯, (8.1)
where the diffusion constant π· > 0 has units [π·] = π2/π‘, and we have usedthe notation π’π₯ = ππ’/ππ₯. The mass flux is opposite in sign to the gradient ofconcentration. The time rate of change in the mass of dye between π₯1 and π₯2
is given by the difference between the mass flux into and the mass flux out ofthe infinitesimal cross sectional volume. When π’π₯ < 0, π½ > 0 and the massflows into the volume at position π₯1 and out of the volume at position π₯2. Onthe other hand, when π’π₯ > 0, π½ < 0 and the mass flows out of the volume atposition π₯1 and into the volume at position π₯2. In both cases, the time rate ofchange of the dye mass is given by
ππ
ππ‘= π½(π₯1, π‘)β π½(π₯2, π‘),
or rewriting in terms of π’(π₯, π‘):
π’π‘(π₯, π‘)Ξπ₯ = π· (π’π₯(π₯2, π‘)β π’π₯(π₯1, π‘)) .
Dividing by Ξπ₯ and taking the limit Ξπ₯ β 0 results in the diffusion equation:
π’π‘ = π·π’π₯π₯.
We note that the diffusion equation is identical to the heat conduction equation,where π’ is temperature, and the constant π· (commonly written as π ) is thethermal conductivity.
8.2 Derivation of the wave equation
view lectureTo derive the wave equation in one spacial dimension, we imagine an elasticstring that undergoes small amplitude transverse vibrations. We define π’(π₯, π‘)to be the vertical displacement of the string from the π₯-axis at position π₯ andtime π‘, and we wish to find the pde satisfied by π’. We define π to be the
8.2. DERIVATION OF THE WAVE EQUATION 99
Figure 8.2: Derivation of the wave equation.
constant mass density of the string, π the tension of the string, and π the anglebetween the string and the horizonal line. We consider an infinitesimal stringelement located between π₯1 and π₯2, with Ξπ₯ = π₯2 β π₯1, as shown in Fig. 8.2.The governing equations are Newtonβs law of motion for the horizontal andvertical acceleration of our infinitesimal string element, and we assume that thestring element only accelerates vertically. Therefore, the horizontal forces mustbalance and we have
π2 cos π2 = π1 cos π1.
The vertical forces result in a vertical acceleration, and with π’π‘π‘ the verticalacceleration of the string element and π
βΞπ₯2 +Ξπ’2 = πΞπ₯
β1 + π’2
π₯ its mass,where we have used π’π₯ = Ξπ’/Ξπ₯, exact as Ξπ₯ β 0, we have
πΞπ₯β1 + π’2
π₯π’π‘π‘ = π2 sin π2 β π1 sin π1.
We now make the assumption of small vibrations, that is Ξπ’ βͺ Ξπ₯, or equiv-alently π’π₯ βͺ 1. Note that [π’] = π so that π’π₯ is dimensionless. With thisapproximation, to leading-order in π’π₯ we have
cos π2 = cos π1 = 1,
sin π2 = π’π₯(π₯2, π‘), sin π1 = π’π₯(π₯1, π‘),
and β1 + π’2
π₯ = 1.
Therefore, to leading order π1 = π2 = π , (i.e., the tension in the string isapproximately constant), and
πΞπ₯π’π‘π‘ = π (π’π₯(π₯2, π‘)β π’π₯(π₯1, π‘)) .
100 CHAPTER 8. PARTIAL DIFFERENTIAL EQUATIONS
Dividing by Ξπ₯ and taking the limit Ξπ₯ β 0 results in the wave equation
π’π‘π‘ = π2π’π₯π₯,
where π2 = π/π. Since [π ] = ππ/π‘2 and [π] = π/π, we have [π2] = π2/π‘2 so thatπ has units of velocity.
8.3 Fourier series
view tutorial
Our solution of the diffusion and wave equations will require use of a Fourierseries. A periodic function π(π₯) with period 2πΏ, can be represented as a Fourierseries in the form
π(π₯) =π02
+
ββπ=1
(ππ cos
πππ₯
πΏ+ ππ sin
πππ₯
πΏ
). (8.2)
Determination of the coefficients π0, π1, π2, . . . and π1, π2, π3, . . . makes use oforthogonality relations for sine and cosine. We first define the widely usedKronecker delta πΏππ as
πΏππ =
{1 if π = π;0 otherwise.
The orthogonality relations for π and π positive integers are then given withcompact notation as the integration formulasβ« πΏ
βπΏ
cos(πππ₯
πΏ
)cos(πππ₯
πΏ
)ππ₯ = πΏπΏππ, (8.3)β« πΏ
βπΏ
sin(πππ₯
πΏ
)sin(πππ₯
πΏ
)ππ₯ = πΏπΏππ, (8.4)β« πΏ
βπΏ
cos(πππ₯
πΏ
)sin(πππ₯
πΏ
)ππ₯ = 0. (8.5)
We illustrate the integration technique used to obtain these results. To derive(8.4), we assume that π and π are positive integers with π = π, and we makeuse of the change of variables π = ππ₯/πΏ:β« πΏ
βπΏ
sin(πππ₯
πΏ
)sin(πππ₯
πΏ
)ππ₯
=πΏ
π
β« π
βπ
sin (ππ) sin (ππ)ππ
=πΏ
2π
β« π
βπ
[cos((πβ π)π
)β cos
((π+ π)π
)]ππ
=πΏ
2π
[1
πβ πsin((πβ π)π
)β 1
π+ πsin((π+ π)π
)]πβπ
= 0.
8.3. FOURIER SERIES 101
For π = π, however,β« πΏ
βπΏ
sin2(πππ₯
πΏ
)ππ₯ =
πΏ
π
β« π
βπ
sin2 (ππ)ππ
=πΏ
2π
β« π
βπ
(1β cos (2ππ)
)ππ
=πΏ
2π
[π β 1
2πsin 2ππ
]πβπ
= πΏ.
Integration formulas given by (8.3) and (8.5) can be similarly derived.
To determine the coefficient ππ, we multiply both sides of (8.2) by cos (πππ₯/πΏ)with π a nonnegative integer, and change the dummy summation variable fromπ to π. Integrating over π₯ from βπΏ to πΏ and assuming that the integration canbe done term by term in the infinite sum, we obtain
β« πΏ
βπΏ
π(π₯) cosπππ₯
πΏππ₯ =
π02
β« πΏ
βπΏ
cosπππ₯
πΏππ₯
+
ββπ=1
{ππ
β« πΏ
βπΏ
cosπππ₯
πΏcos
πππ₯
πΏππ₯+ ππ
β« πΏ
βπΏ
cosπππ₯
πΏsin
πππ₯
πΏππ₯
}.
If π = 0, then the second and third integrals on the right-hand-side are zeroand the first integral is 2πΏ so that the right-hand-side becomes πΏπ0. If π isa positive integer, then the first and third integrals on the right-hand-side arezero, and the second integral is πΏπΏππ. For this case, we haveβ« πΏ
βπΏ
π(π₯) cosπππ₯
πΏππ₯ =
ββπ=1
πΏπππΏππ
= πΏππ,
where all the terms in the summation except π = π are zero by virtue of theKronecker delta. We therefore obtain for π = 0, 1, 2, . . .
ππ =1
πΏ
β« πΏ
βπΏ
π(π₯) cosπππ₯
πΏππ₯. (8.6)
To determine the coefficients π1, π2, π3, . . . , we multiply both sides of (8.2) bysin (πππ₯/πΏ), with π a positive integer, and again change the dummy summationvariable from π to π. Integrating, we obtain
β« πΏ
βπΏ
π(π₯) sinπππ₯
πΏππ₯ =
π02
β« πΏ
βπΏ
sinπππ₯
πΏππ₯
+
ββπ=1
{ππ
β« πΏ
βπΏ
sinπππ₯
πΏcos
πππ₯
πΏππ₯+ ππ
β« πΏ
βπΏ
sinπππ₯
πΏsin
πππ₯
πΏππ₯
}.
102 CHAPTER 8. PARTIAL DIFFERENTIAL EQUATIONS
Here, the first and second integrals on the right-hand-side are zero, and thethird integral is πΏπΏππ so thatβ« πΏ
βπΏ
π(π₯) sinπππ₯
πΏππ₯ =
ββπ=1
πΏπππΏππ
= πΏππ.
Hence, for π = 1, 2, 3, . . . ,
ππ =1
πΏ
β« πΏ
βπΏ
π(π₯) sinπππ₯
πΏππ₯. (8.7)
Our results for the Fourier series of a function π(π₯) with period 2πΏ are thusgiven by (8.2), (8.6) and (8.7).
8.4 Fourier cosine and sine series
view tutorialThe Fourier series simplifies if π(π₯) is an even function such that π(βπ₯) = π(π₯),or an odd function such that π(βπ₯) = βπ(π₯). Use will be made of the followingfacts. The function cos (πππ₯/πΏ) is an even function and sin (πππ₯/πΏ) is an oddfunction. The product of two even functions is an even function. The productof two odd functions is an even function. The product of an even and an oddfunction is an odd function. And if π(π₯) is an even function, thenβ« πΏ
βπΏ
π(π₯)ππ₯ = 2
β« πΏ
0
π(π₯)ππ₯;
and if π(π₯) is an odd function, thenβ« πΏ
βπΏ
π(π₯)ππ₯ = 0.
We examine in turn the Fourier series for an even or an odd function. First,if π(π₯) is even, then from (8.6) and (8.7) and our facts about even and oddfunctions,
ππ =2
πΏ
β« πΏ
0
π(π₯) cosπππ₯
πΏππ₯,
ππ = 0.
(8.8)
The Fourier series for an even function with period 2πΏ is thus given by theFourier cosine series
π(π₯) =π02
+
ββπ=1
ππ cosπππ₯
πΏ, π(π₯) even. (8.9)
Second, if π(π₯) is odd, then
ππ = 0,
ππ =2
πΏ
β« πΏ
0
π(π₯) sinπππ₯
πΏππ₯;
(8.10)
8.4. FOURIER COSINE AND SINE SERIES 103
β2*pi βpi 0 pi 2*piβ1
0
1
Figure 8.3: The even triangle function.
and the Fourier series for an odd function with period 2πΏ is given by the Fouriersine series
π(π₯) =
ββπ=1
ππ sinπππ₯
πΏ, π(π₯) odd. (8.11)
Examples of Fourier series computed numerically can be obtained using theJava applet found at http://www.falstad.com/fourier. Here, we demonstrate ananalytical example.
Example: Determine the Fourier cosine series of the even trianglefunction represented by Fig. 8.3.
view tutorialThe triangle function depicted in Fig. 8.3 is an even function of π₯ with period2π (i.e., πΏ = π). Its definition on 0 < π₯ < π is given by
π(π₯) = 1β 2π₯
π.
Because π(π₯) is even, it can be represented by the Fourier cosine series given by(8.8) and (8.9). The coefficient π0 is
π0 =2
π
β« π
0
π(π₯)ππ₯
=2
π
β« π
0
(1β 2π₯
π
)ππ₯
=2
π
[π₯β π₯2
π
]π0
= 0.
104 CHAPTER 8. PARTIAL DIFFERENTIAL EQUATIONS
The coefficients for π > 0 are
ππ =2
π
β« π
0
π(π₯) cos (ππ₯)ππ₯
=2
π
β« π
0
(1β 2π₯
π
)cos (ππ₯)ππ₯
=2
π
β« π
0
cos (ππ₯)ππ₯β 4
π2
β« π
0
π₯ cos (ππ₯)ππ₯
=2
ππsin(ππ₯)
]π0β 4
π2
{[π₯πsin (ππ₯)
]π0β 1
π
β« π
0
sin (ππ₯)ππ₯
}=
4
ππ2
β« π
0
sin (ππ₯)ππ₯
= β 4
π2π2cos (ππ₯)
]π0
=4
π2π2
(1β cos (ππ)
).
Since
cos (ππ) =
{β1, if π odd;1, if π even;
we have
ππ =
{8/(π2π2), if π odd;0, if π even.
The Fourier cosine series for the triangle function is therefore given by
π(π₯) =8
π2
(cosπ₯+
cos 3π₯
32+
cos 5π₯
52+ . . .
).
Convergence of this series is rapid. As an interesting aside, evaluation of thisseries at π₯ = 0, using π(0) = 1, yields an infinite series for π2/8:
π2
8= 1 +
1
32+
1
52+ . . . .
With Fourier series now included in our applied mathematics toolbox, we areready to solve the diffusion and wave equations in bounded domains.
8.5 Solution of the diffusion equation
8.5.1 Homogeneous boundary conditions
view lectureview lecture
We consider one dimensional diffusion in a pipe of length πΏ, and solve thediffusion equation for the concentration π’(π₯, π‘),
π’π‘ = π·π’π₯π₯, 0 β€ π₯ β€ πΏ, π‘ > 0. (8.12)
Both initial and boundary conditions are required for a unique solution. Thatis, we assume the initial concentration distribution in the pipe is given by
π’(π₯, 0) = π(π₯), 0 β€ π₯ β€ πΏ. (8.13)
8.5. SOLUTION OF THE DIFFUSION EQUATION 105
Furthermore, we assume that boundary conditions are given at the ends ofthe pipes. When the concentration value is specified at the boundaries, theboundary conditions are called Dirichlet boundary conditions. As the simplestexample, we assume here homogeneous Dirichlet boundary conditions, that iszero concentration of dye at the ends of the pipe, which could occur if the endsof the pipe open up into large reservoirs of clear solution,
π’(0, π‘) = 0, π’(πΏ, π‘) = 0, π‘ > 0. (8.14)
We will later also discuss inhomogeneous Dirichlet boundary conditions andhomogeneous Neumann boundary conditions, for which the derivative of theconcentration is specified to be zero at the boundaries. Note that if π(π₯) isidentically zero, then the trivial solution π’(π₯, π‘) = 0 satisfies the differentialequation and the initial and boundary conditions and is therefore the uniquesolution of the problem. In what follows, we will assume that π(π₯) is not iden-tically zero so that we need to find a solution different than the trivial solution.
The solution method we use is called separation of variables. We assumethat π’(π₯, π‘) can be written as a product of two other functions, one dependentonly on position π₯ and the other dependent only on time π‘. That is, we makethe ansatz
π’(π₯, π‘) = π(π₯)π (π‘). (8.15)
Whether this ansatz will succeed depends on whether the solution indeed hasthis form. Substituting (8.15) into (8.12), we obtain
ππ β² = π·π β²β²π,
which we rewrite by separating the π₯ and π‘ dependence to opposite sides of theequation:
π β²β²
π=
1
π·
π β²
π.
The left hand side of this equation is independent of π‘ and the right hand side isindependent of π₯. Both sides of this equation are therefore independent of bothπ₯ and π‘ and equal to a constant. Introducing βπ as the separation constant, wehave
π β²β²
π=
1
π·
π β²
π= βπ,
and we obtain the two ordinary differential equations
π β²β² + ππ = 0, π β² + ππ·π = 0. (8.16)
Because of the boundary conditions, we must first consider the equation forπ(π₯). To solve, we need to determine the boundary conditions at π₯ = 0 andπ₯ = πΏ. Now, from (8.14) and (8.15),
π’(0, π‘) = π(0)π (π‘) = 0, π‘ > 0.
Since π (π‘) is not identically zero for all π‘ (which would result in the trivialsolution for π’), we must have π(0) = 0. Similarly, the boundary condition atπ₯ = πΏ requires π(πΏ) = 0. We therefore consider the two-point boundary valueproblem
π β²β² + ππ = 0, π(0) = π(πΏ) = 0. (8.17)
106 CHAPTER 8. PARTIAL DIFFERENTIAL EQUATIONS
The equation given by (8.17) is called an ode eigenvalue problem. The allowedvalues of π and the corresponding functions π(π₯) are called the eigenvalues andeigenfunctions of the differential equation. Since the form of the general solutionof the ode depends on the sign of π, we consider in turn the cases π > 0, π < 0and π = 0. For π > 0, we write π = π2 and determine the general solution of
π β²β² + π2π = 0
to beπ(π₯) = π΄ cosππ₯+π΅ sinππ₯.
Applying the boundary condition at π₯ = 0, we find π΄ = 0. The boundarycondition at π₯ = πΏ then yields
π΅ sinππΏ = 0.
The solution π΅ = 0 results in the trivial solution for π’ and can be ruled out.Therefore, we must have
sinππΏ = 0,
which is an equation for the eigenvalue π. The solutions are
π = ππ/πΏ,
where π is an integer. We have thus determined the eigenvalues π = π2 > 0 tobe
ππ = (ππ/πΏ)2, π = 1, 2, 3, . . . , (8.18)
with corresponding eigenfunctions
ππ = sin (πππ₯/πΏ). (8.19)
For π < 0, we write π = βπ2 and determine the general solution of
π β²β² β π2π = 0
to beπ(π₯) = π΄ coshππ₯+π΅ sinhππ₯,
where we have previously introduced the hyperbolic sine and cosine functionsin S3.4.1. Applying the boundary condition at π₯ = 0, we find π΄ = 0. Theboundary condition at π₯ = πΏ then yields
π΅ sinhππΏ = 0,
which for π = 0 has only the solution π΅ = 0. Therefore, there is no nontrivialsolution for π’ with π < 0. Finally, for π = 0, we have
π β²β² = 0,
with general solutionπ(π₯) = π΄+π΅π₯.
The boundary condition at π₯ = 0 and π₯ = πΏ yields π΄ = π΅ = 0 so again there isno nontrivial solution for π’ with π = 0.
8.5. SOLUTION OF THE DIFFUSION EQUATION 107
We now turn to the equation for π (π‘). The equation corresponding to theeigenvalue ππ, using (8.18), is given by
π β² +(π2π2π·/πΏ2
)π = 0,
which has solution proportional to
ππ = πβπ2π2π·π‘/πΏ2
. (8.20)
Therefore, multiplying the solutions given by (8.19) and (8.20), we concludethat the functions
π’π(π₯, π‘) = sin (πππ₯/πΏ)πβπ2π2π·π‘/πΏ2
(8.21)
satisfy the pde given by (8.12) and the boundary conditions given by (8.14) forevery positive integer π.
The principle of linear superposition for homogeneous linear differentialequations then states that the general solution to (8.12) and (8.14) is givenby
π’(π₯, π‘) =
ββπ=1
πππ’π(π₯, π‘)
=
ββπ=1
ππ sin (πππ₯/πΏ)πβπ2π2π·π‘/πΏ2
.
(8.22)
The final solution step is to satisfy the initial conditions given by (8.13). Atπ‘ = 0, we have
π(π₯) =
ββπ=1
ππ sin (πππ₯/πΏ). (8.23)
We immediately recognize (8.23) as a Fourier sine series (8.11) for an odd func-tion π(π₯) with period 2πΏ. Equation (8.23) is a periodic extension of our originalπ(π₯) defined on 0 β€ π₯ β€ πΏ, and is an odd function because of the boundarycondition π(0) = 0. From our solution for the coefficients of a Fourier sine series(8.10), we determine
ππ =2
πΏ
β« πΏ
0
π(π₯) sinπππ₯
πΏππ₯. (8.24)
Thus the solution to the diffusion equation with homogeneous Dirichlet bound-ary conditions defined by (8.12), (8.13) and (8.14) is given by (8.22) with theππ coefficients computed from (8.24).
Example: Determine the concentration of a dye in a pipe of length πΏ,where the dye has unit mass and is initially concentrated at the centerof the pipe, and the ends of the pipe are held at zero concentration
The governing equation for concentration is the diffusion equation. We modelthe initial concentration of the dye by a delta-function centered at π₯ = πΏ/2,
108 CHAPTER 8. PARTIAL DIFFERENTIAL EQUATIONS
that is, π’(π₯, 0) = π(π₯) = πΏ(π₯β πΏ/2). Therefore, from (8.24),
ππ =2
πΏ
β« πΏ
0
πΏ(π₯β πΏ
2) sin
πππ₯
πΏππ₯
=2
πΏsin (ππ/2)
=
β§β¨β© 2/πΏ if π = 1, 5, 9, . . . ;β2/πΏ if π = 3, 7, 11, . . . ;0 if π = 2, 4, 6, . . . .
With ππ determined, the solution for π’(π₯, π‘) given by (8.22) can be written as
π’(π₯, π‘) =2
πΏ
ββπ=0
(β1)π sin
((2π+ 1)ππ₯
πΏ
)πβ(2π+1)2π2π·π‘/πΏ2
.
When π‘ β« πΏ2/π·, the leading-order term in the series is a good approximationand is given by
π’(π₯, π‘) β 2
πΏsin (ππ₯/πΏ)πβπ2π·π‘/πΏ2
.
8.5.2 Inhomogeneous boundary conditions
view lectureConsider a diffusion problem where one end of the pipe has dye of concentrationheld constant at πΆ1 and the other held constant at πΆ2, which could occur if theends of the pipe had large reservoirs of fluid with different concentrations ofdye. With π’(π₯, π‘) the concentration of dye, the boundary conditions are givenby
π’(0, π‘) = πΆ1, π’(πΏ, π‘) = πΆ2, π‘ > 0.
The concentration π’(π₯, π‘) satisfies the diffusion equation with diffusivity π·:
π’π‘ = π·π’π₯π₯.
If we try to solve this problem directly using separation of variables, we willrun into trouble. Applying the inhomogeneous boundary condition at π₯ = 0directly to the ansatz π’(π₯, π‘) = π(π₯)π (π‘) results in
π’(0, π‘) = π(0)π (π‘) = πΆ1;
so thatπ(0) = πΆ1/π (π‘).
However, our separation of variables ansatz assumes π(π₯) to be independent ofπ‘! We therefore say that inhomogeneous boundary conditions are not separable.
The proper way to solve a problem with inhomogeneous boundary conditionsis to transform it into another problem with homogeneous boundary conditions.As π‘ β β, we assume that a stationary concentration distribution π£(π₯) willattain, independent of π‘. Since π£(π₯) must satisfy the diffusion equation, we have
π£β²β²(π₯) = 0, 0 β€ π₯ β€ πΏ,
with general solutionπ£(π₯) = π΄+π΅π₯.
8.5. SOLUTION OF THE DIFFUSION EQUATION 109
Since π£(π₯) must satisfy the same boundary conditions of π’(π₯, π‘), we have π£(0) =πΆ1 and π£(πΏ) = πΆ2, and we determine π΄ = πΆ1 and π΅ = (πΆ2 β πΆ1)/πΏ.
We now express π’(π₯, π‘) as the sum of the known asymptotic stationary con-centration distribution π£(π₯) and an unknown transient concentration distribu-tion π€(π₯, π‘):
π’(π₯, π‘) = π£(π₯) + π€(π₯, π‘).
Substituting into the diffusion equation, we obtain
π
ππ‘(π£(π₯) + π€(π₯, π‘)) = π·
π2
ππ₯2(π£(π₯) + π€(π₯, π‘))
or
π€π‘ = π·π€π₯π₯,
since π£π‘ = 0 and π£π₯π₯ = 0. The boundary conditions satisfied by π€ are
π€(0, π‘) = π’(0, π‘)β π£(0) = 0,
π€(πΏ, π‘) = π’(πΏ, π‘)β π£(πΏ) = 0,
so that π€ is observed to satisfy homogeneous boundary conditions. If the initialconditions are given by π’(π₯, 0) = π(π₯), then the initial conditions for π€ are
π€(π₯, 0) = π’(π₯, 0)β π£(π₯)
= π(π₯)β π£(π₯).
The resulting equations may then be solved for π€(π₯, π‘) using the technique forhomogeneous boundary conditions, and π’(π₯, π‘) subsequently determined.
8.5.3 Pipe with closed ends
view lectureview lecture
There is no diffusion of dye through the ends of a sealed pipe. Accordingly,the mass flux of dye through the pipe ends, given by (8.1), is zero so that theboundary conditions on the dye concentration π’(π₯, π‘) becomes
π’π₯(0, π‘) = 0, π’π₯(πΏ, π‘) = 0, π‘ > 0, (8.25)
which are known as homogeneous Neumann boundary conditions. Again, weapply the method of separation of variables and as before, we obtain the twoordinary differential equations given by (8.16). Considering first the equationfor π(π₯), the appropriate boundary conditions are now on the first derivativeof π(π₯), and we must solve
π β²β² + ππ = 0, π β²(0) = π β²(πΏ) = 0. (8.26)
Again, we consider in turn the cases π > 0, π < 0 and π = 0. For π > 0, wewrite π = π2 and determine the general solution of (8.26) to be
π(π₯) = π΄ cosππ₯+π΅ sinππ₯,
so that taking the derivative
π β²(π₯) = βππ΄ sinππ₯+ ππ΅ cosππ₯.
110 CHAPTER 8. PARTIAL DIFFERENTIAL EQUATIONS
Applying the boundary condition π β²(0) = 0, we find π΅ = 0. The boundarycondition at π₯ = πΏ then yields
βππ΄ sinππΏ = 0.
The solution π΄ = 0 results in the trivial solution for π’ and can be ruled out.Therefore, we must have
sinππΏ = 0,
with solutionsπ = ππ/πΏ,
where π is an integer. We have thus determined the eigenvalues π = π2 > 0 tobe
ππ = (ππ/πΏ)2, π = 1, 2, 3, . . . , (8.27)
with corresponding eigenfunctions
ππ = cos (πππ₯/πΏ). (8.28)
For π < 0, we write π = βπ2 and determine the general solution of (8.26) to be
π(π₯) = π΄ coshππ₯+π΅ sinhππ₯,
so that taking the derivative
π β²(π₯) = ππ΄ sinhππ₯+ ππ΅ coshππ₯.
Applying the boundary condition π β²(0) = 0 yields π΅ = 0. The boundarycondition π β²(πΏ) = 0 then yields
ππ΄ sinhππΏ = 0,
which for π = 0 has only the solution π΄ = 0. Therefore, there is no nontrivialsolution for π’ with π < 0. Finally, for π = 0, the general solution of (8.26) is
π(π₯) = π΄+π΅π₯,
so that taking the derivativeπ β²(π₯) = π΅.
The boundary condition π β²(0) = 0 yields π΅ = 0; π β²(πΏ) = 0 is then triviallysatisfied. Therefore, we have an additional eigenvalue and eigenfunction givenby
π0 = 0, π0(π₯) = 1,
which can be seen as extending the formula obtained for eigenvalues and eigen-vectors for positive π given by (8.27) and (8.28) to π = 0.
We now turn to the equation for π (π‘). The equation corresponding to eigen-value ππ, using (8.27), is given by
π β² +(π2π2π·/πΏ2
)π = 0,
which has solution proportional to
ππ = πβπ2π2π·π‘/πΏ2
, (8.29)
8.5. SOLUTION OF THE DIFFUSION EQUATION 111
valid for π = 0, 1, 2, . . . . Therefore, multiplying the solutions given by (8.28)and (8.29), we conclude that the functions
π’π(π₯, π‘) = cos (πππ₯/πΏ)πβπ2π2π·π‘/πΏ2
(8.30)
satisfy the pde given by (8.12) and the boundary conditions given by (8.25) forevery nonnegative integer π.
The principle of linear superposition then yields the general solution as
π’(π₯, π‘) =
ββπ=0
πππ’π(π₯, π‘)
=π02
+
ββπ=1
ππ cos (πππ₯/πΏ)πβπ2π2π·π‘/πΏ2
,
(8.31)
where we have redefined the constants so that π0 = π0/2 and ππ = ππ, π =1, 2, 3, . . . . The final solution step is to satisfy the initial conditions given by(8.13). At π‘ = 0, we have
π(π₯) =π02
+
ββπ=1
ππ cos (πππ₯/πΏ), (8.32)
which we recognize as a Fourier cosine series (8.9) for an even function π(π₯)with period 2πΏ. We have obtained a cosine series for the periodic extension ofπ(π₯) because of the boundary condition π β²(0) = 0, which is satisfied by an evenfunction. From our solution (8.8) for the coefficients of a Fourier cosine series,we determine
ππ =2
πΏ
β« πΏ
0
π(π₯) cosπππ₯
πΏππ₯. (8.33)
Thus the solution to the diffusion equation with homogenous Neumann bound-ary conditions defined by (8.12), (8.13) and (8.25) is given by (8.31) with thecoefficients computed from (8.33).
Example: Determine the concentration of a dye in a pipe of lengthπΏ, where the dye has unit mass and is initially concentrated at thecenter of the pipe, and the ends of the pipe are sealed
Again we model the initial concentration of the dye by a delta-function centeredat π₯ = πΏ/2. From (8.33),
ππ =2
πΏ
β« πΏ
0
πΏ(π₯β πΏ
2) cos
πππ₯
πΏππ₯
=2
πΏcos (ππ/2)
=
β§β¨β© 2/πΏ if π = 0, 4, 8, . . . ;β2/πΏ if π = 2, 6, 10, . . . ;0 if π = 1, 3, 5, . . . .
The first two terms in the series for π’(π₯, π‘) are given by
π’(π₯, π‘) =2
πΏ
[1/2β cos (2ππ₯/πΏ)πβ4π2π·π‘/πΏ2
+ . . .].
112 CHAPTER 8. PARTIAL DIFFERENTIAL EQUATIONS
Notice that as π‘ β β, π’(π₯, π‘) β 1/πΏ: the dye mass is conserved in the pipe(since the pipe ends are sealed) and eventually diffused uniformly throughoutthe pipe of length πΏ.
8.6 Solution of the wave equation
view lecture
8.6.1 Plucked string
view lectureWe assume an elastic string with fixed ends is plucked like a guitar string. Thegoverning equation for π’(π₯, π‘), the position of the string from its equilibriumposition, is the wave equation
π’π‘π‘ = π2π’π₯π₯, (8.34)
with π2 = π/π and with boundary conditions at the string ends located at π₯ = 0and πΏ given by
π’(0, π‘) = 0, π’(πΏ, π‘) = 0. (8.35)
Since the wave equation is second-order in time, initial conditions are requiredfor both the displacement of the string due to the plucking and the initial velocityof the displacement. We assume
π’(π₯, 0) = π(π₯), π’π‘(π₯, 0) = 0, 0 β€ π₯ β€ πΏ. (8.36)
Again we use the method of separation of variables and try the ansatz
π’(π₯, π‘) = π(π₯)π (π‘). (8.37)
Substitution of our ansatz (8.37) into the wave equation (8.34) and separatingvariables results in
π β²β²
π=
1
π2π β²β²
π= βπ,
yielding the two ordinary differential equations
π β²β² + ππ = 0, π β²β² + ππ2π = 0. (8.38)
We solve first the equation for π(π₯). The appropriate boundary conditions forπ are given by
π(0) = 0, π(πΏ) = 0, (8.39)
and we have solved this equation for π(π₯) previously in S8.5.1 (see (8.17)).A nontrivial solution exists only when π > 0, and our previously determinedsolution was
ππ = (ππ/πΏ)2, π = 1, 2, 3, . . . , (8.40)
with corresponding eigenfunctions
ππ = sin (πππ₯/πΏ). (8.41)
With ππ specified, the π equation then becomes
π β²β²π +
π2π2π2
πΏ2ππ = 0,
8.6. SOLUTION OF THE WAVE EQUATION 113
with general solution given by
ππ(π‘) = π΄ cosππππ‘
πΏ+π΅ sin
ππππ‘
πΏ. (8.42)
The second of the initial conditions given by (8.36) implies
π’π‘(π₯, 0) = π(π₯)π β²(0) = 0,
which can be satisfied only if π β²(0) = 0. Applying this boundary condition to(8.42), we find π΅ = 0. Combining our solution for ππ(π₯), (8.41), and ππ(π‘), wehave determined that
π’π(π₯, π‘) = sinπππ₯
πΏcos
ππππ‘
πΏ, π = 1, 2, 3, . . .
satisfies the wave equation, the boundary conditions at the string ends, and theassumption of zero initial string velocity. Linear superposition of these solutionsresults in the general solution for π’(π₯, π‘) of the form
π’(π₯, π‘) =
ββπ=1
ππ sinπππ₯
πΏcos
ππππ‘
πΏ. (8.43)
The remaining condition to satisfy is the initial displacement of the string, thefirst equation of (8.36). We have
π(π₯) =
ββπ=1
ππ sin (πππ₯/πΏ),
which is observed to be a Fourier sine series (8.11) for an odd function withperiod 2πΏ. Therefore, the coefficients ππ are given by (8.10),
ππ =2
πΏ
β« πΏ
0
π(π₯) sinπππ₯
πΏππ₯, π = 1, 2, 3, . . . . (8.44)
Our solution to the wave equation with plucked string is thus given by (8.43)and (8.44). Notice that the solution is time periodic with period 2πΏ/π. Thecorresponding fundamental frequency is the reciprocal of the period and is givenby π = π/2πΏ. From our derivation of the wave equation in S8.2, the velocity πis related to the density of the string π and tension of the string π by π2 = π/π.Therefore, the fundamental frequency (pitch) of our βguitar stringβ increases (israised) with increasing tension, decreasing string density, and decreasing stringlength. Indeed, these are exactly the parameters used to construct, tune andplay a guitar.
The wave nature of our solution and the physical significance of the velocityπ can be made more transparent if we make use of the trigonometric identity
sinπ₯ cos π¦ =1
2
(sin (π₯+ π¦) + sin (π₯β π¦)
).
With this identity, our solution (8.43) can be rewritten as
π’(π₯, π‘) =1
2
ββπ=1
ππ
(sin
ππ(π₯+ ππ‘)
πΏ+ sin
ππ(π₯β ππ‘)
πΏ
). (8.45)
114 CHAPTER 8. PARTIAL DIFFERENTIAL EQUATIONS
The first and second sine functions can be interpreted as a traveling wave movingto the left or the right with velocity π. This can be seen by incrementing time,π‘ β π‘ + πΏ, and observing that the value of the first sine function is unchangedprovided the position is shifted by π₯ β π₯β ππΏ, and the second sine function isunchanged provided π₯ β π₯ + ππΏ. Two waves travelling in opposite directionswith equal amplitude results in a standing wave.
8.6.2 Hammered string
view lectureIn contrast to a guitar string that is plucked, a piano string is hammered. Theappropriate initial conditions for a piano string would be
π’(π₯, 0) = 0, π’π‘(π₯, 0) = π(π₯), 0 β€ π₯ β€ πΏ. (8.46)
Our solution proceeds as previously, except that now the homogeneous initialcondition on π (π‘) is π (0) = 0, so that π΄ = 0 in (8.42). The wave equationsolution is therefore
π’(π₯, π‘) =
ββπ=1
ππ sinπππ₯
πΏsin
ππππ‘
πΏ. (8.47)
Imposition of initial conditions then yields
π(π₯) =ππ
πΏ
ββπ=1
πππ sinπππ₯
πΏ.
The coefficient of the Fourier sine series for π(π₯) is seen to be πππππ/πΏ, and wehave
ππππππΏ
=2
πΏ
β« πΏ
0
π(π₯) sinπππ₯
πΏππ₯,
or
ππ =2
πππ
β« πΏ
0
π(π₯) sinπππ₯
πΏππ₯.
8.6.3 General initial conditions
view lectureIf the initial conditions on π’(π₯, π‘) are generalized to
π’(π₯, 0) = π(π₯), π’π‘(π₯, 0) = π(π₯), 0 β€ π₯ β€ πΏ, (8.48)
then the solution to the wave equation can be determined using the principle oflinear superposition. Suppose π£(π₯, π‘) is the solution to the wave equation withinitial condition (8.36) and π€(π₯, π‘) is the solution to the wave equation withinitial conditions (8.46). Then we have
π’(π₯, π‘) = π£(π₯, π‘) + π€(π₯, π‘),
since π’(π₯, π‘) satisfies the wave equation, the boundary conditions, and the initialconditions given by (8.48).
8.7. THE LAPLACE EQUATION 115
Figure 8.4: Dirichlet problem for the Laplace equation in a rectangle.
8.7 The Laplace equation
The diffusion equation in two spatial dimensions is
π’π‘ = π·(π’π₯π₯ + π’π¦π¦).
The steady-state solution, approached asymptotically in time, has π’π‘ = 0 sothat the steady-state solution π’ = π’(π₯, π¦) satisfies the two-dimensional Laplaceequation
π’π₯π₯ + π’π¦π¦ = 0. (8.49)
We will consider the mathematical problem of solving the two dimensionalLaplace equation inside a rectangular or a circular boundary. The value ofπ’(π₯, π¦) will be specified on the boundaries, defining this problem to be of Dirich-let type.
8.7.1 Dirichlet problem for a rectangle
view lectureWe consider the Laplace equation (8.49) for the interior of a rectangle 0 < π₯ < π,0 < π¦ < π, (see Fig. 8.4), with boundary conditions
π’(π₯, 0) = 0, π’(π₯, π) = 0, 0 < π₯ < π;
π’(0, π¦) = 0, π’(π, π¦) = π(π¦), 0 β€ π¦ β€ π.
More general boundary conditions can be solved by linear superposition of so-lutions.
We take our usual ansatz
π’(π₯, π¦) = π(π₯)π (π¦),
116 CHAPTER 8. PARTIAL DIFFERENTIAL EQUATIONS
and find after substitution into (8.49),
π β²β²
π= βπ β²β²
π= π,
with π the separation constant. We thus obtain the two ordinary differentialequations
π β²β² β ππ = 0, π β²β² + ππ = 0.
The homogeneous boundary conditions are π(0) = 0, π (0) = 0 and π (π) = 0.We have already solved the equation for π (π¦) in S8.5.1, and the solution yieldsthe eigenvalues
ππ =(ππ
π
)2, π = 1, 2, 3, . . . ,
with corresponding eigenfunctions
ππ(π¦) = sinπππ¦
π.
The remaining π equation and homogeneous boundary condition is therefore
π β²β² β π2π2
π2π = 0, π(0) = 0,
and the solution is the hyperbolic sine function
ππ(π₯) = sinhπππ₯
π,
times a constant. Writing π’π = ππππ, multiplying by a constant and summingover π, yields the general solution
π’(π₯, π‘) =
ββπ=0
ππ sinhπππ₯
πsin
πππ¦
π.
The remaining inhomogeneous boundary condition π’(π, π¦) = π(π¦) results in
π(π¦) =
ββπ=0
ππ sinhπππ
πsin
πππ¦
π,
which we recognize as a Fourier sine series for an odd function with period 2π,and coefficient ππ sinh (πππ/π). The solution for the coefficient is given by
ππ sinhπππ
π=
2
π
β« π
0
π(π¦) sinπππ¦
πππ₯.
8.7.2 Dirichlet problem for a circle
view lectureview lecture
The Laplace equation is commonly written symbolically as
β2π’ = 0, (8.50)
8.7. THE LAPLACE EQUATION 117
where β2 is called the Laplacian, sometimes denoted as Ξ. The Laplacian canbe written in various coordinate systems, and the choice of coordinate systemsusually depends on the geometry of the boundaries. Indeed, the Laplace equa-tion is known to be separable in 13 different coordinate systems! We have solvedthe Laplace equation in two dimensions, with boundary conditions specified ona rectangle, using
β2 =π2
ππ₯2+
π2
ππ¦2.
Here we consider boundary conditions specified on a circle, and write the Lapla-cian in polar coordinates by changing variables from cartesian coordinates. Polarcoordinates is defined by the transformation (π, π) β (π₯, π¦):
π₯ = π cos π, π¦ = π sin π; (8.51)
and the chain rule gives for the partial derivatives
ππ’
ππ=
ππ’
ππ₯
ππ₯
ππ+
ππ’
ππ¦
ππ¦
ππ,
ππ’
ππ=
ππ’
ππ₯
ππ₯
ππ+
ππ’
ππ¦
ππ¦
ππ. (8.52)
After taking the partial derivatives of π₯ and π¦ using (8.51), we can write thetransformation (8.52) in matrix form as(
ππ’/ππππ’/ππ
)=
(cos π sin π
βπ sin π π cos π
)(ππ’/ππ₯ππ’/ππ¦
). (8.53)
Inversion of (8.53) can be determined from the following result, commonlyproved in a linear algebra class. If
A =
(π ππ π
), detA = 0,
then
Aβ1 =1
detA
(π βπ
βπ π
).
Therefore, since the determinant of the 2Γ 2 matrix in (8.53) is π, we have(ππ’/ππ₯ππ’/ππ¦
)=
(cos π β sin π/πsin π cos π/π
)(ππ’/ππππ’/ππ
). (8.54)
Rewriting (8.54) in operator form, we have
π
ππ₯= cos π
π
ππβ sin π
π
π
ππ,
π
ππ¦= sin π
π
ππ+
cos π
π
π
ππ. (8.55)
To find the Laplacian in polar coordinates with minimum algebra, we combine(8.55) using complex variables as
π
ππ₯+ π
π
ππ¦= πππ
(π
ππ+
π
π
π
ππ
), (8.56)
so that the Laplacian may be found by multiplying both sides of (8.56) by itscomplex conjugate, taking care with the computation of the derivatives on the
118 CHAPTER 8. PARTIAL DIFFERENTIAL EQUATIONS
right-hand-side:
π2
ππ₯2+
π2
ππ¦2= πππ
(π
ππ+
π
π
π
ππ
)πβππ
(π
ππβ π
π
π
ππ
)=
π2
ππ2+
1
π
π
ππ+
1
π2π2
ππ2.
We have therefore determined that the Laplacian in polar coordinates is givenby
β2 =π2
ππ2+
1
π
π
ππ+
1
π2π2
ππ2. (8.57)
We now consider the solution of the Laplace equation in a circle with radiusπ < π subject to the boundary condition
π’(π, π) = π(π), 0 β€ π β€ 2π. (8.58)
An additional boundary condition due to the use of polar coordinates is thatπ’(π, π) is periodic in π with period 2π. Furthermore, we will also assume thatπ’(π, π) is finite within the circle.
The method of separation of variables takes as our ansatz
π’(π, π) = π (π)Ξ(π),
and substitution into the Laplace equation (8.50) using (8.57) yields
π β²β²Ξ+1
ππ β²Ξ+
1
π2π Ξβ²β² = 0,
or
π2π β²β²
π + π
π β²
π = βΞβ²β²
Ξ= π,
where π is the separation constant. We thus obtain the two ordinary differentialequations
π2π β²β² + ππ β² β ππ = 0, Ξβ²β² + πΞ = 0.
The Ξ equation is solved assuming periodic boundary conditions with period2π. If π < 0, then no periodic solution exists. If π = 0, then Ξ can be constant.If π = π2 > 0, then
Ξ(π) = π΄ cosππ +π΅ sinππ,
and the requirement that Ξ is periodic with period 2π forces π to be an integer.Therefore,
ππ = π2, π = 0, 1, 2, . . . ,
with corresponding eigenfunctions
Ξπ(π) = π΄π cosππ +π΅π sinππ.
The π equation for each eigenvalue ππ then becomes
π2π β²β² + ππ β² β π2π = 0, (8.59)
which is an Euler equation. With the ansatz π = ππ , (8.59) reduces to thealgebraic equation π (π β 1) + π β π2 = 0, or π 2 = π2. Therefore, π = Β±π, and
8.7. THE LAPLACE EQUATION 119
there are two real solutions when π > 0 and degenerate solutions when π = 0.When π > 0, the solution for R(r) is
π π(π) = π΄ππ +π΅πβπ.
The requirement that π’(π, π) is finite in the circle forces π΅ = 0 since πβπ becomesunbounded as π β 0. When π = 0, the solution for π (π) is
π π(π) = π΄+π΅ ln π,
and again finite π’ in the circle forces π΅ = 0. Therefore, the solution for π =0, 1, 2, . . . is π π = ππ. Thus the general solution for π’(π, π) may be written as
π’(π, π) =π΄0
2+
ββπ=1
ππ(π΄π cosππ +π΅π sinππ), (8.60)
where we have separated out the π = 0 solution to write our solution in a formsimilar to the standard Fourier series given by (8.2). The remaining boundarycondition (8.58) specifies the values of π’ on the circle of radius π, and impositionof this boundary condition results in
π(π) =π΄0
2+
ββπ=1
ππ(π΄π cosππ +π΅π sinππ). (8.61)
Equation (8.61) is a Fourier series for the periodic function π(π) with period 2π,i.e., πΏ = π in (8.2). The Fourier coefficients πππ΄π and πππ΅π are therefore givenby (8.6) and (8.7) to be
πππ΄π =1
π
β« 2π
0
π(π) cosππππ, π = 0, 1, 2, . . . ;
πππ΅π =1
π
β« 2π
0
π(π) sinππππ, π = 1, 2, 3, . . . . (8.62)
A remarkable fact is that the infinite series solution for π’(π, π) can be summedexplicitly. Substituting (8.62) into (8.60), we obtain
π’(π, π) =1
2π
β« 2π
0
πππ(π)
[1 + 2
ββπ=1
( ππ
)π(cosππ cosππ+ sinππ sinππ)
]
=1
2π
β« 2π
0
πππ(π)
[1 + 2
ββπ=1
( ππ
)πcosπ(π β π)
].
We can sum the infinite series by writing 2 cosπ(π β π) = πππ(πβπ) + πβππ(πβπ),and using the sum of the geometric series
ββπ=1 π§
π = π§/(1β π§) to obtain
1 + 2
ββπ=1
( ππ
)πcosπ(π β π) = 1 +
ββπ=1
(πππ(πβπ)
π
)π
+
ββπ=1
(ππβπ(πβπ)
π
)π
= 1 +
(πππ(πβπ)
πβ πππ(πβπ)+ c.c.
)=
π2 β π2
π2 β 2ππ cos (π β π) + π2.
120 CHAPTER 8. PARTIAL DIFFERENTIAL EQUATIONS
Therefore,
π’(π, π) =π2 β π2
2π
β« 2π
0
π(π)
π2 β 2ππ cos (π β π) + π2ππ,
an integral result for π’(π, π) known as Poissonβs formula. As a trivial example,consider the solution for π’(π, π) if π(π) = πΉ , a constant. Clearly, π’(π, π) = πΉsatisfies both the Laplace equation and the boundary conditions so must be thesolution. You can verify that π’(π, π) = πΉ is indeed the solution by showing thatβ« 2π
0
ππ
π2 β 2ππ cos (π β π) + π2=
2π
π2 β π2.