Rank: 2171 based on 32 downloads (last 30 days) and 1 file submitted
photo

ustc huan

E-mail

Personal Profile:

Professional Interests:

 

Watch this Author's files

 

Files Posted by ustc
Updated   File Tags Downloads
(last 30 days)
Comments Rating
28 Mar 2009 fft fft code written my me Author: ustc huan fft, signal processing 32 2
  • 1.0
1.0 | 2 ratings
Comments and Ratings on ustc's Files View all
Updated File Comment by Comments Rating
30 Mar 2009 fft fft code written my me Author: ustc huan 9000, Hal

This file is full of garbage. How is this supposed to run?

30 Mar 2009 fft fft code written my me Author: ustc huan Hanselman, Duane

Why is the Database Toolbox required? Here is what is in this file:
function xn=myfft(x)
N=length(x);%È¡Êý×鳤¶È
M=log2(N);%ÇóÊý×鳤¶ÈÒÔ2Ϊµ×µÄÃÝ
%´Ë´¦½«Êý×éxÅÅÐò³Éxtmp
%»ù±¾Ë¼Ï룺½«Ã¿Î»x(i)ÖеÄiµÄÖµ»»Ëã³É2½øÖÆ£¬Ã¿´Î½«×îµÍλȡ³ö±£´æµ½³¤¶ÈΪMµÄÊý×éÖÐ
%¸ÃÊý×éµÄ´ÓµÚMλµ½µÚ1λÅÅ¿ª¾ÍÊÇÅÅÐòºóµÄλÖõĶþ½øÖƱíʾ
%½«¸ÃÊý×é»»Ëã³ÉÊ®½øÖƵÄÊý¾ÍÊÇÐòÊýÖØÅźóµÄÐòÊýpos£¬ÔÙ½«x(i)¸³Óèxtmp(pos)
%ÓÉÓÚmatlabÖÐÊý×é´Ó1¿ªÊ¼£¬¹ÊӦΪx(pos+1)=x(i+1)
xtmp=zeros(1,N);
value=zeros(1,M);
for i=0:N-1
    repr=i;
    for t=1:1:M
        repr=bitshift(i,1-t);
        value(t)=bitand(repr,1);
    end
    pos=0;
    for k=1:1:M
        pos=pos+value(k)*2^(M-k);
    end
    xtmp(pos+1)=x(i+1);
end
%xtmp=x;

%fftÖ÷º¯Êý
%Ö÷Ҫ˼Ï룺¹²ÓÐM²ã¼ÆËã
%ÿ²ã°üÀ¨width¿é¼ÆË㣬ÿ¿é¼äÏà¾à2^iµÄ¾àÀ루iΪµÚi²ã£©
%ÿ¿é¼ÆËã°üÀ¨deepth¸öµûÐÎÔËËã
for i=1:M
    deepth=2^(i-1);
    width=2^(M-i);
    for t=1:2^i:N
        for k=1:deepth
            tmp=xtmp(t+k-1);
            wn=width*(k-1);
            xtmp(t+k-1)=tmp+exp(-j*2*pi*wn/N)*xtmp(t+k+deepth-1);
            xtmp(t+k+deepth-1)=tmp-exp(-j*2*pi*wn/N)*xtmp(t+k+deepth-1);
        end
    end
end
xn=xtmp;

Top Tags Applied by ustc
signal processing
Files Tagged by ustc
Updated   File Tags Downloads
(last 30 days)
Comments Rating
28 Mar 2009 fft fft code written my me Author: ustc huan fft, signal processing 32 2
  • 1.0
1.0 | 2 ratings
 

MATLAB Central Terms of Use

NOTICE: Any content you submit to MATLAB Central, including personal information, is not subject to the protections which may be afforded information collected under other sections of The MathWorks, Inc. Web site. You are entirely responsible for all content that you upload, post, e-mail, transmit or otherwise make available via MATLAB Central. The MathWorks does not control the content posted by visitors to MATLAB Central and, does not guarantee the accuracy, integrity, or quality of such content. Under no circumstances will The MathWorks be liable in any way for any content not authored by The MathWorks, or any loss or damage of any kind incurred as a result of the use of any content posted, e-mailed, transmitted or otherwise made available via MATLAB Central. Read the complete Terms prior to use.

Contact us at files@mathworks.com