A14 · Lesson 40 · L² and the convergence of Fourier series
In what sense a square wave equals the sum of its harmonics
A square wave is a sum of odd harmonics, and every engineer has seen the partial sums ring at the edges. In what sense does the series "equal" the square wave? Not uniformly: the ringing peak never shrinks below about 9% of the jump, however many terms you add (the Gibbs phenomenon). Not exactly at the jump either, where the series gives the midpoint. But in energy it converges perfectly: the energy of the error goes to zero. That's convergence in , the inner-product space of finite-energy signals, and it's the sense in which Fourier analysis is exact. Parseval's identity, which splits a signal's power among its harmonics, is its most useful consequence.
- The dashed curve sums the first m odd harmonics of a ±1 square wave, .
- The readouts show the share of the square wave's energy that the sum captures, by Parseval, and the error, which shrinks steadily toward 0.
- The overshoot next to each jump doesn't shrink: it narrows and moves toward the jump but stays near 1.18 in height. Small in energy, but never small in the sup norm.
Predict
What fraction of a square wave's power is in its fundamental?
. The fundamental's amplitude is times the square wave's, so its power is of the square wave's power of 1. The other 19% is spread over the odd harmonics, falling as : the square wave's distortion.
Name it
The space
is the space of functions with finite energy , with the inner product of lesson 37 (functions that agree except on a set of zero length count as equal). It's complete: a Hilbert space.
Fourier series as an orthogonal expansion
The functions 1, cos kx, sin kx are orthogonal in , so the Fourier coefficients are projections:
and each partial sum is the best approximation to f, in energy, by trigonometric polynomials of degree N.
Convergence
- In : for every , . And Parseval's identity holds:
- Pointwise: if f is piecewise smooth, where f is continuous, and to the midpoint at a jump.
- Uniformly: if f is continuous, periodic and piecewise smooth (so ).
- Gibbs: at a jump of size J, the partial sums overshoot by about on each side, for every large N.
- Fejér: averaging the partial sums removes the overshoot and converges uniformly for every continuous periodic f; it's the trigonometric Weierstrass theorem.
In measurement
Parseval makes distortion computable: a signal's total harmonic distortion is the RMS of its harmonics over the fundamental's RMS, which for a square wave is .
Worked example
How much of a square wave's energy do the harmonics through the 25th capture?
Show the solution
- All the energy. The odd harmonics have powers proportional to , and together they account for all of it, since
- The share through k = 25.
- What's left. That leaves an error of on [−π, π], where the square wave's own norm is .
Answer the harmonics through the 25th capture 98.4% of the energy.
Worked example
What does the Fourier series of the ±1 square wave give at x = 0?
Show the solution
- Each term at 0. Every term is 0, so the series gives 0.
- Where that sits. 0 is the midpoint of the jump from −1 to 1. Pointwise convergence can't pick a side.
Answer the series gives 0, the midpoint of the jump.
Worked example
A triangle wave between −1 and +1 has odd harmonics of amplitude . Check Parseval and find its THD.
Show the solution
- Mean square. Its mean square is .
- Sum the harmonics' powers. as Parseval requires.
- The THD. It's the RMS of the harmonics above the fundamental over the fundamental's: or 12.1%, against a square wave's 48%.
- Why it's low. The coefficients fall as because the triangle is continuous.
Answer the harmonics' powers add to , matching the mean square, and the THD is 12.1%.
Check
What's the amplitude of harmonic 3 of a square wave that switches between −1 and +1?
Check
By Parseval, what fraction of a square wave's power do its first 2 odd harmonics carry?
Check
At a jump of size 5, about how far past the higher level do the Fourier partial sums overshoot?
Check
A piecewise smooth f jumps from 1 to 3 at x = 0. What does its Fourier series converge to there?
Check
Measured up to harmonic 5, what's a square wave's THD (RMS of the odd harmonics from 3 to 5 over the fundamental's RMS)?
Check
The Fourier partial sums of a square wave converge in which sense?
Check
A triangle wave between −1 and +1 has harmonics of amplitude for odd k.
(a)
What is harmonic 5's amplitude?
(b)
What is it relative to the fundamental?
Check
on [−π, π].
Step 1
What is ?
Type it the way you would write it, like 3sin(2πft) or 3*sin(2*pi*f*t). Angles can be in radians or carry a degree sign, like 45°.
Step 2
What is its RMS value?
Explain why
How can the Fourier series of a square wave converge in energy while its overshoot never shrinks?
Energy convergence measures the integral of the squared error, while the overshoot is about the largest error. As more harmonics are added, the Gibbs ripple near each jump keeps its height, about 9% of the jump, but gets narrower in proportion to . A spike of fixed height and shrinking width has shrinking area and shrinking energy, so the error goes to zero even though the sup norm of the error doesn't. That's why "the Fourier series equals the signal" is exact as a statement about energy, power and filtering, but not as a statement about the worst-case value at every instant.
Practice
Keep practicing
9 kinds of problem on this topic, dealt one at a time with new numbers every time, for as long as you like.