[Notes on Diffy Qs home] [PDF version] [Buy paperback on Amazon]

[next] [prev] [prev-tail] [tail] [up]

2.3 Higher order linear ODEs

Note: somewhat more than 1 lecture, §3.2 and §3.3 in [EP], §4.1 and §4.2 in [BD]

We briefly study higher order equations. Equations appearing in applications tend to be second order. Higher order equations do appear from time to time, but generally the world around us is “second order.”

The basic results about linear ODEs of higher order are essentially the same as for second order equations, with 2 replaced by n . The important concept of linear independence is somewhat more complicated when more than two functions are involved. For higher order constant coefficient ODEs, the methods developed are also somewhat harder to apply, but we will not dwell on these complications. It is also possible to use the methods for systems of linear equations from chapter 3 to solve higher order constant coefficient equations.

Let us start with a general homogeneous linear equation

y(n) + pn−1(x)y(n−1) + ⋅⋅⋅ + p1(x)y′ + p0(x)y = 0.
(2.4)

Theorem 2.3.1 (Superposition). Suppose y1 , y2 , …, yn are solutions of the homogeneous equation (2.4). Then

y(x) = C 1y1(x ) + C2y2(x) + ⋅⋅⋅ + Cnyn(x)

also solves (2.4) for arbitrary constants C 1,C 2,...,Cn .

In other words, a linear combination of solutions to (2.4) is also a solution to (2.4). We also have the existence and uniqueness theorem for nonhomogeneous linear equations.

Theorem 2.3.2 (Existence and uniqueness). Suppose p0 through pn−1 , and f are continuous functions on some interval I , a is a number in I , and b ,b ,...,b 0 1 n−1 are constants. The equation

 (n) (n−1) ′ y + pn−1(x)y + ⋅⋅⋅ + p1(x)y + p0(x)y = f (x )

has exactly one solution y(x) defined on the same interval I satisfying the initial conditions

y(a) = b0, y′(a ) = b1, ..., y(n−1)(a) = bn−1.

2.3.1 Linear independence

When we had two functions y1 and y2 we said they were linearly independent if one was not the multiple of the other. Same idea holds for n functions. In this case it is easier to state as follows. The functions y 1 , y 2 , …, y n are linearly independent if

c1y1 + c2y2 + ⋅⋅⋅ + cnyn = 0

has only the trivial solution c1 = c2 = ⋅⋅⋅ = cn = 0 , where the equation must hold for all x . If we can solve equation with some constants where for example c1 ⇔ 0 , then we can solve for y1 as a linear combination of the others. If the functions are not linearly independent, they are linearly dependent.

Example 2.3.1: Show that ex,e2x,e3x are linearly independent.

Let us give several ways to show this fact. Many textbooks (including [EP] and [F]) introduce Wronskians, but it is difficult to see why they work and they are not really necessary here.

Let us write down

c1ex + c2e2x + c3e3x = 0.

We use rules of exponentials and write  x z = e . Hence  2 2x z = e and  3 3x z = e . Then we have

c z + c z2 + c z3 = 0. 1 2 3

The left hand side is a third degree polynomial in z . It is either identically zero, or it has at most 3 zeros. Therefore, it is identically zero, c1 = c2 = c3 = 0 , and the functions are linearly independent.

Let us try another way. As before we write

c1ex + c2e2x + c3e3x = 0.

This equation has to hold for all x . We divide through by e3x to get

c1e−2x + c2e−x + c3 = 0.

As the equation is true for all x , let x → ∞ . After taking the limit we see that c3 = 0 . Hence our equation becomes

 x 2x c1e + c2e = 0.

Rinse, repeat!

How about yet another way. We again write

c1ex + c2e2x + c3e3x = 0.

We can evaluate the equation and its derivatives at different values of x to obtain equations for c1 , c2 , and c 3 . Let us first divide by ex for simplicity.

c1 + c2ex + c3e2x = 0.

We set x = 0 to get the equation c + c + c = 0 1 2 3 . Now differentiate both sides

c2ex + 2c3e2x = 0.

We set x = 0 to get c2 + 2c3 = 0 . We divide by ex again and differentiate to get 2c3ex = 0 . It is clear that c3 is zero. Then c2 must be zero as c2 = −2c3 , and c1 must be zero because c1 + c2 + c3 = 0 .

There is no one best way to do it. All of these methods are perfectly valid. The important thing is to understand why the functions are linearly independent.

Example 2.3.2: On the other hand, the functions ex , e−x , and co sh x are linearly dependent. Simply apply definition of the hyperbolic cosine:

 x −x co sh x = e-+-e--- or 2 cosh x − ex − e −x = 0. 2

2.3.2 Constant coefficient higher order ODEs

When we have a higher order constant coefficient homogeneous linear equation, the song and dance is exactly the same as it was for second order. We just need to find more solutions. If the equation is nth order we need to find n linearly independent solutions. It is best seen by example.

Example 2.3.3: Find the general solution to

y′′′ − 3y′′ − y′ + 3y = 0.
(2.5)

Try:  rx y = e . We plug in and get

r3erx − 3r2erx − rerx + 3erx = 0.

We divide through by erx . Then

 3 2 r − 3r − r + 3 = 0.

The trick now is to find the roots. There is a formula for the roots of degree 3 and 4 polynomials but it is very complicated. There is no formula for higher degree polynomials. That does not mean that the roots do not exist. There are always n roots for an nth degree polynomial. They may be repeated and they may be complex. Computers are pretty good at finding roots approximately for reasonable size polynomials.

A good place to start is to plot the polynomial and check where it is zero. We can also simply try plugging in. We just start plugging in numbers r = −2,− 1,0,1,2,... and see if we get a hit (we can also try complex numbers). Even if we do not get a hit, we may get an indication of where the root is. For example, we plug r = −2 into our polynomial and get − 15 ; we plug in r = 0 and get 3. That means there is a root between r = − 2 and r = 0 , because the sign changed. If we find one root, say r1 , then we know (r − r1) is a factor of our polynomial. Polynomial long division can then be used.

A good strategy is to begin with r = − 1 , 1, or 0. These are easy to compute. Our polynomial happens to have two such roots, r = −1 1 and r = 1 2 . There should be 3 roots and the last root is reasonably easy to find. The constant term in a monic polynomial such as this is the multiple of the negations of all the roots because  3 2 r − 3r − r + 3 = (r − r1)(r − r2)(r − r3) . So

3 = (−r1)(− r2)(−r3) = (1 )(− 1)(− r3) = r3.

You should check that r = 3 3 really is a root. Hence we know that e−x , ex and e3x are solutions to (2.5). They are linearly independent as can easily be checked, and there are 3 of them, which happens to be exactly the number we need. Hence the general solution is

y = C 1e−x + C 2ex + C3e3x.

Suppose we were given some initial conditions y(0) = 1 , y′(0) = 2 , and y′′(0) = 3 . Then

 1 = y(0) = C1 + C 2 + C 3, 2 = y′(0) = −C 1 + C2 + 3C3, ′′ 3 = y (0) = C1 + C 2 + 9C 3.
It is possible to find the solution by high school algebra, but it would be a pain. The sensible way to solve a system of equations such as this is to use matrix algebra, see § 3.2. For now we note that the solution is C = − 1∕4 1 , C = 1 2 , and C = 1∕4 3 . The specific solution to the ODE is
 −1 1 y = ---e−x + ex +-e3x. 4 4

Next, suppose that we have real roots, but they are repeated. Let us say we have a root r repeated k times. In the spirit of the second order solution, and for the same reasons, we have the solutions

erx, xerx, x2erx, ..., xk−1erx.

We take a linear combination of these solutions to find the general solution.

Example 2.3.4: Solve

y(4) − 3y′′′ + 3y ′′ − y′ = 0.

We note that the characteristic equation is

r4 − 3r3 + 3r2 − r = 0.

By inspection we note that r4 − 3r 3 + 3r2 − r = r(r − 1)3 . Hence the roots given with multiplicity are r = 0,1,1,1 . Thus the general solution is

y = (C 1 + C 2x + C 3x2)ex + ◟C◝◜4◞ . ◟-----te---rm---s------co---m◝i◜ng----fr---om------r=---1----◞ from r=0

The case of complex roots is similar to second order equations. Complex roots always come in pairs r = α ± iβ . Suppose we have two such complex roots, each repeated k times. The corresponding solution is

(C0 + C1x + ⋅⋅⋅ + Ck −1xk−1)eαxcos(βx) + (D 0 + D 1x + ⋅⋅⋅ + Dk −1xk−1)eαxsin(βx).

where C 0 , …, Ck −1 , D0 , …, Dk−1 are arbitrary constants.

Example 2.3.5: Solve

y(4) − 4y′′′ + 8y′′ − 8y ′ + 4y = 0.

The characteristic equation is

r4 − 4r3 + 8r2 − 8r + 4 = 0, (r2 − 2r + 2)2 = 0, ( 2 )2 (r − 1) + 1 = 0.
Hence the roots are 1 ± i , both with multiplicity 2. Hence the general solution to the ODE is
y = (C + C x )ex cosx + (C + C x)ex sin x. 1 2 3 4

The way we solved the characteristic equation above is really by guessing or by inspection. It is not so easy in general. We could also have asked a computer or an advanced calculator for the roots.

2.3.3 Exercises

Exercise 2.3.1: Find the general solution for  ′′′ ′′ ′ y − y + y − y = 0 .

Exercise 2.3.2: Find the general solution for  (4) ′′′ ′′ y − 5y + 6y = 0 .

Exercise 2.3.3: Find the general solution for y′′′ + 2y ′′ + 2y′ = 0 .

Exercise 2.3.4: Suppose the characteristic equation for a differential equation is (r − 1)2(r − 2)2 = 0 . a) Find such a differential equation. b) Find its general solution.

Exercise 2.3.5: Suppose that a fourth order equation has a solution y = 2e 4xx cosx . a) Find such an equation. b) Find the initial conditions that the given solution satisfies.

Exercise 2.3.6: Find the general solution for the equation of Exercise 2.3.5.

Exercise 2.3.7: Let  x f (x) = e − cos x ,  x g (x) = e + cos x , and h(x) = cos x . Are f(x) , g(x) , and h(x) linearly independent? If so, show it, if not, find a linear combination that works.

Exercise 2.3.8: Let f (x) = 0 , g(x) = cosx , and h(x) = sinx . Are f(x) , g(x ) , and h(x) linearly independent? If so, show it, if not, find a linear combination that works.

Exercise 2.3.9: Are x , x2 , and x4 linearly independent? If so, show it, if not, find a linear combination that works.

Exercise 2.3.10: Are ex , xex , and x2ex linearly independent? If so, show it, if not, find a linear combination that works.

Exercise 2.3.11: Find an equation such that y = xe −2xsin(3x) is a solution.

Exercise 2.3.101: Find the general solution of y(5) − y(4) = 0

Exercise 2.3.102: Suppose that the characteristic equation of a third order differential equation has roots 3,± 2i . a) What is the characteristic equation? b) Find the corresponding differential equation. c) Find the general solution.

Exercise 2.3.103: Solve  √ -- 100 1y′′′ + 3.2y′′ + πy ′ − 4y = 0 , y(0) = 0 , y′(0) = 0 , y′′(0) = 0 .

Exercise 2.3.104: Are ex , ex+1 , e2x , sin(x) linearly independent? If so, show it, if not find a linear combination that works.

Exercise 2.3.105: Are sin(x) , x , xsin(x ) linearly independent? If so, show it, if not find a linear combination that works.

Exercise 2.3.106: Find an equation such that y = c os(x) , y = sin(x) , y = ex are solutions.