function [ w, s ] = gaussian_focus( w0, s0, f, lambda ) %Focusing of Gaussian beams based on Sidney A. Self's "Focusing of %spherical Gaussian beams" Applied Optics, Vol. 22, Issue 5, pp. 658-661 (1983) % Input: lambda = wavelength; % w0 = waist before the lens; % s0 = distance of waist before lens (s>0 before lens) % f = focal length of lens (f>0 for converging lens) % Output: w = new waist; % s = position of waist from lens zR = pi*w0^2/lambda; %Rayleigh Range s = f*(1+(s0/f-1)/((s0/f-1)^2+(zR/f)^2)); %Eq. (9b) w = w0/sqrt((1-s0/f)^2+(zR/f)^2); end