Home »Math »Spring-Mass Simulator
Engineering Simulation

Spring-Mass-Damper Simulator

Visualize the full second-order ODE response, free, damped, forced, and resonance, with live solution decomposition and a phase-space portrait.

Visualizations

System Diagram

eqkm = 1 kgy
t = 0.00 sy = 0.5000 mẏ = 0.0000 m/s

Phase Space Plot

y vs ẏ (displacement vs velocity)

Analysis Highlights

ω0 (natural)

4.000 rad/s

ccr (critical)

8.000

Period T

1.571 s

Damping ratio ζ

0.000

Stability: Conservative system — oscillates indefinitely without decay.

Math & Derivation Breakdown

Collapse / Expand

Dynamic Mathematical Model

General form:
my+ky=0m\,y'' + k\,y = 0
With current values:
1y+16y=01\,y'' + 16\,y = 0

Newton's second law applied to the mass: spring force −ky, damping force −cy', and external force F(t).

Solution Decomposition

y(t)=yc(t)y(t) = y_c(t)
Free response — only the homogeneous (transient) part is present.

Detailed Derivation

Characteristic equation:
mr2+k=0    r=±iω0,    ω0=k/m=4m r^2 + k = 0 \;\Rightarrow\; r = \pm i\,\omega_0,\;\; \omega_0 = \sqrt{k/m} = 4
General solution:
y(t)=Acos(ω0t)+Bsin(ω0t)y(t) = A\cos(\omega_0 t) + B\sin(\omega_0 t)
Initial conditions:
y(0)=y0=0.500,y(0)=v0=0y(0) = y_0 = 0.500,\quad y'(0) = v_0 = 0
Solve for A, B:
A=y0=0.500,B=v0ω0=0A = y_0 = 0.500,\quad B = \dfrac{v_0}{\omega_0} = 0
Closed-form solution:
y(t)=0.500cos(4t)y(t) = 0.500\,\cos(4\,t)