Spring-mass-damper System Vibration Simulation and Animation

A MATLAB simulation of a Single Degree of Freedom (SDOF) mass–spring–damper system with animation
8 Downloads
Aktualisiert 7. Jan 2026

Lizenz anzeigen

This MATLAB code simulates the dynamic response of a Single Degree of Freedom (SDOF) mass–spring–damper system subjected to free and harmonic forced vibrations.
The program numerically solves the equation of motion using an ODE solver and automatically identifies the system type based on the damping coefficient and external force parameters. Both the time-domain response and an animated visualization of the system motion are provided.
The animated visualization includes all relevant physical components of the system, such as the mass, spring, damper, rigid wall, and external force arrow. The relevant physical components and thier dimensions are automatically adjusted based on the identified system type and the motion range.
The user is required to input several paraemters, based on these parameters, the system case is determined automatically based on user-defined parameters.
The code supports the following vibration cases:
1) Free Undamped vibration. For this case, the restricted settings are:
c = 0; F_0 = 0; % No Damping and external force present
2) Free Damped vibration. For this case, the restricted setting is:
F_0 = 0; % No external force
3) Harmonic forced Undamped vibration, for this case, the restricted setting is:
c = 0; % No Damping presen
4) Harmonic forced Damped vibration
To use the code, download all .m files, and run the file "SDOF_Systtem_Vibration_Simulation"

Zitieren als

Ayham Aljawabrah (2026). Spring-mass-damper System Vibration Simulation and Animation (https://de.mathworks.com/matlabcentral/fileexchange/182999-spring-mass-damper-system-vibration-simulation-and-animation), MATLAB Central File Exchange. Abgerufen.

Kompatibilität der MATLAB-Version
Erstellt mit R2025b
Kompatibel mit allen Versionen
Plattform-Kompatibilität
Windows macOS Linux
Tags Tags hinzufügen
Version Veröffentlicht Versionshinweise
1.0.0