资源简介

基于kaiser窗的双谱线插值FFT谐波分析算法。有配套论文。

资源截图

代码片段和文件信息

clear;%Nuttall128点4-order卷积 2009-07-16
N=1024;    
f11=50.0;  
Fs=2500; 
n=0:N-1;
T=1/50;
%apl=[20.020.10.010.0500.020.000.01];%panghao
apl=[220.54.41036130.81.50.81.10.040.850.110.040.50.020.30.0050.01];
%apl=[2200100000000000000000000];
phol=[103580.5123761469756301526121015252073851602042];
ci=21;
t=n/Fs;
s=zeros(1N);
s=apl(1)*sin(2*pi*f11*t+phol(1)*pi/180);
u1=stepfun(t2*T);
for i=2:ci
    s=s+apl(i)*sin(2*pi*i*f11*t+phol(i)*pi/180).*u1;
end

a=250;
t=pi*5;
for jj=1:1:N
    window(jj) =besseli(0t*sqrt(1-(1-2*jj/(N-1))^2))/besseli(0t);
end
k=s.*window;
K=fft(kN);
K1=abs(K);
[kmax ind]=max(K1);


ai=-0.49:0.001:0.49;
k1=zeros(1length(ai));
for ii=1:1:length(ai)
    temp1=pi*sqrt(25-(-ai(ii)+0.5)^2);
    temp2=pi*sqrt(25-(-ai(ii)-0.5)^2);
    a1=(N-1)*sinh(temp1)/(besseli(0t)*temp1);
    b1=(N-1)*sinh(temp2)/(besseli(0t)*temp2);
    k1(ii)=(abs(a1)-abs(b1))/(abs(a1)+abs(b1));
end
h=polyfit(k1ai7);
be=(K1(ind+1)-kmax)/(K1(ind+1)+kmax);
al=polyval(hbe);
f0=(al+ind-1+0.5)*Fs/N

for i=1:ci
    t1=round(((i)*f0-12)*N/Fs);   
    t2=round(((i)*f0+12)*N/Fs); 
    max1=0;
    for j=t1:t2;
      if K1(j)>max1;
       max1=K1(j);
       px=j;
       an=j;
      end
    end
    y1=K1(px);
    y2=K1(px+1);
    y3=K1(px-1);
    maxc=y2;
    if y3>y2
        maxc=y3;
        an=an-1;
    end
    if maxc==y3
        t=y1;
        y1=maxc;
        y2=t;
    end
    b=(y2-y1)/(y2+y1);
    al_21(i)=polyval(hb);
    Q(i)=(3.811608+0.79465173*al_21(i)^2+0.08673112*al_21(i)^4+0.0067964*al_21(i)^6)*(y1+y2)/1024;
    f(i)=(an-1+al_21(i)+0.5)*Fs/N;
    fc(i)=(f(i)-i*50)/(i*50);
end

 属性            大小     日期    时间   名称
----------- ---------  ---------- -----  ----

     文件       1744  2014-04-10 16:46  kaiserwin.m

     文件     515935  2014-03-02 15:12  基于Kaiser窗双谱线插值FFT的谐波分析方法.pdf

----------- ---------  ---------- -----  ----

               517679                    2


评论

共有 条评论