Fourier Series

From Notes
Jump to navigation Jump to search

The Fourier Series of a function f(x) over an interval [a,b] is an infinite series that defines the function f as a sum of sines and cosines.

Definition

f(x)=a0+k=1akcos(2πbakx)+bksin(2πbakx)

where

a0=1baabf(x)dxak=2baabf(x)cos(2πbakx)dxbk=2baabf(x)sin(2πbakx)dx

Where ba represents the period of the function. The resulting series, if plotted beyond [a,b] would be a periodic extension of the function.

Complex Definition

Using Euler's formula, (eiθ=cosθ+isinθ), we can rewrite the definition above as

f(x)=k=ckei2πbakx

where

ck=1baabf(x)ei2πbakxdx

Even and Odd Extension Variants

By default, the Fourier series simply duplicates the function f on the interval [a,b] and shifts it by k(ba) for k. Alternatively, even and odd periodic extensions can be constructed

Even Extension

In this case, the Fourier series simulates an even function. To accomplish this, we fix the left endpoint at the origin (i.e. a=0) and construct a Fourier series with the property f(x)=f(x). This series will involve only cosine terms.

f(x)=a0+k=1akcos(πbakx)

where

a0=1b0bf(x)dxak=2b0bf(x)cos(πbkx)dx
Derivation

Let g(x) be the even periodic extension of f(x) on the interval [b,b] such that the image of g on the interval [b,0] is the image of f on the interval [0,b] mirrored about the y-axis.

We will compute the Fourier series of g(x). We begin by finding a0:

a0=1b(b)bbg(x)dx=12b(b0g(x)dx+0bg(x)dx)=12b(b0g(x)dx+abg(x)dx)u=2axdu=dx=12b0bg(x)+g(x)dx

By the symmetry of g(x) described above, we know that g(x)=f(x) for all x[a,b] and that g(x)=f(x) for all x[b,0].

a0=12b0bf(x)+f(x)dx=22b0bf(x)dx=1b0bf(x)dx


Next we find ak:

ak=2b(b)bbg(x)cos(2πb(b)kx)dx=22b)bbg(x)cos(2π2b)kx)dx=1bbbg(x)cos(πbkx)dx=1b(b0g(x)cos(πbkx)dx+0bg(x)cos(πbkx)dx)=1b(b0g(x)cos(πbk(x))dx+0bg(x)cos(πbkx)dx)=1b0bg(x)cos(πbkx)+g(x)cos(πbkx)dx=1b0bf(x)cos(πbkx)+f(x)cos(πbkx)dx=2b0bf(x)cos(πbkx)dx

Finally, we find bk with the same method as above:

bk=2b(b)bbg(x)sin(2πb(b)kx)dx=22bbbg(x)sin(2π2bkx)dx=1bbbg(x)sin(πbkx)dx

Observe that g(x) is an even function by definition, and sin(πbkx) is an odd function. Therefore their product is odd, and by symmetry, the integral of their product over the symmetric interval [b,b] is 0. Hence all sine terms in the series cancel.


Odd Extension

In this case, the Fourier series simulates an odd function. To accomplish this, we fix the left endpoint at the origin (i.e. a=0) and construct a Fourier series with the property f(x)=f(x). This series will involve only sine terms.

f(x)=k=0bksin(πbakx)

where

bk=1b0bf(x)sin(πbkx)dx
Derivation

Let g(x) be the odd periodic extension of f(x) on the interval [b,b] such that the image of g on the interval [b,0] is the image of f on the interval [0,b] rotated 180 degrees about the origin

We will compute the Fourier series of g(x). We notice right away that a0=0 and ak=0 because they are integrals of an odd function over a symmetric interval. Therefore, only the bk terms need to be computed:

bk=2b(b)bbg(x)sin(2πb(b)kx)dx=22bbbg(x)sin(2π2bkx)dx=1bbbg(x)sin(πbkx)dx=1b(b0g(x)sin(πbkx)dx+0bg(x)sin(πbkx)dx)=1b(b0g(x)sin(πbk(x))dx+0bg(x)sin(πbkx)dx)=1b0bg(x)sin(πbkx)+g(x)sin(πbkx)dx

This time, observe that both g(x) and sinx are odd functions, so g(x)=g(x) and sin(x)=sinx.

bk=1b0bf(x)sin(πbkx)+f(x)sin(πbkx)dx=2b0bf(x)sin(πbkx)dx


Simplified Interval

On the interval [π,π], the formulas simplify to

f(x)=a0+k=1akcos(kx)+bksin(kx)a0=12πππf(x)dxak=1πππf(x)cos(kx)dxbk=1πππf(x)sin(kx)dx