有会相位恢复算法的吗?能帮我看看下面的代码错哪儿了吗?不胜感激 HU/4K7e`
-a>CF^tH
2d centered Fourier transform,居中的傅里叶变换 e<=Nd,v4;
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% VByA6^JR
% Citation for this code and algorithm: &F#eYEuy
% Tatiana Latychevskaia and Hans-Werner Fink $-pijBiz_
% "Practical algorithms for simulation and reconstruction of digital in-line holograms", vv2[t
% Appl. Optics 54, 2424 - 2434 (2015) $v2t6wS,"
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% MtPdpm6\
% The code is written by Tatiana Latychevskaia, 2002 AU)\ lyB
% The version of Matlab for this code is R2010b :oW 16m1`
1>\V>g9
function [out] = FT2Dc(u0); S2|pn\0V
XaE*$:
[Nx, Ny] = size(1i,1j); 'L7u`
zBq&/?
f1 = zeros(Nx,Ny); w{ _g"X
LU8[$.P
for ii = 1:Nx A =Z$H2
for jj = 1:Ny x%H,ta%
f1(ii,jj) = exp(1i*pi*(ii + jj)); YR/I<m`]}
end !PeSnO
end YW~ 9 N
)sK53O$
FT = fft2(f1.*in); wBw(T1VN
*'H\`@L
out = f1.*FT; F?FfRzZ[
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%