Chapter 9 Lecture 13 - Fourier Series We consider the expansion of the function f (x) of the form nπx nπx a0 + an cos + bn sin = S(x) 2 L L ∞ f (x) ∼ (9.1) n=1 where an = bn = 1 L 1 L L f (x) cos nπx L −L L f (x) sin nπx −L L dx a0 1 = 2 2L L f (x) dx = average value of f . −L dx (9.2) Note: nπx nπλ 2L (x + λ) = cos provided = 2π, λ = L L L n nπx nπ (x + 2L) = sin . Thus each of the terms and similarly sin L L of the Fourier Series S(x) on the RHS of (10.1) is a periodic function having a period 2L. As a result the function S(x) is also periodic. 1. Note that cos nπ How does this relate to f (x) which may not be periodic? The function S(x) represented by the series is known as the periodic extension of f on [−L, L]. 61 Lecture 13 - Fourier Series 2. If f (or its periodic extension) is discontinuous at a point x0 then S(x) converges to the average value of f across the discontinuity. S(x0 ) = 1 − f (x+ 0 ) + f (x0 ) 2 (9.3) −π < x < 0 0≤x≤π (9.4) Example 9.1 f (x) = 62 0 x L=π a0 = an = = = = = a2m+1 = bn = = = = 1 π 1 π 1 π π −π π 1 f (x) dx = π π x dx = 0 π 2 (9.5) f (x) cos(nx) dx −π π x cos(nx) dx 0 ⎧ ⎫ π π ⎨ ⎬ sin(nx) 1 1 x − 1. sin(nx) dx ⎭ π⎩ n 0 n 0 π 1 π sin 1 (nπ) + 2 cos(nx) π n n 0 1 n 1 2 3 4 (−1)n − 1 n − 1 −2 0 −2 0 2 (−1) πn 2 − m = 0, 1, 2, . . . π(2m + 1)2 π 1 f (x) sin(nx) dx π 1 π (9.6) (9.7) −π π x sin(nx) dx 0 ⎫ ⎧ π π ⎬ ⎨ 1 cos(nx) 1 + 1. cos(nx) dx −x ⎭ π⎩ n 0 n 0 π cos(nπ) 0. cos 0 1 1 −π + + 2 sin(nx) π n n n 0 = (−1)n+1 /n ∞ a0 an cos(nx) + bn sin(nx) + f (x) = 2 n=1 ∞ ∞ sin(nx) 2 cos (2m + 1)x π − + (−1)n+1 = 4 π (2m + 1)2 n m=0 (9.8) (9.9) n=1 63 Lecture 13 - Fourier Series 9.1 It can be useful to shift the interval of integration from [−L, L] to [c, c + 2L] Since the periodic extension fe (x)is periodic with period 2L (as are the nπx nπx basis functions cos and sin ). L L 1 L an = 1 L bn = L f (x) cos nπx L −L L f (x) sin nπx −L L 1 dx = L dx = 1 L c+2L fe (x) cos c c+2L fe (x) sin c nπx L nπx L dx (9.10) dx. (9.11) Example 9.2 Previous Example: f (x) = 0 −π < x < 0 x 0≤x≤π (9.12) 0 π < x < 2π x − 2π 2π ≤ x ≤ 3π (9.13) On [π, 3π] fe (x) = an = 1 π = 1 π = 64 1 π 3π π 3π 2π π 0 fe (x) cos(nx) dx (x − 2π) cos(nx) dx t cos(nt) dt. t = x − 2π dx = dt x = t + 2π x = π ⇒ t = −π (9.14) x = 3π ⇒ t = π since cos n(t + 2π) = cos t 9.2. COMPLEX FORM OF FOURIER SERIES 9.2 Complex Form of Fourier Series nπx nπx a0 + an cos + bn sin 2 L L ∞ f (x) = cos nπx L n=1 = e nπx nπx ei( nπx −i( nπx L ) − e L ) + e−i( L ) ; sin = 2 L 2i ∞ b nπx nπx nπx an i( nπx ) n + e L + e−i( L ) + ei( L ) − e−i( L ) 2 2i n=1 ∞ an − ibn nπx nπx an + ibn + ei( L ) + e−i( L ) (9.15) 2 2 i( nπx L ) Therefore f (x) = a0 2 = a0 2 n=1 ↑ = ↑ ↑ cn c0 ∞ cn ei( nπx L c−n ) n=−∞ an − ibn cn = 2 = = 1 2L 1 2L L −L L nπx nπx f (x) cos − i sin dx (9.16) L L f (x)e−i( nπx L ) dx b−n = −bn (9.17) −L Therefore f (x) = ∞ cn ei( nπx L ) (9.18) n=−∞ cn = 1 2L L f (x)e−i( nπx L ) dx. (9.19) −L 65 Lecture 13 - Fourier Series Example 9.3 f (x) = cn = −1 −π ≤ x < 0 L=π 1 0<x<π ⎧ ⎫ 0 π ⎨ ⎬ 1 − e−inx dx + e−inx dx ⎭ 2π ⎩ 0 −L 0 e−inx −π = = i −2 + e+inπ + e−inπ = 2πn (−in) + (9.21) π e−inx 0 1 2π − (9.20) (−in) (9.22) 0 n even (2/iπn) n odd (9.23) Therefore f (x) = 66 2 ei (2n+1)x . πi(2n + 1) n=−∞ ∞ (9.24)