function [x,delta]=SF_Spec_Calc(r0,lambda_r0,loss,lambda_loss,dia) % SF_Spec_Calc.m % Written by Stacie Manuel % Version History: % June 4, 2009 - Version 1 %% Overview % This function calculates the polishing specification for a telescope, % following the discussion by Hill in "Optical Design, Error Budget and % Specifications for the Columbus Project Telescope" (Proc. SPIE 1236, % 86-107 (1990)). This calculation assumes the telescope has tilt % correction. % Inputs % 1) r0: the coherence length of the atmosphere, also known as Fried's % parameter, in units of cm % 2) lambda_ro: the wavelength for which r0 is given, in units of nm % 3) loss: loss due to scattering normalized to 1 % 4) lambda_loss: the wavelength for which the loss is given, in units of nm % 5) dia: the diameter of the telescope, in units of cm % % Outputs % 1) x: the separation values, in units of cm % 2) delta: the rms wavefront difference between points separated by x, in % units of nm % The example script SF_Specification.m shows an example of how to call % this function. %% Calculations r0=r0*(lambda_r0/500)^1.2; % adjust r0 so that it is given for lambda = 500nm x = logspace(-3,0,100); % Separation distances to form the x axis of the graph (normalized to 1) x = x*dia; % Separation distances to form the x axis of the graph (in units of cm) % Contribution due to scattering: SF_loss = 2*loss*(lambda_loss/(2*pi))^2; % Contribution due to atmospheric turbulence: SF_atm = ((lambda_r0/(2*pi))^2)*6.88*((x/r0).^(5/3)).*(1-0.975*(x/dia).^(1/3)); % Total structure function: SF = SF_loss + SF_atm; % rms wavefront difference between points separated by x given in the same % units as the wavelengths (nm) delta = sqrt(SF);