Differential equations – Partial differential equations – Fourier series
A series of the form
\[\frac{a_0}{2}+\sum_{n=1}^{\infty}\left(a_n\cos\left(\frac{n\pi x}{L}\right)+b_n\sin\left(\frac{n\pi x}{L}\right)\right),\quad L>0\]is called a Fourier series. The functions \(\displaystyle\cos\left(\frac{n\pi x}{L}\right)\) and \(\displaystyle\sin\left(\frac{n\pi x}{L}\right)\) are periodic with period \(2L\). Moreover they satisfy a remarkable orthogonality property:
Define an inner product: \(\langle f,g\rangle=\displaystyle\int_{\alpha}^{\beta}f(x)g(x)\,dx\) for functions \(f\) and \(g\) defined on the interval \((\alpha,\beta)\). Two functions \(f\) and \(g\) are then called orthogonal if \(\langle f,g\rangle=0\).
Now we have for \(m,n\in\{1,2,3,\ldots\}\):
\[\int_{-L}^L\cos\left(\frac{m\pi x}{L}\right)\cos\left(\frac{n\pi x}{L}\right)\,dx=\left\{\begin{array}{ll}0,&m\neq n\\[2.5mm]L,&m=n,\end{array}\right.\] \[\int_{-L}^L\sin\left(\frac{m\pi x}{L}\right)\sin\left(\frac{n\pi x}{L}\right)\,dx=\left\{\begin{array}{ll}0,&m\neq n\\[2.5mm]L,&m=n\end{array}\right.\]and
\[\int_{-L}^L\cos\left(\frac{m\pi x}{L}\right)\sin\left(\frac{n\pi x}{L}\right)\,dx=0.\]Proof: Using \(\cos(a+b)=\cos(a)\cos(b)-\sin(a)\sin(b)\) we have that \(\cos(a)\cos(b)=\frac{1}{2}\left(\cos(a-b)+\cos(a+b)\right)\). Dus:
\begin{align*} \int_{-L}^L\cos\left(\frac{m\pi x}{L}\right)\cos\left(\frac{n\pi x}{L}\right)\,dx &=\frac{1}{2}\int_{-L}^L\cos\left(\frac{(m-n)\pi x}{L}\right)\,dx+\frac{1}{2}\int_{-L}^L\cos\left(\frac{(m+n)\pi x}{L}\right)\,dx\\[2.5mm] &=\frac{1}{2}\left[\frac{L}{(m-n)\pi}\sin\left(\frac{(m-n)\pi x}{L}\right)+\frac{L}{(m+n)\pi}\sin\left(\frac{(m+n)\pi x}{L}\right)\right]_{-L}^L =0,\quad m\neq n \end{align*}and for \(m=n\) we use \(\cos(2a)=2\cos^2(a)-1\) to obtain:
\[\int_{-L}^L\left\{\cos\left(\frac{n\pi x}{L}\right)\right\}^2\,dx=\frac{1}{2}\int_{-L}^L\left\{1+\cos\left(\frac{2n\pi x}{L}\right)\right\}\,dx =\frac{1}{2}\left[x+\frac{L}{2n\pi}\sin\left(\frac{2n\pi x}{L}\right)\right]_{-L}^L=L.\]Similarly we have \(\sin(a)\sin(b)=\frac{1}{2}\left(\cos(a-b)-\cos(a+b)\right)\). Hence:
\begin{align*} \int_{-L}^L\sin\left(\frac{m\pi x}{L}\right)\sin\left(\frac{n\pi x}{L}\right)\,dx &=\frac{1}{2}\int_{-L}^L\cos\left(\frac{(m-n)\pi x}{L}\right)\,dx-\frac{1}{2}\int_{-L}^L\cos\left(\frac{(m+n)\pi x}{L}\right)\,dx\\[2.5mm] &=\frac{1}{2}\left[\frac{L}{(m-n)\pi}\sin\left(\frac{(m-n)\pi x}{L}\right)-\frac{L}{(m+n)\pi}\sin\left(\frac{(m+n)\pi x}{L}\right)\right]_{-L}^L =0,\quad m\neq n \end{align*}and for \(m=n\) we use \(\cos(2a)=1-2\sin^2(a)\) to obtain:
\[\int_{-L}^L\left\{\sin\left(\frac{n\pi x}{L}\right)\right\}^2\,dx=\frac{1}{2}\int_{-L}^L\left\{1-\cos\left(\frac{2n\pi x}{L}\right)\right\}\,dx =\frac{1}{2}\left[x-\frac{L}{2n\pi}\sin\left(\frac{2n\pi x}{L}\right)\right]_{-L}^L=L.\]Finally we use \(cos(a)\sin(b)=\frac{1}{2}\left(\sin(a+b)-\sin(a-b)\right)\) to obtain:
\begin{align*} \int_{-L}^L\cos\left(\frac{m\pi x}{L}\right)\sin\left(\frac{n\pi x}{L}\right)\,dx &=\frac{1}{2}\int_{-L}^L\sin\left(\frac{(m+n)\pi x}{L}\right)\,dx-\frac{1}{2}\int_{-L}^L\sin\left(\frac{(m-n)\pi x}{L}\right)\,dx\\[2.5mm] &=\frac{1}{2}\left[-\frac{L}{(m+n)\pi}\cos\left(\frac{(m+n)\pi x}{L}\right)+\frac{L}{(m-n)\pi}\cos\left(\frac{(m-n)\pi x}{L}\right)\right]_{-L}^L =0,\quad m\neq n \end{align*}and
\[\int_{-L}^L\cos\left(\frac{n\pi x}{L}\right)\sin\left(\frac{n\pi x}{L}\right)\,dx=\frac{1}{2}\int_{-L}^L\sin\left(\frac{2n\pi x}{L}\right)\,dx=0.\]Fourier's theorem: If \(f\) and \(f'\) are piecewise continuous on an interval \([-L,L)\) and \(f\) is defined outside that interval so that it is periodic with period \(2L\), then we have:
\[f(x)=\frac{a_0}{2}+\sum_{n=1}^{\infty}\left(a_n\cos\left(\frac{n\pi x}{L}\right)+b_n\sin\left(\frac{n\pi x}{L}\right)\right)\]with \(a_0=\displaystyle\frac{1}{L}\int_{-L}^Lf(x)\,dx\) and
\[a_n=\frac{1}{L}\int_{-L}^Lf(x)\cos\left(\frac{n\pi x}{L}\right)\,dx\quad\text{and}\quad b_n=\frac{1}{L}\int_{-L}^Lf(x)\sin\left(\frac{n\pi x}{L}\right)\,dx.\]These are called the Euler-Fourier formulas. Moreover we have Parseval's relation: \(\displaystyle\frac{1}{L}\int_{-L}^L\left\{f(x)\right\}^2\,dx=\frac{a_0^2}{2}+\sum_{n=1}^{\infty}\left(a_n^2+b_n^2\right)\). After all:
\begin{align*} \frac{1}{L}\int_{-L}^L\left\{f(x)\right\}^2\,dx&=\frac{a_0}{2}\cdot\frac{1}{L}\int_{-L}^Lf(x)\,dx +\sum_{n=1}^{\infty}\left(a_n\cdot\frac{1}{L}\int_{-L}^Lf(x)\cos\left(\frac{n\pi x}{L}\right)\,dx +b_n\cdot\frac{1}{L}\int_{-L}^Lf(x)\sin\left(\frac{n\pi x}{L}\right)\,dx\right)\\[2.5mm] &=\frac{a_0^2}{2}+\sum_{n=1}^{\infty}\left(a_n^2+b_n^2\right). \end{align*}The Fourier series converges in all points \(x\) to \(\displaystyle\frac{f(x-)+f(x+)}{2}\), where \(f(x-)=\lim\limits_{t\uparrow x}f(t)\) and
\(f(x+)=\lim\limits_{t\downarrow x}f(t)\).
In points \(x\), where \(f\) is continuous, we have: \(\lim\limits_{t\uparrow x}f(t)=f(x)=\lim\limits_{t\downarrow x}f(t)\)
and therefore: \(\displaystyle\frac{f(x-)+f(x+)}{2}=f(x)\).
Definition: A function \(f\) is called even if \(f(-x)=f(x)\) for all \(x\) in the domain of \(f\). A function \(f\) is called odd if \(f(-x)=-f(x)\) for all \(x\) in the domain of \(f\). So, such a function should be defined on a symmetric interval around \(0\).
Theorem: If \(f\) is odd, then we have: \(\displaystyle\int_{-L}^Lf(x)\,dx=0\). If \(f\) is even, then we have: \(\displaystyle\int_{-L}^Lf(x)\,dx=2\int_0^Lf(x)\,dx\).
Moreover we have the following rules of calculation:
- If \(f\) is even and \(g\) is even, then \(f\cdot g\) is even;
- If \(f\) is even and \(g\) is odd, then \(f\cdot g\) is odd;
- If \(f\) is odd and \(g\) is odd, then \(f\cdot g\) is even.
Corollary: If \(f\) is even, then we have \(\displaystyle\frac{1}{L}\int_{-L}^Lf(x)\sin\left(\frac{n\pi x}{L}\right)\,dx=0\) and
\(\displaystyle\frac{1}{L}\int_{-L}^Lf(x)\cos\left(\frac{n\pi x}{L}\right)\,dx=\frac{2}{L}\int_0^Lf(x)\cos\left(\frac{n\pi x}{L}\right)\,dx\).
And if \(f\) is odd, then we have \(\displaystyle\frac{1}{L}\int_{-L}^Lf(x)\cos\left(\frac{n\pi x}{L}\right)\,dx=0\) and
\(\displaystyle\frac{1}{L}\int_{-L}^Lf(x)\sin\left(\frac{n\pi x}{L}\right)\,dx=\frac{2}{L}\int_0^Lf(x)\sin\left(\frac{n\pi x}{L}\right)\,dx\).
Fourier cosine series: If \(f\) is an even function on \((-L,L)\) and outside that interval periodic with period \(2L\), then we have:
\[f(x)=\frac{a_0}{2}+\sum_{n=1}^{\infty}a_n\cos\left(\frac{n\pi x}{L}\right)\]with \(a_0=\displaystyle\frac{2}{L}\int_0^Lf(x)\,dx\) and \(a_n=\displaystyle\frac{2}{L}\int_0^Lf(x)\cos\left(\frac{n\pi x}{L}\right)\,dx\) for \(n=1,2,3,\ldots\).
Fourier sine series: If \(f\) is an odd function on \((-L,L)\) and oustide that interval periodic with period \(2L\), then we have:
\[f(x)=\sum_{n=1}^{\infty}b_n\sin\left(\frac{n\pi x}{L}\right)\]with \(b_n=\displaystyle\frac{2}{L}\int_0^Lf(x)\sin\left(\frac{n\pi x}{L}\right)\,dx\) for \(n=1,2,3,\ldots\).
If a function \(f\) is defined on an interval \([0,L]\) with \(L>0\), then this can be defined to be even on the interval \([-L,L]\) and outside that interval periodically with period \(2L\), but it can also be defined to be odd on the interval \([-L,L]\) and outside that interval periodically with period \(2L\). So, such a function can be written as a Fourier cosine series, but also as a Fourier sine series:
\[f(x)=\frac{a_0}{2}+\sum_{n=1}^{\infty}a_n\cos\left(\frac{n\pi x}{L}\right)=\sum_{n=1}^{\infty}b_n\sin\left(\frac{n\pi x}{L}\right)\]with \(a_0=\displaystyle\frac{2}{L}\int_0^Lf(x)\,dx\), \(a_n=\displaystyle\frac{2}{L}\int_0^Lf(x)\cos\left(\frac{n\pi x}{L}\right)\,dx\) and \(b_n=\displaystyle\frac{2}{L}\int_0^Lf(x)\sin\left(\frac{n\pi x}{L}\right)\,dx\) voor \(n=1,2,3,\ldots\).
Last modified on August 23, 2021