See attached file.
Gradient problems are in the attachments.
Conservation of momentum:
m1 v1 = (m1 + m2)v2 ------->
v2 = m1v1/(m1 + m2)
Kinetic energy after collision:
1/2 (m1 + m2)v2^2 = 1/2 m1^2 v1^2/(m1 + m2)
Kinetic energy has decreased by:
1/2 m1 v1^2 - 1/2 m1^2 v1^2/(m1 + m2)
Divide by 1/2 m1 v1^2 to find the relative fraction that has been lost:
[1/2 m1 v1^2 - ...
A problem about inelastic collsion is solved and we consider an unrelated problem on gradients of potential energy functions.