TITLE: What functions can be represented as a series of eigenfunctions
QUESTION [7 upvotes]: Consider the differential equation:
$y'' = \lambda y$
with the boundary conditions
$y(0) = y(2\pi) = 0$.
This equation has eigenfunctions $\mu_n(x) = \sin(\frac{nx}{2})$ with the corresponding eigenvalues $\lambda_n = -\frac{n^2}{4}$ for $n > 0$

Am I right, that certain functions f(x) satisfying the same boundary conditions as above can be represented as an infinite series
$f(x) = \sum_1^\infty c_n \mu_n(x)$ with coefficients $c_n = \frac{\langle f,\mu_n \rangle}{\langle \mu_n, \mu_n \rangle}$? What conditions those certain functions need to satisfy?
Can the previous claim be generalised for any set of eigenfunctions of some differential equation? I.E. suppose $Ly = \lambda y$ is a differential equation ($L$ being the 2nd order differential operator) with boundary conditions $y(a) = y(b) = c$ . What functions can be represented as a weighted sum of the eigensolutions?

REPLY [2 votes]: Consider the following problem on the interval $[a,b]$ for some $a < b$ and real angles $\alpha,\beta$:
$$
            y''=\lambda y,\;\;\; a \le x \le b, \\
      \cos\alpha y(a)+\sin\alpha y'(a) = 0 \\
      \cos\beta y(b)+\sin\beta y'(b) = 0
$$
This gives rise to a discrete set of eigenvalues
$$
      \lambda_1 < \lambda_2 < \lambda_3 < \cdots,
$$
and associated eigenfunctions $\phi_n(x)$. For any function $f\in L^2[a,b]$, the Fourier series for $f$ in these eigenfunctions converges to $f$ in $L^2[a,b]$. And you get pointwise convergence of the series at $x\in(a,b)$ under the same type of Fourier conditions that you learned for the ordinary Fourier series. The endpoint conditions make the convergence at $x=a,b$ trickier, of course. Conditions of the type $y(a)=0=y(b)$, for example, forces any series in these eigenfunctions to converge to $0$ at the endpoints.