rms correction factor for fft

조회 수: 2 (최근 30일)
Melissa
Melissa 2014년 7월 30일
편집: Melissa 2014년 8월 1일
Good Afternoon All,
I am looking to apply a correction factor to the fft for a hanning window. I have looked and have seen 2*sqrt(8/3) for most literature in matlab and have stumbled across this page (<http://mathforum.org/kb/thread.jspa?threadID=2060176&messageID=7150679#7150679>)
which says the correction factor to be 2/sqrt(2);
How can I determine which correction function to use in my code?
%Importing data file
Data=xlsread('GME_DOE_LVO_2mm_90C_DOE_run_1.xls','DOE_run=1');
TimeDomain=Data(:,2);
HPC=Data(:,4);
N=length(HPC);
dF=(TimeDomain(end)-TimeDomain(1));
FS=N/dF;
FreqRange=(0:N-1)*FS/N;
FreqRange=FreqRange';
win=hann(N,'periodic');
p=HPC.*win;
P = fft(p,N);
P = 2*sqrt(2)*P/N; %2*sqrt(2) correction error
Mag=abs(P);
Phase=angle(P)*180/pi; % in degrees
  댓글 수: 1
Matz Johansson Bergström
Matz Johansson Bergström 2014년 7월 30일
Maybe upload HPC and TimeDomain as variables instead of copy/paste in here.

댓글을 달려면 로그인하십시오.

답변 (1개)

Image Analyst
Image Analyst 2014년 7월 30일
How are you defining linear averaging? You mean like convolving with a rect function? That's the same thing as multiplying your signal spectrum by a sinc function in Fourier space, since the FT or a rect is a sinc. So just do that then inverse FT and you have your signal.

카테고리

Help CenterFile Exchange에서 Fourier Analysis and Filtering에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by