Solution (source code)

= Solution

A weighted <Sturm-Liouville operator> has the form
$$
\boxed{Ly=\frac1{w(x)}\left[-\frac{d}{dx}\left(p(x)\frac{dy}{dx}\right)+q(x)y\right]},
$$
where $p,q,w$ are real, $p>0$ and $w>0$ in the interval's interior, and the coefficients have the regularity required by the derivatives. The corresponding <eigenvalue equation> is $-(py')'+qy=\lambda wy$. Its natural <weighted inner product> is $\langle f,g\rangle_w=\int w f\bar g\,dx$. Suitable endpoint conditions must also annihilate $[p(f\bar g'-f'\bar g)]$ for a <self-adjoint differential operator>; the displayed differential expression alone does not specify those conditions.