Statement

For a continuous LL-periodic function ff, an LL-periodic antiderivative exists exactly when ∫0Lf(s) ds=0\int_0^L f(s)\,ds=0. Under this condition a primitive is

F(x)=∫0xf(s) ds,F(x)=\int_0^x f(s)\,ds,

and all primitives differ by a constant. There is exactly one with over a period.

Proof and Fourier formula

Periodicity of a primitive forces 0=F(L)−F(0)=∫0Lf0=F(L)-F(0)=\int_0^L f. Conversely, periodicity of ff gives F(x+L)−F(x)=∫xx+Lf=0F(x+L)-F(x)=\int_x^{x+L}f=0. Subtract its average to normalize FF. If ff is smooth with period one, the normalized primitive has coefficients F^(m)=f^(m)/(2πim)\widehat F(m)=\widehat f(m)/(2\pi im) for m≠0m\ne0, and F^(0)=0\widehat F(0)=0.