Fourier Series Applet, Curve fitting
Cuthbert Nyack
The Coefficients of the Fourier series are also what would be
obtained if a least squares curve fitting analysis is done with
sinusoidal harmonics being used to fit the function. The
analysis is illustrated in the MathCad file below for a
square wave defined by f(t). Both a1
and a3 have their correct values (4/p)
and (4/3p) when fitting is done.
The Applet below for a quadratic wave show how the error is affected as the coefficient is varied about the Fourier Series
value(1.032049) for n = 1. The wave is in magenta, the
Fourier approximation is in yellow, shifted upwards for
visibility and the error multiplied by the Gain is in orange. The Square of the
error is printed in blue. As the coefficient changes from 1.001
to 1.067, the error goes from 12.52..E-4 to 13.81..E-4 reaching
a minimum of 7.706..E-4 at a1 = 1.032.
When activated the following gif image show how the applet should appear.
Return to main page
Return to page index
COPYRIGHT © 1996 Cuthbert Nyack.