有会相位恢复算法的吗?能帮我看看下面的代码错哪儿了吗?不胜感激 ~V)?>)T
%*z-PT22
2d centered Fourier transform,居中的傅里叶变换 JmOW~W
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% GZ}/leR
% Citation for this code and algorithm: 5V-jMB
% Tatiana Latychevskaia and Hans-Werner Fink %do1i W
% "Practical algorithms for simulation and reconstruction of digital in-line holograms", #T~&]|{,
% Appl. Optics 54, 2424 - 2434 (2015) 4B-yTyO
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% TSL9ax4j
% The code is written by Tatiana Latychevskaia, 2002 Nm]%
}
% The version of Matlab for this code is R2010b Di=9mHC
qJ8-9^E,L
function [out] = FT2Dc(u0); |G=[5e^s[
BH@b1}
[Nx, Ny] = size(1i,1j); PI|`vC|yy&
h ?#@~
f1 = zeros(Nx,Ny); 8
#oR/Nt
FA>1x*;c
for ii = 1:Nx =qoRS0Qa
for jj = 1:Ny (U87}}/l
f1(ii,jj) = exp(1i*pi*(ii + jj)); SFjU0*B$
end Y?Vz(udD
end GVd48 *
EZ#gp^$
FT = fft2(f1.*in); /N^~U&7
b; 9n'UX\
out = f1.*FT; }X$l\pm
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%