Section 3.3 Sums of sinusoids
Subsection 3.3.1 Sums of complex exponentials
We're going to start by considering functions that consist of finite sums of trigonometric functions. Consider a function defined by a sum of the form
The phase in a particular frequency is determined by the coefficients of the cosine and sine of that frequency. The term \(\sin 2 \pi n t\) has frequency \(n\text{,}\) and so you can think about \(f\) as a composite of pure sinusoids of frequencies \(1, \ldots, N\text{.}\) The other mysterious quantity is \(a_0/2\text{.}\) It seems odd to write an arbitrary constant this way, but it falls out of a general forumla that we're building to. (In the context of electrical circuits, the term \(a_0/2\) is called the direct current, and the sum of sinusoids is the alternating current.)
Now we can use (3.2.2) to rewrite our sum as a series of complex exponentials (for the ease of computation).
The first sum contains the positive powers and the second sum the negative. We'd like to write the series as one sum over all the powers from \(-N\) to \(N\text{.}\) So we can make the definition
and furthermore, notice that when \(n = 0\text{,}\) the formulas above give \(c_0 = \frac{a_0}{2}\text{,}\) which explains the fraction. Then we can write
First, note that the \(c_n\) are complex numbers. If the signal \(f\) is real-valued, then it must be the case that for all \(n\text{,}\) \(c_n = \cc{c_{-n}}\text{,}\) which implies that
for all \(n\text{.}\) (This does not need to be the case when \(f\) takes on complex values.)
Suppose that we have a periodic function \(f\text{,}\) and assume (for now) that \(f\) has a representation in terms of complex exponentials
Is it possible to compute the \(c_i\text{?}\) Since they are complex numbers, whatever we are going to do is going to involve dealing with that fact (which isn't really any more difficult that real calculus). There are many approaches to the next step, most involving serious algebra and calculus to arrive at the formula for computing \(c_i\text{.}\) We're going to move straight to the linear algebra perspective, which while more abstract is much more clear about why the formulas turn out the way that they do. First, we'll define perhaps the single most important vector space in mathematics.
Subsection 3.3.2 Computing \(c_n\) using linear algebra
Definition 3.3.1.
\(L^2(0,1)\) is the complex vector space of functions with the property that
\(L^2\) is an inner product space when equipped with the dot product
Functions in \(L^2\) are called square-integrable and they show up in a huge number of applications. Perhaps most importantantly, some of our favorite functions turn out to be orthogonal in \(L^2\text{.}\)
Proposition 3.3.2.
The set \(\{e^{2 \pi i n t}\}_{n = -N}^N\) is orthogonal considered as a set of vectors in \(L^2\text{.}\) That is,
whenever \(n \neq m\text{.}\)
Proof.
Suppose that \(n \neq m\text{.}\) Then
We've used the fact that \(e^{2 \pi i k} = 1\) for any integer \(k \neq 0\text{.}\) Thus, in \(L^2\text{,}\) we have \(e^{2 \pi i n t} \perp e^{2 \pi i m t}\) when \(m \neq n\text{.}\)
We can also see that
and so \(\norm{e^{2 \pi i n t}} = \sqrt{1} = 1\text{.}\)
We're going to use the theorem from linear algebra that lets us project onto the span of a set of orthogonal vectors.
Theorem 3.3.3.
If \(u\) is a vector in a vector space \(V\) and \(e_1, \ldots, e_n\) is an orthogonal set of vectors, then the projection of \(u\) onto the space \(S\) spanned by the \(e_n\) is given by the formula
where the coefficients \(c_n\) are given by the formula
If \(u \in S\text{,}\) then \(u = \sum c_n e_n\text{.}\)
So let's write the projection of a function \(f\) onto the span of the orthogonal vectors \(e^{2 \pi i n t}\text{,}\) \(n = -N, \ldots, N\text{.}\) Let \(S\) be the space of linear combinations of the \(e^{2 \pi i n t}\text{.}\)
where
But these are precisely the \(c_n\) that we need a formula to compute! Assuming that \(f\) can be written as a sum of complex exponentials is the same as assuming that \(f\) is in the space spanned by the orthogonal set. Thus, if \(f\) can be written
then the \(c_n\) can be computed via
The \(c_n\) are called Fourier coefficients.
We have one major leap left to go - we've shown that if a periodic function \(f\) has representation as a finite sum of complex exponentials that we can produce the coefficients via an integral. We do not know yet if all periodic \(f\) can be expressed this way.
Subsection 3.3.3 Fourier coefficients as a function
One of the major themes of our course is the idea of transforms, which change a function in some setting to another function in a different setting. The Fourier coefficients can be thought of as the outputs of a function \(\hat{f}\) that takes an integer \(n\) as an input and produces \(c_n\text{.}\)