Lecture 1

1. Periodic functions

In the first part of the course we study Fourier series. The Fourier series is a tool to study periodic functions by writing it as an infinite sum of trignomic functions.

Definition 1.1. A function on R\mathbb{R} is called periodic provided f(x+T)=f(x)f(x+T) = f(x) for some T>0T>0. We usually tacitly assume TT to be the smallest positive period of ff.

We identify the following three things:

(a) A periodic function on R\mathbb{R} with period 2π2\pi.

(b) A function ff on [0,2π][0,2\pi] with f(0)=f(2π)f(0) = f(2\pi).

(c) A function defined on the unit circle S1:={(x,y)R2:x2+y2=1}S^1:=\{(x,y)\in \mathbb{R}^2:x^2+y^2 = 1\}.

(d) The quotient space T:=R/Z\mathbb{T}:=\mathbb{R}/\mathbb{Z}. When we say xTx\in \mathbb{T} we mean x[0,1]x\in [0,1] with 0 and 1 taken as the same point.

From the data given by (a), i.e. a periodic function ff with period 2π2\pi, we can restrict the function to [0,2π][0,2\pi] or any interval of length 2π2\pi, like [π,π][-\pi,\pi] to get data (b). Conversely, if we have a function defined on [0,T][0,T] satisfying f(0)=f(T)f(0) = f(T), then we can construct a periodic function on R\mathbb{R} by its periodization fT(x)=kZf(xkT)f_T(x) = \sum_{k\in \mathbb{Z}}f(x-kT) (with modificatilunon at integral multiples of TT).

The unit circle can be parametrized on [0,2π][0,2\pi] by θeiθ\theta \mapsto e^{i\theta}. Let FF be a function on the circle S1S^1, then f(θ):=F(eiθ)f(\theta):=F(e^{i\theta}) is a periodic function of period 2π2\pi. Similarly, we can also identify FF with g(x)=F(e2πix)g(x) = F(e^{2\pi i x}), then g(x)g(x) is a periodic function with period 1. By definition, FF is continuous, differentiable, or integrable... if and only if ff the corresponding parametrization ff is continuous, differentiable, or integrable.

Let ff be a periodic function with period TT, then f(Tx)f(Tx) is a periodic function with period 1 and f(2πT)f(2\pi T) is period 2π2\pi, hence we can restrict our study on period 1 or period 2π2\pi case (use whichever is more convenient). Note that the integral of function on its period is not invarient under scaling: 01f(Tx)dx=0Tf(x)d(xT)=1T0Tf(x)dx\int_{0}^1f(Tx)dx = \int_{0}^Tf(x')d(\frac{x'}{T}) = \frac{1}{T}\int_{0}^Tf(x')dx', i.e. shrinking period by TT also shrinks integral by TT.

Trignomic functions and trignomic polynomials

A real trignomic polynomial is a function of the form f(t)=k=1n(akcos(kt)+bksin(kt))+a02f(t) = \sum_{k = 1}^n (a_k \cos(kt) + b_k\sin(kt))+\frac{a_0}{2}. In most theoretical calculations it will be easier to use the complex exponentials instead of sines and cosines, thanks to the identity eiθ=cosθ+isinθe^{i\theta} = \cos \theta + i \sin \theta. Then cost=eit+eit2,sint=eiteit2i\cos t = \frac{e^{it}+e^{-it} }{2}, \sin t = \frac{e^{it} - e^{-it} }{2i}, and

f(t)=k=1nakeit+eit2+k=1nbkeiteit2i+a02f(t) = \sum_{k=1}^n a_k \frac{e^{it}+e^{-it} }{2} + \sum_{k=1}^n b_k \frac{e^{-it} - e^{-it} }{2i} + \frac{a_0}{2}

=k=1neiktakibk2+k=1neiktak+ibk2+a02= \sum_{k=1}^n e^{ikt}\frac{a_k-ib_k}{2} + \sum_{k=1}^n e^{-ikt} \frac{a_k+ib_k}{2} + \frac{a_0}{2}.

Let ck=akibk2c_k = \frac{a_k-ib_k}{2}, in particular c0=a0+02c_0 = \frac{a_0+0}{2}, we have f(t)=k=nnckeiktf(t) = \sum_{k=-n}^n c_ke^{ikt} with ck=ckc_{-k}=\overline{c_k}. Note that this is because our f(t)f(t) is real at the beginning.

Example 1.1. DN:=n=NNeintD_N:=\sum_{n=-N}^{N}e^{int} is a trignomic polynomial and DN=sin((N+12)t)sin(12t)D_N = \frac{\sin((N+\frac{1}{2})t)}{\sin(\frac{1}{2}t)}.

Proof. Let ω=eit\omega = e^{it},then DN=n=NNωn=n=0Nωn+n=N1ωnD_N = \sum_{n=-N}^N\omega^n = \sum_{n=0}^N \omega^n + \sum_{n=-N}^{-1}\omega^{n}. The first term = 1ωN+11ω\frac{1-\omega^{N+1}}{1-\omega}, the second term = 1ω(11ωN)11ω=ωN11ω\frac{\frac{1}{\omega}(1-\frac{1}{\omega^N})}{1-\frac{1}{\omega}} = \frac{\omega^{-N}-1}{1-\omega}.

Then sum up we get DN=ωNωN+11ω=ω(N+1/2)ωN+1/2ω1/2ω1/2=2isin((N+12)x)2isin(12x)D_N = \frac{\omega^{-N}-\omega^{N+1}}{1-\omega} = \frac{\omega^{-(N+1/2)}-\omega^{N+1/2}}{\omega^{-1/2} -\omega^{1/2}} = \frac{2i \sin((N+\frac{1}{2})x)}{2i \sin(\frac{1}{2}x)}.

This DND_N is called the Dirichlet kernel and we’ll come back later to study it in detail.

Question: Suppose I tell you that a function f(t)f(t), for example, sin((N+12)t)sin(12t)\frac{\sin((N+\frac{1}{2})t)}{\sin(\frac{1}{2}t)}, is a trignomic polynomial, how do you know its coefficients?

To answer this question we need the following fundamental property of complex exponentials.

Lemma 1.1

02πeinteimt={0nm2πn=m \int_{0}^{2\pi}e^{ int} e^{- imt} = \begin{cases}0 & n\neq m\\2\pi & n=m\end{cases}

The vector space of trignomic polynomials

Here is a geometric explanation of the above proposition. Let VV be a vector space with inner product (,)(,), let e1,,eme_1,\dots,e_m be an orthonormal basis of VV. Then every vector x\mathbf{x} in VV can be written as a1e1++anena_1e_1+\cdots+a_ne_n for scalers a1,,ana_1,\dots,a_n, and we can calculate aka_k by ak=(v,ek)a_k = (v,e_k). In fact, we have (v,ek)=(a1e1++anen,ek)=0+ak(ek,ek)=ak(v,e_k) =(a_1e_1+\cdots+a_ne_n, e_k) = 0+a_k(e_k,e_k) = a_k.

Now let VNV_N be trignomic polynomials of degree NN, i.e, VNV_N consists of functions of the form n=NNcneint,cnC\sum_{n=-N}^N c_n e^{int}, c_n\in \mathbb{C}. Then VNV_N is a complex vector space. Define inner product (,)(,) on VNV_N by (f,g)12π02πf(t)g(t)dt(f,g)\mapsto \frac{1}{2\pi}\int_{0}^{2\pi}f(t)\overline{g(t)} dt, then (eikt)k=NN(e^{ikt})_{k=-N}^N is an orthonormal basis of VNV_N. So we have cn=(f,en)=12π02πf(t)eintdt=12π02πf(t)eintdtc_n = (f,e_n) = \frac{1}{2\pi}\int_{0}^{2\pi}f(t)\overline{e^{i n t}} dt = \frac{1}{2\pi}\int_{0}^{2\pi}f(t)e^{-int}dt and f=n=NNcneintf = \sum_{n=-N}^N c_n e^{int}.

In the period 1 case the inner product is 01f(x)g(x)dx\int_0^1 f(x)\overline{g(x)}dx and (e2πinx)n=NN(e^{2\pi i n x})_{n=-N}^N is orthonormal basis.

2. Fourier series

Can we write any period function, say, with period 2π2\pi, as a sum of complex exponentials? One can soon realize that finite sum will usually not be possible because a trignomic polynomial is always smooth, on the other hand, of course not all periodic functions are smooth. So we cannot avoid infinite sums.

Definition 2.1. Let ff be an integrable function on [0,T][0,T].

  • The n-th Fourier coefficient of ff is given by cn=1T0Tf(t)e(2π/T)intdtc_n = \frac{1}{T}\int_{0}^{T}f(t)e^{-(2\pi/T) int}dt. Sometimes we also use f^(n)\hat{f}(n) to denote cnc_n.
  • SN(f):=n=NNcne(2π/T)intS_N(f):=\sum_{n=-N}^N c_ne^{(2\pi/T)int} is the NN-th Fourier partial sum of ff.
  • The series S(f):=n=+cne(2π/T)int=limNSN(f)S(f):=\sum_{n=-\infty}^{+\infty}c_ne^{(2\pi/T)int}=\lim_{N\to \infty}S_N(f) is called the Fourier series of ff.

The first question is convergence of Fourier series, when and in which sense can we write f(x)=n=+cneinxf(x) = \sum_{n=-\infty}^{+\infty}c_ne^{inx}?

Note. In order for the integrals to make sense we need some integrability assumption on ff. Now you can understand the notion “integrable” as “Riemann integrable”. Later, we’ll introduce a more general notion of Lebesgue integrals, most of the results holds for Lebesgue integrable functions.

The convergence of Fourier series turns out to be delicate.

  • If the function is continuously differentiable (i.e. first derivative is continuous), then the Fourier series converges uniformly.
  • There exists a continuous function whose Fourier series diverge at some point.
  • In the general case, need to consider more general sense of convergence.

Example 2.1 f(θ)=θf(\theta) = \theta on [π,π][-\pi,\pi]. Then the Fourier series of ff is given by

cn=12πππθeinθdθ=12πππθd(einθin)=12π(θeinθππππeinθindθ)=(1)n+1inc_n = \frac{1}{2\pi} \int_{-\pi}^\pi \theta e^{-in\theta}d\theta = \frac{1}{2\pi}\int_{-\pi}^\pi\theta d(\frac{e^{-in\theta}}{-in})=\frac{1}{2\pi}(\theta e^{-in\theta}|_{-\pi}^\pi - \int_{-\pi}^\pi \frac{e^{-in\theta}}{-in}d\theta) = \frac{(-1)^{n+1}}{in}

when n0n\neq 0 and c0=0c_0 = 0. So S(f)=n=+(1)n+1ineinθ=2n=1+(1)n+1sinnθnS(f) = \sum_{n = -\infty}^{+\infty}\frac{(-1)^{n+1}}{in}e^{in\theta} = 2\sum_{n = 1}^{+\infty}(-1)^{n+1}\frac{\sin n\theta}{n}.

We can use the following Sagemath code to visualize the Fourier partial sums, you can change NN and see how it goes. This approach is to directly plot the Fourier partial sum based on our hand calculation.

x = var('x') # Define symbolic variable x
n = var('n') # Define symbolic variable n
N = 20
a(n) = 2*(-1)^(n+1)*(1/n)
Sf=sum(a(n)*sin(n*x),n,1,N) # The Fourier partial sum of f 
plot(Sf,x,-pi,pi)

Example 2.2 f(x)1f(x) \equiv 1 on [1/2,1/2][-1/2,1/2], find the Fourier series of ff on [T/2,T/2][-T/2,T/2].

cn=1TT2T21e(2π/T)inxdx=12πin(enπTienπTi)=sin(nπT)nπc_n = \frac{1}{T}\int_{-\frac{T}{2}}^{\frac{T}{2}}1\cdot e^{-(2\pi/T)inx}dx = -\frac{1}{2\pi in}(e^{-\frac{n\pi}{T}i}-e^{-\frac{n\pi}{T}i}) = \frac{\sin(\frac{n\pi}{T})}{n\pi} for n0n\neq 0 and c0=1Tc_0 = \frac{1}{T}.

In the case T=2πT = 2\pi, the Fourier series is n=+sin(n/2)nπeinx=12π+n=1n2sin(n/2)nπcos(nx)\sum_{n=-\infty}^{+\infty}\frac{\sin(n/2)}{n\pi}e^{inx} = \frac{1}{2\pi}+\sum_{n=1}^n \frac{2\sin(n/2)}{n\pi}\cos(nx).

Actually Sagemath has a built in method to calculate the Fourier series for us, as shown in the following code:

x = var('x') # Declare variable x
f = piecewise([[(-pi,-1/2),0],[(-1/2,1/2),1],[(1/2,pi),0] ] ) # Define f as a piecewise function
FS5=f.fourier_series_partial_sum(5,pi) # For a piecewise function, there is a method called "fourier_series_partial_sum", we calculate 5 terms
print(FS5) # print the result
P1 = f.plot() # plot the graph of f
P2 = plot(FS5,x,-pi,pi,linestyle="--") # plot the graph of fourier partial sum
(P1+P2).show(title="5 terms") # print the graph
FS100=f.fourier_series_partial_sum(50,pi)
P3 = plot(FS100,x,-pi,pi).show(title="100 terms") # What happens if we calculate 100 terms?

From the picture we can see that even though we approximate ff hard enough, the approximation seems to be OK for points far from the jump. But near the jump we there is still big error remaining. This is called the Gibbs phenomenon.

3. Pointwise convergence (simple case)

First observation as a consequence of Weierstrass MM-test:

If n=+cn<\sum_{n=-\infty}^{+\infty }|c_n|<\infty, then S(f)S(f) converges uniformly.

In this case we call the Fourier series of ff converge absolutely. For a postive series, it converges when the coefficients decays sufficiently fast, and from calculus we know that O(1n)O(\frac{1}{n}) is not enough and O(1n2)O(\frac{1}{n^2}) is enough. In fact, we can show using Fourier series of the quadratic function that n=1+1n2=π26\sum_{n=1}^{+\infty}\frac{1}{n^2} = \frac{\pi^2}{6} (in exercise).

Proposition 3.1 (The derivative theorem) Let ff be continuously differentiable on T\mathbb{T} (this means ff is continuously differentiable on [0,1][0,1] with f(0)=f(1)f(0) = f(1)), then f^(n)=2πinf^(n)\widehat{{f'}}(n) = 2\pi in\hat{f}(n).

Proof. This is just integration by part. f^(n)=01f(x)e2πinxdx=01e2πinxdf=f(x)e2πinx0101f(x)(2πin)e2πinxdx=2πin01f(x)e2πinxdx=2πinf^(n)\widehat{f'}( n) = \int_{0}^{1}f'(x)e^{-2\pi i n x}dx = \int_{0}^1e^{-2\pi in x}df = f(x)e^{-2\pi i n x}|_{0}^1 - \int_{0}^1 f(x)(-2\pi i n)e^{-2\pi i n x} dx = 2\pi i n \int_{0}^1 f(x)e^{-2\pi i nx }dx = 2\pi i n \hat{f}(n).

Remark. In the period TT case f^(n)=2πTinf^(n)\widehat{f}(n) = \frac{2\pi}{T} i n\hat{f}(n).

We call a function on S1S^1 integrable if 02πf(x)dx<\int_{0}^{2\pi}|f(x)|dx<\infty. We use L1(S1)L^1(S^1) to denote integrable functions on S1S^1. For fL1(S1)f\in L^1(S^1), the quantity 02πf(x)dx\int_{0}^{2\pi}|f(x)|dx is called the L1L^1-norm of ff. We have the following handy uniform bound by the L1L^1-norm for the Fourier coefficients:

Lemma. f^(n)01f(x)dx|\hat{f}(n)|\leq \int_{0}^1|f(x)|dx. If we denote 01f(x)dx\int_{0}^1|f(x)|dx by fL1\|f\|_{L^1} then f^(n)fL1|\widehat{f}(n)|\leq \|f\|_{L^1}.

Proof. f^(n)=01f(x)e2πinxdx01f(x)dx|\hat{f}(n)| = |\int_{0}^1f(x)e^{-2\pi i n x}dx|\leq \int_{0}^1|f(x)|dx.

Corollary. If ff has continuous second derivative then f^(n)=O(1n2)\widehat{f}(n) =O(\frac{1}{n^2}), hence the Fourier series of ff converges uniformly.

Proof. Apply the derivative theorem twice we get f^(n)=4π2n2f^(n)\widehat{f''}(n) = -4\pi^2n^2\hat{f}(n). By the L1L^1 estimate we have f^(n)01f(x)dx=fL1|\hat{f''}(n)| \leq \int_{0}^1|f''(x)|dx = \|f''\|_{L^1}. So f^(n)14πf1n2=constant1n2|\hat{f}(n)|\leq \frac{1}{4\pi}\|f''\| \cdot \frac{1}{n^2} = \text{constant}\cdot \frac{1}{n^2}.

Next we consider the continuous case.

Proposition 3.2. Let ff be an integrable function on the circle. If f^(n)=0\hat{f}(n) = 0 for all nZn\in\mathbb{Z}, then f(x)f(x) vanishes at continuous points, i.e. for every x[0,2π]x\in[0,2\pi] such that ff is continuous at xx, f(x)=0f(x) = 0.

Note. The Fourier coefficients vanishes means ff is orthogonal to all trignomic polynomials.

Proof.

Method 1. Assume f(x0)0f(x_0)\neq 0 for some continuous point x0x_0. We can moreover assome f(x0)>0f(x_0)>0, then since ff is continuous at x0x_0, it must be ϵ\geq \epsilon near x0x_0. Then the idea is to construct a sequence of trignomial polynomials pkp_k such that pkp_k goes to ++\infty near x0x_0 and the negative part of pkp_k is controlled, so that 02πf(t)pk(t)dt\int_{0}^{2\pi}f(t)p_k(t)dt \to \infty, which contradicts to the assumption that ff is orthogonal to pkp_k. Precisely, fix ϵ>0\epsilon > 0 and choose small δ>0\delta > 0 such that f(x)ϵf(x)\geq \epsilon on (x0δ,x0+δ)(x_0-\delta,x_0+\delta). Let p(x)=cos(xx0)+αp(x)=\cos(x-x_0)+\alpha for small α>0\alpha > 0. Let pk(x)=p(x)kp_k(x) = p(x)^k. We choose α so small that p(x)<1|p(x)|<1 so pk(x)0p_k(x)\to 0 when x(x0δ,x0+δ)x\notin (x_0-\delta,x_0+\delta). Then 0=02πf(x)pk(x)dx=x0δx0+δf(x)pk(x)dx+x(x0δ,x0+δ)f(x)pk(x)dx0=\int_{0}^{2\pi}f(x)p_k(x)dx = \int_{x_0-\delta}^{x_0+\delta}f(x)p_k(x)dx + \int_{x\notin(x_0-\delta,x_0+\delta)}f(x)p_k(x)dx. The first term go to ++\infty when kk\to \infty, the second term go to 0 when kk\to \infty, contradiction.

Note: the second limit is a consequence of the dominated convergence theorem. We want to have limkx(x0δ,x0+δ)f(x)pk(x)dx=x(x0δ,x0+δ)limkf(x)pk(x)dx=x(x0δ,x0+δ)f(x)0dx=0\lim_{k\to \infty}\int_{x\notin(x_0 - \delta,x_0 + \delta)}f(x)p_k(x)dx = \int_{x \notin (x_0-\delta,x_0+\delta)}\lim_{k\to \infty}f(x)p_k(x)dx = \int_{x\notin (x_0-\delta,x_0+\delta)}f(x)\cdot 0 dx = 0. To change the limit and integral we need the condition that f(x)pk(x)some L1 function|f(x)p_k(x)|\leq \text{some } L^1 \text{ function} on (x0δ,x0+δ)(x_0-\delta,x_0+\delta). Since pk(x)2|p_k(x)|\leq 2 and f(x)L1(S1)f(x)\in L^1(S^1), we can take 2f2|f|.

If you want a more elementary proof see the book Theorem 2.1.

The second method involves Lemma 5.1 and Theorem 5.2 in Chapter 2 of Stein-Shakarchi, that we’ll do later.

Method 2. Let FN(x)=1Nsin2(Nx/2)sin2(x/2)F_N(x)=\frac{1}{N}\frac{\sin^2(Nx/2)}{\sin^2(x/2)} which is a trignomic polynomial called Fejer kernel. Assume ff is continuous at 0, the Fejer theorem (later) implies 12π02πf(x)FN(x)dxf(0)\frac{1}{2\pi}\int_{0}^{2\pi}f(x)F_N(x)dx\to f(0) when NN\to \infty. Since ff is orthogonal to trignomic polynomials, this shows f(0)=0f(0)=0. If x00x_0\neq 0, let g(x)=f(x+x0)g(x) = f(x+x_0), apply the result to g(x)g(x) shows g(0)=0=f(x0)g(0) = 0 = f(x_0).

Corollary. Let ff be an integrable function on the circle such that the Fourier series of ff converges absolutely. If ff is continuous at x0x_0, then the Fourier series of ff converges to ff at x0x_0, i.e. limNSN(f)(x0)=f(x0)\lim_{N\to \infty}S_N(f)(x_0) = f(x_0).

Proof. Since the Fourier series of ff converges absolutely which implies S(f)S(f) converges uniformly, hence S(f)S(f) is a continuous function. Note that the Fourier coefficients of S(f)S(f) is precisely f^(n)\hat{f}(n), so S(f)S(f) and ff has same Fourier coefficients. Then S(f)S(f) and ff coincide on continuous points by Proposition 3.2.

Appendix: Plot of Direchlet kernel and Fejer kernel

N=20
x=var('x')
DN=sin((N+1/2)*x)/sin(1/2*x)
FN=(1/N)*sin(N*x/2)^2/(sin(x/2)^2)
P1=plot(DN)
P1.show(title="Direchlet kernel")
P2=plot(FN)
P2.show(title="Fejer kernel")

We can also plot an approximate process for different values, for example the Fejer kernel

for N in [20,40,60,80]:
    FN=(1/N)*sin(N*x/2)^2/(sin(x/2)^2)
    P2=P2+plot(FN)
P2.show()