Lecture Notes

9.1 Periodic Functions and Fourier Series

Processed February 27, 2026 at 09:51 AM
Download Original Handwritten Notes
PAGE 1

9.1 Periodic Functions and Fourier Series

recall Taylor series: find out how \( f(x) \) is made up of the building blocks \( x^n \)

for example, \[ e^x = 1 + x + \frac{x^2}{2!} + \frac{x^3}{3!} + \dots \]

to build \( e^x \), we need one part of 1, one part of \( x \), \( \frac{1}{2!} \) parts of \( x^2 \), etc

\[ \frac{1}{1-x} = 1 + x + x^2 + x^3 + x^4 + \dots \]

equal parts of \( x^n \)

these \( x^n \) are called the basis functions

(generalization of, for example, \( \vec{i}, \vec{j}, \vec{k} \) in \( \mathbb{R}^3 \))

for Taylor, \( f(x) \) needs to infinitely differentiable at \( x=a \)

PAGE 2

Fourier series have the basic idea: individual "parts" of \(f(x)\) but not using \(x^n\) as basis functions, but use \(\cos(nx)\) and \(\sin(nx)\)

as long as \(f(x)\) is periodic and piecewise smooth

periodic: \(f(x) = f(x+T) \rightarrow f(x)\) is periodic w/ period \(T\)

\(\sin(x) = \sin(x+2\pi) \rightarrow \sin(x)\) has period \(2\pi\)

A coordinate graph showing a periodic sine wave on an x-axis. Two consecutive peaks are marked with dots. The first peak is at x, and the second peak is at x + 2\pi. The horizontal distance between these peaks is labeled 2\pi. An annotation with arrows points to both peaks, stating f(x) = f(x + 2\pi), demonstrating that the function repeats every 2\pi units.
Figure: A coordinate graph showing a periodic sine wave on an x-axis. Two consecutive peaks are marked with dots. The first peak is at x, and the second peak is at x + 2\pi. The horizontal distance between these peaks is labeled 2\pi. An annotation with arrows points to both peaks, stating f(x) = f(x + 2\pi), demonstrating that the function repeats every 2\pi units.
\[ \sin(x) = \sin(x+2\pi) = \sin(x+4\pi) = \sin(x+k \cdot 2\pi) \]\[ k = 1, 2, 3, \dots \]\[ f(x) = f(x+T) = f(x+kT) \]

shortest such period is the fundamental period

PAGE 3

what is the fundamental period of \(\sin(3x)\)

\[ T = \frac{2\pi}{3} \]

this function is periodic with period \(2\pi\) and piecewise smooth

A coordinate graph showing a periodic square wave function f(x). The x-axis is labeled with tick marks at -\pi, 0, \pi, 2\pi, and 3\pi. The y-axis has a mark at 1. The function consists of horizontal green segments. There is a segment at y=1 from -\pi to 0 with an open circle at -\pi and a closed circle at 0. There is a segment at y=0 from 0 to \pi with an open circle at 0 and a closed circle at \pi. This pattern repeats: a segment at y=1 from \pi to 2\pi (open circle at \pi, closed at 2\pi) and a segment at y=0 from 2\pi to 3\pi (open circle at 2\pi, closed at 3\pi). There is also a segment at y=1 to the left of -\pi.
Figure: A coordinate graph showing a periodic square wave function f(x). The x-axis is labeled with tick marks at -\pi, 0, \pi, 2\pi, and 3\pi. The y-axis has a mark at 1. The function consists of horizontal green segments. There is a segment at y=1 from -\pi to 0 with an open circle at -\pi and a closed circle at 0. There is a segment at y=0 from 0 to \pi with an open circle at 0 and a closed circle at \pi. This pattern repeats: a segment at y=1 from \pi to 2\pi (open circle at \pi, closed at 2\pi) and a segment at y=0 from 2\pi to 3\pi (open circle at 2\pi, closed at 3\pi). There is also a segment at y=1 to the left of -\pi.

expressed as \[ f(x) = \begin{cases} 1 & -\pi < x \le 0 \\ 0 & 0 < x \le \pi \end{cases} \] period is \(2\pi\)

can be expressed as sum of \(\cos(nx)\) and \(\sin(nx)\)

PAGE 4

Fourier series for \( f(x) \) w/ period \( 2\pi \) defined on \( -\pi < x < \pi \) is

\( a_0 \cdot 1 = a_0 \cdot \cos(0x) \)

\[ f(x) = \frac{1}{2} a_0 + a_1 \cos(x) + a_2 \cos(2x) + a_3 \cos(3x) + \dots \]\[ + b_1 \sin(x) + b_2 \sin(2x) + b_3 \sin(3x) + \dots \]\[ = \frac{1}{2} a_0 + \sum_{n=1}^{\infty} a_n \cos(nx) + b_n \sin(nx) \]

\( a_n, b_n \) are coefficients of basis functions

( like \( \frac{f^{(n)}(a)}{n!} \) in Taylor series)

How to find \( a_n \) and \( b_n \)?

3 important properties of cosine and sine

\[ \int_{-\pi}^{\pi} \cos(\alpha x) \cos(\beta x) dx = \begin{cases} \pi & \text{if } \alpha = \beta \neq 0 \\ 2\pi & \text{if } \alpha = \beta = 0 \\ 0 & \text{if } \alpha \neq \beta \end{cases} \]
PAGE 5
\[ \int_{-\pi}^{\pi} \sin(\alpha x) \sin(\beta x) dx = \begin{cases} \pi & \text{if } \alpha = \beta \neq 0 \\ 0 & \text{if } \alpha = \beta = 0 \\ 0 & \text{if } \alpha \neq \beta \end{cases} \]

\[ \int_{-\pi}^{\pi} \cos(\alpha x) \sin(\beta x) dx = 0 \]

cosines and sines are mutually orthogonal

\[ f(x) = \frac{1}{2} a_0 + a_1 \cos(x) + a_2 \cos(2x) + \dots + a_n \cos(nx) + \dots \]

\[ + b_1 \sin(x) + b_2 \sin(2x) + \dots + b_n \sin(nx) + \dots \]

multiply both sides by \(\cos(nx)\) and integrate over \(-\pi < x < \pi\)

\[ \int_{-\pi}^{\pi} f(x) \cos(nx) dx = \int_{-\pi}^{\pi} \frac{1}{2} a_0 \cos(0x) \cos(nx) dx + \int_{-\pi}^{\pi} a_1 \cos(x) \cos(nx) dx + \dots \]

\[ + \int_{-\pi}^{\pi} b_1 \sin(x) \cos(nx) dx + \int_{-\pi}^{\pi} b_2 \sin(2x) \cos(nx) dx + \dots \]

Annotations on the terms above:

  • The term \(\int_{-\pi}^{\pi} \frac{1}{2} a_0 \cos(0x) \cos(nx) dx\) is 0 if \(n \neq 0\).
  • The term \(\int_{-\pi}^{\pi} a_1 \cos(x) \cos(nx) dx\) is 0 if \(n \neq 1\).
  • The term \(\int_{-\pi}^{\pi} b_1 \sin(x) \cos(nx) dx\) is 0.
  • The term \(\int_{-\pi}^{\pi} b_2 \sin(2x) \cos(nx) dx\) is 0.
  • The remaining terms in the series also go to 0.

\[ = \int_{-\pi}^{\pi} a_n \cos(nx) \cos(nx) dx = a_n \cdot \pi \]

PAGE 6

so,

\[ a_n = \frac{1}{\pi} \int_{-\pi}^{\pi} f(x) \cos(nx) dx \]

cosine coefficients \( n=0, 1, 2, 3, \dots \)

repeating w/ \( \sin(nx) \) and we see

\[ b_n = \frac{1}{\pi} \int_{-\pi}^{\pi} f(x) \sin(nx) dx \]

sine coefficients \( n=1, 2, 3, \dots \)

try on

\[ f(x) = \begin{cases} 1 & \text{if } -\pi < x < 0 \\ 0 & \text{if } 0 < x < \pi \end{cases} \quad \text{period } 2\pi \]

calculate \( a_0 \) separately

\[ a_0 = \frac{1}{\pi} \int_{-\pi}^{\pi} f(x) dx = \frac{1}{\pi} \int_{-\pi}^{0} 1 \cdot dx = 1 \]

\[ a_n = \frac{1}{\pi} \int_{-\pi}^{\pi} f(x) \cos(nx) dx = \frac{1}{\pi} \int_{-\pi}^{0} \cos(nx) dx \]\[ = \left. \frac{1}{n\pi} \sin(nx) \right|_{-\pi}^{0} = 0 \]

PAGE 7

\[ b_n = \frac{1}{\pi} \int_{-\pi}^{\pi} f(x) \sin(nx) dx = \frac{1}{\pi} \int_{-\pi}^{0} \sin(nx) dx \]

\[ = -\frac{1}{n\pi} \cos(nx) \Big|_{-\pi}^{0} = -\frac{1}{n\pi} (1 - \cos(n\pi)) \]

  • -1 if \(n\) is odd
  • 1 if \(n\) is even

\(\Rightarrow (-1)^n\)

\[ = -\frac{1}{n\pi} (1 - (-1)^n) \]

\[ = \begin{cases} 0 & \text{if } n \text{ is even} \\ -\frac{2}{n\pi} & \text{if } n \text{ is odd} \end{cases} \]