Processing math: 100%

Fourier Series

From LNTwww


General Description


Every periodic function  x(t)  can be fragmented into a trigonometric series, which is called Fourier series, in all areas, where it is continuous or has only finite discontinuities.

Definition:  The  Fourier series   of a periodic signal  x(t)  is defined as follows

x(t)=A0+n=1Ancos(nω0t)+n=1Bnsin(nω0t).

Here the symbols denote the following definitions:

  • A0  the  constant component  of  x(t),
  • An  the  cosine coefficients  with  n1,
  • Bn  the  sine coefficients  mit  n1,
  • ω0=2π/T0 the  angular frequency  of the periodic signal  (T0 is the period duration).


If the Fourier series is to exactly match the actual periodic signal  x(t) , an infinite number of cosine and sine coefficients must generally be used for calculation.

  • If the Fourier series is interrupted and only  N  of  An  and  Bn coefficients is used, then a slightly different plot of the function results except for some special cases:
xN(t)=A0+Nn=1Ancos(nω0t)+Nn=1Bnsin(nω0t).
  • The relation between the periodic signal  x(t)  and the Fourier series approximation  xN(t)  holds:
x(t)=limNxN(t).
  • If   Nf0  is the highest frequency occurring in the signal  x(t)  then of course  xN(t)=x(t).


Example 1:  We consider two periodic square wave signals, each with the period duration  T0  and the fundamental frequency  ω0=2π/T0.

Even and Odd Rectangle Pulse
  • For the even time signal sketched above:   xg(t)=xg(t).
  • The function shown below is odd:  xu(t)=xu(t).


One finds the  fourier series representations  of both signals in formularies:

xg(t)=4π[cos(ω0t)13cos(3ω0t)+15cos(5ω0t)...+...],
xu(t)=4π[sin(ω0t)+13sin(3ω0t)+15sin(5ω0t)+...+...].
  • Because of the generally valid relationship
113+1517+19...+...=π4

the amplitudes (maximum values) of the two rectangle pulses result to  1.

  • This can also be verified using the signal curves in the above graphic:
xg(t=0)=xu(t=T0/4)=1.


Calculation of the Fourier Coefficients


The Fourier coefficient  A0  specifies the  constant component  which can be determined by averaging over the signal course  x(t) . Due to the periodicity, averaging over one period is sufficient:

A0=1T0+T0/2T0/2x(t)dt.

The integration limits can also be selected from  t=0  to  t=T0  (or over a differently defined period of equal length).

The determination of the Fourier coefficients  An  and  Bn  (n1)  is based on the property that the harmonic cosine functions and sine functions are so-called orthogonal functions . For them the following applies:

+T0/2T0/2cos(nω0t)cos(mω0t)dt={T0/20ifm=n,sonst
+T0/2T0/2sin(nω0t)sin(mω0t)dt={T0/20ifm=n,sonst
+T0/2T0/2cos(nω0t)sin(mω0t)dt=0f¨uralle m, n.

Conclusion: Considering these equations, the cosine coefficients  An  and the sine coefficients  Bn  result as follows

An=2T0+T0/2T0/2x(t)cos(nω0t)dt,
Bn=2T0+T0/2T0/2x(t)sin(nω0t)dt.


The german learning video  Calculating the Fourier Coefficients  illustrates these equations.

On Calculating the Fourier Coefficients

Example 2:  We consider the drawn periodic time function

x(t)=0.4+0.6cos(ω0t)0.3sin(3ω0t).

Since the integral of the cosine and sine functions is identical to zero over one period in each case, one obtains for the DC signal coefficient  A0=0.4.

One determines the cosine coefficient  A1  with the following equations (Integration limits from  t=0  to t=T0):

A1=2T0T000.4cos(ω0t)dt+2T0T000.6cos2(ω0t)dt2T0T000.3sin(3ω0t)cos(ω0t)dt.

The last integral is equal to zero due to orthogonality; the first one is zero too (integral over one period).

  • Only the middle term contributes here to  A1, namely  20.60.5=0.6.
  • For all further  (n2)  cosine coefficients all three integrals return the value zero, and thus  An1=0.


To determine the sine coefficients   Bn  with the determining equation:

Bn=2T0T000.4sin(n ω0t)dt+2T0T000.6cos(ω0t)sin(nω0t)dt2T0T000.3sin(3ω0t)sin(nω0t)dt.
  • For  n3  all three integral values are zero and therefore  Bn3=0.
  • On the other hand, for  n=3  the last integral provides a contribution, and one gets for the sine coefficient  B3=0.3.


Exploitation of Symmetries


Some insights into the Fourier coefficients  An  and  Bn  can already be read from the  Symmetry properties  of the time function  x(t) .

  • If the time signal   x(t)  is an even function   ⇒   axis-symmetrical around the ordinate  (t=0), all sine coefficients  Bn disappear, since the sine function itself is an odd function   ⇒   sin(α)=sin(α):
Bn=0(n=1, 2, 3,...).
  • An odd function  x(t)  is point symmetric around the coordinate origin  (t=0; x=0). Therefore, all cosine coefficients  (An=0) disappear here, since the cosine function itself is even. In this case, the constant component  A0  is also always zero.
An=0(n=0, 1, 2, 3,...).
  • If a function without a constant component is present  (A0=0)  and if this function is odd within a period   ⇒   it is  x(t)=x(tT0/2), then only odd multiples of the fundamental frequency are present in the Fourier series representation. For the coefficients with an even index, however, the following always applies:
An=Bn=0(n=2, 4, 6,...).
  • If all coefficients  An  and  Bn  with even-numbered index  (n=2, 4, 6,...)  equals zero and the coefficient  A00, then the symmetry property mentioned in the last point refers to the DC component and applies:
x(t)=2A0x(tT0/2).

Remark:   Several of the named symmetry properties can be fulfilled at the same time.

The symmetry properties of the Fourier coefficients are explained in the first part of the german learning video  Properties and Accuracy of the fourier series .

Symmetry Properties of the Fourier Coefficients

Example 3:  The above mentioned properties are now illustrated by three signal characteristics.

  • x1(t)  is an averaged function   ⇒   A00 and is also even, which is accordingly exclusively determined by cosine coefficients  An   (Bn=0).


  • In contrast, the odd function  x2(t)  all  An, (n0)  are identical to zero.


  • Also the odd function  x3(t)  contains only sine coefficients, but because of  x3(t)=x3(tT0/2)  exclusively for odd values of  n.


Complex Fourier Series


As shown on the page  3 Representation with Cosine and Sine Components  in case of a harmonic oscillation any periodic signal


x(t)=A0+n=1Ancos(nω0t)+n=1Bnsin(nω0t)

can also be displayed using the magnitude and phase coefficients:

x(t)=C0+n=1Cncos(nω0tφn).

These modified Fourier coefficients have the following properties:

  • The  DC coefficient  C0  is identical with  A0.
  • The  magnitude coefficient  read with   n1:   Cn=A2n+B2n.
  • For the  phase coefficient  applies:   φn=arctan(Bn/An).


With the „Eulerian relationship”  cos(x)+jsin(x)=ejx  we get a second representation variant of the Fourier series evolution, which starts from the complex exponential function.

Definition:  The  complex Fourier series   of a periodic signal  x(t)  is as follows

x(t)=+n=Dnejnω0t.

Here  Dn  denote the  complex Fourier coefficients, which

  • from the cosine coefficients  An  and the sine coefficients  Bn, or
  • from the magnitude coefficients  Cn  and the phase coefficients  φn


can be calculated as follows (valid for  n0):

Dn=1/2(AnjBn)=1/2Cnejφn


The complex Fourier coefficients can also be calculated directly using the following equation

Dn=1T0+T0/2T0/2x(t)ejnω0tdt.

As long as the integration interval  T0  is preserved, it can be shifted randomly as with the coefficients  An  and  Bn  for example from  t=0  to  t=T0.

Conclusion:  The coefficient  D0=A0  is always real. For the complex coefficients with negative iterating index  (n<0)  applies:

Dn=Dn=1/2(An+jBn).


Periodic Signal Spectrum


Starting from the complex Fourier series just derived

x(t)=+n=Dnejnω0t

and the   Displacement Theorem  (for the frequency domain) one gets the following spectrum for the periodic signal  x(t):

X(f)=+n=Dnδ(fnf0).

This means:

  • The spectrum of a signal periodic with  T0  is a  line spectrum  for integer multiples of the fundamental frequency  f0=1/T0.
  • The  constant component   returns a dirac function at  f=0  with the impulse weight  A0.
  • There are also   dirac functions  δ(f±nf0)  at the multiples of  f0, whereas  δ(fnf0)  denotes a dirac function at   f=nf0  (namely in the nonnegative frequency domain) and  δ(f+nf0)  denotes a dirac at the frequency  f=nf0  (n the negative frequency domain).
  • The  pulse weights   are generally complex.

Diese Aussagen werden nun anhand zweier Beispiele verdeutlicht.

Example 4:  We consider - as in  Example 1 at the beginning of this section - two periodic square wave signals, each with period duration  T0  and fundamental frequency  f0=1/T0. The upper signal

xg(t)=4/π[cos(ω0t)1/3cos(3ω0t)+1/5cos(5ω0t)...+...]

is a even function, composed of different cosine parts. The corresponding spectral function  Xg(f)  is thus purely real.

Reason:  As already described on the page  Spectral Representation of a Cosine Signal   The fundamental wave returns two Dirac functions at  ±f0, each weighted with  2/π.

  • This weighting corresponds to the (generally complex) Fourier coefficients  D1=D1, which are only real in the special case of an even function.
  • Other dirac functions are available in  ±3f0 (negative),  ±5f0 (positive),  ±7f0 (negative) etc.
  • All phase values  φn  are either zero or  π due to the alternating signs.


Spectrum of a periodic rectangle pulse

The function  xu(t)  shown below is odd:

xu(t)=4/π[sin(ω0t)+1/3sin(3ω0t)+1/5sin(5ω0t)+...].

Reason: As already described in the  Example 4  on the page  General Spectral Representation  the fundamental wave provides two Dirac functions at  +f0  (weighted with  j2/π)  bzw. bei  f0  (weighted with   +j2/π).

  • All other Dirac functions at  ±3f0±5f0, etc. are purely imaginary and are located in the same direction as the Dirac functions at  ±f0.
  • The two magnitude spectra are equal:   |Xu(f)|=|Xg(f)|.


The Gibbs Phenomenon


Not every signal is suitable for the fourier series.Some restrictions below:

  • An important condition for the convergence of the Fourier series is that the signal may only have a finite number of discontinuities per period.
  • At those places  t=ti, where  x(t)  has jumps, the series converges to the arithmetic mean value formed by the respective left and right boundary value.
  • In the surrounding area of such discontinuities, high-frequency oscillations usually occur in the row representation. This error is of principle kind, i.e. it could not be avoided too, if infinite summands would be considered. One speaks of  Gibbs phenomenon, named after the physicist  Josiah Willard Gibbs.
  • An increase of  N  reduces the erroneous range but not the maximum deviation between  x(t)  and the Fourier series representation  xN(t). The maximum error is ca.  9%  of the jumping amplitude - independent of  N.


The Gibbs phenomenon and other interesting aspects of comparable effects are presented in the german learning video  Properties of Fourier Series Representations .


Example 5:  The left graphic shows a dotted section of a periodic  ±1 rectangle signal and the corresponding Fourier series representation with  N=1  (blue),  N=3  (red) and  N=5  (green) summands.

  • The fundamental wave here has the amplitude value  4/π1.27.
  • Even with  N=5  (this means because of  A2=A4=0  three „relevant” summands) the Fourier series still differs significantly from the approximated square wave signal, especially in the area of the edge.


On the Gibbs Phenomenon

From the right graphic you can see that the flank and the inner area are marked with  N=100  but due to the Gibbs phenomenon there are still oscillations around  9%  at the jumping point.

  • Since the jump amplitudes here are equal to  2  the maximum values are approximately  1.18.
  • With  N=1000  the oscillations would be exactly the same size, but limited to a narrower space and possibly not recognizable with time-discrete representation.


Exercises for the Chapter


Aufgabe 2.4: Gleichgerichteter Cosinus

Aufgabe 2.4Z: Dreiecksignal

Aufgabe 2.5: Einweggleichrichtung

Aufgabe 2.5Z: Rechtecksignale

Aufgabe 2.6: Komplexe Fourierreihe

Aufgabe 2.6Z:   Betrag und Phase