diff --git a/src/new/tutorials/FTE_map_preparation_03.m b/src/new/tutorials/FTE_map_preparation_03.m index 789b27d735a340d7c270bd8b45e56b952ffa93e9..e1de0b80377df6aef4f7109cebffd8465702a63a 100644 --- a/src/new/tutorials/FTE_map_preparation_03.m +++ b/src/new/tutorials/FTE_map_preparation_03.m @@ -25,12 +25,10 @@ map = FT_recenter_mirror_map(map); map = FT_remove_elements_outside_map(map); % Removing zernike curvature -[map,zc] = FT_remove_zernike_curvatures_from_map(map,'constant'); +[map,A,Rc] = FT_remove_zernike_curvatures_from_map(map,'constant'); -% Calculate equivalent radius of curvature -R = map.xstep*(FT_find_map_radius(map,'max')); -A = FT_get_zernike_coefficient(zc,2,0); -OF = FT_zernike_optical_features(A,R,2,0); +% Map radius +R = map.xstep*FT_find_map_radius(map); % Plot mirror FT_plot_mirror_map(map,0) @@ -39,6 +37,6 @@ FT_plot_mirror_map(map,0) fprintf('--------------------------------------------------------------\n') fprintf('Mirror diameter: %g cm \n',2*R*100) fprintf('Zernike amplitude (Z20): %g nm \n',A) -fprintf('Equivalent ROC: %g m \n',OF.value) +fprintf('Equivalent ROC: %g m \n',Rc(1)) fprintf('--------------------------------------------------------------\n') diff --git a/src/new/tutorials/FTE_map_preparation_04.m b/src/new/tutorials/FTE_map_preparation_04.m index 2be96e699d91dc260367456b2130bedee1ffe138..f910340530bb0eb4f6318e66b815da2ed5a70c3d 100644 --- a/src/new/tutorials/FTE_map_preparation_04.m +++ b/src/new/tutorials/FTE_map_preparation_04.m @@ -24,19 +24,13 @@ map = FT_recenter_mirror_map(map); map = FT_remove_elements_outside_map(map); % Removing zernike curvature -[map,zc] = FT_remove_zernike_curvatures_from_map(map,'constant'); +[map,A2,Rc] = FT_remove_zernike_curvatures_from_map(map,'constant'); -% Calculating equivalent radius of curvature -R = map.xstep*FT_find_map_radius(map,'max'); -A2 = FT_get_zernike_coefficient(zc,2,0); -OF2 = FT_zernike_optical_features(A2,R,2,0); +% Map radius +R = map.xstep*FT_find_map_radius(map); % Remove zernike offset -map = FT_remove_zernike_offset_from_map(map); - -% Equivalent offset -A0 = FT_get_zernike_coefficient(zc,0,0); -OF0 = FT_zernike_optical_features(A0,R,0,0); +[map,A0] = FT_remove_zernike_offset_from_map(map); % Plot mirror FT_plot_mirror_map(map,0) @@ -45,9 +39,8 @@ FT_plot_mirror_map(map,0) fprintf('--------------------------------------------------------------\n') fprintf('Mirror diameter: %g cm \n',2*R*100) fprintf('Zernike amplitude (Z20): %g nm \n',A2) -fprintf('Equivalent ROC: %g m \n',OF2.value) +fprintf('Equivalent ROC: %g m \n',Rc(1)) fprintf('Zernike amplitude (Z00): %g nm \n',A0) -fprintf('Equivalent offset: %g nm \n',OF0.value) fprintf('--------------------------------------------------------------\n') diff --git a/src/new/tutorials/FTE_map_preparation_05.m b/src/new/tutorials/FTE_map_preparation_05.m index 3acd81ea76e261ab8d380ddf7f24c368fddde17f..32b8d8c15f84046bfbdbd84067b3bb5d7891e66b 100644 --- a/src/new/tutorials/FTE_map_preparation_05.m +++ b/src/new/tutorials/FTE_map_preparation_05.m @@ -25,28 +25,16 @@ map = FT_recenter_mirror_map(map); map = FT_remove_elements_outside_map(map); % Removing zernike curvature -[map,zc] = FT_remove_zernike_curvatures_from_map(map,'constant'); +[map,A2,Rc] = FT_remove_zernike_curvatures_from_map(map,'constant'); -% Calculating equivalent radius of curvature -R = map.xstep*FT_find_map_radius(map,'max'); -A2 = FT_get_zernike_coefficient(zc,2,0); -OF2 = FT_zernike_optical_features(A2,R,2,0); +% Map radius +R = map.xstep*FT_find_map_radius(map); % Remove zernike offset -map = FT_remove_zernike_offset_from_map(map); +[map,A0] = FT_remove_zernike_offset_from_map(map); -% Equivalent offset -A0 = FT_get_zernike_coefficient(zc,0,0); -OF0 = FT_zernike_optical_features(A0,R,0,0); - % Remove zernike tilt -map = FT_remove_zernike_tilt_from_map(map); - -% Equivalent mis-alignements -A1o = FT_get_zernike_coefficient(zc,1,-1); -OF1o = FT_zernike_optical_features(A1o,R,1,-1); -A1e = FT_get_zernike_coefficient(zc,1,1); -OF1e = FT_zernike_optical_features(A1e,R,1,1); +[map,A1,xbeta,ybeta] = FT_remove_zernike_tilt_from_map(map); % Plot map FT_plot_mirror_map(map,0) @@ -55,11 +43,10 @@ FT_plot_mirror_map(map,0) fprintf('--------------------------------------------------------------\n') fprintf('Mirror diameter: %g cm \n',2*R*100) fprintf('Zernike amplitude (Z20): %g nm \n',A2) -fprintf('Equivalent ROC: %g m \n',OF2.value) +fprintf('Equivalent ROC: %g m \n',Rc(1)) fprintf('Zernike amplitude (Z00): %g nm \n',A0) -fprintf('Equivalent offset: %g nm \n',OF0.value) -fprintf('Zernike amplitude (Z1-1): %g nm \n',A1o) -fprintf('Equivalent tilt (ybeta): %g urad \n',OF1o.value*1e6) -fprintf('Zernike amplitude (Z11): %g nm \n',A1e) -fprintf('Equivalent tilt (xbeta): %g urad \n',OF1e.value*1e6) +fprintf('Zernike amplitude (Z1-1): %g nm \n',A1(1)) +fprintf('Equivalent tilt (ybeta): %g urad \n',ybeta*1e6) +fprintf('Zernike amplitude (Z11): %g nm \n',A1(2)) +fprintf('Equivalent tilt (xbeta): %g urad \n',xbeta*1e6) fprintf('--------------------------------------------------------------\n') diff --git a/src/new/tutorials/FTE_map_preparation_06.m b/src/new/tutorials/FTE_map_preparation_06.m index 94e3d9962cb096b7132fda1a1bbebe3231ccd6ec..59e1906042756b18a2647d35c5f7ae1713925158 100644 --- a/src/new/tutorials/FTE_map_preparation_06.m +++ b/src/new/tutorials/FTE_map_preparation_06.m @@ -16,7 +16,8 @@ clear all; filename = 'CVI1-S1-BC.asc'; % Read map in .asc format -map = FT_read_zygo_map(filename,2) +map = FT_read_zygo_map(filename,2); % Prepare the map for use in FINESSE simulations -map_out = FT_prepare_phase_map_for_finesse(map,[0,0],'constant'); \ No newline at end of file +% Using no Gaussian weighting for removal of curvatures +map_out = FT_prepare_phase_map_for_finesse(map,[0,0],0); \ No newline at end of file