Second-Order Differential Equations
Solve y″ + py′ + qy = 0 with initial values — all three cases: distinct real roots, a repeated root, and complex roots with oscillation — via the characteristic equation, constants solved in front of you.
Example — y″ − 3y′ + 2y = 0, y(0) = 1, y′(0) = 0y = 2eˣ − e²ˣ — y(1) = −1.9525
Equation: y″ + p·y′ + q·y = 0, with y(0) and y′(0) given.
How we got it — the example, step by step
- Characteristic equation: r² − 3r + 2 = 0. Discriminant: 9 − 8 = 1. Roots: r = 2 and r = 1.
- General solution: y = C₁eˣ + C₂e²ˣ. Initial values: C₁ + C₂ = 1 and C₁ + 2C₂ = 0, giving C₁ = 2, C₂ = −1.
Check it backwards
At x = 0: 2 − 1 = 1 = y(0). Substituting y, y′ and y″ into the equation gives (2eˣ − 4e²ˣ) − 3(2eˣ − 2e²ˣ) + 2(2eˣ − e²ˣ) = 0 at every x — the eˣ terms: 2 − 6 + 4 = 0; the e²ˣ terms: −4 + 6 − 2 = 0.
Questions people also ask
What changes when the roots are complex?
The solution oscillates: y = e^(αx)(C₁ cos βx + C₂ sin βx). The real part α controls growth or decay of the envelope; β is the frequency. The tool detects the case from the discriminant's sign and says which one you are in.