Sine and Cosine Fourier Series

Brown University, Applied Mathematics


Return to computing page
Return to MuPAD tutorial page for the first course
Return to MuPAD tutorial page for the second course
Return to the main page (APMA0340)

Sine and Cosine Fourier Series

Great! We have made it halfway to where we want to be; we what to expand an integrable function into a Fourier series that contains only sines or cosines. This is achieved when the original function, which is assumed to be defined on the finite interval \( (0, \ell ), \) is expanded in even or odd way on the interval \( (-\ell ,0 ). \) Recall that a function f(x) on a symmetric interval \( (-\ell , \ell ), \) is called even iff \( f(-x) = f(x) . \) Correspondingly, a function f(x) is referred to as odd when the following relation holds \( f(-x) = -f(x) \) for any \( x\in (0, \ell ) .\)

Essentially, A function f(x), defined on the the finite interval \( (0, \ell ), \) can be expanded in either sine Fourier series

\[ f(x) \,\sim \, \sum_{n\ge 1} b_n \,\sin \left( \frac{n\pi x}{\ell} \right) \]
or cosine Fourier series
\[ f(x) \,\sim \, \frac{a_0}{2} + \sum_{n\ge 1} a_n \,\cos \left( \frac{n\pi x}{\ell} \right) , \]
where coefficients are determined according to Euler--Fourier formulas:
\begin{align*} b_n = \frac{2}{\ell} \,\int_0^{\ell} f(x) \,\sin \left( \frac{n\pi x}{\ell} \right) {\text d} x , \qquad n=1,2,\ldots ; \\ a_n = \frac{2}{\ell} \,\int_0^{\ell} f(x) \,\cos \left( \frac{n\pi x}{\ell} \right) {\text d} x , \qquad n=0,1,2,\ldots . \end{align*}

Gibbs Phenomenon

Sine and cosine Fourier series suffers the same Gibbs phenomenon as regular Fourier series: its partial sums overshoot and undershoot the actual value of discontinuity by about 9% independently of the number of terms in the finite sums. When the number of terms in the partial sum incleases, the overshoot and undershoot approaches the numerical value that is determined as follows.

Let \( F_N (x) \) be the finite Fourier sum with N+1 terms:

\[ F_N (x) = \frac{a_0}{2} + \sum_{k=1}^N \left( a_k \cos \frac{k\pi x}{\ell} + b_k \sin \frac{k\pi x}{\ell} \right) \]
If a function f(x) has a discontinuity at the point \( x_0 \) of amount \( f(x_0 +0) - f(x_0 -0) \) then finite Fourier sums experience overshoot and undershoot in a neighborhood of this point. These undershoots or overshoots cannot be eliminated by increasing the the number of terms in the finite Fourier sum and they approach with \( N\mapsto \infty \) the value
\[ 1.1789797444721675\ldots \left\vert f(x_0 +0) - f(x_0 -0) \right\vert . \]
Such behavior of Fourier series is usually referred to as the Gibbs phenomenon, which was first noticed and analyzed by the English mathematician Henry Wilbraham (1825--1883) in 1848. The term "Gibbs phenomenon" was introduced by the American mathematician Maxime Bocher in 1906. The 'magic' number is the approximation of
\[ \frac{2}{\pi} \,\mbox{Si} (\pi ) \approx 1.1789797444721675\ldots \qquad\mbox{where } \mbox{Si} (x) = \int_0^x \frac{\sin t}{t} \,{\text d}t \]
is sine integral (special function), which is build-in MuPad as Si(x).

Solving Using Partial Fraction Decomposition

1. First you will split your fraction into a sum of simple fractions by using Partial Fraction Decomposition.
2. Next you will look up the Inverse Laplace for a given function of lambda in a table provided to write the answer (if you are working by hand).

Example 1:


Example 2:


Example 3:


Example 4:

Working In MuPAD

The syntax is exactly the same, only this time, we will be ussing "ilaplace" instead of "laplace".

ilaplace::addpattern(pat, s, t, res)

ilaplace(1/`λ`^5,`λ`,t)

t^4/24

ilaplace(1/(`λ`^2+1),`λ`,t)

sin(t)

Home

< Previous

Next >