FOURIER ANALYSIS 1. The best approximation onto trigonometric polynomials

FOURIER ANALYSIS 1. The best approximation onto trigonometric polynomials
FOURIER ANALYSIS
ERIK LØW AND RAGNAR WINTHER
1. The best approximation onto trigonometric
polynomials
Before we start the discussion of Fourier series we will review some
basic results on inner–product spaces and orthogonal projections mostly
presented in Section 4.6 of [1].
1.1. Inner–product spaces. Let V be an inner–product space. As
usual we let hu, vi denote the inner–product of u and v. The corresponding norm is given by
p
kvk = hv, vi.
A basic relation between the inner–product and the norm in an inner–
product space is the Cauchy–Scwarz inequality. It simply states that
the absolute value of the inner–product of u and v is bounded by the
product of the corresponding norms, i.e.
(1.1)
|hu, vi| ≤ kuk kvk.
An outline of a proof of this fundamental inequality, when V = Rn and
k · k is the standard Eucledian norm, is given in Exercise 24 of Section
2.7 of [1]. We will give a proof in the general case at the end of this
section.
Let W be an n dimensional subspace of V and let P : V 7→ W be the
corresponding projection operator, i.e. if v ∈ V then w ∗ = P v ∈ W is
the element in W which is closest to v. In other words,
kv − w ∗ k ≤ kv − wk for all w ∈ W.
It follows from Theorem 12 of Chapter 4 of [1] that w ∗ is characterized
by the conditions
(1.2)
hv − P v, wi = hv − w ∗ , wi = 0 for all w ∈ W.
In other words, the error v − P v is orthogonal to all elements in W .
It is a consequence of the characterization (1.2) and Cauchy–Schwarz
inequality (1.1) that the norm of P v is bounded by the norm of v, i.e.
(1.3)
kP vk ≤ kvk for all v ∈ V.
To see this simply take w = w ∗ in (1.2) to obtain
kw ∗ k2 = hw ∗ , w ∗ i = hv, w ∗i ≤ kvk kw ∗k,
Notes written for for Mat 120B, Fall 2001, Preliminary version.
1
or
kw ∗ k ≤ kvk.
Hence, since P v = w ∗ , we established the bound (1.3).
Let {u1 , u2 , . . . , un } be an orthogonal basis of the subspace W . Such
an orthogonal basis can be used to give an explicit representation of
the projection P v of v. It follows from Theorem 13 of Chapter 4 of [1]
that P v is given by
(1.4)
Pv =
n
X
cj u j
where the coefficients cj =
j=1
hv, uj i
.
kuj k2
¿From the orthogonal basis we can also derive an expression for the
norm of P v. In fact, we have
(1.5)
2
kP vk =
n
X
j=1
c2j kuj k2 .
This follows more or less directly from the orthogonality property of
the basis {u1 , u2 , . . . , un }. We have
kP vk2 = hP v, P vi
n
n
X
X
cj u j ,
ck u k i
=h
=
=
j=1
n X
n
X
k=1
cj ck huj , uk i
j=1 k=1
n
X
c2j kuj k2 .
j=1
The situation just described is very general. Some more concrete examples using orthogonal basises to compute projections are given Section
4.6 of [1]. Fourier analysis is another very important example which
fits into the general framework described above, where V is a space of
functions and W is a space of trigonometric polynomials. The Fourier
series correspons to orthogonal projections of a given function onto the
trigonometric polynomials, and the basic formulas of Fourier series can
be derived as special examples of general discussion given above.
Proof of Cauchy–Schwarz inequality (1.1). If v = 0 we have zero on
both sides of (1.1). Hence, (1.1) holds in this case. Therefore, we can
assume that v 6= 0 in the rest of the proof.
For all t ∈ R we have
ku − tvk2 ≥ 0.
2
However,
ku − tvk2 = hu − tv, u − tvi
= hu, ui − thu, vi − thv, ui + t2 hvv, vi
= kuk2 − 2thu, vi + t2 kvk2 .
Taking t = hu, vi/kvk2 we therefor obtain
0 ≤ ku − tvk2 = kuk2 −
or
hu, vi2
kvk2
hu, vi2 ≤ kuk2 kvk2 .
By taking square roots we obtain (1.1).
1.2. Fourier series. A trigonometric polynomial of order m is a function of t of the form
m
X
p(t) = a0 +
(ak cos kt + bk sin kt),
k=1
where the coefficients a0 , a1 , . . . , am , b1 , . . . , bm are real numbers. Hence,
trigonometric polynomials of order zero are simply all constant functions, while first order trigonometric polynomials are functions of the
form
p(t) = a0 + a1 cos t + b1 sin t.
A function f (t) is called periodic with period T if f (t) = f (t + T ) for
all t. Such a function is uniquely determined by its values in the interval [−T /2, T /2] or any other interval of length T . The trigonometric
polynomials are periodic with period 2π. Hence we can regard them
as elements of the space C[−π, π].
The space of trigonometric polynomials of order m will be denoted by
Tm . More precisely,
m
X
(ak cos kt+bk sin kt), ak , bk ∈ R}
Tm = {p ∈ C[−π, π] : p(t) = a0 +
k=1
C[−π, π] is equipped with a natural inner product
Z π
hf, gi =
f (t)g(t)dt
−π
The norm is then given by
Z
||f || = (
π
f 2 (t)dt)1/2
−π
2
We call this the L -norm of f on [−π, π]. Any periodic function can
be regarded as a 2π-periodic function by a simple change of variable.
Hence everything that follows can be applied to general periodic functions.
3
It is easy to see that the constant function 1, together with the functions
sin(kt) and cos(kt), 1 ≤ k ≤ m constitute an orthogonal basis for Tm .
To prove this, it is sufficient to prove that for all integers j, k the
following identities hold:
Z π
sin(jt) sin(kt) dt = 0 j 6= k,
−π
Z π
cos(jt) cos(kt) dt = 0 j 6= k,
−π
Z π
cos(jt) sin(kt) dt = 0.
−π
Notice that setting j = 0 the cos(jt) factor becomes the constant 1.
To prove the first identity, we use the trigonometric formula
1
sin(u) sin(v) = (cos(u − v) − cos(u + v)).
2
¿From this identity we obtain for j 6= k, using the fact that sin(lπ) = 0
for all integers l, that
Z
Z π
1 π
(cos((j − k)t) − cos(j + k)t) dt
sin(jt) sin(kt) dt =
2 −π
−π
1
1
=
sin((j − k)t) −
sin((j + k)t) |π−π
2(j − k)
2(j + k)
= 0.
The two other equalities follow in a similar fashion. Note that we can
also compute the norm of these functions using the same equation.
Clearly the norm of the constant function 1 is (2π)1/2 . Setting j = k
in the integrals above yields
Z π
Z
1 π
2
sin (kt) dt =
(1 − cos(2kt) dt
2 −π
−π
t
1
= −
sin(2kt) |π−π
2 4k
= π.
(This also follows easily from the fact that sin2 t + cos2 t = 1, hence
both of these functions have average value 1/2 over a whole period.)
Hence the norm of sin(kt) and cos(kt) equals π 1/2 .
The projection of a function f ∈ C[−π, π] onto Tm is the best approximation in L2 -norm of f by a trigonometric polynomial of degree m
and is denoted by Sm (t). Notice that Sm depends on the function f ,
although this is suppressed in the notation. By (1.4) the coefficients
4
are given by the formulae
Z π
1
f (t) dt
a0 =
2π −π
Z
1 π
ak =
f (t) cos kt dt
π −π
Z
1 π
bk =
f (t) sin kt dt
π −π
A central question in Fourier analysis is whether or not the approximations Sm (t) converge to f (t),i.e. if formula
∞
X
f (t) = a0 +
(ak cos kt + bk sin kt)
k=1
holds. The series on the right is called the Fourier series of f , whether
it converges to f or not.In Figure 1 we see the graphs of f (t) = t and
Sm (t) for m = 1, 3, 5, 10.
x
x
4
4
3
3
2
2
1
1
0
0
−1
−1
−2
−2
−3
−3
−4
−4
−3
−2
−1
0
x
1
2
3
−3
−2
−1
x
0
x
1
2
3
1
2
3
x
4
4
3
3
2
2
1
1
0
0
−1
−1
−2
−2
−3
−3
−4
−4
−3
−2
−1
0
x
1
2
3
−3
−2
−1
0
x
Figure 1. Fourier approximations to f (t) = t
There are three things to observe from these curves. First, the functions
Sm (t) do get closer to f (t) as m incresases, at least in a somewhat
smaller interval. Second, at the endpoints it is not possible for Sm to
converge to f , since Sm is 2π-periodic and hence has the same values
at these enpoints. In this case the value is 0. Finally, close to the
endpoints there are blips which do not approach zero, although they
do get closer to the endpoints. This is called the Gibbs phenomenon
5
and again is related to the fact that f does not have the same values
at the endpoints. We do not investigate this phenomenon further.
In Figure 2 we see the corresponding curves for f (t) = t2 . This function
has the same values at the endpoints. Notice that the blips have dissappeared and the convergence is faster, but it is still somewhat slower
at the endpoints.
x.2
x.2
12
12
10
10
8
8
6
6
4
4
2
2
0
0
−3
−2
−1
0
x
1
2
3
−3
−2
−1
x.2
0
x
1
2
3
1
2
3
x.2
12
12
10
10
8
8
6
6
4
4
2
2
0
0
−3
−2
−1
0
x
1
2
3
−3
−2
−1
0
x
Figure 2. Fourier approximations to f (t) = t2
1.3. Exercises. 1.Determine the Fourier coefficients of f (t) = et
2. a) A function f is called even if f (−t) = f (t) for all t and odd if
f (−t) = −f (t). Which polynomials are even or odd ?
b)If f ∈ C[−π, π] is even, prove that bk = 0 for all k > 0. If f is odd,
prove that ak = 0 for all k ≥ 0.
c)Prove that any f may be written as a sum of an even and an odd
function. (Hint : Let fe (t) = (f (t) + f (−t))/2 and fo (t) = (f (t) −
f (−t))/2.
d)Determine the Fourier coefficients of sinht and cosht.
3.a) If p is an odd polynomial, prove that
Z π
Z
1 π ′′
k+1 2
p(t)sin(kt) dt = (−1)
p(π) − 2
p (t)sin(kt) dt
k
k −π
−π
b) If p is an even polynomial, prove that
Z π
Z
1 π ′′
k 2 ′
p(t)cos(kt) dt = (−1) 2 p (π) − 2
p (t)cos(kt) dt
k
k −π
−π
6
c) Find the Fourier coefficients of f (t) = t3 + t2 .
4.The curves in the figures above were made by using the Matlab toolbox fourgraph. Download fourgraph from http://www.mathworks.com
(for instance by writing fourgraph in the search box). Reproduce the
curves above and try some other functions, for instance et or t3 + t2 .
2. Trigonometric polynomials
2.1. The complex exponential function. The real exponential function ex can be extended to complex values of the argument. Let
z = s + it be a complex number. If the complex exponential function satisfies the usual product rule, we must have
ez = es+it = es eit
Hence we must define the complex function f (t) = eit . If f satisfies
the usual chain rule for differentiation of the exponential function, we
′
must have f (t) = ieit = if (t). Hence, if g(t) and h(t) denote the real
and imaginary parts of f (t), i.e. f (t) = g(t) + ih(t), we get
′
′
g (t) + ih (t) = i(g(t) + ih(t))
and we must have
′
h (t) = g(t)
′
g (t) = −h(t)
which gives
′′
′
g (t) = −h (t) = −g(t)
′′
′
h (t) = g (t) = −h(t)
Since we also must have f (0) = 1, this gives g(0) = 1 and h(0) = 0.
The solutions to these equations are g(t) = cos t and h(t) = sin t.Hence
we must have eit = cos t + i sin t. We therefore define the complex
exponential function ez by
(2.1)
es+it = es (cos t + i sin t)
The complex number eit = cos t + i sin t is located on the unit circle in
the complex plane at the angle t with the real axis. It follows that the
complex number w = es+it in the point in the complex plane whose
length is es and angle is t. It follows from (2.1) that the complex
exponential function satisfies the usual addition rule for the exponent:
ez1 ez2 = ez1 +z2
From this we obtain the famous DeMoivre’s formula:
(2.2)
cos nt + i sin nt = (cos t + i sin t)n
since both sides equal eint = (eit )n . This formula contains the formulas
for cos nt and sin nt as functions of cos t and sin t and is the most
7
efficient way of expressing these formulas. It is also the easiest to
remember.
If f is a real or complex function defined on the unit circle in the complex plane, then f (eit ), as a function of t, is 2π-periodic. Conversely,
given any function f of t that is 2π-periodic, we may think of f as being
defined on the unit circle. In this way we identify 2π-periodic functions
with functions defined on the unit circle in the complex plane.
Also, if f is a function defined on [−π, π), then f extends uniquely
to a 2π-periodic function on the whole real line. This is actually true
for any function defined on a (half-open) interval of length 2π.
2.2. Complex representation of trigonometric polynomials. In
this section we shall write a trigonometric polynomial p ∈ Tm in the
form
m
X
1
p(t) = a0 +
(ak cos kt + bk sin kt).
2
k=1
1
2
Notice the factor in front of a0 . Hence if p(t) = 4 + cos t + sin t,
then a0 = 8, a1 = 1 and b1 = 1. This convention will make formulas
simpler later.( Notice also that if p is the projection of some 2π periodic
functionRf onto Tm , then all the ak -coefficients are given by the formula
π
ak = π1 −π f (t) cos kt dt, also for k = 0.) By convention, we also set
b0 = 0. For any complex number z = x + iy, the real and imaginary
parts are given by
1
ℜz = (z + z̄)
2
1
ℑz = (z − z̄)
2i
Applying this to z = eikt , we see that
(2.3)
1
1
cos kt = (eikt + e−ikt ) , sin kt = (eikt − e−ikt )
2
2i
so
m
X
1
(ak cos kt + bk sin kt)
p(t) = a0 +
2
k=1
m
X
1
1
1
= a0 +
ak (eikt + e−ikt ) + bk (eikt − e−ikt )
2
2
2i
k=1
m
X
1
1
1
(ak − ibk )eikt + (ak + ibk )e−ikt
= a0 +
2
2
2
k=1
Hence if we define
(2.4)
1
1
ck = (ak − ibk ), c−k = (ak + ibk )
2
2
8
we see that we can write this as
(2.5)
p(t) =
m
X
ck eikt .
k=−m
The constants satisfy c−k = c¯k . This will be called the complex representation of the trigonometric polynomial p(t) Conversely, any function
of the form (2.5) is a real trigonometric polynomial, provided the constants satisfy c−k = c¯k . The coefficients are then given by
ak = ck + c−k
bk = i(ck − c−k )
On the unit circle z = eit , hence if we consider p as a function on the
unit circle, we have
(2.6)
p(z) =
m
X
ck z k
k=−m
This shows the connection between real trigonometric polynomials and
complex polynomials (if we admit negative powers in a polynomial).
P
k
By P2m+1 we denote the set of complex functions of the form m
k=−m ck z .
We have shown that Tm is naturally isomorphic to the real subspace
of P2m+1 defined by the equations c−k = c¯k for k = 0, 1, .., m.If we had
allowed complex values for the coefficients ak , bk in Tm , i.e. considered
the complex vector space CTm of complex trigonometric polynomials,
the argument above shows that CTm and P2m+1 are isomorphic as
complex vector spaces.
Finally, if Sm (t) is the projection of a function f onto Tm , then the
coefficients of the complex representation of Sm (t) are given by the one
formula
Z π
1
(2.7)
ck =
f (t)e−ikt dt
2π −π
These coefficients are called the complex Fourier coefficients of f .
2.3. Sampling of functions in Tm . The vector space Tm is a real
vector space of dimension 2m + 1. It is therefore reasonable to expect
that a trigonometric polynomial p ∈ Tm is uniquely determined by its
values at 2m + 1 points. We shall see that this is the case if we divide
the interval [0, 2π] into 2m + 1 equally long pieces, i.e. consider the
points
2π
tj = j
, j = 0, 1, · · · , 2m
2m + 1
Furthermore, we shall determine the precise relationship between the
coefficients a0 , a1 , · · · , am , b1 , · · · , bm and the sampled values vj = p(tj ),
j = 0, 1, · · · , 2m.
9
To do this, we consider the evaluation map
L : Tm → R2m+1
defined by L(p) = v where the components of v are defined by evaluating p at tj , i.e. vj = p(tj ). The colums of the matrix A of L with
respect to the basis {1, cos kt, sin kt} of Tm and the standard basis of
R2m+1 are given by:
 
1
 1 

u0 = L(1) = 
 ... 
1
uk = L(cos kt) = cos kj
2π
, j = 0, 1, · · · , 2m
2m + 1
2π
vk = L(sin kt) = sin kj
, j = 0, 1, · · · , 2m
2m + 1
for k = 1, 2, · · · , m.
We shall prove that the vectors u0 , · · · , um , v1 , · · · , vm are orthogonal, hence form an orthogonal basis for R2m+1 . To prove this, we shall
need the following formula:
(2.8)
N
X
cos jα =
N
X
j=0
j=0
ℜ(eijα ) = ℜ
N
X
j=0
(eiα )j = ℜ(
1 − ei(N +1)α
)
1 − eiα
where we have used the formula for the sum of a (finite) geometric
series. Similarly, we also have
N
X
(2.9)
j=0
sin jα = ℑ(
1 − ei(N +1)α
)
1 − eiα
We shall prove that the vectors v1 , · · · , vm are orthogonal. The argument for the u-vectors is similar and also that the u’s and v’s are
′
mutually orthogonal. Therefore let k and k be two indices. The usual
trig formula for the product of two sines then gives
hvk , vk′ i =
2m
X
sin kj
j=0
2π
2π
′
sin k j
2m + 1
2m + 1
2m
=
′
2m
′
2π(k − k ) 1 X
2π(k + k )
1X
−
cos j
cos j
2 j=0
2m + 1
2 j=0
2m + 1
Setting N = 2m and α =
′
2π(k+k )
2m+1
we have
′
1 − ei(N +1)α = 1 − ei2π(k+k ) = 0
10
, hence the second sum is zero by (2.8). Also, the first sum is zero for
′
′
for k = k . This show that the vectors all are
k 6= k and equal to 2m+1
2
orthogonal and the norms are given by
ku0 k2 = 2m + 1,
2m + 1
2
Hence A is an ortogonal matrix whose inverse is given by
 1 T 
u
2 0
 uT1 


 .. 
. 

2
 T 
A−1 =
 u 

2m + 1  vm
 1T 
 . 
 .. 
T
vm
kuk k2 = kvk k2 =
In other words, if p is a trigonometric polynomial whose values vj =
p(tj ) are given by v = [vj ], then the coefficients of p are given by
1
hu0 , vi,
2m + 1
2
huk , vi, 1 ≤ k ≤ m,
ak =
2m + 1
2
bk =
hvk , vi, 1 ≤ k ≤ m
2m + 1
a0 =
2.4. Signal processing. The terms in a trigonometric polynomial
have different frequencies. In figure 1 the top curve is sin t and the
middle curve is sin 5t. We see that the middle curve oscillates five
times as fast as the top curve, i.e. the frequency is five times higher.
So the constant k that appears in the terms sin kt and cos kt measures
the frequency of the oscillation. If we draw the graph of a trigonometric polynomial p(t), then we call the curve the time representation of
p, or the representation of p in the time domain. The bottom curve is
p(t) = sin t−0.5 sin 2t+sin 5t. This curve therefore is the representation
of p in the time domain.
A trigonometric polynomial, however, is defined by
p(t) = a0 +
m
X
(ak cos kt + bk sin kt).
k=1
We call this the representation of p in the frequency domain because
this representation explicitly states how much (specified by the constants ak and bk ) p contains of oscillations with frequency k. In the
bottom curve, p contains the frequencies 1, 2 and 5, or more explicitly,
b1 = 1, b2 = −0.5 and b5 = 1, while all the other a’s and b’s are 0.
11
sin(x)
1
0.5
0
−0.5
−1
−3
−2
−1
0
x
1
2
3
1
2
3
2
3
sin(5 x)
1
0.5
0
−0.5
−1
−3
−2
−1
0
x
sin(x)−0.5 sin(2 x)+sin(5 x)
2
1.5
1
0.5
0
−0.5
−1
−1.5
−2
−3
−2
−1
0
x
1
Figure 3. Time representations of trigonometric polynomials
We saw in the previous paragraph that p also was caracterized by its
values at regularly spaced points. We may think of this as a discrete
time representation of p. If the points are chosen very close (i.e. m
is chosen big), then these points will trace out the graph. We also
saw that one could pass from the frequency representation to the time
representation and back. This is the central theme of Fourier analysis;
that functions may be described either in the time domain (through its
12
graph) or in the frequency domain, by breaking the function down into
its frequency components (i.e. components of different frequencies).
It follows from the orthogonality of the basis {1, cos kt, sin kt} that
the projection of Tm onto Tn for some n < m simply consists of omitting
the highest frequencies, i.e.
m
n
X
X
P (a0 +
ak cos kt + bk sin kt) = a0 +
ak cos kt + bk sin kt
k=1
k=1
2
So, the best (L ) approximation of a trigonometric polynomial of degree
m by a trigonometric polynomial of degree n is simply the degree n part
of the trigonometric polynomial.
2.5. Convolution in Tm . If f and g are 2π-periodic functions, we
define the convolution of f and g by
Z π
1
f ∗ g(t) =
f (s)g(t − s) ds
2π −π
It follows that we can actually perform the inegration over any interval
of length 2π and that f ∗ g also is 2π-periodic and f ∗ g = g ∗ f . The
functions can be real or complex. If f, g ∈ Tm , the convolution is most
easily described using the complex Fourier representation. Therefore,
′
assume that f (t) = eikt and g(t) = eik t . Then
Z π
′
1
f ∗ g(t) =
eiks eik (t−s) ds
2π −π
Z π
′
′
1
eik t ei(k−k )s ds
=
2π −π
Z
′
1 ik′ t π i(k−k′ )s
0
if k 6= k
=
e
ds =
e
′
eikt if k = k
2π
−π
Pm
P
′ ikt
ikt
c
e
and
f
=
Hence, if f = m
k
k=−m ck e , then
k=−m
f ∗ g(t) =
m
X
′
ck ck eikt
k=−m
Hence the complex Fourier coefficients of the convolution of f and g
equal the product of the Fourier coefficients of f and g. In other words,
convolution in the time domain corresponds to pointwise products in
the frequency domain.
If we project a trigonometric polynomial p ∈ Tm to Tn , then we
simply omit the terms of degree greater than n, i.e. we multiply the
coefficients ck by 1 for |k| ≤ n and by 0 for |k| > n. By the discussion
above, this means that we convolve p with the function
n
X
eikt
(2.10)
Dn (t) =
k=−n
13
which is called the Dirichlet kernel (of degree n). This is a finite geometric series, whose sum is
ei(2n+1)t − 1
eit − 1
ei(n+1)t − e−int
=
eit − 1
1
1
ei(n+ 2 )t − e−i(n+ 2 )t
=
t
t
ei 2 − e−i 2
sin(n + 12 )t
=
sin 12 t
Dn (t) = e−int
by (2.3).In Figure 2 we see the Dirichlet kernel for n = 1, 3, 5, 10.
sin(3.5 x)/sin(0.5 x)
sin(1.5 x)/sin(0.5 x)
7
3
6
2.5
5
2
4
1.5
3
1
2
0.5
1
0
0
−0.5
−1
−1
−2
−3
−2
−1
0
x
1
2
−3
3
−2
−1
0
x
1
2
3
1
2
3
sin(10.5 x)/sin(0.5 x)
sin(5.5 x)/sin(0.5 x)
20
10
8
15
6
10
4
5
2
0
0
−2
−3
−2
−1
0
x
1
2
−3
3
−2
−1
0
x
Figure 4. Dirichlet kernel for n = 1, 3, 5, 10
Rπ
Notice that the peaks are higher and higher. We have −π Dn (t)dt =
2π for all n. From the figures above, we see that as n increases Dn (t)
more and more concentrates a mass (i.e. integral) of 2π at the origin.
14
If f is a 2π-periodic function, we have
Sm (t) =
m
X
ck eikt
k=−m
m
X
Z π
1
=
(
f (s)e−iks ds)eikt
2π
−π
k=−m
Z π
m
X
1
f (s)(
eik(t−s) ) ds
=
2π −π
k=−m
Z π
1
=
f (s)Dm (t − s) ds
2π −π
= f ∗ Dm (t)
We shall see later that if f is differentiable, this converges to f . This
1
is easily understood from the fact that for large m, 2π
Dm (t − s) concentrates a mass of 1 at s=t.
2.6. Exercises. 1.Show that the complex Fourier coefficients of an
even/odd function are real/pure imaginary. Use exercise 3c) in Chapter
1 to find the complex Fourier coefficients of f (t) = t3 + t2
2 a)For m = 1, determine the 3x3 matrix A of the evaluation map
L : T1 → R3 described in this chapter.
) = 1 and p( 2π
) = 4.
b) Determine p ∈ T1 such that p(0) = p( 4π
3
3
c)Using MATLAB, compute the 5x5 matrix A for L : T2 → R5 . Use
this to find a trigonometric polynomial p ∈ T2 such that p(0) = p( 6π
)=
5
4π
8π
)
=
p(
)
=
p(
)
=
1.
(Plot
your
curve
to
check
the
result,
0 and p( 2π
5
5
5
for instance using fourgraph).
3. Let f be the 2π-periodic function whose values in [−π, π) is given
by f (t) = t.
a)Determine f ∗ f and draw the graph. (Requires some work!)
b)Determine the complex Fourier coefficients of f .
c)Determine Sm ∗ Sm for m = 1 and 2 and draw the graph.
4.(Parseval’s
identity. Move to Chapter 1 next year!) If p(t) = a0 +
Pm
(a
cos
kt
+ bk sin kt), show that
k=1 k
Z π
m
1X 2
1
2
2
|p(t)| dt = a0 +
(ak + b2k )
2π −π
2
k=1
5.Using fourgraph, plot the projection of f (t) = t6 − 13t4 + 36t2 − 2
onto T0 , T1 , T3 , T5 , T10 .
15
3. Orthogonal systems of functions
The basic properties of the Fourier expansion of a function f discussed above is a consequence of the orthogonality properties of the
basis functions cos(kx) and sin(kx), i.e.
Z π
cos(jx) cos(kx) dx = 0 j 6= k,
−π
Z π
sin(jx) sin(kx) dx = 0 j 6= k,
−π
Z π
cos(jx) sin(kx) dx = 0.
−π
In fact, as soon as we have a set of basis functions satisfying similar orthogonality properties, the a corresponding “generalized Fourier
expansion” can be derived.
A sequence of functions {φk (x)}∞
k=1 , defined on an interval [a, b], is
referred to as an orthogonal system of functions if
Z
(3.1)
a
b
φj (x)φk (x) dx = 0 j 6= k.
Of course, the standard trigonometric basis functions fits into this
set up if we let the interval [a, b] be [−π, π], φ2k+1 (x) = cos(kx) and
φ2k (x) = sin(kx). However, there are many more examples of orthogonal systems.
Example 3.1 Let the interval [a, b] be [−π, π] and φk (x) = sin(kx),
k ≥ 1. Then the system is orthogonal, since we already know that
Z π
sin(jx) sin(kx) dx = 0 j 6= k.
−π
Example 3.2 Let the interval [a, b] be [0, π] and φk (x) = sin(kx), k ≥ 1.
Note that we have changed the interval of definition. In order to show
that the system is orthogonal we have to show that
Z π
sin(jx) sin(kx) dx = 0 j 6= k.
0
To show this we use the identity
1
sin(u) sin(v) = (cos(u − v) − cos(u + v)).
2
16
¿From this identity we obtain for j 6= k, using the fact that sin(kπ) = 0
for all integers k, that
Z π
Z
1 π
sin(jx) sin(kx) dx =
(cos((j − k)x) − cos(j + k)x) dx
2 0
0
1
1
sin((j − k)π) −
sin((j + k)π)
=
2(j − k)
2(j + k)
= 0.
Hence, the system is orthogonal.
Example 3.3 Let the interval [a, b] be [0, π] and φk (x) = sin((k + 21 )x),
k ≥ 1. As above we have for j 6= k
Z π
Z π
1
1
φj (x)φk (x) dx =
sin((j + )x) sin((k + )x) dx
2
2
0
0
Z π
1
=
(cos((j − k)x) − cos(j + k + 1)x) dx
2 0
1
1
sin((j − k)π) −
sin((j + k + 1)π)
=
2(j − k)
2(j + k + 1)
= 0.
Therefore, the system is orthogonal.
All the examples we have studied up to now are basesd on the
trigonometric functions sin and cos. However, there also exists many
other orthogonal systems, for example orthogonal polynomials.
Example 3.4 The Legendre polynomials are orthogonal functions with
respect to the interval [−1, 1]. For k ≥ 0 these polynomials are of the
form
d
Lk (x) = αk ( )k (x2 − 1)k ,
dx
d k
) is the derivative of order
where αk is a suitable constant and ( dx
k. For the discussion here we let αk = 1, even if other scalings, like
αk = 1/2k k! is more standard.
Note that (x2 − 1)k is a polynomial of degree 2k. By differentiating
this function k times we therefore end up with a polynomial of degree
k. We have therefore established that Lk (x) is a polynomial of degree
k. In fact, from the definition above we can easily compute
L0 (x) = 1,
L1 (x) = 2x,
L2 (x) = 12x2 − 4.
Next we like to establish that the polynomials Lk are orthogonal, i.e.
we like to show that
Z 1
Lj (x)Lk (x) dx = 0 for j 6= k.
−1
17
Consider first the polynomial L2 (x). The integral of this polynomial
over [−1, 1] is given by
Z 1
L2 (x) dx = (4x3 − 4x)|1−1 = 0.
−1
Similarly, the first order moment of L2 (x) is given by
Z 1
Z 1
xL2 (x) dx =
(12x4 − 4x2 ) dx
−1
−1
4
= (3x − 2x2 )|1−1 = 1 − 1 = 0.
By combining these two results it follows that for arbritary constants
a0 and a1 we have
Z 1
Z 1
Z 1
(a0 + a1 x)L2 (x) dx = a0
L2 (x) dx + a1
xL2 (x) dx = 0.
−1
−1
−1
In orther words, the quadratic polynomial L2 (x) is orthogonal to all
linear polynomials. In particular,
Z 1
Z 1
L2 (x)L1 (x) dx =
L2 (x)L0 (x) dx = 0,
−1
−1
i.e. L2 is orthogonal to L1 and L0 .
A similar argument can be used to show that Lk is orthogonal to Lj
for j < k. Since Lj is a polynomial of degree j it is enough to show
that
Z 1
xj Lk (x) dx = 0 for all j < k.
−1
Note that the function (x2 − 1)k = (x − 1)k (x + 1)k has a root of order
k at each endpoint ±1. Therefore, if i < k then
d i 2
) (x − 1)k = 0 for x = ±1.
dx
Integration by parts therefore gives
Z 1
Z 1
d
j
x Lk (x) dx =
xj ( )k (x2 − 1)k dx
dx
−1
−1
Z 1
d
d
j d k−1 2
k 1
= x ( ) (x − 1) )|−1 −
( xj )( )k−1 (x2 − 1)k dx
dx
dx
−1 dx
Z 1
d
=−
jxj−1 ( )k−1 (x2 − 1)k dx.
dx
−1
(
By repeating this argument k times we get
Z 1
Z 1
d
j
k
x Lk (x) dx = (−1)
(( )k xj )(x2 − 1)k dx = 0,
−1
−1 dx
18
where we have used that k th derivative of xj equals zero for j < k.
Hence, we have shown that Lk is orthogonal to Lj for j < k, or, in other
words, the sequence {Lk } is an orthogonal system of polynomials.
Example 3.5 If {ψk (x)}∞
k=1 is any sequence of functions in C[a, b], then
we can produce an orthogonal sequence {φk (x)}∞
k=1 by Gram-Schmidt
orthogonalization :
φ1 (x) = ψ1 (x)
..
.
Pn−1 hψn ,φk i
φk (x)
φn (x) = ψn (x) − k=1
kφk k2
Returning to the general situation, let {φk (x)}∞
k=1 be an orthogonal system of continuous functions defined on an interval [a, b]. For each integer n ≥ 1 we let Wn be the subspace of C[a, b] spanned by {φ1 , φ2 , . . . φn },
i.e.
n
X
Wn = {w ∈ C[a, b] : w(x) =
ak φk (x), ak ∈ R}.
k=1
It is clear that
W1 ⊂ W2 ⊂ . . . ⊂ Wn ⊂ Wn+1 . . .
since an element in Wn corresponds to an element in Wn+1 with an+1 =
0.
Let Pn : C[a, b] 7→ Wn be the orthogonal projection. It follows from
(1.4) that
(3.2)
Pn f =
n
X
ak φk ,
k=1
where the coefficients ak are given by
Z b
Z b
1
2
(3.3) ak =
f (x)φk (x) dx and kφk k =
(φk (x))2 dx.
kφk k2 a
a
The finite series (3.2) is a generalized finite Fourier expansion of f ,
and the function Pn f is the best L2 -approximation of f by a function
in Wn . We observe that, just as in the case of the ordinary Fourier
expansion, the coefficients ak are independent of n. Hence, in order to
compute Pn+1 f , when Pn f is known, all we have to do is to add the
extra term an+1 φn+1 .
The coefficients ak are called the generalized Fourier coefficients of
f and the series
∞
X
ak φk (x)
k=1
is called the generalized Fourier series of f .
19
It also follows from (3.2) that
2
kPn f k =
n
X
k=1
a2k kφk k2 .
By combining this identity with (1.3) we obtain the inequality
Z b
n
X
2
2
2
ak kφk k ≤ kf k =
(f (x))2 dx,
a
k=1
where the coefficients ak are given by (3.3). We observe that the right
hand side of this inequality is independent of n. Hence, the partial
sums on the left hand side are bounded independent of n. Since all the
terms in the series are positive it therefore follows that the inequality
still holds with n = ∞, cf. Theorem 12.2.1 in [2]. In particular, the
infinite series converges. This result is usually referred to as Bessel’s
inequality. We state the result precisely as a theorem.
Theorem 3.1 (Bessel’s inequality). If f ∈ C[a, b] and {φk }∞
k=1 is an
orthogonal system of continuous functions on [a, b] then
Z b
∞
X
2
2
ak kφk k ≤
(f (x))2 dx,
(3.4)
a
k=1
where the generalized Fourier coefficients ak are given by (3.3).
Since the infinite series (3.4) converges we must have, in particular,
that the sequence {ak kφk k} converges to zero. This result will be used
later. We therefore state it as a corollary.
Corollary 3.1. Let f , {φk }∞
k=1 and {ak } be as in Theorem 3.1 above.
Then
ak kφk k −→ 0 as k → ∞.
∞
In particular, if {φk }k=1 is an orthonormal family (or more generally,
kφk k > c for all k for some c > 0), then ak → 0.
Example 3.6 If we consider the usual Fourier series
∞
X
ak cos kt + bk sin kt
a0 +
k=1
of a continuous 2π-periodic function f (t) defined for all real t, then we
have the following formula for the n-th partial sum :
n
X
ak cos kt + bk sin kt
Sn (t) = a0 +
k=1
1
= f ∗ Dn (t) =
2π
20
Z
π
−π
f (t − s)Dn (s) ds
where Dn is the Dirichlet kernel
Dn (s) =
sin(n + 21 )s
sin 21 s
We have also shown that the integral of Dn is 2π, which gives
Z π
1
f (t)Dn (s) ds
f (t) =
2π −π
Subtracting these two equations gives
Z π
1
(f (t) − f (t − s))Dn (s) ds
f (t) − Sn (t) =
2π −π
Z π
1
f (t) − f (t − s)
1
=
sin(n + )s ds
1
2π −π
2
sin 2 s
1 f (t)−f (t−s)
The function g t (s) = 2π
is continuous for s 6= 0. It is easy
sin 21 s
to see, using L’Hoptal’s rule, that it is also continuous for s = 0 if f
is differentiable at t. Furthermore, the functions φn (s) = sin(n + 21 )s
√
are orthogonal on [−π, π], by example 3.3, and kφn k = π. Hence
the integral above is just the generalized Fourier coefficients of g t with
respect to the orthogonal family φn , and therefore converges to zero,
by Corollary 3.1.
Theorem 3.2 (Convergence of Fourier series). If f is a 2π-periodic
continuous function which is differentiable at t, then
∞
X
ak cos kt + bk sin kt,
f (t) = a0 +
k=1
i.e. the Fourier series of f converges to f at t.
Example 3.7 If we use the orthononal family sin nt in C[0, π] (see example 3.2), then the generalized Fourier series of f ∈ C[0, π] is called
the sine series of f and is given by
Z
∞
X
2 π
bk sin kt and bk =
(3.5)
f (t) sin kt dt
π
0
k=1
It will converge to f (t) for all t ∈ (0, π) where f is differentiable. Since
the series is always zero at t = 0 and t = π, it will converge there if
and only if f (0) = 0 (f (π) = 0).
Example 3.8 It is also easy to see that the family {1, cos t, cos 2t, · · · }
also is orthogonal in C[0, π] . In this case the generalized Fourier series
of f ∈ C[0, π] is called the cosine series of f and is given by
Rπ
∞
X
aR0 = π1 0 f (t) dt
ak cos kt and
(3.6)
a0 +
π
ak = π2 0 f (t) cos kt dt (k > 0)
k=1
21
It will converge to f (t) for all t ∈ (0, π) where f is differentiable and
at the endpoints if f has one-sided derivatives at both endpoints.
∞
3.1. Exercises. 1. Let {φk (x)}∞
k=1 = {sin(kx)}k=1 be the orthogonal
system studied in Example 3.1 above.
a) Compute Pn f for f (x) = x.
b) Compute Pn g for g(x) = 1.
∞
2. Let {φk (x)}∞
k=1 = {sin(kx)}k=1 be the orthogonal system studied in
Example 3.2 above, i.e. the functions are considered on the interval
[0, π].
a) Compute Pn f for f (x) = x.
b) Compute Pn g for g(x) = 1.
3. a) Let f (x) be the sign–function, i.e. f (x) = 1 for x > 0, f (x) = −1
for x < 0 and f (0) = 0. Compute the ordinary Fourier expansion of f
and compare the result with the result of Exercise 2b above.
b) Let f be a function defined on [0, π]. Show that the generalized Fourier expansion of f , with respect to the orthogonal system
{sin(kx)}∞
k=1 , is exactly the ordinary Fourier expansion of the odd extension of f .
4. Let f (x) be the sign–function. Use Bessel’s inequality to show that
∞
X
1
π2
(
)2 ≤ .
2k − 1
8
k=1
5. Let {Lk (x)}∞
k=1 be the Legendre polynomials studied in Example
3.4.
a) It can be shown that the polynomials Lk (x) satisfies the recurrence
relation
(3.7)
Lk+1 (x) = 2(2k + 1)xLk (x) − 4k 2 Lk−1 (x)
for k ≥ 1. Use this relation, and the fact that L0 (x) = 1 and L1 (x) =
2x, to compute the polynomials L2 (x), L3 (x) and L4 (x).
b) Establish the relation (3.7).
References
[1] L.W. Johnson, R.D. Riess and J.T. Arnold Linear algebra, 4. edition, Addison
Wesley 1998.
[2] Tom Lindstrøm, Kalkulus, Universitetsforlaget 1995.
22
Was this manual useful for you? yes no
Thank you for your participation!

* Your assessment is very important for improving the work of artificial intelligence, which forms the content of this project

Download PDF

advertisement