Responsive Navbar with Google Search
Ordinary Differential Equation-2: 2nd Order ODE (RK2 Method)
Python runs in your browser. Heavy or infinite loops may freeze your browser tab. Use "Stop" if needed; for heavy jobs, run locally.
Program 1

2nd Order ODE (RK2 Method)

Damped Harmonic Oscillator ODE Solution

This program uses numerical methods to solve the ordinary differential equation (ODE) for a damped harmonic oscillator. The ODE is given by:

\(\frac{d^2x}{dt^2} + 2 \zeta \omega_n \frac{dx}{dt} + \omega_n^2 x = 0\)

Initial Conditions: \(x(t=0)=1 \quad \frac{dx}{dt}_{t=0}=0\)

Output 1
Program 2

2nd Order ODE (RK2 Method)

Solve a forced oscillation differential equation using the RK2 (Runge-Kutta 2nd order) method, we consider a standard form of the equation:

$$ m \frac{d^2 x}{dt^2} + b \frac{dx}{dt} + kx = F_0 \sin(\omega t) $$

Initial conditions:$$ x(0) = 0 \quad \frac{dx}{dt}\big|_{t=0} = 0 $$

Output 2