Fast Fourier transform FFT - Page 1
Forum section: electronics / general

author: dlopezb
author_rank: Newbie
timestamp: May 13, 2010, 08:47:07 pm
content: Hi Dave,I studied electronics over 15 years ago when Internet in Spain was just a dream so I had to deal with so many datasheet books, and it was crazy to find some items. My laboratory is really basic, but now I have a RIGOL :-) and its excellent. I always worked with analog oscilloscopes so there are so many new functionality, just unbelievable. One of this functionalities is the FFT for frequency analysis. I am not sure to understand all the power of the FFT and it would be great if you can explain how to use it and in which situations is useful.Thanks in advance and best regards,PD: Please find attached my laboratory :-)

author: hans
author_rank: Super Contributor
timestamp: May 13, 2010, 09:46:29 pm
content: FFT stands for Fast Fourier Transform. So, it's a fast way of doing Fourier Transform. Fourier Transform is used to transform a (periodic) signal between the time base (which you can see on the normal oscilloscope screen) and the frequency base (a plot where you can see all the containing frequences).If you put on a 1kHz signal on your channel and let it run a FFT it will show 1 line at 1kHz. It will also show the amplitude, which you can determine by it's height. Note that this is in the decibel scale. I think it's 0dB if your signal originally went top-top in your normal oscilloscope screen. The big advantage of this type of measuring is you can see how much noise a signal has, how your mixers and other signal transforming circuits work.For example. If you make a FM stereo coder you have 2 audio channels (the audio for the left and the right speaker) and an output (MPX channel). In the past FM has been used to be received by mono radio's. It was just connecting the received audio signal up to a speaker. If you want to send out stereo, you need 2 different channels; L and R. Because you can't just leave away the R (or the L) channel, they made a dual side band at 38kHz with L-R, the mono sound or L+R on the normal band and added a pilote tone of 19kHz (which shouldn't be of that high amplitude). It would look something like this, except the SCA band:If you would make a mixer that computes the L+R sound, the L-R sound, a 19kHz pilot tone and a DSB modulator (to make the L-R a 38kHz band where the signal folds out from the 38kHz point), you will need such a tool as FFT to verify it's functionality. We had to make this device for a college project, where it was very important to see even the smallest signals which are basically invisible on the normal scope screen. If you see a signal of -50 dB or even less in the FFT screen, that's something of 10000x as small as 0dB. Might not seem important, but it will when you are going to mix signals or amplify them.edit:I believe it was also a rule that the 38kHz was supposed to be damped, otherwise you would have to put like 25% or even more of the transmitting power into that signal. So , we did find an IC (MC1496) that could suppress the carrier, but it performed disappointing. In these terms I am speaking about a carrier signal of a few millivolts against 2Vpp of the original audio signal. We could see it on FFT screen very clearly, no way we see that on the time base. Still though, we expected the carrier signal to be in the regions of -65dB, because that's what the specified for a much higher frequency.There are a lot of books about Fourier Analysis but I won't recommended buying those. The reason is because they are all very theoretic and I think you should look for the practical usage of this first. I think you will find it a lot used in telecommunications and signal processing. Most of these books will describe a bit of it and also how it works.edit:: Oh yeah, I know that DSP book and it's indeed worth a read. It's more focussed on digital signals, but those require the same theory.

author: tecman
author_rank: Frequent Contributor
timestamp: May 13, 2010, 11:09:12 pm
content: A bit more explanation. Hans did a good job, but a few more details. Fourier series math explains that any waveform, no matter how complex, is made up of a series of sine wave signals. The amplitude, frequency and phase of each of these sine waves, when combined, will result in the final waveform.So the output of an FFT is most commonly displayed as a frequency response curve. Amplitude, or power, vs frequency. FFT, as was explained, is a mathematical method to generate this frequency plot from a signal input. FFT required far fewer calculations that the long method FDT (discrete fourier transform) and allows analyzers to plot the results in near real time.The RIGOL has FFT functionality, but it is somewhat limited. It does not display as much of the frequency spectrum as is of interest. Also the ability to get detailed information seems to be limited by the amplitude resolution.It is nice as a feature, but not overly useful for FFT analysis.Go to:http://www.home.agilent.com/agilent/facet.jspx?cc=US&lc=eng&k=an+243&sm=gand download AN 243. It is a good referencePaul

author: wd5gnr
author_rank: Regular Contributor
timestamp: May 13, 2010, 11:12:31 pm
content: As the previous poster mentioned, the FFT is a way to map the time domain to the frequency domain. So when your scope is in the "normal" mode it is plotting time (x axis) vs voltage (y axis). In FFT mode it is plotting frequency (x axis) vs magnitude (y axis).While I agree a lot of books are theoretical, there is a freebie you can download that is quite good. I got a hardcopy of it from analog devices awhile back but if you don't mind PDF:http://www.dspguide.com/Very good and very practical. However, just to use your scope, here's a few basic things:1) You can only measure to 1/2 of your sampling rate (Nyquist limit).2) Each "tick" in the frequency domain is basically a sine wave at that frequency. So if you feed a square wave (like your probe calibrator) into the FFT you will find out that a square wave is the same as a sine wave at the frequency of the square wave plus the sum of the odd harmonics (technically to infinity, but in real life, just a few harmonics added together gets you pretty square). It is instructive to use a spreadsheet or a program like SciLab or MatLab to make sine waves at say, 1kHz, 3kHz, 5kHz, 7kHz, etc. and add them together.I've attached what my calibrator looks like on the FFT. Notice on the left hand edge is just "0 Hz" garbage. Then there is a big spike at 1kHz, 3kHz, etc. The center line is on 7kHz.3) In actuality, for the transform to work you should have infinitely fine sampling that goes from the beginning of time to the end of time. But none of that is practical. So instead you have a discrete FT -- you sample at certain points for a finite period of time. That produces little errors. The "Window" is a way to make the "abrupt edges" less significant. Different windows have different characteristics (like a filter, do you want flat passband, steep skirts, or no phase shift -- pick one or two but not all 3).Rectangle is basically no window. If you set your scope up and flip through the windows you'll see the "blips" get steeper, but remember you are introducing other errors too.That's about all I can think of at the moment you NEED to know for something like this. The DSP book is worth a read. Not so much math and very practical.Al W.http://www.hotsolder.com

author: saturation
author_rank: Super Contributor
timestamp: May 14, 2010, 12:12:26 am
content: Buenas dias, nice lab! photo.Quote from: dlopezb on May 13, 2010, 08:47:07 pm

author: kc1980
author_rank: Regular Contributor
timestamp: May 14, 2010, 12:54:08 am
content: Quote from: wd5gnr on May 13, 2010, 11:12:31 pmHere's something fun to do. Feed the probe calibrator square wave into your scope. Then turn on the digital filter to low pass and adjust the cut-off frequency. You will find that the higher frequencies are what make the nice sharp corners of the square wave. Repeat using the high pass filter and see what you get.Check out this website:http://www.fourier-series.com/

author: EEVblog
author_rank: Unknown
timestamp: May 14, 2010, 03:04:54 am
content: Nice compact lab, and an analog multimeter too!I think the others covered FFT's pretty well. There will probably be a blog on it sometime in the future I'm sure.Dave.

author: migsantiago
author_rank: Frequent Contributor
timestamp: May 14, 2010, 02:30:57 pm
content: HelloImagine a dance floor. There are people dancing different songs and rhythms. Every couple is dancing at a different pace. Some couples are just so tired that they are resting on a bench, watching the others dance.If you calculated a FFT of this situation, you would separate every couple by their dance rhythm. The plot would have 2 axis, the X axis would be the rhythm and the Y axis would be the number of couples.The people that are sitting would be at the beginning of the X axis since they are not moving. Then a couple which is dancing "romance" would be next to them in the plot since "romantic" dances are slow. Then another couple that is dancing "rumba" is next in the plot. And at the very end of the X axis would be the couples that dance "break-dance"An FFT is just a separation of signals. Every signal is a sum of more simple signals. The FFT separates these simple signals and tells you their simple frequency (dance pace) and amplitude (number of couples).If you sum up these simple signals, you'll have the original signal.

author: jahonen
author_rank: Super Contributor
timestamp: May 14, 2010, 07:53:50 pm
content: Nobody mentioned that there are several caveats using scope FFT. Aliasing is one thing (it becomes much more apparent in frequency domain than in time domain), FFT is not good method for pulsed signals, sensitivity and dynamic range is low compared to real SA, you can't adjust the resolution/video bandwidth/frequency sweep speed or choose detector types etc.I seldom use FFT for serious work, and would only recommend it on signals you already know. Measuring unknown signals can be misleading. For simple measurements/sanity checks it is okay, but it is bad substitute for real (RF) spectrum analyzer, even on much more expensive scopes than Rigol. The good thing of course is that it costs nothing (comes free with the scope), so go ahead and try it out.Regards,Janne

author: chscholz
author_rank: Regular Contributor
timestamp: May 15, 2010, 02:01:43 am
content: Resolution bandwidth of the FFT inversely proportional to the time span and frequency span of the FFT is inversely proportional to the sample rate. with that can implement many of the functions of a "real" spectrum analyzer.Good medium range and high-end oscilloscopes provide spectrum analyzer software with a user interface similar to a basic spectrum analyzer.The major limitation are the 8bit samplers. If you need high dynamic range you need a "real" spectrum analyzer.ChrisQuote from: jahonen on May 14, 2010, 07:53:50 pm

author: jahonen
author_rank: Super Contributor
timestamp: May 15, 2010, 06:17:42 pm
content: Chris,I can guess whom you work for, can you give example of mid-range priced oscilloscope which has spectrum analyzer-like features like you shown?Here are some carrier closeups measured with spectrum analyzer (vertical axis is set to volts for convenience instead of dBms). In fact modern spectrum analyzers use too FFT (usually selectable between sweep and FFT modes), but the signal coming to the ADC is always heavily bandwidth-limited, so no alias will occur. So whereas scope tries to swallow the whole spectrum in one go, spectrum analyzer takes relatively small part of the spectrum to processing at any time, thus avoiding the alias even with inputs with unlimited spectrum, like steep-edged square wave.The caveats I was referring were from my personal experience. One particular application I use spectrum analyzer a lot is the EMI/EMC-problem hunting, for that I have found SA much more useful. It is easier to see 30 MHz-1 GHz bandwidth better with logarithmic scale (I don't know if any scopes support that), otherwise the whole bottom end frequency range is squeezed to just few pixels.Regards,Janne

author: chscholz
author_rank: Regular Contributor
timestamp: May 15, 2010, 09:29:43 pm
content: Thanks Janne,No disagreement, looks like you really need a spectrum analyzer for your application.Will shoot you an e-mail what mid-rage oscilloscope has a spectrum analyzer option. I don't believe it would be right for me to post specific product information, neither do I try to hide who I work for.Chris