I was just wondering, given the idea that the Fourier series can be thought of as the basis expansion of an element of a vector space given the basis $cos(x)$ and $sin(x)$, what is the requirement of $f(x)$ to be an element of this space since presumably it can't be any old function