summaryrefslogtreecommitdiff
path: root/self_gbeam_propagation.m
blob: 824be5aecefbcfdde969e4ddcfde02dad8aefef2 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
function [ w, w_pos ] = self_gbeam_propagation( w0, x_lens, f, x0, lambda )
%Beam propagation based on Sidney A. Self's "Focusing of spherical Gaussian
%beams". Applied Optics, Vol. 22, Issue 5, pp. 658-661 (1983)

n_lens = 3;

w = w0; %Initial waist
w_pos = x0; %Initial waist position

for i = 1:n_lens
    x_from_next_lens = x_lens(i) - w_pos(i);
    [w_new, s_new] = gaussian_focus(w(i), x_from_next_lens, f(i), lambda);
    w(i+1) = w_new;
    w_pos(i+1) = x_lens(i) + s_new;
end

end