Waves & Oscillationsx = A cos(ωt + φ)

Simple Harmonic Motion Simulator

Explore spring-mass oscillations with adjustable mass, spring constant, and damping. See displacement graph update in real time.

— x(t)- - envelope
Parameters
Amplitude A₀
m
Mass m
kg
Spring constant k
N/m
Damping b
N·s/m

Predicted
ω₀6.32 rad/s
Period0.993 s
ωd6.32 rad/s

Time0.00 s
x0.000 m
v0.000 m/s
ω₀0.00 rad/s
Period0.000 s
Energy0.0000 J

About Simple Harmonic Motion

Simple Harmonic Motion (SHM) occurs whenever a restoring force is proportional to displacement from equilibrium. The classic example is a mass on a spring: the spring pulls or pushes the mass back toward the centre with force F = −kx.

Any system where the net restoring force is proportional to displacement exhibits SHM — springs, pendulums (small angles), LC circuits, and many molecular vibrations.

Key Variables

SymbolNameUnitDescription
kSpring ConstantN/mStiffness of the spring
mMasskgMass of the oscillating object
bDamping CoefficientN·s/mResistance force per unit velocity
AAmplitudemInitial displacement from equilibrium
ω₀Natural Frequencyrad/s√(k/m) — frequency without damping
ωdDamped Frequencyrad/s√(ω₀² − (b/2m)²)
TPeriodsTime for one complete oscillation
γDamping Ratios⁻¹b/m — controls decay rate

Worked Example

A 0.5 kg mass on a spring with k = 20 N/m, released from x₀ = 1.0 m at rest, with no damping:

Effect of Damping

  • Underdamped (b < 2√(km)): oscillation with decaying amplitude — what the simulator shows.
  • Critically damped (b = 2√(km)): fastest return to equilibrium without oscillating.
  • Overdamped (b > 2√(km)): slow exponential return, no oscillation.
💡Set b = 0 for pure SHM. Increase b to see the amplitude decay. The graph shows the envelope curve e^(−γt/2) as a dashed line.

Energy in SHM

Total mechanical energy (undamped) is conserved and equals the initial potential energy:

With damping, energy is dissipated as heat. The total energy decays as E(t) = ½kA² e^(−γt).

Key Formulas

Equation of Motion

Displacement (Underdamped)

Natural and Damped Frequencies

Period and Frequency

Energy

FormulaDescriptionNotes
ω₀ = √(k/m)Natural angular frequencyIncreases with k, decreases with m
T = 2π√(m/k)PeriodIndependent of amplitude (for small oscillations)
x(t) = A cos(ω₀t)Undamped displacementPhase φ depends on initial conditions
v(t) = −Aω₀ sin(ω₀t)Velocity90° phase shift from displacement
x(t) = A e^(−γt/2) cos(ωdt)Damped displacementAmplitude decays exponentially
E = ½kA²Total energyConserved only when b = 0
The period T = 2π√(m/k) is independent of amplitude — a heavier mass oscillates more slowly, a stiffer spring oscillates more quickly.

Frequently Asked Questions

Why does a heavier mass oscillate more slowly?

The period T = 2π√(m/k) increases with mass. A heavier mass has more inertia, so it accelerates less for the same restoring force, taking longer to complete each cycle.

Does amplitude affect the period of a spring-mass system?

No. Unlike a pendulum at large angles, a spring-mass system follows Hooke's Law exactly, so the period T = 2π√(m/k) is independent of amplitude.

What is critical damping?

Critical damping (b = 2√(km)) gives the fastest return to equilibrium without oscillating. Used in car suspensions and door closers where you want quick settling without ringing.

What happens to energy with damping?

Energy is dissipated as heat through the damping force. Total mechanical energy decays as E(t) = ½kA² · e^(−γt) where γ = b/m.

What is the difference between ω₀ and ωd?

ω₀ = √(k/m) is the natural frequency (no damping). ωd = √(ω₀² − (b/2m)²) is the damped frequency, which is slightly lower. With no damping they are equal.