This program uses PyGame and Numpy to visualise how a Fourier series approximates a function (in this case a square wave).
As you move your mouse right and left across the screen the number of coefficients in the Fourier series increases or decreases. You can see how the approximation of the series improves with increasing coefficients as the RMSE decreases.
The animation is inspired by one seen on the wikipedia page for Fourier Series (https://en.wikipedia.org/wiki/Fourier_series).