Fourier series of functions with variable period

93 Views Asked by At

Consider the function $f(x)=\sum_{n=1}^\infty f_{n}(x)$ where $$f_n(x)= \left\{ \begin{array}{lr} mod(x, n) & x \in [n^2, (n+1)^2] \\ 0 & \text{otherwise} \end{array}\right..$$ You can see $f$ as the identity function in $[0, 1]$ extended "periodically" with periods the squares of the integers picture You could also see it as $f(x)=x-floor(\sqrt{x})^2$ i think. Is there a way to express $f(x)$ as a series of sines and cosines in the same way as Fourier series expresses periodical functions?

The only thing i got is that $2\sqrt{x}-1$ (in blue) is a good interpolation of the upper bounds of the $f_n$ bits and could therefore be somehow related to the coefficients of said sines and cosines. interp