This Demonstration provides a visualization of the classical damped driven harmonic oscillator. The first plot shows the solution of the differential equation; you can choose the initial boundary condition as the tangent to the solution curve at a specified point by dragging the two locators. The second graphic plots the amplitude versus frequency, which peaks at a resonance.

The equation is , where is the mass of a block on a spring, is the damping factor, and is the spring constant. The right-hand side of the equation is the driving force involved in motion. Specifically, it is a periodic force with frequency and amplitude . The boundary condition applied to this equation gives exactly one solution.

The resonance curve of the differential equation is given by , which may have a singularity at the resonance frequency .