Is there any special reason that we use the sines and cosines functions in the Fourier Series, while we know that if we chose any maximal orthonormal system in L2, we would get the same result? 
Is it something historical or what?


Thanks in advance.



Why sin and cos in the Fourier Series?
$1$. Mathematical reason.


There is one reason which makes the basis of complex exponentials look very natural, and the reason is from complex analysis. Let $f(z)$ be a complex analytic function in the complex plane, with period $1$. 


Then write the substitution $q = e^{2\pi i z}$. This way the analytic function $f$ actually becomes a meromorphic function of $q$ around zero, and $z = i \infty$ corresponds to $q = 0$. The Fourier expansion of $f(z)$ is then nothing but the Laurent expansion of $f(q)$ at $q = 0$.


Thus we have made use of a very natural function in complex analysis, the exponential function, to see the periodic function in another domain. And in that domain, the Fourier expansion is nothing but the Laurent expansion, which is a most natural thing to consider in complex analysis.


Here you can make suitable modifications when $f$ is periodic in some domain which is not the whole complex plane. In that case in the $q$-domain, $f$ will be analytic in some circle around $0$, and you can use that to get a Laurent expansion. The modular forms for instance are defined only in the upper-half plane, and what we get here is called the $q$-expansion.


However from the point of view of Real analysis, $L^p$-spaces etc., any other base would do just as fine as the complex exponentials. The complex exponentials are special because of complex analytic reasons.


$2$. Physical reason.


There are historical reasons also. For instance, in electrical engineering or theory of waves, it is very useful to decompose a function into its frequency components and this is the reason for the great importance of Fourier analysis in electrical engineering or in electrical communication theory. The impedance offered by circuits depends on the frequency of the signal that is being fed in, and a circuit consisting of capacitors, inductors etc. react differently to different frequencies, and thus the sine/cosine wave decomposition is very natural from a physical point of view. And it was from this context, and also the theory of heat conduction, that Fourier analysis developed up.


