This calculator works out the motion of an object undergoing simple harmonic motion, finding its position, velocity and acceleration at any instant, along with the period of oscillation. Simple harmonic motion, or SHM, is the smooth back-and-forth oscillation that appears throughout physics whenever a restoring force pulls an object back toward a central position in proportion to how far it has strayed. A mass bouncing on a spring, a pendulum swinging through small angles, a vibrating guitar string, and the oscillation of atoms and circuits all follow it. The motion is described by a few key quantities: the amplitude, the maximum displacement from the centre; the frequency, how many oscillations occur per second; and from these the angular frequency and the period. At any moment the object's position traces a cosine curve, its velocity is greatest at the centre and zero at the extremes, and its acceleration is greatest at the extremes and zero at the centre, always pointing back toward the middle. This tool computes them. You enter the amplitude, the frequency, and a time of interest, and the calculator returns the position at that time, the velocity at that time, the maximum velocity, and the period. The results update as you type, so you can trace how the motion evolves. Use it for physics problems on springs, pendulums and waves, for understanding oscillations, or for engineering vibration work. The relationships are clean: the angular frequency is two pi times the frequency, the maximum velocity is the amplitude times the angular frequency, and the maximum acceleration is the amplitude times the angular frequency squared. A defining feature of simple harmonic motion is that the period depends only on the system's properties, not on the amplitude, which is why a pendulum keeps good time whether it swings a little or a lot.
x = A cos(2 pi f t), with velocity and acceleration following. Max velocity = A x angular frequency. The period depends only on frequency, not amplitude. Rounded for display.
The angular frequency is two pi times the frequency. The position at time t is the amplitude times the cosine of the angular frequency times t, taking the object to start at maximum displacement. The velocity is minus the amplitude times the angular frequency times the sine of that angle. The maximum velocity is the amplitude times the angular frequency, and the period is one over the frequency.
For an amplitude of 0.1 metres at a frequency of 2 hertz, the angular frequency is 4 pi, about 12.57 radians per second. At 0.1 seconds, the position is 0.1 times the cosine of 1.257 radians, about 0.0309 metres, and the velocity is about minus 1.195 metres per second. The maximum velocity is 0.1 times 12.57, about 1.257 metres per second, and the period is 0.5 seconds.
It is smooth back-and-forth oscillation that occurs when a restoring force pulls an object toward a central position in proportion to its displacement. Springs, pendulums at small angles, and vibrating strings all follow it. The position traces a cosine curve over time.
In simple harmonic motion the restoring force grows in exact proportion to displacement, so a larger swing means a larger force that returns the object faster, exactly cancelling the extra distance. The period therefore depends only on the system, not on how far it swings, which is why pendulums keep good time.
Velocity is greatest as the object passes through the central equilibrium position and zero at the extremes of the swing, where it momentarily stops to turn around. Acceleration is the opposite: greatest at the extremes, pointing back to the centre, and zero at the middle.
If you've found a bug, or would like to contact us, or learn more about James Graham and Calculate.co.nz.
Calculate.co.nz is partnered with Interest.co.nz for New Zealand's highest quality calculators and financial analysis.
Calculate.co.nz is the sister site of CalculatorHub.com, the world's largest calculator website by tool count.
All calculators and tools are provided for educational and indicative purposes only and do not constitute financial advice.
Calculate.co.nz is proudly part of the Realtor.co.nz group, New Zealand's leading property transaction literacy platform, helping Kiwis understand the home buying and selling process from start to finish. Whether you're a first home buyer navigating your first property purchase, an investor evaluating your next acquisition, or a homeowner planning to sell, Realtor.co.nz provides clear, independent, and trustworthy guidance on every step of the New Zealand property transaction journey.
Calculate.co.nz is also partnered with Health Based Building and Premium Homes to promote informed choices that lead to better long-term outcomes for Kiwi households.
Calculate.co.nz is hosted in Auckland by SiteHost New Zealand.
All content on this website, including calculators, tools, source code, and design, is protected under the Copyright Act 1994 (New Zealand). No part of this site may be reproduced, copied, distributed, stored, or used in any form without prior written permission from the owner.
About & trust: Why Calculate is NZ's most comprehensive · By the Numbers · How we compare · Editorial standards · How we keep data current · NZ finance glossary · Research & data · Financial literacy NZ · About · Privacy policy · Terms of use
Reviewed and maintained. Last reviewed 2026-08-15 and checked on a twice-monthly cycle against IRD, RBNZ and Stats NZ. How we keep data current.
© 2026 Calculate.co.nz. All rights reserved. Building free NZ calculators since 2011.