Simulation elastic and inelastic collisions

version 1.0.2 (4.24 MB) by devilPRG
This example shows how to modeling elastic and inelastic collisions between two sliders on air track using Simulink Simscape


Updated 29 Nov 2019

View License

One important consequence of Newton’s third law is the conservation of momentum in collisions between two bodies. One way of verifying this is to investigate collisions between two sliders on an air track. When all of the kinetic energy is conserved, we speak of elastic collisions. In cases where kinetic energy is only conserved for the common centre of gravity of the two bodies, we use the term inelastic collisions. In this experiment, the individual velocities of the sliders are determined from the times that photoelectric light barriers are interrupted and the momentum values are calculated from these speeds.
Using the track itself as the frame of reference, conservation of momentum is described by the following equation:

p_1,p_2:individual momenta before collision
p_1^',p_2^':individual momenta before collision

Therefore the conservation of momentum is given by:


Here v'1 and v'2 have different values after an elastic collision, but are the same subsequent to an inelastic collision. In an elastic collision, a flat buffer on the first slider collides with a stretched rubber band on the second slider. An inelastic collision involves a long pointed spike being pushed into some modelling clay. The masses of the sliders can be modified by adding weights.

The instantaneous velocity is given by the following:


In order to measure the instantaneous velocity in this experiment, an interrupter flag of known width Δs is attached to the slider and breaks the beam of a photoelectric sensor as the slider passes by it. The time the beam is broken Δt is measured by means of a digital counter.

Official web-site:

Paid Version (Google Play):

Free Version (Google Play):

Free online-version (HTML5):

Virtual Lab: Laws of Collisions:

Cite As

devilPRG (2022). Simulation elastic and inelastic collisions (, MATLAB Central File Exchange. Retrieved .

MATLAB Release Compatibility
Created with R2019b
Compatible with any release
Platform Compatibility
Windows macOS Linux

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!