aboutsummaryrefslogtreecommitdiff
path: root/gbeam_propagation_froward_only.m
diff options
context:
space:
mode:
authorEugeniy Mikhailov <evgmik@gmail.com>2013-03-20 16:53:39 -0400
committerEugeniy Mikhailov <evgmik@gmail.com>2013-03-20 16:53:39 -0400
commit99f39dc1423adc360a04344689a83d2f788aae33 (patch)
tree2731d3687b663d27fad56d97c3e20fe05a5949f9 /gbeam_propagation_froward_only.m
parent4943c1cb5d453dd08aab0ec7000f094779178c94 (diff)
downloadmode_match-99f39dc1423adc360a04344689a83d2f788aae33.tar.gz
mode_match-99f39dc1423adc360a04344689a83d2f788aae33.zip
Matt's changes to use faster beam propagator
Diffstat (limited to 'gbeam_propagation_froward_only.m')
-rw-r--r--gbeam_propagation_froward_only.m9
1 files changed, 3 insertions, 6 deletions
diff --git a/gbeam_propagation_froward_only.m b/gbeam_propagation_froward_only.m
index 2cdc1d8..afc1316 100644
--- a/gbeam_propagation_froward_only.m
+++ b/gbeam_propagation_froward_only.m
@@ -1,4 +1,4 @@
-function [q] = gbeam_propagation_froward_only(x_pos, q_in, x_in, optics_elements)
+function q = gbeam_propagation_froward_only(x_pos, q_in, x_in, optics_elements)
% calculate the 'q' parameter of the Gaussian beam propagating through optical
% 'optics_elements' only in the positive direction along 'x' axis at points 'x_pos'
% takes the gaussian beam with initial q_in parameter at x_in
@@ -8,10 +8,6 @@ function [q] = gbeam_propagation_froward_only(x_pos, q_in, x_in, optics_element
%
% all x_pos must be to the right of x_in
% x_pos must be monotonic!
-
- %Initialize q_lens (q at position of lens)
- q_lens = zeros(1,size(optics_elements,2));
-
if (any(x_pos < x_in))
error('all beam positions must be to the right of the x_in');
end
@@ -49,7 +45,8 @@ function [q] = gbeam_propagation_froward_only(x_pos, q_in, x_in, optics_element
index = (x_last_calc <= x_pos);
x=x_pos(index);
q(index)= q_after_free_space(q_last_calc,x-x_last_calc);
-
+
+
end