Fourier series examples
Consider the waveforms that you can generate with the following applet:All of these are periodic. The sinusoid has the least interesting timbre, suggesting that it will have the simplest harmonic structure. The following applet shows the Fourier series coefficients for each waveform.
The exact waveform is shown in red, and an approximation in blue. The
right edge of each red bar aligns with the scale at the bottom, so the
fundamental, corresponding to the first red bar, is at 125Hz, with is one
over the period of 8 milliseconds.
The approximation obtained by summing selected terms from the Fourier
series. You can control which terms are used through the checkboxes on
the right, but only up to 16 terms can be included in the approximation.
The Fourier series coefficients are shown on the plot labeled "Frequency domain". The phase is not shown, but rather only A_{k}. The components you select are shown in blue. This lower plot is called a frequency domain representation of the waveform because it describes the waveform in terms of its frequency components.
Notice the following about these plots:
- There is no constant term. The average value in the time domain is zero.
- The fundamental is 125 Hz.
- The first harmonic, which would be at 250 Hz, is absent for all but the sawtooth.
- The even Fourier series coefficients (k = 0, 2, 4, ...) are all absent for all but the sawtooth. This subtle property is due to the symmetry of waveforms (except for the sawtooth, which is not symmetric).
- The coefficients become small quickly for the triangle wave, but not for the square wave or the sawtooth. Intuitively, the sharp discontinuities in the square wave and the sawtooth imply relatively large high frequency components.
- For the square wave, the peak error of the approximation (the maximum difference between the red and blue curves) does not appear to decrease as the number of terms in the approximation is increased. This is known as Gibb's phenomenon, and indeed, the square wave is one that cannot be exactly described with a Fourier series. The peak error does not decrease to zero as the number of terms in the Fourier series is increased to infinity.