FFT from measured data - Scaling y-axis

40 次查看(过去 30 天)
Hi all,
As a data basis, I have measured data the volts were recorded. Matlab will now be used to perform an FFT. I have the following questions:
  • What unit do I have on the ordinate axis after the FFT? Also volts?
  • How is scaled correctly? By hiding the negative frequencies (Nyquist), I would actually have to double the amplitude, right?
  • Do I have to multiply all values of the FFT again with 20 * log10 (FFT) to represent the ordinate in db?
Here the basis Matlab Code:
load('TimeDomain.mat')%loading of the time domain signal
L=2500; %length of the signal
Fs=500000;%sampling frequency
N=2^nextpow2(L);%scale factor
t=(0:L-1)*10^-3;%time domain array
f=linspace(0,Fs/2,length(t));%frequency domain array
FFT=abs(fft(Timedomain,N));
figure(1)
plot(f,FFT(1:2500))
Thank you so much for your support!
Frank

采纳的回答

Star Strider
Star Strider 2018-5-28
编辑:Star Strider 2018-5-28
Your code appears to be correct.
I would change two lines:
FFT=abs(fft(Timedomain,N)/L); % Divide By ‘L’ To Scale For Signal Vector Length
figure(1)
plot(f,FFT(1:2500)*2) % Your Second Point Is Correct: Multiply By ‘2’ Since You Are Plotting A One-Sided Fourier Transform
The units are the same as the original (here Volts) unless you square ‘FFT’ or use the equivalent ‘20*log10(FFT)’ transformation, since the units then become power (Watts).
EDIT Corrected typographical error, clarified explanation.
  7 个评论
Star Strider
Star Strider 2018-5-30
I would just use 10*log10(FFT) if that is what you want to do.
However, I have only used dB with respect to power, so I defer to you to determine if ‘dBV’ is valid.
An easier solution would simply be to plot the amplitude on a logarithmic scale, and not do the conversion to dB at all.
David Goodmanson
David Goodmanson 2018-6-19
编辑:David Goodmanson 2018-6-19
I don't agree that 20*log10(fft) means that the expression refers to Watts. Systems like this one have linear quantities such as voltage, and squared quantities such as power ~~ V^2. The factor of 20 pertains to a linear quantity such as Volts, not Watts.
dB is always expressed in terms of the log of a ratio, and sometimes the denominator of that ratio is a specified reference level.
In terms of power, dB Watts is 10*log10(P_signal/1W).
In terms of voltage, dB Volts is 20*log10(V_signal/1V).
Suppose the voltage signal V1 is doubled to make voltage signal V2. Then the dB increase is 20*log10(V2/V1) = 6 dB. In terms of power, the dB increase is 10*log10(V2^2/V1^2) = 6 dB. It's always the same increase in dB, whether the calculation is done in terms of voltage or in terms of power.
To convert from voltage to power, you have to know something about the impedance of the system, which is most often 50 ohms. If V is expressed in rms volts, then P = Vrms^2/50.
1 Vrms (0 dBVrms) produces .02 W = 20 mW, and 10*(log10(20mW/1mW) = 13 dBmW.
So 0 dBVrms corresponds to 13 dBmW.
If it were a 1 ohm system then 0 dBVrms would correspond to 0 dBW but that assumption is uncommon.

请先登录,再进行评论。

更多回答(1 个)

Yuvaraj Venkataswamy
编辑:Yuvaraj Venkataswamy 2018-5-28
1.If you are directly use the voltage output as input, then your FFT amplitude must be in mV.

类别

Help CenterFile Exchange 中查找有关 Spectral Measurements 的更多信息

产品

Community Treasure Hunt

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

Start Hunting!

Translated by