ODEHard
2nd order ODE — harmonic oscillator
Solve the differential equation y″ + 4y = 0 with initial conditions y(0) = 2, y′(0) = 0.
Given data
y″ + 4y = 0y(0) = 2y'(0) = 0- Write the associated characteristic equation.
- Solve the characteristic equation: λ² = −4.
- Apply y(0) = 2 to find C₁.
- Calculate y′(x) and apply y′(0) = 0 to find C₂.
Full worked solution
- Write the associated characteristic equation.The characteristic equation is . Obtained by substituting , which gives .
- Solve the characteristic equation: λ² = −4.. Complex conjugate roots with give the general solution .
- Apply y(0) = 2 to find C₁.. Using , , we find .
- Calculate y′(x) and apply y′(0) = 0 to find C₂.. At : . The solution is .
Result:y(x) = 2·cos(2x).