Series Expansion of Function over Complete Orthonormal Set

Theorem
Let $\map f x$ be a real function defined over the interval $\openint a b$.

Let $\map f x$ be able to be expressed in terms of a complete orthonormal set of real functions $S := \family {\map {\phi_i} x}_{i \mathop \in I}$ for some indexing set $I$:


 * $\map f x = \ds \sum_{i \mathop \in I} a_i \map {\phi_i} x$

Then the coefficients $\family {a_i}_{i \mathop \in I}$ can be determined as:
 * $\forall i \in I: a_i = \ds \int_a^b \map f x \map {\phi_i} x \rd x$