See the Pen Fourier series by André Michelle (@andremichelle) on CodePen.

### Fourier series

In maths, a Fourier series () is a way to represent a function as the sum of simple sine waves. More formally, it decomposes any periodic function or periodic signal into the weighted sum of a (possibly infinite) set of simple oscillating functions, namely sines and cosines (or, equivalently, complex exponentials).

Definition from Wikipedia – Fourier series