Spring-Mass System Simulator Back
Vibration Simulator

Spring-mass systemSimulator

Vary spring constant, mass, and damping coefficient to animate 1-DOF system vibration in real time. Visualize overdamped, critically damped, and underdamped responses. Also supports forced excitation.

Parameters
Spring constant k
N/m
Mass m
kg
Damping Coefficient c
N·s/m
Initial Displacement x₀
m
Forced vibration
Excitation Force F₀
N
Excitation Frequency f
Hz
Natural frequency fₙ
Damping ratio ζ
Damping Type
Results
ωₙ [rad/s]
Damping ratio ζ
fₙ [Hz]
Current Displacement [m]
Underdamped
Damping Type
Animation
Displacement Time History x(t)
Visualization
Theory & Key Formulas
$$m\ddot{x}+ c\dot{x}+ kx = F_0\cos(\Omega t)$$ $$\omega_n = \sqrt{\frac{k}{m}}, \quad \zeta = \frac{c}{2\sqrt{mk}}, \quad \omega_d = \omega_n\sqrt{1-\zeta^2}$$

Underdamped($\zeta < 1$):$x(t) = Ae^{-\zeta\omega_n t}\cos(\omega_d t + \phi)$

Numerical integration uses the 4th-order Runge-Kutta method (Δt = 1 ms).

Related Tools

GoodmanDiagram
Plot of operating point for mean stress and amplitude stress
Rotational Dynamics Simulator
Calculate the relationship among torque, moment of inertia, and angular acceleration
Plane trussAnalysis(Joint method・Direct stiffness method)
Calculate nodal displacement and member stress for a plane truss using the direct stiffness method
Projectile motionSimulator
Render projectile trajectories in real time with variable initial velocity, launch angle, height, and gravity

What is a Spring-Mass-Damper System?

🙋
What exactly is this simulator showing? I see a block bouncing on a spring, but what are the sliders for "k", "m", and "c" actually doing?
🎓
Basically, you're looking at the simplest model for vibration in the world. The block is the mass (m), the spring's stiffness is (k), and the damper (c) is like a shock absorber that saps energy. Try moving the "Spring Constant k" slider up. See how the spring gets stiffer and the block vibrates faster? That's the core relationship you're controlling.
🙋
Wait, really? So the "Damping Coefficient c" slider is what changes it from bouncing a lot to just slowly settling? What's the difference between "overdamped" and "underdamped"?
🎓
Exactly! In practice, damping controls how oscillations die out. Set the damping "c" very low—you get "underdamped" where it rings for a long time, like a guitar string. Crank "c" up high, and you get "overdamped" where it slowly creeps back to zero without oscillating, like a door closer. The magic middle is "critically damped," which returns to rest the fastest. Try finding that sweet spot with the sliders!
🙋
Okay, that makes sense for free vibration. But what about the "Forced Vibration" switch and the "Excitation Force F₀" and "Frequency f"? What's happening there?
🎓
Great question! That's when you give the system a continuous push, like an engine shaking a car frame. The "Excitation Force F₀" is how hard you push, and "Frequency f" is how often you push per second. Turn forced vibration on and play with the frequency. You'll see a huge spike in vibration when the push frequency matches the system's natural frequency—that's resonance, and it's what engineers must avoid! For instance, this is why washing machines can shake violently at certain spin speeds.

Physical Model & Key Equations

The fundamental equation of motion for a 1-DOF spring-mass-damper system, also known as the governing differential equation, balances inertia, damping, and spring forces with any external force.

$$m\ddot{x}+ c\dot{x}+ kx = F_0\cos(\Omega t)$$

m: Mass (kg) | c: Viscous damping coefficient (N·s/m) | k: Spring constant (N/m)
x: Displacement (m) | F₀: Amplitude of external force (N) | Ω = 2πf: Angular excitation frequency (rad/s)

From this equation, we derive key characteristic parameters that define the system's natural behavior and response type.

$$\omega_n = \sqrt{\frac{k}{m}}, \quad \zeta = \frac{c}{2\sqrt{mk}}, \quad \omega_d = \omega_n\sqrt{1-\zeta^2}$$

ωₙ: Natural frequency - the inherent oscillation frequency if there were no damping.
ζ (zeta): Damping ratio - a dimensionless number that determines the oscillation type (ζ < 1: underdamped, ζ = 1: critically damped, ζ > 1: overdamped).
ω_d: Damped natural frequency - the actual oscillation frequency when damping is present (for ζ < 1).

Real-World Applications

Automotive Suspension Tuning: Your car's shock absorbers and springs form a spring-mass-damper system. Engineers tune the damping ratio (ζ) to be slightly underdamped (around 0.2-0.3) for a balance of comfort (absorbing bumps) and control (keeping tires on the road). The simulator's "c" slider directly models this tuning process.

Earthquake Engineering & Building Design: Skyscrapers are essentially giant masses on flexible foundations (springs) with built-in dampers. Engineers analyze their natural frequency (ωₙ) to ensure it doesn't match the dominant frequency of earthquake ground motions, preventing catastrophic resonance. The "Forced Vibration" mode in the simulator demonstrates this dangerous phenomenon.

Precision Manufacturing & Machinery: In CNC machines or semiconductor manufacturing equipment, any vibration reduces precision. Systems are designed to be heavily overdamped (ζ >> 1) so that after a movement command, the tool settles to its position as quickly as possible without oscillating, just like the slow, smooth return you see in the simulator with high damping.

Aerospace & Aircraft Component Testing: Aircraft wings and components are subjected to forced vibration tests to find their natural frequencies and damping ratios, a process called modal analysis. This 1DOF model is the fundamental building block of the complex Finite Element Method (FEM) software (like NASTRAN or Abaqus) used for this analysis, where typical damping ratios for aerospace structures range from 0.01 to 0.05.

Common Misconceptions and Points to Note

When you start using this simulator, there are a few common pitfalls. First, there's a tendency to think that "if the natural frequency is the same, the behavior will be the same, even if mass and spring constant are changed." It's true that the natural frequency $\omega_n$ is determined by $\sqrt{k/m}$, so $\omega_n$ will be the same 10 rad/s for both $m=1, k=100$ and $m=4, k=400$. However, look at the damping ratio formula $\zeta = c / (2\sqrt{mk})$. If $m$ and $k$ are quadrupled, the damping coefficient $c$ required to maintain the same damping ratio becomes twice as large. In other words, even if the apparent vibration frequency is the same, the influence of the system's inherent "weight" or "stiffness" on the design must be considered separately. For example, the required damper size (the value of $c$) will differ between a light, stiff system and a heavy, soft one.

Next, there's the misconception that "the maximum resonance amplitude always occurs exactly at the natural frequency for forced vibration." When damping is significant (say, $\zeta$ exceeds about 0.1), the frequency at which the maximum amplitude occurs shifts slightly lower than the natural frequency $\omega_n$. In this simulator too, if you set $\zeta$ to around 0.3 and slowly vary the excitation frequency $f$, you should be able to confirm that the amplitude peak is slightly lower than $\omega_n/(2\pi)$. This is also important in practical work; when designing to avoid resonance points, you need to account for this shift.

Finally, there's the assumption that "critical damping is always optimal." It's true that critical damping is ideal if the sole goal is to "bring the system to rest most quickly." However, the story changes when considering factors like "ride comfort" in a car's suspension. With critical damping ($\zeta=1$), road bumps are transmitted directly to the vehicle body, resulting in a "harsh" ride. To absorb vibrations moderately while still achieving relatively quick convergence, an "underdamped" region like $\zeta=0.2–0.4$ is often chosen. The optimal damping ratio changes depending on the objective—that's practical engineering wisdom.