Solution (source code)

= Solution

Work first in units $c=1$. In the <neutron> rest frame, let $s_{p\nu}=(p_p+p_\nu)^2$. From $p_n-p_e=p_p+p_\nu$,
$$
s_{p\nu}=m_n^2+m_e^2-2m_nE_e,
\qquad E_e=\frac{m_n^2+m_e^2-s_{p\nu}}{2m_n}.
$$
The <electron>'s minimum possible total energy is its rest energy. This configuration has the <electron> at rest while the <proton> and massless <antineutrino> move back to back with equal momentum magnitudes. Their common momentum satisfies a two-body energy balance for the remaining mass $m_n-m_e$:
$$
\boxed{E_{e,\min}=m_ec^2,\qquad
|\mathbf p_p|=|\mathbf p_\nu|=
\frac{(m_n-m_e)^2-m_p^2}{2(m_n-m_e)}c,\quad\mathbf p_p=-\mathbf p_\nu.}
$$
For the maximum <electron> energy, minimize $s_{p\nu}$. Since the massless <antineutrino> has nonnegative energy, $s_{p\nu}\geq m_p^2$, with the boundary reached as its energy tends to zero. Then
$$
\boxed{E_{e,\max}=\frac{m_n^2+m_e^2-m_p^2}{2m_n}c^2.}
$$
At this limiting endpoint the <electron> and <proton> have equal and opposite momenta. The <proton> recoils; it is \b[not] at rest. A massless <neutrino> has no rest frame, so “<neutrino> at rest” must be replaced by the precise soft-energy limit $E_\nu\to0$. The <electron>'s maximum <kinetic energy> is the displayed total energy minus $m_ec^2$, rather than the same number. These endpoint configurations lie on phase-space boundaries; their kinematic existence does not imply a nonzero event density exactly at the boundary.