Second Order Differential Equations

As discussed in the introduction to differential equations, a vibrational system can be represented with a second-order differential equation of the form my+cy+ky=f(t)my''+cy'+ky=f(t) where mm is the mass of the body, cc is the damper constant, kk is the spring constant, and f(t)f(t) is some external force. In general, a second-order differential equation looks like p(x)y+q(x)y+r(x)y=g(x).p(x)y''+q(x)y'+r(x)y=g(x).

In this course, we're going to stick to simpler cases, where the following two assumptions hold:

  1. The equation is homogeneous: g(x)=0.g(x)=0. In the case of the vibration application, this means there's no external force on the object; it is simply deflected and left to vibrate.
  2. The coefficients are constants: p,p, q,q, and rr are constant.

General Solution


For a differential equation of the form py+qy+ry=0,py''+qy'+ry=0, solutions are given by y=c1y1+c2y2,y=c_1y_1+c_2y_2, where y1y_1 and y2y_2 are two linearly independent solutions of the differential equation. When we solve these equations, we'll get two solutions, and then write the full solution this way. To get a particular solution, we'll need two given conditions, so that we can find c1c_1 and c2.c_2.

Definition: Linear Independence

Two functions are linearly independent if neither is a constant multiple of the other.

For example, 3sinx3 \sin x and 4sinx−4 \sin x are not linearly independent, but 2x2x and 4x24x^2 are linearly independent. This will be significant in one case below.

Finding the Solution

Start with the differential equation: py+qy+ry=0py''+qy'+ry=0 Follow me for a moment on a seeming leap: we are looking for this unknown function y,y, and all that we know is that if we add it, its derivative, and its second derivative together, they all cancel each other out; they must therefore look like the original function. The only function we know of whose derivatives look like it is the exponential function. So let's assume that the solution looks like y=emx.y=e^{mx}. Following that logic, y=emxy=memxy=m2emx\begin{aligned} y &= e^{mx}\ y' &= me^{mx}\ y'' &= m^2e^{mx} \end{aligned}

so when we substitute these into the differential equation, we get the following:

pm2emx+qmemx+remx=0emx(pm2+qm+r)=0\begin{aligned} pm^2e^{mx}+qme^{mx}+re^{mx} &= 0\ e^{mx}(pm^2+qm+r) &= 0 \end{aligned}

Since emxe^{mx} is never equal to 0,0, it follows that^2+qm+r=0.

If we solve this equation, called the characteristic equation, to find m,m, we'll have the solutions.

Solution Possibilities

There are three possibilities for the forms of the solutions, based on the values of m,m, which are in turn based on the form of the characteristic equation. If we use the quadratic formula to find m,m, we find that m=q±q24pr2pm=\dfrac{−q \pm \sqrt{q^2−4pr}}{2p}

The three possibilities depend on the value of q24pr,q^2−4pr, the discriminant of the quadratic equation.

Case 1: Two Distinct Real Roots (q24pr>0)(q^2-4pr > 0)

If the discriminant is positive, we'll get two real answers for mm that are different. In that case, the two solutions look like

y1=em1x and y2=em2x,y_1=e^{m_1x} \textrm{ and } y_2=e^{m_2x},

which makes the full solution y=c1em1x+c2em2x\ans{y = c_1e^{m_1x} + c_2e^{m_2x}}

Case 2: One Real Root (q24pr=0)(q^2-4pr = 0)

If the discriminant is zero, everything after the plus/minus is zero, so there will only be one real answer for m.m. This is the case where it is important to account for linear independence. Here, the two solutions look like

y1=emx and y2=xemx,y_1=e^{mx} \textrm{ and } y_2=xe^{mx},

which makes the full solution y=c1emx+c2xemx\ans{y = c_1e^{mx} + c_2xe^{mx}}

Case 3: A Conjugate Pair of Complex Roots (q24pr<0)(q^2-4pr < 0)

If the discriminant is negative, we'll get a complex conjugate pair of solutions, of the form m=a±bi.m = a \pm bi. In that case, the two solutions look like

y1=eaxcos(bx) and y2=eaxsin(bx),y_1=e^{ax}\cos(bx) \textrm{ and } y_2=e^{ax}\sin(bx),

which makes the full solution y=c1eaxcos(bx)+c2eaxsin(bx)\ans{y = c_1e^{ax}\cos(bx) + c_2e^{ax}\sin(bx)}

Solve the following differential equation. y6y+9y=0y''−6y'+9y=0


The characteristic equation is m26m+9=0.m^2−6m+9=0.

Notice that we simply replace yy'' with m2,m^2, yy′ with m,m, and yy with 11 to get the characteristic equation. We can solve for mm using the quadratic formula, but this one also can be factored nicely:


which means that m=3.m=3. This is the second case; there is only one value for m.m. Therefore, the solution is y=c1e3x+c2xe3x\ans{y=c_1e^{3x}+c_2xe^{3x}}

Solve the following differential equation. y+6y+5y=0y(0)=2, y(0)=1y''+6y'+5y=0 \hspace{0.5in} y(0)=2,\ y'(0)=1


The characteristic equation is m2+6m+5=0.m^2+6m+5=0.

Again, we can solve for mm by factoring: m2+6m+5=(m+5)(m+1)=0,m^2+6m+5=(m+5)(m+1)=0,

which means that m=5,1.m=−5,−1. This is the first case; there are two distinct real values for m.m. Therefore, the general solution is y=c1e5x+c2ex.y=c_1e^{−5x}+c_2e^{−x}.

To find the particular solution, we need to use the given initial conditions: y(x)=c1e5x+c2ex2=c1+c2y(x)=5c1e5xc2ex1=5c1c2\begin{aligned} y(x) = c_1e^{−5x}+c_2e^{−x} &\longrightarrow 2=c_1+c_2\ y'(x)=−5c_1e^{−5x}−c_2e^{−x} &\longrightarrow 1=−5c_1−c_2 \end{aligned}

When you solve this system of two equations, you'll find that c1=3/4c_1=−3/4 and c2=11/4,c_2=11/4, so the particular solution is y=34e5x+114ex\ans{y=−\dfrac{3}{4}e^{−5x}+\dfrac{11}{4}e^{−x}}

  1. Solve the following differential equation. y+2y15y=0y''+2y'−15y=0

  2. y=c1e5x+c2e3xy=c_1e^{−5x}+c_2e^{3x}

Solve the following differential equation. y+y+2y=0y''+y'+2y=0


The characteristic equation is m2+m+2=0.m^2+m+2=0.

This one doesn't factor nicely, so we have to find mm using the quadratic formula: m=1±14(1)(2)2=12±72im=\dfrac{−1 \pm \sqrt{1−4(1)(2)}}{2}=\dfrac{−12 \pm \sqrt{7}}{2}i

Matching this to the form m=a±bi,m=a±bi, we find that a=1/2a=−1/2 and b=7/2.b=\sqrt{7}/2. Therefore, the solution (according to Case 3) looks like y=c1e12xcos(72x)+c2e12xsin(72x)\ans{y=c_1e^{−12x}\cos\left(\dfrac{\sqrt{7}}{2}x\right)+c_2e^{−12x}\sin\left(\dfrac{\sqrt{7}}{2}x\right)}