10
1 Introduction to Differential Equations A differential equation is an equation that involves the derivative of some unknown function. For example, consider the equation f 0 (x)=4x 3 . (1) This equation tells us information about the derivative f 0 (x) of some function f (x), but it doesn’t actually give us a formula for f (x). Of course, in this example, it’s not too hard to figure out what f (x) might be. If the derivative of f (x) is 4x 3 , then one possibility is that f (x)= x 4 . This formula is a solution to the differential equation, because it matches the infor- mation about f 0 (x) that we were given. Most differential equations have more than one solution. For example, f (x)= x 4 +2 and f (x)= x 4 +5 are also solutions to equation (1), since the derivative of either of these is equal to 4x 3 . More generally, any formula of the form f (x)= x 4 + C (2) Really all we’ve done here is integrate, i.e. Z 4x 3 dx = x 4 + C. is a solution, where C can be any constant, and every possible solution has this form. Thus, this formula is the general solution to equation (1). The general solution to a differential equation usually involves one or more arbitrary constants. Because of this, most differential equations have infinitely many different solutions, with one solution for every possible value of the constant(s). Notation When writing differential equations, it is common to use the letter y for the function, Letters other than y are often used in applications. instead of the letter f . Thus, equation (1) would be written y 0 (x)=4x 3 . Moreover, it is common to simply write y 0 or dy/dx instead of y 0 (x): It is common in applications to use the variable t (for time) in place of x. In this case, the derivative would be written y 0 or dy/dt, or possibly ˙ y (with a dot above the y). y 0 =4x 3 or dy dx =4x 3 . In any case, the goal is to find a formula for y in terms of x that satisfies the given differential equation. Basic Examples Let’s look at a few more examples of differential equations, to help us get a feel for the subject.

Introduction to Di erential Equations - Bard Collegefaculty.bard.edu/.../IntroductionDifferentialEquationsRevised.pdf · 1 Introduction to Di erential Equations ... INTRODUCTION TO

  • Upload
    vokiet

  • View
    213

  • Download
    0

Embed Size (px)

Citation preview

1 Introduction to Differential Equations

A differential equation is an equation that involves the derivative of some unknownfunction. For example, consider the equation

f ′(x) = 4x3. (1)

This equation tells us information about the derivative f ′(x) of some function f(x),but it doesn’t actually give us a formula for f(x).

Of course, in this example, it’s not too hard to figure out what f(x) might be. Ifthe derivative of f(x) is 4x3, then one possibility is that

f(x) = x4.

This formula is a solution to the differential equation, because it matches the infor-mation about f ′(x) that we were given.

Most differential equations have more than one solution. For example,

f(x) = x4 + 2 and f(x) = x4 + 5

are also solutions to equation (1), since the derivative of either of these is equal to 4x3.More generally, any formula of the form

f(x) = x4 + C (2)Really all we’ve done here is integrate,

i.e.

∫4x3 dx = x4 + C.

is a solution, where C can be any constant, and every possible solution has this form.Thus, this formula is the general solution to equation (1).

The general solution to a differential equation usually involves one or more arbitraryconstants.

Because of this, most differential equations have infinitely many differentsolutions, with one solution for every possible value of the constant(s).

NotationWhen writing differential equations, it is common to use the letter y for the function,Letters other than y are often used in

applications. instead of the letter f . Thus, equation (1) would be written

y′(x) = 4x3.

Moreover, it is common to simply write y′ or dy/dx instead of y′(x):It is common in applications to usethe variable t (for time) in place of x.In this case, the derivative would bewritten y′ or dy/dt, or possibly y(with a dot above the y).

y′ = 4x3 ordy

dx= 4x3.

In any case, the goal is to find a formula for y in terms of x that satisfies the givendifferential equation.

Basic ExamplesLet’s look at a few more examples of differential equations, to help us get a feel for thesubject.

INTRODUCTION TO DIFFERENTIAL EQUATIONS 2

EXAMPLE 1 Find the general solution to the following differential equation.

y′ = 2x cos(x2).

SOLUTION This isn’t much harder than our initial example. All we need to do isintegrate:

y =

∫2x cos

(x2)dx.

This integral is most easily evaluated by substituting u = x2, which gives

y =

∫cosu du = sinu + C = sin

(x2)

+ C �

In general, any differential equation of the form

y′ = f(x)

can be solved by integrating:

y =

∫f(x) dx.

However, not every differential equation is so simple.

EXAMPLE 2 Find the general solution to the following differential equation.

y′ = y.

SOLUTION This equation is much more interesting than those we have encounteredso far. In words, it says the following: find a formula that doesn’t change when youtake its derivative.

Here is one solution that immediately leaps to mind:Actually, it is essentially the definitionof the number e that the derivative ofex is ex. That is, e is defined so thatex is a solution to the differentialequation y′ = y.

y = ex.

The derivative of ex is just ex, so if y = ex then y′ will be equal to y.But how can we find the general solution? Where should we place the constant C?

So far, we have always just added C to the end of the formula:

y = ex + C

But this doesn’t work: if y = ex + C, then y′ is just ex, so y and y′ are not the same.The answer is that C should be the coefficient instead.

y = Cex

This works, since the derivative of Cex is Cex for any constant C. �

In the last example, we started by finding a particular solution to the dfferentialequation, and then we figured out how to add a constant C to get the general solution.This is a common two-step process when solving differential equations

EXAMPLE 3 Find a general solution to the following differential equation.

y′ = −y2

INTRODUCTION TO DIFFERENTIAL EQUATIONS 3

SOLUTION Where do we even begin? How can we possibly find a formula for y thatsatisfies this equation?

When we have no idea how to solve a math problem, one method we can alwaysresort to is guess and check. We have no idea what formula might work here, andthere’s no way to find out without making some guesses, and then checking whetherthey work.

Here are some possible guesses:

y = sinx, y = ex, y =√x, y =

1

x, y = x2, y = lnx.

Do any of these work?

It turns out that y = 1/x is the right guess. If y = 1/x, then y′ = −1/x2, and theequation becomes

− 1

x2= −

(1

x

)2

.

So y = 1/x is a particular solution to this differential equation.Later on, we will learn a methodcalled separation of variables thatallows us to solve this equationwithout any guessing.

Now, what about the general solution? We need to figure out how to include anarbitrary constant C. Here are a few possibilities:

y =1

x+ C, y =

C

x, y =

1

Cx, y =

1

x + C, y =

1

xC.

Do any of these work? Yes — it is easy to check that

Actually, this answer isn’t quitecorrect. In particular, y = 0 is asolution to the given equation, thoughit doesn’t correspond to any valueof C. (Intuitively, it’s the solution youget when C =∞.)

y =1

x + C

is always a solution, so presumably this is the general solution to the given differentialequation. �

Making up Differential Equations

Although our goal is to learn how to solve differential equations, you can learn a lot bytrying to make up differential equations that have a certain solution. For example, supposewe want a differential equation that has

y = x3

as a solution. The simplest possibility is

y′ = 3x2.

However, any differential equation that holds when you plug in y = x3 and y′ = 3x2 willwork. For example,

xy′ = 3y

has y = x3 as a solution, since x(3x2)

= 3(x3). Some other differential equations with

y = x3 as a solution include(y′)3

= 27y2, xy′ + 4y = 7x3, and yy′ = 3x5.

On your own, you could try making some differential equations that have y = x2 as asolution, or perhaps y = sinx.

INTRODUCTION TO DIFFERENTIAL EQUATIONS 4

Initial Value ProblemsAn initital value problem consists of the following information:

1. A differential equation involving an unknown function y.

2. An initial value for y, i.e. the value y(0) of the function y when x = 0.Instead of including y(0), sometimesan initial value problem includes adifferent value of y, such as y(1), orpossibly the limiting value of y asx→ −∞ or x→∞.

The idea is that the value of y(0) is usually enough information to specify a singlesolution to the differential equation.

Usually, an initial value problem has only one solution.

Here is the most common procedure for solving an initial value problem.

SOLVING INITIAL-VALUE PROBLEMS

1. Find the general solution to the given differential equation, involving an arbitraryconstant C.

2. Plug in the initial value to get an equation involving C, and then solve for C.

EXAMPLE 4 Find the solution to the following initial value problem.

y′ = −y2, y(0) = 3.

SOLUTION We found the general solution to this differential equation in Example 3:

y =1

x + C

Therefore, all that remains is figure out a value for C so that y(0) = 3. Plugging inx = 0 and y = 3 gives the equation

3 =1

0 + C.

Solving for C gives C = 1/3, and hence

y =1

x + 1/3

We can simplify our answer by multiplying the numerator and denominator by 3:

y =3

3x + 1�

EXAMPLE 5 Find the solution to the following initial value problem.

y′ = 2y, y(0) = 5.

SOLUTION The given differential equation isn’t very different from the equation

y′ = y

from Example 2. In that case, the general solution was y = Cex. How can we modifythis solution to account for the extra 2?

INTRODUCTION TO DIFFERENTIAL EQUATIONS 5

A few minutes of thought reveals the answer:

y = Ce2xMore generally, the solution to anyequation of the form y′ = ky (where kis a constant) is y = Cekx. So this is the general solution to the given equation. Plugging in x = 0 and y = 5 gives

the equation5 = Ce0,

so C = 5, and the solution is y = 5e2x . �

Second-Order EquationsRecall that the second derivative of a function y is the derivative of the derivative.This can be written

y′′ ord2y

dx2.When using t (for time) instead of x,

the second derivative is sometimeswritten with two dots, i.e. y. A second-order equation is a differential equation that involves y′′, as well as perhaps

y′, y, and x.

EXAMPLE 6 Find the general solution to the following second-order equation.

y′′ = 12x2.

SOLUTION Integrating once gives a formula for y′:

y′ =

∫12x2 dx = 4x3 + C.

We can now integrate again to get a formula for y.

y =

∫ (4x3 + C

)dx = x4 + Cx + C2.

Here C2 represents a new constant of integration, which may be different from theoriginal C. Actually, it would make more sense to refer to the original C as C1:

y = x4 + C1x + C2

This is the general solution to the given second-order equation. �

Note that the general solution in the last example involved two arbitrary constants.This is fairly common.

1. The general solution to a first-order equation usually involves one arbitraryconstant.

2. The general solution to a second-order equation usually involves two arbitraryconstants.

Here the phrase “first-order equation” refers to an equation that has only firstderivatives, i.e. the sort of equation we were discussing initially.

Incidentally, it is of course possible to discuss third-order equations (involving thethird derivative), fourth-order equations, and so forth. As you would expect, the generalsolution to an nth order equation usually involves n arbitrary constants. However, wewill mostly restrict our attention to first and second order equations, since equationsof third order or higher are rare in both science and mathematics.

INTRODUCTION TO DIFFERENTIAL EQUATIONS 6

EXAMPLE 7 Find the general solution to the following second-order equation.

y′′ = y.

SOLUTION Obviously y = ex is a solution, and more generally y = C1ex is a solution

for any constant C1. However, this is not the general solution—we are expecting onemore arbitrary constant.

So how can we find another solution to this differential equation? Think about thisfor a minute—we want a function other than a multiple of ex that is equal to its ownsecond derivative.

The answer is quite clever: what about y = e−x? Though the derivative of e−x

has an extra minus sign, the second derivative is again e−x, so e−x is a solution to theabove equation. Indeed, anything of the form y = C2e

−x is a solution, where C2 canbe any constant.

But how can we combine the two solutions into a single formula? In this case, itturns out that it works to just add them together:

y = C1ex + C2e

−x

(The reader may want to check this by plugging this formula into the original equation.)This formula includes two arbitrary constants, so it ought to be the general solutionto the given second-order equation. �

Because the general solution to a second-order equation involves two arbitrary con-stants, you need two additional pieces of information to determine a single solution.One option is to give two different values for y, e.g. y(0) and y(1). This is called aboundary value problem, and you can solve it using the following procedure.It is common in applications that the

two known values of y are at theboundary points of the interval ofpossible x-values. Hence theterminology “boundary valueproblem”.

SOLVING BOUNDARY-VALUE PROBLEMS

1. Find the general solution to the given second-order equation, involving constantsC1 and C2.

2. Plug in the first value for y to get an equation involving C1 and C2.

3. Plug in the second value for y′ to get another equation involving C1 and C2.

4. Solve the two equations for the unknown constants C1 and C2.

EXAMPLE 8 Find the solution to the following boundary-value problem

y′′ = 12x, y(−1) = 3, y(1) = 5.

SOLUTION We can integrate to get a formula for y′:

y′ =

∫12x dx = 6x2 + C1,

and then integrate again to get a formula for y:

y =

∫(6x2 + C1) dx = 2x3 + C1x + C2,

All that remains is to find the values of C1 and C2.Plugging in x = −1 and y = 3 gives the equation

3 = −2− C1 + C2,

INTRODUCTION TO DIFFERENTIAL EQUATIONS 7

and plugging in x = 1 and y = 5 gives the equation

5 = 2 + C1 + C2,

We can solve these two equations to get C1 = −1 and C2 = 4, so

y = 2x3 − x + 4 �

Instead of giving two pieces of information about y, another way of specifying asingle solution to a second-order differential equation is to give one piece of informationabout y and one piece of information about y′. In particular, a second-order initialvalue problem consists of the following information:

1. A second-order differential equation involving an unknown function y.

2. An initial value for y, such as y(0).

3. An initial value for y′, such as y′(0).

You can solve such a problem using the following procedure.

SOLVING SECOND-ORDER INITIAL VALUE PROBLEMS

1. Find the general solution to the given second-order equation, involving constantsC1 and C2.

2. Plug in the initial value for y to get an equation involving C1 and C2.

3. Take the derivative of the general formula for y to get a general formula for y′.

4. Plug in the initial value for y′ to get another equation involving C1 and C2.

5. Solve the two equations for the unknown constants C1 and C2.

EXAMPLE 9 Find the solution to the following initial value problem.

y′′ = y, y(0) = 7, y′(0) = 3.

SOLUTION As we saw in Example 7, the general solution to the given equation is

y = C1ex + C2e

−x.

Therefore, we need only figure out the values of C1 and C2.Plugging in x = 0 and y = 7 gives the equation

7 = C1 + C2.

Next we take the derivative of the general formula for y to get a general formula for y′.

y′ = C1ex − C2e

−x.

Plugging in x = 0 and y′ = 3 gives the equation

3 = C1 − C2.

We can now solve the equations C1 + C2 = 7 and C1 − C2 = 3 for C1 and C2. Theresult is that C1 = 5 and C2 = 2, so

y = 5ex + 2e−x �

INTRODUCTION TO DIFFERENTIAL EQUATIONS 8

Guessing the FormOne basic method for solving differential equations is an enhanced version of guess &

check: we can guess the form of the solution, and then solve for any missing constants.For example, we might guess that a differential equation has a solution of the form

y = eax

for some unknown value of a. We then check this solution by plugging it into thedifferential equation, and then try to figure out which values of a will make the solutionwork.

EXAMPLE 10 Suppose we wish to find a solution the equation

y′′ = 7y′ − 10y.

We might guess that this equation has solutions of the form y = eax for some constant a.In this case, we have

y′ = aeax and y′′ = a2eax.

Plugging these into the equation gives

a2eax = 7aeax − 10eax

which simplifies toa2eax = (7a− 10)eax.

Now, how can we arrange it so that the left and right sides of this equation are thesame? Well, they will be the same as long as

a2 = 7a− 10For this equation we only found twosolutions y = e2x and y = e5x of thegiven form, but there ought to bemany more solutions not of this form.Indeed, the general solution to thisdifferential equation isy = C1e2x + C2e5x.

The solutions to this quadratic equation are a = 2 and a = 5, and therefore y = e2x

and y = e5x are two solutions to the given differential equation. �

EXAMPLE 11 Find a solution to the equation

x2y′′ = 2xy′ + 10y

of the form y = xa.

SOLUTION If y = xa, then

y′ = axa−1 and y′′ = a(a− 1)xa−2

Plugging these into differential equation gives

x2(a(a− 1)xa−2) = 2x

(axa−1)+ 10xa

which simplifies toa(a− 1)xa = (2a + 10)xa.

Now, how can we arrange it so that the left and right sides of this equation are thesame? Well, they will be the same as long as

a(a− 1) = 2a + 10Again, we only found two solutions tothe given equation, but it turns outthat the general solution isy = C1x5 + C2x−2.

Solving gives a = 5 or a = −2, so y = x5 and y = x−2 are two solutions to thisequation. �

INTRODUCTION TO DIFFERENTIAL EQUATIONS 9

Forms with Two Constants

Sometimes it works well to guess a form that involves two constants. For example, considerthe equation

y′y′′ = 2y

We might guess that this equation has solutions of the form y = axb, where a and b areconstants. The derivatives of this form are

y′ = abxb−1 and y′′ = ab(b− 1)xb−2.

Plugging these into the differential equation and simplifying yields

a2b2(b− 1)x2b−3 = 2axb.

The only way for the left and right sides of this equation to be the same is if the coefficientsare the same and the exponents are the same. This gives us the following two equations:

a2b2(b− 1) = 2a and 2b− 3 = b.

The second equation tells us that b = 3. Plugging this into the first equation and solvingfor a yields a = 0 or a = 1/9. Therefore, y = 0 and y = 1

9x3 are two solutions to the given

equation.

EXERCISES

1–6 Use integration to find the general solution to the givendifferential equation.

1. y′ = x√x2 + 1 2. y′ = x cosx

3. y′ + cos(3x) = 0 4. y′ex = 1

5. xy′ + 4x3 = 1 6. y′ = 1− x2y′

7. y′′ = 3√x 8. x3y′′ = x+ 2

9–10 Use guess & check to find the general solution to thegiven differential equation.

9. y′ + y tanx = 0 10.(y′)2

= 4y

11–14 Use guess & check to find just one solution to thegiven differential equation.

11. y′ + y = 9e2x 12. yy′ = 4e8x

13. x2y′ + ey = 2x 14. y′y′′ = 14y + 4x3

15–16 Solve the given initial value problem.

15. y′ = xex, y(0) = 3 16. y′ = 3y, y(2) = 4

17–18 Solve the given boundary value problem.

17. y′′ = sinx, y(0) = 4, y(π) = 6

18. y′′ = y, y(0) = 7, y(ln 2) = 8

19–20 Solve the given initial value problem.

19. y′′ = x2, y(1) = 1/2, y′(1) = 1/2

20. y′′ = 4y, y(0) = 5, y′(0) = 2

21–24 Find all solutions to the given differential equation ofthe specified form.

21. y′′ = 3y′ + 4y (y = eax)

22. x2y′′ − 7xy′ + 12y = 0 (y = xa)

23. y′y′′ = −36y3 (y = xa)

24. 5yy′′ =(y′)2

+ 36y2 (y = eax)

Answers

1. y = 13

(x2 +1

)3/2+C 2. y = x sin x+ cos x+C 3. y =− 1

3 sin(3x)+C 4. y =−e−x +C

5. y = ln |x|− 43 x3 +C 6. y = arctanx+C 7. y = 9

28 x7/3 +C1x+C2 8. y =− ln |x|+ x−1 +C1x+C2

9. y =C cos x 10. y = (x+C)2 11. y = 3e2x 12. y = e4x 13. y = lnx 14. y = x3

15. y = (x−1)ex +4 16. y = 4e3x−6 17. y =−sinx+(2/π)x+4 18. y = 3ex +4e−x

19. y = 112

(x4 +2x+3

)20. y = 3e2x +2e−2x 21. y = e−x and y = e4x 22. y = x2 and y = x6

23. y = x−3 24. y = e3x and y = e−3x