mxlib
c++ tools for analyzing astronomical data and other tasks by Jared R. Males. [git repo]
|
Definition at line 49 of file deformableMirror.hpp.
#include <ao/sim/deformableMirror.hpp>
Public Types | |
typedef _realT | realT |
typedef std::complex< realT > | complexT |
typedef wavefront< realT > | wavefrontT |
The wavefront data type. | |
typedef Eigen::Array< realT, Eigen::Dynamic, Eigen::Dynamic > | imageT |
The pupil image type. | |
typedef deformableMirrorSpec | specT |
Public Member Functions | |
deformableMirror () | |
Default c'tor. | |
~deformableMirror () | |
template<typename AOSysT > | |
void | initialize (AOSysT &AOSys, specT &spec, const std::string &pupil) |
std::string | name () |
std::string | basisName () |
int | settleTime () |
Get the settling time of the DM. | |
void | settleTime (int st) |
Set the settling time of the DM. | |
realT | calAmp () |
Get the calibration amplitude. | |
void | calAmp (realT ca) |
Set the calibration amplitude. | |
int | nModes () |
Get the number of modes in the M2C. | |
void | applyMode (wavefrontT &wf, int modeNo, realT amp, realT lambda) |
Apply a single mode. | |
template<typename commandT > | |
void | setShape (commandT &commandV) |
void | applyShape (wavefrontT &wf, realT lambda) |
void | setFilter (int width) |
Public Attributes | |
std::string | _name |
std::string | _basisName |
std::string | m_pupilName |
int | _settleTime |
Time to move from old shape to new shape, in loop time steps. | |
int | _settling |
int | _settleTime_counter |
float | _calAmp |
The amplitude used when measuring the response matrix of the current basis set. | |
imageT | m_pupil |
realT | m_pupilSum |
The system pupil, possibly apodized, etc. | |
std::vector< size_t > | m_idx |
The sum of the pupil mask, nominally the number of pixels. | |
Eigen::Array< realT, -1, -1 > | m_m2c |
The offset coordinates of non-zero pixels in the pupil. | |
improc::eigenCube< realT > | m_infF |
size_t | m_nActs |
size_t | m_nRows |
size_t | m_nCols |
realT | _settlingIter |
realT | _settledIter |
double | t0 |
double | t1 |
double | t_mm |
double | t_sum |
bool | _writeCommands |
bool | _commandFileOpen |
std::string | _commandFile |
std::ofstream | _commandFout |
realT | _commandLimit |
Eigen::Array< double, -1, -1 > | _pos |
Eigen::Array< double, -1, -1 > | _map |
sigproc::psdFilter< realT, 2 > | m_filter |
bool | m_applyFilter { false } |
Protected Attributes | |
imageT | _shape |
imageT | _oldShape |
imageT | _nextShape |
typedef std::complex<realT> mx::AO::sim::deformableMirror< _realT >::complexT |
Definition at line 54 of file deformableMirror.hpp.
typedef Eigen::Array<realT, Eigen::Dynamic, Eigen::Dynamic> mx::AO::sim::deformableMirror< _realT >::imageT |
The pupil image type.
Definition at line 60 of file deformableMirror.hpp.
typedef _realT mx::AO::sim::deformableMirror< _realT >::realT |
Definition at line 52 of file deformableMirror.hpp.
typedef deformableMirrorSpec mx::AO::sim::deformableMirror< _realT >::specT |
Definition at line 62 of file deformableMirror.hpp.
typedef wavefront<realT> mx::AO::sim::deformableMirror< _realT >::wavefrontT |
The wavefront data type.
Definition at line 57 of file deformableMirror.hpp.
mx::AO::sim::deformableMirror< _realT >::deformableMirror | ( | ) |
Default c'tor.
Definition at line 192 of file deformableMirror.hpp.
|
inline |
Definition at line 124 of file deformableMirror.hpp.
References mx::AO::sim::deformableMirror< _realT >::_commandFileOpen, and mx::AO::sim::deformableMirror< _realT >::_commandFout.
void mx::AO::sim::deformableMirror< _realT >::applyMode | ( | wavefrontT & | wf, |
int | modeNo, | ||
realT | amp, | ||
realT | lambda | ||
) |
Apply a single mode.
Definition at line 382 of file deformableMirror.hpp.
References mx::sys::get_curr_time(), mx::AO::sim::wavefront< _realT >::phase, and mx::math::six_fifths().
void mx::AO::sim::deformableMirror< _realT >::applyShape | ( | wavefrontT & | wf, |
realT | lambda | ||
) |
Definition at line 666 of file deformableMirror.hpp.
References BREAD_CRUMB, mx::AO::sim::wavefront< _realT >::iterNo, mx::AO::sim::wavefront< _realT >::phase, and mx::math::six_fifths().
|
inline |
Definition at line 140 of file deformableMirror.hpp.
References mx::AO::sim::deformableMirror< _realT >::_basisName.
_realT mx::AO::sim::deformableMirror< _realT >::calAmp | ( | ) |
Get the calibration amplitude.
The modal commands are relative to this value.
Definition at line 359 of file deformableMirror.hpp.
void mx::AO::sim::deformableMirror< _realT >::calAmp | ( | realT | ca | ) |
Set the calibration amplitude.
Definition at line 365 of file deformableMirror.hpp.
void mx::AO::sim::deformableMirror< _realT >::initialize | ( | AOSysT & | AOSys, |
specT & | spec, | ||
const std::string & | pupil | ||
) |
Definition at line 214 of file deformableMirror.hpp.
References mx::AO::path::dm::actuatorPositions(), mx::AO::sim::deformableMirrorSpec::basisName, mx::improc::eigenCube< dataT >::image(), mx::AO::path::dm::influenceFunctions(), mx::AO::path::dm::M2c(), mx::AO::path::basis::modes(), mx::AO::sim::deformableMirrorSpec::name, mx::improc::eigenCube< dataT >::planes(), mx::AO::path::pupil::pupilFile(), mx::fits::fitsFile< dataT >::read(), and mx::improc::eigenCube< dataT >::rows().
|
inline |
Definition at line 135 of file deformableMirror.hpp.
References mx::AO::sim::deformableMirror< _realT >::_name.
int mx::AO::sim::deformableMirror< _realT >::nModes | ( | ) |
Get the number of modes in the M2C.
Definition at line 376 of file deformableMirror.hpp.
Referenced by mx::AO::sim::wooferTweeterDM< _floatT >::nModes().
void mx::AO::sim::deformableMirror< _realT >::setFilter | ( | int | width | ) |
Definition at line 702 of file deformableMirror.hpp.
void mx::AO::sim::deformableMirror< _realT >::setShape | ( | commandT & | commandV | ) |
Definition at line 471 of file deformableMirror.hpp.
int mx::AO::sim::deformableMirror< _realT >::settleTime | ( | ) |
Get the settling time of the DM.
Definition at line 341 of file deformableMirror.hpp.
void mx::AO::sim::deformableMirror< _realT >::settleTime | ( | int | st | ) |
Set the settling time of the DM.
Definition at line 347 of file deformableMirror.hpp.
std::string mx::AO::sim::deformableMirror< _realT >::_basisName |
Definition at line 67 of file deformableMirror.hpp.
Referenced by mx::AO::sim::deformableMirror< _realT >::basisName().
float mx::AO::sim::deformableMirror< _realT >::_calAmp |
The amplitude used when measuring the response matrix of the current basis set.
Definition at line 79 of file deformableMirror.hpp.
std::string mx::AO::sim::deformableMirror< _realT >::_commandFile |
Definition at line 177 of file deformableMirror.hpp.
bool mx::AO::sim::deformableMirror< _realT >::_commandFileOpen |
Definition at line 176 of file deformableMirror.hpp.
Referenced by mx::AO::sim::deformableMirror< _realT >::~deformableMirror().
std::ofstream mx::AO::sim::deformableMirror< _realT >::_commandFout |
Definition at line 178 of file deformableMirror.hpp.
Referenced by mx::AO::sim::deformableMirror< _realT >::~deformableMirror().
realT mx::AO::sim::deformableMirror< _realT >::_commandLimit |
Definition at line 180 of file deformableMirror.hpp.
Eigen::Array<double, -1, -1> mx::AO::sim::deformableMirror< _realT >::_map |
Definition at line 182 of file deformableMirror.hpp.
std::string mx::AO::sim::deformableMirror< _realT >::_name |
Definition at line 65 of file deformableMirror.hpp.
Referenced by mx::AO::sim::deformableMirror< _realT >::name().
|
protected |
Definition at line 118 of file deformableMirror.hpp.
|
protected |
Definition at line 115 of file deformableMirror.hpp.
Eigen::Array<double, -1, -1> mx::AO::sim::deformableMirror< _realT >::_pos |
Definition at line 182 of file deformableMirror.hpp.
realT mx::AO::sim::deformableMirror< _realT >::_settledIter |
Definition at line 166 of file deformableMirror.hpp.
int mx::AO::sim::deformableMirror< _realT >::_settleTime |
Time to move from old shape to new shape, in loop time steps.
Definition at line 72 of file deformableMirror.hpp.
int mx::AO::sim::deformableMirror< _realT >::_settleTime_counter |
Definition at line 76 of file deformableMirror.hpp.
int mx::AO::sim::deformableMirror< _realT >::_settling |
Definition at line 74 of file deformableMirror.hpp.
realT mx::AO::sim::deformableMirror< _realT >::_settlingIter |
Definition at line 165 of file deformableMirror.hpp.
|
protected |
Definition at line 112 of file deformableMirror.hpp.
bool mx::AO::sim::deformableMirror< _realT >::_writeCommands |
Definition at line 175 of file deformableMirror.hpp.
bool mx::AO::sim::deformableMirror< _realT >::m_applyFilter { false } |
Definition at line 186 of file deformableMirror.hpp.
sigproc::psdFilter<realT, 2> mx::AO::sim::deformableMirror< _realT >::m_filter |
Definition at line 184 of file deformableMirror.hpp.
std::vector<size_t> mx::AO::sim::deformableMirror< _realT >::m_idx |
The sum of the pupil mask, nominally the number of pixels.
Definition at line 83 of file deformableMirror.hpp.
improc::eigenCube<realT> mx::AO::sim::deformableMirror< _realT >::m_infF |
Definition at line 90 of file deformableMirror.hpp.
Eigen::Array<realT, -1, -1> mx::AO::sim::deformableMirror< _realT >::m_m2c |
The offset coordinates of non-zero pixels in the pupil.
Definition at line 87 of file deformableMirror.hpp.
size_t mx::AO::sim::deformableMirror< _realT >::m_nActs |
Definition at line 106 of file deformableMirror.hpp.
size_t mx::AO::sim::deformableMirror< _realT >::m_nCols |
Definition at line 108 of file deformableMirror.hpp.
size_t mx::AO::sim::deformableMirror< _realT >::m_nRows |
Definition at line 107 of file deformableMirror.hpp.
imageT mx::AO::sim::deformableMirror< _realT >::m_pupil |
Definition at line 81 of file deformableMirror.hpp.
std::string mx::AO::sim::deformableMirror< _realT >::m_pupilName |
Definition at line 69 of file deformableMirror.hpp.
realT mx::AO::sim::deformableMirror< _realT >::m_pupilSum |
The system pupil, possibly apodized, etc.
Definition at line 82 of file deformableMirror.hpp.
double mx::AO::sim::deformableMirror< _realT >::t0 |
Definition at line 173 of file deformableMirror.hpp.
double mx::AO::sim::deformableMirror< _realT >::t1 |
Definition at line 173 of file deformableMirror.hpp.
double mx::AO::sim::deformableMirror< _realT >::t_mm |
Definition at line 173 of file deformableMirror.hpp.
double mx::AO::sim::deformableMirror< _realT >::t_sum |
Definition at line 173 of file deformableMirror.hpp.