有会相位恢复算法的吗?能帮我看看下面的代码错哪儿了吗?不胜感激 <!v^Df
xa[<k>r3
2d centered Fourier transform,居中的傅里叶变换 Zz'(!h Uy
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% bN`oQ.Z 4
% Citation for this code and algorithm: RFU(wek
% Tatiana Latychevskaia and Hans-Werner Fink :Ag]^ot
% "Practical algorithms for simulation and reconstruction of digital in-line holograms", f<=
#WV
% Appl. Optics 54, 2424 - 2434 (2015) EW%%W6O6
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% `(vgBz`e[
% The code is written by Tatiana Latychevskaia, 2002 +y! dU{L^
% The version of Matlab for this code is R2010b tO~DA>R
[=z1~dXKb
function [out] = FT2Dc(u0); hPE#l?H@A
~}q"M[{
[Nx, Ny] = size(1i,1j); dQVV0)z
cKEf- &~
f1 = zeros(Nx,Ny); WO?EzQ ?
,B(UkPGT
for ii = 1:Nx f ?_YdVZ
for jj = 1:Ny (C={/waJ
f1(ii,jj) = exp(1i*pi*(ii + jj)); OmQSNU.our
end BC ]^BKP
end hZ Gr/5f
<W2}^q7F^
FT = fft2(f1.*in); iA3d[%tBb
{a.{x+!5I-
out = f1.*FT; ~
'
81
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%