What exactly does it mean for the Hermite polynomials to be a bases for $L^2(\mathbb{R})$ functions? In a lot of source it is mentioned that the Hermite polynomials are an orthonormal bases (with respect to a specific inner product) of $L^2(\mathbb{R})$ functions. Does this mean that for any $f \in L^2(\mathbb{R})$, we have
\begin{align}
f(x) = \sum_{n = 0}^\infty a_nH_n(x),
\end{align}
where $a_n$ are constants and $H_n(x)$ the Hermite polynomial of degree n. Or does the sum have to be replaced by an integral or something? Also, if the above expansion is correct, is there something known about the coefficients $a_n$?
Thanks for the help!
 A: You are correct in saying that being an orthonormal basis means $f = \sum_{n=0}^\infty a_nH_n$ in $L^2(\mathbb{R})$ with the particular inner product $\langle f, g\rangle = \int_{\mathbb{R}} f(x)\overline{g(x)}e^{-x^2} dx$. But there are some underlying things which define what we mean by this summation.
The term "basis" is probably drawn from the concept of a Schauder basis. If you take a topological vector space $X$--for example, a normed space with topology defined by convergence in norm--then a Schauder basis is a sequence $(e_n) \subseteq X$ such that for every $x \in X$, there exist unique scalars $(a_n)$ such that $x = \sum_{n=0}^\infty a_ne_n$, where the convergence means $\lim_{N\to\infty} \|x - \sum_{n=0}^N a_ne_n\| = 0$. It's a natural extension of the algebraic concept of a basis to include infinite sums.
The Hermite polynomials satisfy this condition. But as pointed out in the comments, this does NOT mean that the sum $\sum_{n=0}^\infty a_nH_n$ converges uniformly, pointwise, or even (a priori) in the "traditional" $L^2$ norm. It converges only in the topology defined by the above inner product (you might be able to get the regular $L^2$ convergence, but I'm not sure on that).
Schauder bases have nicer properties if we are in a Hilbert space (like $L^2$) and the basis vectors are orthonormal (hence the term "orthonormal basis," although I prefer the term "total orthonormal set"). In this case, the series $f = \sum_{n=0}^\infty a_nH_n$ is called the "generalized Fourier series" of $f$ with respect to the basis. Because the inner product is continuous and linear in the first argument (or second, if you're doing quantum mechanics), one has the following:
$$
\langle f, H_m \rangle = \left\langle \sum_{n=0}^\infty a_nH_n, H_m \right\rangle = \sum_{n=0}^\infty \langle a_nH_n, H_m\rangle = \sum_{n=0}^\infty a_n\langle H_n, H_m\rangle = a_m\langle H_m, H_m\rangle = a_m.
$$
Based on the inner product we're using, this means your coefficients are
$$
a_m = \int_{-\infty}^\infty f(x)H_m(x)e^{-x^2} dx.
$$
This kind of behavior is one of the driving reasons for studying linear operators on Hilbert spaces in the first place.
