3. Fourier transforms#
Like Fourier series, the Fourier transform of a function \(f\) is a way to decompose \(f\) into complex exponentials. This is a very useful tool in quantum mechanics and signal processing, for example.
The difference between Fourier series and Fourier transforms is that while Fourier series are defined for functions on a bounded interval (or equivalently for periodic functions), the Fourier transform can be applied to functions on the whole real line. As a consequence, all complex exponentials
for arbitrary real numbers \(t\) are needed to decompose arbitrary functions \(f\) as above.
3.1. Definition and basic properties#
(Fourier transform)
Let \(f\) be a (real or complex) function on the real line \(\mathbb{R}\). The Fourier transform of \(f\) is the function
Warning
Various other conventions exist for the definition of the Fourier transform, so be careful when combining different sources.
The most important property is that using the Fourier transform \(\hat f\), we can express the original function \(f\) using a very similar formula.
(Fourier inversion formula)
Let \(f\) be a (real or complex) function on the real line \(\mathbb{R}\). Then we can recover \(f\) from its Fourier transform \(\hat f\) via the formula
This means that \(\hat f\) describes the ‘coefficients’ that occur when expressing \(f\) as a ‘linear combination’ of exponential functions, except the expression involves an integral rather than a sum.
(Properties of the Fourier transform)
Here are several other properties of the Fourier transform, for a given function \(f\) with Fourier transform \(\hat f\):
For any real number \(a\), the Fourier transform of \(f(x-a)\) equals \(\exp(-2\pi i ay)\hat f(y)\).
For any real number \(a\ne0\), the Fourier transform of \(f(ax)\) equals \(|a|^{-1}\hat f(y/a)\).
The Fourier transform of \(\frac{df}{dx}\) is \(2\pi iy\hat f(y)\).
The Fourier transform of \(xf(x)\) is \(\frac{1}{2\pi i y}\) times the Fourier transform of \(\frac{df}{dx}\).
(Plancherel’s theorem) We have
\[ \int_{-\infty}^\infty|f(x)|^2 dx= \int_{-\infty}^\infty|\hat f(y)|^2 dy. \]
The first four of these properties are fairly direct consequences of the definition of the Fourier transform. The last property is more difficult to show; see Exercise 3.2.
3.2. Examples#
3.2.1. The Fourier transform of a rectangular function#
Consider the rectangular (or “square pulse”) function
(see Fig. 3.1 below). We compute
Using the formula
we obtain
where the \(\sinc\) function is defined by
Show code cell source
from matplotlib import pyplot as plot
from myst_nb import glue
import numpy as np
fig, ax = plot.subplots(2, 1, figsize=(8,8))
ax[0].plot((-1, -.5, -.5, .5, .5, 1), (0, 0, 1, 1, 0, 0), color='red')
ax[0].set_xlabel('$x$')
ax[0].set_ylabel('$f(x)$')
y = np.linspace(-4, 4, 101)
fhat = np.sinc(y)
ax[1].plot(y, fhat, color='blue')
ax[1].set_xlabel('$y$')
ax[1].set_ylabel('$\\hat f(y)$')
glue("rectangular", fig, display=False)
3.2.2. The Fourier transform of a Gaussian function#
For a fixed \(a>0\), consider the function
(see Fig. 3.2 below). We compute
To finish the computation, we need the contour integration technique from complex analysis. The integral in the above expression can be interpreted as the integral of the function \(\exp(-\pi z^2)\) over the line \(\Im z=-y/a\). Shifting the line of integration to \(\Im z=0\) (the real axis), we get
Finally, we make use of the Gaussian integral
(if you don’t know this, look it up in your favourite reference for integrals) to conclude
Show code cell source
from matplotlib import pyplot as plot
from myst_nb import glue
import numpy as np
fig, ax = plot.subplots(2, 1, figsize=(8,8))
a = 0.5
x = np.linspace(-2, 2, 101)
f = np.exp(-np.pi * a * x**2)
ax[0].plot(x, f, color='red')
ax[0].set_xlabel('$x$')
ax[0].set_ylabel('$f(x)$')
y = np.linspace(-2, 2, 101)
fhat = a**(-1/2) * np.exp(-np.pi / a * y**2)
ax[1].plot(y, fhat, color='blue')
ax[1].set_xlabel('$y$')
ax[1].set_ylabel('$\\hat f(y)$')
glue("gaussian", fig, display=False)
3.3. Fourier transforms and convolutions#
The convolution of two functions is an operation that has applications in many areas, such as physics, engineering and probability. We briefly introduce it here because of an interesting and useful relation between convolutions and the Fourier transform: the Fourier transform converts convolution into (pointwise) multiplication. This is made precise by Theorem 3.2 below.
(Convolution)
Let \(f\) and \(g\) be (real or complex) functions on the real line \(\mathbb{R}\). The convolution of \(f\) and \(g\) is the function \(f * g\) defined by
(Fourier transform and convolution)
Let \(f\) and \(g\) be (real or complex) functions on the real line \(\mathbb{R}\). Then the Fourier transform of the convolution of \(f\) and \(g\) equals the (pointwise) product of the Fourier transforms:
Proof. We compute the Fourier transform of \(f * g\) by interchanging the order of integration and using part 1 of Property 3.1 for the function \(g(y-x)\):
Symmetrically, the Fourier transform converts a pointwise product into a convolution; see Exercise 3.5.
3.4. Exercises#
For a fixed \(a>0\), compute the Fourier transform of the function
Do Problem 2.20 in Griffiths [Gri95], which gives a step-by-step derivation of the Fourier inversion formula (called Plancherel’s theorem in [Gri95]).
Consider the rectangular function \(f\) defined by (3.2). Show that the convolution of \(f\) with itself equals the ‘triangular’ function \(\Lambda\) (sketch the graph!) given by
Use the previous exercise and Theorem 3.2 to compute the Fourier transform of the triangular function \(\Lambda\) defined by (3.5).
Show that if \(f\) and \(g\) are two functions on the real line, then the following analogue of Theorem 3.2 holds:
Hint: use the Fourier inversion formula.