Calculus

Fourier Series

Fourier Series Logo

Differentiation and Integration of Fourier Series

Differentiation of Fourier Series

Let f (x) be a 2π-periodic piecewise continuous function defined on the closed interval [−π, π]. As we know, the Fourier series expansion of such a function exists and is given by

\[f\left( x \right) = \frac{{{a_0}}}{2} + \sum\limits_{n = 1}^\infty {\left( {{a_n}\cos nx + {b_n}\sin nx} \right)} .\]

If the derivative f ' (x) of this function is also piecewise continuous and the function f (x) satisfies the periodicity conditions

\[f\left( { - \pi } \right) = f\left( \pi \right),\;\; f'\left( { - \pi } \right) = f'\left( \pi \right),\]

then the Fourier series expansion of the derivative \(f'\left( x \right)\) is expressed by the formula

\[f'\left( x \right) = \sum\limits_{n = 1}^\infty {\left( {n{b_n}\cos nx - n{a_n}\sin nx} \right)} .\]

Integration of Fourier Series

Let \(g\left( x \right)\) be a \(2\pi\)-periodic piecewise continuous function on the interval \(\left[ { - \pi ,\pi } \right].\) Then this function can be integrated term by term on this interval. The Fourier series for \(g\left( x \right)\) is given by

\[g\left( x \right) = \frac{{{a_0}}}{2} + \sum\limits_{n = 1}^\infty {\left( {{a_n}\cos nx + {b_n}\sin nx} \right)} .\]

Consider the function

\[G\left( x \right) = \int\limits_0^x {g\left( t \right)dt} \sim \frac{{{A_0}}}{2} + \sum\limits_{n = 1}^\infty {\left( {{A_n}\cos nx + {B_n}\sin nx} \right)},\]

where \({A_n} = - {\frac{{{b_n}}}{n}},\) \({B_n} = {\frac{{{a_n}}}{n}}.\)

By setting \(x = 0,\) we see that

\[G\left( 0 \right) = 0 = \frac{{{A_0}}}{2} + \sum\limits_{n = 1}^\infty {{A_n}} = \frac{{{A_0}}}{2} - \sum\limits_{n = 1}^\infty {\frac{{{b_n}}}{n}} \;\;\text{or}\;\; \frac{{{A_0}}}{2} = \sum\limits_{n = 1}^\infty {\frac{{{b_n}}}{n}} .\]

Hence, the Fourier series expansion of the function \(G\left( x \right)\) is defined by

\[G\left( x \right) = \int\limits_0^x {g\left( t \right)dt} = \int\limits_0^x {\frac{{{a_0}}}{2}dx} + \sum\limits_{n = 1}^\infty {\int\limits_0^x {\left( {{a_n}\cos nx + {b_n}\sin nx} \right)dx} } = \frac{{{a_0}x}}{2} + \sum\limits_{n = 1}^\infty {\frac{{{a_n}\sin nx + {b_n}\left( {1 - \cos nx} \right)}}{n}},\]

where the series on the right-hand side is obtained by the formal term-by-term integration of the Fourier series for \(g\left( x \right).\)

Because of the presence of the term depending on \(x\) on the right-hand side, this is not clearly a Fourier series expansion of the integral of \(g\left( x \right).\) The result can be rearranged to be a Fourier series expansion of the function

\[\Phi \left( x \right) = \int\limits_0^x {g\left( t \right)dt} - \frac{{{a_0}x}}{2}.\]

The Fourier series of the function \(\Phi\left( x \right)\) is given by the expression

\[\Phi \left( x \right) = \int\limits_0^x {g\left( t \right)dt} - \frac{{{a_0}x}}{2} = \frac{{{A_0}}}{2} + \sum\limits_{n = 1}^\infty {\left( {{A_n}\cos nx + {B_n}\sin nx} \right)} ,\]

where the Fourier coefficients are defined by the relationships:

\[\frac{{{A_0}}}{2} = \sum\limits_{n = 1}^\infty {\frac{{{b_n}}}{n}} ,\;\; {A_n} = - \frac{{{b_n}}}{n},\;\; {B_n} = \frac{{{a_n}}}{n}.\]

Solved Problems

Example 1.

Find the Fourier series of the sign function

\[ f\left( x \right) = \text{sign}\,x = \begin{cases} -1, & -\pi \le x \le 0 \\ 1, & 0 \lt x \le \pi \end{cases},\]

knowing that the Fourier series expansion of the function \(F\left( x \right) = \left| x \right|\) on the interval \(\left[ { - \pi ,\pi } \right]\) is given by

\[F\left( x \right) = \left| x \right| = \frac{\pi }{2} - \frac{4}{\pi }\sum\limits_{n = 0}^\infty {\frac{{\cos \left( {2n + 1} \right)x}}{{{{\left( {2n + 1} \right)}^2}}}}.\]

Solution.

As \(f\left( x \right) = F'\left( x \right)\) for all \(x \ne 0,\) we obtain

\[f\left( x \right) = \frac{d}{{dx}}\left[ {\frac{\pi }{2} - \frac{4}{\pi }\sum\limits_{n = 0}^\infty {\frac{{\cos \left( {2n + 1} \right)x}}{{{{\left( {2n + 1} \right)}^2}}}} } \right] \]

or

\[f\left( x \right) = \frac{4}{\pi }\sum\limits_{n = 0}^\infty {\frac{{\sin\left( {2n + 1} \right)x}}{{2n + 1}}} .\]

The graphs of the given function and its Fourier approximation are shown in Figure \(1.\)

Fourier series for the sawtooth wave
Figure 1, n = 5, n = 50

Example 2.

Find the Fourier series expansion of the function \(f\left( x \right) = {x^2}\) knowing that

\[x = 2\sum\limits_{n = 1}^\infty {\frac{{{{\left( { - 1} \right)}^{n + 1}}}}{n}\sin nx}\]

for \(- \pi \le x \le \pi.\)

Solution.

As the function \(f\left( x \right)\) is piecewise continuous on the interval \(\left[ { - \pi ,\pi } \right],\) we may integrate its Fourier series term by term to obtain

\[\int\limits_{ - \pi }^x {tdt} = 2\sum\limits_{n = 1}^\infty {\int\limits_{ - \pi }^x {\frac{{{{\left( { - 1} \right)}^{n + 1}}}}{n}\sin nt\,dt} } .\]

Consequently,

\[ \frac{{{x^2}}}{2} - \frac{{{\pi ^2}}}{2} = 2\sum\limits_{n = 1}^\infty {{{\left( { - 1} \right)}^{n + 1}}\left[ {\left. {\left( { - \frac{{\cos nt}}{{{n^2}}}} \right)} \right|_{ - \pi }^x } \right]} ,\;\; \Rightarrow \frac{{{x^2}}}{2} - \frac{{{\pi ^2}}}{2} = 2\sum\limits_{n = 1}^\infty {\frac{{{{\left( { - 1} \right)}^n}}}{{{n^2}}}\left[ {\cos nx - \cos \left( { - \pi n} \right)} \right]} ,\;\; \Rightarrow \frac{{{x^2}}}{2} - \frac{{{\pi ^2}}}{2} = 2\sum\limits_{n = 1}^\infty {\frac{{{{\left( { - 1} \right)}^n}}}{{{n^2}}}\cos nx} - 2\sum\limits_{n = 1}^\infty {\frac{{{{\left( { - 1} \right)}^n}{{\left( { - 1} \right)}^n}}}{{{n^2}}}} ,\;\; \Rightarrow \frac{{{x^2}}}{2} - \frac{{{\pi ^2}}}{2} = 2\sum\limits_{n = 1}^\infty {\frac{{{{\left( { - 1} \right)}^n}}}{{{n^2}}}\cos nx} - 2\sum\limits_{n = 1}^\infty {\frac{1}{{{n^2}}}} .\]

We know from Example \(1\) on the page Bessel's Inequality and Parseval's Theorem that \(\zeta \left( 2 \right) = \sum\limits_{n = 1}^\infty {\frac{1}{{{n^2}}}} = {\frac{{{\pi ^2}}}{6}}.\) Then we get

\[{x^2} - {\pi ^2} = 4\sum\limits_{n = 1}^\infty {\frac{{{{\left( { - 1} \right)}^n}}}{{{n^2}}}\cos nx} - \frac{{2{\pi ^2}}}{3}\]

or

\[{x^2} = \frac{{{\pi ^2}}}{3} + 4\sum\limits_{n = 1}^\infty {\frac{{{{\left( { - 1} \right)}^n}}}{{{n^2}}}\cos nx} .\]

See more problems on Page 2.

Page 1 Page 2