mxlib
c++ tools for analyzing astronomical data and other tasks by Jared R. Males. [git repo]
Loading...
Searching...
No Matches
mx::AO::analysis::aoSystem< _realT, _inputSpectT, iosT > Class Template Reference

template<typename _realT, class _inputSpectT, typename iosT = std::ostream>
class mx::AO::analysis::aoSystem< _realT, _inputSpectT, iosT >

Describes an analytic adaptive optics (AO) system.

Templatized by the turbulence power spectral density (PSD).

Template Parameters
realTthe floating point type used for all calculations
inputSpecTspecifies the turbulence spatial PSD type
iosTis an output stream type with operator << defined (default is std::ostream)

Definition at line 63 of file aoSystem.hpp.

#include <ao/analysis/aoSystem.hpp>

Public Member Functions

 aoSystem ()
 Default c'tor.
 ~aoSystem ()
 Destructor.
void loadGuyon2005 ()
 Load the default parameters from Guyon, 2005 [14].
void loadMagAOX ()
 Load parameters corresponding to the MagAO-X system.
void loadGMagAOX ()
 Load parameters corresponding to the G-MagAO-X system.
void D (realT nD)
 Set the value of the primary mirror diameter.
realT D ()
 Get the value of the primary mirror diamter.
void d_min (const std::vector< realT > &nd)
 Set the minimum subaperture sampling for each WFS mode.
void d_min (int idx, realT nd)
 Set the minimum subaperture sampling for a given WFS mode.
realT d_min (size_t idx)
 Get the minimum subaperture sampling for a given WFS mode.
std::vector< realT > d_min ()
 Get the minimum subaperture sampling for all WFS modes.
void optd (bool od)
 Set whether or not the value of d is optimized or just set to m_d_min.
bool optd ()
 Get the value of m_optd.
void optd_delta (realT odd)
 Set the fractional change in actuator spacing for optimization.
realT optd_delta ()
 Get the value of the fractional change in actuator spacing for optimization..
template<typename wfsT>
void wfsBeta (const wfsT &w)
 Set the WFS Beta pointer.
template<typename wfsT>
void wfsBeta (const wfsT *w)
 Set the WFS Beta pointer.
wfs< realT, iosT > * wfsBeta ()
 Get the WFS Beta pointer.
realT beta_p (realT m, realT n)
 Get the value of beta_p for a spatial frequency.
realT beta_r (realT m, realT n)
 Get the value of beta_r for a spatial frequency.
void opticalGain (realT og)
 Set the value of the Optical Gain.
realT opticalGain ()
 Get the value of the optical gain.
void lam_wfs (realT nlam)
 Set the value of the WFS wavelength.
realT lam_wfs ()
 Get the value of the WFS wavelength.
void npix_wfs (const std::vector< realT > &npix)
 Set the number of pixels in the WFS for each WFS mode.
void npix_wfs (int idx, realT npix)
 Set the number of pixels in the WFS for a given WFS mode.
realT npix_wfs (size_t idx)
 Get the number of pixels in the WFS for a given WFS mode.
std::vector< realT > npix_wfs ()
 Get the number of pixels in the WFS for all WFS modes.
void ron_wfs (const std::vector< realT > &nron)
 Set the value of the WFS readout noise for each WFS mode.
void ron_wfs (int idx, realT nron)
 Set the value of the WFS readout noise for a given bining mode.
realT ron_wfs (size_t idx)
 Get the value of the WFS readout noise for a given WFS mode.
std::vector< realT > ron_wfs ()
 Get the value of the WFS readout noise for all WFS modes.
void Fbg (const std::vector< realT > &fbg)
 Set the value of the background fluxes.
void Fbg (int idx, realT fbg)
 Set a single value of the background flux for a given WFS mode.
realT Fbg (size_t idx)
 Get the value of the background flux for a given WFS mode.
std::vector< realT > Fbg ()
 Get the value of the background flux for all WFS modes.
void minTauWFS (const std::vector< realT > &ntau)
 Set the value of the minimum WFS exposure times.
void minTauWFS (size_t idx, realT ntau)
 Set a single value of the minimum WFS exposure time for a given WFS mode.
realT minTauWFS (size_t idx)
 Get the value of the minimum WFS exposure time for a given binning.
std::vector< realT > minTauWFS ()
 Get the values of the minimum WFS exposure time.
void bin_npix (bool bnp)
 Set the value of the pixel binning flag.
bool bin_npix ()
 Get the value of the pixel binngin flag.
int bin_opt ()
 Get the value of the optimum binning factor/index.
void tauWFS (realT ntau)
 Set the value of the WFS exposure time.
realT tauWFS ()
 Get the value of the minimum WFS exposure time.
void deltaTau (realT ndel)
 Set the value of m_deltaTau.
realT deltaTau ()
 Get the value of m_deltaTau.
void optTau (bool ot)
 Set the value of m_optTau.
bool optTau ()
 Get the value of m_optTau.
void lam_sci (realT nlam)
 Set the science wavelength.
realT lam_sci ()
 Get the science wavelength.
void zeta (realT nz)
 Set the zenith angle, and its secant.
realT zeta ()
 Get the zenith angle.
realT secZeta ()
 Get the zecant of the zenith angle.
void fit_mn_max (int mnm)
 Set the value of m_fit_mn_max.
int fit_mn_max ()
 Get the value of m_fit_mn_max.
void circularLimit (bool cl)
 Set the value of the circularLimit flag.
bool circularLimit ()
 Get the value of the circularLimit flag.
void spatialFilter_ku (realT ku)
 Set the value of spatialFilter_ku.
realT spatialFilter_ku ()
 Get the value of spatialFilter_ku.
void spatialFilter_kv (realT kv)
 Set the value of spatialFilter_kv.
realT spatialFilter_kv ()
 Get the value of spatialFilter_kv.
void ncp_wfe (realT nwfe)
 Set the value of the non-common path WFE.
realT ncp_wfe ()
 Get the value of the non-common path WFE.
void ncp_alpha (realT alpha)
 Set the value of the non-common path WFE PSD index.
realT ncp_alpha ()
 Get the value of the non-common path WFE PSD index.
void F0 (realT nF0)
 Set the value of the 0 magnitude photon rate.
realT F0 ()
 Get the value of the 0 magnitude photon rate.
void starMag (realT nmag)
 Set the value of the Star's magnitude.
realT starMag ()
 Get the value of the Star's magnitude.
realT Fg (realT mag)
 The photon flux at a given star magnitude.
realT Fg ()
 Get the photon rate at the current Star magnitude.
const Eigen::Array< int, -1, -1 > & controlledModes ()
 Access the array of controlledModes.
realT ncpError (int m, int n)
 Calculate the NCP variance at a spatial frequency.
realT ncpError ()
 Calculate the total NCP variance in rad^2.
iosT & dumpAOSystem (iosT &ios)
 Output current parameters to a stream.
void setupConfig (app::appConfigurator &config)
 Setup the configurator to configure this class.
error_t loadConfig (app::appConfigurator &config)
 Load the configuration of this class from a configurator.
Measurement Error

Calculating the WFE due to WFS measurement noise.

realT signal2Noise2 (realT &Nph, realT tau_wfs, realT d, int b)
 Calculate the terms of the signal to noise ratio squared (S/N)^2 for the WFS measurement.
realT measurementError (realT m, realT n, realT d, int b)
 Calculate the measurement noise at a spatial frequency and specified actuator spacing.
realT measurementErrorTotal ()
 Calculate the total measurement error over all corrected spatial frequencies.
Time Delay Error

Calculating the WFE due to time delay.

realT timeDelayError (realT m, realT n, realT d, int b)
 Calculate the time delay at a spatial frequency at the optimum exposure time and the specified actuator spacing.
realT timeDelayErrorTotal ()
 Calculate the time delay error over all corrected spatial frequencies.
Fitting Error

Calculating the WFE due to uncorrected spatial frequencies.

realT fittingError (realT m, realT n)
 Calculate the fitting error at a specific spatial frequency.
realT fittingErrorTotal ()
 Calculate the total fitting error over all uncorrected spatial frequencies.
Chromatic Errors

Calculating the WFE due to chromaticity in scintillaion, index of refraction, and dispersion.

realT chromScintOPDError (int m, int n)
 Calculate the wavefront error due to scintillation chromaticity in the OPD at a spatial frequency.
realT chromScintOPDErrorTotal ()
 Calculate the wavefront error due to scintillation chromaticity in the OPD over all spatial frequencies.
realT chromScintAmpError (int m, int n)
 Calculate the wavefront error due to scintillation chromaticity in amplitude for a given spatial frequency.
realT chromScintAmpError ()
 Calculate the wavefront error due to scintillation chromaticity in amplitude over all spatial frequencies.
realT chromIndexError (int m, int n)
 Calculate the wavefront error due to chromaticity in the index of refraction at a given spatial frequency.
realT chromIndexErrorTotal ()
 Calculate the wavefront error due to chromaticity in the index of refraction at a specific spatial frequency.
realT dispAnisoOPDError (int m, int n)
 Calculate the wavefront error due to dispersive anisoplanatism in the OPD at a given spatial frequency.
realT dispAnisoOPDErrorTotal ()
 Calculate the wavefront error due to dispersive anisoplanatism in the OPD over all specific spatial frequencies.
realT dispAnisoAmpError ()
 Calculate the wavefront error due to dispersive anisoplanatism in the amplitude at a specific spatial frequency.
Optimum Parameters

Functions to calculate the optimum integration time and actuator spacing.

realT optimumTauWFS (realT m, realT n, realT d, int b)
 Calculate the optimum exposure time for a given spatial frequency at a specified actuator spacing.
realT optimumTauWFS (realT m, realT n)
 Calculate the optimum exposure time for a given spatial frequency at the optimum actuator spacing.
realT d_opt ()
 Calculate the optimum actuator spacing.
Contrast

Calculating contrast

template<typename varFuncT>
realT C_ (int m, int n, bool normStrehl, varFuncT varFunc, int doFittingError)
 Worker function for raw contrast fuctions.
template<typename imageT, typename CfuncT>
void C_Map (imageT &im, CfuncT Cfunc, bool normStrehl)
 Worker function for the contrast-map functions.
realT C0var (realT m, realT n)
 Calculate the residual variance due to uncorrected phase at a spatial frequency.
realT C0 (realT m, realT n, bool normStrehl=true)
 Calculate the contrast due to uncorrected phase, C0.
template<typename imageT>
void C0Map (imageT &map, bool normStrehl)
 Calculate a 2D map of contrast C0.
realT C1var (realT m, realT n)
 Calculate the residual variance due to uncorrected amplitude at a spatial frequency.
realT C1 (realT m, realT n, bool normStrehl=true)
 Calculate the contrast due to uncorrected amplitude, C1.
template<typename imageT>
void C1Map (imageT &map, bool normStrehl)
 Calculate a 2D map of contrast C1.
realT C2var (realT m, realT n)
 Calculate the residual variance due to measurement and time delay errors in phase/OPD at a spatial frequency.
realT C2 (realT m, realT n, bool normStrehl=true)
 Calculate the contrast due to measurement and time delay errors in phase/OPD at a spatial frequency.
template<typename imageT>
void C2Map (imageT &map, bool normStrehl)
 Calculate a 2D map of contrast C2().
realT C3var (realT m, realT n)
 Calculate the residual variance due to measurement and time delay errors in amplitude at a spatial frequency.
realT C3 (realT m, realT n, bool normStrehl=true)
 Calculate the contrast due to measurement and time delay errors in amplitude at a spatial frequency.
template<typename imageT>
void C3Map (imageT &map, bool normStrehl)
 Calculate a 2D map of contrast C3.
realT C4var (realT m, realT n)
 Calculate the residual variance due to scintilation-OPD chromaticity.
realT C4 (realT m, realT n, bool normStrehl=true)
 Calculate the contrast due to scintilation-OPD chromaticity.
template<typename imageT>
void C4Map (imageT &map, bool normStrehl)
 Calculate a 2D map of contrast C4.
realT C5var (realT m, realT n)
 Calculate the residual variance due to to scintilation-amplitude chromaticity.
realT C5 (realT m, realT n, bool normStrehl=true)
 Calculate the contrast due to scintilation-amplitude chromaticity.
template<typename imageT>
void C5Map (imageT &map, bool normStrehl)
 Calculate a 2D map of contrast C5.
realT C6var (realT m, realT n)
 Calculate the residual variance due to chromaticity of the index of refraction of air.
realT C6 (realT m, realT n, bool normStrehl=true)
 Calculate the contrast due to chromaticity of the index of refraction of air.
template<typename imageT>
void C6Map (imageT &map, bool normStrehl)
 Calculate a 2D map of contrast C6.
realT C7var (realT m, realT n)
 Calculate the residual variance due to dispersive anisoplanatism.
realT C7 (realT m, realT n, bool normStrehl=true)
 Calculate the contrast due to dispersive anisoplanatism.
template<typename imageT>
void C7Map (imageT &map, bool normStrehl)
 Calculate a 2D map of contrast C7.

Protected Attributes

realT m_D { 0 }
 Telescope diameter [m].
std::vector< realT > m_d_min { 0 }
 Minimum AO system actuator pitch [m]. One per WFS mode.
realT m_d_opt { 0 }
 Current optimum AO system actuator pitch [m].
bool m_optd { false }
realT m_optd_delta { 1.0 }
wfs< realT, iosT > * m_wfsBeta { nullptr }
 The WFS beta_p class.
bool m_ownWfsBeta { false }
 Flag indicating if the WFS beta_p pointer is owned by this instance.
realT m_opticalGain { 1 }
realT m_lam_wfs { 0 }
 WFS wavelength [m].
std::vector< realT > m_npix_wfs { 0 }
 Number of WFS pixels. One per WFS mode.
std::vector< realT > m_ron_wfs { 0 }
 WFS readout noise [electrons/pix]. One per WFS mode.
std::vector< realT > m_Fbg { 0 }
 Background flux, [photons/sec/pixel]. One per WFS mode.
std::vector< realT > m_minTauWFS { 0 }
 Minimum WFS exposure time [sec]. One per WFS mode.
bool m_bin_npix { true }
 Flag controlling whether or not to bin WFS pixels according to the actuator spacing.
int m_bin_opt { 0 }
realT m_tauWFS { 0 }
 Actual WFS exposure time [sec].
realT m_deltaTau { 0 }
 Loop latency [sec].
bool m_optTau { true }
realT m_lam_sci { 0 }
 Science wavelength [m].
realT m_zeta { 0 }
 Zenith angle [radians].
realT m_secZeta { 1 }
 Secant of the Zenith angle (calculated).
int m_fit_mn_max { 100 }
 Maximum spatial frequency index to use for fitting error calculation.
bool m_circularLimit { false }
 Flag to indicate that the spatial frequency limit is circular, not square.
realT m_spatialFilter_ku { std::numeric_limits<realT>::max() }
 The spatial filter cutoff in u, [m^-1].
realT m_spatialFilter_kv { std::numeric_limits<realT>::max() }
 The spatial filter cutoff in v, [m^-1].
realT m_ncp_wfe { 0 }
 Static WFE [m rms].
realT m_ncp_alpha { 2 }
 Power-law exponent for the NCP aberations. Default is 2.
realT m_F0 { 0 }
 0 mag flux from star at WFS [photons/sec]
realT m_starMag { 0 }
 The magnitude of the star.
bool m_specsChanged { true }
 Flag to indicate that a specification has changed.
bool m_dminChanged { true }
 Flag to indicate that d_min has changed.
Eigen::Array< int, -1, -1 > m_controlledModes
 Map of which modes are under control. Set by calcStrehl.
realT m_wfeMeasurement { 0 }
 Total WFE due to measurement a error [rad^2 at m_lam_sci].
realT m_wfeTimeDelay { 0 }
 Total WFE due to time delay [rad^2 at m_lam_sci].
realT m_wfeFitting { 0 }
 Total WFE due to fitting error [rad^2 at m_lam_sci].
realT m_wfeChromScintOPD { 0 }
 Total WFE due to the chromaticity of scintillation OPD [rad^2 at lam_sc].
realT m_wfeChromIndex { 0 }
 Total WFE due to the chromaticity of the index of refraction [rad^2 at lam_Sci].
realT m_wfeAnisoOPD { 0 }
 Total WFE due to dispersive anisoplanatism OPD.
realT m_wfeNCP { 0 }
 Total WFE due to NCP errors [rad^2 at m_lam_sci].
realT m_wfeVar { 0 }
 The WFE variance, in meters^2. Never use this directly, instead use wfeVar().
realT m_strehl { 0 }
 Strehl ratio, a calculated quantity. Never use this directdy, instead use strehl().

Overall WFE and Strehl Ratio

Functions to calculate the total WFE and Strehl ratio.

realT wfeVar ()
 Get the current value of the total WFE variance.
realT strehl (realT d, int b)
 Get the Strehl ratio for a given actuator pitch and WFS WFS mode.
realT strehl ()
 Get the current Strehl ratio.
void calcStrehl ()
 Calculate the component WFE, total WFE, and Strehl ratio.

Constructor & Destructor Documentation

◆ aoSystem()

template<typename realT, class inputSpectT, typename iosT>
mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::aoSystem ( )

Default c'tor.

Calls initialize().

Definition at line 1173 of file aoSystem.hpp.

References wfsBeta().

◆ ~aoSystem()

template<typename realT, class inputSpectT, typename iosT>
mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::~aoSystem ( )

Destructor.

Definition at line 1179 of file aoSystem.hpp.

References m_ownWfsBeta, and m_wfsBeta.

Member Function Documentation

◆ beta_p()

template<typename realT, class inputSpectT, typename iosT>
realT mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::beta_p ( realT m,
realT n )

Get the value of beta_p for a spatial frequency.

beta_p is the photon noise sensitivity of the WFS.

Returns
beta_p as calculated by the WFS.
Parameters
[in]mthe spatial frequency index
[in]nthe spatial frequency index

Definition at line 1373 of file aoSystem.hpp.

References d_opt(), m_D, m_lam_sci, m_wfsBeta, and mx::paramnotset.

Referenced by measurementError(), and optimumTauWFS().

◆ beta_r()

template<typename realT, class inputSpectT, typename iosT>
realT mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::beta_r ( realT m,
realT n )

Get the value of beta_r for a spatial frequency.

beta_r is the read noise sensitivity of the WFS.

Returns
beta_r as calculated by the WFS.
Parameters
[in]mthe spatial frequency index
[in]nthe spatial frequency index

Definition at line 1384 of file aoSystem.hpp.

References d_opt(), m_D, m_lam_sci, m_wfsBeta, and mx::paramnotset.

Referenced by measurementError(), and optimumTauWFS().

◆ bin_npix() [1/2]

template<typename realT, class inputSpectT, typename iosT>
bool mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::bin_npix ( )

Get the value of the pixel binngin flag.

Returns

Definition at line 1609 of file aoSystem.hpp.

References m_bin_npix.

◆ bin_npix() [2/2]

template<typename realT, class inputSpectT, typename iosT>
void mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::bin_npix ( bool bnp)

Set the value of the pixel binning flag.

Parameters
[in]bnpis the new value of m_bin_npix

Definition at line 1598 of file aoSystem.hpp.

References m_bin_npix, m_dminChanged, and m_specsChanged.

Referenced by loadConfig(), and TEST_CASE().

◆ bin_opt()

template<typename realT, class inputSpectT, typename iosT>
int mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::bin_opt ( )

Get the value of the optimum binning factor/index.

If WFS modes are used, this is the mode index (0 to N-1). If not, it is 1 minus the pixel binning factor. It is always 1 minus the actuator binning factor. This calls opt_d() to perform the optimization if needed.

Returns
the current value of m_bin_opt.

Definition at line 1615 of file aoSystem.hpp.

References d_opt(), and m_bin_opt.

◆ C0()

template<typename realT, class inputSpectT, typename iosT>
realT mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::C0 ( realT m,
realT n,
bool normStrehl = true )

Calculate the contrast due to uncorrected phase, C0.

Contrast C0 is the uncorrected phase, with the effects of scintillation included. See Guyon (2005) [14] and the updated derivation in Males & Guyon (2018) [20]

Note
this is the raw PSD, it must be convolved with the PSF for the true contrast.
Returns
C0.
Parameters
[in]mis the spatial frequency index in u
[in]nis the spatial frequency index in v
[in]normStrehlflag controls whether the contrast is normalized by Strehl ratio

Definition at line 2541 of file aoSystem.hpp.

References C0var(), and C_().

Referenced by C0Map().

◆ C0Map()

template<typename realT, class inputSpectT, typename iosT>
template<typename imageT>
void mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::C0Map ( imageT & map,
bool normStrehl )

Calculate a 2D map of contrast C0.

Template Parameters
imageTis an Eigen-like image type.
Parameters
[in]mapthe map image to be filled in with contrast

Definition at line 2549 of file aoSystem.hpp.

References C0(), and C_Map().

◆ C0var()

template<typename realT, class inputSpectT, typename iosT>
realT mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::C0var ( realT m,
realT n )

Calculate the residual variance due to uncorrected phase at a spatial frequency.

Used to calculate contrast C0().

Returns
variance at (m,n).
Todo
handle multiple layers
Parameters
[in]mis the spatial frequency index in u
[in]nis the spatial frequency index in v

Definition at line 2532 of file aoSystem.hpp.

References m_D, m_lam_sci, and m_secZeta.

Referenced by C0(), and C6var().

◆ C1()

template<typename realT, class inputSpectT, typename iosT>
realT mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::C1 ( realT m,
realT n,
bool normStrehl = true )

Calculate the contrast due to uncorrected amplitude, C1.

Contrast C1 is the uncorrected amplitude due to scintillation. See Guyon (2005) [14], and the updated derivation in Males & Guyon (2018) [20].

Returns
C0.
Parameters
[in]mis the spatial frequency index in u
[in]nis the spatial frequency index in v
[in]normStrehlflag controls whether the contrast is normalized by Strehl ratio

Definition at line 2565 of file aoSystem.hpp.

References C1var(), and C_().

Referenced by C1Map().

◆ C1Map()

template<typename realT, class inputSpectT, typename iosT>
template<typename imageT>
void mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::C1Map ( imageT & map,
bool normStrehl )

Calculate a 2D map of contrast C1.

The contrast is Strehl-normalized here.

Note
this is the raw PSD, it must be convolved with the PSF for the true contrast.
Template Parameters
imageTis an Eigen-like image type.
Parameters
[in]mapthe map image to be filled in with contrast

Definition at line 2572 of file aoSystem.hpp.

References C1(), and C_Map().

◆ C1var()

template<typename realT, class inputSpectT, typename iosT>
realT mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::C1var ( realT m,
realT n )

Calculate the residual variance due to uncorrected amplitude at a spatial frequency.

Used to calculate contrast C1().

Returns
variance at (m,n).
Todo
handle multiple layers
Parameters
[in]mis the spatial frequency index in u
[in]nis the spatial frequency index in v

Definition at line 2555 of file aoSystem.hpp.

References m_D, m_lam_sci, and m_secZeta.

Referenced by C1().

◆ C2()

template<typename realT, class inputSpectT, typename iosT>
realT mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::C2 ( realT m,
realT n,
bool normStrehl = true )

Calculate the contrast due to measurement and time delay errors in phase/OPD at a spatial frequency.

Contrast C2 is just the total variance due to time delay and measurement errors, divided by the Strehl ratio. See Guyon (2005) [14], and the updated derivation in Males & Guyon (2018) [20].

Returns
C2.
Parameters
[in]mis the spatial frequency index in u
[in]nis the spatial frequency index in v
[in]normStrehlflag controls whether the contrast is normalized by Strehl ratio.

Definition at line 2585 of file aoSystem.hpp.

References C2var(), and C_().

Referenced by C2Map().

◆ C2Map()

template<typename realT, class inputSpectT, typename iosT>
template<typename imageT>
void mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::C2Map ( imageT & map,
bool normStrehl )

Calculate a 2D map of contrast C2().

The contrast is Strehl-normalized here.

Note
this is the raw PSD, it must be convolved with the PSF for the true contrast.
Template Parameters
imageTis an Eigen-like image type.
Parameters
[in]mapthe map image to be filled in with contrast

Definition at line 2592 of file aoSystem.hpp.

References C2(), and C_Map().

◆ C2var()

template<typename realT, class inputSpectT, typename iosT>
realT mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::C2var ( realT m,
realT n )

Calculate the residual variance due to measurement and time delay errors in phase/OPD at a spatial frequency.

Used to calculate contrast C2().

Returns
variance at (m,n).
Parameters
[in]mis the spatial frequency index in u
[in]nis the spatial frequency index in v

Definition at line 2578 of file aoSystem.hpp.

References d_opt(), m_bin_opt, measurementError(), and timeDelayError().

Referenced by C2().

◆ C3()

template<typename realT, class inputSpectT, typename iosT>
realT mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::C3 ( realT m,
realT n,
bool normStrehl = true )

Calculate the contrast due to measurement and time delay errors in amplitude at a spatial frequency.

Contrast C3 is just the total variance due to time delay and measurement errors, divided by the Strehl ratio. See Guyon (2005) [14], and the updated derivation in Males & Guyon (2018) [20].

Returns
C3.
Parameters
[in]mis the spatial frequency index in u
[in]nis the spatial frequency index in v
[in]normStrehlflag controls whether the contrast is normalized by Strehl ratio.

Definition at line 2604 of file aoSystem.hpp.

References C3var(), and C_().

Referenced by C3Map().

◆ C3Map()

template<typename realT, class inputSpectT, typename iosT>
template<typename imageT>
void mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::C3Map ( imageT & map,
bool normStrehl )

Calculate a 2D map of contrast C3.

The contrast is Strehl-normalized here.

Note
this is the raw PSD, it must be convolved with the PSF for the true contrast.
Template Parameters
imageTis an Eigen-like image type.
Parameters
[in]mapthe map image to be filled in with contrast

Definition at line 2611 of file aoSystem.hpp.

References C3(), and C_Map().

◆ C3var()

template<typename realT, class inputSpectT, typename iosT>
realT mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::C3var ( realT m,
realT n )

Calculate the residual variance due to measurement and time delay errors in amplitude at a spatial frequency.

Used to calculate contrast C3().

Returns
variance at (m,n).
Parameters
[in]mis the spatial frequency index in u
[in]nis the spatial frequency index in v

Definition at line 2598 of file aoSystem.hpp.

Referenced by C3().

◆ C4()

template<typename realT, class inputSpectT, typename iosT>
realT mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::C4 ( realT m,
realT n,
bool normStrehl = true )

Calculate the contrast due to scintilation-OPD chromaticity.

Contrast C4 is due to the chromaticity of scintillation, causing the ODP measurement to be slightly incorrect at the science wavelength. See Guyon (2005) [14], and the updated derivation in Males & Guyon (2018) [20].

Returns
C4.
Parameters
[in]mis the spatial frequency index in u
[in]nis the spatial frequency index in v
[in]normStrehlflag controls whether the contrast is normalized by Strehl ratio.

Definition at line 2628 of file aoSystem.hpp.

References C4var(), and C_().

Referenced by C4Map().

◆ C4Map()

template<typename realT, class inputSpectT, typename iosT>
template<typename imageT>
void mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::C4Map ( imageT & map,
bool normStrehl )

Calculate a 2D map of contrast C4.

The contrast is Strehl-normalized here.

Note
this is the raw PSD, it must be convolved with the PSF for the true contrast.
Template Parameters
imageTis an Eigen-like image type.
Parameters
[in]mapthe map image to be filled in with contrast

Definition at line 2635 of file aoSystem.hpp.

References C4(), and C_Map().

◆ C4var()

template<typename realT, class inputSpectT, typename iosT>
realT mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::C4var ( realT m,
realT n )

Calculate the residual variance due to scintilation-OPD chromaticity.

Used to calculate contrast C4().

Returns
variance at (m,n).
Todo
handle multiple layers
Parameters
[in]mis the spatial frequency index in u
[in]nis the spatial frequency index in v

Definition at line 2617 of file aoSystem.hpp.

References m_D, m_lam_sci, m_lam_wfs, and m_secZeta.

Referenced by C4(), and chromScintOPDError().

◆ C5()

template<typename realT, class inputSpectT, typename iosT>
realT mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::C5 ( realT m,
realT n,
bool normStrehl = true )

Calculate the contrast due to scintilation-amplitude chromaticity.

Contrast C5 is due to the chromaticity of scintillation, causing the amplitude measurement to be slightly incorrect at the science wavelength. See Guyon (2005) [14], and the updated derivation in Males & Guyon (2018) [20].

Returns
C4.
Parameters
[in]mis the spatial frequency index in u
[in]nis the spatial frequency index in v
[in]normStrehlflag controls whether the contrast is normalized by Strehl ratio.

Definition at line 2652 of file aoSystem.hpp.

References C5var(), and C_().

Referenced by C5Map().

◆ C5Map()

template<typename realT, class inputSpectT, typename iosT>
template<typename imageT>
void mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::C5Map ( imageT & map,
bool normStrehl )

Calculate a 2D map of contrast C5.

The contrast is Strehl-normalized here.

Note
this is the raw PSD, it must be convolved with the PSF for the true contrast.
Template Parameters
imageTis an Eigen-like image type.
Parameters
[in]mapthe map image to be filled in with contrast

Definition at line 2659 of file aoSystem.hpp.

References C5(), and C_Map().

◆ C5var()

template<typename realT, class inputSpectT, typename iosT>
realT mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::C5var ( realT m,
realT n )

Calculate the residual variance due to to scintilation-amplitude chromaticity.

Used to calculate contrast C5().

Note
this is the raw PSD, it must be convolved with the PSF for the true contrast.
Returns
variance at (m,n).
Todo
handle multiple layers
Parameters
[in]mis the spatial frequency index in u
[in]nis the spatial frequency index in v

Definition at line 2641 of file aoSystem.hpp.

References m_D, m_lam_sci, m_lam_wfs, and m_secZeta.

Referenced by C5(), and chromScintAmpError().

◆ C6()

template<typename realT, class inputSpectT, typename iosT>
realT mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::C6 ( realT m,
realT n,
bool normStrehl = true )

Calculate the contrast due to chromaticity of the index of refraction of air.

Contrast C6 is due to the index of refraction of air being wavelength dependent, causing the ODP measurement to be slightly incorrect at the science wavelength. See Guyon (2005) [14], and the updated derivation in Males & Guyon (2018) [20].

Returns
C6.
Parameters
[in]mis the spatial frequency index in u
[in]nis the spatial frequency index in v
normStrehlflag controls whether the contrast is normalized by Strehl ratio.

Definition at line 2674 of file aoSystem.hpp.

References C6var(), and C_().

Referenced by C6Map().

◆ C6Map()

template<typename realT, class inputSpectT, typename iosT>
template<typename imageT>
void mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::C6Map ( imageT & map,
bool normStrehl )

Calculate a 2D map of contrast C6.

The contrast is Strehl-normalized here.

Note
this is the raw PSD, it must be convolved with the PSF for the true contrast.
Template Parameters
imageTis an Eigen-like image type.
Parameters
[in]mapthe map image to be filled in with contrast

Definition at line 2681 of file aoSystem.hpp.

References C6(), and C_Map().

◆ C6var()

template<typename realT, class inputSpectT, typename iosT>
realT mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::C6var ( realT m,
realT n )

Calculate the residual variance due to chromaticity of the index of refraction of air.

Used to calculate contrast C6().

Returns
variance at (m,n).
Parameters
[in]mis the spatial frequency index in u
[in]nis the spatial frequency index in v

Definition at line 2665 of file aoSystem.hpp.

References C0var(), m_lam_sci, and m_lam_wfs.

Referenced by C6(), and chromIndexError().

◆ C7()

template<typename realT, class inputSpectT, typename iosT>
realT mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::C7 ( realT m,
realT n,
bool normStrehl = true )

Calculate the contrast due to dispersive anisoplanatism.

Contrast C7 is due to atmospheric dispersion causing light at different wavelengths to take different paths through atmospheric turbulence. See Fitzgerald (2017, in prep).

Returns
C7.
Parameters
[in]mis the spatial frequency index in u
[in]nis the spatial frequency index in v
normStrehlflag controls whether the contrast is normalized by Strehl ratio.

Definition at line 2697 of file aoSystem.hpp.

References C7var(), and C_().

Referenced by C7Map().

◆ C7Map()

template<typename realT, class inputSpectT, typename iosT>
template<typename imageT>
void mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::C7Map ( imageT & map,
bool normStrehl )

Calculate a 2D map of contrast C7.

The contrast is Strehl-normalized here.

Note
this is the raw PSD, it must be convolved with the PSF for the true contrast.
Template Parameters
imageTis an Eigen-like image type.
Parameters
[in]mapthe map image to be filled in with contrast

Definition at line 2704 of file aoSystem.hpp.

References C7(), and C_Map().

◆ C7var()

template<typename realT, class inputSpectT, typename iosT>
realT mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::C7var ( realT m,
realT n )

Calculate the residual variance due to dispersive anisoplanatism.

Used to calculate contrast C7().

Returns
variance at (m,n).
Todo
this needs to handle multiple layers – do we violate an assumption of L_0 isn't constant?
Parameters
[in]mis the spatial frequency index in u
[in]nis the spatial frequency index in v

Definition at line 2687 of file aoSystem.hpp.

References m_D, m_lam_sci, m_lam_wfs, and m_secZeta.

Referenced by C7(), and dispAnisoOPDError().

◆ C_()

template<typename realT, class inputSpectT, typename iosT>
template<typename varFuncT>
realT mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::C_ ( int m,
int n,
bool normStrehl,
varFuncT varFunc,
int doFittingError )

Worker function for raw contrast fuctions.

The logic in this calculation is the same regardless of component, except for the calculation of variance. The varFunc function pointer is used to calculate the variance, otherwise This handles the other details such as Strehl normalization, fitting error (if appropriate), and bounds checking.

Note
this gives the raw PSD, it must be convolved with the PSF for the true contrast.
Template Parameters
varFuncTis a function-pointer-to-member (of this class) with signature realT(*f)(realT, realT)
Parameters
[in]mis the spatial frequency index in u/
[in]nis the spatial frequency index in v.
[in]normStrehlflag controls whether the contrast is normalized by Strehl ratio/
[in]varFuncthe variance function to use.
[in]doFittingErrorflag to describe how fitting error should be considered for this term: FITTING_ERROR_NO, FITTING_ERROR_ZERO, FITTING_ERROR_X, or FITTING_ERROR_Y.

Definition at line 2463 of file aoSystem.hpp.

References d_opt(), fittingError(), m_controlledModes, m_D, m_fit_mn_max, m_lam_sci, m_secZeta, and strehl().

Referenced by C0(), C1(), C2(), C3(), C4(), C5(), C6(), and C7().

◆ C_Map()

template<typename realT, class inputSpectT, typename iosT>
template<typename imageT, typename CfuncT>
void mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::C_Map ( imageT & im,
CfuncT Cfunc,
bool normStrehl )

Worker function for the contrast-map functions.

The map calculation is the same for all terms, except for the calculation of variance at each pixel. The Cfunc function pointer is used to actually get the contrast.

Note
this is the raw PSD, it must be convolved with the PSF for the true contrast.
Template Parameters
imageTis an Eigen-like image
CfuncTis a function-pointer-to-member (of this class) with signature realT (*f)(realT, realT, bool)
Parameters
[out]imthe map image to be filled in.
[in]Cfuncthe raw contrast function to use for filling in the map.
[in]normStrehlflag controlling whether or not the map is normalized by Strehl

Definition at line 2510 of file aoSystem.hpp.

Referenced by C0Map(), C1Map(), C2Map(), C3Map(), C4Map(), C5Map(), C6Map(), and C7Map().

◆ calcStrehl()

template<typename realT, class inputSpectT, typename iosT>
void mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::calcStrehl ( )
protected

◆ chromIndexError()

template<typename realT, class inputSpectT, typename iosT>
realT mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::chromIndexError ( int m,
int n )

Calculate the wavefront error due to chromaticity in the index of refraction at a given spatial frequency.

This totals the WFE from chromaticity in the index of refraction.

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Returns
the WFE in rad^2 rms at the science wavelength at (m,n).
Parameters
[in]mspecifies the u component of the spatial frequency
[in]nspecifies the v component of the spatial frequency

Definition at line 1973 of file aoSystem.hpp.

References C6var().

Referenced by calcStrehl(), and strehl().

◆ chromIndexErrorTotal()

template<typename realT, class inputSpectT, typename iosT>
realT mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::chromIndexErrorTotal ( )

Calculate the wavefront error due to chromaticity in the index of refraction at a specific spatial frequency.

This totals the WFE from chromaticity in the index of refraction for the optimum actuator spacing.

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Returns
the WFE in rad^2 rms at the science wavelength at (m,n).

Definition at line 1979 of file aoSystem.hpp.

References calcStrehl(), m_dminChanged, m_specsChanged, and m_wfeChromIndex.

◆ chromScintAmpError() [1/2]

template<typename _realT, class _inputSpectT, typename iosT = std::ostream>
realT mx::AO::analysis::aoSystem< _realT, _inputSpectT, iosT >::chromScintAmpError ( )

Calculate the wavefront error due to scintillation chromaticity in amplitude over all spatial frequencies.

Returns
the WFE in rad^2 rms at the science wavelength at (m,n).

◆ chromScintAmpError() [2/2]

template<typename realT, class inputSpectT, typename iosT>
realT mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::chromScintAmpError ( int m,
int n )

Calculate the wavefront error due to scintillation chromaticity in amplitude for a given spatial frequency.

Returns
the WFE in rad^2 rms at the science wavelength at (m,n).
Parameters
[in]mspecifies the u component of the spatial frequency
[in]nspecifies the v component of the spatial frequency

Definition at line 1949 of file aoSystem.hpp.

References C5var(), d_opt(), and m_D.

◆ chromScintOPDError()

template<typename realT, class inputSpectT, typename iosT>
realT mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::chromScintOPDError ( int m,
int n )

Calculate the wavefront error due to scintillation chromaticity in the OPD at a spatial frequency.

This totals the WFE from scintillation chromaticity in the OPD.

Returns
the WFE in rad^2 rms at the science wavelength at (m,n).
Parameters
[in]mspecifies the u component of the spatial frequency
[in]nspecifies the v component of the spatial frequency

Definition at line 1935 of file aoSystem.hpp.

References C4var().

Referenced by calcStrehl(), and strehl().

◆ chromScintOPDErrorTotal()

template<typename realT, class inputSpectT, typename iosT>
realT mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::chromScintOPDErrorTotal ( )

Calculate the wavefront error due to scintillation chromaticity in the OPD over all spatial frequencies.

This totals the WFE from scintillation chromaticity in the OPD for the optimum actuator spacing.

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Returns
the WFE in rad^2 rms at the science wavelength at (m,n).

Definition at line 1941 of file aoSystem.hpp.

References calcStrehl(), m_dminChanged, m_specsChanged, and m_wfeChromScintOPD.

◆ circularLimit() [1/2]

template<typename realT, class inputSpectT, typename iosT>
bool mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::circularLimit ( )

Get the value of the circularLimit flag.

Returns
the current value of m_circularLimit

Definition at line 1722 of file aoSystem.hpp.

References m_circularLimit.

◆ circularLimit() [2/2]

template<typename realT, class inputSpectT, typename iosT>
void mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::circularLimit ( bool cl)

Set the value of the circularLimit flag.

If this is true, then the spatial frequency limits are treated as a circle rather than a square. This will create a circular dark hole.

Parameters
[in]clthe new value of the circularLimit flag

Definition at line 1714 of file aoSystem.hpp.

References m_circularLimit, m_dminChanged, and m_specsChanged.

Referenced by loadConfig(), and TEST_CASE().

◆ controlledModes()

template<typename realT, class inputSpectT, typename iosT>
const Eigen::Array< int, -1, -1 > & mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::controlledModes ( )

Access the array of controlledModes.

This array indicates which modes are controlled after optimizeStrehl chooses them.

Returns
a const reference to m_controlledModes.

Definition at line 1824 of file aoSystem.hpp.

References calcStrehl(), m_controlledModes, m_dminChanged, and m_specsChanged.

◆ D() [1/2]

template<typename realT, class inputSpectT, typename iosT>
realT mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::D ( )

Get the value of the primary mirror diamter.

Returns
the current value of m_D.

Definition at line 1258 of file aoSystem.hpp.

References m_D.

◆ D() [2/2]

template<typename realT, class inputSpectT, typename iosT>
void mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::D ( realT nD)

◆ d_min() [1/4]

template<typename realT, class inputSpectT, typename iosT>
std::vector< realT > mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::d_min ( )

Get the minimum subaperture sampling for all WFS modes.

Returns
the current value of m_d_min.

Definition at line 1297 of file aoSystem.hpp.

References m_d_min.

◆ d_min() [2/4]

template<typename realT, class inputSpectT, typename iosT>
void mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::d_min ( const std::vector< realT > & nd)

Set the minimum subaperture sampling for each WFS mode.

This sets the vector

Parameters
[in]ndis the new values of m_d_min

Definition at line 1264 of file aoSystem.hpp.

References m_d_min, m_dminChanged, and m_specsChanged.

Referenced by dumpAOSystem(), loadConfig(), loadGuyon2005(), loadMagAOX(), and TEST_CASE().

◆ d_min() [3/4]

template<typename realT, class inputSpectT, typename iosT>
void mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::d_min ( int idx,
realT nd )

Set the minimum subaperture sampling for a given WFS mode.

This sets the entry in the vector, if it has the proper length.

Parameters
[in]idxthe index of the WFS mode
[in]ndis the new value of m_d_min[idx]

Definition at line 1272 of file aoSystem.hpp.

References m_d_min, m_dminChanged, m_specsChanged, and mx::sizeerr.

◆ d_min() [4/4]

template<typename realT, class inputSpectT, typename iosT>
realT mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::d_min ( size_t idx)

Get the minimum subaperture sampling for a given WFS mode.

Returns
the current value of m_d_min[idx]
Parameters
[in]idxthe index of the WFS mode.

Definition at line 1286 of file aoSystem.hpp.

References m_d_min, and mx::sizeerr.

◆ d_opt()

template<typename realT, class inputSpectT, typename iosT>
realT mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::d_opt ( )

Calculate the optimum actuator spacing.

Finds the value of m_d_opt where the fitting error is less than than the combined time delay and measurement error.

Returns
the current value of m_d_opt.
Todo
this should be in a separate valideModes function
Todo
investigate why we tolerate m_d_min = 0 here. Is this just a config error?

Definition at line 2117 of file aoSystem.hpp.

References m_bin_npix, m_bin_opt, m_D, m_d_min, m_d_opt, m_dminChanged, m_Fbg, m_minTauWFS, m_npix_wfs, m_optd, m_optd_delta, m_ron_wfs, mx::sizeerr, and strehl().

Referenced by beta_p(), beta_r(), bin_opt(), C2var(), C_(), calcStrehl(), chromScintAmpError(), dispAnisoAmpError(), optimumTauWFS(), and TEST_CASE().

◆ deltaTau() [1/2]

template<typename realT, class inputSpectT, typename iosT>
realT mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::deltaTau ( )

Get the value of m_deltaTau.

Returns
the current value of m_deltaTau.

Definition at line 1644 of file aoSystem.hpp.

References m_deltaTau.

◆ deltaTau() [2/2]

template<typename realT, class inputSpectT, typename iosT>
void mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::deltaTau ( realT ndel)

Set the value of m_deltaTau.

Parameters
[in]ndelis the new value of m_deltaTau

Definition at line 1636 of file aoSystem.hpp.

References m_deltaTau, m_dminChanged, and m_specsChanged.

Referenced by dumpAOSystem(), loadConfig(), and TEST_CASE().

◆ dispAnisoAmpError()

template<typename realT, class inputSpectT, typename iosT>
realT mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::dispAnisoAmpError ( )

Calculate the wavefront error due to dispersive anisoplanatism in the amplitude at a specific spatial frequency.

Returns
the WFE in rad^2 rms at the science wavelength at (m,n).

Definition at line 2001 of file aoSystem.hpp.

References d_opt(), m_circularLimit, and m_D.

◆ dispAnisoOPDError()

template<typename realT, class inputSpectT, typename iosT>
realT mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::dispAnisoOPDError ( int m,
int n )

Calculate the wavefront error due to dispersive anisoplanatism in the OPD at a given spatial frequency.

This calculates the WFE from dispersive anisoplanatism in the OPD.

Returns
the WFE in rad^2 rms at the science wavelength at (m,n).
Parameters
[in]mspecifies the u component of the spatial frequency
[in]nspecifies the v component of the spatial frequency

Definition at line 1987 of file aoSystem.hpp.

References C7var().

Referenced by calcStrehl(), and strehl().

◆ dispAnisoOPDErrorTotal()

template<typename realT, class inputSpectT, typename iosT>
realT mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::dispAnisoOPDErrorTotal ( )

Calculate the wavefront error due to dispersive anisoplanatism in the OPD over all specific spatial frequencies.

This totals the WFE from dispersive anisoplanatism in the OPD for the optimum actuator spacing.

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Returns
the WFE in rad^2 rms at the science wavelength at (m,n).

Definition at line 1993 of file aoSystem.hpp.

References calcStrehl(), m_dminChanged, m_specsChanged, and m_wfeAnisoOPD.

◆ dumpAOSystem()

template<typename realT, class inputSpectT, typename iosT>
iosT & mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::dumpAOSystem ( iosT & ios)

Output current parameters to a stream.

Outputs a formatted list of all current parameters.

Parameters
[in]iosa std::ostream-like stream.

Definition at line 2710 of file aoSystem.hpp.

References D(), d_min(), deltaTau(), mx::dumpGitStatus(), F0(), Fbg(), lam_sci(), lam_wfs(), m_bin_npix, m_d_min, m_fit_mn_max, m_ncp_alpha, m_ncp_wfe, m_optd, m_optTau, m_spatialFilter_ku, m_spatialFilter_kv, m_wfsBeta, minTauWFS(), npix_wfs(), optd_delta(), mx::paramnotset, ron_wfs(), starMag(), tauWFS(), and zeta().

◆ F0() [1/2]

template<typename realT, class inputSpectT, typename iosT>
realT mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::F0 ( )

Get the value of the 0 magnitude photon rate.

Returns
the current value of m_F0.

Definition at line 1792 of file aoSystem.hpp.

References m_F0.

◆ F0() [2/2]

template<typename realT, class inputSpectT, typename iosT>
void mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::F0 ( realT nF0)

Set the value of the 0 magnitude photon rate.

This is the photon rate at the WFS, photons/sec.

Parameters
[in]nF0is the new value of m_F0.

Definition at line 1784 of file aoSystem.hpp.

References m_dminChanged, m_F0, and m_specsChanged.

Referenced by dumpAOSystem(), loadConfig(), loadGMagAOX(), loadGuyon2005(), loadMagAOX(), and TEST_CASE().

◆ Fbg() [1/4]

template<typename realT, class inputSpectT, typename iosT>
std::vector< realT > mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::Fbg ( )

Get the value of the background flux for all WFS modes.

Returns
the current value of m_Fbg

Definition at line 1548 of file aoSystem.hpp.

References m_Fbg.

◆ Fbg() [2/4]

template<typename realT, class inputSpectT, typename iosT>
void mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::Fbg ( const std::vector< realT > & fbg)

Set the value of the background fluxes.

This sets the value of the background flux for each WFS mode

Parameters
[in]fbgis the new value of m_Fbg

Definition at line 1510 of file aoSystem.hpp.

References m_dminChanged, m_Fbg, and m_specsChanged.

Referenced by dumpAOSystem(), loadConfig(), loadGuyon2005(), loadMagAOX(), and TEST_CASE().

◆ Fbg() [3/4]

template<typename realT, class inputSpectT, typename iosT>
void mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::Fbg ( int idx,
realT fbg )

Set a single value of the background flux for a given WFS mode.

This sets the entry in the vector if the vector has the proper length

Parameters
[in]idxthe index of the WFS mode
[in]fbgis the new value of m_Fbg[idx]

Definition at line 1523 of file aoSystem.hpp.

References m_dminChanged, m_Fbg, m_specsChanged, and mx::sizeerr.

◆ Fbg() [4/4]

template<typename realT, class inputSpectT, typename iosT>
realT mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::Fbg ( size_t idx)

Get the value of the background flux for a given WFS mode.

Returns
m_Fbg[idx]
Parameters
[in]idxthe index of the WFS mode.

Definition at line 1537 of file aoSystem.hpp.

References m_Fbg, and mx::sizeerr.

◆ Fg() [1/2]

template<typename realT, class inputSpectT, typename iosT>
realT mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::Fg ( )

Get the photon rate at the current Star magnitude.

Calculates \( F_\gamma = F_0 10^{-0.4 m} \) where \( F_0 \) is m_F0 and \( m \) is m_starMag.

Returns
the current value of the current photon rate.

Definition at line 1818 of file aoSystem.hpp.

References Fg(), and m_starMag.

◆ Fg() [2/2]

template<typename realT, class inputSpectT, typename iosT>
realT mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::Fg ( realT mag)

The photon flux at a given star magnitude.

Returns
the photon flux of the star in the bandpass assumed by F0.
Parameters
[in]magis the magnitude of the star.

Definition at line 1812 of file aoSystem.hpp.

References m_F0.

Referenced by Fg(), optimumTauWFS(), signal2Noise2(), and TEST_CASE().

◆ fit_mn_max() [1/2]

template<typename realT, class inputSpectT, typename iosT>
int mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::fit_mn_max ( )

Get the value of m_fit_mn_max.

Definition at line 1708 of file aoSystem.hpp.

References m_fit_mn_max.

◆ fit_mn_max() [2/2]

template<typename realT, class inputSpectT, typename iosT>
void mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::fit_mn_max ( int mnm)

Set the value of m_fit_mn_max.

Parameters
[in]mnmis the new value of m_fit_mn_max

Definition at line 1700 of file aoSystem.hpp.

References m_fit_mn_max.

Referenced by loadConfig(), and TEST_CASE().

◆ fittingError()

template<typename realT, class inputSpectT, typename iosT>
realT mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::fittingError ( realT m,
realT n )

Calculate the fitting error at a specific spatial frequency.

Returns
the fitting error in rad^2 rms at the science wavelength at (m,n).
Todo
handle multiple layers
Parameters
[in]mspecifies the u component of the spatial frequency
[in]nspecifies the v component of the spatial frequency

Definition at line 1918 of file aoSystem.hpp.

References m_D, m_lam_sci, and m_secZeta.

Referenced by C_(), calcStrehl(), and strehl().

◆ fittingErrorTotal()

template<typename realT, class inputSpectT, typename iosT>
realT mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::fittingErrorTotal ( )

Calculate the total fitting error over all uncorrected spatial frequencies.

This totals the fitting WFE for the optimum actuator spacing and binning.

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Returns
the total fitting error.

Definition at line 1927 of file aoSystem.hpp.

References calcStrehl(), m_dminChanged, m_specsChanged, and m_wfeFitting.

◆ lam_sci() [1/2]

template<typename realT, class inputSpectT, typename iosT>
realT mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::lam_sci ( )

Get the science wavelength.

Returns
the current value of m_lam_sci.

Definition at line 1672 of file aoSystem.hpp.

References m_lam_sci.

◆ lam_sci() [2/2]

template<typename realT, class inputSpectT, typename iosT>
void mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::lam_sci ( realT nlam)

Set the science wavelength.

Parameters
[in]nlamis the new value of m_lam_sci

Definition at line 1664 of file aoSystem.hpp.

References m_dminChanged, m_lam_sci, and m_specsChanged.

Referenced by dumpAOSystem(), loadConfig(), loadGuyon2005(), loadMagAOX(), TEST_CASE(), TEST_CASE(), unitTest::ao_sim_turbAtmosphere_test::TEST_CASE(), and unitTest::ao_sim_turbSubHarmonic_test::TEST_CASE().

◆ lam_wfs() [1/2]

template<typename realT, class inputSpectT, typename iosT>
realT mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::lam_wfs ( )

Get the value of the WFS wavelength.

Returns
the current value of m_lam_wfs.

Definition at line 1416 of file aoSystem.hpp.

References m_lam_wfs.

◆ lam_wfs() [2/2]

template<typename realT, class inputSpectT, typename iosT>
void mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::lam_wfs ( realT nlam)

Set the value of the WFS wavelength.

Parameters
[in]nlamis the new value of m_lam_wfs

Definition at line 1408 of file aoSystem.hpp.

References m_dminChanged, m_lam_wfs, and m_specsChanged.

Referenced by dumpAOSystem(), loadConfig(), loadGuyon2005(), loadMagAOX(), TEST_CASE(), and TEST_CASE().

◆ loadConfig()

template<typename realT, class inputSpectT, typename iosT>
error_t mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::loadConfig ( app::appConfigurator & config)

Load the configuration of this class from a configurator.

Returns
error_t::noerror when the configured atmosphere is valid, or its typed validation error.
Parameters
[in]configthe app::configurator object

Definition at line 3056 of file aoSystem.hpp.

References bin_npix(), circularLimit(), D(), d_min(), deltaTau(), F0(), Fbg(), fit_mn_max(), mx::invalidarg, mx::app::appConfigurator::isSet(), lam_sci(), lam_wfs(), m_wfsBeta, minTauWFS(), ncp_alpha(), ncp_wfe(), npix_wfs(), optd(), optd_delta(), optTau(), ron_wfs(), spatialFilter_ku(), spatialFilter_kv(), starMag(), tauWFS(), wfsBeta(), and zeta().

Referenced by TEST_CASE(), and TEST_CASE().

◆ loadGMagAOX()

template<typename realT, class inputSpectT, typename iosT>
void mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::loadGMagAOX ( )

Load parameters corresponding to the G-MagAO-X system.

Definition at line 1234 of file aoSystem.hpp.

References D(), F0(), loadMagAOX(), m_dminChanged, m_specsChanged, and mx::math::pi().

◆ loadGuyon2005()

template<typename realT, class inputSpectT, typename iosT>
void mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::loadGuyon2005 ( )

Load the default parameters from Guyon, 2005 [14].

Definition at line 1188 of file aoSystem.hpp.

References D(), d_min(), F0(), Fbg(), lam_sci(), lam_wfs(), m_dminChanged, m_specsChanged, minTauWFS(), npix_wfs(), mx::math::pi(), ron_wfs(), starMag(), and tauWFS().

◆ loadMagAOX()

template<typename realT, class inputSpectT, typename iosT>
void mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::loadMagAOX ( )

Load parameters corresponding to the MagAO-X system.

Definition at line 1212 of file aoSystem.hpp.

References D(), d_min(), F0(), Fbg(), lam_sci(), lam_wfs(), m_dminChanged, m_specsChanged, minTauWFS(), npix_wfs(), ron_wfs(), and tauWFS().

Referenced by mx::AO::analysis::fourierCovarMap(), and loadGMagAOX().

◆ measurementError()

template<typename realT, class inputSpectT, typename iosT>
realT mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::measurementError ( realT m,
realT n,
realT d,
int b )

Calculate the measurement noise at a spatial frequency and specified actuator spacing.

Calculates the wavefront phase variance due measurement noise at \( k = (m/D)\hat{u} + (n/D)\hat{v} \).

Returns
the measurement noise in rad^2 rms at the science wavelength
Parameters
[in]mspecifies the u component of the spatial frequency
[in]nspecifies the v component of the spatial frequency
[in]dthe actuator spacing in meters
[in]bthe binning parameter. Either the WFS mode index, or the binning factor minus 1.

Definition at line 1853 of file aoSystem.hpp.

References beta_p(), beta_r(), m_D, m_lam_sci, m_lam_wfs, m_opticalGain, m_optTau, m_tauWFS, m_wfsBeta, optimumTauWFS(), mx::paramnotset, and signal2Noise2().

Referenced by C2var(), calcStrehl(), and strehl().

◆ measurementErrorTotal()

template<typename realT, class inputSpectT, typename iosT>
realT mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::measurementErrorTotal ( )

Calculate the total measurement error over all corrected spatial frequencies.

This totals the measurement WFE at the optimum actuator spacing and binning.

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Returns
the total WFE due to measurement error.

Definition at line 1879 of file aoSystem.hpp.

References calcStrehl(), m_dminChanged, m_specsChanged, and m_wfeMeasurement.

◆ minTauWFS() [1/4]

template<typename realT, class inputSpectT, typename iosT>
std::vector< realT > mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::minTauWFS ( )

Get the values of the minimum WFS exposure time.

Returns
the current value of m_minTauWFS.

Definition at line 1592 of file aoSystem.hpp.

References m_minTauWFS.

◆ minTauWFS() [2/4]

template<typename realT, class inputSpectT, typename iosT>
void mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::minTauWFS ( const std::vector< realT > & ntau)

Set the value of the minimum WFS exposure times.

This sets the vector of the minimum WFS exposure times

Parameters
[in]ntauis the new value of m_minTauWFS

Definition at line 1554 of file aoSystem.hpp.

References m_dminChanged, m_minTauWFS, and m_specsChanged.

Referenced by dumpAOSystem(), loadConfig(), loadGuyon2005(), loadMagAOX(), and TEST_CASE().

◆ minTauWFS() [3/4]

template<typename realT, class inputSpectT, typename iosT>
realT mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::minTauWFS ( size_t idx)

Get the value of the minimum WFS exposure time for a given binning.

Returns
the current value of m_minTauWFS[idx].
Parameters
[in]idxthe index of the WFS mode.

Definition at line 1581 of file aoSystem.hpp.

References m_minTauWFS, and mx::sizeerr.

◆ minTauWFS() [4/4]

template<typename realT, class inputSpectT, typename iosT>
void mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::minTauWFS ( size_t idx,
realT ntau )

Set a single value of the minimum WFS exposure time for a given WFS mode.

This sets the entry in the vector if the vector has sufficient length.

Parameters
[in]idxthe index of the WFS mode
[in]ntauis the new value of m_minTauWFS

Definition at line 1567 of file aoSystem.hpp.

References m_dminChanged, m_minTauWFS, m_specsChanged, and mx::sizeerr.

◆ ncp_alpha() [1/2]

template<typename realT, class inputSpectT, typename iosT>
realT mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::ncp_alpha ( )

Get the value of the non-common path WFE PSD index.

Returns
the current value of m_ncp_alpha.

Definition at line 1778 of file aoSystem.hpp.

References m_ncp_alpha.

◆ ncp_alpha() [2/2]

template<typename realT, class inputSpectT, typename iosT>
void mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::ncp_alpha ( realT alpha)

Set the value of the non-common path WFE PSD index.

Parameters
[in]alphais the new value of m_ncp_alpha

Definition at line 1770 of file aoSystem.hpp.

References m_dminChanged, m_ncp_alpha, and m_specsChanged.

Referenced by loadConfig(), and TEST_CASE().

◆ ncp_wfe() [1/2]

template<typename realT, class inputSpectT, typename iosT>
realT mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::ncp_wfe ( )

Get the value of the non-common path WFE.

Returns
the current value of m_ncp_wfe.

Definition at line 1764 of file aoSystem.hpp.

References m_ncp_wfe.

◆ ncp_wfe() [2/2]

template<typename realT, class inputSpectT, typename iosT>
void mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::ncp_wfe ( realT nwfe)

Set the value of the non-common path WFE.

Parameters
[in]nwfeis the new value of m_ncp_wfe

Definition at line 1756 of file aoSystem.hpp.

References m_dminChanged, m_ncp_wfe, and m_specsChanged.

Referenced by loadConfig(), and TEST_CASE().

◆ ncpError() [1/2]

template<typename realT, class inputSpectT, typename iosT>
realT mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::ncpError ( )

Calculate the total NCP variance in rad^2.

Returns
the total NCP variance.

Definition at line 2299 of file aoSystem.hpp.

References m_lam_sci, m_ncp_wfe, and mx::math::two_pi().

◆ ncpError() [2/2]

template<typename realT, class inputSpectT, typename iosT>
realT mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::ncpError ( int m,
int n )

Calculate the NCP variance at a spatial frequency.

Finds the NCP variance at \( k = (m/D)\hat{u} + (n/D)\hat{v} \).

Returns
the NCP variance at k.
Parameters
[in]mis the spatial frequency index in u
[in]nis the spatial frequency index in v

Definition at line 2275 of file aoSystem.hpp.

References m_D, m_fit_mn_max, m_ncp_alpha, ncpError(), and mx::math::two_pi().

Referenced by calcStrehl(), ncpError(), and strehl().

◆ npix_wfs() [1/4]

template<typename realT, class inputSpectT, typename iosT>
std::vector< realT > mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::npix_wfs ( )

Get the number of pixels in the WFS for all WFS modes.

Returns
the current value of m_npix_wfs

Definition at line 1460 of file aoSystem.hpp.

References m_npix_wfs.

◆ npix_wfs() [2/4]

template<typename realT, class inputSpectT, typename iosT>
void mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::npix_wfs ( const std::vector< realT > & npix)

Set the number of pixels in the WFS for each WFS mode.

This sets the vector.

Parameters
[in]npixis the new values of m_npix_wfs

Definition at line 1422 of file aoSystem.hpp.

References m_dminChanged, m_npix_wfs, and m_specsChanged.

Referenced by dumpAOSystem(), loadConfig(), loadGuyon2005(), loadMagAOX(), and TEST_CASE().

◆ npix_wfs() [3/4]

template<typename realT, class inputSpectT, typename iosT>
void mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::npix_wfs ( int idx,
realT npix )

Set the number of pixels in the WFS for a given WFS mode.

This sets the entry in the vector, if it has the proper length.

Parameters
[in]idxthe index of the WFS mode
[in]npixis the new value of m_npix_wfs[idx]

Definition at line 1435 of file aoSystem.hpp.

References m_dminChanged, m_npix_wfs, m_specsChanged, and mx::sizeerr.

◆ npix_wfs() [4/4]

template<typename realT, class inputSpectT, typename iosT>
realT mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::npix_wfs ( size_t idx)

Get the number of pixels in the WFS for a given WFS mode.

Returns
the current value of m_npix_wfs[idx]
Parameters
[in]idxthe index of the WFS mode.

Definition at line 1449 of file aoSystem.hpp.

References m_npix_wfs, and mx::sizeerr.

◆ optd() [1/2]

template<typename realT, class inputSpectT, typename iosT>
bool mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::optd ( )

Get the value of m_optd.

Returns
the new value of m_optd_delta.

Definition at line 1311 of file aoSystem.hpp.

References m_optd.

◆ optd() [2/2]

template<typename realT, class inputSpectT, typename iosT>
void mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::optd ( bool od)

Set whether or not the value of d is optimized or just set to m_d_min.

Parameters
[in]odis the new value of m_optd

Definition at line 1303 of file aoSystem.hpp.

References m_dminChanged, m_optd, and m_specsChanged.

Referenced by loadConfig(), and TEST_CASE().

◆ optd_delta() [1/2]

template<typename realT, class inputSpectT, typename iosT>
realT mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::optd_delta ( )

Get the value of the fractional change in actuator spacing for optimization..

Returns
the value of m_optd_delta.

Definition at line 1325 of file aoSystem.hpp.

References m_optd_delta.

◆ optd_delta() [2/2]

template<typename realT, class inputSpectT, typename iosT>
void mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::optd_delta ( realT odd)

Set the fractional change in actuator spacing for optimization.

Sets the fraction of m_d_min by which the optimizer changes actautor spacing.

Parameters
[in]oddis the new value of m_optd_delta

Definition at line 1317 of file aoSystem.hpp.

References m_dminChanged, m_optd_delta, and m_specsChanged.

Referenced by dumpAOSystem(), loadConfig(), and TEST_CASE().

◆ opticalGain() [1/2]

template<typename realT, class inputSpectT, typename iosT>
realT mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::opticalGain ( )

Get the value of the optical gain.

Optical gain is applied in the WFS noise calculation

Returns
the current value of m_opticalGain

Definition at line 1402 of file aoSystem.hpp.

References m_opticalGain.

◆ opticalGain() [2/2]

template<typename realT, class inputSpectT, typename iosT>
void mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::opticalGain ( realT og)

Set the value of the Optical Gain.

Parameters
[in]ogthe new value of m_opticalGain

Definition at line 1394 of file aoSystem.hpp.

References m_dminChanged, m_opticalGain, and m_specsChanged.

◆ optimumTauWFS() [1/2]

template<typename realT, class inputSpectT, typename iosT>
realT mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::optimumTauWFS ( realT m,
realT n )

Calculate the optimum exposure time for a given spatial frequency at the optimum actuator spacing.

Finds the optimum exposure time at \( k = (m/D)\hat{u} + (n/D)\hat{v} \). If optd == false this uses the minimum actuator spacing.

Todo
Check inclusion of X in parameters
Returns
the optimum expsoure time.
Parameters
[in]mis the spatial frequency index in u
[in]nis the spatial frequency index in v

Definition at line 2110 of file aoSystem.hpp.

References d_opt(), m_bin_opt, m_d_opt, and optimumTauWFS().

◆ optimumTauWFS() [2/2]

template<typename realT, class inputSpectT, typename iosT>
realT mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::optimumTauWFS ( realT m,
realT n,
realT d,
int b )

Calculate the optimum exposure time for a given spatial frequency at a specified actuator spacing.

Finds the optimum exposure time at \( k = (m/D)\hat{u} + (n/D)\hat{v} \).

Todo
Check inclusion of X in parameters
Returns
the optimum expsoure time.
Todo
handle multiple layers
Parameters
[in]mis the spatial frequency index in u
[in]nis the spatial frequency index in v
[in]dthe actuator spacing, in meters
[in]bthe binning parameter. Either the WFS mode index, or the binning factor minus 1.

Definition at line 2030 of file aoSystem.hpp.

References beta_p(), beta_r(), Fg(), m_bin_npix, m_D, m_deltaTau, m_F0, m_Fbg, m_lam_wfs, m_minTauWFS, m_npix_wfs, m_opticalGain, m_ron_wfs, m_secZeta, m_wfsBeta, mx::internal::mxlib_error_report(), mx::paramnotset, mx::math::quarticRoots(), and mx::math::two_pi().

Referenced by measurementError(), optimumTauWFS(), and timeDelayError().

◆ optTau() [1/2]

template<typename realT, class inputSpectT, typename iosT>
bool mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::optTau ( )

Get the value of m_optTau.

Returns
the current value of m_optTau.

Definition at line 1658 of file aoSystem.hpp.

References m_optTau.

◆ optTau() [2/2]

template<typename realT, class inputSpectT, typename iosT>
void mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::optTau ( bool ot)

Set the value of m_optTau.

Parameters
[in]otis the new value of m_optTau

Definition at line 1650 of file aoSystem.hpp.

References m_dminChanged, m_optTau, and m_specsChanged.

Referenced by loadConfig(), and TEST_CASE().

◆ ron_wfs() [1/4]

template<typename realT, class inputSpectT, typename iosT>
std::vector< realT > mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::ron_wfs ( )

Get the value of the WFS readout noise for all WFS modes.

Returns
the current value of m_ron_wfs

Definition at line 1504 of file aoSystem.hpp.

References m_ron_wfs.

◆ ron_wfs() [2/4]

template<typename realT, class inputSpectT, typename iosT>
void mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::ron_wfs ( const std::vector< realT > & nron)

Set the value of the WFS readout noise for each WFS mode.

This sets the vector.

Parameters
[in]nronis the new value of m_ron_wfs

Definition at line 1466 of file aoSystem.hpp.

References m_dminChanged, m_ron_wfs, and m_specsChanged.

Referenced by dumpAOSystem(), loadConfig(), loadGuyon2005(), loadMagAOX(), and TEST_CASE().

◆ ron_wfs() [3/4]

template<typename realT, class inputSpectT, typename iosT>
void mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::ron_wfs ( int idx,
realT nron )

Set the value of the WFS readout noise for a given bining mode.

This sets the entry in the vector if the vector has the proper length

Parameters
[in]idxthe index of the WFS mode
[in]nronis the new value of m_ron_wfs [idx]

Definition at line 1479 of file aoSystem.hpp.

References m_dminChanged, m_ron_wfs, m_specsChanged, and mx::sizeerr.

◆ ron_wfs() [4/4]

template<typename realT, class inputSpectT, typename iosT>
realT mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::ron_wfs ( size_t idx)

Get the value of the WFS readout noise for a given WFS mode.

Returns
the current value of m_ron_wfs[idx]
Parameters
[in]idxthe index of the WFS mode.

Definition at line 1493 of file aoSystem.hpp.

References m_ron_wfs, and mx::sizeerr.

◆ secZeta()

template<typename realT, class inputSpectT, typename iosT>
realT mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::secZeta ( )

Get the zecant of the zenith angle.

Returns
the current value of m_secZeta

Definition at line 1694 of file aoSystem.hpp.

References m_secZeta.

Referenced by TEST_CASE().

◆ setupConfig()

template<typename realT, class inputSpectT, typename iosT>
void mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::setupConfig ( app::appConfigurator & config)

Setup the configurator to configure this class.

Parameters
[in]configthe app::configurator object

Definition at line 2799 of file aoSystem.hpp.

References mx::app::appConfigurator::add().

Referenced by TEST_CASE(), and TEST_CASE().

◆ signal2Noise2()

template<typename realT, class inputSpectT, typename iosT>
realT mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::signal2Noise2 ( realT & Nph,
realT tau_wfs,
realT d,
int b )

Calculate the terms of the signal to noise ratio squared (S/N)^2 for the WFS measurement.

The S/N squared is

\[ (S/N)^2 = \frac{ F_\gamma^2 \tau_{wfs}^2 }{ F_\gamma \tau_{wfs} + n_{pix} F_{bg} \tau_{wfs} + n_{pix} \sigma_{ron}^2 } \]

Returns
the S/N squared
Parameters
[out]Nphthe number of photons
[in]tau_wfsspecifies the WFS exposure time. If 0, then optimumTauWFS is used
[in]dthe actuator spacing in meters, used if binning WFS pixels
[in]bthe binning parameter. Either the WFS mode index, or the binning factor minus 1.

Definition at line 1833 of file aoSystem.hpp.

References Fg(), m_bin_npix, m_Fbg, m_npix_wfs, and m_ron_wfs.

Referenced by measurementError().

◆ spatialFilter_ku() [1/2]

template<typename realT, class inputSpectT, typename iosT>
realT mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::spatialFilter_ku ( )

Get the value of spatialFilter_ku.

Returns
the current value of m_spatialFilter_ku

Definition at line 1736 of file aoSystem.hpp.

References m_spatialFilter_ku.

◆ spatialFilter_ku() [2/2]

template<typename realT, class inputSpectT, typename iosT>
void mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::spatialFilter_ku ( realT ku)

Set the value of spatialFilter_ku.

Parameters
[in]kuis the new value of spatialFilter_ku

Definition at line 1728 of file aoSystem.hpp.

References m_dminChanged, m_spatialFilter_ku, and m_specsChanged.

Referenced by loadConfig(), and TEST_CASE().

◆ spatialFilter_kv() [1/2]

template<typename realT, class inputSpectT, typename iosT>
realT mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::spatialFilter_kv ( )

Get the value of spatialFilter_kv.

Returns
the current value of m_spatialFilter_kv

Definition at line 1750 of file aoSystem.hpp.

References m_spatialFilter_kv.

◆ spatialFilter_kv() [2/2]

template<typename realT, class inputSpectT, typename iosT>
void mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::spatialFilter_kv ( realT kv)

Set the value of spatialFilter_kv.

Parameters
[in]kvis the new value of spatialFilter_kv

Definition at line 1742 of file aoSystem.hpp.

References m_dminChanged, m_spatialFilter_kv, and m_specsChanged.

Referenced by loadConfig(), and TEST_CASE().

◆ starMag() [1/2]

template<typename realT, class inputSpectT, typename iosT>
realT mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::starMag ( )

Get the value of the Star's magnitude.

Returns
the current value of m_starMag

Definition at line 1806 of file aoSystem.hpp.

References m_starMag.

◆ starMag() [2/2]

template<typename realT, class inputSpectT, typename iosT>
void mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::starMag ( realT nmag)

Set the value of the Star's magnitude.

Parameters
[in]nmagis the new value of m_starMag.

Definition at line 1798 of file aoSystem.hpp.

References m_dminChanged, m_specsChanged, and m_starMag.

Referenced by dumpAOSystem(), loadConfig(), loadGuyon2005(), and TEST_CASE().

◆ strehl() [1/2]

template<typename realT, class inputSpectT, typename iosT>
realT mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::strehl ( )

Get the current Strehl ratio.

If no changes, merely returns m_strehl. Calls calcStrehl if there are changes. Strehl is calculated using the extended Marechal approximation:

\[ S = e^{-\sigma_{wfe}^2} \]

where \( \sigma_{wfe}^2 \) is the current value of m_wfeVar.

Returns
the current value of m_strehl.

Definition at line 2453 of file aoSystem.hpp.

References calcStrehl(), m_dminChanged, m_specsChanged, and m_strehl.

◆ strehl() [2/2]

template<typename realT, class inputSpectT, typename iosT>
realT mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::strehl ( realT d,
int b )

Get the Strehl ratio for a given actuator pitch and WFS WFS mode.

Strehl is calculated using the extended Marechal approximation:

\[ S = e^{-\sigma_{wfe}^2} \]

where \( \sigma_{wfe}^2 \) is the WFE for the spacing and binning

Returns
the strehl for these values
Parameters
[in]dthe actuator spacing, in meters
[in]bthe binning parameter. Either the WFS mode index, or the binning factor minus 1.

Definition at line 2305 of file aoSystem.hpp.

References chromIndexError(), chromScintOPDError(), dispAnisoOPDError(), fittingError(), m_circularLimit, m_D, m_fit_mn_max, measurementError(), ncpError(), timeDelayError(), and wfeVar().

Referenced by C_(), and d_opt().

◆ tauWFS() [1/2]

template<typename realT, class inputSpectT, typename iosT>
realT mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::tauWFS ( )

Get the value of the minimum WFS exposure time.

Returns
the current value of m_tauWFS.

Definition at line 1630 of file aoSystem.hpp.

References m_tauWFS.

◆ tauWFS() [2/2]

template<typename realT, class inputSpectT, typename iosT>
void mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::tauWFS ( realT ntau)

Set the value of the WFS exposure time.

Parameters
[in]ntauis the new value of m_tauWFS

Definition at line 1622 of file aoSystem.hpp.

References m_dminChanged, m_specsChanged, and m_tauWFS.

Referenced by dumpAOSystem(), loadConfig(), loadGuyon2005(), loadMagAOX(), and TEST_CASE().

◆ timeDelayError()

template<typename realT, class inputSpectT, typename iosT>
realT mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::timeDelayError ( realT m,
realT n,
realT d,
int b )

Calculate the time delay at a spatial frequency at the optimum exposure time and the specified actuator spacing.

Calculates the wavefront phase variance due to time delay at \( f = (m/D)\hat{u} + (n/D)\hat{v} \).

Returns
the measurement noise in rad^2 rms at the science wavelength
Todo
handle multiple layers
Parameters
[in]mspecifies the u component of the spatial frequency
[in]nspecifies the v component of the spatial frequency
[in]dthe actuator spacing, in meters
[in]bthe binning parameter. Either the WFS mode index, or the binning factor minus 1.

Definition at line 1887 of file aoSystem.hpp.

References m_D, m_deltaTau, m_lam_sci, m_optTau, m_secZeta, m_tauWFS, optimumTauWFS(), and mx::math::two_pi().

Referenced by C2var(), calcStrehl(), and strehl().

◆ timeDelayErrorTotal()

template<typename realT, class inputSpectT, typename iosT>
realT mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::timeDelayErrorTotal ( )

Calculate the time delay error over all corrected spatial frequencies.

This totals the time delay WFE at the optimum actuator spacing and binning.

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Returns
the total WFE due to time delay.

Definition at line 1910 of file aoSystem.hpp.

References calcStrehl(), m_dminChanged, m_specsChanged, and m_wfeTimeDelay.

◆ wfeVar()

template<typename realT, class inputSpectT, typename iosT>
realT mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::wfeVar ( )

Get the current value of the total WFE variance.

If no changes, merely returns m_wfeVar. Calls calcStrehl if there are changes.

Returns
the current value of m_wfeVar;

Definition at line 2444 of file aoSystem.hpp.

References calcStrehl(), m_dminChanged, m_specsChanged, and m_wfeVar.

Referenced by strehl().

◆ wfsBeta() [1/3]

template<typename realT, class inputSpectT, typename iosT>
wfs< realT, iosT > * mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::wfsBeta ( )

Get the WFS Beta pointer.

Returns
a pointer to the current m_wfsBeta

Definition at line 1367 of file aoSystem.hpp.

References m_wfsBeta.

◆ wfsBeta() [2/3]

template<typename realT, class inputSpectT, typename iosT>
template<typename wfsT>
void mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::wfsBeta ( const wfsT & w)

Set the WFS Beta pointer.

The WFS beta parameter determines the photon noise sensitivity.

Template Parameters
wfsTis a type derived from ao::analysis::wfs
Parameters
[in]wan object derived from ao::analysis::wfs base class

Definition at line 1332 of file aoSystem.hpp.

References m_ownWfsBeta, and m_wfsBeta.

Referenced by aoSystem(), loadConfig(), and TEST_CASE().

◆ wfsBeta() [3/3]

template<typename realT, class inputSpectT, typename iosT>
template<typename wfsT>
void mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::wfsBeta ( const wfsT * w)

Set the WFS Beta pointer.

The WFS beta parameter determines the photon noise sensitivity.

Template Parameters
wfsTis a type derived from ao::analysis::wfs
Parameters
[in]wpointer to an object derived from ao::analysis::wfs base class. If nullptr then a new object is allocated and managed.

Definition at line 1346 of file aoSystem.hpp.

References m_ownWfsBeta, and m_wfsBeta.

◆ zeta() [1/2]

template<typename realT, class inputSpectT, typename iosT>
realT mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::zeta ( )

Get the zenith angle.

Returns
the current value of m_zeta

Definition at line 1688 of file aoSystem.hpp.

References m_zeta.

◆ zeta() [2/2]

template<typename realT, class inputSpectT, typename iosT>
void mx::AO::analysis::aoSystem< realT, inputSpectT, iosT >::zeta ( realT nz)

Set the zenith angle, and its secant.

Parameters
[in]nzThe new value of m_zeta

Definition at line 1678 of file aoSystem.hpp.

References m_dminChanged, m_secZeta, m_specsChanged, and m_zeta.

Referenced by dumpAOSystem(), loadConfig(), and TEST_CASE().

Member Data Documentation

◆ m_bin_npix

template<typename _realT, class _inputSpectT, typename iosT = std::ostream>
bool mx::AO::analysis::aoSystem< _realT, _inputSpectT, iosT >::m_bin_npix { true }
protected

Flag controlling whether or not to bin WFS pixels according to the actuator spacing.

Definition at line 101 of file aoSystem.hpp.

Referenced by bin_npix(), bin_npix(), d_opt(), dumpAOSystem(), optimumTauWFS(), and signal2Noise2().

◆ m_bin_opt

template<typename _realT, class _inputSpectT, typename iosT = std::ostream>
int mx::AO::analysis::aoSystem< _realT, _inputSpectT, iosT >::m_bin_opt { 0 }
protected

The optimum binning factor. If WFS modes are used, this is the mode index (0 to N-1). If not, it is 1 minus the pixel binning factor. It is always 1 minus the actuator binning factor.

Definition at line 103 of file aoSystem.hpp.

Referenced by bin_opt(), C2var(), calcStrehl(), d_opt(), and optimumTauWFS().

◆ m_circularLimit

template<typename _realT, class _inputSpectT, typename iosT = std::ostream>
bool mx::AO::analysis::aoSystem< _realT, _inputSpectT, iosT >::m_circularLimit { false }
protected

Flag to indicate that the spatial frequency limit is circular, not square.

Definition at line 121 of file aoSystem.hpp.

Referenced by calcStrehl(), circularLimit(), circularLimit(), dispAnisoAmpError(), and strehl().

◆ m_controlledModes

template<typename _realT, class _inputSpectT, typename iosT = std::ostream>
Eigen::Array<int, -1, -1> mx::AO::analysis::aoSystem< _realT, _inputSpectT, iosT >::m_controlledModes
protected

Map of which modes are under control. Set by calcStrehl.

Definition at line 136 of file aoSystem.hpp.

Referenced by C_(), calcStrehl(), and controlledModes().

◆ m_D

template<typename _realT, class _inputSpectT, typename iosT = std::ostream>
realT mx::AO::analysis::aoSystem< _realT, _inputSpectT, iosT >::m_D { 0 }
protected

◆ m_d_min

template<typename _realT, class _inputSpectT, typename iosT = std::ostream>
std::vector<realT> mx::AO::analysis::aoSystem< _realT, _inputSpectT, iosT >::m_d_min { 0 }
protected

Minimum AO system actuator pitch [m]. One per WFS mode.

Definition at line 78 of file aoSystem.hpp.

Referenced by d_min(), d_min(), d_min(), d_min(), d_opt(), and dumpAOSystem().

◆ m_d_opt

template<typename _realT, class _inputSpectT, typename iosT = std::ostream>
realT mx::AO::analysis::aoSystem< _realT, _inputSpectT, iosT >::m_d_opt { 0 }
protected

Current optimum AO system actuator pitch [m].

Definition at line 80 of file aoSystem.hpp.

Referenced by d_opt(), and optimumTauWFS().

◆ m_deltaTau

template<typename _realT, class _inputSpectT, typename iosT = std::ostream>
realT mx::AO::analysis::aoSystem< _realT, _inputSpectT, iosT >::m_deltaTau { 0 }
protected

Loop latency [sec].

Definition at line 109 of file aoSystem.hpp.

Referenced by deltaTau(), deltaTau(), optimumTauWFS(), and timeDelayError().

◆ m_dminChanged

◆ m_F0

template<typename _realT, class _inputSpectT, typename iosT = std::ostream>
realT mx::AO::analysis::aoSystem< _realT, _inputSpectT, iosT >::m_F0 { 0 }
protected

0 mag flux from star at WFS [photons/sec]

Definition at line 129 of file aoSystem.hpp.

Referenced by F0(), F0(), Fg(), and optimumTauWFS().

◆ m_Fbg

template<typename _realT, class _inputSpectT, typename iosT = std::ostream>
std::vector<realT> mx::AO::analysis::aoSystem< _realT, _inputSpectT, iosT >::m_Fbg { 0 }
protected

Background flux, [photons/sec/pixel]. One per WFS mode.

Definition at line 98 of file aoSystem.hpp.

Referenced by d_opt(), Fbg(), Fbg(), Fbg(), Fbg(), optimumTauWFS(), and signal2Noise2().

◆ m_fit_mn_max

template<typename _realT, class _inputSpectT, typename iosT = std::ostream>
int mx::AO::analysis::aoSystem< _realT, _inputSpectT, iosT >::m_fit_mn_max { 100 }
protected

Maximum spatial frequency index to use for fitting error calculation.

Definition at line 119 of file aoSystem.hpp.

Referenced by C_(), calcStrehl(), dumpAOSystem(), fit_mn_max(), fit_mn_max(), ncpError(), and strehl().

◆ m_lam_sci

template<typename _realT, class _inputSpectT, typename iosT = std::ostream>
realT mx::AO::analysis::aoSystem< _realT, _inputSpectT, iosT >::m_lam_sci { 0 }
protected

Science wavelength [m].

Definition at line 114 of file aoSystem.hpp.

Referenced by beta_p(), beta_r(), C0var(), C1var(), C4var(), C5var(), C6var(), C7var(), C_(), fittingError(), lam_sci(), lam_sci(), measurementError(), ncpError(), and timeDelayError().

◆ m_lam_wfs

template<typename _realT, class _inputSpectT, typename iosT = std::ostream>
realT mx::AO::analysis::aoSystem< _realT, _inputSpectT, iosT >::m_lam_wfs { 0 }
protected

WFS wavelength [m].

Definition at line 93 of file aoSystem.hpp.

Referenced by C4var(), C5var(), C6var(), C7var(), lam_wfs(), lam_wfs(), measurementError(), and optimumTauWFS().

◆ m_minTauWFS

template<typename _realT, class _inputSpectT, typename iosT = std::ostream>
std::vector<realT> mx::AO::analysis::aoSystem< _realT, _inputSpectT, iosT >::m_minTauWFS { 0 }
protected

Minimum WFS exposure time [sec]. One per WFS mode.

Definition at line 99 of file aoSystem.hpp.

Referenced by d_opt(), minTauWFS(), minTauWFS(), minTauWFS(), minTauWFS(), and optimumTauWFS().

◆ m_ncp_alpha

template<typename _realT, class _inputSpectT, typename iosT = std::ostream>
realT mx::AO::analysis::aoSystem< _realT, _inputSpectT, iosT >::m_ncp_alpha { 2 }
protected

Power-law exponent for the NCP aberations. Default is 2.

Definition at line 127 of file aoSystem.hpp.

Referenced by dumpAOSystem(), ncp_alpha(), ncp_alpha(), and ncpError().

◆ m_ncp_wfe

template<typename _realT, class _inputSpectT, typename iosT = std::ostream>
realT mx::AO::analysis::aoSystem< _realT, _inputSpectT, iosT >::m_ncp_wfe { 0 }
protected

Static WFE [m rms].

Definition at line 126 of file aoSystem.hpp.

Referenced by dumpAOSystem(), ncp_wfe(), ncp_wfe(), and ncpError().

◆ m_npix_wfs

template<typename _realT, class _inputSpectT, typename iosT = std::ostream>
std::vector<realT> mx::AO::analysis::aoSystem< _realT, _inputSpectT, iosT >::m_npix_wfs { 0 }
protected

Number of WFS pixels. One per WFS mode.

Definition at line 96 of file aoSystem.hpp.

Referenced by d_opt(), npix_wfs(), npix_wfs(), npix_wfs(), npix_wfs(), optimumTauWFS(), and signal2Noise2().

◆ m_optd

template<typename _realT, class _inputSpectT, typename iosT = std::ostream>
bool mx::AO::analysis::aoSystem< _realT, _inputSpectT, iosT >::m_optd { false }
protected

Flag controlling whether actuator pitch is optimized (true) or just uses m_d_min (false). Default: true.

Definition at line 81 of file aoSystem.hpp.

Referenced by d_opt(), dumpAOSystem(), optd(), and optd().

◆ m_optd_delta

template<typename _realT, class _inputSpectT, typename iosT = std::ostream>
realT mx::AO::analysis::aoSystem< _realT, _inputSpectT, iosT >::m_optd_delta { 1.0 }
protected

The fractional change from d_min used in optimization. Set to 1 for integer binnings, > 1 for finer sampling.

Definition at line 83 of file aoSystem.hpp.

Referenced by d_opt(), optd_delta(), and optd_delta().

◆ m_opticalGain

template<typename _realT, class _inputSpectT, typename iosT = std::ostream>
realT mx::AO::analysis::aoSystem< _realT, _inputSpectT, iosT >::m_opticalGain { 1 }
protected

The optical gain of the WFS, 0-1. Treated as a sensitivity reduction in measurement noise. Default 1.

Definition at line 89 of file aoSystem.hpp.

Referenced by measurementError(), opticalGain(), opticalGain(), and optimumTauWFS().

◆ m_optTau

template<typename _realT, class _inputSpectT, typename iosT = std::ostream>
bool mx::AO::analysis::aoSystem< _realT, _inputSpectT, iosT >::m_optTau { true }
protected

Flag controlling whether optimum integration time is calculated (true) enforcing m_minTauWFS, or if m_tauWFS is used (false). Default: true.

Definition at line 111 of file aoSystem.hpp.

Referenced by dumpAOSystem(), measurementError(), optTau(), optTau(), and timeDelayError().

◆ m_ownWfsBeta

template<typename _realT, class _inputSpectT, typename iosT = std::ostream>
bool mx::AO::analysis::aoSystem< _realT, _inputSpectT, iosT >::m_ownWfsBeta { false }
protected

Flag indicating if the WFS beta_p pointer is owned by this instance.

Definition at line 87 of file aoSystem.hpp.

Referenced by ~aoSystem(), wfsBeta(), and wfsBeta().

◆ m_ron_wfs

template<typename _realT, class _inputSpectT, typename iosT = std::ostream>
std::vector<realT> mx::AO::analysis::aoSystem< _realT, _inputSpectT, iosT >::m_ron_wfs { 0 }
protected

WFS readout noise [electrons/pix]. One per WFS mode.

Definition at line 97 of file aoSystem.hpp.

Referenced by d_opt(), optimumTauWFS(), ron_wfs(), ron_wfs(), ron_wfs(), ron_wfs(), and signal2Noise2().

◆ m_secZeta

template<typename _realT, class _inputSpectT, typename iosT = std::ostream>
realT mx::AO::analysis::aoSystem< _realT, _inputSpectT, iosT >::m_secZeta { 1 }
protected

Secant of the Zenith angle (calculated).

Definition at line 117 of file aoSystem.hpp.

Referenced by C0var(), C1var(), C4var(), C5var(), C7var(), C_(), fittingError(), optimumTauWFS(), secZeta(), timeDelayError(), and zeta().

◆ m_spatialFilter_ku

template<typename _realT, class _inputSpectT, typename iosT = std::ostream>
realT mx::AO::analysis::aoSystem< _realT, _inputSpectT, iosT >::m_spatialFilter_ku { std::numeric_limits<realT>::max() }
protected

The spatial filter cutoff in u, [m^-1].

Definition at line 123 of file aoSystem.hpp.

Referenced by dumpAOSystem(), spatialFilter_ku(), and spatialFilter_ku().

◆ m_spatialFilter_kv

template<typename _realT, class _inputSpectT, typename iosT = std::ostream>
realT mx::AO::analysis::aoSystem< _realT, _inputSpectT, iosT >::m_spatialFilter_kv { std::numeric_limits<realT>::max() }
protected

The spatial filter cutoff in v, [m^-1].

Definition at line 124 of file aoSystem.hpp.

Referenced by dumpAOSystem(), spatialFilter_kv(), and spatialFilter_kv().

◆ m_specsChanged

◆ m_starMag

template<typename _realT, class _inputSpectT, typename iosT = std::ostream>
realT mx::AO::analysis::aoSystem< _realT, _inputSpectT, iosT >::m_starMag { 0 }
protected

The magnitude of the star.

Definition at line 131 of file aoSystem.hpp.

Referenced by Fg(), starMag(), and starMag().

◆ m_strehl

template<typename _realT, class _inputSpectT, typename iosT = std::ostream>
realT mx::AO::analysis::aoSystem< _realT, _inputSpectT, iosT >::m_strehl { 0 }
protected

Strehl ratio, a calculated quantity. Never use this directdy, instead use strehl().

Definition at line 148 of file aoSystem.hpp.

Referenced by calcStrehl(), and strehl().

◆ m_tauWFS

template<typename _realT, class _inputSpectT, typename iosT = std::ostream>
realT mx::AO::analysis::aoSystem< _realT, _inputSpectT, iosT >::m_tauWFS { 0 }
protected

Actual WFS exposure time [sec].

Definition at line 107 of file aoSystem.hpp.

Referenced by measurementError(), tauWFS(), tauWFS(), and timeDelayError().

◆ m_wfeAnisoOPD

template<typename _realT, class _inputSpectT, typename iosT = std::ostream>
realT mx::AO::analysis::aoSystem< _realT, _inputSpectT, iosT >::m_wfeAnisoOPD { 0 }
protected

Total WFE due to dispersive anisoplanatism OPD.

Definition at line 143 of file aoSystem.hpp.

Referenced by calcStrehl(), and dispAnisoOPDErrorTotal().

◆ m_wfeChromIndex

template<typename _realT, class _inputSpectT, typename iosT = std::ostream>
realT mx::AO::analysis::aoSystem< _realT, _inputSpectT, iosT >::m_wfeChromIndex { 0 }
protected

Total WFE due to the chromaticity of the index of refraction [rad^2 at lam_Sci].

Definition at line 142 of file aoSystem.hpp.

Referenced by calcStrehl(), and chromIndexErrorTotal().

◆ m_wfeChromScintOPD

template<typename _realT, class _inputSpectT, typename iosT = std::ostream>
realT mx::AO::analysis::aoSystem< _realT, _inputSpectT, iosT >::m_wfeChromScintOPD { 0 }
protected

Total WFE due to the chromaticity of scintillation OPD [rad^2 at lam_sc].

Definition at line 141 of file aoSystem.hpp.

Referenced by calcStrehl(), and chromScintOPDErrorTotal().

◆ m_wfeFitting

template<typename _realT, class _inputSpectT, typename iosT = std::ostream>
realT mx::AO::analysis::aoSystem< _realT, _inputSpectT, iosT >::m_wfeFitting { 0 }
protected

Total WFE due to fitting error [rad^2 at m_lam_sci].

Definition at line 140 of file aoSystem.hpp.

Referenced by calcStrehl(), and fittingErrorTotal().

◆ m_wfeMeasurement

template<typename _realT, class _inputSpectT, typename iosT = std::ostream>
realT mx::AO::analysis::aoSystem< _realT, _inputSpectT, iosT >::m_wfeMeasurement { 0 }
protected

Total WFE due to measurement a error [rad^2 at m_lam_sci].

Definition at line 138 of file aoSystem.hpp.

Referenced by calcStrehl(), and measurementErrorTotal().

◆ m_wfeNCP

template<typename _realT, class _inputSpectT, typename iosT = std::ostream>
realT mx::AO::analysis::aoSystem< _realT, _inputSpectT, iosT >::m_wfeNCP { 0 }
protected

Total WFE due to NCP errors [rad^2 at m_lam_sci].

Definition at line 145 of file aoSystem.hpp.

Referenced by calcStrehl().

◆ m_wfeTimeDelay

template<typename _realT, class _inputSpectT, typename iosT = std::ostream>
realT mx::AO::analysis::aoSystem< _realT, _inputSpectT, iosT >::m_wfeTimeDelay { 0 }
protected

Total WFE due to time delay [rad^2 at m_lam_sci].

Definition at line 139 of file aoSystem.hpp.

Referenced by calcStrehl(), and timeDelayErrorTotal().

◆ m_wfeVar

template<typename _realT, class _inputSpectT, typename iosT = std::ostream>
realT mx::AO::analysis::aoSystem< _realT, _inputSpectT, iosT >::m_wfeVar { 0 }
protected

The WFE variance, in meters^2. Never use this directly, instead use wfeVar().

Definition at line 147 of file aoSystem.hpp.

Referenced by calcStrehl(), and wfeVar().

◆ m_wfsBeta

template<typename _realT, class _inputSpectT, typename iosT = std::ostream>
wfs<realT, iosT>* mx::AO::analysis::aoSystem< _realT, _inputSpectT, iosT >::m_wfsBeta { nullptr }
protected

The WFS beta_p class.

Definition at line 86 of file aoSystem.hpp.

Referenced by ~aoSystem(), beta_p(), beta_r(), dumpAOSystem(), loadConfig(), measurementError(), optimumTauWFS(), wfsBeta(), wfsBeta(), and wfsBeta().

◆ m_zeta

template<typename _realT, class _inputSpectT, typename iosT = std::ostream>
realT mx::AO::analysis::aoSystem< _realT, _inputSpectT, iosT >::m_zeta { 0 }
protected

Zenith angle [radians].

Definition at line 116 of file aoSystem.hpp.

Referenced by zeta(), and zeta().


The documentation for this class was generated from the following file: