Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    text
    copied!<blockquote> <p>1) Why does the x-axis (frequency) end at 500? How do I know that there aren't more frequencies or are they just ignored?</p> </blockquote> <p>It ends at 500Hz because that is the <a href="http://en.wikipedia.org/wiki/Nyquist_frequency" rel="noreferrer">Nyquist frequency of the signal</a> when sampled at 1000Hz. Look at this line in the Mathworks example:</p> <pre><code>f = Fs/2*linspace(0,1,NFFT/2+1); </code></pre> <p>The frequency axis of the second plot goes from 0 to <strong>Fs/2, or half the sampling frequency.</strong> The Nyquist frequency is always half the sampling frequency, because above that, <a href="http://en.wikipedia.org/wiki/Aliasing#Sampling_sinusoidal_functions" rel="noreferrer">aliasing</a> occurs: <img src="https://i.stack.imgur.com/djBW3.png" alt="Aliasing illustration"> </p> <p>The signal would "fold" back on itself, and <em>appear</em> to be some frequency at or below 500Hz.</p> <blockquote> <p>2) How do I know the frequencies are between 0 and 500? Shouldn't the FFT tell me, in which limits the frequencies are? </p> </blockquote> <p>Due to "folding" described above (the Nyquist frequency is also commonly known as the "folding frequency"), it is physically impossible for frequencies above 500Hz to appear in the FFT; higher frequencies will "fold" back and appear as lower frequencies.</p> <blockquote> <p>Does the FFT only return the amplitude value without the frequency?</p> </blockquote> <p>Yes, the MATLAB FFT function only returns one vector of amplitudes. However, they map to the frequency points you pass to it.</p> <p>Let me know what needs clarification so I can help you further.</p>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload