what are the units when we plot the absolute of fft
1 view (last 30 days)
Show older comments
Hey.
if a use the command plot(abs(fft(Data))) where Data has dimension 1xN, what do i have as units on x-axis? Is it Hz or rad/sample?
Thanks in advance
0 Comments
Answers (1)
Star Strider
on 2 Jan 2020
‘Is it Hz or rad/sample?’
Both, depending on the chosen interpretation. The ‘sampling frequency’ (‘Fs’) of the vector is by definition 1, so it could be interpreted as going from 0 Hz to Fs-1, although if it is shifted first with fftshift, it would go from -Fs/2 to +Fs/2 (or -1/2 to +1/2). Transforming that to radians would equate to (-pi to +pi).
This is the reason that it is best to use data with known sampling times, so that it is then possible to calculate a frequency vector, removing all ambiguity.
At least that is how I interpret it.
0 Comments
See Also
Categories
Find more on Fourier Analysis and Filtering in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!