Target function:
Square wave
Sawtooth
Triangle
|sin x|
Terms N:
5
Blue: Fourier partial sum with N terms. Gray dashed: target function. The Gibbs overshoot near the square wave's jumps never disappears.