Professional Documents
Culture Documents
FourierSeries (Nopauses) PDF
FourierSeries (Nopauses) PDF
MA 16021
Definition
A function f (x) is said to be even if f (−x) = f (x).
The function f (x) is said to be odd if f (−x) = −f (x).
Examples:
I Sums of odd powers of x are odd: 5x3 − 3x
I Sums of even powers of x are even: −x6 + 4x4 + x2 − 3
I sin x is odd, and cos x is even
−A
The Basics Fourier series Examples
A A
The Basics Fourier series Examples
Periodic functions
Definition
A function f (x) is said to be periodic if there exists a number
T > 0 such that f (x + T ) = f (x) for every x. The smallest such
T is called the period of f (x).
Fourier series
Let p > 0 be a fixed number and f (x) be a periodic function
with period 2p, defined on (−p, p). The Fourier series of f (x) is
a way of expanding the function f (x) into an infinite series
involving sines and cosines:
∞ ∞
a0 X nπx X nπx
f (x) = + an cos( )+ bn sin( ) (2.1)
2 p p
n=1 n=1
1 p 1 p
Z Z
nπx
a0 = f (x) dx, an = f (x) cos( ) dx, (2.2)
p −p p −p p
Z p
1 nπx
bn = f (x) sin( ) dx,
p −p p
The Basics Fourier series Examples
Fourier Series
Remarks:
I To find a Fourier series, it is sufficient to calculate the
integrals that give the coefficients a0 , an , and bn and plug
them in to the big series formula, equation (2.1) above.
I Typically, f (x) will be piecewise defined.
I Big advantage that Fourier series have over Taylor series:
the function f (x) can have discontinuities!
Useful identities for Fourier series: if n is an integer, then
I sin(nπ) = 0
e.g. sin(π) = sin(2π)(= sin(3π) = sin(20π) = 0
1 n even
I cos(nπ) = (−1)n =
−1 n odd
e.g. cos(π) = cos(3π) = cos(5π) = −1,
but cos(0π) = cos(2π) = cos(4π) = 1.
The Basics Fourier series Examples
Disclaimer
Example 1
−4 −2 2 4
The Basics Fourier series Examples
Example 1
1 2
Z
nπx 2 2
bn = f (x) sin( ) dx = (1 − cos(nπ)) = (1 − (−1)n )
2 −2 2 nπ nπ
Therefore
∞
X 2 nπx
f (x) = (1 − (−1)n ) sin( )
nπ 2
n=1
4 πx 4 3πx
= sin( ) + sin( )+···
|π {z 2 } |3π {z 2 }
n=1 n=3
Example 1
−2 −1 1 2 −2 −1 1 2 −2 −1 1 2 −2 −1 1 2
N = 10 N = 20 N = 30 N = 40
−2 −1 1 2 −2 −1 1 2 −2 −1 1 2 −2 −1 1 2
The Basics Fourier series Examples
Example 1
Observations:
I As the number
of terms used increases, the
approximation gets closer and
closer to the original function
−2 −1 1 2 I The original function has
a discontinuity at x = 0. The
approximation converges to
0 there, which is the average of
the right- and left-hand limits
as x → 0.
In general, if f (x) has a discontinuity at x0 , then the
Fourier series converges to the average of
lim f (x) and lim f (x).
x→x+
0 x→x−
0
The Basics Fourier series Examples
Example 2
Let f (x) be periodic and defined on one period by the formula
(
0 −π < x < 0
f (x) = 2
x 0<x<π
π2
−2π −π π 2π
Example 2
After some calculations (which are very tedious and involve lots
of IBP),
1 2(−1)n (−1)n (2 − π 2 n2 ) − 2
a0 = π 2 , an = , bn =
3 n2 n3 π
Thus,
∞
1 2 X 2(−1)n (−1)n (2 − n2 π 2 ) − 2
f (x) = π +
2
cos(nx) + 3
sin(nx)
6 n n{zπ
|{z} n=1 | {z } | }
a0 an bn
2
The Basics Fourier series Examples
Example 2
π2
π2
2
−2π −π π 2π
π2
Notice: At x = π, the series converges to 12 (π 2 + 0) = 2 .
The Basics Fourier series Examples
Example 2