Source: https://perso.math.univ-toulouse.fr/marechal/files/2012/04/TD-S%25C3%25A9ries-Fourier.pdf