Simple harmonic motion is the back-and-forth of a mass on a spring, its period set by T = 2π·sqrt(m/k). Drag the sliders below to change the mass, spring constant and amplitude, and watch the period, frequency and the kinetic/potential energy split respond in real time.

Simple Harmonic Motion

A mass on a spring. Change the mass, stiffness, and amplitude, then watch the motion and energy respond.

T = 2π·sqrt(m/k)

Controls

0.50 kg
40 N/m
0.12 m

Live readings

Displacement x0.120m
Velocity v0.00m/s
Acceleration a0.0m/s²
Period T0.000s
Frequency f0.00Hz
Kinetic KE0.000J
Potential PE0.000J
Total energy E0.000J

Energy is conserved: KE + PE = E at every instant. Speed peaks at the centre; acceleration peaks at the turning points.

What Is the Simple Harmonic Motion Simulator?

The simple harmonic motion simulator is a free interactive physics lab that runs in your browser — nothing to install and no sign-up. Change the mass, spring constant and amplitude and watch the period, frequency and energy respond.

What you can change in the simple harmonic motion simulator
ControlRangeStep
Mass0.10 – 2.00 kg0.01
Spring constant per metre5 – 100 N1
Amplitude0.02 – 0.20 m0.01

Watch Energy Slosh Between Spring and Mass

Every cycle of simple harmonic motion is a trade: the spring stores elastic potential energy as it stretches and compresses, then hands it back to the mass as kinetic energy through the middle. This simulator lets you feel that exchange directly. Watch the KE and PE readouts as the block travels — they rise and fall in perfect opposition while Total energy E holds fixed, because the ideal model has no damping and KE + PE = E at every instant.

Now drag the Amplitude A slider and keep your eye on Period T and Frequency f. They do not budge. Pulling the mass twice as far only raises the energy, since E = 1/2·k·A², and lifts the peak speed — the rhythm itself is isochronous. Only the Mass m and Spring constant k sliders change the timing, through T = 2π·sqrt(m/k): load on more mass and the beat slows, stiffen the spring and it quickens.

The turning points expose the classic trap. Speed hits zero at x = ±A, yet the mass is not resting there — acceleration and restoring force peak exactly then, since a = -ω²·x, which is what flings it back. Maximum speed lives at the centre, where PE reads zero. Put real numbers to it with the simple harmonic motion calculator, then take the same hands-on approach to waves, pendulums, and circuits waiting across the full shelf of physics simulations.

Frequently asked questions

What determines the period of a mass on a spring?

Only the mass and the spring constant: T = 2π·sqrt(m/k). A heavier mass lengthens the period; a stiffer spring shortens it. The amplitude has no effect on the period at all.

Does the amplitude change the period?

No. Simple harmonic motion is isochronous — the period stays the same however far you pull the mass. A larger amplitude raises the total energy (E = ½·k·A²) and the peak speed, but the period and frequency are unchanged.

Where is the mass moving fastest?

At the centre, the equilibrium point, where all the energy is kinetic and the potential energy reads zero. At the two turning points the speed is zero — but the mass is not resting there: the acceleration and restoring force are at their maximum, which is what reverses it.

Is energy conserved in simple harmonic motion?

In the ideal, undamped model, yes. Energy shuttles back and forth between kinetic and elastic potential every quarter cycle while the total, KE + PE = E, stays constant. Real oscillations lose energy to friction and slowly decay.

References & formula source

  • Halliday, Resnick & Walker — Fundamentals of Physics, Chapter 15 (Oscillations).
  • Young & Freedman — University Physics with Modern Physics, §14.2–14.3 (SHM; Energy in SHM).
  • R. Nave — HyperPhysics, Georgia State University, "Simple Harmonic Motion" section.
  • Further reading: Simple harmonic motion — Wikipedia