The train, of mass 2.5kg, is stopped by compressing a spring in the buffer. After the train has stopped, the energy stored in the spring is 0.48J. Calculate the initial speed 𝑣 of the train.

The relation between kinetic and potential energy
The potential energy is the energy accumulated in an object by its location.
PE = mgh where, m - mass, g - acceleration due to gravity and h - height
The energy possessed by an object as a result of its motion is known as kinetic energy.
KE = \frac{1}{2} mv^2 Where, m-mass and v- velocity
Energy cannot be destroyed, only converted from one form to another, according to the law of conservation of energy.
PE begins from 0 at the projection point and increases to a maximum value at a constant speed at maximum height.
KE begins at the projection point with a maximum value and decrease constantly to 0 at maximum height.
Total energy = PE + KE.
At the maximum height (when object dropped): PE = KE
Step 1: Set up an equation for the speed of the train
Given that
Mass of the train m = 2.5 kg
Energy stored in the spring due to compression by the train, PE = 0.48 joules
When train starts
The amount of potential energy stored by spring is equal to the kinetic energy of the train.
PE = KE
PE = \frac{1}{2}mv^2
v = \sqrt{\frac{2 * PE}{m}}
Step 2: Determine the initial velocity of the train
v = \frac{2* 0.48}{2.5}
v = 0.384
Hence, initial speed of the train v = 0.384 m/s