Cosine perturbation of the ground level in a one-dimensional box (source code)

= Cosine perturbation of the ground level in a one-dimensional box
{title2=$E=\dfrac{\pi^2\hbar^2}{2ma^2}-\dfrac\epsilon2-\dfrac{ma^2\epsilon^2}{16\pi^2\hbar^2}+O(\epsilon^3)$}

For the normalized sine eigenfunctions of a <particle in a box> on $(0,a)$, multiplying the lowest one by $\epsilon\cos(2\pi x/a)$ gives $\epsilon(\phi_3-\phi_1)/2$. Thus the first-order diagonal shift is $-\epsilon/2$, and the only second-order coupling is to level three. With $E_3=9E_1$, its contribution is $(\epsilon^2/4)/(E_1-E_3)=-\epsilon^2/(32E_1)$, giving the displayed expansion. This simple selection rule makes the full second-order <perturbation theory> sum a single term.