Skip to content

Fourier series coefficients

Turn the multiply-and-average trick into the Fourier series formula, write it three ways, read it as a line spectrum, and use symmetry and power.

Before this2.1 · 7.1 · 6 more
Chapter 7 · Lesson 2 of 4

First, the picture

A wave that is 1 for half of each period and 0 for the rest, wound around a circle. Watch the dot: the average position of the wound-up curve.

Wind the wave, find its balance point

Six winding settings, one after another; then the wave is lifted.

Winding setting 1: every point is turned back one lap per period.

Winding setting
1
Balance point
–
0.00 / 18.00 s
Describe this picture

Three parts: the wave; the wound-up curve on the complex plane, with a dot at the average position of the part drawn so far; and a strip of bars named ”∣ck∣\lvert c_k\rvert: half an arrow’s length”, with an “average” slot 0 and slots 1 to 5. The clip plays the winding settings in the order 1,2,0,3,4,51, 2, 0, 3, 4, 5, two and a half seconds each, and after each setting stamps a bar on the strip: the average in slot 0 and ∣ck∣\lvert c_k\rvert in slots 1 to 5. From 15 s it shows setting 0 again and lifts the wave by 0.5. The step buttons |◀ and ▶| jump from one setting to the next. The finished frame shows setting 0 on the lifted wave; then dragging along the bars, or the arrow keys, Home and End, pick any setting from 0 to 5, and the caption describes the lifted wave. The readouts are “Winding setting” and “Balance point”, the dot as a complex number.

From arrows to a formula

On the page Signals as sums of sinusoids (7.1) you saw that a repeating wave is a sum of spinning arrows. You also saw that one arrow can be measured alone: multiply the wave by that arrow’s harmonic, average, and double. This page turns that trick into a formula that works for any repeating wave.

The formula comes in three forms, and an exam may ask for any of them. I will show that they describe the same wave. Then I will draw the answer as a row of lines, and use symmetry to know in advance which lines are empty.

The wave I use throughout is a 0-to-1 square wave. It is 1 for the first half of each period TT and 0 for the second half. I chose it, and not 7.1’s wave between −1-1 and +1+1, because it has a constant part, and I want that part to have something to show. It equals 12\tfrac12 plus half of 7.1’s wave, so you already know most of its arrows.

There is one change of reading from 7.1. There I followed the height of an arrow’s tip, so a sine started at height 0. From here on I follow the horizontal position of the tip, as on the page Complex exponentials & phasors (3.4).

A cosine is then an arrow that starts pointing right. A sine is a cosine delayed by a quarter turn, as in Sinusoids (3.2), so it is an arrow that starts pointing down.

height of tiphorizontal position
Fig. The same arrow, read two ways. Left: 7.1 read the height of the tip. Right: this page reads its horizontal position, so a cosine starts pointing right and a sine starts pointing down.

Winding the wave up

Here is 7.1’s trick, rewritten with complex numbers. To measure harmonic kk, multiply the wave by the arrow e−jkω0te^{-jk\omega_0t} and average. Here ω0=2π/T\omega_0=2\pi/T is the fundamental, and θ=ω0t\theta=\omega_0t is the angle it has turned by time tt.

Multiplying by a point on the unit circle only rotates, as on the page Complex numbers for signals (3.3). So at every instant this turns the wave’s value back by kθk\theta. I call that winding the wave at setting kk.

The wave’s value is a point on the real axis of the complex plane. Where the wave is 1, the wound-up point rides the unit circle. Where the wave is 0, it stays at the origin. The average of where this point has been is a complex number, and I call it ckc_k.

Go back to the picture at the top of the page. While the curve is drawn, the dot is the average position of the part drawn so far, so it moves. When the curve is complete, the dot is ckc_k, the curve’s balance point. At setting 1 the curve leans to one side, and the dot settles 0.3180.318 from the centre. At setting 2 the curve closes into a full circle, and the dot sits at the centre.

Setting 0 is no winding at all, so the dot is the average of the wave itself, which is 0.5. At the end the clip lifts the wave by 0.5, which raises every value of the wave by 0.5. The dot slides from 0.5 to 1.0, and only the bar in the “average” slot moves.

When the clip has finished, drag along the bars to pick any setting from 0 to 5. Settings 2 and 4 put the dot at the centre. Odd settings lean it to one side, and the dot is nearer the centre for larger settings.

The strip says “half an arrow’s length” for a reason. In 7.1 a real wave needs one arrow for each harmonic. On the page Complex exponentials & phasors (3.4) that arrow is really two, spinning in opposite directions at kk and −k-k, and each is half as long. The winding at setting kk measures one of the two. For the 0-to-1 wave, 7.1’s arrow 1 is 0.6370.637 long and the bar for setting 1 is 0.3180.318. The next section draws the pair.

Now the formula. Averaging a complex quantity means averaging its real parts and its imaginary parts separately, as when you add points in Complex numbers for signals (3.3). Written with the area from 00 to TT divided by TT, as in 7.1,

ck=1T∫0Tx(t) e−jkω0t dt.c_k=\frac1T\int_0^T x(t)\,e^{-jk\omega_0t}\,dt .

This is the analysis equation. Any one period gives the same answer for a repeating wave, so I use 00 to TT unless another period is easier, as in step 4 of the worked example.

Why does the winding find harmonic kk and nothing else? Suppose the wave is a sum of arrows, x(t)=∑mcmejmω0tx(t)=\sum_m c_m e^{jm\omega_0t}, with mm running over all whole numbers, positive and negative. Multiply by e−jkω0te^{-jk\omega_0t}. The term for harmonic mm becomes cm ej(m−k)ω0tc_m\,e^{j(m-k)\omega_0t}, an arrow that turns m−km-k laps per period.

For m≠km\ne k, that arrow keeps turning, and its average is zero. For m=km=k the arrow stands still and survives with the value ckc_k. The zero comes from one line of calculus: for a constant aa that may be complex, ∫eat dt=eat/a\int e^{at}\,dt=e^{at}/a. With a=jnω0a=jn\omega_0 and n≠0n\neq0,

∫0Tejnω0t dt=ejnω0T−1jnω0=0,\int_0^T e^{jn\omega_0t}\,dt=\frac{e^{jn\omega_0T}-1}{jn\omega_0}=0,

because ω0T=2π\omega_0T=2\pi, so ejnω0T=ej2πn=1e^{jn\omega_0T}=e^{j2\pi n}=1. This is the same cancellation as in 7.1, now for any pair of harmonics. It also gives the other half of the pair of equations, the synthesis equation:

x(t)=∑k=−∞∞ck ejkω0t.x(t)=\sum_{k=-\infty}^{\infty}c_k\,e^{jk\omega_0t}.

Let’s use the analysis equation on the running wave, which is 1 on (0,T/2)(0,T/2) and 0 after that. For k=0k=0 nothing winds, and c0c_0 is the average of the wave, which is 12\tfrac12. For k≠0k\neq0,

ck=1T∫0T/2e−jkω0t dt=1−e−jkπjk ω0T=1−e−jkπj2πk.c_k=\frac1T\int_0^{T/2}e^{-jk\omega_0t}\,dt=\frac{1-e^{-jk\pi}}{jk\,\omega_0T}=\frac{1-e^{-jk\pi}}{j2\pi k}.

For even kk, e−jkπ=1e^{-jk\pi}=1 and ck=0c_k=0, which is the circle that closes. For odd kk, e−jkπ=−1e^{-jk\pi}=-1, so ck=1jkπ=−jkπc_k=\dfrac{1}{jk\pi}=\dfrac{-j}{k\pi}, since 1/j=−j1/j=-j. That gives c1=−0.3183jc_1=-0.3183j, c3=−0.1061jc_3=-0.1061j and c5=−0.0637jc_5=-0.0637j, the bars of the instrument.

Watch out

c0c_0 is the average of the wave over a period. It is not the value of the wave at t=0t=0. Lifting the whole wave by dd adds dd to c0c_0 and changes no other ckc_k, because a constant has no turning part to average.

One harmonic, three ways to write it

Each harmonic with k≥1k\ge1 is a real wave at kω0k\omega_0. You can write it in three ways, and the picture below shows that they are one wave. I use the example from the page Complex exponentials & phasors (3.4): 3cos⁡θ+4sin⁡θ=5cos⁡(θ−53.13°)3\cos\theta+4\sin\theta=5\cos(\theta-53.13°).

Watch the traced wave. It never changes, while the description of it does.

Two arrows, one arrow, a mirror pair

Three ways to write 3 cos θ + 4 sin θ. The traced wave never changes.

Two arrows: 3 cos θ, and 4 sin θ, which starts pointing down.

Two arrows (trigonometric)3 cos θ + 4 sin θ
One arrow (compact)–
Mirror pair (complex)–
0.00 / 12.00 s
Describe this picture

Arrows on the complex plane and the wave they trace, with three rows appearing below the figure one after another: “Two arrows (trigonometric)”, “One arrow (compact)” and “Mirror pair (complex)”. First there are two arrows, a length-3 arrow pointing right for the cosine and a length-4 arrow pointing down for the sine, and they spin one lap together. The second arrow then moves until its tail sits on the first arrow’s tip, and the two make one arrow of length 5. At 8 s that arrow splits into two arrows of length 2.5, which spin one lap in opposite directions. The rows end with c1=1.5−2jc_1=1.5-2j and c−1=1.5+2jc_{-1}=1.5+2j.

The two arrows, 3 and 4, join into one arrow of length 5, and that arrow splits into a mirror pair of arrows 2.5 long, spinning in opposite directions.

The three forms are these. In the trigonometric form, a harmonic is akcos⁡kθ+bksin⁡kθa_k\cos k\theta+b_k\sin k\theta. In the compact form, it is one shifted cosine, Akcos⁡(kθ+ϕk)A_k\cos(k\theta+\phi_k). In the complex form, it is a mirror pair of arrows, ckejkθ+c−ke−jkθc_ke^{jk\theta}+c_{-k}e^{-jk\theta}. On this page aka_k and bkb_k are Fourier coefficients; on the page Difference equations (6.1) the same letters name filter coefficients, which are a different thing.

The two arrows of the complex form are mirror images of each other. For a real wave, the analysis equation gives

ck∗=1T∫0Tx(t) e+jkω0t dt=c−k,c_k^*=\frac1T\int_0^T x(t)\,e^{+jk\omega_0t}\,dt=c_{-k},

since x(t)x(t) is real and conjugating the integrand turns e−jkω0te^{-jk\omega_0t} into e+jkω0te^{+jk\omega_0t}. Here ck∗c_k^* is the mirror image of ckc_k from Complex numbers for signals (3.3). The pair adds to 2 Re (ckejkθ)2\,\mathrm{Re}\,(c_ke^{jk\theta}), which is real.

Now put ck=(ak−jbk)/2c_k=(a_k-jb_k)/2 into that pair. Multiplying out 2 Re[ak−jbk2(cos⁡kθ+jsin⁡kθ)]2\,\mathrm{Re}\left[\tfrac{a_k-jb_k}{2}(\cos k\theta+j\sin k\theta)\right] gives akcos⁡kθ+bksin⁡kθa_k\cos k\theta+b_k\sin k\theta. So

ak=2 Re ck,bk=−2 Im ck,Ak=2∣ck∣=ak2+bk2,ϕk=∠ck=−atan2(bk,ak).a_k=2\,\mathrm{Re}\,c_k,\qquad b_k=-2\,\mathrm{Im}\,c_k,\qquad A_k=2\lvert c_k\rvert=\sqrt{a_k^2+b_k^2},\qquad \phi_k=\angle c_k=-\mathrm{atan2}(b_k,a_k).

Here atan2(bk,ak)\mathrm{atan2}(b_k,a_k) is the angle of the point ak+jbka_k+jb_k, in the range (−180°,180°](-180°,180°], as the readouts use and as on the page Complex numbers for signals (3.3). The minus sign appears because the arrow that starts pointing down is a sine with a positive bkb_k. The constant is a0=A0=c0a_0=A_0=c_0. Some books write a0/2a_0/2 for the constant, with a0=2c0a_0=2c_0.

For 3cos⁡θ+4sin⁡θ3\cos\theta+4\sin\theta we have a1=3a_1=3 and b1=4b_1=4. Then c1=1.5−2jc_1=1.5-2j, so ∣c1∣=2.5\lvert c_1\rvert=2.5 and ∠c1=−53.13°\angle c_1=-53.13° (−0.9273-0.9273 rad). The arrow lengths of 7.1 are Ak=2∣ck∣A_k=2\lvert c_k\rvert, which is 55 here. That is why the bars of the first instrument were half an arrow: each real arrow is the sum of two halves.

For the 0-to-1 wave, ck=−j/(kπ)c_k=-j/(k\pi) is purely imaginary. So ak=0a_k=0 and bk=2/(kπ)b_k=2/(k\pi) for odd kk, which is 0.6366, 0.2122 and 0.1273 for k=1,3,5k=1,3,5. These are half of 7.1’s lengths 4/(πk)4/(\pi k) for the wave between −1-1 and +1+1, as they should be.

The line spectrum, and what a delay does

Plot the length ∣ck∣\lvert c_k\rvert and the angle ∠ck\angle c_k against kk, for negative and positive kk alike. The result is a row of lines, the line spectrum of the wave. For the 0-to-1 wave the line at k=0k=0 has length 0.50.5. The odd lines have length 1/(∣k∣π)1/(\lvert k\rvert\pi), and their angles are −90°-90° for k>0k>0 and +90°+90° for k<0k<0, as the mirror rule requires.

Now delay the wave by a time t0t_0, as on the page Shifting, reversing and scaling time (2.1). The notes of a recording played a moment later are the same notes at the same loudness. So what happens to the lines?

Put s=t−t0s=t-t_0 in the analysis equation. The delayed wave x(t−t0)x(t-t_0) has the coefficient

1T∫x(t−t0) e−jkω0t dt=1T∫x(s) e−jkω0(s+t0) ds=e−jkω0t0 ck.\frac1T\int x(t-t_0)\,e^{-jk\omega_0t}\,dt=\frac1T\int x(s)\,e^{-jk\omega_0(s+t_0)}\,ds=e^{-jk\omega_0t_0}\,c_k .

The length of every line is unchanged. Line kk turns by the angle −kω0t0-k\omega_0t_0, which is kk times as far as line 1. Before you watch, decide: if the whole wave moves later by T/4T/4, does every line turn by the same angle?

Press play and watch the dial under each line as the wave moves later, first by T/8T/8, then by T/4T/4.

The square wave delayed by a quarter period

Line lengths, and a dial for each line’s angle.

No delay yet. Lines 1, 3 and 5 all point at −90°.

Delay
0
Angle of line 1
−90°
turned 0°
Angle of line 3
−90°
turned 0°
Angle of line 5
−90°
turned 0°

Angles are given between −180° and 180°; −180° and 180° point the same way.

0.00 / 8.00 s
Describe this picture

The 0-to-1 wave with its harmonics 1 and 3 (the key reads “wave, harmonic 1, harmonic 3”), the lines of its spectrum, and a dial under each line showing its angle. The readouts are “Delay”, “Angle of line 1”, “Angle of line 3” and “Angle of line 5”; at first all three angles read −90°-90°. The wave moves later in two steps, to T/8T/8 at about 3.5 s and to T/4T/4 at 7 s. Each angle readout also shows how far its dial has turned, and angles are given between −180°-180° and 180°180°, so when a dial turns past 180°180°, its reading jumps to the other end of that range.

At first every angle reads −90°-90°. The dial for line 3 turns three times as far as the dial for line 1, and line 5 turns five times as far. The answer to the question is no: one time shift is a different angle on every line. The readouts give angles between −180°-180° and 180°180°.

At a delay of T/8T/8 the angle step is kω0t0=k⋅2πT⋅T8=k⋅45°k\omega_0t_0=k\cdot\tfrac{2\pi}{T}\cdot\tfrac T8=k\cdot45°. So line 1 reads −90°−45°=−135°-90°-45°=-135°. Line 3 is at −90°−135°=−225°-90°-135°=-225°, which the readout shows as +135°+135°. Line 5 is at −90°−225°=−315°-90°-225°=-315°, shown as +45°+45°. At T/4T/4 the turns are −90°-90°, −270°-270° and −450°-450°, and the lines read 180°180°, 0°0° and 180°180°.

Line 0 never moves. Its length stays 0.50.5 and its angle stays 0°0°. But the wave near t=0t=0 does change. At first it jumps from 0 to 1 at t=0t=0, so just after t=0t=0 it is 1. After the delay of T/4T/4 it is 0 there. So the line at 00 is the average, not the value of the wave at t=0t=0.

Symmetry tells you what is zero

You can often tell that whole families of coefficients are zero without computing any integral. The reason is this: a cosine is even and a sine is odd. These words are from Kinds of signals (1.2): a wave is even if its mirror image about t=0t=0 lies exactly on it, and odd if the mirror image is the wave turned upside down.

Take the mirrored copy of a wave, x(−t)x(-t). It leaves every cosine term as it was and flips every sine term. So if the copy equals the wave, no sine term can be present, because each would have to equal its own negative. If the copy is the wave turned upside down, no cosine term can be present, including the constant.

There is a third kind of symmetry. A wave has half-wave symmetry if its second half is its first half turned upside down: x(t+T/2)=−x(t)x(t+T/2)=-x(t).

Advance the wave by T/2T/2 and use the delay rule from the last section with t0=−T/2t_0=-T/2. Each coefficient is multiplied by ejkπ=(−1)ke^{jk\pi}=(-1)^k, so odd kk flips and even kk stays. Half-wave symmetry says the advanced wave is −x(t)-x(t), so (−1)kck=−ck(-1)^kc_k=-c_k, and every even ckc_k is zero.

Even and odd depend on where you place t=0t=0, as in Decomposing signals (2.3).

Here are three tests, one after another. The bars are signed arrow lengths, as in 7.1: each bar for k≥1k\ge1 is ±2∣ck∣\pm2\lvert c_k\rvert, and a0a_0 is c0c_0. A dashed bar marked ”?” could be anything. Press play and watch the dashed bars.

Three copies that fit onto the wave

When a moved copy fits exactly onto the wave, a whole family of bars is zero.

A wave, and every bar it could have.

0.00 / 12.00 s
Describe this picture

A wave and a moved copy of it (the key names the “wave” and its “copy”), above two strips of bars, ”aka_k (cosine)” and ”bkb_k (sine)”. A bar that has been decided to be zero shows “0”. Three tests run one after another, each for four seconds. First, an even triangle is mirrored across the vertical axis and fits onto itself; the sine bars change to “0”, the cosine bars at odd kk settle at 0.8110.811, 0.0900.090 and 0.0320.032, and the even-kk bars keep their ”?”. Next, the 0-to-1 wave loses its constant part: the a0a_0 bar shrinks to “0”, leaving an odd wave between −0.5-0.5 and +0.5+0.5. From about 5.7 s a copy turned over both axes fits onto it; the cosine bars become “0” and the sine bars at odd kk settle at 0.6370.637, 0.2120.212 and 0.1270.127. In the last four seconds, the triangle is slid by half a period and turned upside down, fits onto itself, and the even bars change from ”?” to “0”.

First, an even triangle is mirrored across the vertical axis and fits onto itself, so every sine bar is “0”. The even-kk bars keep their ”?”, because mirror symmetry says nothing about them.

Next, the 0-to-1 wave first loses its constant part, and what remains is an odd wave between −0.5-0.5 and +0.5+0.5. A copy turned over both axes fits onto it, so no cosine bars remain.

Last, the triangle is slid by half a period and turned upside down, and it fits onto itself. Now the even bars change from ”?” to “0”. For the triangle only the odd cosine bars survive. The odd wave of the second part passes the same test, so only its odd sine bars survive.

Moving the origin matters too. The delay of T/4T/4 in the last section turned lines 1, 3 and 5 to 180°180°, 0°0° and 180°180°. Those lines point along the real axis, so those ckc_k are real numbers, and bk=−2 Im ck=0b_k=-2\,\mathrm{Im}\,c_k=0. The delayed wave has no sine terms. It is even, although the original was not.

Where the power goes

The last quantity is power. As on the page How big is a signal (1.3), the power of a wave is the average of ∣x∣2\lvert x\rvert^2.

Write ∣x∣2=x x∗\lvert x\rvert^2=x\,x^* with x=∑mcmejmω0tx=\sum_m c_me^{jm\omega_0t}, and average. The cross terms between different harmonics spin and average to zero, as before. Only the terms with the same harmonic survive, and each contributes ∣ck∣2\lvert c_k\rvert^2:

1T∫0T∣x∣2 dt=∑k=−∞∞∣ck∣2.\frac1T\int_0^T\lvert x\rvert^2\,dt=\sum_{k=-\infty}^{\infty}\lvert c_k\rvert^2 .

This is Parseval’s relation. For a real wave, lines kk and −k-k carry the same power. Together they give 2∣ck∣2=Ak2/22\lvert c_k\rvert^2=A_k^2/2, which is 7.1’s fact that sin⁡2\sin^2 averages to 12\tfrac12 for an arrow of length AkA_k. The total is a02+∑k≥1Ak2/2a_0^2+\sum_{k\ge1}A_k^2/2.

I will check it on the wave between −1-1 and +1+1, because its square is 1 at every instant and so its power is exactly 1. Fill a tank with one layer per arrow: the arrow for harmonic kk adds Ak2/2=8π2k2A_k^2/2=\dfrac{8}{\pi^2k^2}, and only odd kk have one. Watch “Power so far” climb towards 1.

Filling the power tank

The ±1 square wave; one layer per arrow.

The square wave's average power is 1: its square is 1 all the time.

Arrows
0
Power so far
0.0000
k = 1–
k = 3–
k = 5–
k = 7–
k = 9–
k = 11–
k = 13–
k = 15–
0.00 / 12.00 s
Describe this picture

The ±1 square wave with the sum of the arrows so far, and a tank labelled “power” with a level marked “1: the mean of x²”. A new arrow adds its layer about every 1.2 seconds, and the readouts “Arrows” and “Power so far” follow. The clip holds for a moment at four arrows, from 4.8 s, where the level is 0.94960.9496, and again at eight arrows, from 10.5 s, where it is 0.97470.9747. A list under the picture gives the power of each arrow.

The first arrow alone fills 0.81060.8106, which is 81 %81\,\% of the total. Four arrows reach 0.94960.9496 and eight reach 0.97470.9747. Each later arrow adds a thinner layer, so the level rises more slowly towards 1.

I do not sum the infinite series here. The total of 1 comes straight from x2=1x^2=1. The small gap that remains after a given number of arrows is the subject of the page Convergence and the Gibbs phenomenon (7.3). The wave panel of this instrument shows the sum of the arrows overshooting near each jump. That overshoot is explained there too.

For the 0-to-1 wave, x2=xx^2=x, so its power is its average, 0.50.5. The constant part carries a02=0.25a_0^2=0.25 of that total, which is half.

The maths behind it · orthogonal bases

Measuring ckc_k by multiplying and averaging works like measuring how far one arrow in space points along another. Harmonics at different whole-number frequencies average to zero against each other, like arrows at right angles. Parseval’s relation then says that a squared length is the sum of the squared lengths of its parts, which is Pythagoras’ theorem with infinitely many directions. Linear algebra calls the multiply-and-average a projection, and calls the set of harmonics an orthogonal basis.

The maths behind it · splitting the variance

The constant c0c_0 is the average of the signal, the same number a statistician calls the sample mean. Parseval’s relation says that the total mean square is the squared mean plus one share from each harmonic. Harmonics at different frequencies do not rise and fall together, so their shares add with no cross terms. Statistics calls this splitting the variance into parts, and calls such components uncorrelated.

Worked example

  1. Square wave between −1-1 and +1+1. It is +1+1 on (0,T/2)(0,T/2) and −1-1 on (T/2,T)(T/2,T). Then ck=1T[∫0T/2−∫T/2T]e−jkω0t dt=2jkπc_k=\dfrac1T\left[\displaystyle\int_0^{T/2}-\int_{T/2}^{T}\right]e^{-jk\omega_0t}\,dt=\dfrac{2}{jk\pi} for odd kk, and 00 for even kk and for k=0k=0. So c1=−0.6366jc_1=-0.6366j, c3=−0.2122jc_3=-0.2122j and c5=−0.1273jc_5=-0.1273j. Then 2∣ck∣=4/(πk)2\lvert c_k\rvert=4/(\pi k), the lengths of 7.1.
  2. The 0-to-1 square wave. It equals 12+12(the wave of step 1)\tfrac12+\tfrac12(\text{the wave of step 1}). So c0=0.5c_0=0.5, and ck=1jkπc_k=\dfrac1{jk\pi} for odd kk: c1=−0.3183jc_1=-0.3183j, c3=−0.1061jc_3=-0.1061j, c5=−0.0637jc_5=-0.0637j. The arrow lengths 2∣ck∣2\lvert c_k\rvert are 0.6366, 0.2122 and 0.1273. Lifting the wave by 0.50.5 moves only c0c_0, from 0.50.5 to 1.01.0.
  3. Three forms. For 3cos⁡θ+4sin⁡θ3\cos\theta+4\sin\theta: a=3a=3, b=4b=4, A=5A=5, ϕ=−atan2(4,3)=−0.9273\phi=-\mathrm{atan2}(4,3)=-0.9273 rad =−53.13°=-53.13°. Also c1=(a−jb)/2=1.5−2jc_1=(a-jb)/2=1.5-2j with ∣c1∣=2.5\lvert c_1\rvert=2.5 and ∠c1=−53.13°\angle c_1=-53.13°, and c−1=c1∗=1.5+2jc_{-1}=c_1^*=1.5+2j. Check: 2 Re (c1ejθ)=3cos⁡θ+4sin⁡θ2\,\mathrm{Re}\,(c_1e^{j\theta})=3\cos\theta+4\sin\theta.
  4. A pulse train. Take T=1T=1 s and a pulse of half-width T1=0.25T_1=0.25 s, so x=1x=1 for ∣t∣<T1\lvert t\rvert<T_1 and x=0x=0 elsewhere in the period. Integrating from −T/2-T/2 to T/2T/2, with ω0T=2π\omega_0T=2\pi, ck=1T∫−T1T1e−jkω0t dt=ejkω0T1−e−jkω0T1jkω0T=2sin⁡(kω0T1)kω0T=sin⁡(kω0T1)kπ.c_k=\frac1T\int_{-T_1}^{T_1}e^{-jk\omega_0t}\,dt=\frac{e^{jk\omega_0T_1}-e^{-jk\omega_0T_1}}{jk\omega_0T}=\frac{2\sin(k\omega_0T_1)}{k\omega_0T}=\frac{\sin(k\omega_0T_1)}{k\pi}. Here kω0T1=kπ/2k\omega_0T_1=k\pi/2, so ck=sin⁡(kπ/2)kπc_k=\dfrac{\sin(k\pi/2)}{k\pi}, and c0=2T1/T=0.5c_0=2T_1/T=0.5. Then c1=0.3183c_1=0.3183, c2=0c_2=0, c3=−0.1061c_3=-0.1061, c4=0c_4=0 and c5=0.0637c_5=0.0637. Its power is 0.50.5, because x2=xx^2=x.
  5. A time shift. Delay the wave of step 1 by T/8T/8. Each ckc_k becomes cke−jkπ/4c_ke^{-jk\pi/4}, so ∠c1=−135°\angle c_1=-135°, ∠c3=−225°≡+135°\angle c_3=-225°\equiv+135° and ∠c5=−315°≡+45°\angle c_5=-315°\equiv+45°. The magnitudes and c0c_0 are unchanged.
  6. Parseval. For the wave of step 1, harmonic kk carries 2∣ck∣2=8π2k22\lvert c_k\rvert^2=\dfrac{8}{\pi^2k^2}: 0.8106, 0.0901, 0.0324 and 0.0165 for k=1,3,5,7k=1,3,5,7. The running totals are 0.8106, 0.9006, 0.9331 and 0.9496. With eight arrows the total is 0.97470.9747, and the exact total is 11.
  7. Three quick cases. Lifting a wave by 0.50.5 changes only c0c_0, by +0.5+0.5. For x=3cos⁡ω0t+4sin⁡ω0tx=3\cos\omega_0t+4\sin\omega_0t, A1=5A_1=5 and ∣c1∣=2.5\lvert c_1\rvert=2.5. A delay of T/4T/4 keeps every ∣ck∣\lvert c_k\rvert and turns line 3 by −3⋅90°=−270°-3\cdot90°=-270°, not −90°-90°.

Where you’ll meet this

The lines of a spectrum are what an audio analyser shows: the length of each line is how much of that frequency a sound contains. The phase dials explain why a sound stays recognisable when it is delayed, while a different delay for each frequency, as in some filters, changes its shape. This is the subject of Fourier series and LTI systems (7.4), where each ckc_k passes through a system on its own.

Power per harmonic is how harmonic distortion is measured: the power in the harmonics that should not be there, compared with the power in the one that should. The next step is to let the period TT grow without limit, so that the lines crowd together into a curve. That is the page From series to transform (8.1). The rule that a delay turns each line by an angle in proportion to its frequency returns on the page Properties of the Fourier transform (8.2).

Reference card

QuantityFormulaNotes
Synthesis (complex)x(t)=∑k=−∞∞ckejkω0tx(t)=\sum_{k=-\infty}^{\infty}c_ke^{jk\omega_0t}ω0=2π/T\omega_0=2\pi/T
Analysisck=1T∫0Tx(t)e−jkω0t dtc_k=\dfrac1T\int_0^Tx(t)e^{-jk\omega_0t}\,dtany one period would do; c0c_0 is the average
Trigonometricx=a0+∑k≥1[akcos⁡kω0t+bksin⁡kω0t]x=a_0+\sum_{k\ge1}\left[a_k\cos k\omega_0t+b_k\sin k\omega_0t\right]ak=2 Re cka_k=2\,\mathrm{Re}\,c_k, bk=−2 Im ckb_k=-2\,\mathrm{Im}\,c_k, a0=c0a_0=c_0; here ak,bka_k,b_k are Fourier coefficients
Compactx=A0+∑k≥1Akcos⁡(kω0t+ϕk)x=A_0+\sum_{k\ge1}A_k\cos(k\omega_0t+\phi_k)Ak=2∣ck∣A_k=2\lvert c_k\rvert, ϕk=∠ck\phi_k=\angle c_k
Real signalc−k=ck∗c_{-k}=c_k^*even magnitude, odd angle
Lifting a wavex+d ⇒ c0→c0+dx+d\ \Rightarrow\ c_0\to c_0+d, all other ckc_k unchangedc0c_0 is the average, not the value at t=0t=0
Time shiftx(t−t0)↔cke−jkω0t0x(t-t_0)\leftrightarrow c_ke^{-jk\omega_0t_0}magnitudes and c0c_0 unchanged; line kk turns by −kω0t0-k\omega_0t_0
Symmetrieseven: bk=0b_k=0; odd: ak=0a_k=0 and a0=0a_0=0; half-wave (x(t+T/2)=−x(t)x(t+T/2)=-x(t)): even kk vanisha cosine is even, a sine is odd
Parseval1T∫0T∣x∣2dt=∑k∣ck∣2=a02+∑k≥1Ak22\dfrac1T\int_0^T\lvert x\rvert^2dt=\sum_k\lvert c_k\rvert^2=a_0^2+\sum_{k\ge1}\dfrac{A_k^2}{2}power per harmonic Ak2/2A_k^2/2; the constant part’s share is a02a_0^2
Square wave (±1\pm1)ck=2jkπc_k=\dfrac{2}{jk\pi}, odd kk=−j 2/(kπ)=-j\,2/(k\pi)
0-to-1 square wavec0=12c_0=\tfrac12, ck=1jkπc_k=\dfrac{1}{jk\pi}, odd kkhalf the ±1\pm1 lines, plus the average
Pulse train, ∣t∣<T1\lvert t\rvert<T_1ck=sin⁡(kω0T1)kπc_k=\dfrac{\sin(k\omega_0T_1)}{k\pi}c0=2T1/Tc_0=2T_1/T

End of lesson 7.2

Where to go next.

Phasorium
LibraryEvery lesson, in order

Parts

About Phasorium
Look