Solution (source code)

= Solution

Motion under a <central force> is planar. In <plane polar coordinates>, the radial component of the <acceleration> is $\ddot r-r\dot\theta^2$, so
$$
\ddot r-r\dot\theta^2=-\frac{k}{r^2}.
$$
The conserved specific <angular momentum> is $h=r^2\dot\theta$. Substitution of $\dot\theta=h/r^2$ yields
$$
\boxed{\ddot r=-\frac{k}{r^2}+\frac{h^2}{r^3}}.
$$
The last term is the centrifugal part of the radial <effective potential>.