lecture viii: fourier seriesmaxim.ece.illinois.edu/teaching/fall08/lec8.pdf · trigonometric...
TRANSCRIPT
Lecture VIII: Fourier series
Maxim Raginsky
BME 171: Signals and Systems
Duke University
September 19, 2008
Maxim Raginsky Lecture VIII: Fourier series
This lecture
Plan for the lecture:
1 Review of vectors and vector spaces
2 Vector space of continuous-time signals
3 Vector space of T -periodic signals
4 Complete orthonormal systems of functions
5 Trigonometric Fourier series
6 Complex exponential Fourier series
Maxim Raginsky Lecture VIII: Fourier series
Review: vectors
Recall vectors in n-space Rn. Each such vector u can be uniquely
represented as a linear combination of n unit vectors e1, . . . , en:
u = α1e1 + α2e2 + . . . + αnen,
where α1, . . . , αn are real numbers (coefficients). These can becomputed using the scalar (or dot) product as follows:
αk = u · ek, k = 1, . . . , n
Note that the vectors e1, . . . , en are:
normalized — ek · ek = 1 for all k
orthogonal — ek · em = 0 for k 6= m
e1
e2
u
v
x
y
6.53
3
5
0
Example: u,v in R2
u = 3e1 + 5e2
v = 6.5e1 + 3e2
Maxim Raginsky Lecture VIII: Fourier series
Vector spaces
By definition, vectors are objects that can be added together andmultiplied by scalars:
if u =∑n
k=1αkek and v =
∑nk=1
βkek, then we can form their sum
u + v =
n∑
k=1
(αk + βk)ek
if u =∑n
k=1αkek and β is a scalar, then we can form the vector
βu =
n∑
k=1
βαkek
More generally, a collection of objects that can be added and/or
multiplied by scalars is called a vector space.
Maxim Raginsky Lecture VIII: Fourier series
Signal spaces
We have already seen one example of a vector space — the space ofcontinuous-time signals. We can easily verify:
we can form the sum of any two signals x1(t) and x2(t) to getanother signal
x(t) = x1(t) + x2(t)
we can multiply any signal x(t) by a constant c to get another signal
z(t) = cx(t)
Unlike the n-space Rn, the vector space of all continuous-time signals is
huge. In fact, it is infinite-dimensional.
Maxim Raginsky Lecture VIII: Fourier series
The space of periodic signals
Let us consider all T -periodic signals. Any such signal x(t) satisfies
x(t + T ) = x(t) for all t
for some given T > 0.
It is easy to see that T -periodic signals form a vector space:
if x1(t) and x2(t) are T -periodic, then
x1(t + T ) + x2(t + T ) = x1(t) + x2(t),
so their sum is T -periodic
if x(t) is T -periodic, then
cx(t + T ) = cx(t),
so any scaled version of x(t) is also T -periodic
If we impose even more conditions on our T -periodic signals (theso-called Dirichlet conditions, which hold for all signals encountered inpractice), then we can represent signals as infinite linear combinations oforthogonal and normalized (orthonormal) vectors.
Maxim Raginsky Lecture VIII: Fourier series
Complete orthonormal sets of functions
First of all, we can define a scalar (or dot) product of two T -periodicsignals x1(t) and x2(t) as
〈x1, x2〉 =
∫ T
0
x1(t)x2(t)dt
(note that we can integrate over any whole period, not necessarily fromt = 0 to t = T ).
Then we can take any sequence of T -periodic functions (signals)φ0(t), φ1(t), φ2(t), . . . that are
1 normalized: 〈φk, φk〉 =
∫ T
0
φ2
k(t)dt = 1
2 orthogonal: 〈φk, φm〉 =
∫ T
0
φk(t)φm(t)dt = 0 if k 6= m
3 complete: if a signal x(t) is such that
〈x, φk〉 =
∫ T
0
x(t)φk(t)dt = 0 for all k, then x(t) ≡ 0
Maxim Raginsky Lecture VIII: Fourier series
Fourier series
Let {φk(t)}∞k=1be a complete, orthonormal set of functions. Then any
“well-behaved” T -periodic signal x(t) can be uniquely represented as aninfinite series
x(t) =
∞∑
k=0
αkφk(t).
This is called the Fourier series representation of x(t). The scalars(numbers) αk are called the Fourier coefficients of x(t) (with respect to{φk(t)}) and are computed as follows:
αk = 〈x, φk〉 =
∫ T
0
x(t)φk(t)dt
In analogy to vectors in n-space, you can think of αk as the projection(or component) of x(t) in the direction of φk(t).
Maxim Raginsky Lecture VIII: Fourier series
Fourier coefficients
To derive the formula for αk, write
x(t)φk(t) =
∞∑
m=0
αmφm(t)φk(t),
and integrate over one period:
∫ T
0
x(t)φk(t)dt
︸ ︷︷ ︸
〈x,φk〉
=
∫ T
0
(∞∑
m=0
αmφm(t)φk(t)
)
dt
=
∞∑
m=0
αm
∫ T
0
φm(t)φk(t)dt
︸ ︷︷ ︸
〈φm,φk〉
= αk,
where in the last line we use the fact that {φk} form an orthonormal
system of functions.
Maxim Raginsky Lecture VIII: Fourier series
Convergence of Fourier series
It can be proved that, because the functions {φk} form a completeorthonormal system, the partial sums of the Fourier series
x(t) =
∞∑
k=0
αkφk(t)
converge to x(t) in the following sense:
limN→∞
∫ T
0
(
x(t) −N∑
k=1
αkφk(t)
)2
dt = 0
So, we can use the partial sums
xN (t) =
N∑
k=1
αkφk(t)
to approximate x(t).
Maxim Raginsky Lecture VIII: Fourier series
Trigonometric Fourier series
Fact: the sequence of T -periodic functions {φk(t)}∞k=0defined by
φ0(t) =1√T
and φk(t) =
√2
T sin(kω0t), if k ≥ 1 is odd√
2
T cos(kω0t), if k > 1 is even
is complete and orthonormal. Here,
ω0 =2π
T
is called the fundamental frequency. Orthonormality is quite easy toshow, completeness — not so much.
Thus, any well-behaved T -periodic signal x(t) can be represented as aninfinite sum of sinusoids (plus a constant term α0φ0):
x(t) =∞∑
k=0
αkφk(t)
Maxim Raginsky Lecture VIII: Fourier series
Trigonometric Fourier series
A more common way of writing down the trigonometric Fourier series ofx(t) is this:
x(t) = a0 +∞∑
k=1
ak cos(kω0t) +∞∑
k=1
bk sin(kω0t)
Then the Fourier coefficients can be computed as follows:
a0 =1
T
∫ T
0
x(t)dt
ak =2
T
∫ T
0
x(t) cos(kω0t)dt
bk =2
T
∫ T
0
x(t) sin(kω0t)dt
Recall that ω0 = 2π/T .
Maxim Raginsky Lecture VIII: Fourier series
Trigonometric Fourier series
To relate this to the orthonormal representation in terms of the φk, wenote that we can write
a0 =1√T
∫ T
0
x(t)φ0(t)dt =1√T
α0
ak =
√
2
T
∫ T
0
x(t)φ2k(t)dt =
√
2
Tα2k
bk =
√
2
T
∫ T
0
x(t)φ2k−1(t)dt =
√
2
Tα2k−1
Thus, we have
x(t) = a0 +
∞∑
k=1
ak cos(kω0t) +
∞∑
k=1
bk sin(kω0t)
=1√T
αk ·√
Tφ0(t) +
√
2
T
(∞∑
k=1
α2k ·√
T
2φ2k(t) +
∞∑
k=1
α2k−1 ·√
T
2φ2k−1(t)
)
=∞∑
k=1
αkφk(t)
Maxim Raginsky Lecture VIII: Fourier series
Symmetry properties
Things to watch out for when computing the Fourier coefficients:
if x(t) is an even function, i.e., x(t) = x(−t) for all t, then all itssine Fourier coefficients are zero:
bk =2
T
∫ T/2
−2/T
x(t) sin(kω0t)dt = 0
if x(t) is an odd function, i.e., x(t) = −x(−t), then all its cosineFourier coefficients are zero:
ak =2
T
∫ T/2
−2/T
x(t) cos(kω0t)dt = 0,
and
a0 =1
T
∫ T/2
−2/T
x(t)dt = 0
Maxim Raginsky Lecture VIII: Fourier series
Trigonometric Fourier series: example
Consider a 2-periodic signal x(t) given by repeating the square wave:
−1 −0.8 −0.6 −0.4 −0.2 0 0.2 0.4 0.6 0.8 1
−1
−0.8
−0.6
−0.4
−0.2
0
0.2
0.4
0.6
0.8
1
a0 = 0 and ak = 0 for all k(the signal has oddsymmetry)
bk =
∫0
−1
sin(kπt)dt −∫
1
0
sin(kπt)dt
= − 1
kπ[cos(kπt)]
0
−1+
1
kπ[cos(kπt)]
1
0
=1
kπ
(
cos(−kπ) − 1 + cos(kπ) − 1)
=1
kπ(2 cos(kπ) − 2)
= −4 sin2(kπ/2)
kπ
x(t) = −∞∑
k=1
4 sin2(kπ/2)
kπsin(kπt) = −
∞∑
k odd
4
kπsin(kπt)
Maxim Raginsky Lecture VIII: Fourier series
Trigonometric Fourier series: example
Approximating x(t) by partial sums of its Fourier series:
−1 −0.5 0 0.5 1−1.5
−1
−0.5
0
0.5
1
1.5N = 10
−1 −0.5 0 0.5 1−1.5
−1
−0.5
0
0.5
1
1.5N = 15
−1 −0.5 0 0.5 1−1.5
−1
−0.5
0
0.5
1
1.5N = 50
−1 −0.5 0 0.5 1−1.5
−1
−0.5
0
0.5
1
1.5N = 150
Note the Gibbs phenomenon: the Fourier series (over/under)shoots the
actual value of x(t) at points of discontinuity. In signal processing, this
effect is also called ringing.
Maxim Raginsky Lecture VIII: Fourier series
Complex exponential Fourier series
Another useful complete orthonormal set is furnished by the complexexponentials:
φk(t) =1√T
ejkω0t, k = . . . ,−2,−1, 0, 1, 2, . . .
where ω0 = 2π/T , as before.
Note that these functions are complex-valued, and we need to redefinethe dot product as
〈x1, x2〉 =
∫ T
0
x1(t)x∗2(t)dt,
where x∗1(t) denotes the complex conjugate of x2(t). Then it is
straightforward to show that
〈φk, φm〉 =1
T
∫ T
0
ejkω0te−jmω0tdt =
{1, k = m0, k 6= m
Maxim Raginsky Lecture VIII: Fourier series
Complex exponential Fourier series
Thus, we can expand any T -periodic x(t) as
x(t) =∞∑
k=−∞
ckejkω0t
The Fourier coefficients are given by
ck =1
T
∫ T
0
x(t)e−jkω0tdt
To derive this, multiply the series representation of x(t) on the right by
e−jkω0t and integrate from 0 to T .
Maxim Raginsky Lecture VIII: Fourier series
Symmetry properties for real signals
Consider a real-valued T -periodic signal x(t). Then
ck =1
T
∫ T
0
x(t)e−jkω0tdt and c−k =1
T
∫ T
0
x(t)ejkω0tdt = c∗k
Write ck in polar form:
ck = Akejθk , Ak = |ck|, θk = ∠ck
Thenck = c∗−k ⇒ Ak = A−k and ∠ck = −∠c−k
Thus, for real signals the amplitude spectrum Ak has even symmetry,
while the phase spectrum θk has odd symmetry.
Maxim Raginsky Lecture VIII: Fourier series
Amplitude and phase spectra
We can use the amplitudes Ak and the phases θk to represent thespectrum (or frequency content) of x(t) graphically as follows:
ω02ω03ω0
ω02ω03ω0
−3ω0−2ω
0−ω
0
−3ω0−2ω
0−ω
0
0
0
A(ω)
θ(ω)
ω
ω
Observe that the amplitude spectrum A(ω) has even symmetry, while
the phase spectrum θ(ω) has odd symmetry.
Maxim Raginsky Lecture VIII: Fourier series