Math 201 Lecture 29: Fourier Series - ualberta.caxinweiyu/201.ev1.12w/201.ev1.… · ·...
Transcript of Math 201 Lecture 29: Fourier Series - ualberta.caxinweiyu/201.ev1.12w/201.ev1.… · ·...
Math 201 Lecture 29: Fourier Series
Mar. 21, 2012
• Many examples here are taken from the textbook. The first number in () refers to the problem numberin the UA Custom edition, the second number in () refers to the problem number in the 8th edition.
0. Review
• We have the following Sturm-Liouville theory: Consider a general eigenvalue problem
−(p(x)X ′)′+ q(x)X =λw(x)X, a<x<b (1)
with boundary conditions
α1X(a) + β1X′(a)= 0; α2X(b)+ β2X(b)= 0. (2)
The following hold true:
1. The eigenvalues are countable, and can be ordered by their sizes.
2. For each eigenvalue λn, the eigenfunction can be written as CXn.
3. The Xn’s are “orthogonal” in the following sense:
∫
a
b
Xm(x)Xn(x)w(x) dx=0 when m� n. (3)
4. The Xn’s are “complete” in the following sense: Any reasonable f(x) (for example, bounded)has exactly one representation as linear combination of Xn’s:
f(x)=∑
n
fnXn. (4)
The “=” here means
limN→∞
∫
∣
∣
∣
∣
∣
f(x)−∑
n<N
fnXn
∣
∣
∣
∣
∣
dx=0. (5)
which leads to
f(x)=∑
n
fnXn then fn=
∫
a
bf(x)Xn(x)w(x) dx∫
a
bXn(x)2w(x)dx
. (6)
• In particular, considering X ′′−KX =0 with Dirichlet and Neumann boundary conditions, we have
◦ Fourier Cosine Series:
f(x)=∑
n=0
∞
fn cos(
nπ x
L
)
(7)
with
f0=1
L
∫
0
L
f(x) dx; fn=2
L
∫
0
L
f(x) cos(
nπx
L
)
dx, for n=1, 2, 3, (8)
Or more popular form:
f(x)=a02+∑
n=1
∞
an cos(
nπx
L
)
, an=2
L
∫
0
L
f(x) cos(
nπ x
L
)
dx, n=0, 1, 2, 3, (9)
◦ Fourier Sine Series:
f(x)=∑
n=1
∞
bn sin(
nπx
L
)
with bn=2
L
∫
0
L
f(x) sin(
nπx
L
)
dx, n=1, 2, 3, (10)
1
1. Basic Information
• Fourier Expansion.
◦ Eigenvalue problem:
X ′′−KX =0, X(−L) =X(L);X ′(−L) =X ′(L). (11)
Then we have two linearly independent eigenfunctions for every eigenvalue (except the firstone 0):
cos(
nπx
L
)
, sin(
nπx
L
)
. (12)
Remark 1. Note that here we have changed things a little bit. The interval is now −L<x<L.This is to make all formulas consistent with their traditional form, and also make the connectionbetween Fourier series and Fourier Cosine/Sine series more straightforward.
Important: The interval for the integrals in all formulas are always the same as theinterval over which the eigenvalue problem is solved. Therefore, as we have changed the rangeof x to −L<x<L, all the following integrals are
∫
−L
L.
◦ Fourier Series:
Definition 2. A Fourier series is the infinite sum
a02+∑
n=1
∞{
an cosnπx
L+ bn sin
nπx
L
}
. (13)
◦ Sturm-Liouville type theory:Turns out a similar set of results hold. In particular:
− Orthogonality:∫
−L
L
cosnπx
Lcos
mπx
Ldx=
{
L n=m
0 n� m, (14)
∫
−L
L
sinnπ x
Lcos
mπx
Ldx=0, (15)
∫
−L
L
sinnπx
Lsin
mπx
Ldx=
{
L n=m
0 n� m, (16)
− Fourier Expansion.Based on these we easily get the following formulas:
f(x)∼a0
2+∑
n=1
∞{
an cosnπx
L+ bn sin
nπx
L
}
(17)
then an, bn are given by
an=1
L
∫
−L
L
f(x) cosnπ x
Ldx. n=0, 1, 2, (18)
bn=1
L
∫
−L
L
f(x) sinnπx
Ldx. n=1, 2, (19)
− Completeness:Let an, bn be given as above. Then
limN→∞
∫
−L
L∣
∣
∣
∣
∣
f(x)−
(
a02+∑
n=1
N{
an cosnπx
L+ bn sin
nπx
L
}
)∣
∣
∣
∣
∣
dx=0. (20)
• Example of Fourier Expansion:
2 Math 201 Lecture 29: Fourier Series
Example 3. (10.3.9; 10.3 9) Compute the Fourier series for
f(x)= x, −π <x<π. (21)
Solution. We have L= π. Now we compute the coefficients.
◦ First
a0=1
π
∫
−π
π
x dx=0; (22)
◦ Next
an =1
π
∫
−π
π
x cos (nx) dx
=1
nπ
∫
−π
π
x dsin (nx)
=1
nπ
[
x sin (nx)N −ππ −
∫
−π
π
sin (nx) dx
]
= 0. (23)
◦ Finally
bn =1
π
∫
−π
π
x sin (nx) dx
= −1
nπ
∫
−π
π
x dcos (nx)
= −1
nπ
[
x cos (nx)N −ππ −
∫
−π
π
cos (nx) dx
]
= −1
nπ[π (−1)
n− (−π) (−1)
n]
= −2 (−1)
n
n
=2 (−1)
n+1
n. (24)
Summarizing, the Fourier expansion for x is
x∼∑
n=1
∞
2 (−1)n+1
nsin (nx). (25)
• Pointwise Convergence.
◦ Periodic Extension.Let f(x) be defined for −L<x<L. We can write down its Fourier series expansion
a02+∑
n=1
∞{
an cosnπ x
L+ bn sin
nπ x
T
}
(26)
Now:
1. Recall that the “completeness” property does not guarantee
f(x0)=a0
2+∑
n=1
∞{
an cosnπx0
L+ bn sin
nπ x0
T
}
(27)
for all x0.Therefore we can set
F (x) =a02+∑
n=1
∞{
an cosnπ x
L+ bn sin
nπ x
T
}
(28)
in a pointwise sense, that is, given x, the value of F (x) is obtained by adding up infinitelymany numbers
a02+∑
n=1
∞{
an cosnπx
L+ bn sin
nπx
T
}
. (29)
Mar. 21, 2012 3
2. Observe that F (x) is clearly periodic with period 2L:
F (x+2L) =a02+∑
n=1
∞ {
an cosnπ (x+2L)
L+ bn sin
nπ (x+2L)
T
}
=a0
2+∑
n=1
∞{
an cos(
nπ x
L+2nπ
)
+ bn sin(
nπ x
T+2nπ
)}
=a0
2+∑
n=1
∞{
an cosnπx
L+ bn sin
nπx
T
}
= F (x). (30)
Therefore it makes sense to define the periodic extension of f by setting
f̃ (x+2nL)= f(x), n=1,−1, 2,−2, 3,−3, (31)
and study the relation between f̃ (x) and F (x).It turns out that this extension is crucial in understanding the pointwise convergence of
Fourier series.
◦ Pointwise convergence:
Remark 4. Recall that a function is “piecewise continuous” on [a, b] if it is continuous at everypoint in [a,b] except possibly for a finite number of points at which f has a “jump discontinuity”,that is f(x+), f(x−) both exist but are not equal.
Recall that
f(x+)= limh>0,h→0
f(x+ h), f(x−) = limh<0,h→0
f(x+ h)= limh>0,h→0
f(x−h). (32)
Theorem 5. (Pointwise convergence) If f and f ′ are piecewise continuous on [−L, L],and let f̃ be the periodic extension of f, and let
a0
2+∑
n=1
∞{
an cosnπ x
L+ bn sin
nπ x
L
}
(33)
be the Fourier expansion of f.Then we have
a0
2+∑
n=1
∞{
an cosnπ x
L+ bn sin
nπ x
L
}
=1
2
[
f̃ (x+)+ f̃ (x−)]
. (34)
Back to f(x):
a0
2+∑
n=1
∞{
an cosnπx
L+ bn sin
nπx
L
}
=1
2[f(x+)+ f(x−)] (35)
for all −L<x<L, while at x=±L, we have
a0
2+∑
n=1
∞{
an cosnπx
L+ bn sin
nπx
L
}
=1
2[f(−L+)+ f(L−)]. (36)
◦ Rules of thumb:The above theorem says:
− If f is continuous at x0, then
a02+∑
n=1
∞{
an cosnπx0
L+ bn sin
nπ x0
L
}
= f(x0) (37)
− If f has a jump (from fleft to fright) at x0, then
a02+∑
n=1
∞{
an cosnπx0
L+ bn sin
nπx0
L
}
=1
2[fleft+ fright]. (38)
4 Math 201 Lecture 29: Fourier Series
◦ Procedure for determining pointwise convergence for Fourier expansion: Given f(x) over −L<
x<L.
1. Extend f(x) periodically.
2. Use “rules of thumb” to decide the values its Fourier expansion converges to.
It should be emphasized that to determine the values of Fourier expansion sums, the coefficientsof the actual Fourier expansion does not need to be computed.
◦ Examples.
Example 6. (10.3.17; 10.3 17) Consider the Fourier series for f(x) with period 2 π andf(x) =x for −π <x<π. f is continuous for −π <x<π but f(π− )= π � −π= f(−π+). Asa consequence its Fourier series will converge to f̃ with period 2π and
f̃ (x)=
{
x −π <x<π
0 x=±π(39)
Example 7. (10.3.19; 10.3 19) Consider the Fourier series for f(x) with period 4 and
f(x)=
{
1 −2<x< 0x 0<x< 2
. (40)
We see that f is continuous for −2<x< 0 and 0<x< 2, while has jump discontinuity at −2,
0, 2. As a consequence its Fourier series converges to f̃ with period 4 and
f̃ (x)=
1 −2<x< 01/2 x=0x 0<x< 23/2 x=±2
. (41)
2. More Examples
Example 8. (10.3.11; 10.3 11) Compute the Fourier series for
f(x)=
{
1 −2<x< 0x 0<x< 2
. (42)
Solution. Clearly L=2 andnπx
Tbecomes
nπx
2. We compute
• first
a0=1
2
∫
−2
2
f(x) dx=1
2
∫
−2
0
dx+1
2
∫
0
2
x dx=2� a02= 1; (43)
• next
an =1
2
∫
−2
2
f(x) cos(
nπx
2
)
dx
=1
2
∫
−2
0
cos(
nπx
2
)
dx+1
2
∫
0
2
x cos(
nπ x
2
)
dx
=1
nπsin(
nπx
2
)N −20 +
1
nπ
∫
0
2
x dsin(
nπx
2
)
= 0+1
nπ
[
x sin(
nπ x
2
)N 02−∫0
2
sin(
nπx
2
)
dx
]
=1
nπ
2
nπcos(
nπ x
2
)N 02=
2
(nπ)2[(−1)
n− 1]; (44)
Mar. 21, 2012 5
• and finally
bn =1
2
∫
−2
2
f(x) sin(
nπ x
2
)
dx
=1
2
∫
−2
0
sin(
nπ x
2
)
dx+1
2
∫
0
2
x sin(
nπx
2
)
dx
= −1
nπcos(
nπx
2
)N −20 −
1
nπ
∫
0
2
x dcos(
nπ x
2
)
= −1
nπ[1− cos (−nπ)]−
1
nπ
[
x cos(
nπx
2
)N 02− ∫0
2
cos(
nπ x
2
)
dx
]
=1
nπ[(−1)
n− 1]−
1
nπ
[
2 (−1)n−
2
nπsin(
nπ x
2
)N 02 ]= −
1
nπ[(−1)
n+1]. (45)
Summarizing, we have
f(x)=
{
1 −2<x< 0x 0<x< 2
∼ 1+∑
n=1
∞
2
(nπ)2[(−1)
n− 1] cos
(
nπ x
2
)
−1
nπ[(−1)
n+1] sin
(
nπx
2
)
. (46)
3. Notes and Comments
• General Sturm-Liouville theory for periodic boundary conditions is more involved. In particular,eigenvalues/eigenfunctions only exist for
−(p(x)X ′)′+ q(x)X =λw(x)X, a<x<b (47)
when p(x) satisfies p(a) = p(b). Try solve
y ′′− 2 y ′+ y=λ y, y(0)= y(1), y ′(0)= y ′(1). (48)
and show that there is no eigenvalue.In fact, any interested can try to show that for the following problem
y ′′− a y ′+ b y=λ y, y(0)= y(L), y ′(0)= y ′(L) (49)
where a, b are constants, eigenvalues exist when and only when a=0.
◦ Method 1: Write down general solution formulas and show that C1 = C2 = 0 no matter whatvalue λ takes.
◦ Method 2: Multiply the equation by y ′ and integrate.
• (Gibbs phenomenon, 10.3.39) When jump discontinuities are present, the convergence aroundthem suffers from the so-called “Gibbs phenomenon”, that is, the partial sum
a02+∑
1
N{
an cosnπx
T+ bn sin
nπx
T
}
(50)
always overshoot f by approximately 9% of the size of the jump (that is for any f it’s always 9%!).As a consequence the convergence is not uniform – which means it may be misleading to use the graphof the partial sum as an indicator of what the actually function looks like.
• Uniform convergence, differentiation, integration.Gibbs phenomenon disappears as soon as the function is continuous everywhere. In fact, in this
case the convergence is uniform:
Theorem 9. (Uniform convergence of Fourier series) Let f be a continuous functions on(−∞,∞) and periodic of period 2T. If f ′ is piecewise continuous on [−T ,T ], then the Fourier seriesfor f converges uniformly to f on [−T , T ] and hence on any interval. That is, for each ε > 0, thereexists an integer N0 (that depends on ε) such that
∣
∣
∣
∣
∣
f(x)−
[
a0
2+∑
1
N{
an cosnπ x
T+ bn sin
nπx
T
}
]∣
∣
∣
∣
∣
<ε (51)
6 Math 201 Lecture 29: Fourier Series
for all N >N0 and all x∈ (−∞,∞).
For f with appropriate continuity/smoothness, we can differentiate and integrate term by term.
Theorem 10. (Differentiation and Integration)
◦ Let f(x) be continuous on (−∞, ∞) and 2 T-periodic. Let f ′(x) and f ′′(x) be piecewisecontinuous on [−T ,T ]. Then the Fourier series of f ′(x) can be obtained from that of f throughtermwise differentiation.
◦ Let f(x) be piecewise continuous on [−T ,T ]. Then we can integrate its Fourier series termwise.
Remark 11. Note that the integration of a Fourier series is not a Fourier series anymore.
Example 12. (10.3.25 b)) Find the functions represented by the series obtained by the termwiseintegration of the given series from −π to x.
4
π
∑
n=0
∞
sin (2n+1)x
(2n+1)∼ f(x) (52)
with
f(x)=
{
−1 −π <x< 01 0<x<π
. (53)
Solution. We know that the integrated series represents
∫
−π
x
f(x) dx=
∫
−π
x
−1 dx −π <x< 0
∫
−π
0
−1 dx+
∫
0
x
dx 0<x<π
=
{
−(x+ π) −π <x< 0−π+x 0<x<π
= |x| − π. (54)
• Complex form of Fourier Series.Recall that eiθ= cosθ+ sinθ which leads to
cosθ=eiθ+ e−iθ
2, sin θ=
eiθ− e−iθ
2 i. (55)
Thus we can write
a0
2+∑
n=1
∞{
an cosnπx
T+ bn sin
nπ x
T
}
=a0
2+∑
n=1
∞
an
2
(
einπx
T + e−i
nπx
2
)
+∑
n=1
∞
bn
2 i
(
einπx
T − e−i
nπx
2
)
=a02+∑
n=1
∞
an− i bn2
einπx
T +an+ i bn
2e−i
nπx
T . (56)
If we set c0=a0
2, cn=
an − i bn
2, c−n=
an+ i bn
2for n=1, 2, 3, then we have
a0
2+∑
n=1
∞{
an cosnπ x
T+ bn sin
nπ x
T
}
=∑
−∞
∞
cn einπx
T . (57)
Now we compute
cn=an− i bn
2=
1
2T
∫
−T
T
f(x)[
cosnπx
T− i sin
nπ x
T
]
dx=1
2T
∫
−T
T
f(x) e−i
nπx
T dx, (58)
and similarly
c−n=1
2T
∫
−T
T
f(x) einπx
T . (59)
Summarizing, we have the complex Fourier series:
f(x)∼∑
−∞
∞
cn einπx
T , cn=1
2T
∫
−T
T
f(x) e−i
nπx
T dx. (60)
Mar. 21, 2012 7