How Spring Calculations Work
An ideal spring resists being stretched or compressed with a restoring force that grows in proportion to how far it is displaced from its natural (equilibrium) length. This relationship — Hooke's Law — lets you find the force needed to hold a spring at a given displacement, the elastic energy stored inside it, and, if a mass is attached, how quickly that mass bounces back and forth. This calculator uses your spring constant, displacement, and optional mass to compute all four quantities at once.
Hooke's Law and elastic potential energy
Hooke's Law states that the restoring force of a spring is F = -kx, where k is the spring constant (stiffness, in N/m) and x is the signed displacement from equilibrium; the minus sign shows the force always points back toward equilibrium. The magnitude of force required to hold the spring at displacement x is simply F = k|x|. The energy stored while stretching or compressing the spring to that point is the elastic potential energy, PE = ½kx² — the area under the straight-line force-versus-displacement graph. Because x is squared, PE is always positive whether the spring is stretched or compressed, and doubling the displacement quadruples the stored energy.
Simple harmonic motion: period and frequency
If you attach a mass m to the spring and let it oscillate freely (on a frictionless surface or hanging vertically, ignoring air resistance), it undergoes simple harmonic motion with period T = 2π√(m/k) — the time for one complete back-and-forth cycle — and frequency f = 1/T, measured in hertz (cycles per second). A stiffer spring (larger k) or a lighter mass produces faster oscillation; a heavier mass or a softer spring produces slower oscillation. Notice that the period does not depend on how far you stretch or release the spring, only on m and k — a hallmark of simple harmonic motion.
Assumptions and common mistakes
- Elastic limit: Hooke's Law only holds while the spring deforms elastically. Stretch or compress it too far and it deforms permanently, so F = kx no longer applies.
- Massless, ideal spring: the period formula assumes the spring itself is massless and there is no friction, air resistance, or damping — real systems oscillate with slowly decaying amplitude.
- Sign confusion: a negative displacement means compression, not a "negative" force — always interpret the sign relative to your chosen positive direction.
- Unit mixing: keep spring constant, displacement, and mass in consistent units before combining them; this calculator converts your chosen units to SI (N/m, m, kg) internally so results stay correct.