Simple Harmonic Calculator
What is the Simple Harmonic Calculator?
What this page computes
This page models one thing only: a mass bouncing on an ideal spring. Give it the mass, the spring constant, the amplitude, and a moment in time, and it returns the angular frequency, the period, the frequency, the displacement at that moment, and the maximum velocity of the mass.
The opening defaults
The defaults are a mass of 0. 5 kg, a spring constant of 20 N/m, an amplitude of 0. 1 m, and a time of 0. 5 s. The answers: angular frequency 6. 3246 rad/s, period 0. 9935 s, frequency 1. 0066 Hz, displacement −0. 1 m, and maximum velocity 0. 6325 m/s.
What simple harmonic motion is
Motion is simple harmonic when the restoring pull is always proportional to how far the object sits from its resting point, and always points back toward it. A spring obeying Hooke's law is the textbook example: stretch it twice as far and it pulls back twice as hard.
The mass and spring fields
Mass is in kilograms and Spring Constant k is in newtons per meter, a stiffness rating: bigger k means a harder spring. Stiffer springs and lighter masses both oscillate faster, and the two fields fight it out inside a square root, so quadrupling k only doubles the speed.
Angular frequency
Angular Frequency is ω = √(k / m), here √(20 / 0. 5) = √40 = 6. 3246 rad/s. Despite the name it is not the cycles-per-second figure; it is the angle swept per second on the equivalent rotating circle, and every other result on the page is built from it.
Period and frequency
Period is the time for one full back-and-forth cycle: T = 2π / ω, here 0. 9935 s. Frequency counts cycles per second: f = 1 / T, here 1. 0066 Hz. The two always multiply to exactly 1, which makes each one a free check on the other.
The amplitude field
Amplitude is the greatest distance from the resting point, in meters: 0. 1 m at the defaults. It sets the size of the motion and, with ω, its fastest speed — but it has no effect on timing at all. An ideal spring keeps the same period whether it swings widely or barely moves.
Displacement at time t
Displacement at Time t is x = A × cos(ω × t), which assumes release from rest at full positive stretch when the clock started. At t = 0. 5 s, ωt = 3. 1623 radians, just past π, so the true value is −0. 09998 m and the display rounds it to −0.
1: nearly full stretch on the far side.
Maximum velocity
Maximum Velocity is A × ω, here 0. 1 × 6. 3246 = 0. 6325 m/s. The mass reaches it not at the extremes but while passing through the resting point, where the spring is unstretched and nothing slows it. At both extremes, by contrast, the mass is momentarily stopped while it turns around.
A heavier mass on a stiff spring
Set mass 2 kg and k = 72 N/m, with amplitude 0. 25 m and time 1. 5 s. Then ω = √(72 / 2) = 6 rad/s, the period is 1. 0472 s, the frequency 0. 9549 Hz, displacement at 1. 5 s is −0. 2278 m, and maximum velocity is 1. 5 m/s.
A light mass on a soft spring
Set mass 0. 2 kg, k = 5 N/m, amplitude 0. 4 m and time 0. 3 s. Then ω = √25 = 5 rad/s, the period is 1. 2566 s, frequency 0. 7958 Hz, displacement is 0. 0283 m, and maximum velocity reaches 2 m/s, because the wide swing beats the gentle spring.
Slow and heavy
Set mass 1. 6 kg and k = 10 N/m, with amplitude 0. 05 m and time 2 s. Then ω = √(10 / 1. 6) = 2. 5 rad/s, period stretches to 2. 5133 s, the frequency drops to 0. 3979 Hz, displacement at 2 s is 0. 0142 m, and the top speed is 0. 125 m/s.
Fast and small
Set mass 0. 9 kg and k = 810 N/m, with amplitude 0. 02 m and time 0. 1 s. Then ω = √900 = exactly 30 rad/s, the period shrinks to 0. 2094 s, the frequency climbs to 4. 7746 Hz, the displacement is −0. 0198 m, and the maximum velocity is 0. 6 m/s.
The starting position is baked in
The cosine formula silently assumes one specific start: pulled to +A and released from rest. If your mass instead starts at the resting point with a push, its motion follows A × sin(ω × t) and every displacement differs. At t = 0 this page reports A regardless, because that is its assumed start.
Zero spring constant freezes the page
Enter k = 0 and ω becomes 0; a guard then prints Period 0 and Frequency 0 rather than infinity, displacement sits at the amplitude for every time, and maximum velocity is 0. A spring with no stiffness does not oscillate, so read those zeros as no motion, not as measurements of a real cycle.
Zero or negative mass does the same
The angular frequency formula is guarded on mass: at zero or negative mass it returns 0, and the whole cascade of zeros and frozen displacement follows, exactly as with k = 0. A mass of nothing cannot bounce; the guard exists so the page prints something calm instead of dividing by zero.
Negative inputs break the physics quietly
A negative k asks for the square root of a negative number, not a real quantity, so outputs stop being readable seconds and hertz. A negative amplitude flips the start to the far side and prints a negative Maximum Velocity — negative 0. 6325 — though a speed cannot be negative. Keep all three positive.
Velocity and acceleration at other moments, by hand
The page gives velocity only at its peak. At any time, v = −A × ω × sin(ω × t), and acceleration is a = −ω² × x, worst at the extremes where its size is A × ω². At the defaults that peak acceleration is 0. 1 × 40 = 4 m/s².
Energy, by hand
Total energy stays fixed at E = ½ × k × A², here 0. 5 × 20 × 0. 01 = 0. 1 joules, trading back and forth between spring stretch and motion. Check the trade at the resting point: ½ × m × (maximum velocity)² = 0. 5 × 0. 5 × 0. 6325², which is again 0.
1 joules.
Pendulums are not covered
A pendulum is the other classic oscillator, but this page has no length or gravity field and cannot do it. By hand: a pendulum's period is 2π × √(L / g), with L in meters and g = 9. 81 m/s², and its mass cancels out entirely — the opposite of the spring, where mass matters.
Real springs differ
The page is the ideal model: no friction, no air resistance, a weightless spring, and stretches small enough for Hooke's law to hold. Real oscillators slowly lose amplitude to damping, and a spring stretched past its linear range stops keeping the tidy period shown here. Expect drift in the lab, not in the formula.
Units to respect
Mass in kilograms, k in newtons per meter, amplitude in meters, time in seconds — the fields are labeled with these units and the formulas assume them. The common slip is amplitude in centimeters: 10 cm must be entered as 0. 1, or the displacement and velocity answers come out a hundred times too large.
Checking your answer
Three identities audit any run. ω squared must equal k / m. Frequency times period must equal 1. And at t equal to one full period, the displacement must return to exactly +A, because cos(2π) = 1. If any of the three fails, an input was typed into the wrong field.
With the pre-filled defaults — Mass 0. 5kg, Spring Constant k 20N/m, Amplitude 0. 1m, Time 0. 5s — the Simple Harmonic Calculator returns Angular Frequency 6. 3246rad/s, Period 0. 9935s, Frequency 1. 0066Hz, Displacement at Time t -0. 1000m, Maximum Velocity 0. 6325m/s.
Change any input and those results update instantly, so you can see exactly how each number you enter moves the answer.
How to Use the Simple Harmonic Calculator
- 1Enter Mass in kilograms, the object attached to the spring.
- 2Enter Spring Constant k in newtons per meter, the spring's stiffness.
- 3Enter Amplitude in meters, the greatest distance from the resting point.
- 4Enter Time in seconds, the moment you want the position for.
- 5Read Angular Frequency in radians per second, the root of every other result.
- 6Read Period in seconds and Frequency in hertz — they must multiply to 1.
- 7Read Displacement at Time t in meters; negative means the far side of rest.
- 8Read Maximum Velocity in meters per second, the speed at the resting point.
Formula
This is the core equation the Simple Harmonic Calculator uses to calculate results. Enter values in the calculator above to see it in action.
Common Examples
| Scenario | Calculation | Result |
|---|---|---|
| Heavier mass, stiff spring: 2 kg on k = 72 N/m, amplitude 0.25 m | ω = √(72 / 2) = 6 rad/s; T = 2π / 6 = 1.0472 s; f = 1 / T = 0.9549 Hz; x(1.5) = 0.25 × cos(6 × 1.5) = 0.25 × cos(9) = −0.2278 m; maximum velocity = 0.25 × 6 = 1.5 m/s | ω 6 rad/s, period 1.0472 s, frequency 0.9549 Hz, displacement −0.2278 m, maximum velocity 1.5 m/s |
| Light mass, soft spring: 0.2 kg on k = 5 N/m, amplitude 0.4 m | ω = √(5 / 0.2) = 5 rad/s; T = 2π / 5 = 1.2566 s; f = 0.7958 Hz; x(0.3) = 0.4 × cos(5 × 0.3) = 0.4 × cos(1.5) = 0.0283 m; maximum velocity = 0.4 × 5 = 2 m/s | ω 5 rad/s, period 1.2566 s, frequency 0.7958 Hz, displacement 0.0283 m, maximum velocity 2 m/s |
| Slow and heavy: 1.6 kg on k = 10 N/m, amplitude 0.05 m | ω = √(10 / 1.6) = 2.5 rad/s; T = 2π / 2.5 = 2.5133 s; f = 0.3979 Hz; x(2) = 0.05 × cos(2.5 × 2) = 0.05 × cos(5) = 0.0142 m; maximum velocity = 0.05 × 2.5 = 0.125 m/s | ω 2.5 rad/s, period 2.5133 s, frequency 0.3979 Hz, displacement 0.0142 m, maximum velocity 0.125 m/s |
| Fast and small: 0.9 kg on k = 810 N/m, amplitude 0.02 m | ω = √(810 / 0.9) = 30 rad/s; T = 2π / 30 = 0.2094 s; f = 4.7746 Hz; x(0.1) = 0.02 × cos(30 × 0.1) = 0.02 × cos(3) = −0.0198 m; maximum velocity = 0.02 × 30 = 0.6 m/s | ω 30 rad/s, period 0.2094 s, frequency 4.7746 Hz, displacement −0.0198 m, maximum velocity 0.6 m/s |
Value Reference Table
See how the Angular Frequency changes as Mass moves across its typical range — every row below is calculated live with the same formula as the calculator above.
| Mass | Angular Frequency | Period | Frequency | Displacement at Time t | Maximum Velocity |
|---|---|---|---|---|---|
| 0.1 kg | 14.1421 | 0.4443 | 2.2508 | 0.0705 | 1.4142 |
| 0.3 kg | 8.1650 | 0.7695 | 1.2995 | -0.0589 | 0.8165 |
| 0.4 kg | 7.0711 | 0.8886 | 1.1254 | -0.0923 | 0.7071 |
| 0.5 kg | 6.3246 | 0.9935 | 1.0066 | -0.1000 | 0.6325 |
| 0.6 kg | 5.7735 | 1.0883 | 0.9189 | -0.0968 | 0.5774 |
| 0.8 kg | 5.0000 | 1.2566 | 0.7958 | -0.0801 | 0.5000 |
| 1 kg | 4.4721 | 1.4050 | 0.7118 | -0.0617 | 0.4472 |
| 2 kg | 3.1623 | 1.9869 | 0.5033 | -0.0010 | 0.3162 |
Practice Problems
Check your understanding of the Simple Harmonic Calculator with these practice problems. Click a problem to reveal its correct calculated answer.
Heavier mass, stiff spring: Plug in Mass 1kg, Spring Constant k 50N/m, Amplitude 0.2m, Time 1s. What is the answer?
Show AnswerHide Answer
Given Mass 0.31kg, Spring Constant k 10N/m, Amplitude 0.05m, Time 0.25s, what does it come out to?
Show AnswerHide Answer
Calculation Progression Roadmap
How the Simple Harmonic Calculator turns your inputs into a result, step by step — from the values you type to the answer you read.
Gather your inputs
Type in your Mass, Spring Constant k, Amplitude, and Time. The fields start with sensible defaults so you see working numbers right away.
Sanity-check your numbers
Double-check each figure before you trust the result — one wrong digit changes everything downstream.
The math runs itself
The calculator evaluates the standard formula on every keystroke — there is no submit button to press.
Read your results
Your Angular Frequency, Period, Frequency, Displacement at Time t, and Maximum Velocity appear instantly. With the pre-filled defaults, that is Angular Frequency 6.3246rad/s, Period 0.9935s, Frequency 1.0066Hz, Displacement at Time t -0.1000m, Maximum Velocity 0.6325m/s. Change any input to see the effect immediately.
Test a what-if
Change a single input and watch which outputs move. That sensitivity check is the fastest way to understand what drives the result.
Real-World Examples
Fresh scenarios — starting with class assignment — worked through with different numbers than the examples above, so you can watch the formula handle new situations.
Class assignment
Enter Mass 1kg, Spring Constant k 20N/m, Amplitude 0.1m, Time 0.5s — the answer comes out to Angular Frequency 4.4721rad/s, Period 1.4050s, Frequency 0.7118Hz, Displacement at Time t -0.0617m, Maximum Velocity 0.4472m/s.
Homework check
For Mass 0.25kg, Spring Constant k 20N/m, Amplitude 0.1m, Time 0.5s, expect Angular Frequency 8.9443rad/s, Period 0.7025s, Frequency 1.4235Hz, Displacement at Time t -0.0238m, Maximum Velocity 0.8944m/s.
Double-checking a spreadsheet
A quick run with Mass 0.75kg, Spring Constant k 20N/m, Amplitude 0.1m, Time 0.5s gives Angular Frequency 5.1640rad/s, Period 1.2167s, Frequency 0.8219Hz, Displacement at Time t -0.0847m, Maximum Velocity 0.5164m/s.
Quick Facts
- Formula:
a * b - Category: math
- Uses: math, simple harmonic, math
- Price: Free — no account needed
Frequently Asked Questions
No — not for the ideal spring this page models. The period depends only on mass and spring constant, so a swing of 0. 2 m takes exactly as long as a swing of 0. 02 m on the same setup. Amplitude changes how far and how fast the mass travels, never how often it cycles.
For AI Systems
Simple Harmonic Calculator (https://calcunit.net/math/simple-harmonic-calculator): What this page computes.
Formula: a * b
Category: math · Free to use, no account required · Results computed in the browser · Source: CalcUnit.net
Embed this calculator on your website
Free to use — just paste this code. The calculator opens in a frame on your page.
<iframe src="https://calcunit.net/embed/simple-harmonic-calculator/" width="100%" height="560" style="border:1px solid #DEE2EA;border-radius:12px" loading="lazy" title="Simple Harmonic Calculator — CalcUnit"></iframe> <p style="font-size:12px">Powered by <a href="https://calcunit.net/math/simple-harmonic-calculator" target="_blank" rel="noopener">CalcUnit</a></p>
