Variation of parameters
Find a particular solution yp = u₁y₁ + u₂y₂ of y'' + p y' + q y = g(t) for any continuous g from the Wronskian formulas, and use it where undetermined coefficients fails.
It opens on
Try guessing yp for y'' + y = sec t. Differentiate sec t a few times: do its derivatives ever settle into a finite list of shapes?
Why it matters
Real forcing is rarely a polynomial or a sinusoid: a rectified current, a tide or a pulse train is any function, and this method turns the forced equation into two integrals.
Good to know first
- Undetermined coefficients: y = yc + yp
- the Wronskian W = y₁y₂' − y₁'y₂ of a fundamental set is never zero
- ∫ tan t dt = −ln|cos t|
Step by step
Why guessing fails for sec t
See that sec t has infinitely many distinct derivatives, so no finite guess works, and state the idea of letting c₁ and c₂ vary.
The first derivative of sec t is sec t tan t, and the second is sec t tan²t + sec³t, shapes with no finite span.
A common mix-up
Sec t is just cos t upside down, so a guess like A cos t works.
In fact: Sec t is not a combination of cos t and sin t, and no finite guess reproduces its derivatives.
The formulas for u₁' and u₂'
Derive and apply yp = −y₁∫(y₂g/W)dt + y₂∫(y₁g/W)dt to y'' + y = sec t.
The two conditions are u₁'cos t + u₂'sin t = 0 and −u₁'sin t + u₂'cos t = sec t.
A common mix-up
The constants of integration in u₁ and u₂ matter.
In fact: Any constants only add c₁y₁ + c₂y₂ to yp, which is already in yc, so take them zero.
The full solution and a second forcing
Assemble y = yc + yp, fit a start, and repeat the method for the forcing tan t.
The general solution is y = c₁cos t + c₂sin t + cos t ln(cos t) + t sin t on −π/2 < t < π/2.
A common mix-up
Variation of parameters gives a different family of solutions from undetermined coefficients.
In fact: Any yp differs from another by a homogeneous solution, so the general solution is the same family.
Try it
For which of g = t³, e2t, 1/t, sin 3t does a guess for y'' + y = g fail?Answer
Only 1/t, whose derivatives −1/t², 2/t³, ... are always new
Hint: Look at the list of derivative shapes
Check that y = t sin t + cos t ln(cos t) has y(0) = 0 and y'(0) = 0.Answer
y(0) = 0 + 1·ln 1 = 0 and y'(0) = −sin 0 ln 1 + cos 0 · 0 = 0
Hint: Differentiate each product
For y'' + y = tan t, state u₂ and the Wronskian used.Answer
W = 1 and u₂ = −cos t
Hint: u₂' = y₁g/W = cos t tan t = sin t
Which finite family would a guess for sec t need, and does it exist?Answer
None: the derivatives sec t, sec t tan t, sec t tan²t + sec³t, ... are new each time.
In general, what are the formulas for u₁' and u₂' in terms of y₁, y₂, g and W?Answer
u₁' = −y₂g/W and u₂' = y₁g/W.
