Pulsars
0 %
Log inSign up

The harmonic oscillator

Setting Up the Equation of the Harmonic Oscillator

The mass-spring system

Consider a mass m attached to a spring of stiffness k, sliding without friction on a horizontal axis. Its position is described by x(t), the displacement from the equilibrium position.

Hooke's law and Newton's second law

The spring exerts a restoring force F = -k.x (Hooke's law: proportional to the displacement, directed toward equilibrium). Applying Newton's second law (m.a = sum of forces):

m.x''(t) + k.x(t) = 0

We define omega0 = sqrt(k/m), the natural angular frequency (in rad/s). The equation becomes:

x''(t) + omega0^2 . x(t) = 0

This is the canonical differential equation of the harmonic oscillator, found in many different contexts (LC circuit, pendulum for small oscillations, diatomic molecule...).

General solution

The solution is written:

x(t) = A.cos(omega0.t + phi)

where A (amplitude) and phi (initial phase) are set by the initial conditions x(0) and x'(0). The natural period is T0 = 2.pi/omega0.

Summary table

Quantity Symbol Expression
Natural angular frequency omega0 sqrt(k/m)
Natural period T0 2.pi/omega0
Natural frequency f0 1/T0

Common pitfall

Do not confuse omega0 (angular frequency, rad/s) with f0 (frequency, Hz): omega0 = 2.pi.f0. A common mistake is to plug f0 directly into cos(f0.t) instead of omega0.t.