Skip to content

Second-order linear ODEs with constant coefficients

6 min read

Short answer

Try y=erxy=e^{rx}. Substituting gives the characteristic equation ar2+br+c=0ar^2+br+c=0. Two real roots r1≠r2r_1\neq r_2: y=C1er1x+C2er2xy=C_1e^{r_1x}+C_2e^{r_2x}. Repeated root: y=(C1+C2x)erxy=(C_1+C_2x)e^{rx}. Complex roots α±iβ\alpha\pm i\beta: y=eαx(C1cos⁡βx+C2sin⁡βx)y=e^{\alpha x}(C_1\cos\beta x+C_2\sin\beta x).

Roots of ar² + br + c = 0 compared with General solutionRoots of ar² + br +c = 0r₁ ≠ r₂ realr₁ = r₂ repeatedα ± iβ complexGeneral solutionC₁e^(r₁x) + C₂e^(r₂x)(C₁ + C₂x)e^(rx)e^(αx)(C₁cos βx +C₂sin βx)
The discriminant b² − 4ac decides which row you are in.

Why exponentials

Differentiating erxe^{rx} only multiplies by rr, so ay′′+by′+cy=erx(ar2+br+c)ay''+by'+cy=e^{rx}(ar^2+br+c). This vanishes exactly when rr solves the characteristic equation. Linear combinations of solutions are solutions, and two independent ones give the general solution.

Complex roots mean oscillation

Euler's formula eiβx=cos⁡βx+isin⁡βxe^{i\beta x}=\cos\beta x+i\sin\beta x turns the complex exponentials into real sines and cosines. The real part α\alpha sets growth (α>0\alpha>0) or decay (α<0\alpha<0) of the oscillation, and β\beta its frequency.

Worked example

Solve y′′−4y′+13y=0y''-4y'+13y=0 with y(0)=1y(0)=1, y′(0)=0y'(0)=0.

r2−4r+13=0r^2-4r+13=0, r=2±3ir=2\pm3i. So y=e2x(C1cos⁡3x+C2sin⁡3x)y=e^{2x}(C_1\cos3x+C_2\sin3x). y(0)=C1=1y(0)=C_1=1. y′=e2x[2(C1cos⁡3x+C2sin⁡3x)+(−3C1sin⁡3x+3C2cos⁡3x)]y'=e^{2x}[2(C_1\cos3x+C_2\sin3x)+(-3C_1\sin3x+3C_2\cos3x)], so y′(0)=2C1+3C2=0y'(0)=2C_1+3C_2=0, C2=−23C_2=-\tfrac23.

Try it yourself

Solve y′′−5y′+6y=0y''-5y'+6y=0.

Show the answer

r2−5r+6=(r−2)(r−3)r^2-5r+6=(r-2)(r-3), so y=C1e2x+C2e3xy=C_1e^{2x}+C_2e^{3x}.

Keep going with practice

Vidi's mechanics lessons use exactly this equation for springs and pendulums.