Spring-Mass Oscillator Calculator (Simple Harmonic Motion)

A mass on a spring is the model for every simple harmonic oscillator, from vehicle suspensions to molecules. Enter the mass, spring constant and amplitude to get the natural frequency, period, peak speed, acceleration and force, and the energy stored in the motion.

Inputs

Advanced options (1)

Results

Natural frequency
3.183
Period
0.3142
Angular frequency ω
20
Maximum speed
1
Maximum acceleration
20
Maximum spring force
10
Total energy of oscillation
0.25
Static stretch when hung vertically
24.52

    RefPHY-MEC-010
    Methodω = √(k/m), T = 2π√(m/k)
    UnitsSI
    Date2026-11-24

    Working

    Calculated in SI base units; inputs are converted from the units you choose.

    1. Moving massm_eff = m + m_spring/3m_eff = 0.5 + 0/3 = 0.5 kg
    2. Angular frequencyω = √(k/m_eff)ω = √(200 / 0.5) = 20 rad/s
    3. Frequency and periodf = ω/2π, T = 1/ff = 3.183 Hz, T = 0.3142 s
    4. Peak valuesv_max = Aω, a_max = Aω², F_max = kAv_max = 1 m/s, a_max = 20 m/s², F_max = 10 N
    5. EnergyE = ½kA²E = 0.5 × 200 × 0.05² = 0.25 J

    Frequency does not depend on amplitude

    For a linear spring the restoring force is −kx, giving x(t) = A·cos(ωt + φ) with ω = √(k/m). The period is the same for large and small swings. Hanging the system vertically shifts the equilibrium by mg/k but does not change the frequency, so f = (1/2π)√(g/δ) where δ is the static stretch.

    Assumptions and limits

    • Linear (Hookean) spring within its elastic range.
    • No damping; see the damped oscillator calculator for decay.
    • Spring mass, if entered, is included with Rayleigh’s one-third approximation.

    References

    • Halliday, D., Resnick, R. and Walker, J., Fundamentals of Physics, 12th ed., Wiley, 2021, chapter on oscillations.
    • Rao, S. S., Mechanical Vibrations, 6th ed., Pearson, 2017, chapter on free vibration of single-degree-of-freedom systems.

    Questions

    What is the frequency of a 0.5 kg mass on a 200 N/m spring?
    3.18 Hz, a period of 0.314 s. With a 50 mm amplitude the mass peaks at 1 m/s and the oscillation holds 0.25 J.
    Does adding mass lower the frequency?
    Yes, as 1/√m. Four times the mass halves the frequency: 2 kg on the same spring gives 1.59 Hz.

    This calculator is a design aid. Check results against the governing code or standard and have critical work verified by a qualified engineer. Read the disclaimer.