= Solution
Project the expansion onto one normalized basis function. <Orthogonality> removes every other coefficient:
$$
\begin{aligned}
\int_0^a\Psi_m(x)^*f(x)\,\mathrm dx
&=\sum_{n=1}^{\infty}a_n\int_0^a\Psi_m(x)^*\Psi_n(x)\,\mathrm dx\\
&=\sum_{n=1}^{\infty}a_n\delta_{mn}=a_m.
\end{aligned}
$$
Consequently,
$$
\boxed{a_n=\langle\Psi_n|f\rangle
=\sqrt{\frac2a}\int_0^a f(x)\sin\frac{n\pi x}{a}\,\mathrm dx.}
$$
This is a <Fourier sine series> in normalized form. For a square-integrable $f$, completeness gives convergence in the norm of the function space; pointwise convergence requires the usual additional regularity. If $f$ is a normalized <wavefunction>, the <Born rule> gives probabilities $|a_n|^2$ and $\sum_n|a_n|^2=1$.
Back to article page