Forced oscillations

Let a block on a spring go and watch friction make its swings die away, or push it in rhythm and watch the swings build up to a steady size. Slide the push rate through resonance, see the resonance curve for more and less damping, and get the amplitude, phase lag and Q with your numbers.

Keep it one tap away for everyday use.

Bookmark Forced oscillations?

Press Ctrl + D now. Your browser opens its own bookmark box, where you choose the name and folder.

  1. Set damping
  2. Watch x(t)
  3. Resonance
  4. Check
Nothing is uploadedWorks offline once open

Push a spring in rhythm

The resonance curve

Less damping gives a taller, narrower peak; more damping a lower, wider one. Without damping the peak would be infinitely tall.

Try this

  • Driven: start at ω/ω₀ = 1 and watch the swings build up over several seconds until they level off.
  • Move the push rate to 0.5 or 2: the block hardly moves. Far below resonance it follows the push; far above, it moves opposite to it.
  • Set the damping to 0 at resonance: the swings keep growing. This is why soldiers break step on a bridge.
  • Let go (damped): double b and the swings die away twice as fast.
  • Push the damping up to 8 with m = 1 and k = 10: the block creeps back without swinging at all (overdamped).

Check yourself

What it does

A real spring does not bob for ever: air and friction take a little energy every swing and the swings die away. Push the same spring in rhythm, though, and the swings build up until the energy you put in each swing matches what friction takes out. If your pushes match the spring’s own natural rhythm the swings become very large: that is resonance, the reason a child on a swing goes higher with small, well-timed pushes, and why some bridges and buildings have to be damped.

This page runs a block on a spring with adjustable damping. In Let go mode it starts 10 cm from the middle and the graph shows the swings shrinking inside the curve A₀e^(−bt/2m). In Driven mode a steady push F₀ cos ωt starts it from rest; the graph shows the start-up wobble settle into steady swings, and a second graph, the resonance curve, shows the steady amplitude for every push rate, for your damping and for half and double it.

This goes a little beyond the school book: it extends Class 11 Physics, Oscillations (damped simple harmonic motion, forced oscillations and resonance, which the book describes in words) and links to Class 12 Physics, Alternating Current (resonance in an LCR circuit follows the same equation). Start from SHM circle for undamped motion and spring combinations for the spring constant, and compare with pendulum lab.

How to use it

  1. Choose Let go (damped) or Driven.
  2. Mass m and spring constant k set the natural frequency ω₀ = √(k/m).
  3. Damping b sets how strongly friction resists motion (force = −b × velocity). 0 means no friction.
  4. In Driven mode, push rate ω ÷ ω₀ sets how fast you push compared with the natural rhythm, and push strength F₀ how hard.
  5. Every change starts the run again from the beginning so you can watch the start-up. Pause and Start again are under the graph.

Worked example

As the page opens: m = 1 kg, k = 40 N/m, b = 0.5 kg/s, pushed with F₀ = 1 N at ω = ω₀.

ω₀ = √(40/1) = 6.325 rad/s (1.007 Hz) and ζ = 0.5 / (2√40) = 0.0395, so Q = 1/(2ζ) = 12.6. At ω₀ the spring and mass terms cancel and the steady amplitude is A = F₀ / (bω₀) = 1 / (0.5 × 6.325) = 31.62 cm, lagging the push by 90°. Push at half the rate and A = 3.329 cm; at twice the rate, 0.832 cm, almost opposite to the push (177° behind). The largest amplitude comes at ω = 6.315 rad/s, just below ω₀.

Let go with the same spring and damping: the swings fall to 1/e in τ = 2m/b = 4 s and halve every 2.773 s.

Check yourself

Five fresh questions: the natural frequency, the time for swings to halve, the amplitude at resonance, the amplitude off resonance, and what damping does to the peak. Answers are checked on the page and the working is shown. Nothing is saved.

Tips

  • Damping hardly changes how fast the block swings (ω′ is very close to ω₀ for light damping); it changes how long the swings last.
  • At resonance the push is in step with the velocity, so every push adds energy; that is why the displacement lags the push by 90°.
  • Halve the damping and the resonance peak doubles in height.

FAQ

What does Q mean? The quality factor: roughly how many swings it takes for the energy to fall by a large fraction, and how sharp the resonance peak is. A tuning fork has a very high Q; a car’s shock absorber a very low one.

Why does the graph wobble at first? At the start the block’s own natural swing and the forced swing add together. The natural part dies away with the damping, leaving only the forced, steady motion.

What is critical damping? ζ = 1: the block returns to the middle as fast as possible without overshooting. Door closers and measuring meters are tuned close to it.

Where the numbers come from

  • Damped, driven oscillator m x″ + b x′ + k x = F₀ cos ωt: ω₀ = √(k/m), damping ratio ζ = b/(2√(km)), decay e^(−bt/2m), ω′ = ω₀√(1 − ζ²), steady amplitude F₀/√((k − mω²)² + (bω)²), phase lag atan(bω/(k − mω²)), peak at ω₀√(1 − 2ζ²), Q = 1/(2ζ): standard mechanics.
  • The motion shown is the equation solved step by step (Runge–Kutta).
  • Checked against an independent Python calculation and a separate step-by-step run to steady state.

Standard scientific values, such as constants, atomic weights and melting points, are facts found in every textbook; we name where ours were checked. If you are an author or publisher and want a value, a credit or a table changed or removed, tell us and we will act quickly.

Last updated 2026-11-09.

Change log for Forced oscillations

  1. Add #1353 Damped and forced oscillations Details on GitHub

Every change to fibub

Related tools

Coupled oscillators #T642 Line up to 12 masses joined by springs, between walls or floating free, and get every normal mode: its frequency, period and shape. Watch a single mode or any starting push move, see how the energy is shared between the modes, and download the motion. SHM circle #L26 A point goes round a circle at a steady speed; its shadow moves in simple harmonic motion. Change the amplitude, period and phase, watch the x, v and a graphs and the energy bars, and turn the same motion into a mass on a spring or a pendulum. Pendulum lab #L213 Swing a pendulum of any length on Earth, the Moon, Mars or Jupiter and see its period worked out. At Class 11 see how much longer big swings take, then time a pendulum with the stopwatch and fit a straight line of T² against L to measure g. Spring combinations #L214 Hang a mass on one spring, two springs one below the other, or two side by side, and watch it bob. See the combined spring constant, how far it hangs, the period T = 2π√(m/k) and the energy, all with your numbers, and compare series with parallel. Mirror ray diagram #L1 Drag an object in front of a concave or convex mirror and watch the principal rays find the image: where it forms, how big it is, real or virtual, with the mirror formula and magnification worked out with signs. Lens ray diagram #L2 Drag an object in front of a convex or concave lens and watch the principal rays find the image: where it forms, how big it is, real or virtual, with the lens formula, magnification and power worked out with signs.