Simple Harmonic Motion (SHM) Calculator

Calculate displacement, velocity, acceleration, and energy for simple harmonic motion at any time.

ω = 2πf = √(k/m)
Please check your inputs and try again.

Reading Position, Velocity, and Acceleration in SHM

Simple harmonic motion occurs when acceleration is proportional to displacement and always points back toward equilibrium. The defining relationship is a=−ω2x. The minus sign matters: if the object is displaced in the positive direction, its acceleration is negative, and vice versa. This restoring behavior produces a repeating sinusoidal motion rather than motion at constant speed.

For the common zero-phase form x=A cos(ωt), the object starts at maximum positive displacement at t=0. Its speed is zero there, then increases as it moves toward equilibrium. At x=0 the speed is greatest and acceleration is zero. At either turning point x=±A, the speed returns to zero and acceleration has its greatest magnitude.

x=A cos(ωt),   v=−Aω sin(ωt),   a=−ω2x
SymbolMeaningWhy it appears / units
AAmplitudeMaximum displacement from equilibrium, in meters.
ωAngular frequencyRadians per second; ω=2πf.
TPeriodT=2π/ω, the time for one complete cycle.
x, v, aInstantaneous motion variablesPosition (m), velocity (m/s), acceleration (m/s2).

Energy provides a second way to interpret SHM. In an ideal oscillator, kinetic and potential energy trade back and forth while total mechanical energy stays constant. Increasing amplitude increases total energy as A2, but for an ideal spring-mass oscillator it does not change the period. Real systems eventually lose energy through damping, so their amplitudes shrink with time.

Worked Examples

Example 1: Spring: A=0.1m, ω=5rad/s, t=0.2s
x=0.1cos(1.0)=0.054m
Result: v=-0.421m/s, a=-1.35m/s²
Position, velocity, acceleration at t=0.2s
Example 2: At t=T/4 (quarter period)
x=A cos(π/2)=0
Result: v=-Aω (max speed!)
Maximum speed at equilibrium position
Example 3: Half a period after release
At t=T/2, ωt=π → x=A cos(π)=−A and v=−Aωsin(π)=0
Result: x=−A, v=0
The oscillator has reached the opposite turning point. Its acceleration points back toward equilibrium and has maximum magnitude.
Example 4: Energy and maximum speed
A=0.05m, ω=10rad/s, m=0.20kg → E=0.5mω2A2
Result: E=0.025 J and vmax=0.50 m/s
The maximum speed occurs at equilibrium, where all of the ideal oscillator's mechanical energy is kinetic.

Common Mistakes

⚠️
Confusing frequency f with angular frequency ω

They are related by ω=2πf. Putting hertz directly into a formula that expects rad/s introduces a factor of 2π error.

⚠️
Dropping the minus sign in acceleration

The relation a=−ω2x encodes the restoring direction. Without the minus sign, the motion would accelerate away from equilibrium rather than oscillate.

⚠️
Assuming speed is greatest at maximum displacement

At x=±A the object turns around, so v=0. Speed is greatest at x=0, where the oscillator passes through equilibrium.

Frequently Asked Questions

Where is speed maximum in SHM?
At x=0 (equilibrium). v_max=Aω. All energy is kinetic. At x=±A (amplitude), speed=0, all energy is potential.
SHM equations summary?
x=A cos(ωt+φ), v=-Aω sin(ωt+φ), a=-ω²x. Note a=-ω²x is the defining property of SHM — restoring force proportional to displacement.
What condition makes motion simple harmonic?
The acceleration must be directly proportional to displacement from equilibrium and opposite in direction: a=−ω2x. Equivalently, the restoring force is proportional to −x. A mass on an ideal spring satisfies this exactly within Hooke's-law behavior; a pendulum does so approximately only for small angles.
How are period, frequency, and angular frequency related?
Frequency is cycles per second, so f=1/T. Angular frequency measures phase change in radians per second and is ω=2πf=2π/T. The three quantities describe the same repetition rate in different forms, so converting between them correctly is essential before substituting into SHM equations.
Does a larger amplitude change the period of ideal SHM?
For an ideal mass-spring oscillator obeying Hooke's law, the period depends on mass and spring constant, not amplitude. A larger amplitude increases maximum speed and total energy, but not the ideal period. In real systems, large motion can enter nonlinear behavior where this approximation no longer holds.
Why is acceleration zero at equilibrium?
At equilibrium, x=0, so a=−ω2x is also zero. That does not mean the oscillator stops. In fact, its speed is maximum there because potential energy is minimum and kinetic energy is maximum. The object continues through equilibrium due to its inertia.

Formula Explorer connections

Interpretation: This relationship connects motion, force, momentum, work or energy in a mechanical system. Assumption: Choose a consistent reference direction and unit system. The model may assume constant acceleration, rigid bodies, negligible losses or an isolated system.

Speed Distance Time Calculator →Spring Constant Calculator →Static Equilibrium Calculator →Physics Formula Explorer →