Simple Harmonic Motion Calculator (Spring-Mass & Pendulum)
Calculate the period, frequency, and angular frequency of a spring-mass system or a simple pendulum, and visualize how displacement, velocity, and acceleration change over time. Learn the physics of oscillation from spring constant and mass, or pendulum length and gravity.
Tips
- A spring-mass system's period depends only on the spring constant and mass, not the amplitude. Try changing the amplitude and notice how the period stays the same on the graph.
- The pendulum formula T=2π√(L/g) is only accurate for small swing angles (roughly under 15°). Larger angles make the real period longer than this calculated value.
- Mass has no effect at all on a simple pendulum's period. A heavier or lighter bob on the same length string will swing with the same period.
- Switch gravity to "Moon" to see how the same pendulum length produces a longer period than on Earth — weaker gravity means a weaker restoring force, so the swing is slower.
- Notice on the graph that velocity is zero exactly when displacement is at its peak or trough — this visually shows the 90-degree phase difference between displacement and velocity.
Frequently Asked Questions
Side Note — Galileo and the Swinging Lamp
A famous story often used to introduce simple harmonic motion involves a young Galileo Galilei watching a swinging chandelier in a cathedral. Using his own pulse as a timer, he is said to have noticed that even as the swing gradually grew smaller, the time for each full swing barely changed. This observation is widely credited as an early step toward the invention of the pendulum clock and the broader mathematical description of oscillation in physics.
Spring-mass systems and pendulums look and move very differently, but mathematically both are governed by the same underlying property: a restoring force proportional to displacement (a linear, Hooke's-law-like relationship). Because of this shared structure, the theory of simple harmonic motion extends far beyond springs and pendulums — to tuning fork vibrations, LC oscillations in AC circuits, and even models of molecular bonds.
Real springs and pendulums gradually lose amplitude to friction, air resistance, and internal material damping — a phenomenon called damped oscillation. The idealized simple harmonic motion modeled by this tool assumes no energy loss. Measuring a pendulum's period to determine the local gravitational acceleration g remains a classic physics classroom experiment, offering a hands-on connection between this formula and real-world measurement.