fast fourier transform a bunch of smart people. outline (hopefully) finite discrete signals linear...
Post on 20-Dec-2015
238 views
TRANSCRIPT
![Page 1: Fast Fourier Transform A bunch of smart people. Outline (hopefully) Finite discrete signals Linear shift-invariant filters Impulse responses Circular](https://reader038.vdocument.in/reader038/viewer/2022102907/56649d455503460f94a2248a/html5/thumbnails/1.jpg)
Fast Fourier Transform
A bunch of smart people
![Page 2: Fast Fourier Transform A bunch of smart people. Outline (hopefully) Finite discrete signals Linear shift-invariant filters Impulse responses Circular](https://reader038.vdocument.in/reader038/viewer/2022102907/56649d455503460f94a2248a/html5/thumbnails/2.jpg)
Outline (hopefully)
• Finite discrete signals
• Linear shift-invariant filters
• Impulse responses
• Circular convolutions
• Discrete Fourier Transform
• The Fast Fourier Transform
![Page 3: Fast Fourier Transform A bunch of smart people. Outline (hopefully) Finite discrete signals Linear shift-invariant filters Impulse responses Circular](https://reader038.vdocument.in/reader038/viewer/2022102907/56649d455503460f94a2248a/html5/thumbnails/3.jpg)
Continuous signals
![Page 4: Fast Fourier Transform A bunch of smart people. Outline (hopefully) Finite discrete signals Linear shift-invariant filters Impulse responses Circular](https://reader038.vdocument.in/reader038/viewer/2022102907/56649d455503460f94a2248a/html5/thumbnails/4.jpg)
Finite signals
• Usually come from regular discretization
![Page 5: Fast Fourier Transform A bunch of smart people. Outline (hopefully) Finite discrete signals Linear shift-invariant filters Impulse responses Circular](https://reader038.vdocument.in/reader038/viewer/2022102907/56649d455503460f94a2248a/html5/thumbnails/5.jpg)
Finite signals
• Usually come from regular discretization
• Might as well think of them as vectors!
![Page 6: Fast Fourier Transform A bunch of smart people. Outline (hopefully) Finite discrete signals Linear shift-invariant filters Impulse responses Circular](https://reader038.vdocument.in/reader038/viewer/2022102907/56649d455503460f94a2248a/html5/thumbnails/6.jpg)
Discrete Fourier Transform
Complexity O(N2)
FFT is just an O(N log N) algorithm
![Page 7: Fast Fourier Transform A bunch of smart people. Outline (hopefully) Finite discrete signals Linear shift-invariant filters Impulse responses Circular](https://reader038.vdocument.in/reader038/viewer/2022102907/56649d455503460f94a2248a/html5/thumbnails/7.jpg)
Transformations on vectors
Linear (i.e., matrices)
![Page 8: Fast Fourier Transform A bunch of smart people. Outline (hopefully) Finite discrete signals Linear shift-invariant filters Impulse responses Circular](https://reader038.vdocument.in/reader038/viewer/2022102907/56649d455503460f94a2248a/html5/thumbnails/8.jpg)
Linear (i.e., matrices)
Shift invariant
(in a circular way)
Transformations on vectors
![Page 9: Fast Fourier Transform A bunch of smart people. Outline (hopefully) Finite discrete signals Linear shift-invariant filters Impulse responses Circular](https://reader038.vdocument.in/reader038/viewer/2022102907/56649d455503460f94a2248a/html5/thumbnails/9.jpg)
Closer look at shift invariance
![Page 10: Fast Fourier Transform A bunch of smart people. Outline (hopefully) Finite discrete signals Linear shift-invariant filters Impulse responses Circular](https://reader038.vdocument.in/reader038/viewer/2022102907/56649d455503460f94a2248a/html5/thumbnails/10.jpg)
Closer look at shift invariance
L is shift invariant iff
![Page 11: Fast Fourier Transform A bunch of smart people. Outline (hopefully) Finite discrete signals Linear shift-invariant filters Impulse responses Circular](https://reader038.vdocument.in/reader038/viewer/2022102907/56649d455503460f94a2248a/html5/thumbnails/11.jpg)
The canonic basis of RN
is the canonic basis for
plays the role of Dirac's delta or impulse
![Page 12: Fast Fourier Transform A bunch of smart people. Outline (hopefully) Finite discrete signals Linear shift-invariant filters Impulse responses Circular](https://reader038.vdocument.in/reader038/viewer/2022102907/56649d455503460f94a2248a/html5/thumbnails/12.jpg)
How does matrix L look like?
h is the impulse response of L
It captures all information about L!
![Page 13: Fast Fourier Transform A bunch of smart people. Outline (hopefully) Finite discrete signals Linear shift-invariant filters Impulse responses Circular](https://reader038.vdocument.in/reader038/viewer/2022102907/56649d455503460f94a2248a/html5/thumbnails/13.jpg)
How does matrix L look like?
![Page 14: Fast Fourier Transform A bunch of smart people. Outline (hopefully) Finite discrete signals Linear shift-invariant filters Impulse responses Circular](https://reader038.vdocument.in/reader038/viewer/2022102907/56649d455503460f94a2248a/html5/thumbnails/14.jpg)
How do we multiply L by v?
This is why we care about convolutions!
![Page 15: Fast Fourier Transform A bunch of smart people. Outline (hopefully) Finite discrete signals Linear shift-invariant filters Impulse responses Circular](https://reader038.vdocument.in/reader038/viewer/2022102907/56649d455503460f94a2248a/html5/thumbnails/15.jpg)
The circular convolution
Complexity O(N2)
![Page 16: Fast Fourier Transform A bunch of smart people. Outline (hopefully) Finite discrete signals Linear shift-invariant filters Impulse responses Circular](https://reader038.vdocument.in/reader038/viewer/2022102907/56649d455503460f94a2248a/html5/thumbnails/16.jpg)
What we have so far
• We discretized a continuous function turning it into a vector in RN
• We defined a class of transformations from RN to RN that we care about
• Each linear shift-invariant transformations L can be written as a circular convolution
• The convolution is with the impulse response h of the transformation L
• We can compute it in O(N2)
![Page 17: Fast Fourier Transform A bunch of smart people. Outline (hopefully) Finite discrete signals Linear shift-invariant filters Impulse responses Circular](https://reader038.vdocument.in/reader038/viewer/2022102907/56649d455503460f94a2248a/html5/thumbnails/17.jpg)
This is too abstract!
• Want to make a recording of your voice sound as if you were inside a bathroom?
• Your bathroom transform sound in a linear, shift invariant way.
• Record the sound of a clap in the bathroom.• Record your voice outside.• Convolve the two signals!
![Page 18: Fast Fourier Transform A bunch of smart people. Outline (hopefully) Finite discrete signals Linear shift-invariant filters Impulse responses Circular](https://reader038.vdocument.in/reader038/viewer/2022102907/56649d455503460f94a2248a/html5/thumbnails/18.jpg)
Easy to do in Matlab
a = wavread('bathroom-ip.wav');b = wavread('laugh.wav');a = a / max(abs(a));b = b / max(abs(b));c = conv(a, b);c = c / max(abs(c));p = audioplayer(c, 44000);play(p, [1 length(c)])
![Page 19: Fast Fourier Transform A bunch of smart people. Outline (hopefully) Finite discrete signals Linear shift-invariant filters Impulse responses Circular](https://reader038.vdocument.in/reader038/viewer/2022102907/56649d455503460f94a2248a/html5/thumbnails/19.jpg)
Better convolution strategy
F-1v F-1LF F-1vO(N)
product
LvO(N2)
vconvolution
FFT IFFT
But first...
![Page 20: Fast Fourier Transform A bunch of smart people. Outline (hopefully) Finite discrete signals Linear shift-invariant filters Impulse responses Circular](https://reader038.vdocument.in/reader038/viewer/2022102907/56649d455503460f94a2248a/html5/thumbnails/20.jpg)
Diagonalizing L
• Need a basis of eigenvectors for L. Trick is to look at P first!• Assume for now that P has distinct eigenvalues.
• If wi is an eigenvector of P, then it is also an eigenvector of L!
• Lwi is an eigenvector of P, with the same eigenvalue
• We must have
• wi is also eigenvector of L (for some other eigenvalue)
• Since P has a full set of wi, L is diagonalized by the same wi!
![Page 21: Fast Fourier Transform A bunch of smart people. Outline (hopefully) Finite discrete signals Linear shift-invariant filters Impulse responses Circular](https://reader038.vdocument.in/reader038/viewer/2022102907/56649d455503460f94a2248a/html5/thumbnails/21.jpg)
The eigenvalues of P
Indeed, P has a full set!
![Page 22: Fast Fourier Transform A bunch of smart people. Outline (hopefully) Finite discrete signals Linear shift-invariant filters Impulse responses Circular](https://reader038.vdocument.in/reader038/viewer/2022102907/56649d455503460f94a2248a/html5/thumbnails/22.jpg)
The eigenvectors wk of P
![Page 23: Fast Fourier Transform A bunch of smart people. Outline (hopefully) Finite discrete signals Linear shift-invariant filters Impulse responses Circular](https://reader038.vdocument.in/reader038/viewer/2022102907/56649d455503460f94a2248a/html5/thumbnails/23.jpg)
The eigenvectors wk of P
![Page 24: Fast Fourier Transform A bunch of smart people. Outline (hopefully) Finite discrete signals Linear shift-invariant filters Impulse responses Circular](https://reader038.vdocument.in/reader038/viewer/2022102907/56649d455503460f94a2248a/html5/thumbnails/24.jpg)
Better convolution strategy
F-1v F-1LF F-1vO(N)
product
LvO(N2)
vconvolution
FFT IFFT
Not only does F exist. It does not depend on L!
![Page 25: Fast Fourier Transform A bunch of smart people. Outline (hopefully) Finite discrete signals Linear shift-invariant filters Impulse responses Circular](https://reader038.vdocument.in/reader038/viewer/2022102907/56649d455503460f94a2248a/html5/thumbnails/25.jpg)
How do F and F-1 look like?
We can also verify that...
![Page 26: Fast Fourier Transform A bunch of smart people. Outline (hopefully) Finite discrete signals Linear shift-invariant filters Impulse responses Circular](https://reader038.vdocument.in/reader038/viewer/2022102907/56649d455503460f94a2248a/html5/thumbnails/26.jpg)
How to compute F-1v?
Finally!!!
![Page 27: Fast Fourier Transform A bunch of smart people. Outline (hopefully) Finite discrete signals Linear shift-invariant filters Impulse responses Circular](https://reader038.vdocument.in/reader038/viewer/2022102907/56649d455503460f94a2248a/html5/thumbnails/27.jpg)
The eigenvalues of L
Finally!!!
![Page 28: Fast Fourier Transform A bunch of smart people. Outline (hopefully) Finite discrete signals Linear shift-invariant filters Impulse responses Circular](https://reader038.vdocument.in/reader038/viewer/2022102907/56649d455503460f94a2248a/html5/thumbnails/28.jpg)
Discrete Fourier Transform
FFT is just an O(N log N) algorithm
![Page 29: Fast Fourier Transform A bunch of smart people. Outline (hopefully) Finite discrete signals Linear shift-invariant filters Impulse responses Circular](https://reader038.vdocument.in/reader038/viewer/2022102907/56649d455503460f94a2248a/html5/thumbnails/29.jpg)
Better convolution strategy
F-1v F-1LF F-1vO(N)
product
LvO(N2)
vconvolution
FFT IFFT
![Page 30: Fast Fourier Transform A bunch of smart people. Outline (hopefully) Finite discrete signals Linear shift-invariant filters Impulse responses Circular](https://reader038.vdocument.in/reader038/viewer/2022102907/56649d455503460f94a2248a/html5/thumbnails/30.jpg)
Fast Fourier Transform
![Page 31: Fast Fourier Transform A bunch of smart people. Outline (hopefully) Finite discrete signals Linear shift-invariant filters Impulse responses Circular](https://reader038.vdocument.in/reader038/viewer/2022102907/56649d455503460f94a2248a/html5/thumbnails/31.jpg)
Fast Fourier Transform
• Coley and Tukey, 1965
• Gauss, 1805
![Page 32: Fast Fourier Transform A bunch of smart people. Outline (hopefully) Finite discrete signals Linear shift-invariant filters Impulse responses Circular](https://reader038.vdocument.in/reader038/viewer/2022102907/56649d455503460f94a2248a/html5/thumbnails/32.jpg)
Better convolution strategy
F-1v F-1LF F-1vO(N)
product
LvO(N2)
vconvolution
FFT IFFT
![Page 33: Fast Fourier Transform A bunch of smart people. Outline (hopefully) Finite discrete signals Linear shift-invariant filters Impulse responses Circular](https://reader038.vdocument.in/reader038/viewer/2022102907/56649d455503460f94a2248a/html5/thumbnails/33.jpg)
Easy to do in Matlab
a = wavread('bathroom-ip.wav');b = wavread('laugh.wav');a = a / max(abs(a));b = b / max(abs(b));c = fftfilt(a, b);c = c / max(abs(c));p = audioplayer(c, 44000);play(p, [1 length(c)])