Get Seriesous - Pt. 1
To begin with, you may want to go back and read Fourier Transformers as that is a basic intro to what I'm going to start with. This time, however, expect a bit more rigor. As always, feel free to add comments and/or links to supplementary material as that will be useful to my friend or anyone else reading this.
Of course, you can always read the Wikipedia article on Fourier Transforms. One unfortunate aspect of Wikipedia is that it is often too mathematical for a layperson to read it and attain any sort of comprehension. On the other hand, the simple English wikipedia article isn't more helpful. I'm shooting for somewhere in the middle of the two.
The goal in taking a Fourier Transform of something is to move between the time domain (the data you see when you capture the signal) and the frequency domain. The frequency domain tells you what frequencies make up a signal. We won't get there today, though. We'll start by looking at Fourier Series. As mentioned in the Fourier Transformers post, Fourier came up with the idea that you could make any signal with an infinite number of harmonic signals. Sounds easy, but it requires some math.
So let's start at the beginning. I'm going to assume a basic knowledge of trigonometry, so hopefully you're familiar with sine and cosine functions. These are, of course, periodic functions, meaning they have a pattern that repeats at regular intervals. The amount of time they take before beginning the pattern over is T. I'm going to talk about sine, but this applies just as well to cosine. To say that a function is periodic in terms of math, we can say that f(t) = f(t+T). Take this function at t=0: f(0)=f(T). In other words, if the function begins it's pattern at time t=0, it will have the same value at time t=T. So we can say that if f(t)=sin(t) (leaving off the 'e' is shorthand), then sin(t)=sin(t+T).
In the case of the sine function, T is equal to 2π because that's how long it takes the sine function to move around a unit circle. (Remember radians? There are 2π of them in a circle.) This means f(t) = f(t + 2π).
I mentioned in the Fourier Transformers post that Fourier's big idea was to add up a bunch of sine and cosine functions in order to reconstruct a signal. It wasn't, however, just any set of them. In fact, it turns out that they have to be harmonics. That is, the period of the functions are all related. If the fundamental function has a period of T, the period of the harmonics are related by dividing the value T by an integer (whole number). Therefore, the fundamental, or first harmonic, will have a period of T, the second harmonic will have a period of T/2, the third harmonic will have a period of T/3, and so on. More generally, we can write this as Tn=To/n, where n is the number of the harmonic and To is the period of the fundamental harmonic.
Another way of looking at this is via the frequency. The frequency (f) of a sine or cosine wave is related to the period by the relationship f=2π/T. If we look at the frequency of the second harmonic, it will be two times the frequency of the first harmonic. The third harmonic will have three times the frequency of the first harmonic. And so on, ad nauseum. Likewise, we can write this more generally as fn=nfo.
Here is a visual of waves on a string to help you visualize what these functions look like (clicking on it will take you to the wikipedia article on harmonics):
In the picture, we can see that the strings are mounted to something at the end, which we can imagine as our zero point. So in the case of these waves, we can pretend they're cosine functions. If we were to imagine them mounted to something moving, say a an oscillator connected to signal generator where the peak of the wave is at the end, that would be more like a sine wave.
To wrap things up for this post, Fourier said that you can take a sum of these waves to make a signal. One way to write this may be:
or more compactly
In this second equation, we replace our infinite sum of sines and cosines with summation notation (the big sigma) and we replace the 1s, 2s, 3s that denote our harmonics with an n. But where did the a and b things come from? Those are the amplitude or strength of each harmonic. In other words, we don't just slap these waves together and say, "Voilà! I have a signal!" We only add certain amounts of each wave to get a particular signal.
In the next post, I'll cover how we arrive at the values for a and b.