Return to computing page for the first course APMA0330
Return to computing page for the second course APMA0340
Return to computing page for the fourth course APMA0360
Return to Mathematica tutorial for the first course APMA0330
Return to Mathematica tutorial for the second course APMA0340
Return to Mathematica tutorial for the fourth course APMA0360
Return to the main page for the first course APMA0330
Return to the main page for the second course APMA0340
Return to the main page for the fourth course APMA0360
Return to Part V of the course APMA0340
Introduction to Linear Algebra with Mathematica
Not every Fourier series can be term-by-term differentiated, but those that correspond to functions having derivatives expanded into Fourier series. Term-by-term differentiation is not justified for functions having an unbounded jump discontinuity. In mathematics, there is a special class of functions, called absolute continuous that have derivatives almost everywhere.
Suppose that a periodic function f(x) is an integral, i.e., f(x) is absolutely continuous. Integrating by parts gives
so that \( \hat{f'}(n) = {\bf j}n\,\hat{f}(n) , \) where \( \hat{f'}(n) \) is the Fourier coefficient of the derivative of f(x). Since f(x) is periodic, \( \hat{f'}(0) = 0. \) Similar for trigonometric series \eqref{EqFourier.3}, we have
This is precisely what would be obtained by differentiating the Fourier series of f(x) term by term. Hence, even though the Fourier series S[f'] of f'(x) may not converge uniformly or even converge at all, it can still be obtained by differentiating the Fourier series S[f] of f(x) term by term.
Theorem 1:
Let π(π₯) be a continuous function defined on [β Ο, Ο] with an
absolutely integrable derivative (which may not exist at certain points). Then its derivative
\[
f' (x ) \,\sim\, \frac{c}{2} + \frac{\pi}{\ell}\,\sum_{n\ge 1} \left[ \left( n\,b_n + (-1)^n c\,\ell /\pi \right) \cos \left( \frac{n\pi x}{\ell} \right) - n\,a_n \,\sin \left( \frac{n\pi x}{\ell} \right) \right] ,
\]
where πₙ and bₙ are the Fourier coefficients of π(π₯) and \( \displaystyle \quad c = \frac{1}{\pi} \left[ f(\pi ) - f(-\pi ) \right] . \)
Let the Fourier series for the derivative of π(π₯) be
\[
f' (x) = \frac{1}{2}\,\alpha_0 + \sum_{n\ge 1} \left[ \alpha_n \cos \left( \frac{n\pi x}{\ell} \right) + \beta_n \sin \left( \frac{n\pi x}{\ell} \right) \right] ,
\]
where
\[
\alpha_0 = \frac{1}{\ell} \int_{-\ell}^{\ell} \,f'(x)\,{\text d} x = \frac{1}{\ell} \left[ f(\ell ) - f(-\ell ) \right] = c .
\]
According to section on integration of Fourier series, the integral \( \displaystyle \quad F(x) = \int_0^x \left[ f' (x) - \frac{1}{2}\,\alpha_0 \right] {\text d}x \quad \) can be obtained from the term-by-term integration of the corresponding Fourier series:
\begin{align*}
F(x) &= \int_0^x \left[ f' (x) - \frac{1}{2}\,\alpha_0 \right] {\text d}x = f(x) - f(0) - \frac{x}{2}\,\alpha_0
\\
&= \int_0^x \left[ \sum_{n\ge 1} \left[ \alpha_n \cos \left( \frac{n\pi x}{\ell} \right) + \beta_n \sin \left( \frac{n\pi x}{\ell} \right) \right] \right] {\text d}x
\\
&= \frac{\ell}{\pi}\, \sum_{n\ge 1} \left[ \alpha_n \frac{1}{n}\,\sin \left( \frac{n\pi x}{\ell} \right) -\beta_n \frac{1}{n} \left[ \cos \left( \frac{n\pi x}{\ell} \right) - 1 \right] \right] .
\end{align*}
Substituting instead of π(π₯) its Fourier series, we obtain
\begin{align*}
F(x) &= \frac{1}{2}\,a_0 + \sum_{n\ge 1} \left[ a_n \cos \left( \frac{n\pi x}{\ell} \right) + b_n \sin \left( \frac{n\pi x}{\ell} \right) \right] - f(0) - \frac{x}{2}\,\alpha_0
\\
&= \frac{1}{2}\,a_0 + \sum_{n\ge 1} \left[ a_n \cos \left( \frac{n\pi x}{\ell} \right) + b_n \sin \left( \frac{n\pi x}{\ell} \right) \right] - \frac{1}{2}\,a_0 - \sum_{n\ge 1} a_n - \frac{x}{2}\,\alpha_0
\\
&= \frac{\ell}{\pi}\, \sum_{n\ge 1} \left[ \alpha_n \frac{1}{n}\,\sin \left( \frac{n\pi x}{\ell} \right) -\beta_n \frac{1}{n} \left[ \cos \left( \frac{n\pi x}{\ell} \right) - 1 \right] \right] .
\end{align*}
Expanding π₯ into Fourier series yields
2*Integrate[x*Sin[n*Pi*x/L], {x, 0, L}]/L
(2 L (-n \[Pi] Cos[n \[Pi]] + Sin[n \[Pi]]))/(n^2 \[Pi]^2)
Tis theorem tells us that given a function π(π₯) on [βℓ, ℓ], the Fourier series of its derivative cannot be generally obtained from the term-by-term differentiation of the Fourier series for π(π₯). However, if π(−ℓ) = π(ℓ) or c = 0, then we can differentiate the Fourier series term-by-term.
According to the Riemann--Lebesgue lemma, the Fourier coefficients of a differentiable function satisfy
\[
\lim_{n\to\infty} \, a_n n = \lim_{n\to\infty} \, b_n n = 0.
\]
In other words, for a periodic function with an absolutely integrable derivative, its Fourier coefficients vanish faster than 1/π as π β β.
Theorem 13:
Let π(π₯) be a continuous periodic function, which has π
derivatives, where πβ1 derivatives are continuous of the same period and the π-th derivative is absolutely integrable (the π-th derivative may not exist at certain points).
Then the Fourier series of all π derivatives can be obtained by term-by-term
differentiations of the Fourier series of π(π₯), \( \ S^{(k)}[f] = S[f^{(k)}] , \quad k = 1, 2, \ldots m, \) where π[π] is the Fourier series for function π(π₯). Moreover, all the series, except possibly
the last, converge uniformly to the corresponding derivatives and the
Fourier coefficients of the function π(π₯) satisfy the relations
The proof of this theorem is straightforward; it simply involves applying
integration by parts successively to all the Fourier series for the derivatives of up to the (π β 1)-th order, and recognizing the fact that in the process all the involved derivatives are
absolutely integrable and their corresponding series can be directly obtained from
term-by-term differentiations.
This Teorem is very useful in that it reveals the intrinsic connection between
the smoothness of a periodic function and the convergence characteristic of its
Fourier series expansion. In an ideal case, the Fourier series of a periodic analytic
function can actually converge at an exponential rate (Tadmor 1986).
However, it must be emphasized that the periodicity is a prerequisite for this
convergence theorem to hold. Once the periodicity condition is not met by a func-
tion, the convergence of its Fourier series can be seriously deteriorated, even
when the function is defined sufficiently smooth on the interval.
The following example illustrates this point.
Example 19:
Let us consider a function f(x) = x on the interval [0, ℓ]. Its Fourier series is
You will learn later in the even and odd section how to construct this series and determine the coefficients, but now you have to trust me or plot partial sums to verify the identity.
If we differentiate the function on the left-hand
side, then we get the function 1. However, if we formally differentiate term by term the
function on the right, then we arrive at
The series at the left does not converge because its general term does not tern to zero. However, we will see later that if we use another definition of convergence, called CesΓ ro summation, the right-hand side series converges to 1. If we formally apply geometric series formula (see Example 2 in CesΓ ro summation section)
Fourier sine series of the derivative f'(x) = 1
can be obtained by term-by-term differentiation of the Fourier cosine series of f(x) = x.
Assuming that term-by-term differentiation is valid as claimed, it follows that
Theorem 14:
Suppose that f(x) has discontinuities of the first kind (finite jumps) at the points 0 < x1 < x2 < ··· < xm < 2π, and that f(x) is absolutely continuous in each of the subintervals (xi, xi+1), if completed by continuoity at the end points xi, xi+1. Let
\[
\Phi (x) = d_1 \phi \left( x - x_1 \right) + d_2 \phi \left( x - x_2 \right) + \cdots + d_m \phi \left( x - x_m \right)
\]
has the same points of discontinuity and the same jumps, as f(x). The difference g(x) = f(x) − Φ(x) is therefore continuous, indeed, absolutely continuous. Moreover,
Gonzalez-Velasco, E.A., Fourier Analysis and Boundary Value Problems, 1996, Academic Press, San Diego, CA.
Hardy, G.H. and Rogosinski W.W., Fourier series, Dover Publications, 2013.
Iserles, A., and S. P. NΓΈrsett. 2008. From high oscillation to rapid approximation I:
Modified Fourier expansions. IMA Journal of Numerical Analysis 28: 862β887.
Tadmor, E. 1986. The exponential accuracy of Fourier and Chebyshev differencing methods.
SIAM Journal on Numerical Analysis 23: 1--10.
Return to Mathematica page
Return to the main page (APMA0340)
Return to the Part 1 Matrix Algebra
Return to the Part 2 Linear Systems of Ordinary Differential Equations
Return to the Part 3 Non-linear Systems of Ordinary Differential Equations
Return to the Part 4 Numerical Methods
Return to the Part 5 Fourier Series
Return to the Part 6 Partial Differential Equations
Return to the Part 7 Special Functions