How to plot Fresnel Diffraction?

80 visualizaciones (últimos 30 días)
Mehmet
Mehmet el 1 de Mzo. de 2014
Comentada: Matthew Fisher el 1 de Dic. de 2020
Hi I am trying to plot 1D fresnel diffraction in MATLAB. Is there any way of it?
  1 comentario
Image Analyst
Image Analyst el 1 de Mzo. de 2014
Yes. You need the equation giving the signal as a function of distance, then use plot().

Iniciar sesión para comentar.

Respuestas (1)

Prasobhkumar P. P.
Prasobhkumar P. P. el 4 de Mzo. de 2020
Editada: Prasobhkumar P. P. el 4 de Mzo. de 2020
function U = fresnel_advance(U0, dx, dy, z, lambda)
% The function receives a field U0 at wavelength lambda
% and returns the field U after distance z, using the Fresnel
% approximation. dx, dy, are spatial resolution.
%If required, Please see below code's 2d version at
k=2*pi/lambda;
[~ nx] = size(U0);
Lx = dx * nx;
dfx = 1./Lx;
u = ones(nx,1)*((1:nx)-nx/2)*dfx;
O = fftshift(fft(U0));
H = exp(1i*k*z).*exp(-1i*pi*lambda*z*(u.^2));
U = ifft2(O.*H);
  1 comentario
Matthew Fisher
Matthew Fisher el 1 de Dic. de 2020
Shouldn't H=exp(1i*k*z).*exp(-1i*pi/(lambda*z)*(u.^2))?

Iniciar sesión para comentar.

Categorías

Más información sobre Visual Exploration en Help Center y File Exchange.

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by