How does FFT work with limited data?

6 visualizzazioni (ultimi 30 giorni)
Sisi Di
Sisi Di il 24 Giu 2016
Commentato: Sisi Di il 28 Giu 2016
I've collected 2000 pairs of data at the frequency of 200Hz. I hope to figure out the noise at about 50kH, since my motor works above 41kHz. So I set my sampling frequency at 100kHz ( FFT is only effective in the first half of the sampling frequency, that is 0-50kHz.) which is much greater than my experimental sampling frequency 200Hz. Does this make sense, or will Matlab do something to my data? Otherwise, can I set the simultaneous sampling frequency as large as I need?
Thanks a lot!

Risposte (1)

Walter Roberson
Walter Roberson il 24 Giu 2016
You never tell fft() what the sampling frequency is. fft() is just given the data, together with the assumption that the points are equally spaced. You never tell fft() what the spacing is, because it doesn't need to know. The result of fft has its bins spaced apart according to a mathematical relationship between the original spacing, and the number of points of data. For plotting purposes or further calculation purposes you might have reason to figure out what that bin spacing is, given the original spacing. But you can't just lie to MATLAB and say the bins are a certain distance apart because that's what you want them to be.
There is one thing that you can do to end up with a particular frequency resolution: you can pad the input with zeros (or, equivalently, tell fft to use more points than are actually present, which has the same mathematical effect as padding with zeros.) But remember that if you do so you are declaring that the data went silent for a time -- whereas without padding the implicit declaration is that what you feed in is periodic. Actually, padding it with zeros (or given a larger N than there is data) is equivalent to declaring that [given signal followed by that much silence] is periodic). If you cannot justify the idea that your signal was followed by 499 times as much silence, then you cannot resolve down to the 100 kHz that you desire.
Sometimes what you need to do is just go back and collect data at a higher rate.
  1 Commento
Sisi Di
Sisi Di il 28 Giu 2016
Thanks a lot. I suppose I have to increase my sampling frequency or change my methology for speed measurement.

Accedi per commentare.

Categorie

Scopri di più su Fourier Analysis and Filtering in Help Center e File Exchange

Tag

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by