Generated by the Physics Derivation Graph. Eq. \ref{eq:4978059} is an initial equation. $$\vec{p}_{\rm before} = \vec{p}_{\rm after} \label{eq:4978059}$$ Eq. \ref{eq:2840008} is an initial equation. $$\vec{p}_{\rm before} = \vec{p}_{1} \label{eq:2840008}$$ Eq. \ref{eq:1209604} is an initial equation. $$\vec{p}_{\rm after} = \vec{p}_{2}+\vec{p}_{electron} \label{eq:1209604}$$ Substitute LHS of Eq. \ref{eq:2840008} into Eq. \ref{eq:4978059}; yields Eq. \ref{eq:2491904}. $$\vec{p}_{\rm after} = \vec{p}_{1} \label{eq:2491904}$$ Substitute LHS of Eq. \ref{eq:2491904} into Eq. \ref{eq:1209604}; yields Eq. \ref{eq:5610925}. $$\vec{p}_{1} = \vec{p}_{2}+\vec{p}_{electron} \label{eq:5610925}$$ Subtract $$\vec{p}_{2}$$ from both sides of Eq. \ref{eq:5610925}; yields Eq. \ref{eq:4068150}. $$\vec{p}_{1}-\vec{p}_{2} = \vec{p}_{electron} \label{eq:4068150}$$ Swap LHS of Eq. \ref{eq:4068150} with RHS; yields Eq. \ref{eq:4200334}. $$\vec{p}_{electron} = \vec{p}_{1}-\vec{p}_{2} \label{eq:4200334}$$ Multiply Eq. \ref{eq:4200334} by Eq. \ref{eq:4200334}; yields Eq. \ref{eq:4218805}. $$\vec{p}_{electron}\cdot\vec{p}_{electron} = ( \vec{p}_{1}\cdot\vec{p}_{1})+( \vec{p}_{2}\cdot\vec{p}_{2})-2( \vec{p}_{1}\cdot\vec{p}_{2}) \label{eq:4218805}$$