isfptos

Top  Previous  Next

Using data generated by aogeom (or a user-supplied equivalent), lsfptos computes a slope influence function matrix which can be used for wavefront sensing in the absence of a DM.  In this case the aoinf routine is not used. We still set up the WFS geometry with aogeom, but then we continue with the sequence lsfptos-aorecon, instead of using the sequence aogeom-aoinf-aorecon.  When we use lsfptos in the absence of a DM, "actuator" locations specified in aogeom are interpreted as the points at which the wavefront OPD is represented. lsfptos requires that the "actuator" locations be at the corners of the subapertures.

From the Matlab command line, the calling syntax for lsfptos is:

>>  [ptos, c] = lsfptos(xsub, ysub, xact, yact);  % NOTE:  the first letter of "lsfptos" is lower case "ell"

where

xsub   =  vector (dim nsub x 1) containing the x-coordinates (in m) of the centers of the WFS subapertures.  The subaperture numbering convention has been described previously.

ysub   =  vector (dim nsub x 1) containing the y-coordinates (in m) of the centers of the WFS subapertures.

xact   =  vector (dim nact x 1) containing the x-coordinates (in m) of the "actuator" locations. The actuator numbering convention has been described previously.

yact   =  vector (dim nact x 1) containing the y-coordinates (in m) of the "actuator" locations.

ptos   = the slope influence matrix of type S'c , defined previously.  Dimensions are  2nsub x nact .

CAUTION:  the lsfptos routine neglects to divide by the actuator separations dxact and dyact when computing the matrix ptos.  To compensate manually, see the Matlab example listed next.  

UNITS:  after the compensating divisor is applied, the corrected matrix ptos will map an OPD vector in units of meters into a slopes vector in units of radians of tilt angle.

c  = diagnostic quantity not needed for subsequent processing.

Starting with a sample file generated by aogeom, the following Matlab example illustrates the use of lsfptos:

% First, use aogeom to inspect the subap and "actuator" layout to be used:

>> aogeom

       % Using File-Load in the AOgeom window, load "small45g.mat" into the geometry display

       % Note that we have 32 subapertures and 45 "actuators" in this configuration.

       % Using File-Define Geometry, inspect the Parameters window: note that the "actuator"

       % spacing dxact = 0.15m = dyact.

% Now load "small45g.mat" into the Matlab workspace:

>> load small45g.mat

        % The coordinate vectors  xact, yact, xsub, ysub are now present in the workspace;

        % xact and yact have dim (45x1), xsub and ysub have dim (32x1).

>> [ptos,c] = lsfptos(xsub, ysub, xact, yact);   % Compute the S'c matrix, absent a scale factor.

>> ptos = ptos/0.15;   % Divide by the actuator spacing (in m) to correct for the missing scale factor.

% For testing purposes, we now create an opd map at the "actuator" coordinates.

% The functional form of the opd will be a uniform tilt, with x-tilt = 1E-6 rad, and y-tilt = 2E-6 rad,

% expressed by the equation  opd = (x / 1.0m)*1E-6m + (y / 1.0m)*2E-6m,  where {x,y,opd} are in m:

>> for k=1:nact;  opd(k,1) = ( xact(k)/1.0)*1E-6 + (yact(k)/1.0)*2E-6;  end;  

                          % Note that opd must be defined as a column vector, dim (nactx1) =( 45x1).

% Now apply the slope influence matrix S'c to compute subaperture slopes:

>> s = ptos*opd;  

        % s is the vector of subaperture slopes (dim 2nsub x 1 = 64x1) in radians of angle,

        % where s(1:32) are the x-slopes, s(33:64) are the y-slopes.

>> s(1:32)';     % Print the x-tilts in each subap:  each is 1E-6 rad, as expected.

>> s(33:64)';   % Print the y-tilts in each subap:  each is 2E-6 rad, as expected.