Learning Objectives
By the end of this section you will be able to:
- Detect the repeated-root case by the discriminant and identify the unique root .
- Explain three independent reasons why is the missing second solution: a limit of two close exponentials, reduction of order, and direct verification.
- Write the general solution and apply two initial conditions to solve for .
- Recognise this case as the boundary between overdamped and underdamped behaviour — the regime engineers call critical damping.
- Implement an analytic solver, an RK4 numerical solver, and a PyTorch matrix-exponential solver, and verify that all three agree to machine precision.
- See the deeper linear-algebra reason: the companion matrix has a Jordan block, and the matrix exponential of a Jordan block naturally carries a factor of .
The Puzzle: Only One Exponential
We learned in Section 22.01 that every homogeneous second-order linear ODE with constant coefficients
is solved by trying , which reduces the differential equation to the algebraic characteristic equation . The quadratic has two roots, and those roots become the two independent exponential modes of the system.
But there is a sharp edge case. What happens when is exactly ?
We get only one exponent. The naive recipe would hand us a one-parameter family of solutions . But a second-order ODE is supposed to need two initial conditions and have a two-parameter solution family. Something is missing.
The headline
When the characteristic equation has a single repeated root , the second linearly independent solution is , and the general solution is
The rest of this section explains, from three independent angles, where that mysterious factor of actually comes from.
Where Does t Come From? The Coalescence Argument
The cleanest derivation is to perturb the problem. Imagine the characteristic equation does not quite have a repeated root — instead the two roots are and for some tiny . Then we are in the distinct-real-roots case, where two known independent solutions are
Because the ODE is linear, any linear combination of these is still a solution. Consider the particular combination
This is just a scaled divided difference — the symmetric Newton quotient of with respect to the parameter , sampled at . Now let .
Factor out :
Use the Taylor expansion :
Therefore
What this argument is really saying
As the two roots collide on the real axis, one of the two independent solutions does not vanish — it rotates into a derivative-with-respect-to-the-root. Concretely,
The partial derivative with respect to the eigenvalue is what plays the role of a second independent solution when the eigenvalue is repeated. You will see this exact pattern again for eigenvalues of matrices, for Wronskian arguments, and for the matrix exponential later in this section.
Why is this still a solution after the limit?
Each solves a slightly different ODE (with discriminant ). But as , the coefficients of that ODE converge to , and converges to uniformly on compact -intervals. By continuous dependence of linear ODE solutions on their coefficients, the limit solves the limiting equation — i.e. the repeated-root ODE. You can also verify directly by substitution, which we do in a moment.
Second Derivation: Reduction of Order
Here is a second, completely independent route to the same answer — and one that generalises far beyond constant coefficients.
Suppose we already know one solution . Look for a second solution of the form
where is an unknown function, not just a constant. (If were constant, this would just be a multiple of , which is not linearly independent.)
Compute derivatives using the product rule:
Substitute into and divide by (always positive):
Group by derivatives of :
Two things now collapse beautifully:
- The bracket on is — the characteristic equation, which holds because is its root.
- The bracket on is . Plug : .
Both brackets vanish! What remains is
Therefore the most general solution is
What just happened — the deep reason
The cancellation of the bracket is not a coincidence. The quantity is the derivative of the characteristic polynomial evaluated at : . A root is repeated precisely when AND . So both brackets vanish together exactly when the root is repeated — which is exactly when we need a polynomial factor to fill the gap.
Third Derivation: Just Substitute and Check
The most elementary route is brute force. Take as a candidate and plug in:
Then
The coefficient of is zero because is a root of the characteristic equation. The constant piece is zero because forces . So is genuinely a solution.
And it is linearly independent from : the Wronskian is
Since for every , the two solutions form a fundamental set and span the entire solution space.
The General Solution and Two Initial Conditions
Putting all three derivations together, the general solution of with is
To pin down the two constants we use both initial conditions. Setting :
Differentiate with the product rule:
Evaluate at :
| Quantity | Formula | Comes from |
|---|---|---|
| Repeated root r | r = −b / (2a) | Discriminant is 0 |
| C₁ | C₁ = y(0) | Set t = 0 in y(t) |
| C₂ | C₂ = y'(0) − r·y(0) | Set t = 0 in y'(t) |
| Number of zeros of y | 0 or 1 on (0, ∞) | Linear · positive exponential |
A useful qualitative fact
Because for every real , the sign of is determined entirely by the linear factor . A repeated-root solution therefore changes sign at most once, at (provided ). It is the most boring oscillation in the world — no oscillation at all.
Interactive: Watch the Limit Happen
The picture below has two coupled plots. In the top plot, drag the ε slider toward zero and watch the green divided-difference curve glue itself onto the amber curve. That is the second solution being born as the two roots collide.
In the bottom plot you can dial in any and see how the linear factor rides on top of the exponential envelope. Pay attention to the red dashed line marking the zero crossing at .
Three things to try
- Set . The envelope becomes 1 and is a literal straight line. The repeated-root machinery is consistent with this edge case.
- Set and . The curve overshoots zero once, then asymptotes back to zero from the other side. This is the critically damped overshoot — your car suspension hitting a pothole.
- Set . The polynomial factor is irrelevant in the long run; the growing exponential dominates. This is what happens when a controller goes unstable.
Physical Meaning: Critical Damping
Translate to the canonical mass–spring–damper . The discriminant condition becomes
is the damping ratio. The repeated-root case sits exactly at — the knife-edge between two very different behaviours.
| Regime | ζ | Roots | What it looks like |
|---|---|---|---|
| Overdamped | ζ > 1 | Two distinct negative real | Slow, non-oscillating return; energy bleeds away through two timescales. |
| Critically damped | ζ = 1 | One repeated negative real | Fastest non-oscillating return. At most one zero crossing. |
| Underdamped | 0 < ζ < 1 | Complex conjugate pair | Decaying oscillation; system rings before settling. |
Why engineers care: car suspensions, robotic-arm controllers, hard-disk read heads, and analog filter circuits are often tuned just barely underdamped of critical. Critical damping returns to equilibrium fastest without overshoot, but the slightest disturbance pushes a real system either over (sluggish) or under (ringing) — so designers leave a safety margin.
The boundary is mathematically thin, physically wide
In any continuous family of ODEs, the set is a one-dimensional surface in the three-dimensional parameter space — a thin slice. But it is the slice that separates the oscillating and non-oscillating worlds. Almost every interesting control-engineering decision lives within a small neighbourhood of this slice.
Worked Example (Step-by-Step)
Solve subject to and .
Click to expand the full hand calculation
Comparing with : .
. Repeated-root case confirmed.
. Negative root ⇒ both basic solutions and decay to zero.
, so .
, so .
✓. For : at the formula is ✓.
Compute and . Then equals ✓.
Set . Because the exponential is never zero, this is the unique zero for . Numerically: .
At : . Check the visualization above with — the curve dips below zero around and returns to zero from below.
Sweep Through the Three Cases
The interactive below is the same explorer from Section 22.01, but now look at it through the lens of this section. Drag the slider slowly while watching the two root markers in the complex plane on the right. The instant they collide on the real axis is exactly the repeated-root case. Push a hair further and they pop off the real axis as a complex pair.
Two presets to compare
- Click Critically damped (repeated root). Note the two root markers collapse to one point. Coefficients give — exactly our worked example (the ICs differ; the algebra is the same).
- Now click Overdamped (distinct real roots). The two markers split apart along the real axis. The shape of the solution is qualitatively similar (no oscillation, decays to zero), but the closed form is — no factor. The repeated-root case is the limit of this as .
Computation in Python — Analytic Solver
Mathematics first, then code. With the closed form in hand, a complete Python solver is short. The only judgement call is what to do when the user hands us non-repeated coefficients — we raise an explicit error rather than silently producing nonsense.
Numerical Check with RK4
Two analytic derivations are convincing. Three independent computer verifications are conclusive. Here we re-derive the same solution by integrating the equivalent first-order vector ODE with classical RK4. If the numerical and analytic answers disagree, one of them is wrong; we will find that they agree to ~1e-8 on a fine grid.
PyTorch View: A Jordan Block in Disguise
Now the punchline. Promote the companion matrix to a torch tensor and compute directly. The matrix exponential is defined by the same Taylor series as the scalar one,
For a generic matrix this series is infinite. But here has a single repeated eigenvalue . The matrix turns out to be nilpotent of order 2: . Using and :
The series truncates at the linear term! That single is the structural origin of the factor in the scalar solution. Repeated eigenvalue ⟺ nilpotent ⟺ matrix exponential carries a finite polynomial in ⟺ appears in the solution.
Why this view scales
For higher-order linear ODEs and for linear systems with several variables, the same picture works. An eigenvalue with algebraic multiplicity but only independent eigenvectors produces solutions of the form . The same Jordan-block mechanism explains in 2nd order, and it explains the first time you meet a triple root in a 3rd-order equation.
Common Pitfalls
Writing the wrong second solution
The most common mistake is to write in the repeated-root case. That is the same exponential twice — the two terms combine into , a ONE-parameter family. The correct second solution is , not another .
Forgetting the product rule for y'(0)
Differentiating requires the product rule. A frequent error is to write , dropping the term. Always carry both pieces: .
Mistaking Δ ≈ 0 for Δ = 0
With finite-precision arithmetic, you will rarely hit exactly. If your code branches on the sign of , add a small tolerance and treat near-zero values as the repeated case — or better, use the matrix-exponential approach, which handles all three regimes uniformly.
Sign of r vs sign of b
. For (the usual physical case), the solution decays when (positive damping) and grows when (negative damping — an energy-pumping system). Always sanity-check by reading off the sign of .
Summary
For a homogeneous second-order linear ODE with constant coefficients and discriminant :
- The single repeated root is .
- The general solution is . The mysterious factor of arises from three independent viewpoints: coalescence of two close roots, reduction of order, and the Jordan-block structure of the companion matrix.
- The two constants are and .
- Physically this is the boundary between overdamped and underdamped behaviour — critical damping, .
- The solution can change sign at most once (no oscillation), at .
Key formulas at a glance
| Quantity | Formula |
|---|---|
| Discriminant | Δ = b² − 4ac = 0 |
| Repeated root | r = −b / (2a) |
| Fundamental set | { e^(rt), t·e^(rt) } |
| General solution | y(t) = (C₁ + C₂t) e^(rt) |
| First constant | C₁ = y(0) |
| Second constant | C₂ = y'(0) − r·y(0) |
| Wronskian | W(t) = e^(2rt) (never zero) |
| Single zero crossing | t = −C₁/C₂ (if C₂ ≠ 0) |
| Matrix view | exp(A t) = e^(rt) (I + (A − rI) t), (A − rI)² = 0 |
Coming next: Section 22.04 turns to nonhomogeneous equations and the method of undetermined coefficients. The homogeneous theory we have built — distinct, repeated, complex — provides the natural building blocks for the general nonhomogeneous solution.