Live data from Hacker News

Understanding The Fourier Transform

altdevblogaday.com

21–30 of 45 posts

Re: Understanding The Fourier Transform

#21
post #16

You can also think of the Fourier Transform as a projection (dot product) of a signal onto the space of all sinusoids. That's the explanation that made everything click for me.

I like this way of thinking about it, but I think it is not quite accurate for discrete Fourier Transforms. In this case, we're not projecting onto the space of all sinusoids, only the space of sinusoids whose period is a multiple of (1/N). We could probably prove (if we wanted to try) that those form a basis for the vector space of N-long complex vectors, so using any more sinusoids would be redundant. However, I be…

Very true, and if you want to be more specific my definition only works for finite duration continuous time signals with finite second moment. I use this definition as it also works well for understanding other transforms such as the Laplace transform.

Re: Understanding The Fourier Transform

#22
post #17

Earlier quoted context omitted.

The imaginary part of the transform.

The article uses the magnitude of the coefficients, which is computed using both the real and the imaginary part.

The phase portion isn't actually just the imaginary part, it's just the piece of information lost when one goes from real+imag -> magnitude, i.e. it's the argument of the complex number.

Re: Understanding The Fourier Transform

#23
You can also think about the Fourier Transform in terms of its physical properties.

For example, the Fourier transform is behind quantum uncertainty (dp.dx>h). Think of it this way: the inverse Fourier transform of a frequency impulse (zero extent) is a sine wave of infinite duration. Truncate the infinite sine wave and its spectrum ceases being an impulse, broadening into the shape of the windowing function used to truncate the sine wave. That is, an attempt to constrain/define time leads to a broadening in frequency, and vice versa. The uncertainty principle naturally arises from using the Fourier Transform in an environment where "you can't have infinities".

This is true of any two variables which are related by a Fourier Transform. Yes, position and momentum are related by a Fourier transform (as are energy and time).

The thinking also works for the other extreme: if you consider how a time impulse (zero extent) related to its Fourier transform, a flat spectrum of infinite extent on the frequency axis.

Re: Understanding The Fourier Transform

#24

You can also think of the Fourier Transform as a projection (dot product) of a signal onto the space of all sinusoids. That's the explanation that made everything click for me.

It is both the least squares approximation using periodic functions of this sort (i.e. the projection you mentioned), and an interpolant - a very nice combination of properties.

Re: Understanding The Fourier Transform

#25
My preferred way to think about it is in linear algebra terms: your signal of length n is an n-dimensional vector. Now you just need to change the coordinate system into fourier basis, which is made up of vectors of length n who's entries are sin/cos waves of different frequencies. The way you change basis in linear alebra is by doing a dot product with the basis vectors you want to transform to, and it's no different here... it's just a projection of your single point into fourier basis and that's all the formula says.

The fancy e^i stuff is just for mathematical beauty and compactness and should be avoided when explaining the fourier transform, imo. There's absolutely no need for it as far as the idea goes, just do the sins and coses separately.

Re: Understanding The Fourier Transform

#27

My preferred way to think about it is in linear algebra terms: your signal of length n is an n-dimensional vector. Now you just need to change the coordinate system into fourier basis, which is made up of vectors of length n who's entries are sin/cos waves of different frequencies. The way you change basis in linear alebra is by doing a dot product with the basis vectors you want to transform to, and it's no differen…

If, however, one wanted a similarly intuitive explanation of the e^i part of the story, I recommend these two articles in order. They explain the hand wavy part about complex numbers and rotation: http://betterexplained.com/articles/a-visual-intuitive-guide... http://betterexplained.com/articles/intuitive-understanding-...

Re: Understanding The Fourier Transform

#28

The Fourier Transform can also be thought of as part of Linear Algebra, because it's actually funding a representation of a given function in the basis consisting of sin and cos functions (or complex exponentials). See, the collection of non-pathological functions is a vector space. We add elements by adding the functions pointwise, we multiply by a constant in the obvious way, and the other requirements can be check…

Yup, that's how I usually picture it, change the values to a collection of sin and cos functions.

When I started explaining it to some computer science students, it helped by giving a particular example of its usefulness:

Sound is composed of waves so, when you want to send a music to a friend it's all a bunch of values like [0, 1, 2, 1, 0, -1 , -2, -1, 0, ...]. If you know they're going to look like waves (sinusoidal functions) why not just send your friend how much they look like sin or cos? The values back there were just a 2sin(x) so why not just send them the value [2]?

You could save a lot of bandwidth. You just need to "correlate" sounds with a bunch of sin or cos functions everybody agrees on :)

Bonus: you can add the phase values, 2 sin(x + phase), to get the beats just right.

Re: Understanding The Fourier Transform

#30
post #23

You can also think about the Fourier Transform in terms of its physical properties. For example, the Fourier transform is behind quantum uncertainty (dp.dx>h). Think of it this way: the inverse Fourier transform of a frequency impulse (zero extent) is a sine wave of infinite duration. Truncate the infinite sine wave and its spectrum ceases being an impulse, broadening into the shape of the windowing function used to…

http://www.youtube.com/watch?v=Znby3t3AS5s

♫♫♫

Uncertainty is not so odd as long as we're aware

position and momentum are a Fourier transform pair

So anything that tightens our precision on the one

means certainty about the other value gets undone

♫♫♫

Still, I'm not sure I approve of your suggestion to use this physical property of the universe as a basis for intuition. The reasons why quantum mechanics "works" are far, far more difficult to understand, internalize, and accept than the concepts behind the DFT which only really requires an understanding of first-semester linear algebra. In other words, I expect that the set of people who understand QM at this level but do not understand the DFT is nearly empty.

If you actually meant to go the other way (use the properties of the FT/DFT to gain an understanding of QM) then I completely agree with everything you said, of course.

Post reply on HN