Contour plots for Newtonian and relativistic elastic collision equations

For the purposes of a lecture on computational applied mathematics, I wanted to illustrate the solution of nonlinear simultaneous equations by first employing contour plots or grid search techniques to find approximate solutions before using these approximate solutions as starting values for more accurate quasi-newton root finding methods. I decided to illustrate these techniques using the pairs of energy conservation and momentum conservation equations that arise when modelling elastic collisions in both Newtonian and relativistic physics. I was intrigued by some similarities in the contour plots I obtained for the two cases and want to record these results here.

For the Newtonian case, I considered the following problem: A ball of mass m_1 = 1kg moving with initial velocity u_1 = 9m/s collides elastically with a ball of mass m_2 = 10kg moving with initial velocity u_2 = 1m/s. Assume all motion occurs in one dimension. Calculate the final velocities v_1 and v_2 of the 1kg ball and the 10kg ball respectively after the collision.

In such an elastic collision, both energy and momentum are conserved, so the following equations must hold respectively:

\frac{1}{2} m_1 v_1^2 + \frac{1}{2} m_2 v_2^2 - \frac{1}{2} m_1 u_1^2 - \frac{1}{2} m_2 u_2^2 = 0

m_1 v_1 + m_2 v_2 - m_1 u_1 - m_2 u_2 = 0

I used Python to obtain contour plots of these two equations using the data in the problem and obtained the following result:

So, this system has two roots, a trivial one which involves setting the final velocities equal to the initial velocities, and a nontrivial root which turned out to be (-5.54545455,  2.45454545) (found using quasi-newton methods).

It was not too surprising to see that the energy equation produced a contour which is a closed loop (actually, an ellipse) while the momentum equation produced a contour which is an open curve (actually, a straight line). The reason for this difference is that the kinetic energy of each ball is bounded below by zero and above by the total energy of the system (determined by the initial conditions), so the closed energy contour arises as a result of the total energy being distributed continuously between the balls subject to these bounds, with a symmetry between negative and positive velocities arising due to the quadratic functional form of Newtonian kinetic energy. In contrast, the velocities in the Newtonian momentum equation are free to vary from minus infinity to infinity as long as the total momentum (also determined by the initial conditions) is conserved, and the velocities also appear linearly in the momentum equation so the contour for momentum is unable to ‘close’ and in fact is a straight line extending indefinitely in both directions.

For the relativistic case, I considered the following problem: A \pi-meson of rest energy m_1c^2 = 139.6 MeV moving with initial velocity u_1/c = 0.9 collides elastically with a proton of rest energy m_2c^2 = 938.2 MeV and with initial velocity u_2/c = 0.1. Assume all motion occurs in one dimension, and note that in a relativistic elastic collision the rest masses are unchanged after the collision. Calculate the final velocities v_1/c and v_2/c of the \pi-meson and the proton respectively after the collision.

We again note that in an elastic collision both energy and momentum are conserved, so the following relativistic equations must hold respectively:

\frac{m_1c^2}{\sqrt{1 - (v_1/c)^2}} + \frac{m_2c^2}{\sqrt{1 - (v_2/c)^2}} = \frac{m_1c^2}{\sqrt{1 - (u_1/c)^2}} + \frac{m_2c^2}{\sqrt{1 - (u_2/c)^2}}

\frac{m_1 v_1}{\sqrt{1 - (v_1/c)^2}} + \frac{m_2 v_2}{\sqrt{1 - (v_2/c)^2}} = \frac{m_1 u_1}{\sqrt{1 - (u_1/c)^2}} + \frac{m_2 u_2}{\sqrt{1 - (u_2/c)^2}}

We need to solve these simultaneously for v_1/c and v_2/c. To use the data given in the problem, we need to manipulate the second equation to obtain velocities relative to the speed of light c and rest energies in the numerator (this manipulation effectively multiplies the momentum conservation equation through by c, but this does not affect the results since the extra factor of c appears on both sides of the equation and therefore cancels):

\frac{m_1c^2 (v_1/c)}{\sqrt{1 - (v_1/c)^2}} + \frac{m_2c^2 (v_2/c)}{\sqrt{1 - (v_2/c)^2}} = \frac{m_1c^2 (u_1/c)}{\sqrt{1 - (u_1/c)^2}} + \frac{m_2c^2 (u_2/c)}{\sqrt{1 - (u_2/c)^2}}

We can then obtain contour plots of the relativistic energy and momentum conservation equations using the data in the problem and with the equations rearranged to equal zero:

\frac{m_1c^2}{\sqrt{1 - (v_1/c)^2}} + \frac{m_2c^2}{\sqrt{1 - (v_2/c)^2}} - \frac{m_1c^2}{\sqrt{1 - (u_1/c)^2}} - \frac{m_2c^2}{\sqrt{1 - (u_2/c)^2}} = 0

\frac{m_1c^2 (v_1/c)}{\sqrt{1 - (v_1/c)^2}} + \frac{m_2c^2 (v_2/c)}{\sqrt{1 - (v_2/c)^2}} - \frac{m_1c^2 (u_1/c)}{\sqrt{1 - (u_1/c)^2}} - \frac{m_2c^2 (u_2/c)}{\sqrt{1 - (u_2/c)^2}} = 0

I obtained the following contour plots using Python:

So, again this system has two roots, a trivial one which involves setting the final velocities equal to the initial velocities, and a nontrivial root which turned out to be (-0.68999624, 0.48073178) (again found using quasi-newton methods).

What intrigued me is that the relativistic case also produced a closed loop for the energy contour and an open curve for the momentum contour. The energy contour is a closed loop for reasons which are similar to those of the Newtonian case. In the relativistic case, the energy of each particle is bounded below by its rest energy (given by Einstein’s famous formula E = mc^2) and bounded above by the total energy of the system (determined by the initial conditions) minus the rest energy of the other particle, so the closed energy contour again arises as a result of the total energy being distributed continuously between the particles subject to these bounds, and due to a symmetry between negative and positive velocities arising due to the quadratic form of the velocity term in the Lorentz factor. In the case of momentum, however, even though relativistic velocities are bounded by the speed of light c, we still get an open curve for the momentum contour (though not one that extends indefinitely) because velocity appears linearly in the numerator of the relativistic momentum terms so the contour for momentum is still unable to ‘close’ in this case.

Published by Dr Christian P. H. Salas

Mathematics Lecturer

Leave a comment