+ All Categories
Home > Documents > Ordinary Di erential Equations: Worked Examples with...

Ordinary Di erential Equations: Worked Examples with...

Date post: 27-Apr-2020
Category:
Upload: others
View: 5 times
Download: 0 times
Share this document with a friend
57
Ordinary Differential Equations: Worked Examples with Solutions Edray Herber Goins Talitha Michal Washington July 31, 2016
Transcript
Page 1: Ordinary Di erential Equations: Worked Examples with Solutionsegoins/notes/Ordinary_Differential_Equation… · Ordinary Di erential Equations: Worked Examples with Solutions Edray

Ordinary Differential Equations:

Worked Examples with Solutions

Edray Herber GoinsTalitha Michal Washington

July 31, 2016

Page 2: Ordinary Di erential Equations: Worked Examples with Solutionsegoins/notes/Ordinary_Differential_Equation… · Ordinary Di erential Equations: Worked Examples with Solutions Edray

2

Page 3: Ordinary Di erential Equations: Worked Examples with Solutionsegoins/notes/Ordinary_Differential_Equation… · Ordinary Di erential Equations: Worked Examples with Solutions Edray

Contents

I First Order Differential Equations 5

1 What is a Differential Equation? 71.1 Limits and Continuity . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 71.2 Differential Calculus . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 91.3 Integral Calculus . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 111.4 Slope Fields . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 141.5 Classical Mechanics . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15

2 Separable Equations and Population Dynamics 232.1 Separable Equations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 232.2 Autonomous Equations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 262.3 Population Growth Models . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 292.4 Newton’s Law of Cooling . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 372.5 Radioactive Decay . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 39

3 Exact Equations and Integrating Factors 413.1 Exact Equations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 413.2 Equidimensional Equations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 433.3 Bernoulli Equations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 453.4 Integrating Factors . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 463.5 Linear Equations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 473.6 Loan Calculations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 483.7 Diffusion Problems . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 50

3

Page 4: Ordinary Di erential Equations: Worked Examples with Solutionsegoins/notes/Ordinary_Differential_Equation… · Ordinary Di erential Equations: Worked Examples with Solutions Edray

4

Page 5: Ordinary Di erential Equations: Worked Examples with Solutionsegoins/notes/Ordinary_Differential_Equation… · Ordinary Di erential Equations: Worked Examples with Solutions Edray

Part I

First Order Differential Equations

5

Page 6: Ordinary Di erential Equations: Worked Examples with Solutionsegoins/notes/Ordinary_Differential_Equation… · Ordinary Di erential Equations: Worked Examples with Solutions Edray
Page 7: Ordinary Di erential Equations: Worked Examples with Solutionsegoins/notes/Ordinary_Differential_Equation… · Ordinary Di erential Equations: Worked Examples with Solutions Edray

Chapter 1

What is a Differential Equation?

1.1 Limits and Continuity

Problem 1. Let d ≥ 1 be a rational number, and define the sequence of rational numbers xn by

x1 = 1 and xn+1 = 1 +d− 1

4

1

xnfor n = 1, 2, . . . . Assuming that this sequence converges, show

the following:

(a.) 0 ≤ xn − 1 ≤ d− 1

4for n = 1, 2, . . .

(b.) limn→∞

xn =1 +√d

2

Solution. First note that x1 ≥ 1 so all terms in the sequence xn − 1 ≥ 0. This gives

1 ≥ 1

xn=⇒ d− 1

4=

(1 +

d− 1

4

)− 1 ≥

(1 +

d− 1

4

1

xn

)− 1 = xn+1 − 1.

As for the value of such a limit, we have the identity(limn→∞

xn+1

)= 1 +

d− 1

4

1(limn→∞

xn

) ;

so that if we denote L = limn→∞ xn we have

L = 1 +d− 1

4

1

L=⇒ L2 − L− d− 1

4= 0.

By the quadratic formula, we have two possibilities:1±√d

2. Since d ≥ 1, we cannot have the −

sign or else L would be negative. Hence L =1 +√d

2.

Problem 2. Let θ be an angle between 0 andπ

2radians, and define the five points A = (0, 0),

B = (1, 0), C = (cos θ, sin θ), D = (cos θ, 0), E = (cos2 θ, cos θ sin θ). Note that B and C lie on acircle of radius 1, while D and E lie on a circle of radius cos θ.

7

Page 8: Ordinary Di erential Equations: Worked Examples with Solutionsegoins/notes/Ordinary_Differential_Equation… · Ordinary Di erential Equations: Worked Examples with Solutions Edray

Let a(θ) be the region bounded by the line AB, the line AC, and the arc BC. Let b(θ) be thesubregion of a(θ) which is the triangle ADC. Let c(θ) be the subregion of b(θ) which is boundedby the line AD, the line AE, and the arc DE. Show the following:

(a.)area of c(θ)

area of a(θ)= cos2 θ

(b.)area of b(θ)

area of a(θ)=

cos θ sin θ

θ

(c.) cos θ <sin θ

θ<

1

cos θ

Solution. The area of the sector s of a circle of radius r and an angle θ is s =1

2θ r2, so we have

area of a(θ) =θ

2, area of b(θ) =

cos θ sin θ

2, area of c(θ) =

θ cos2 θ

2.

Since c(θ) is a subregion of b(θ) is a subregion of a(θ), we have

θ cos2 θ

2<

cos θ sin θ

2<θ

2=⇒ cos θ <

sin θ

θ<

1

cos θ.

Problem 3. Using the previous exercise, show that we have the following limits.

(a.) limx→0

cosx = 1

(b.) limx→0

sinx

x= 1

(c.) limx→0

1− cosx

x2=

1

2

Solution. First, note that cosx is a continuous function so limx→0 cosx = cos 0 = 1. Now using theprevious exercise (with x in place of θ) we have

1 = limx→0

cosx ≤ limx→0

sinx

x≤ lim

x→0

1

cosx= 1 =⇒ lim

x→0

sinx

x= 1.

Finally, to work out the third limit, we note that

1− cosx

x2=

1− cos2 x

x2 (1 + cosx)=

1

1 + cosx

(sinx

x

)2

;

so that we have the limit

limx→0

1− cosx

x2= lim

x→0

1

1 + cosx·(

limx→0

sinx

x

)2

=1

2· 12 =

1

2.

8

Page 9: Ordinary Di erential Equations: Worked Examples with Solutionsegoins/notes/Ordinary_Differential_Equation… · Ordinary Di erential Equations: Worked Examples with Solutions Edray

Problem 4. Let F (x) be a function satisfying the recursive formula F (x+ 1) = xF (x) where F (1)is nonzero. Show that F (x) has a singularity at the nonpositive integers 0, −1, −2, . . . .

Solution. Let k be a nonnegative integer; then −k is a nonpositive integer. Using the recursiveformula,

F (x− k) =F(x− (k − 1)

)(x− k)

=F (x)

(x− 1) · · · (x− k)=

F (x+ 1)

x (x− 1) · · · (x− k)

so that we have the limit

limx→−k

F (x) = limx→0

F (x− k) = limx→0

F (x+ 1)

x(x− 1) · · · (x− k)=

(−1)k

k!F (1) · lim

x→0

1

x

which does not converge.

Problem 5. Let n be a positive real number. Show that

(a.) limx→0

xn log x = 0

(b.) limx→∞

x−n log x = 0

Solution. We show the first limit. Substitute x = e−t/n so that as t = −n log x. Hence, as x → 0,the variable t→∞. This gives

limx→0

xn log x = − 1

n· limt→∞

t e−t = 0

The value is zero because the exponential function f(t) = e−t dies faster than the linear functiong(t) = t grows. As for the second limit, the substitution x = 1/t means t→ 0 as x→∞ so that

limx→∞

x−n log x = − limt→0

tn log t = 0.

1.2 Differential Calculus

Problem 6. Let y = f(x) be a function which is smooth i.e. a function where derivatives of all

order exist. Given a nonegative integer n, define f (n) =dny

dxn. Show that for smooth functions f(x)

and g(x),

(f · g)(0) = f (0) g(0)

(f · g)(1) = f (1) g(0) + f (0) g(1)

(f · g)(2) = f (2) g(0) + 2 f (1) g(1) + f (0) g(2)

In general, we can write

(f · g)(n) =

n∑k=0

Cn−k,k f(n−k) g(k).

What are the coefficients Cn−k,k?

9

Page 10: Ordinary Di erential Equations: Worked Examples with Solutionsegoins/notes/Ordinary_Differential_Equation… · Ordinary Di erential Equations: Worked Examples with Solutions Edray

Solution. This exercise shows Leibnitz’s Rule: the coefficients

Cn−k,k =

(n

k

)=

n!

(n− k)! k!

are the Binomial Coefficients. One verifies the formulas above by repeated use of the productrule.

Problem 7. Define the function y = cos (log x). Find positive constants a, b, and c such thata x2 y′′ + b x y′ + c y = 0.

Solution. The derivative of y = cos log x is y′ = − sin log x · 1x

, so that x y′ = − sin log x. The second

derivative is

y′′ =

(− cos log x · 1

x

)1

x− sin log x ·

(− 1

x2

)=⇒ x2 y′′ = sin log x− cos log x

and so x2 y′′ = −x y′ − y. Hence, we may choose a = b = c = 1.

Problem 8. For real numbers x1, x2, . . . , xn and positive integers C1, C2, . . . , Cn; define the poly-nomial

g(x) = (x− x1)C1 (x− x2)C2 · · · (x− xn)Cn .

Show the identityg′(x)

g(x)=

C1

x− x1+

C2

x− x2+ · · ·+ Cn

x− xn.

Solution. The logarithm of g(x) is the sum

log g(x) = C1 log(x− x1) + C2 log(x− x2) + · · ·+ Cn log(x− xn)

which in turn has the derivative

g′(x)

g(x)=

d

dx

[log g(x)

]= C1

1

x− x1+ C2

1

x− x2+ · · ·+ Cn

1

x− xn.

Problem 9. Denote the curve

C ={

(x, y) ∈ R2∣∣ y3 = x5 − 1

}.

Without solving for y, show that show that

(a.) (1, 0) ∈ C has a vertical tangent.

(b.) (0,−1) ∈ C has a horizontal tangent.

10

Page 11: Ordinary Di erential Equations: Worked Examples with Solutionsegoins/notes/Ordinary_Differential_Equation… · Ordinary Di erential Equations: Worked Examples with Solutions Edray

(c.) The tangent line at every other point on C has positive slope.

Solution. The curve C is defined by y3 − x5 + 1 = 0, so we can find the derivative via implicitdifferentiation:

3 y2dy

dx− 5x4 = 0 =⇒ dy

dx=

5x4

3 y2.

When x = 1 and y = 0, the slope dy/dx = ∞ so the curve has a vertical tangent. In fact, wheny = 0, then x5 = 1 and the only real number where this is true is x = 1. That is, (1, 0) is the onlypoint on C with a vertical tangent. When x = 0 and y = −1, the slope dy/dx = 0 so the curvehas a horizontal tangent. In fact, when x = 0, then y3 = −1 and the only real number where thisis true is y = −1. That is, (0,−1) is the only point on C with a horizontal tangent. Otherwiseboth x4 and y2 are nonzero and hence must be positive, so that dy/dx is positive as well. Hencethe slope is always positive in these cases.

Problem 10. Let y = y(x) be any function which satisfies the implicit relation x = tan y.

(a.) Show that y = y(x) must be an increasing function without relative extrema.

(b.) It is true that y(0) = 0 and y′(0) = 1?

Solution. First we make an observation:

1 + x2 = 1 + tan2 y =cos2 y + sin2 y

cos2 y=

1

cos2 y= sec2 y.

Now we implicitly differentiate the expression tan y − x = 0:

sec2 ydy

dx− 1 = 0 =⇒ dy

dx= cos2 y =

1

1 + x2.

Hence dy/dx 6= 0 so that it has no relative extrema. In fact, dy/dx > 0 so that it is alwaysincreasing. Note that y′(0) = 1/(1 + 02) = 1 must indeed be true. It need not be true thaty(0) = 0, but it must be true that y(0) satisfy tan y(0) = 0. This occurs only when y(0) = nπwhere n is an integer.

1.3 Integral Calculus

Problem 11. Compute the value of the following integrals:

(a.)

∫ 1

−1

dx√1− x2

(b.)

∫ 2

0

dx√2x− x2

(c.)

∫ 5

3

dx√(x− 3)(5− x)

11

Page 12: Ordinary Di erential Equations: Worked Examples with Solutionsegoins/notes/Ordinary_Differential_Equation… · Ordinary Di erential Equations: Worked Examples with Solutions Edray

Solution. If x = a+ b sin θ then dx = b cos θ dθ. This yields∫ 1

−1

dx√1− x2

=

∫ π/2

−π/2

cos θ dθ√1− sin2 θ

=

∫ π/2

−π/2dθ = π.

With the substitution x = 1 + sin θ, as x ranges from 0 to 2, the function sin θ ranges from -1 to+1, so the variable θ ranges from −π/2 to π/2. Through the identity 2x−x2 = 1− (x2−2x+1) =1− (x− 1)2 = 1− sin2 θ = cos2 θ we may evaluate the integral as∫ 2

0

dx√2x− x2

=

∫ π/2

−π/2

cos θ dθ√cos2 θ

=

∫ π/2

−π/2dθ = π.

Again, with the substitution x = 4 + sin θ, as x ranges from 3 to 5, the function sin θ ranges from-1 to +1, so the variable θ ranges from −π/2 to π/2. Through the identity (x − 3)(5 − x) =(1 + sin θ)(1− sin θ) = 1− sin2 θ = cos2 θ we may evaluate the integral as∫ 5

3

dx√(x− 3)(5− x)

=

∫ π/2

−π/2dθ = π.

Problem 12. Given that a x2+b x+c is a quadratic polynomial with leading term a < 0, discriminantb2 − 4 a c > 0, and roots α < β, show that∫ β

α

dx√a x2 + b x+ c

|a|1/2.

Solution. We’ll make the substitution

x = − b

2 a+

√b2 − 4 a c

2 |a|sin θ =⇒ dx =

√b2 − 4 a c

2 |a|cos θ dθ.

First, using the quadratic formula to find the roots of a x2 + b x+ c, we define

α = − b

2 a−√b2 − 4 a c

2 |a|, β = − b

2 a+

√b2 − 4 a c

2 |a|so that as x ranges from α to β, the function sin θ ranges from -1 to +1, and hence the variable θ

ranges from −π2

to +π

2. We also have the identity (remember that a < 0):

√a x2 + b x+ c =

√−a

[b2 − 4 a c

4 a2−(x+

b

2 a

)2]1/2

=√−a[b2 − 4 a c

4 a2− b2 − 4 a c

4 a2sin2 θ

]1/2=√−a[b2 − 4 a c

4 a2cos2 θ

]1/2= |a|1/2 dx

so that the integral is ∫ β

α

dx√a x2 + b x+ c

=1

|a|1/2

∫ π/2

−π/2dθ =

π

|a|1/2.

12

Page 13: Ordinary Di erential Equations: Worked Examples with Solutionsegoins/notes/Ordinary_Differential_Equation… · Ordinary Di erential Equations: Worked Examples with Solutions Edray

Problem 13. Consider the identity

1− 1

3+

1

5− 1

7+

1

9− 1

11+ · · · =

∫ 1

0

dx

x2 + 1.

Compute the value of this sum/integral.

Solution. We’ll substitute x = tan θ. As x ranges from 0 to 1, the variable θ ranges from 0 to π/4.Recall that the derivative of tan θ is sec2 θ; hence dx = sec2 θ dθ. Also, we have the identity

x2 + 1 = tan2 θ + 1 =sin2 θ

cos2 θ+ 1 =

sin2 θ + cos2 θ

cos2 θ=

1

cos2 θ= sec2 θ

so that the integral becomes∫ 1

0

dx

x2 + 1=

∫ π/4

0

sec2 θ dθ

sec2 θ=

∫ π/4

0dθ =

π

4.

Problem 14. Show that when a > b > 0,∫ ∞−∞

dx

(1 + a2 x2) (1 + b2 x2)=

π

a+ b.

Solution. First consider the partial fraction expansion

1

(1 + a2 x2) (1 + b2 x2)=

A

1 + a2 x2+

B

1 + b2 x2

where A and B satisfy the equations b2A + a2B = 0 and A + B = 1. That is, A = a2/(a2 − b2)and B = b2/(b2 − a2). The integral of interest can now be expressed as the sum of two integrals:∫ ∞

−∞

dx

(1 + a2 x2) (1 + b2 x2)= A

∫ ∞−∞

dx

1 + a2 x2+B

∫ ∞−∞

dx

1 + b2 x2.

Now let’s focus on the integral∫∞−∞ dx/(1 + a2 x2). We’ll make the substitution x =

1

atan θ. As x

ranges from −∞ to ∞, the variable θ ranges from −π/2 to π/2. This gives∫ ∞−∞

dx

1 + a2 x2=

∫ π/2

−π/2

1

a

sec2 θ

1 + tan2 θdθ =

∫ π/2

−π/2

1

adθ =

π

a.

Finally, we can evaluate the original integral. It is∫ ∞−∞

dx

(1 + a2 x2) (1 + b2 x2)=Aπ

a+B π

b=

a π

a2 − b2+

b π

b2 − a2=

(a− b)πa2 − b2

a+ b.

13

Page 14: Ordinary Di erential Equations: Worked Examples with Solutionsegoins/notes/Ordinary_Differential_Equation… · Ordinary Di erential Equations: Worked Examples with Solutions Edray

Problem 15. Given that a x2 + b x + c is a positive definite quadratic polynomial (that is, a > 0and b2 − 4 a c < 0), show that ∫ ∞

−∞

dx

a x2 + b x+ c=

2π√4 a c− b2

.

Solution. We’ll make the substitution

x = − b

2 a+

√4 a c− b2

2 atan θ =⇒ dx =

√4 a c− b2

2 asec2 θ dθ.

As x ranges from−∞ to∞, the variable θ ranges from−π/2 to +π/2. Using the identity tan2 θ+1 =sec2 θ, we also have the identity

a x2 + b x+ c = a

[(x+

b

2 a

)2

+4 a c− b2

4 a2

]

= a

[4 a c− b2

4 a2tan2 θ +

4 a c− b2

4 a2

]=

4 a c− b2

4 asec2 θ =

√4 a c− b2

2

dx

so that the integral is∫ ∞−∞

dx

a x2 + b x+ c=

∫ π/2

−π/2

2√4 a c− b2

dθ =2π√

4 a c− b2.

1.4 Slope Fields

For the following differential equations, draw a slope field for the given differential equation andstate whether you think that the solutions are converging or diverging.

Problem 16.dy

dx= −x y + 0.1 y3.

Solution. Figure 1.1 contains a plot of the slope field. Convergence of the solution depends on theinitial condition. The graph shows that if |y(0)| ≥ 2.4 then y → ±∞, yet if |y(0)| ≤ 2.2 then y → 0.Figure 1.2 contains a closer analysis of the direction field. Using this, we see that the solutions

diverge y → ±∞ if |y(0)| > 2.37, yet the solutions converge y → 0 if |y(0)| < 2.37.

Problem 17.dy

dx= x2 + y2.

Solution. Figure 1.3 contains a plot of the slope field. It is clear that the solutions are diverging y →∞regardless of the initial condition.

14

Page 15: Ordinary Di erential Equations: Worked Examples with Solutionsegoins/notes/Ordinary_Differential_Equation… · Ordinary Di erential Equations: Worked Examples with Solutions Edray

Figure 1.1: Direction Field fordy

dx= −x y + 0.1 y3

-0.5 0 0.5 1 1.5 2 2.5 3 3.5 4

-0.8

0.8

1.6

2.4

3.2

4

4.8

1.5 Classical Mechanics

Problem 18. At t = 0, a ball is propelled downward from an initial height of 1000 m with an initialspeed of 25 m/s. Calculate the time t that the ball hits the ground.

Solution. The height of the ball at time t is given by the formula

x(t) = x0 + v0 t−1

2g t2

where x0 = 1000m is the initial height, v0 = −25m/s is the initial speed (note negative becausethe ball is propelled downward!), and g = 9.81m/s2 is the acceleration due to gravity. We want tofind the time t when x(t) = 0 i.e.

0 = 1000− 25 t− 1

29.8 t2 =⇒ t = 11.9556 or − 17.0525.

Time can only be positive, so we find t = 12 s .

Problem 19. A balloon is ascending at a rate of 15 m/s at a height of 100 m about the ground, whena package is dropped from the gondola. How long will it take the package to reach the ground?Ignore air resistance.

15

Page 16: Ordinary Di erential Equations: Worked Examples with Solutionsegoins/notes/Ordinary_Differential_Equation… · Ordinary Di erential Equations: Worked Examples with Solutions Edray

Figure 1.2: Solutions ofdy

dx= −x y + 0.1 y3, with y(0) = 2.37

0 0.08 0.16 0.24 0.32 0.4 0.48 0.56 0.64 0.72 0.8 0.88 0.96 1.04

2.25

2.5

2.75

3

3.25

3.5

Solution. Denote the height of the package at time t by

x(t) = x0 + v0 t−1

2g t2

where x0 = 100m is the initial height, v0 = 15m/s is the initial velocity (note positive because theballoon is ascending!) and g = 9.81m/s2 is the acceleration due to gravity. We want to find thetime t when x(t) = 0 i.e.

0 = 100 + 15 t− 1

29.81 t2 =⇒ t = 6.29616 or − 3.23806.

Time can only be positive, so we find t = 6.3 s .

Problem 20. The velocity v(t) of a falling object satisfies the initial value problemdv

dt= 9.8 − v

5where v(0) = 0.

(a.) Find the time that must elapse for the object to reach 98% of its terminal velocity.

(b.) How far does the object fall in the time found in part (a)?

Solution. The velocity of the falling object at t seconds is v(t) = 49(1− e−t/5

). The limiting

16

Page 17: Ordinary Di erential Equations: Worked Examples with Solutionsegoins/notes/Ordinary_Differential_Equation… · Ordinary Di erential Equations: Worked Examples with Solutions Edray

Figure 1.3: Direction Field fordy

dx= x2 + y2

-1.25 -1 -0.75 -0.5 -0.25 0 0.25 0.5 0.75 1 1.25

-0.75

-0.5

-0.25

0.25

0.5

0.75

velocity is vL = 49 m/sec, so the velocity reaches 98% of this value when

49(

1− e−t/5)

= 0.98 · 49

1− e−t/5 = 0.98

e−t/5 = 0.02

et/5 = 50 =⇒ t = 5 ln 50 = 19.56 sec.

The distance the object has fallen after t seconds is x(t) = 49 t+245 e−t/5−245. Hence the distanceafter t = 19.56 seconds is x = 49 · 19.56 + 245 · 0.02− 245 = 718.346 m.

Problem 21. A skydiver of mass 60 kg free-falls from an airplane at an altitude of 5000 meters. Heis subjected to an air resistance force that is proportional to his speed. Assume that the constantof proportionality is 10 (kg/sec). Find and solve the differential equation governing the altitude ofthe skydiver at time t seconds after the start of his free-fall. Assuming that he does not employ hisparachute, find his limiting velocity and how much time will elapse before he hits the ground.

Solution. Let x(t) denote the altitude of the skydiver at time t, and v(t) =dx

dtthe velocity of the

skydiver at time t. Then when the skydiver initially jumps from the plane i.e. at t0 = 0 we havex(t0) = 5000m and v(t0) = 0m/s. The force due to gravity is −mg = −588.6 kg m/s2, and the

force due to air resistance is −10 v. Hence the equation of motion is md2x

dt2= −mg − 10

dx

dt.

17

Page 18: Ordinary Di erential Equations: Worked Examples with Solutionsegoins/notes/Ordinary_Differential_Equation… · Ordinary Di erential Equations: Worked Examples with Solutions Edray

First we solve for the velocity. We have the initial value problem

60dv

dt= −588.6− 10 v where v(0) = 0.

This equation is separable:dv

v + 58.86= −dt

6, so that ln |v + 58.86| = − t

6+ C1. The constant is

C1 = ln 58.86, so we have ln |v+ 58.86| = − t6

+ ln 58.86, which gives v(t) = 58.86 e−t/6 − 58.86. As

t→∞, the limiting velocity is v(t)→ −58.86 m/s .

Second we solve for the altitude. We have the initial value problem

dx

dt= 58.86 e−t/6 − 58.86 where x(0) = 5000.

We integrate term by term to find x(t) = −58.86 ·6 e−t/6−58.86 t+C2. Using the initial conditions,we find that the constant is C2 = 5353.16, so we have x(t) = 5353.16 − 58.86 t + 353.16 e−t/6. Tofind out how much time will elapse before the skydiver hits the ground, we want to find the time tsuch that t = 0, i.e., 0 = 5353.16− 58.86 t+ 353.16 e−t/6 so that t = 90.9473 s .

Problem 22. A sky diver weighing 180 lb (including equipment) falls vertically downward from analtitude of 5,000 ft and opens the parachute after 10 sec of free fall. Assume that the force of airresistance is 0.75 |v| when the parachute is closed and 12 |v| when the parachute is open, wherethe velocity v is measured in ft/sec. Note: The force due to gravity is mg = 180 lb where thegravitational acceleration is g = 32 ft/sec2. The mass of the sky diver is m = 180/g = 5.63 lb.

(a.) Find the speed of the sky diver when the parachute opens.

(b.) Find the distance fallen before the parachute opens.

(c.) What is the limiting velocity vL after the parachute opens?

(d.) Determine how long the sky diver is in the air after the parachute opens.

(e.) Plot the graph of velocity versus time from the beginning of the fall until the skydiver reachesthe ground.

Solution. Let v = v(t) denote the speed of the sky diver in the downward direction. The force dueto air resistance is −γ v, where

γ =

{0.75 lb/sec when the parachute is closed,

12 lb/sec when the parachute is open.

Now we find an expression for the speed of the sky diver. Newton’s Second Law of Motion states

F = ma, which is equivalent to the differential equation mdv

dt= mg− γ v. We solve this equation

18

Page 19: Ordinary Di erential Equations: Worked Examples with Solutionsegoins/notes/Ordinary_Differential_Equation… · Ordinary Di erential Equations: Worked Examples with Solutions Edray

using integrating factors. After dividing through by m, we multiply by µ(t) = eγt/m:

mdv

dt+ γ v = mg

dv

dt+γ

mv = g

eγt/mdv

dt+γ

meγt/m v = g eγt/m

d

dt

[eγt/m v

]= g eγt/m =⇒ eγt/m v(t) =

mg

γeγt/m + C

for some constant C. Say that we have the initial condition v(t0) = v0. If we set t = t0, we have

v(t0) =mg

γ+ C e−γt0/m =⇒ C =

(v(t0)−

mg

γ

)eγt0/m.

Hence the speed of the sky diver is

v(t) =mg

γ+ C e−γt/m =

mg

γ+

(v0 −

mg

γ

)e−γ(t−t0)/m.

Initially the sky diver is in free fall, so v0 = 0 ft/sec when t0 = 0 sec. The speed of the sky diverwhen the parachute opens is

v(10) =180

0.75+

(0− 180

0.75

)e−0.75(10−0)/5.63 = 176.74 ft/sec.

Let x = x(t) denote the distance the sky diver has fallen by time t. Since we have chosen

v = v(t) as the velocity in the downward direction, we have the initial value problemdx

dt= v where

x(t0) = x0. We have the differential equation

dx

dt=mg

γ+

(v0 −

mg

γ

)e−γ(t−t0)/m =⇒ x(t) =

mg

γt−

(v0 −

mg

γ

)m

γe−γ(t−t0)/m + C

for some constant C. Upon setting t = t0 we have

x0 =mg

γt0 −

(v0 −

mg

γ

)m

γ+ C =⇒ C = x0 −

mg

γt0 +

(v0 −

mg

γ

)m

γ.

Hence the distance the sky diver has fallen is

x(t) = x0 +mg

γ(t− t0) +

(v0 −

mg

γ

)m

γ

(1− e−γ(t−t0)/m

).

Initially we have v0 = 0 ft/sec and x0 = 0 ft when t0 = 0 sec, so the distance the sky diver has fallenwhen the parachute opens is

x(10) = 0 +180

0.75(10− 0) +

(0− 180

0.75

)5.63

0.75

(1− e−0.75(10−0)/5.63

)= 1074.47 ft.

19

Page 20: Ordinary Di erential Equations: Worked Examples with Solutionsegoins/notes/Ordinary_Differential_Equation… · Ordinary Di erential Equations: Worked Examples with Solutions Edray

After the parachute opens, the differential equation which governs the motion of the sky diverremains the same – except that γ = 12 lb/sec. Hence the speed of the sky diver is

v(t) =mg

γ+

(v0 −

mg

γ

)e−γ(t−t0)/m

where now v0 = 176.74 ft/sec when t0 = 10 sec. Hence the limiting velocity after the parachuteopens is

vL = limt→∞

v(t) =mg

γ=

180

12= 15 ft/sec.

After the parachute opens, the distance the sky diver has fallen is

x(t) = x0 +mg

γ(t− t0) +

(v0 −

mg

γ

)m

γ

(1− e−γ(t−t0)/m

)where now v0 = 176.74 ft/sec and x0 = 1074.47 ft when t0 = 10 sec. Say that T = t− t0 is the timethat the sky diver is in the air after the parachute opens i.e., x(t) = 5000 ft. If T is large enough,then e−γT/m ≈ 0, so we can ignore it. Hence we have the equation

x(T + t0) ≈ x0 +mg

γT +

(v0 −

mg

γ

)m

γ

5000 ≈ 1074.47 +180

12T +

(176.74− 180

12

)5.63

12

3849.71 ≈ 15T

so that T = 256.65 sec.

Figure 1.4: Plot of v(t) vs. t

-50 -25 0 25 50 75 100 125 150 175 200 225 250

-25

25

50

75

100

125

150

175

20

Page 21: Ordinary Di erential Equations: Worked Examples with Solutionsegoins/notes/Ordinary_Differential_Equation… · Ordinary Di erential Equations: Worked Examples with Solutions Edray

Figure 1.4 has a plot of the function:

v(t) =

180

0.75+

(0− 180

0.75

)e−0.75t/5.63 if t ≤ 10 sec,

180

12+

(176.74− 180

12

)e−12(t−10)/5.63 if t ≥ 10 sec.

Problem 23. For small, slowly falling objects, the assumption that the drag force is proportional tothe velocity is a good one. For larger, more rapidly falling objects, it is more accurate to assumethat the drag force is proportional to the square of the velocity.

(a.) Write a differential equation for the velocity of a falling object of mass m if the drag force isproportional to the square of the velocity.

(b.) Determine the limiting velocity after a long time.

(c.) If m = 10 kg, find the drag coefficient so that the limiting velocity is 49 m/sec.

(d.) Using the data in part (c), draw a slope field.

Solution. Let v = v(t) denote the velocity of the falling object in the downward direction at time t.The force due to gravity on this mass is mg. The force due to air resistance is proportional to v2, sothis force is −k v2 for some positive constant k. Newton’s Second Law of Motion states that F = ma

is the sum of the forces on this object, so we have the differential equation mdv

dt= mg − k v2 . Let

vL = limt→∞

v(t) denote the limiting velocity after a long time. It satisfies the equation mg−k vL2 = 0,

so that vL =

√mg

k. Hence v →

√mg

k. Gravitational acceleration is g = 9.8 m/sec2. If the

limiting velocity is to be vL = 49 m/sec for a mass m = 10 kg, then we have mg − k vL2 = 0, sothat

k =mg

vL2=

10 · 9.8492

kg m/sec2

m2/sec2=

2

49kg/m.

Hence k = 2/49 = 0.041 kg/m. We consider the differential equation mdv

dt= mg−k v2, which we

can express asdv

dt= 9.8− 0.0041 v2. A plot of the direction field can be found in Figure 1.5, along

with the equilibrium solution v = 49 m/sec.

21

Page 22: Ordinary Di erential Equations: Worked Examples with Solutionsegoins/notes/Ordinary_Differential_Equation… · Ordinary Di erential Equations: Worked Examples with Solutions Edray

Figure 1.5: Slope Field fordv

dt= 9.8− 0.0041 v2

0 25 50 75 100 125

-25

25

50

22

Page 23: Ordinary Di erential Equations: Worked Examples with Solutionsegoins/notes/Ordinary_Differential_Equation… · Ordinary Di erential Equations: Worked Examples with Solutions Edray

Chapter 2

Separable Equations and PopulationDynamics

2.1 Separable Equations

Problem 1. Find the general solution of the following differential equation. If possible, find anexplicit solution:

dy

dx=(1 + y2

)ex.

Solution. This is a separable equation:

dy

dx=(1 + y2

)ex

1

1 + y2dy = ex dx∫

1

1 + y2dy =

∫ex dx =⇒ arctan y = ex + C.

Hence the solution to the differential equation is y(x) = tan (ex + C) .

Problem 2. Find the exact solution of the following initial value problem. Indicate the interval ofexistence.

dy

dx=(1 + y2

)where y(0) = 1.

Solution. This equation is separable:

dy

dx= 1 + y2

dy

1 + y2= dx

arctan y = x+ C =⇒ y(x) = tan (x+ C) .

23

Page 24: Ordinary Di erential Equations: Worked Examples with Solutionsegoins/notes/Ordinary_Differential_Equation… · Ordinary Di erential Equations: Worked Examples with Solutions Edray

When x = 0 we want y = 1, so we choose C such that tanC = 1. This happens when C =π

4

(modulo multiples of π) so y(x) = tan(x+

π

4

). Now tanC is defined on the interval

(−π

2,π

2

)– notice that C =

π

4is in this interval – so we must have −π

2< x +

π

4<

π

2which implies

−3π

4< x <

π

4. Hence the interval of existence is

(−3π

4,π

4

).

Problem 3. Solve the initial value problemdy

dx= 2 (1+x) (1+y2) subject to y(0) = 0 and determine

where the solution attains its minimum value.

Solution. This differential equation is a separable equation:

dy

dx= 2 (1 + x)

(1 + y2

)1

1 + y2dy

dx= 2 + 2x

d

dx[arctan y] = 2 + 2x =⇒ arctan y = x2 + 2x+ C

for some constant C. Hence y(x) = tan(x2 + 2x+ C

)is the general solution. When x = 0, we

find that 0 = y(0) = tanC, so that C must be an integer multiple of π. Using the Angle AdditionFormula for tangent:

tan (θ + C) =tan θ + tanC

1− tan θ · tanC= tan θ

we have the explicit solution y(x) = tan(x2 + 2x

). This solution attains its minimum value when

its derivative vanishes. But y′ = 2 (1 + x) (1 + y2), and 2 (1 + y2) > 0, so this happens when

1 + x = 0. Hence the solution attains its minimum value when x = −1.

Problem 4. Consider the differential equationdy

dx=

1− 2x

y.

(a.) Find the solution y = y(x) corresponding to y(1) = −2.

(b.) Plot the graph of the solution.

(c.) Determine the interval in which the solution is defined.

Solution. This differential equation is a separable equation:

dy

dx=

1− 2x

y

y dy =(1− 2x

)dx∫

y dy =

∫ (1− 2x

)dx =⇒ y2

2= x− x2 + C

24

Page 25: Ordinary Di erential Equations: Worked Examples with Solutionsegoins/notes/Ordinary_Differential_Equation… · Ordinary Di erential Equations: Worked Examples with Solutions Edray

for some constant C. Upon evaluating at the point (x0, y0) = (1,−2) we find that C = 2. Hence

the solution to the initial value problem is y(x) = −√

2x− 2x2 + 4. Figure 2.1 has a plot of the

solution. The solution y = −√

2 (2− x) (1 + x) is defined when the factors 2 − x and 1 + x have

the same sign, so the solution is defined when −1 < x < 2.

Figure 2.1: Plot of y(x) = −√

2x− 2x2 + 4

-2 -1.5 -1 -0.5 0 0.5 1 1.5 2 2.5

-2.5

-2

-1.5

-1

-0.5

0.5

Problem 5. Solve the given initial value problemdy

dx= −4

x

ywhere y(0) = y0. Determine how the

interval in which the solution exists depends on the initial value y0.

Solution. This differential equation is a separable equation:

dy

dx= −4x

y

y dy = −4x dx∫y dy = −

∫4x dx =⇒ y2

2= −2x2 + C

for some constant C. Upon evaluating at the point (t0, y0) = (0, y0), we find that C =y0

2

2. Hence

we find the expression

y2

2= −2x2 +

y02

2=⇒ y(x) = ±

√y02 − 4x2.

25

Page 26: Ordinary Di erential Equations: Worked Examples with Solutionsegoins/notes/Ordinary_Differential_Equation… · Ordinary Di erential Equations: Worked Examples with Solutions Edray

This solution exists when |x| < 1

2|y0|. In particular, no solution exists if y0 = 0, so we must also

have y0 6= 0.

2.2 Autonomous Equations

In the three exercises below, an autonomous differential equation is given in the formdy

dx= f(y).

Perform each of the following tasks without the aid of technology.

(a.) Sketch a graph of f(y).

(b.) Use the graph of f to develop a phase line for the autonomous equation. Classify eachequilibrium point as either unstable or asymptotically stable.

(c.) Sketch the equilibrium solutions in the xy plane. These equilibrium solutions divide the xyplane into regions. Sketch at least one trajectory in each of these regions.

Problem 6.dy

dx= (y + 1) (y − 4).

Solution. Figure 2.2 has a graph of f(y) = (y + 1) (y − 4). The equilibrium solutions are y = −1and y = 4. Figure 2.3 has a graph of the phase line. We use the First Derivative Test to check for

the stability: since f(y) = (y + 1) (y − 4) = y2 − 3 y − 4 we havedf

dy= 2 y − 3. When y = −1 we

havedf

dy= −5 is negative, so that y = −1 is stable . When y = 4 we have

df

dy= 5 is positive, so

that y = 4 is unstable . Figure 2.4 has a graph of the trajectories in the various regions.

Problem 7.dy

dx= 6 + y − y2.

Solution. We have the factorization f(y) = 6 + y − y2 = − (y + 2) (y − 3). Figure 2.5 has a graphof f(y). The equilibrium solutions are y = −2 and y = 3. Figure 2.6 has a graph of the phaseline. We use the First Derivative Test to check for the stability: since f(y) = 6 + y − y2 we havedf

dy= 1− 2 y. When y = −2 we have

df

dy= 5 is positive, so that y = −2 is unstable . When y = 3

we havedf

dy= −5 is negative so that y = 3 is stable . Figure 2.7 has a graph of the trajectories in

the various regions.

Problem 8.dy

dx= y (y − 1) (y − 2).

Solution. Figure 2.8 has a graph of f(y) = y (y − 1) (y − 2). The equilibrium solutions are y = 0,y = 1, and y = 2. Figure 2.9 has a graph of the phase line. We use the First Derivative Test to checkfor the stability: since f(y) = y3−3 y2+2 y we have f ′(y) = 3 y2−6 y+2. The values of interest are

26

Page 27: Ordinary Di erential Equations: Worked Examples with Solutionsegoins/notes/Ordinary_Differential_Equation… · Ordinary Di erential Equations: Worked Examples with Solutions Edray

Figure 2.2: Plot of f(y) = (y + 1) (y − 4)

f ′(0) = 2 > 0, f ′(1) = −1 < 0 and f ′(2) = 2 > 0. Hence y = 0 and y = 2 are unstable equilibria ,

whereas y = 1 is a stable equilibrium. Figure 2.10 has a graph of the trajectories in the variousregions.

Problem 9. Draw a slope field for the differential equationdy

dx= 3− 2 y. Use this to determine the

behavior of y as x→∞. Does this behavior depends on the initial condition of y at x = 0?

Solution. Figure 2.11 contains a plot of the slope field for the differential equation. It is clear that

y → 3

2as x→∞, regardless of the initial condition of y.

Problem 10. Sometimes a constant equilibrium solution has the property that solutions lying on

27

Page 28: Ordinary Di erential Equations: Worked Examples with Solutionsegoins/notes/Ordinary_Differential_Equation… · Ordinary Di erential Equations: Worked Examples with Solutions Edray

Figure 2.3: Phase Line fordy

dx= (y + 1) (y − 4)

one side of the equilibrium solution tend to approach it, whereas solutions lying on the other sidedepart from it. In this case the equilibrium solution is said to be semistable.

(a.) Consider the equationdy

dx= k (1− y)2, where k is a positive constant. Show that yL = 1 is

the only critical point.

(b.) Sketch f(y) versus y. Show that y is increasing as a function of x for y < 1 and also fory > 1. Note: The phase line has upward-pointing arrows both below and above y = 1. Thussolutions below the equilibrium solution approach it, and those above it grow farther away.Therefore yL = 1 is semistable.

(c.) Solvedy

dx= k (1− y)2 subject to the initial condition y(0) = y0 and confirm the conclusions

reached in part (b).

Solution. Denote the function f(y) = k (1 − y)2. The critical points yL correspond to f(yL) = 0,so yL = 1 is the only critical point. Figure 2.12 contains a plot of f(y) = k (1− y)2 versus y. Saythat y = y(x) is a solution to the differential equation y′ = f(y). When y 6= 1 we have f(y) > 0, sothe derivative y′(x) is positive. Hence y is an increasing function of x whenever y 6= 1.

To solve the differential equation, divide both sides by (1− y)2:

dy

dx= k (1− y)2

(y − 1)−2 dy = k dt∫(y − 1)−2 dy =

∫k dt =⇒ − (y − 1)−1 = k t+ C

for some constant C. When t = 0, we have C = − (y0 − 1)−1. We may use this to explicitly solvefor y as a function of time:

− 1

y − 1= k t− 1

y0 − 1

1

y − 1= −(y0 − 1) k t− 1

y0 − 1

y − 1 =y0 − 1

1 + (1− y0) k t=⇒ y(t) = 1 +

y0 − 1

1 + (1− y0) k t=y0 + (1− y0) k t1 + (1− y0) k t

.

28

Page 29: Ordinary Di erential Equations: Worked Examples with Solutionsegoins/notes/Ordinary_Differential_Equation… · Ordinary Di erential Equations: Worked Examples with Solutions Edray

Figure 2.4: Plot of solutions tody

dx= (y + 1) (y − 4)

If y0 < 1 then (1 − y0) > 0 so that the denominator for y = y(t) does not vanish for t ≥ 0. As tincreases without bound, we see that y → 1. On the other hand, if y0 > 1 then (1− y0) < 0 so thatthe denominator for y = y(t) vanishes when t = 1/ ((y0 − 1) k) > 0. Hence there is a finite value oft for which y → ∞. We conclude that solutions y < 1 approach the limiting solution yL = 1, yetsolutions y > 1 grow farther away.

2.3 Population Growth Models

Problem 11. The size P (t) at t months of a certain population satisfies the differential equationdP

dt= 0.5 p− 450.

(a.) Find the time at which the population becomes extinct if P (0) = 850.

(b.) Find the time of extinction if P (0) = P0, where 0 < P0 < 900.

29

Page 30: Ordinary Di erential Equations: Worked Examples with Solutionsegoins/notes/Ordinary_Differential_Equation… · Ordinary Di erential Equations: Worked Examples with Solutions Edray

Figure 2.5: Plot of f(y) = 6 + y − y2

(c.) Find the initial population P0 if the population is to become extinct in 1 year.

Solution. The solution so the differential equation is P (t) = 900 + C et/2 for some constant C. IfP (0) = 850, then C = −50. The population becomes extinct when 0 = P (t) = 900− 50 et/2. This

gives et/2 =900

50= 18, so that the population becomes extinct when t = 2 ln 18 = 5.78074 months.

More generally, if P (0) = P0, then C = P0−900. The population becomes extinct when 0 = P (t) =

900 + (P0 − 900) et/2. This gives et/2 =900

900− P0, so that the population becomes extinct when

t = 2 ln900

900− P0months. If the population is to become extinct in 1 year, then P (12) = 0. This

gives 900 + (P0 − 900) e12/2 = 0, so that P0 = 900 (e6 − 1)/e6 = 897.769.

Problem 12. Suppose that you have a closed system containing 1000 individuals. A flu epidemicstarts. Let N(t) represent the number of infected individuals in the closed system at time t. Assume

30

Page 31: Ordinary Di erential Equations: Worked Examples with Solutionsegoins/notes/Ordinary_Differential_Equation… · Ordinary Di erential Equations: Worked Examples with Solutions Edray

Figure 2.6: Phase Line fordy

dx= 6 + y − y2

that the rate at which the number of infected individuals is changing jointly proportional to thenumber of infected individuals and the number of noninfected individuals. Furthermore, supposethat when 100 individuals are infected, the rate at which individuals are becoming infected is 90individuals per day. If 20 individuals are infected at time t = 0, when will 90% of the populationbe infected?

Solution. Assuming that there are only healthy individuals and sick individuals, if N(t) is thenumber of sick, then 1000 − N(t) is the number of healthy. Then there is a constant of propor-

tionality k such thatdN

dt= kN(t) (1000−N(t)). When N(t) = 100, we want N ′(t) = 90. Hence,

k = 90/ (100 · 900) = 1/1000 day−1. The differential equation is

dN

dt=

1

1000N (1000−N) =⇒ N(t) =

1

1/1000 + C e−t

where the time t is measured in days. If N(0) = 20, then we have C = 49/1000. Hence N(t) =1000

1 + 49 e−t.

We want to find the number of days t such that N(t) = 90% · 1000 = 900 individuals:

1000

1 + 49 e−t= 900 =⇒ et = 441 =⇒ t = 6.08904

Hence 90% of the population will be infected after approximately 6 days .

Problem 13. A population of bacteria, growing according to the Malthusian model, doubles itselfin 10 days. If there are 1,000 bacteria present initially, how long will it take the population to reach10,000?

Solution. Let P (t) denote the number of bacteria present at time t days. The Malthusian modelstates that there are constant P0 and r such that P (t) = P0 e

rt. Initially, there are 1000 bacteriapresent, so P0 = 1000. The population doubles itself in 10 days, so when t = 10 we have P (t) =

2000. Hence 2000 = 1000 e10r so that r =ln 2

10= 0.0693147. The time t it will take to reach

a population of 10,000 satisfies 10000 = 1000 ert, so t =ln 10

r= 33.2193. Hence it will take

33.2 days .

31

Page 32: Ordinary Di erential Equations: Worked Examples with Solutionsegoins/notes/Ordinary_Differential_Equation… · Ordinary Di erential Equations: Worked Examples with Solutions Edray

Figure 2.7: Plot of solutions tody

dx= 6 + y − y2

Problem 14. Suppose a population is growing according to the logistic equation

dP

dt= r P

(1− P

K

).

Prove that the rate at which the population is increasing is at its greatest when the population isat one-half of its carrying capacity.

Solution. The rate at which the population P is increasing is

f(P ) = r P

(1− P

K

)= r P − r

KP 2.

The rate at which the rate is increasing is

df

dt=

df

dP

dP

dt=[r − 2

r

KP] [r P − r

KP 2]

= r2 P

(1− 2P

K

)(1− P

K

).

32

Page 33: Ordinary Di erential Equations: Worked Examples with Solutionsegoins/notes/Ordinary_Differential_Equation… · Ordinary Di erential Equations: Worked Examples with Solutions Edray

Figure 2.8: Plot of f(y) = y (y − 1) (y − 2)

-0.25 0 0.25 0.5 0.75 1 1.25 1.5 1.75 2

-0.75

-0.5

-0.25

0.25

0.5

0.75

f'(y)>0 f'(y)>0

y=1y=0 y=2

f'(y)<0

Figure 2.9: Phase Line fordy

dx= y (y − 1) (y − 2)

-0.25 0 0.25 0.5 0.75 1 1.25 1.5 1.75 2

-0.75

-0.5

-0.25

0.25

0.5

0.75

f'(y)>0 f'(y)>0

y=1y=0 y=2

f'(y)<0

We find relative extrema when P = 0,K

2, and K; which gives the values f(P ) = 0,

rK

4, and

0, respectively. When P = 0, K the rate f(P ) = 0; but when P = K/2 the rate f(P ) > 0 is

increasing. Hence the rate at which the populaiton is increasing at the greatest is when P =K

2,

i.e., when the population is one-half its carrying capacity.

Problem 15. A population is observed to obey the logistic equation with the eventual population20,000. The initial population is 1,000, and 8 hours later, the observed population is 1,200. Findthe reproductive rate and the time required for the population to reach 75% of its carrying capacity.

Solution. Let P (t) denote the size of the population at time t hours. This function satisfies thedifferential equation

dP

dt= r P

(1− P

K

)=⇒ P (t) =

K P0

P0 + (K − P0) e−rt=

20000

1 + 19 e−rt,

33

Page 34: Ordinary Di erential Equations: Worked Examples with Solutionsegoins/notes/Ordinary_Differential_Equation… · Ordinary Di erential Equations: Worked Examples with Solutions Edray

Figure 2.10: Plot of solutions tody

dx= y (y − 1) (y − 2)

0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1 1.1 1.2 1.3 1.4

0.5

1

1.5

2

2.5

3

where r is the reproductive rate, P0 = 1, 000 is the initial population size, and K = 20, 000 is theeventual population size. When t = 8 we know that P (t) = 1200. We find that

1200 =20000

1 + 19 e−8r=⇒ e8r =

57

47=⇒ r = 0.024113 .

The time it will take to reach 75% of its carrying capacity is

75% · 20000 =20000

1 + 19 e−rt=⇒ ert = 57 =⇒ t = 167.671

Hence the time is 167.7 hours .

Problem 16. At a given level of effort, it is reasonable to assume that the rate at which fish arecaught depends on the population P : The more fish there are, the easier it is to catch them. Thuswe assume that the rate at which fish are caught is given by E P , where E is a positive constant,with units of 1/time, that measures the total effort made to harvest the given species of fish. Toinclude this effect, the logistic equation is replaced by

dP

dt= r

(1− P

K

)P − E P.

(a.) Show that if E < r, then there are two equilibrium points, namely P1 = 0 and P2 =

K

(1− E

r

)> 0.

34

Page 35: Ordinary Di erential Equations: Worked Examples with Solutionsegoins/notes/Ordinary_Differential_Equation… · Ordinary Di erential Equations: Worked Examples with Solutions Edray

Figure 2.11: Slope Field fordy

dx= 3− 2 y

-0.5 0 0.5 1 1.5 2 2.5 3 3.5 4

-1

-0.5

0.5

1

1.5

2

(b.) Show that P = P1 is an unstable equilibrium and P = P2 is a stable equilibrium.

(c.) A sustainable yield Y of the fishery is a rate at which fish can be caught indefinitely. It is theproduct of the effort E and the asymptotically stable population P2. Find Y as a function ofthe effort E; the graph of this function is known as the yield-effort curve.

(d.) Determine E so as to maximize Y and thereby find the maximum sustainable yield Ym.

Solution. Consider the function

f(P ) = r

(1− P

K

)y − E P = − r

KP 2 + (r − E)P = − r

KP

(P +

K (E − r)r

).

Hence P = 0 and P = −K (E − r)r

= K

(1− E

r

)are equilibrium points. (If E < r then

1 − E

r> 0.) We have the derivative f ′(P ) = −2 r

KP + (r − E), which shows f ′(P1) = r − E > 0

yet f ′(P2) = E − r < 0. Hence P = P1 is an unstable equilibrium whereas P = P2 is a stable

equilibrium. The sustainable yield is Y (E) = EK

(1− E

r

)= −K

rE2 +KE. This function has

a maximum when Y ′(E) = −2K

rE + K = 0, so that E =

r

2. Hence the maximum sustainable

yield is Ym =K r

2

(1− 1

2

)=K r

4.

35

Page 36: Ordinary Di erential Equations: Worked Examples with Solutionsegoins/notes/Ordinary_Differential_Equation… · Ordinary Di erential Equations: Worked Examples with Solutions Edray

Figure 2.12: Plot of f(y) = k (1− y)2

0 0.25 0.5 0.75 1 1.25 1.5 1.75 2 2.25

-0.5

-0.25

0.25

0.5

0.75

1

y=1

Problem 17. Some diseases (such as typhoid fever) are spread largely by “carriers”, individuals whocan transmit the disease but who exhibit no overt symptoms. Let S and I, respectively, denotethe proportion of susceptibles and carriers (i.e., infected) in the population, respectively. Suppose

that carriers are identified and removed from the population at a rate β, sodI

dt= −β I. Suppose

also that the disease spreads at a rate proportional to the product of S and I; thusdS

dt= −αS I.

(a.) Determine I(t) at any time t by solvingdI

dt= −β I subject to the initial condition I(0) = I0.

(b.) Use the result of part (a) to find S(t) at any time t by solvingdS

dt= −αS I subject to the

initial condition S(0) = S0.

(c.) Find the proportion of the population that escapes the epidemic by finding the limiting valueof S(t) as t→∞.

Solution. To determine I(t), we solve a separable equation:

dI

dt= −β I

1

IdI = −β dt∫

1

IdI = −

∫β dt

ln |I| = −β t+ C1 =⇒ I(t) = C e−βt

36

Page 37: Ordinary Di erential Equations: Worked Examples with Solutionsegoins/notes/Ordinary_Differential_Equation… · Ordinary Di erential Equations: Worked Examples with Solutions Edray

where C = ±eC1 is a constant. When t = 0 we have C = I0, so that I(t) = I0 e−βt. To determine

S(t), we solve another separable equation:

dS

dt= −αS · I0 e−βt

1

SdS = −α I0 e−βt dt∫

1

SdS = −

∫α I0 e

−βt dt

ln |S| = α I0β

e−βt + C1 =⇒ S(t) = C exp

[α I0β

e−βt]

where C = ±eC1 is a constant. When t = 0, we have

C = S0 exp

[−α I0

β

]=⇒ S(t) = S0 exp

[−α I0

1− e−βt

β

].

As time increases without bound, we have limt→∞

S(t) = S0 exp

[−α I0

β

].

2.4 Newton’s Law of Cooling

Problem 18. Newton’s law of cooling asserts that

the rate at which an object cools is proportional to the difference between the object’stemperature (T ) and the temperature of the surrounding medium (T∞).

Let’s suppose that the ambient temperature is T∞ = 70◦F and that the rate constant is 0.05(min)−1. Write a differential equation for the temperature of the object at any time.

Solution. Let T (t) denote the temperature of the object in ◦F at any time t in minutes. Newton’s

law of cooling states thatdT

dtis proportional to T − 70◦F, so say that

dT

dt= r (T − 70◦F) for some

constant r. We know that |r| = 0.05 (min)−1, so we determine the sign of r. If T > 70◦F then the

object will cool i.e.,dT

dt< 0. Hence r must be a negative constant. The differential equation must

bedT

dt= −0.05 (T − 70).

Problem 19. Assuming Newton’s Law of Cooling, show that T (t) = T∞ + (T0 − T∞) ert, where T0is the temperature of the body at time t = 0 and r is the proportionality constant.

Solution. Newton’s law of cooling is equivalent to the differential equation T ′ ∝ (T − T∞), i.e.,T ′ = r (T − T∞). Note that if T > T∞ then the object will cool, i.e., T ′ < 0, whereas if T < T∞

37

Page 38: Ordinary Di erential Equations: Worked Examples with Solutionsegoins/notes/Ordinary_Differential_Equation… · Ordinary Di erential Equations: Worked Examples with Solutions Edray

then the object will warm up, i.e., T ′ > 0. Hence r is a negative constant of proportionality. Thisequation is separable:

dT

dt= r (T − T∞)

dT

T − T∞= −k dt

ln |T − T∞| − ln |T0 − T∞| = r dt

ln

∣∣∣∣ T − T∞T0 − T∞

∣∣∣∣ = r t∣∣∣∣ T − T∞T0 − T∞

∣∣∣∣ = ert =⇒ T − T∞T0 − T∞

= ±ert

When t = 0 we see that the left-hand side is 1, so we must choose the positive sign on the right-hand

side. HenceT (t)− T∞T0 − T∞

= ert, so that T (t) = T∞ + (T0 − T∞) ert.

Problem 20. A murder victim is discovered at midnight and the temperature of the body is recordedat 31◦C. One hour later, the temperature of the body is 29◦C. Assume that the surrounding airtemperature remains constant at 21◦C. Calculate the victim’s time of death. Note: The “normal”temperature of a living human being is approximately 37◦C.

Solution. Assume that the temperature of the body at time t is

T (t) = T∞ + (T0 − T∞) e−kt,

where T∞ = 21◦C and T0 = 37◦C. We denote t0 = 0 the time when the victim died, t1 the timein minutes that has elapsed since the body was recorded to be T (t1) = 31◦C, and t2 = 60 + t1 tobe the time when the body was discovered to be T (t2) = 29◦C. We want to solve for t1. First wesolve for k. Consider the two equations

T (t1)− T∞ = (T0 − T∞) e−k t1

T (t2)− T∞ = (T0 − T∞) e−k t2=⇒ T (t1)− T∞

T (t2)− T∞= ek(t2−t1).

Upon taking the logarithms of both sides, we can solve for the proportionality constant:

k =1

t2 − t1lnT (t1)− T∞T (t2)− T∞

=1

60ln

31− 21

29− 21= 0.00371906 minutes−1.

Now we solve for t1. We have

T (t1)− T∞ = (T0 − T∞) e−k t1 =⇒ ek t1 =T0 − T∞T (t1)− T∞

=⇒ t1 =1

kln

T0 − T∞T (t1)− T∞

.

Hence

t1 = 60 · ln37− 21

31− 21

/ln

31− 21

29− 21= 126.377 minutes.

In other words, at midnight the victim had been dead for 126 minutes, so the victim died at9:54 PM .

38

Page 39: Ordinary Di erential Equations: Worked Examples with Solutionsegoins/notes/Ordinary_Differential_Equation… · Ordinary Di erential Equations: Worked Examples with Solutions Edray

2.5 Radioactive Decay

Problem 21. The half-life of a radioactive material is the time required for an amount of thismaterial to decay to one-half its original value. Show that for any radioactive material that decays

according to the equationdQ

dt= −r Q, the half-life τ and the decay rate r satisfy the equation

r τ = ln 2.

Solution. First, we solve the differential equation:

dQ

dt= −r Q

1

QdQ = −r dt∫

1

QdQ = −

∫r dt

ln |Q| = −r t+ C1 =⇒ Q(t) = Q0 e−rt

for some constant Q0 = ±eC1 . The half-life τ is that time such that Q(τ) = 0.5Q0. We have theequation Q0 e

−rτ = 0.5Q0 so that erτ = 2. Upon taking logarithms, we find that r τ = ln 2.

Problem 22. Radium-266 has a half-life of 1620 years. Using the previous problem, find the timeperiod during which a given amount of this material is reduced by one-quarter.

Solution. Let Q(t) denote the amount of some given initial amount Q0 of Radium-266 after tyears. We know that Q(t) = Q0 e

−rt for some decay rate r. The half-life is τ = 1620 yr, so

we have r τ = ln 2, so that r =ln 2

τ= 0.000428 yr−1. We wish to find the time t such that

Q(t) = Q0 −1

4Q0 = 0.75Q0. We have the equation Q0 e

−rt = 0.75Q0, so that ert =4

3. Hence

t =ln(4/3)

0.000428= 672.361 yr.

Problem 23. The isotope Iodine 131 is used to destroy tissue in an overactive thyroid gland. It hasa half-life of 8.04 days. If a hospital receives a shipment of 500 mg of 131I, how much of the isotopewill be left after 20 days?

Solution. Let N(t) denote the amount of 131I; then N(t0) = 500 mg when t0 = 0 days. This amount

satisfies the differential equationdN

dt= −r N for some decay rate r which we will find later. This

equation is separable, so we find that N(t) = 500 e−rt. Now we solve for the decay rate r. From the

definition of half-life, when t1 = 8.04 days we have N(t1) =1

2N(0), so 250 = 500 e−8.04 r. Taking

39

Page 40: Ordinary Di erential Equations: Worked Examples with Solutionsegoins/notes/Ordinary_Differential_Equation… · Ordinary Di erential Equations: Worked Examples with Solutions Edray

logarithms gives ln 250 = ln 500− 8.04 r, so that r =ln 2

8.04= 0.0862123 days−1. Hence the amount

left after t2 = 20 days is

N(t2) = 500 e−r 20 = 500 e−0.0862123·20 = 5.60829 mg .

Problem 24. Suppose that the ratio of 14C to carbon in the charcoal on a cave wall is 0.617 times asimilar ratio in living wood in the area. Use the Libby half-life to estimate the age of the charcoal.

Solution. We use the formula found in the previous problem, where R(t) = R0 e−rt. We want

to solve for t when R(t) = 0.617 · R0. We have 0.617 · R0 = R0 e−r t, so that t = − ln 0.617

r=

3878.99 years. Hence the age of the charcoal is approximately 3879 years .

40

Page 41: Ordinary Di erential Equations: Worked Examples with Solutionsegoins/notes/Ordinary_Differential_Equation… · Ordinary Di erential Equations: Worked Examples with Solutions Edray

Chapter 3

Exact Equations and IntegratingFactors

3.1 Exact Equations

Verify that the following equations are exact, and then find the solution.

Problem 1.(2x y2 + 2 y

)dx+

(2x2 y + 2x

)dy = 0.

Solution. Denote the functions

P (x, y) = 2x y2 + 2 y

Q(x, y) = 2x2 y + 2x

=⇒

∂P

∂y= 4x y + 2

∂Q

∂x= 4x y + 2

Hence the equation is indeed exact . We find a solution in the form F (x, y) = C for the differentialequation. Define the functions

G(x, y) =

∫P (x, y) dx = x2 y2 + 2x y,

H(y) =

∫ [Q(x, y)− ∂G

∂y

]dy =

∫ [(2x2 y + 2x

)−(2x2 y + 2 y

)]dy = 0;

and set F (x, y) = G(x, y) +H(y). Hence the solution is x2 y2 + 2x y = C.

Problem 2.x

(x2 + y2)3/2dx+

y

(x2 + y2)3/2dy = 0.

Solution. Denote the functions

P (x, y) =x

(x2 + y2)3/2and Q(x, y) =

y

(x2 + y2)3/2.

41

Page 42: Ordinary Di erential Equations: Worked Examples with Solutionsegoins/notes/Ordinary_Differential_Equation… · Ordinary Di erential Equations: Worked Examples with Solutions Edray

We compute the partial derivatives

∂P

∂y=

∂y

[x(x2 + y2

)−3/2]= −3

2· x(x2 + y2

)−5/2 · 2 y = − 3x y

(x2 + y2)5/2;

∂Q

∂x=

∂x

[y(x2 + y2

)−3/2]= −3

2· y(x2 + y2

)−5/2 · 2x = − 3x y

(x2 + y2)5/2.

Hence the equation is indeed exact. We find a solution in the form F (x, y) = C for the differentialequation. Define the functions

G(x, y) =

∫P (x, y) dx =

∫x

(x2 + y2)3/2dx = − 1√

x2 + y2,

H(y) =

∫ [Q(x, y)− ∂G

∂y

]dy =

∫ [y

(x2 + y2)3/2− y

(x2 + y2)3/2

]dy = 0;

and set F (x, y) = G(x, y) + H(y). Hence the solution is F (x, y) = C1 in terms of some constant

C1, which we can write as x2 + y2 = C for some constant C = C1−2.

Problem 3.x√

x2 + y2dx+

y√x2 + y2

dy = 0.

Solution. Denote P (x, y) =x√

x2 + y2and Q(x, y) =

y√x2 + y2

. We have the partial derivative

∂P

∂y=

∂yx(x2 + y2

)−1/2= −x

2

(x2 + y2

)−3/2 · 2 y = − x y√x2 + y2

3

and so by symmetry∂P

∂y= − x y√

x2 + y23 =

∂Q

∂x. Hence the equation indeed is exact. It is easy

to verify that for F (x, y) =√x2 + y2 we have

∂F

∂x= P and

∂F

∂y= Q. Hence the solution to the

differential equation is x2 + y2 = C for some constant C.

Problem 4. Find the function y = y(x) satisfying the differential equation (2x− y) dx+(2 y − x) dy =0 as well as the initial condition y(1) = 3. For what values x is this function valid?

Solution. First we verify that this differential equation is exact. Denote the functions

P (x, y) = 2x− y

Q(x, y) = 2 y − x

=⇒

∂P

∂y= −1

∂Q

∂x= −1

42

Page 43: Ordinary Di erential Equations: Worked Examples with Solutionsegoins/notes/Ordinary_Differential_Equation… · Ordinary Di erential Equations: Worked Examples with Solutions Edray

Now we compute F (x, y) = G(x, y) +H(y) in terms of the functions

G(x, y) =

∫P (x, y) dx = x2 − x y,

H(y) =

∫ [Q(x, y)− ∂G

∂y

]dy =

∫[(2 y − x)− (−x)] dy =

∫2 y dy = y2.

Hence F (x, y) = G(x, y) +H(y) = x2 − x y + y2, so that the desired solution y = y(x) satisfies theimplicit relation x2−x y+y2 = C for some constant C. Since y(1) = 3, we see that C = F (1, 3) = 7.

Hence y(x) =1

2

(x+

√28− 3x2

). This solution is valid when 28 − 3x2 ≥ 0, which is the same

as saying |x| ≤√

28

3.

Problem 5. Find the value of b for which the given equation is exact, and then solve it using thatvalue of b. (

x y2 + b x2 y)dx+ (x+ y)x2 dy = 0.

Solution. Denote the functions

P (x, y) = x y2 + b x2 y

Q(x, y) = (x+ y)x2 = x3 + x2 y

=⇒

∂P

∂y= 2x y + b x2

∂Q

∂x= 3x2 + 2x y

The differential equation is exact when these derivatives are equal. They are equal when b = 3. Wesolve the differential by constructing a function F (x, y) = G(x, y) +H(y). We define the functions

G(x, y) =

∫P (x, y) dx =

1

2x2 y2 + x3 y,

H(y) =

∫ [Q(x, y)− ∂G

∂y

]dy =

∫ [(x3 + x2 y

)−(x2 y + x3

)]dy = 0.

The solution of the original differential equation is F (x, y) = C, which we can write in the form

x2 y2 + 2x3 y = C .

3.2 Equidimensional Equations

Problem 6. Find the general solution of the equidimensional equation below.(x2 + y2

)dx− 2x y dy = 0.

43

Page 44: Ordinary Di erential Equations: Worked Examples with Solutionsegoins/notes/Ordinary_Differential_Equation… · Ordinary Di erential Equations: Worked Examples with Solutions Edray

Solution. We make the substitution y = t x to find a separable differential equation:(x2 + y2

)dx− 2x y dy = 0

dy

dx=x2 + y2

2x y

dt

dxx+ t =

1 + t2

2 t=⇒ dx

dt=

2 t x

1− t2.

We find the general solution to this equation:

dx

dt=

2 t x

1− t2

1

xdx =

2 t

1− t2dt

ln |x| = − ln∣∣1− t2∣∣+ C1 =⇒ x = C

1

1− t2

for some constant C = ±eC1 . Substituting t =y

xwe find the equation x2 − y2 = C x .

Problem 7. Find the general solution to the homogeneous equation below.

(x+ y) dx+ (y − x) dy = 0.

Solution. We make the substitution y = t x to find a separable differential equation:

(x+ y) dx+ (y − x) dy = 0

dy

dx=x+ y

x− y

dt

dxx+ t =

1 + t

1− t=⇒ dx

dt=

1− t1 + t2

x.

We find the general solution to this equation:

dx

dt=

1− t1 + t2

x

1

xdx =

1− t1 + t2

dt

ln |x| = arctan t− 1

2ln∣∣1 + t2

∣∣+ C1 =⇒ t = tan(

ln |x|√

1 + t2 − C1

).

This can be simplified a bit. Recall the formula

tan (A−B) =tanA− tanB

1 + tanA tanB=⇒

x tan(

ln√x2 + y2

)− y

y tan(

ln√x2 + y2

)+ x

= C

where C = tanC1 is a constant.

44

Page 45: Ordinary Di erential Equations: Worked Examples with Solutionsegoins/notes/Ordinary_Differential_Equation… · Ordinary Di erential Equations: Worked Examples with Solutions Edray

3.3 Bernoulli Equations

Problem 8. Show that the change of variable, z = y1−n, will transform the Bernoulli equationdy

dx= P (x) y + Q(x) yn into the linear equation

dz

dx= (1 − n)P (x) z + (1 − n)Q(x). Here, we

assume that n 6= 1.

Solution. If we substitute z = y1−n, then we havedz

dx= (1− n) y−n

dy

dx, and so

dy

dx=

1

1− nyn

dz

dx.

Note that y = z yn. Hence the equationdy

dx= P (x) y + Q(x) yn transforms to

1− nyn

dz

dx=

P (x) z yn +Q(x) yn, so thatdz

dx= (1− n)P (x) z + (1− n)Q(x) as claimed.

Use the technique of the previous exercise to transform the Bernoulli equations into a linearequation. Find the general solution of the resulting linear equation.

Problem 9.dP

dx= aP − b P 2, assuming that a and b are constants.

Solution. We set n = 2 and z = P−1. Then we have P =1

z, P 2 =

1

z2, and

dP

dx= − 1

z2dz

dx. Hence

the equationdP

dx= aP − b P 2 transforms to − 1

z2dz

dx=a

z− b

z2, which simplifies to

dz

dx+ a z = b .

In order to solve this equation, we multiply by the integrating factor µ(x) = eax:

d

dx

[µ(x) z

]= µ(x)

dz

dx+dµ

dxz = eax

(dz

dx+ a z

)= b eax.

Upon integrating we find µ(x) z =b

aeax + C1, and soz(x) =

b

a+ C1 e

−at for some constant C1.

Hence P (x) =1

z(x)=

a

b+ C e−axfor some constant C = C1/a.

Problem 10. x2dy

dx+ 2x y − y3 = 0.

Solution. We sat n = 3 and z = y−2. Then we have y = z−1/2 anddy

dx= −1

2z−3/2

dz

dx. We

substitute these values into the differential equation:

x2dy

dx+ 2x y = y3

x2[−1

2z−3/2

dz

dx

]+ 2x

[z−1/2

]=[z−1/2

]3−x

2

2

dz

dx+ 2x z = 1 =⇒ dz

dx− 4

xz = − 2

x2.

45

Page 46: Ordinary Di erential Equations: Worked Examples with Solutionsegoins/notes/Ordinary_Differential_Equation… · Ordinary Di erential Equations: Worked Examples with Solutions Edray

This differential equation is linear, so we may solve it using integrating factors. We compute

µ(x) = exp

(−∫

4

xdx

)= exp (−4 ln |x|) =

1

x4.

Multiply the differential equation above by this function:

dz

dx− 4

xz = − 2

x2

1

x4dz

dx− 4

x5z = − 2

x6

d

dx

[1

x4· z]

= − 2

x6=⇒ 1

x4· z =

2

5x5+ C

for some constant C. Hence, the solution to the differential equation is

z(x) =2 + 5C x5

5x=⇒ y(x) =

1√z(x)

= ±√

5x

2 + 5C x5.

3.4 Integrating Factors

Problem 11. The differential equation 3 (y + 1) dx − 2x dy = 0 is not exact. Verify that µ(x, y) =y + 1

x4integrating factor, then solve the resulting exact equation.

Solution. The resulting differential equation is

3 (y + 1)2

x4dx− 2 (y + 1)

x3dy = 0.

First we verify that this equation is indeed an exact equation. Denote

P (x, y) =3 (y + 1)2

x4

Q(x, y) = −2 (y + 1)

x3

=⇒

∂P

∂y

6 (y + 1)

x4

∂Q

∂x=

6 (y + 1)

x4

We seek a function F (x, y) = G(x, y) +H(y) such that

∂F

∂x= P (x, y) and

∂F

∂y= Q(x, y).

Define the functions

G(x, y) =

∫P (x, y) dx = −(y + 1)2

x3,

H(y) =

∫ [Q(x, y)− ∂G

∂y

]dy =

∫ [−2 (y + 1)

x3+

2 (y + 1)

x3

]dy = 0.

Hence F (x, y) = −(y + 1)2

x3= C, so the corresponding solution is (y + 1)2 + C x3 = 0 for some

constant C.

46

Page 47: Ordinary Di erential Equations: Worked Examples with Solutionsegoins/notes/Ordinary_Differential_Equation… · Ordinary Di erential Equations: Worked Examples with Solutions Edray

3.5 Linear Equations

Problem 12. For the following differential equation, find an integrating factor and solve the givenequation.

dy

dx= e2x + y − 1.

Solution. This is a linear equation because it can be expressed in the form y′ − y = e2x − 1, so

µ(x) = e−x is an integrating factor. We see that the solution is y = C ex + 1 + e2x where C is aconstant.

Problem 13. Find the function y(x) satisfyingdy

dx− 2 y = e2x subject to the initial condition

y(0) = 2.

Solution. This is a linear differential equation, so an integrating factor is µ(x) = e−2x. We multiplyboth sides of the original differential equation by this function:

dy

dx− 2 y = e2x

e−2xdy

dt− 2 e−2x y = 1

d

dx

[e−2x y

]= 1 =⇒ e−2x y(x) = x+ C

for some constant C. This constant is uniquely determined by the initial condition: C = y(0) = 2

so that y(t) = (x+ 2) e2t.

Problem 14. Show that all solutions of 2dy

dx+ x y = 2 approach a limit as x → ∞, and find the

limiting value. Hint: Find the general solution then use l’Hopital’s rule.

Solution. This is a linear differential equation, and an integrating factor is the function µ(x) =1

2exp

(x2

4

). We multiply both sides of the original differential equation by this function:

2dy

dx+ x y = 2

ex2/4 dy

dx+x

2ex

2/4 y = ex2/4

d

dx

[ex

2/4 y]

= ex2/4 =⇒ ex

2/4 y(x) =

∫ x

0et

2/4 dt+ C

for some constant C. Hence the general solution to the differential equation is y(x) = e−x2/4

∫ x

0es

2/4 ds+

C e−x2/4. In order to compute the limiting value as x increases without bound, we consider the

47

Page 48: Ordinary Di erential Equations: Worked Examples with Solutionsegoins/notes/Ordinary_Differential_Equation… · Ordinary Di erential Equations: Worked Examples with Solutions Edray

limit

limx→∞

y(x) = limx→∞

f(x)

g(x)in terms of f(x) =

∫ x

0et

2/4 dt and g(x) = ex2/4,

which is independent of C. Since limx→∞

f(x) = limx→∞

g(x) = ∞, we may compute the limit of the

ratio using l’Hopital’s Rule. We compute the derivatives

f ′(x) = ex2/4 and g′(x) =

x

2ex

2/4 =⇒ limx→∞

f(x)

g(x)= lim

x→∞

f ′(x)

g′(x)= lim

x→∞

2

x= 0.

Hence every solution y(x)→ 0 as x→∞.

3.6 Loan Calculations

Problem 15. Clarissa wants to buy a new car. Her loan officer tells her that her annual rate is8%, compounded continuously, over a four-year term. Clarissa informs her loan officer that she canmake equal monthly payments of $225. How much can Clarissa afford to borrow?

Solution. Let S(t) denote the amount of the loan at time t years. Clarissa makes yearly payments

of $225 · 12 = $2700 to pay off the loan, so this function satisfies the differential equationdS

dt=

0.08S − 2700. Note that S(0) is the amount that Clarissa borrows. First we solve this differentialequation by multiplying by the integrating factor µ(t) = e−0.08 t:

d

dt

[µ(t)S

]= µ(t)

(dS

dt− 0.08S

)= −2700µ(t) =⇒ S(t) = 33750 + C e0.08 t.

Now at the end of four years, this loan amount should be zero. Hence, we want S(4) = 0, so thatwe have the equation 33750 + C e0.08·4 = 0, implying that C = −24507.53. Finally, the amount

that Clarissa can borrow is S(0) = 33750 + C = $9242.47 .

Problem 16. Jamal wishes to invest an unknown sum in an account where interest is compoundedcontinuously. Assuming that Jamal makes no additional deposits or withdrawals, what annualinterest rate will allow his initial investment to double in exactly five years?

Solution. Let S(t) denote the sum of money in the account at time t years. Then if r is the annual

interest rate, this function satisfies the differential equationdS

dt= r S, so that S(t) = S0 e

rt. We

want S(5) = 2S0, so we find

2S0 = S0 e5r =⇒ 2 = e5r =⇒ 5 r = ln 2 =⇒ r =

ln 2

5= 0.13862

Hence the annual interest rate should be 13.9% .

48

Page 49: Ordinary Di erential Equations: Worked Examples with Solutionsegoins/notes/Ordinary_Differential_Equation… · Ordinary Di erential Equations: Worked Examples with Solutions Edray

Problem 17. Don and Heidi would like to purchase a new home. They’ve examined their budgetand determined that they can afford monthly payments of $1000. If the annual interest is 7.25%,and the term of the loan is 30 years, what amount can they afford to borrow?

Solution. Let S(t) denote the amount of the loan at time t years. Don and Heidi make annualpayments of $1, 000 · 12 = $12, 000, so that the function S(t) satisfies the differential equationdS

dt= 0.0725S − 12000. Note that P (0) is the amount that Don and Heidi borrow. First we solve

this differential equation by multiply by the integrating factor µ(t) = e−0.0725 t:

d

dt

[µ(t)S

]= µ(t)

(dS

dt− 0.0725S

)= −12000µ(t)

so that S(t) = 165517.24 +C e0.0725 t. Now at the end of 30 years this loan amount should be zero.Hence we want 0 = S(30) = 165517.24 + C e0.0725·30, so that C = −18804.11. Finally, the amount

that Don and Heidi can borrow is S(0) = 165517.24 + C = $146,713.13 .

Problem 18. A certain college graduate borrows $8000 to buy a car. The lender charges interest atan annual rate of 10%. Assuming that interest is compounded continuously and that the borrowermakes payments continuously at a constant annual rate D, determine the payment rate D that isrequired to pay off the loan in 3 years. Also determine how must interest is paid during the 3-yearperiod.

Solution. Let S(t) denote the amount of the loan at t years. Initially S(0) = $8000, and we wishto have S(3) = $0. If r = 10% is the annual percentage rate of the loan, the rate of change of thisloan is given by the initial value problem

dS

dt− 0.10S = −D where S(0) = $8000.

We solve this problem using integrating factors. Multiplying this equation by µ(t) = e−0.10t wefind that

dS

dt− 0.10S = −D

e−0.10tdS

dt− 0.10 e−0.10t S = −De−0.10t

d

dt

[e−0.10t S

]= −De−0.10t =⇒ e−0.10t S(t) = 10De−0.10t + C

for some constant C. Upon substituting t = 0, it is easy to see that C = $8000 − 10D, so thesolution to the initial value problem is the function

S(t) = 10 k + C e0.10t = $8000 e0.10t − 10D(e0.10t − 1

).

Upon substituting t = 3, we wish to have S(3) = $0, so we find that

8000 e0.3 − 10D(e0.3 − 1

)= 0 =⇒ D =

8000 e0.3

10 (e0.3 − 1)= $3086.64/year.

49

Page 50: Ordinary Di erential Equations: Worked Examples with Solutionsegoins/notes/Ordinary_Differential_Equation… · Ordinary Di erential Equations: Worked Examples with Solutions Edray

The total amount borrowed over the 3-year period is S(0)− S(3) = $8000. The total amount paidfor the loan over this period is 3D = $9259.92. Hence the total amount paid towards interest

during the 3-year period is 3D − $8000 = $1259.92.

3.7 Diffusion Problems

Problem 19. A tank contains 100 gal of pure water. A salt solution with concentration 3 lb/galenters the tank at a rate of 2 gal/min. Solution drains from the tank at a rate of 2 gal/min. Usequalitative analysis to find the eventual concentration of the salt solution in the tank.

Solution. Let Q(t) denote the quantity of salt in the tank at time t minutes. We list the relevantinformation in the following table.

Flow Rate Concentration Rate

In 2 gal/min 3 lb/gal 6 lb/min

Out 2 gal/min Q(t)/100 lb/gal Q(t)/50 lb/min

The amount of salt satisfies the initial value problem

dQ

dt= 6− Q

50where Q(0) = 0.

This is an autonomous equation, so over time we find the equilibrium point QL = limt→∞

Q(t) that

satisfies 6 − QL50

= 0, so that QL = 300 lb. Hence the eventual concentration is c∞ = QL/100 =

3 lb/gal .

Problem 20. A 50 gal tank initially contains 20 gal of pure water. Salt-water solution containing 0.5lb of salt for each gallon of water begins entering the tank at a rate of 4 gal/min. Simultaneously,a drain is opened at the bottom of the tank, allowing the salt-water solution to leave the tank atrate of 2 gal/min. What is the salt content (lb) in the tank at the precise moment that the tank isfull of salt-water solution?

Solution. Let Q(t) denote the quantity of salt in pounds in the tank at time t minutes, and V (t) =20+2 t as the volume of water in the tank at time t. We make a chart with the relevant information.

Flow Rate Concentration Rate

In 4 gal/min 0.5 lb/gal 2 lb/min

Out 2 gal/min Q(t) lb/ V (t) gal Q(t)/(10 + t) lb/min

50

Page 51: Ordinary Di erential Equations: Worked Examples with Solutionsegoins/notes/Ordinary_Differential_Equation… · Ordinary Di erential Equations: Worked Examples with Solutions Edray

We have the initial value problem

dQ

dt= 2− Q

10 + twhere Q(0) = 0.

We multiply by µ(t) = 10 + t to find the equation

d

dt

[µ(t)Q

]= µ

dQ

dt+dµ

dtQ = (10 + t)

(dQ

dt+

Q

10 + t

)= 20 + 2 t.

Upon integrating we find µ(t)Q(t) = 20 t + t2 + C for some constant C. When t = 0 we want

Q(t) = 0, so C = 0. This gives Q(t) =20 t+ t2

10 + t. The tank is full of salt-water solution when

V (t) = 50, so 50 = 20 + 2 t yields t = 15 min. Hence we find that the amount of salt is Q(15) =20 · 15 + 152

10 + 15= 21 lb .

Problem 21. Suppose that a solution containing a drug enters a bodily organ at the rate a cm3/s,with drug concentration κ g/cm3. Solution leaves the organ at a slower rate of b cm3/s. Further, thefaster rate of infusion causes the organ’s volume to increase with time according to V (t) = V0 + r t,with V0 its initial volume. If there is no initial quantity of the drug in the organ, show that theconcentration of the drug in the organ is given by

c(t) =a κ

b+ r

[1−

(V0

V0 + r t

)(b+r)/r].

Solution. Let Q(t) denote the quantity of the drug (g) in the organ at t seconds. Note thatc(t) = Q(t)/V (t) is the concentration of the drug in the organ – assuming that we have instantaneousmixing. We make a chart with the relevant information.

Flow Rate Concentration Rate

In a cm3/s κ g/cm3 a κ g/s

Out b cm3/s c(t) g/cm3 bQ(t)/V (t) g/s

Hence the differential equation is

dQ

dt= a κ− bQ

V0 + r twhere Q(0) = 0.

We choose the integrating factor

µ(t) = exp

[∫b

V0 + r tdt

]= exp

[b

rln

(V0r

+ t

)+ C1

]= (V0 + r t)b/r .

(We chose the constant C1 =b

rln r.) Note that µ(t) = V (t)b/r. We have the product

d

dt

[µ(t)Q

]= µ

dQ

dt+dµ

dtQ = µ(t)

(dQ

dt+

bQ

V0 + r t

)= a κ (V0 + r t)b/r

51

Page 52: Ordinary Di erential Equations: Worked Examples with Solutionsegoins/notes/Ordinary_Differential_Equation… · Ordinary Di erential Equations: Worked Examples with Solutions Edray

so upon integrating we find

µ(t)Q(t) =

∫a κ (V0 + r t)b/r dt =

a κ

b+ r(V0 + r t)(b+r)/r + C2.

We want Q(0) = 0, so the constant

C2 = − a κ

b+ r(V0)

(b+r)/r =⇒ µ(t)Q(t) =a κ

b+ r

[(V0 + r t)(b+r)/r − (V0)

(b+r)/r].

Hence the concentration is

c(t) =Q(t)

V (t)=

µ(t)Q(t)

(V0 + r t)(b+r)/r=

a κ

b+ r

[1−

(V0

V0 + r t

)(b+r)/r].

Problem 22. Consider two tanks, labeled tank A and tank B for reference. Tank A contains 100gal of solution in which is dissolved 20 lb of salt. Tank B contains 200 gal of solution in which isdissolved 40 lb of salt. Pure water flows into tank A at a rate of 5 gal/s. There is a drain at thebottom of tank A. Solution leaves tank A via this drain at a rate of 5 gal/s, and flows immediatelyinto tank B at the same rate. A drain at the bottom of tank B allows the solution to leave tankB at a rate of 2.5 gal/s. What is the salt content in tank B at the precise moment that tank Bcontains 250 gal of solution?

Solution. Let QA(t) denote the quantity of salt in tank A at time t seconds, and QB(t) as thequantity of salt in tank B at time t seconds. Then tank A contains a constant volume of 100 galof solution, whereas tank B has a volume of V (t) = 200 + 2.5 t. We make a chart with the relevantinformation.

Tank A Flow Rate Concentration Rate

In 5 gal/s 0 lb/gal 0 lb/s

Out 5 gal/s QA(t) lb/ 100 gal QA(t)/20 lb/s

Tank B Flow Rate Concentration Rate

In 5 gal/s QA(t) lb/ 100 gal QA(t)/20 lb/s

Out 2.5 gal/s QB(t) lb/ V (t) gal QB(t)/(80 + t) lb/s

The differential equations are

dQAdt

= −QA20

,dQBdt

=QA20− QB

80 + t, QA(0) = 20, QB(0) = 40.

52

Page 53: Ordinary Di erential Equations: Worked Examples with Solutionsegoins/notes/Ordinary_Differential_Equation… · Ordinary Di erential Equations: Worked Examples with Solutions Edray

It is clear that QA(t) = 20 e−t/20, so that QB(t) satisfies the differential equationdQBdt

+QB

80 + t=

e−t/20. Upon multiplying by the integrating factor µ(t) = 80 + t we find that

d

dt

[µ(t)QB

]= µ

dQBdt

+dµ

dtQB = (80 + t)

(dQBdt

+QB

80 + t

)= (80 + t) e−t/20.

We integrate to find

µ(t)QB(t) =

∫(80 + t) e−t/20 dt = −20 (100 + t) e−t/20 + C.

When t = 0 we have µ(t) = 80 and we want QB(t) = 40, so that C = 5200. This implies QB(t) =5200

80 + t− 20

100 + t

80 + te−t/20. Tank B contains 250 gal of solution when V (t) = 250 = 200 + 2.5 t, so

t = 20 s. The amount of salt in tank B at this time is

QB(20) =5200

80 + 20− 20

100 + 20

80 + 20e−20/20 = 52− 24 e−1 = 43.1709 lb .

Problem 23. Consider a lake of constant volume V containing at time t an amount Q(t) of pollutant,evenly distributed throughout the lake with a concentration c(t), where c(t) = Q(t)/V . Assumethat water containing a concentration k of pollutant enters the lake at a rate r, and that waterleaves the lake at the same rate. Suppose that pollutants are also added directly to the lake ata constant rate P . Note that the given assumptions neglect a number of factors that may, insome cases, be important — for example, the water added or lost by precipitation, absorption,and evaporation; the stratifying effect of temperature differences in a deep lake; the tendencyof irregularities in the coastline to produce sheltered bays; and the fact that pollutants are notdeposited evenly throughout the lake but (usually) as isolated points around its periphery. Theresults below must be interpreted in the light of the neglect of such factors as these.

(a.) If at time t = 0 the concentration of pollutant is c0, find an expression for the concentrationc(t) at any time. What is the limiting concentration as t→∞?

(b.) If the addition of pollutants to the lake is terminated (k = 0 and P = 0 for t > 0), determinethe time interval T that must elapse before the concentration of pollutants is reduced to 50%of its original value; to 10% of its original value.

Solution. Say that the volume V of the lake is measured in petalitres (i.e., litres×1015 = km3×103),the time t measured in years, and the quantity Q(t) of pollutant is measured in metric tons (i.e.,kg× 103). Then the concentration c(t) of pollutant in the lake is Q(t)/V metric tons per petalitre.

First we find an initial value problem for c(t). There is a water solution containing a concentra-tion of k metric tons per petalitre entering the lake at a rate of r petalitres per year; and pollutantsare also being added at a constant rate of P metric tons per year. Hence pollutants are being addedto the lake at (r k + P ) metric tons per year. There is a water solution containing a concentrationof c(t) metric tons per petalitre leaving the lake at a rate of r petalitres per year. Hence pollutantsare leaving the lake at r · c(t) metric tons per year. The total rate of change for the quantity Q(t)

53

Page 54: Ordinary Di erential Equations: Worked Examples with Solutionsegoins/notes/Ordinary_Differential_Equation… · Ordinary Di erential Equations: Worked Examples with Solutions Edray

of pollutant isdQ

dt= (r k + P )− r · c(t). Upon substituting Q(t) = V · c(t) in terms of the constant

V , we find the initial value problem

dc

dt=r k + P

V− r

Vc where c(0) = c0.

Next we find the solution to this initial value problem. Multiply by µ(t) = ert/V :

dc

dt+r

Vc =

r k + P

V

ert/Vdc

dt+r

Vert/V c =

r k + P

Vert/V

d

dt

[ert/V c(t)

]=r k + P

Vert/V =⇒ ert/V c(t) =

r k + P

V· Vrert/V + C

for some constant C. This constant can be determined by substituting t = 0 into this solution:

c0 =r k + P

r+ C =⇒ C = c0 − k −

P

r.

In particular, the solution to the initial value problem is the function

c(t) =

(k +

P

r

)+

(c0 − k −

P

r

)e−rt/V .

As time increases without bound, the exponential becomes small. Hence the limiting concentration

is limt→∞

c(t) = k +P

r.

If k = 0 and P = 0, then the concentration of pollutant at time t is c(t) = c0 e−rt/V . The time

interval T that must elapse before this concentration is reduced to 0.50 c0 satisfies the equation

1

2c0 = c0 e

−rT/V so that T = ln 2 · Vr

. The time interval T that must elapse before this concen-

tration is reduced to 0.10 c0 satisfies the equation1

10c0 = c0 e

−rT/V so that T = ln 10 · Vr

.

Problem 24. A pond initially contains 1,000,000 gal of water and an unknown quantity of anundesirable chemical. Water containing 0.01 gram of this chemical per gallon flows into the pondat a rate of 300 gal/hr. The mixture flows out at the same rate, so the amount of water in thepond remains constant. Assume that the chemical is uniformly distributed throughout the pond.

(a.) Let Q(t) be the amount of the chemical in the pond at time t. Write down an initial valueproblem for Q(t).

(b.) Solve the problem in part (a) for Q(t). How much chemical is in the pond after 1 year?

(c.) At the end of 1 year the source of the chemical in the pond is removed; thereafter pure waterflows into the pond, and the mixture flows out at the same rate as before. Write down theinitial value problem that describes this new situation.

54

Page 55: Ordinary Di erential Equations: Worked Examples with Solutionsegoins/notes/Ordinary_Differential_Equation… · Ordinary Di erential Equations: Worked Examples with Solutions Edray

(d.) Solve the initial value problem in part (c). How much chemical remains in the pond after 1additional year (2 years from the beginning of the problem)?

(e.) How long does it take for Q(t) to be reduced to 10 g?

(f.) Plot Q(t) versus t for 3 years.

Solution. Let Q(t) denote the quantity of the chemical in grams at any time t in hours. Theconcentration of chemical flowing in to the pond is 1/102 g/gal, whereas the concentration ofchemical flowing out of the pond is Q(t)/106 g/gal. These concentrations are flowing at a rate of300 gal/hr. We summarize this in the following table:

Concentration of Chemical Rate of Flow

Flowing In 10−2 g/gal 300 gal/hr

Flowing Out Q(t) · 10−6 g/gal 300 gal/hr

Since the change of concentration is equal to the rate in minus the rate out, we have the differential

equationdQ

dt= 300

(10−2 −Q 10−6

). To solve the differential equation, multiply both sides by

−104:dQ

dt= 3

(1− 10−4Q

)−104

dQ

dt= 3

(Q− 104

)− 104

Q− 104dQ

dt= 3

1

Q− 104dQ = − 3

104dt∫

1

Q− 104dQ = −

∫3

104dt

ln∣∣Q− 104

∣∣ = − 3 t

104+ C1 =⇒ Q(t) = 104 + C e−3t/10

4

for some constant C = ±eC1 . When t = 0 we have Q(0) = 0, so C = −104. Hence we find that the

quantity of chemical at any time t in hours is Q(t) = 104(

1− e−3t/104)

. In one year, there are

t = 1 year× 365 days

1 year× 24 hours

1 day= 8760 hours,

so that we have Q = 104(

1− e−3·8760/104)

= 9277.77 grams.

Now let Q(t) denote the amount in grams of the chemical in the pond in t hours after the sourceof the chemical is removed. We now have the following table:

55

Page 56: Ordinary Di erential Equations: Worked Examples with Solutionsegoins/notes/Ordinary_Differential_Equation… · Ordinary Di erential Equations: Worked Examples with Solutions Edray

Concentration of Chemical Rate of Flow

Flowing In 0 g/gal 300 gal/hr

Flowing Out Q(t) · 10−6 g/gal 300 gal/hr

At the time the chemical is removed, we have 9277.77 g of chemical in the pond. This gives theinitial value problem

dQ

dt= − 3

104Q where Q(0) = 9277.77.

This is a separable equation:

dQ

dt= − 3

104Q

1

QdQ = − 3

104dt∫

1

QdQ = −

∫3

104dt

ln |Q| = − 3 t

104+ C1 =⇒ Q(t) = C e−3t/10

4

for some constant C = ±eC1 . When t = 0 we have Q(0) = 9277.77, so C = 9277.77. Hence we find

that the quantity of chemical at any time t in hours is Q(t) = 9277.77 e−3t/104. In one year, there

are t = 8760 hours, so that we have Q = 9277.77 e−3·8760/104

= 670.066 grams. The time it takes

to reduce to 10 g satisfies 10 = 9277.77 e−3t/104, so that t =

104

3ln 927.777. This works out to

t =104

3ln 927.777 hours× 1 day

24 hours× 1 year

365 days= 2.599 years.

Figure 3.1 has a plot of the function:

Q(t) =

104

(1− e−3t/104

)if t ≤ 8760 hours,

9277.77 e−3(t−8760)/104

if t ≥ 8760 hours.

The vertical lines denote 1 year, 2 years, and 3 years, respectively.

56

Page 57: Ordinary Di erential Equations: Worked Examples with Solutionsegoins/notes/Ordinary_Differential_Equation… · Ordinary Di erential Equations: Worked Examples with Solutions Edray

Figure 3.1: Plot of Q(t) vs. t

-5000 0 5000 1⋅104 1.5⋅104 2⋅104 2.5⋅104 3⋅104

-1⋅104

-5000

5000

1⋅104

1.5⋅104

57


Recommended