Spin-orbit energy shift in a central potential (source code)

= Spin-orbit energy shift in a central potential
{title2=$\Delta E=\hbar^2[j(j+1)-l(l+1)-s(s+1)]\langle r^{-1}V'(r)\rangle/(4m^2c^2)$}

For a central-potential <Hamiltonian operator> with the <spin-orbit interaction> $H_{\rm so}=[r^{-1}V'(r)/(2m^2c^2)]\mathbf L\cdot\mathbf S$, use $\mathbf J=\mathbf L+\mathbf S$ and
$$
\mathbf L\cdot\mathbf S=\tfrac12(J^2-L^2-S^2).
$$
A coupled <angular momentum eigenstate> makes this angular factor a number. The radial operator commutes with all angular factors, giving the energy shift in the title. It is independent of the magnetic projection $m_j$, so a fixed-$j$ multiplet retains its $2j+1$ degeneracy.

For <spin one-half>, the angular bracket is $l$ when $j=l+1/2$ and $-(l+1)$ when $j=l-1/2$. Only the former exists at $l=0$, where it is zero. For the <Coulomb potential energy>, $r^{-1}V'(r)=e^2/(4\pi\epsilon_0r^3)$; the radial normalization convention must be respected when computing its <expectation value>.