Plotly Motion Graph
The graph shows displacement, velocity, acceleration, and energy trends across several time steps.
Formula Used
The calculator uses the ideal simple harmonic oscillator model:
ω = √(k / m)
f = ω / 2π
T = 2π / ω
x(t) = A cos(ωt + φ)
v(t) = -Aω sin(ωt + φ)
a(t) = -ω²x(t)
F(t) = ma(t) = -kx(t)
PE = ½kx²
KE = ½mv²
E = ½kA²
If initial values are used, amplitude and phase are derived with:
A = √(x₀² + (v₀ / ω)²)
φ = atan2(-v₀ / Aω, x₀ / A)
How to Use This Calculator
- Choose the oscillator source. You may use spring constant, angular frequency, frequency, or period.
- Enter mass in kilograms. If using the spring model, enter spring constant in newtons per meter.
- Choose whether to enter amplitude and phase or initial displacement and velocity.
- Enter the time where you want the motion result.
- Set decimal precision for rounded output.
- Press the calculate button. Results appear above the form and below the header.
- Review the graph, then export CSV or PDF for reports.
Example Data Table
| Case |
Mass kg |
Spring Constant N/m |
Amplitude m |
Phase deg |
Time s |
Expected Use |
| Small lab spring |
1.00 |
10.00 |
0.20 |
0 |
0.40 |
Intro physics experiment |
| Soft suspension |
2.50 |
8.00 |
0.15 |
30 |
1.20 |
Vibration study |
| Known frequency test |
0.80 |
Calculated |
0.05 |
-20 |
0.25 |
Sensor comparison |
Understanding Simple Harmonic Motion
Simple harmonic motion describes repeated movement around an equilibrium point. The restoring force always points back toward that point. Its size is proportional to displacement. A mass on a spring is the common model. A small angle pendulum follows the same pattern when the angle stays small.
Why the Oscillator Matters
This calculator helps connect measured values with the main motion quantities. It converts mass and spring constant into angular frequency, period, and frequency. It also predicts displacement, velocity, acceleration, force, and energy at any chosen time. These values are useful in classroom examples, lab reports, machine vibration checks, and sensor studies.
Using Amplitude and Phase
Amplitude is the largest distance from equilibrium. Phase shifts the wave left or right in time. When amplitude and phase are known, the calculator uses x = A cos(ωt + φ). Velocity is the time derivative. Acceleration is proportional to negative displacement. This means the object accelerates most strongly near the turning points and moves fastest at equilibrium.
Using Initial Conditions
Sometimes amplitude and phase are not measured directly. You may know the starting displacement and starting velocity instead. The calculator can derive amplitude and phase from those starting values. This is helpful after a lab trial where a sensor records position and speed at the release moment.
Energy View
For an ideal oscillator, total mechanical energy stays constant. Potential energy is largest at maximum displacement. Kinetic energy is largest at equilibrium. The graph and result cards show how these quantities are related. In real systems, friction reduces the amplitude, but the ideal model remains a strong first approximation.
Better Inputs, Better Results
Use consistent SI units for best accuracy. Enter mass in kilograms, spring constant in newtons per meter, and time in seconds. If you use centimeters, convert them to meters first. Check whether your source gives ordinary frequency or angular frequency, because they differ by a factor of 2π. Compare the graph with the result cards to verify the selected time and phase.
For repeated trials, change one input at a time. This makes trends easier to see and keeps the final report simple, transparent, and more reliable for readers.
FAQs
1. What is a simple harmonic oscillator?
It is a system that moves back and forth around equilibrium. The restoring force is proportional to displacement and points opposite the motion direction.
2. Which units should I use?
Use kilograms for mass, newtons per meter for spring constant, meters for displacement, seconds for time, and radians per second for angular frequency.
3. What is angular frequency?
Angular frequency measures how quickly the oscillator cycles in radians per second. It equals 2π times ordinary frequency.
4. What does phase angle mean?
Phase angle shifts the oscillation in time. It decides where the object starts in its cycle when time equals zero.
5. Can I use initial displacement and velocity?
Yes. Select the initial condition input style. The calculator derives amplitude and phase from starting displacement and starting velocity.
6. Why is total energy constant?
In the ideal model, no damping or friction removes energy. Energy changes between kinetic and potential forms while total energy remains unchanged.
7. Is this calculator valid for damped systems?
No. It models ideal undamped motion. Real systems with friction, drag, or resistance need damping terms for more accurate results.
8. Why does acceleration have a negative sign?
The negative sign shows acceleration points back toward equilibrium. When displacement is positive, acceleration is negative, and the reverse is true.