转载一个实现分数傅立叶变换的matlab程序,作者信息在程序中有。
S^D7} 5SZa,+] function FF=frft_PXJ(N,alpha);
hn\d{HP %matrix
i+pQ 7wx % FF is the kernel matrix of fractional Fourier transform
zR<fz % \copyright: zjliu
}"SqB{5e( % Author's email:
zjliu2001@163.com D[}^G5 Ts=sqrt(2*pi/N); t=-(N-1)/2:(N-1)/2; t=t'; t=t*Ts;
D_1O4/ variance=N/2/pi; HH=zeros(N); HH(:,1)=1; HH(:,2)=2*t;
GgnR*DVP$ for k=3:N;
a>rDJw: HH(:,k)=HH(:,k-1).*t*2-2*(k-2)*HH(:,k-2);
42p1P6d end
UvM4-M%2JN HH(:,1)=1/sqrt(sqrt(variance))*HH(:,1).*exp(-t.*t/2);
xRdx`
YY u for k=2:N;
n>7aZ1Qa HH(:,k)=exp(-t.*t/2).*HH(:,k)/sqrt(2.^(k-1)*...
cD=IFOB*GD factorial(k-1)*sqrt(variance));
sOiM/}O] end
=9W\;xE S if mod(N,2)==1;
%n GjP^ W=0:N-1; k=exp(-i*alpha*W); D=diag(k);
||.Hv[
]V* else
4=EA3`l W=0:N-2; W=cat(2,W,[N]); k=exp(-i*alpha*W); D=diag(k);
bo(w$&
VW end
TIt\ FF=Ts*HH*D*HH'*2;
M] +.xo+A % Reference:
vU5}E\Ny % by 平先军.一种新的分数阶傅立叶变换快速算法.电子学报.
-|f0;Fl % 2001(3),Vol.29:406-408.