functions in aoutil.i -
|
checkParameters
|
func checkParameters(void)
Check the parameters in yao parfile
- set defaults
- value valid?
- compatibility with other parameters
| |
| SEE ALSO: | ||
|
disp2D
|
func disp2D(arrayptr,xpos,ypos,area,zoom=,power=,init=)
display several images in the same plsys, at position given
by xpos and ypos.
ar: ar can be either an array of pointers or an image cube
xpos,ypos: the (X,Y) positions, in arbitrary coordinates
area: plsys number
zoom: keyword (vector, dim nim), additional zooming factor (on top of default)
power: *arrayptr^power is displayed
init: initialize, precompute stuff
| |
| SEE ALSO: | ||
|
encircled_energy
|
NT encircled_energy(image,ee50,xc=,yc=)
Computes encircled energy function for a 2D array.
Keywords xc and yc optionaly specify center about which the encircled
energy profile is to be computed. Returns optionally the value of the
50% encircled energy *diameter* (output).
F.Rigaut, Nov 2001.
| |
| SEE ALSO: | findfwhm | |
|
findfwhm
|
findfwhm(image,psize)
Determine the FWHM of an image. It simply rebins the image by
a factor of 4 and counts the number of pixels above the maximum
of the image divided by 2. Not the best accurate method but it's
robust
F.Rigaut, 2001/11/10.
| |
| SEE ALSO: | ||
|
ftcb
|
ftcb(te,tcal,tmir,gain,dim,x=)
returns [f,hbo,hcor,hbf]
AUTHOR: F.Rigaut, way back in 1996?
| |
| SEE ALSO: | ||
|
ftcbAoSimul
|
func ftcbAoSimul(FrameDelay,gain,dim)
NOT UPGRADED TO VERSION 2.
DO NOT USE UNTIL UPGRADED.
This routine simulates the time aspect of the numerical loop
and compute the associated transfer functions (error, closeloop)
for further use in modalGainOptimization().
Inputs:
FrameDelay: frame delay in close loop.
gain: AO loop gain
dim: desired linear size of the output transfer functions
| |
| SEE ALSO: | modalGainOptimization | |
|
fwhmStrehl
|
NT function fwhmStrehl
Syntax: fwhmStrehl(image,ps,lambda,teldiam,cobs,strehl,fwhm,strehlab,&airy,
fibre=,source=,rmask=,dlambda=,psf0=,psfcomp=,autoback=)
Cette routine calcule le strehl et la fwhm de l'image. Le strehl
est calcule de la facon suivante :
1) on calcule la fto et on filtre les frequences > coupure du telescope
2) On corrige de l'effet de filtrage par la taille finie du pixel
3) Le cas echeant ("source" is set), on divise par la fto de la source
4) On synthetise une tache d'airy pour la longueur d'onde en question
5) On rebinne par 4, normalise, et on compare les maxima -> Strehl
La FWHM est simplement calcule a partir du nombre de pixel de valeur > au
max de l'image/2.
ps = pixel size en arcsec
lambda = en um
teldiam = telescope diameter en m
cobs = fraction obstruction central/telescope diameter
fibre = cf ci-dessus
source = source dimension in arcsec.
autoback = automatic normalization of background by interpolation of
zero point in MTF
By convention, real plane coordinate (0,0) -> [dim/2,dim/2]
fourier plane coordinates (0,0) -> [0,0]
| |
|
getTurbPhaseInitCheckOverflow
|
func getTurbPhaseInitCheckOverflow
This routine has the sole purpose of checking the possible "overflow"
of the Y index in the future calls to getTurbPhase. In any of the
Y index at which the interpolation is to be done is larger than the
phase screen(s) Y dimension, then an error is flagged.
| |
| SEE ALSO: | getTurbPhaseInit, getTurbPhase | |
|
graphicConfig
|
func configGraphic(void)
Plots a graphical representation of the system config,
per subsystem and per level (altitude)
subsystemnum and dmnum optional. If not set all subsystems
and dms are displayed
| |
| SEE ALSO: | ||
|
MakePztIF
|
NT function MakePztIF2(dm_structure,disp=)
the influence functions are in microns per volt.
| |
|
modalGainOptimization
|
func modalGainOptimization(disp=,update=)
NOT UPGRADED TO VERSION 2.
DO NOT USE.
This routine optimizes the modal gains.
Keywords:
disp: set to display stuff
update: set if this is a gain update (opposite to the first time run)
This routine uses:
- the saved error circular buffer (cberr.fits)
This routine calls:
...
This routine sets:
...
| |
| SEE ALSO: | ||
|
noll
|
func noll(ord)
Noll variance of zernike for D/r0 = 1
| |
| SEE ALSO: | ||
|
nollmat
|
func nollmat(ord)
Noll covariance matrix for D/r0 = 1
| |
| SEE ALSO: | ||
|
projectAnisoIF
|
func projectAnisoIF(nmaniso,nmlow,nmhigh,disp=)
This function finds the actuator commands to apply on dmlow and dmhigh
to produce the anisoplanatism modes (which upper part is in dm(nmaniso)).
nmaniso: # indice of anisoplanatism DM
nmlow: # indice of low DM (at 0 altitude)
nmhigh: # indice of high DM (at non zero altitude)
computes alow and ahigh, which are #actuator x #anisomode.
also compute "comaniso", which is the alow and ahigh put into a
global total_#_actuator x 3 matrix, which can be directly multiplied/added
to the global system command vector (see aoloop).
Store them in extern variables for future use.
| |
| SEE ALSO: | MakeAnisoIF | |
|
telfto
|
telfto | |
| SEE | telftot0 | |
|
telftog
|
telftog | |
| SEE | telftoh2 | |
|
telftot0
|
NT func telfto
Syntax: telfto(lambda,dlambda,teldiam,cobs,pixsize,dim,freqc=,
npt=,silent=,returnpsf=)
Computes and returns the Modulation transfer function (FTO is
the french equivalent...) of a telescope with central obstruction
and perfect optics.
Parameters and keywords:
lambda in microns
dlambda in microns
teldiam in meters
cobs in fraction of teldiam
pixsize in arcsec
dim is output array dimension
freqc is the cut-off frequency ?
npt the number of point in dlambda (for calculations in this routine)
silent has to be set to one for suppressing printout comments
setting returnpsf has the effect of returning the PSF, not the MTF
| |
|
wfsCheckPixelSize
|
wfsCheckPixelSize(ns,&binindices,¢roidw)
Finds the pixel size for the requested WFS configuration.
There are constraints:
- First, the pixel size can not be arbitrary.
It is defined by lambda_wfs/pixel_size_in_pupil_space/sdim.
- Second, the max subaperture size is lambda_wfs/pixel_size_in_pupil_space
I could have preserved wfs.npixels as a strong constraint, but it lead to
complicated algorithms. Instead, I am finding the closest pixel size to
wfs.pixsize and then derive the number of pixel and subaperture size.
In addition, I only allow an even number of pixels in the subaperture
(otherwise I have to check many more things, as for instance an odd
number of pixels in the subaperture combined with a odd rebinFactor
cause problems.
This routine fills and returns binindices and centroidw
| |
| SEE ALSO: | ShWfs | |