Higher Order Linear ODEs with Constant Coefficients: Complementary Functions & Operator D Methods
Idea in plain words
nth-order Linear ODE: a_n (d^n y/dx^n) + a_{n-1} (d^{n-1} y/dx^{n-1}) + ... + a_0 y = X(x).
Exam tip
High-yield exam topic (Very High).
Explanation
Linear differential equations with constant coefficients describe physical systems governed by time-invariant linear laws (e.g., RLC circuits, mechanical oscillators). The algebraic operator D acts as an algebraic polynomial over the ring of infinitely differentiable functions. The complementary function represents the natural transient response of the system (decaying to zero in dissipative systems), while the particular integral represents the forced steady-state response.
Key points
- Differential Operator notation: D = d/dx, D² = d²/dx² => f(D) y = X(x).
- Complete Solution: y = y_c (Complementary Function) + y_p (Particular Integral).
- Auxiliary Equation (AE): f(m) = 0.
- Case 1 (Real distinct roots m₁, m₂): y_c = c₁ e^{m₁x} + c₂ e^{m₂x}.
- Case 2 (Real repeated roots m₁ = m₂ = m): y_c = (c₁ + c₂x) e^{mx}.
- Case 3 (Complex roots α ± iβ): y_c = e^{αx} [c₁ cos βx + c₂ sin βx].
- Rules for Particular Integral y_p = [1 / f(D)] X(x):
- Rule 1: [1 / f(D)] e^{ax} = e^{ax} / f(a), provided f(a) ≠ 0. If f(a) = 0, y_p = x [1 / f'(D)] e^{ax}.
- Rule 2: [1 / f(D²)] sin ax = sin ax / f(-a²), provided f(-a²) ≠ 0. Same for cos ax.
- Rule 3: [1 / f(D)] x^m = [f(D)]⁻¹ x^m by expanding [f(D)]⁻¹ in ascending powers of D via binomial theorem.
- Rule 4: [1 / f(D)] [e^{ax} V(x)] = e^{ax} [1 / f(D + a)] V(x) (Exponential Shift Theorem).
Example
Example
Solve (D² + 9) y = cos 3x: AE: m² + 9 = 0 => m = ±3i => y_c = c₁ cos 3x + c₂ sin 3x. Since f(-3²) = 0, y_p = x [1 / 2D] cos 3x = (x/2) (sin 3x / 3) = (x/6) sin 3x. General solution: y = c₁ cos 3x + c₂ sin 3x + (x/6) sin 3x.
Code examples
// Comprehensive Solution: Non-Homogeneous Second Order Linear ODE
// Solve: (D^2 - 4D + 4) y = 8 (e^{2x} + sin 2x + x^2)
// Step 1: Auxiliary Equation:
// m^2 - 4m + 4 = 0 => (m - 2)^2 = 0 => m = 2, 2 (Repeated real roots)
// Complementary Function: y_c = (c1 + c2 x) e^{2x}
//
// Step 2: Particular Integral y_p = y_p1 + y_p2 + y_p3:
// Part (a): X1 = 8 e^{2x}
// f(D) = (D - 2)^2. Since f(2) = 0, use shift / derivative rule:
// y_p1 = 8 * [1 / (D - 2)^2] e^{2x} = 8 * e^{2x} * [1 / D^2] (1)
// = 8 e^{2x} * (x^2 / 2) = 4 x^2 e^{2x}
//
// Part (b): X2 = 8 sin 2x
// Replace D^2 with -(2^2) = -4 in f(D) = D^2 - 4D + 4:
// y_p2 = [1 / (-4 - 4D + 4)] (8 sin 2x) = [1 / (-4D)] (8 sin 2x)
// = (-2) * ∫ sin 2x dx = (-2) * (-cos 2x / 2) = cos 2x
//
// Part (c): X3 = 8 x^2
// Expand [f(D)]^-1 = 4^-1 [ 1 - (D - D^2/4) ]^-1 = (1/4) [ 1 + D - D^2/4 + D^2 + ... ]
// y_p3 = 8 * (1/4) [ 1 + D + (3/4) D^2 ] x^2
// = 2 [ x^2 + 2x + (3/4)(2) ] = 2x^2 + 4x + 3
//
// Step 3: Complete General Solution:
// y = (c1 + c2 x) e^{2x} + 4 x^2 e^{2x} + cos 2x + 2x^2 + 4x + 3
Exam questions
- [8 Marks] Solve: (D³ - 3D² + 4) y = e^{2x} + x + sin 2x.
- [8 Marks] Solve: (D² - 2D + 1) y = x e^x sin x.
- [7 Marks] Solve: (D² + 4) y = sec 2x by operator methods.