Alexiades - M371 - PS 12
M371 - Alexiades
Problem Set 11: Fourier Analysis
A bit of signal processing:
Read about
JPEG image format on wikipedia
Fourier expansions:
Consider a square pulse on [-π,π] (see Note at the end):
f(x) = 1 for |x|≤1 , = 0 for 1<|x|≤ π
It is an even function on [-π,π], so its Fourier expansion is a
Fourier cosine series: F(x) = a0/2 + ∑ancos(nx) (sum from n=1 to ∞)
with Fourier coefficients: an = 1/π -π∫π f(x)cosnx dx , n=0,1,2,...
(the Fourier sine coefficients are zero since f(x)sin(nx) is odd function).
Note that a0/2 is the average of f(x) over [−π,π] (called the DC coefficient).
According to the theory of Fourier expansions:
Since f∈L2(-π,π), the series converges to it in L2-sense, so F=f in L2-sense.
Since f and f′ are piecewise continuous on [-π,π], the series also converges
pointwise to the 2π-periodic extension of f(x) ∀x∈(-∞,∞) and F(x)=(f(x-)+f(x+))/2.
Thus, F(x)=f(x) when f(x) is continuous at x, and F(x)=average of values when
f(x) has a jump at x. The F.S. simply does the best it can!
1. Sketch the graph of f(x) and its 2π-periodic extension F(x).
To what value will the F.S. converge at x=0 ? at x=1 ? at x=2π-1 ?
2. Find the Fourier coefficients an explicitly (evaluate integral by hand), for any n=0,1,2,...
3. To see how the Fourier Series approximates the function as the number of terms increases,
write a code that evaluates FN(x) = N-th partial sum of the Fourier series (sum from 0 to N),
and plot f(x) and FN(x) on [-π,π] on the same plot
Compute the 2-norm of f-FN .
Debug with N=4 terms using M=10, 50, 100 evaluation points.
4. Try N=10, 50, 100, 200. Must use many evaluation points x for plotting,
at least 800 for high N, to capture the oscillations.
How well does FN(x) approximate f(x) as N increases ?
Is the error decreasing at all x ? what happens at the jumps?
The overshoot/undershoot at jumps are for real, this is the
famous Gibbs Phenomenon!
(google it to learn more... Wikipedia has an excellent article on it).
Note: The choice [-π,π] is for convenience, it simplifies expressions.
On an interval [-L,L], the basis functions would be cos(nπx/L) and
an = 1/L -L∫L f(x)cos(nπx/L) dx , n=0,1,2,...