Beispiel #1
0
atmosDict = {}
nlayer = 2  #10 atmospheric layer
layerList = {"allLayers": ["L%d" % x for x in range(nlayer)]}
strList = [0.5
           ] + [0.5 /
                (nlayer - 1.)] * (nlayer - 1)  #relative strength of the layers
hList = (0, 12376)  #height of the layers
vList = [10., 15.]  #velocity of the layers
dirList = [45., 135.]  #direction (degrees) of the layers
for i in range(nlayer):
    atmosDict["L%d" % i] = layer(hList[i], dirList[i], vList[i], strList[i],
                                 10 + i)

l0 = 25.  #outer scale
r0 = 0.1  #fried's parameter
atmosGeom = geom(atmosDict, sourceList, ntel, npup, telDiam, r0, l0)

#Create the DM object.
from util.dm import dmOverview, dmInfo
import numpy
if ndm > 1:
    dmHeight = numpy.arange(ndm) * (hList[-1] / (ndm - 1.))
else:
    dmHeight = [0]
dmInfoList = []
for i in range(ndm):
    dmInfoList.append(
        dmInfo('dm%dpath' % i, [x.idstr for x in sourceList],
               dmHeight[i],
               nAct,
               minarea=0.1,
Beispiel #2
0
 phslam=sciLam
for i in range(nsci):
 sciDict["sci%d"%(i+1)]=util.sci.sciInfo("sci%d"%(i+1),i*10.,0.,pupil,sciLam,phslam=phslam,phaseType="phaseamp")
 sciOverview=util.sci.sciOverview(sciDict)


sourceList=[]
#the wfs
sourceList.append(wfsOverview.getWfsByID("1"))

#and psf
for i in range(nsci):
 sourceList.append(sciOverview.getSciByID("sci%d"%(i+1)))


atmosGeom=geom(atmosDict,sourceList,ntel,npup,telDiam,r0,l0)
this.physProp.atmosGeom=geom(atmosDict,sourceList,this.physProp.ntel,this.physProp.npup,this.physProp.telDiam,r0,l0,ignoreZenithWarning=1)
this.infScrn.atmosGeom=this.physProp.atmosGeom



#Create the DM object.
nAct=wfs_nsubx+1
from util.dm import dmOverview,dmInfo
dmInfoList=[dmInfo('dm',[x.idstr for x in sourceList],0.,nAct,minarea=0.1,actuatorsFrom="recon",pokeSpacing=(None if wfs_nsubx<20 else 10),maxActDist=1.5,decayFactor=0.95)]
dmOverview=dmOverview(dmInfoList,atmosGeom)

rcond=0.05#condtioning value for SVD
recontype="pinv"#reconstruction type
pokeval=1.#strength of poke
gainFactor=0.5#Loop gain