Limits of Adaptive Optics for High-Contrast Imaging

Contents:

Module for various Adaptive Optics (AO) simulations.

A key reference (among many) is Guyon (2005)

To compute Guyon’s C0-C6 terms, use the following functions:

A quick test is just to run run_example(); look under the hood at its source code to see more details.

DEPENDENCIES:

nsdata.nAir() – refractive index of air (for contrast_chromaticity())

PyLab – for plotting the figure in run_example()

TO DO:

Add functions for beta_p (wavefront sensor sensitivity) for various sensor technologies: Shack-Hartmann, Curvature, etc.

NOTE:

Note that the coefficient “0.484” in Eqs. 16 and 17 of Guyon 2005 has been corrected here to its intended value of 0.22*0.22=0.0484 (O. Guyon, private communication, Jan 2013).

ao.calc_XY(z, dz, cn2, alpha_arcsec, lam_sci, lam_wfs=None)[source]

Calculate X and Y of (Eq. 14 of Guyon 2005)

INPUTS:
z : 1D NumPy array

Altitudes of given C_n^2 profile, in meters

dz : scalar or 1D NumPy array

Width of each layer of ‘z’, in meters; same size as ‘z’

cn2 : 1D NumPy array

C_n^2 (turbulence) profile of atmosphere; same size as ‘z’

alpha_arcsec : scalar or 1D NumPy array

Angular separation for calculation, in arcsec

lam_sci : scalar

Wavelength of science observations, in meters

lam_wfs : scalar

Wavelength of wavefront sensing, in meters (only needed for calculating dX, dY terms).

OUTPUTS:

X, Y (if lam_wfs is None)

X, Y, dX, dY (otherwise)

ao.contrast_chromaticity(lam_r0, r0, z, dz, cn2, alpha_arcsec, lam_wfs, lam_sci, D, X=None, Y=None, dX=None, dY=None, C0=None, C1=None, T=None, P=None, fco2=None, pph2o=None)[source]

Compute PSF contrast from chromaticity of phase and amplitude errors (C4 and C5)

INPUTS:
lam_r0 : scalar

Wavelength at which ‘r0’ is specified, in meters

r0 : scalar

Fried parameter, in meters; specified at wavelength of ‘lam_r0’

z : 1D NumPy array

Altitudes of given C_n^2 profile, in meters

dz : scalar or 1D NumPy array

Width of each layer of ‘z’, in meters; same size as ‘z’

cn2 : 1D NumPy array

C_n^2 (turbulence) profile of atmosphere; same size as ‘z’

alpha_arcsec : scalar or 1D NumPy array

Angular separation for calculation, in arcsec

lam_wfs : scalar

Wavelength of wavefront sensor operation, in meters

lam_sci : scalar

Wavelength of science observations, in meters

D : scalar

Diameter of primary mirror, in meters.

X, Y, dX, dY: 1D NumPy Arrays

See calc_XY().

T, P, fco2, pph2o: scalars

Atmospheric parameters for calculating refractive index. If set to None, the defaults in nsdata.nAir() will be used.

OUTPUTS:
C4, C5, C6 : 3-tuple of 1D NumPy arrays

PSF contrast from chromaticity of: phase errors, amplitude errors, and atmospheric refractivity.

ao.contrast_residual(lam_r0, r0, z, dz, cn2, v, alpha_arcsec, F, beta_p, beta_a, lam_wfs, lam_sci, D, X=None, Y=None)[source]

Compute PSF contrast from residual atmospheric phase and amplitude errors (C2 and C3, of Guyon 2005)

INPUTS:
lam_r0 : scalar

Wavelength at which ‘r0’ is specified, in meters

r0 : scalar

Fried parameter, in meters; specified at wavelength of ‘lam_r0’

z : 1D NumPy array

Altitudes of given C_n^2 profile, in meters

dz : scalar or 1D NumPy array

Width of each layer of ‘z’, in meters; same size as ‘z’

cn2 : 1D NumPy array

C_n^2 (turbulence) profile of atmosphere; same size as ‘z’

v : scalar

Atmospheric windspeed, in meters per second.

alpha_arcsec : scalar or 1D NumPy array

Angular separation for calculation, in arcsec

F : scalar
Source brightness at ‘lam_wfs’, in photons per second per

meters squared.

beta_p : scalar or 1D NumPy array (same size as ‘alpha_arcsec’)

Wavefront sensor sensitivity to phase errors; equals 1.0 for an ideal sensor.

beta_a : scalar or 1D NumPy array (same size as ‘alpha_arcsec’)

Wavefront sensor sensitivity to amplitude errors; equals 1.0 for an ideal sensor.

lam_wfs : scalar

Wavelength of wavefront sensor operation, in meters

lam_sci : scalar

Wavelength of science observations, in meters

D : scalar

Diameter of primary mirror, in meters.

X, Y: 1D NumPy Arrays

See calc_XY()

OUTPUTS:
C2, C3 : 2-tuple of 1D NumPy arrays

PSF contrast from residual atmospheric phase and amplitude errors

ao.contrast_uncorrected(lam_r0, r0, z, dz, cn2, alpha_arcsec, lam_sci, D, X=None, Y=None)[source]

Compute PSF contrast from uncorrected atmospheric phase and amplitude errors (C0 and C1)

INPUTS:
lam_r0 : scalar

Wavelength at which ‘r0’ is specified, in meters

r0 : scalar

Fried parameter, in meters; specified at wavelength of ‘lam_r0’

z : 1D NumPy array

Altitudes of given C_n^2 profile, in meters

dz : scalar or 1D NumPy array

Width of each layer of ‘z’, in meters; same size as ‘z’

cn2 : 1D NumPy array

C_n^2 (turbulence) profile of atmosphere; same size as ‘z’

alpha_arcsec : scalar or 1D NumPy array

Angular separation for calculation, in arcsec

lam_sci : scalar

Wavelength of science observations, in meters

D : scalar

Diameter of primary mirror, in meters.

X, Y: 1D NumPy Arrays

See calc_XY()

OUTPUTS:
C0, C1: 2-tuple of 1D NumPy arrays

PSF contrast from uncorrected atmospheric phase and amplitude errors (respectivey)

NOTE:

Note that the coefficient “0.484” in Eqs. 16 and 17 of Guyon 2005 has been corrected here to its intended value of 0.22*0.22=0.0484 (O. Guyon, private communication, Jan 2013).

ao.makecn2()[source]

Reproduce the C_n^2 profile used in Guyon 2005 (Table 4).

OUTPUTS:
z : 1D NumPy array

altitude of each layer, in meters

dz : scalar

the thickness of each layer, in meters.

cn2 : 1D NumPy array

C_n^2 (turbulence) profile of atmosphere.

EXAMPLE:

import ao z, dz, cn2 = ao.makecn2()

# Compute various moments mu0 = (dz * cn2).sum() mu2 = (dz * cn2 * z**2).sum() mu53 = (dz * cn2 * z**(5/3.)).sum() z2 = (mu2/mu0)**0.5 hbar = (mu53/mu0)**0.6

# Verify z_2 and hbar, in Table 4 of Guyon 2005: print ‘z_2 is: %1.1f km’ % (z2/1000.) print ‘hbar is: %1.1f km’ % (hbar/1000.)

ao.run_example()[source]

Run an example simulation, and reproduce Fig. 12 of Guyon 2005.

See the source code of this function for details.

Note that as published, the coefficients in Guyon 2005 Eqs. 16-17 are incorrect (they should be 0.0484, not 0.484). This function uses the correct coefficient, and so differs from the published version of Fig. 12.

Previous topic

NIRSPEC data reduction

Next topic

NIRSPEC Data Analysis

This Page