Physics I: Mechanics › Oscillations & gravitation › SHM position
SHM position
One equation for every back-and-forth motion — amplitude, speed of oscillation, and starting point, all in a single line.
Notation on this page: A is the amplitude (max distance from equilibrium), ω the angular frequency in rad/s, φ the phase constant (where the cycle starts at t = 0).
Before this lesson: Hooke's law
Where it comes from
Imagine a peg on a turntable spinning at a steady rate, and watch its shadow on the wall beside it — the view edge-on. The peg goes around uniformly, but the shadow shuttles back and forth. This is the reference circle: simple harmonic motion is uniform circular motion seen from the side.
No — and that unevenness is the whole story. Near the circle's edge the peg moves almost along your line of sight, so the shadow barely crawls; near the centre the peg moves sideways at full speed, so the shadow flies. The shadow's position is the projection of circular motion onto a diameter:
The peg's angle grows steadily: θ(t) = ωt + φ, where ω is how fast the turntable spins (rad/s) and φ is the peg's angle when you start the clock. Substitute, and the shadow's motion is:
Every mass on a spring, every pendulum, every vibrating string is some system's “shadow” — which is why one equation covers them all.
Derivation
We derive the position equation from the reference circle, then verify it describes SHM by checking its acceleration — the step that connects this page back to Hooke's law.
Why differentiate twice? The defining feature of SHM is not the cosine shape — it is the restoring acceleration a = −ω²x. Step 4 proves our cosine satisfies it, which is what earns the name “simple harmonic.”
How to use it
The procedure, every time:
- Read off A. The amplitude is the maximum |x| — half the peak-to-peak swing.
- Get ω from the timing. ω = 2πf = 2π/T. If you know the period T, you know ω.
- Fix φ from the start. x(0) = A cos φ and v(0) = −Aω sin φ. Two favourite cases: released from rest at +A → φ = 0; starting at equilibrium moving +x → φ = −π/2.
- Cosine or sine? Doesn't matter — sin(ωt) = cos(ωt − π/2). Pick one, let φ absorb the difference.
- Radians, always. ωt + φ must be in radians, or the derivatives (and everything built on them) break.
The two classic starts
Worked examples
Four problems, easiest first. In each one, read every step — the why of each move is the lesson.
Example 1 — read the equation: x = 0.20 cos(4πt) (SI units)
- Match the pattern x = A cos(ωt + φ): A = 0.20 m, ω = 4π rad/s, φ = 0.
- Period and frequency. T = 2π/ω = 2π/(4π) = 0.50 s; f = 1/T = 2.0 Hz.
- Max speed and acceleration. vmax = Aω = 0.20 × 4π = 0.8π ≈ 2.51 m/s; amax = Aω² = 0.20 × 16π² ≈ 31.6 m/s².
- Sanity check. φ = 0 means it starts at +A at rest — x(0) = 0.20 cos(0) = 0.20 m ✓
Your turn — x = 0.05 cos(2πt + π/3). Find T, f, x(0), vmax.
Answer: T = 1.0 s, f = 1.0 Hz, x(0) = 0.025 m, vmax = 0.314 m/s. ω = 2π → T = 2π/2π = 1.0 s. x(0) = 0.05 cos(π/3) = 0.05 × 0.5 = 0.025 m. vmax = Aω = 0.05 × 2π ≈ 0.314 m/s.
Example 2 — phase from the start: mass released at equilibrium, moving in +x
- Translate the start. “At equilibrium” → x(0) = 0. “Moving +x” → v(0) > 0.
- Use both conditions. x(0) = A cos φ = 0 → φ = ±π/2. v(0) = −Aω sin φ > 0 → sin φ < 0 → φ = −π/2.
- Write it. x(t) = A cos(ωt − π/2) = A sin ωt.
- Check. x(0) = 0 ✓, v(0) = Aω cos(0) = Aω > 0 ✓ — starts centred at full speed, as required.
Your turn — mass released from rest at x = −A. Find φ.
Answer: φ = π (equivalently −π). x(0) = A cos φ = −A → cos φ = −1 → φ = π. Then x(t) = A cos(ωt + π) = −A cos ωt, and v(0) = 0 ✓.
Example 3 — position at a time: A = 0.10 m, T = 2.0 s, find x(0.25 s)
- Get ω. ω = 2π/T = 2π/2.0 = π rad/s.
- Write x(t). Released from rest at +A (the default reading): x(t) = 0.10 cos(πt).
- Evaluate. x(0.25) = 0.10 cos(0.25π) = 0.10 × (√2/2) ≈ 0.0707 m.
- Sanity check. T/8 = 0.25 s is one-eighth of a cycle; the mass has left +A and is heading in — x between 0 and A ✓
Your turn — A = 0.12 m, T = 0.50 s, released from rest at +A. Find x(0.125 s).
Answer: 0 m. ω = 2π/0.50 = 4π rad/s; x(0.125) = 0.12 cos(4π × 0.125) = 0.12 cos(π/2) = 0. A quarter period after release, the mass is exactly at equilibrium.
Example 4 — judgment call: starts at half amplitude, heading inward
- Position condition. x(0) = A cos φ = A/2 → cos φ = 1/2 → φ = ±π/3.
- Velocity condition. v(0) = −Aω sin φ < 0 → sin φ > 0 → φ = +π/3.
- Write it. x(t) = A cos(ωt + π/3).
- Concrete check. A = 0.08 m, T = 1.0 s (ω = 2π): x(0.10) = 0.08 cos(0.2π + π/3) = 0.08 cos(96°) ≈ −0.00836 m — already crossed equilibrium and heading out the other side ✓
Your turn — starts at x = −A/2, moving in +x. Find φ.
Answer: φ = −2π/3 (equivalently 4π/3). cos φ = −1/2 gives φ = ±2π/3; v(0) > 0 needs sin φ < 0, so φ = −2π/3. Check: x(0) = A cos(−2π/3) = −A/2 ✓.
Memorization tips
- Chant it: “A-cos-omega-t-plus-phi.” Three slots: how far, how fast, where it starts.
- The 2π tax: ω = 2πf. Frequency counts cycles; ω counts radians. Never swap them.
- Cosine starts at the top. With φ = 0 the motion begins at +A — that is why cosine is the default, not sine.
- Phase needs two facts. x(0) gives cos φ, the direction of motion gives the sign of sin φ. One fact, two candidates; two facts, one phase.
- The twice-differentiated check: a = −ω²x. If your x(t) doesn't satisfy it, it isn't SHM.
- Units audit: ωt must be unitless — (rad/s)·s = rad ✓. If ωt has units, ω is wrong.
Final challenge
Five mixed questions — reading equations, phases, and the traps, all in one. Score 5/5 and SHM position is yours.
← Back to the Physics I formula sheet
How to learn a formula here
- Read each section in order — every section ends with a short quiz. Take it before moving on; the questions test exactly what you just read.
- Work the examples with the answers covered, then uncover one step at a time and compare.
- Finish with the final challenge — five mixed questions including the classic traps.
- Retake what you miss — every quiz reshuffles each attempt, and every answer explains itself.
Frequently asked questions
Should I use cosine or sine for SHM?
Either — they differ only by a phase shift: sin(ωt) = cos(ωt − π/2). Cosine is the standard because it starts at maximum displacement when t = 0 (with phase zero). The phase constant absorbs whichever you choose.
What does the phase constant do physically?
It sets where in the cycle the motion starts at t = 0. Phase 0 means starting at maximum displacement; −π/2 means starting at equilibrium moving in +x. Same oscillation, different starting snapshot.
Is angular frequency the same as frequency?
No: angular frequency ω = 2πf, measured in rad/s, while frequency f is in Hz (cycles per second). Forgetting the 2π is the most common error — ω is 2π times faster than f numerically.
Can the amplitude A be negative?
By convention A is positive — it is the maximum distance from equilibrium. A minus sign in front is just a phase shift of π: −A cos(ωt) = A cos(ωt + π).
Do I use degrees or radians for ωt + φ?
Radians, always. The derivative relationships v = −Aω sin(ωt+φ) and a = −ω²x only hold in radians — degrees would smuggle in a π/180 factor everywhere.
More from the codex
Physics I formula sheet
All the mechanics formulas — kinematics, forces, energy — printable and quiz-ready.
Open sheet → LiveFormula Sheet Builder
Mix and match any sections into your own printable sheet.
Open tool → LivePrompt Simulator
Practice prompt engineering with deterministic scoring.
Open tool →Support the codex
This page is free, with no account and no ads. If it helped you learn, consider supporting the indie dev behind it.
Questions or a bug to report? Email [email protected].