= Solution
One suitable choice is homogeneous <Dirichlet boundary conditions>, $\psi(\alpha)=\psi(\beta)=0$, with variations vanishing there. Assume real $q$ and the stated positive $p,w$. Introduce a <Lagrange multiplier> $\mu$ for $N[\psi]=1$. For real variations, <integration by parts> gives
$$
\delta(Q-\mu N)=2[p\psi'\eta]_\alpha^\beta+2\int_\alpha^\beta[-(p\psi')'+q\psi-\mu w\psi]\eta\,dx.
$$
The boundary term vanishes, so the <fundamental lemma of the calculus of variations> yields
$$
\boxed{-(p\psi')'+q\psi=\mu w\psi.}
$$
Multiplying this equation by $\psi$, integrating, and using the boundary conditions gives $Q[\psi]=\mu N[\psi]=\mu$. Thus the multiplier, the eigenvalue, and the constrained stationary value coincide. Conversely every normalized eigenfunction makes the first variation vanish for all tangent variations satisfying $\delta N=0$.
Homogeneous <Neumann boundary conditions>, $p\psi'=0$ at both endpoints, or mixed Dirichlet and Neumann conditions also work with this energy form. General <Robin boundary conditions> require the corresponding boundary terms in the form; they cannot simply be inserted into the displayed unmodified integral.
Back to article page