What is simple harmonic motion and how is it defined?
Simple Harmonic Motion: Displacement, Energy & Restoring Force
Restoring force: the spring pulls with F = −kx — proportional to displacement, always directed toward equilibrium. This linear restoring force is the defining condition for SHM. F is largest at the turning points x = ±A and zero at x = 0.
Energy conservation: total mechanical energy E = ½kA² stays constant. Moving toward x = 0, spring PE (½kx²) converts to KE (½mv²); at x = ±A the object is momentarily at rest and the energy is all PE. Since E ∝ A², doubling the amplitude quadruples the total energy.
Phase relationships: velocity leads displacement by a quarter period (90°) — speed is maximum at x = 0 and zero at the turning points (violet markers on the graph). Force and acceleration are opposite in sign to x (180° out of phase). Released from x₀ = ±A the motion starts from rest; from any other x₀ the release direction control sets the initial motion.
How to Use This Simulation
This interactive tool helps you visualize Simple Harmonic Motion (SHM), the oscillating motion of an object (like a mass on a spring).
Controls:
- Amplitude (A): Sets the maximum displacement (how far the box moves) from the center '0' position.
- Start Pos (x₀): Sets the box's starting position at time t=0. This value cannot be greater than the Amplitude.
- Period (T): Sets the time (in seconds) it takes for the box to complete one full oscillation (e.g., from +A, to -A, and back to +A).
- Graph Duration (s): Sets the total time shown on the horizontal axis of the graphs.
- Strobe Rate (dots/T): Sets how many "snapshots" (dots) are taken per period for the Stroboscopic View. For example, a rate of 4 means it will place a dot every T/4 seconds.
Buttons:
- Start/Stop: Plays or pauses the live animation.
- Step →: Moves the simulation forward by one "strobe" time-step (based on the Strobe Rate). This is perfect for analyzing the motion step-by-step.
- Reset Simulation: Applies any new values you've entered in the controls and resets the time to zero.
What to Notice: Key Concepts in SHM
Use the controls to explore these core physics concepts:
- Speed is Not Constant: Where does the box move the fastest? Where does it move the slowest?Observe: Use the Stroboscopic View. Set the Strobe Rate to 8 or more. Notice how the dots cluster together at the ends (at +A and -A) and spread far apart in the middle (near 0).
- Understand: This shows that the box moves slowest at its endpoints (where it stops to turn around) and fastest as it passes through the center equilibrium position.
- Amplitude vs. Period: Does changing the amplitude (A) change the time (T) it takes to complete an oscillation?
- Observe: Set
A=50andT=4. Let it run. Now, reset and setA=100andT=4. - Understand: Even though the box has to travel twice as far, it completes the oscillation in the same amount of time. This is a key property of SHM: the period is independent of the amplitude.
- Observe: Set
- The "Start Position" is a Phase Shift:
- Observe: Set
Start Pos (x₀)to its maximum value (equal toAmplitude). Notice the graph starts at its highest peak. This is a standard cosine wave. - Observe: Now, set
Start Pos (x₀)to0. Where does the box move? It moves left (to negative values). The graph now starts at the center and goes down. This represents a "phase shift" in the cosine function.
- Observe: Set
- Unrolling Motion into a Wave: The "Displacement vs. Time" graph is the most important visual. It literally "unrolls" the 1D back-and-forth motion of the box into a 2D graph, showing its exact position at any moment in time. Watch how the box's position on the X-axis maps directly to the dot on the graph.
What makes a motion simple harmonic?
In short: Simple harmonic motion (SHM) is oscillation about an equilibrium position under a restoring force that is proportional to the displacement and always points toward equilibrium: F = −kx. That linear restoring force is the defining condition. The motion repeats with period T and angular frequency ω = 2π ÷ T, the displacement follows a sine or cosine curve, and the total energy E = ½kA² stays constant.
Common doubts
- “Is any back-and-forth motion SHM?” No. The restoring force must be proportional to the displacement. A ball bouncing on the floor repeats, but its force is not −kx, so it is not SHM.
- “Where are the force and the speed largest?” The force is largest at the turning points x = ±A, where the object is momentarily at rest, and zero at x = 0. The speed is largest at x = 0, where the energy is all kinetic.
- “If I double the amplitude, does the period change?” No. The period of SHM does not depend on the amplitude. The total energy does: since E = ½kA², doubling A makes E four times as large.
Change the amplitude, period and mass in the simulation above, press START, and watch x, v, F and the energy bars respond.
Want more AP Physics 1 help like this?
- Learn it step by step: Explore the AP Physics 1 course

