SatAndLight  2.2.2-hubble
Simulation toolkit for space telescopes
TelescopeRead Class Reference

Read a Telescope object. More...

#include <TelescopeRead.h>

Inheritance diagram for TelescopeRead:
Collaboration diagram for TelescopeRead:

Public Member Functions

TH2F * GetAcceptance (const unsigned int aSourceIndex)
 Returns the telescope acceptance for a given source. More...
 
int GetAlpha (void)
 Returns the current Euler \(\alpha\) angle \([\mathrm{rad}]\). More...
 
int GetBeta (void)
 Returns the current Euler \(\beta\) angle \([\mathrm{rad}]\). More...
 
TGraph * GetEffectiveArea (const unsigned int aSourceIndex)
 Returns the telescope effective area for a given source. More...
 
int GetFocalLength (void)
 Returns the focal length \([\mathrm{mm}]\). More...
 
int GetGamma (void)
 Returns the current Euler \(\gamma\) angle \([\mathrm{rad}]\). More...
 
string GetName (void)
 Returns the telescope name. More...
 
unsigned int GetNsources (void)
 Returns the number of sources. More...
 
TH2F * GetPSF (const double aEnergy)
 Returns the point spread function at a given energy. More...
 
TH2F * GetPSF (const UInt_t aEnergyBinIndex)
 Returns the point spread function in a given energy bin. More...
 
TH3F * GetPSF (void)
 Returns the point spread function. More...
 
int GetSequenceAngle (TGraph **aAlpha, TGraph **aBeta, TGraph **aGamma)
 Returns the sequence of Euler angles as a function of time. More...
 
SourceReadGetSource (const unsigned int aSourceIndex)
 Returns a pointer to a SourceRead object. More...
 
Constructors and destructors
 TelescopeRead (const string aFilePattern, const string aName)
 TelescopeRead class constuctor. More...
 
virtual ~TelescopeRead (void)
 TelescopeRead class destructor. More...
 
- Public Member Functions inherited from CameraRead
int GetAmplitudeNbits (void)
 Returns the current camera number of bits to encode the raw amplitude. More...
 
int GetEntry (Long64_t entry=0, Int_t getall=0)
 Gets a new Camera entry. More...
 
TH2F * GetGainMap (void)
 Returns a pointer to the current gain map. More...
 
int GetHitN (void)
 Returns the current number of hits. More...
 
int GetHitParticleIndex (const UInt_t aHitIndex)
 Returns the particle index for a given hit index. More...
 
int GetHitSourceIndex (const UInt_t aHitIndex)
 Returns the source index for a given hit index. More...
 
double GetHitY (const UInt_t aHitIndex)
 Returns the Y position (intrinsic coordinates) for a given hit index. More...
 
double GetHitZ (const UInt_t aHitIndex)
 Returns the Z position (intrinsic coordinates) for a given hit index. More...
 
TH2S * GetMap (const CAMERA_MAPTYPE aMapType=pixamplitude)
 Returns a pointer to the current map. More...
 
TH2S * GetMapThreshold (TH2S *aAmplitudeThresholdMap)
 Returns the camera amplitude map after thresholding. More...
 
UInt_t GetNy (void)
 Returns the current number of pixels in the Y direction. More...
 
UInt_t GetNz (void)
 Returns the current number of pixels in the Z direction. More...
 
double GetPhotonResolutionY (void)
 Returns the current photon resolution (Y). More...
 
double GetPhotonResolutionZ (void)
 Returns the current photon resolution (Z). More...
 
int GetPixelAmplitudeMax (void)
 Returns the current camera pixel maximum amplitude range value. More...
 
int GetPixelError (const CAMERA_MAPTYPE aMapType, const int aPixIndexY, const int aPixIndexZ)
 Returns current error value of a given pixel and for a selected map type. More...
 
int GetPixelValue (const CAMERA_MAPTYPE aMapType, const int aPixIndexY, const int aPixIndexZ)
 Returns current value of a given pixel and for a selected map type. More...
 
double GetSizeX (void)
 Returns the current camera size in the X direction \([\mathrm{mm}]\). More...
 
double GetSizeY (void)
 Returns the current camera size in the Y direction \([\mathrm{mm}]\). More...
 
double GetSizeZ (void)
 Returns the current camera size in the Z direction \([\mathrm{mm}]\). More...
 
void GetSortedPixelIndex (int &aPixIndexY, int &aPixIndexZ, const int aPixIndex, const string aSortMethod="STANDARD")
 Returns the pixel indices (Y/Z) in a pre-defined order. More...
 
double GetThreshold (void)
 Returns the camera threshold. More...
 
ULong64_t GetTime (void)
 Returns the current camera time \([\mathrm{ms}]\). More...
 
ULong64_t GetTimeMaximum (void)
 Returns the maximum camera time \([\mathrm{ms}]\). More...
 
ULong64_t GetTimeMinimum (void)
 Returns the minimum camera time \([\mathrm{ms}]\). More...
 
UInt_t GetTimeResolution (void)
 Returns the current camera time resolution \([\mathrm{ms}]\). More...
 
UInt_t GetTimeResolutionMaximum (void)
 Returns the maximum camera time resolution \([\mathrm{ms}]\). More...
 
UInt_t GetTimeResolutionMinimum (void)
 Returns the minimum camera time resolution \([\mathrm{ms}]\). More...
 
void SetThreshold (const double aThreshold)
 Sets the camera threshold. More...
 
bool SetTime (const ULong64_t aTime)
 Sets the camera time. More...
 
 CameraRead (const string aFilePattern, const string aName)
 CameraRead class constuctor. More...
 
virtual ~CameraRead (void)
 CameraRead class destructor. More...
 
- Public Member Functions inherited from Rotation
double GetAlpha (void)
 Returns the current value of \(\alpha\) [rad]. More...
 
double GetBeta (void)
 Returns the current value of \(\beta\) [rad]. More...
 
double GetCosAlpha (void)
 Returns the current value of \(\cos(\alpha)\). More...
 
double GetCosBeta (void)
 Returns the current value of \(\cos(\beta)\). More...
 
double GetCosGamma (void)
 Returns the current value of \(\cos(\gamma)\). More...
 
double GetGamma (void)
 Returns the current value of \(\gamma\) [rad]. More...
 
double GetOmega (void)
 Returns the current value of \(\omega\). More...
 
double GetPsi (void)
 Returns the current value of \(\Psi\). More...
 
double GetRotationAngle (void)
 Returns the rotation angle from \(\cal{R}^{\prime}\) to \(\cal{R}\) [rad]. More...
 
double GetRotationAxisXp (void)
 Returns the \(x^{\prime}\) component in \(\cal{R}^{\prime}\) of a vector defining the rotation axis from \(\cal{R}^{\prime}\) to \(\cal{R}\). More...
 
double GetRotationAxisYp (void)
 Returns the \(y^{\prime}\) component in \(\cal{R}^{\prime}\) of a vector defining the rotation axis from \(\cal{R}^{\prime}\) to \(\cal{R}\). More...
 
double GetRotationAxisZp (void)
 Returns the \(z^{\prime}\) component in \(\cal{R}^{\prime}\) of a vector defining the rotation axis from \(\cal{R}^{\prime}\) to \(\cal{R}\). More...
 
double GetRxx ()
 Returns the rotation matrix element \(R_{xx}\). More...
 
double GetRxy ()
 Returns the rotation matrix element \(R_{xy}\). More...
 
double GetRxz ()
 Returns the rotation matrix element \(R_{xz}\). More...
 
double GetRyx ()
 Returns the rotation matrix element \(R_{yx}\). More...
 
double GetRyy ()
 Returns the rotation matrix element \(R_{yy}\). More...
 
double GetRyz ()
 Returns the rotation matrix element \(R_{yz}\). More...
 
double GetRzx ()
 Returns the rotation matrix element \(R_{zx}\). More...
 
double GetRzy ()
 Returns the rotation matrix element \(R_{zy}\). More...
 
double GetRzz ()
 Returns the rotation matrix element \(R_{zz}\). More...
 
double GetSinAlpha (void)
 Returns the current value of \(\sin(\alpha)\). More...
 
double GetSinBeta (void)
 Returns the current value of \(\sin(\beta)\). More...
 
double GetSinGamma (void)
 Returns the current value of \(\sin(\gamma)\). More...
 
double GetUpx (const double aThetaPrime, const double aPhiPrime)
 Returns the \(u^{\prime}_x\) coordinate in the \(\cal{R}^{\prime}\) reference frame. More...
 
double GetUpy (const double aThetaPrime, const double aPhiPrime)
 Returns the \(u^{\prime}_y\) coordinate in the \(\cal{R}^{\prime}\) reference frame. More...
 
double GetUpz (const double aThetaPrime)
 Returns the \(u^{\prime}_z\) coordinate in the \(\cal{R}^{\prime}\) reference frame. More...
 
double GetUx (const double aTheta)
 Returns the \(u_x\) coordinate in the \(\cal{R}\) reference frame. More...
 
double GetUy (const double aTheta, const double aPhi)
 Returns the \(u_y\) coordinate in the \(\cal{R}\) reference frame. More...
 
double GetUz (const double aTheta, const double aPhi)
 Returns the \(u_z\) coordinate in the \(\cal{R}\) reference frame. More...
 
void SetAlpha (const double aAlpha=0.0)
 Sets a new \(\alpha\) value. More...
 
void SetAlphaBetaGamma (const double aAlpha, const double aBeta, const double aGamma)
 Sets Euler angles, \(\alpha, \beta, \gamma\), for the rotation. More...
 
void SetBeta (const double aBeta=0.0)
 Sets a new \(\beta\) value. More...
 
void SetGamma (const double aGamma=0.0)
 Sets a new \(\gamma\) value. More...
 
void SetUnitQuaternion (const double aQ0, const double aQ1, const double aQ2, const double aQ3, const bool aRtoRprime=true)
 Sets Euler angles from a unit quaternion. More...
 
double TransformGetCosPhi (const double aThetaPrime, const double aPhiPrime)
 Returns the \(\cos\varphi\) in the reference frame \(\cal{R}\). More...
 
double TransformGetCosPhiPrime (const double aTheta, const double aPhi)
 Returns the \(\cos\varphi^{\prime}\) in the reference frame \(\cal{R}^{\prime}\). More...
 
double TransformGetCosTheta (const double aThetaPrime, const double aPhiPrime)
 Returns the \(\cos\theta\) in the reference frame \(\cal{R}\). More...
 
double TransformGetCosThetaPrime (const double aTheta, const double aPhi)
 Returns the \(\cos\theta^{\prime}\) in the reference frame \(\cal{R}^{\prime}\). More...
 
double TransformGetSinPhi (const double aThetaPrime, const double aPhiPrime)
 Returns the \(\sin\varphi\) in the reference frame \(\cal{R}\). More...
 
double TransformGetSinPhiPrime (const double aTheta, const double aPhi)
 Returns the \(\sin\varphi^{\prime}\) in the reference frame \(\cal{R}^{\prime}\). More...
 
double TransformGetSinTheta (const double aThetaPrime, const double aPhiPrime)
 Returns the \(\sin\theta\) in the reference frame \(\cal{R}\). More...
 
double TransformGetSinThetaPrime (const double aTheta, const double aPhi)
 Returns the \(\sin\theta^{\prime}\) in the reference frame \(\cal{R}^{\prime}\). More...
 
double TransformGetTanPhi (const double aThetaPrime, const double aPhiPrime)
 Returns the \(\tan\varphi\) in the reference frame \(\cal{R}\). More...
 
double TransformGetTanPhiPrime (const double aTheta, const double aPhi)
 Returns the \(\tan\varphi^{\prime}\) in the reference frame \(\cal{R}^{\prime}\). More...
 
double TransformGetTanTheta (const double aThetaPrime, const double aPhiPrime)
 Returns the \(\tan\theta\) in the reference frame \(\cal{R}\). More...
 
double TransformGetTanThetaCosPhi (const double aThetaPrime, const double aPhiPrime)
 Returns the \(\tan\theta\cos\varphi\) in the reference frame \(\cal{R}\). More...
 
double TransformGetTanThetaPrime (const double aTheta, const double aPhi)
 Returns the \(\tan\theta^{\prime}\) in the reference frame \(\cal{R}^{\prime}\). More...
 
double TransformGetTanThetaSinPhi (const double aThetaPrime, const double aPhiPrime)
 Returns the \(\tan\theta\sin\varphi\) in the reference frame \(\cal{R}\). More...
 
 Rotation (const double aAlpha, const double aBeta, const double aGamma)
 Rotation class constuctor. More...
 
virtual ~Rotation (void)
 Rotation class destructor. More...
 

Private Attributes

double rot_alpha
 rotation Euler \(\alpha\) angle \([\mathrm{rad}]\). More...
 
double rot_beta
 rotation Euler \(\beta\) angle \([\mathrm{rad}]\). More...
 
double rot_gamma
 rotation Euler \(\gamma\) angle \([\mathrm{rad}]\). More...
 
TH2F ** tel_acc
 telescope acceptance to sources. More...
 
TGraph ** tel_effarea
 telescope on-axis effective area to sources. More...
 
int tel_foclen
 telescope focal length \([\mathrm{mm}]\). More...
 
string tel_name
 telescope name. More...
 
TH3F * tel_psf
 telescope optical point spread function (PSF). More...
 
vector< SourceRead * > tel_src
 vector of sources. More...
 

Additional Inherited Members

- Protected Attributes inherited from Rotation
double rot_alpha
 Euler angle \(\alpha\). More...
 
double rot_beta
 Euler angle \(\beta\). More...
 
double rot_gamma
 Euler angle \(\gamma\). More...
 

Detailed Description

Read a Telescope object.

A Telescope object, saved in ROOT files, is extracted. This class offers many methods to read the sequence and the camera/pixels attributes.

Author
Florent Robinet

Constructor & Destructor Documentation

◆ TelescopeRead()

TelescopeRead::TelescopeRead ( const string  aFilePattern,
const string  aName 
)

TelescopeRead class constuctor.

The Telescope object is assumed to be a static object, meaning that its parameters do not change over time. Under this assumption, only the first ROOT file in the input pattern is loaded. The Telescope TTree is loaded and the parameters are extracted.

This class inherits from the CameraRead class. The camera object associated to the telescope is also loaded. All the telescope dynamics are managed at the camera level.

Finally, the telescope directory is scanned and astrophysical sources are detected and loaded with SourceRead.

Parameters
[in]aFilePatternROOT file pattern where the Telescope objet is saved.
[in]aNameTelescope name.

◆ ~TelescopeRead()

TelescopeRead::~TelescopeRead ( void  )
virtual

TelescopeRead class destructor.

Member Function Documentation

◆ GetAcceptance()

TH2F* TelescopeRead::GetAcceptance ( const unsigned int  aSourceIndex)
inline

Returns the telescope acceptance for a given source.

Parameters
[in]aSourceIndexSource index.
Returns
A pointer to a TH2F object, a pointer to NULL if the source index is out of range.
Warning
Do not delete the returned object as it is a part of the class.

◆ GetAlpha()

int TelescopeRead::GetAlpha ( void  )
inline

Returns the current Euler \(\alpha\) angle \([\mathrm{rad}]\).

This quantity is associated to a picture. Use the camera TChain to navigate through the pictures.

See also
CameraRead

◆ GetBeta()

int TelescopeRead::GetBeta ( void  )
inline

Returns the current Euler \(\beta\) angle \([\mathrm{rad}]\).

This quantity is associated to a picture. Use the camera TChain to navigate through the pictures.

See also
CameraRead

◆ GetEffectiveArea()

TGraph* TelescopeRead::GetEffectiveArea ( const unsigned int  aSourceIndex)
inline

Returns the telescope effective area for a given source.

Parameters
[in]aSourceIndexSource index.
Returns
A pointer to a TGraph object, a pointer to NULL if the source index is out of range.
Warning
Do not delete the returned object as it is a part of the class.

◆ GetFocalLength()

int TelescopeRead::GetFocalLength ( void  )
inline

Returns the focal length \([\mathrm{mm}]\).

◆ GetGamma()

int TelescopeRead::GetGamma ( void  )
inline

Returns the current Euler \(\gamma\) angle \([\mathrm{rad}]\).

This quantity is associated to a picture. Use the camera TChain to navigate through the pictures.

See also
CameraRead

◆ GetName()

string TelescopeRead::GetName ( void  )
inline

Returns the telescope name.

◆ GetNsources()

unsigned int TelescopeRead::GetNsources ( void  )
inline

Returns the number of sources.

◆ GetPSF() [1/3]

TH2F * TelescopeRead::GetPSF ( const double  aEnergy)

Returns the point spread function at a given energy.

Warning
The user is in charge of deleting the returned histogram.
Parameters
[in]aEnergyEnergy [keV].

◆ GetPSF() [2/3]

TH2F * TelescopeRead::GetPSF ( const UInt_t  aEnergyBinIndex)

Returns the point spread function in a given energy bin.

Warning
The user is in charge of deleting the returned histogram.
Parameters
[in]aEnergyBinIndexEnergy bin index.

◆ GetPSF() [3/3]

TH3F* TelescopeRead::GetPSF ( void  )
inline

Returns the point spread function.

Warning
Do not modify or delete the returned object as it is a part of the class.

◆ GetSequenceAngle()

int TelescopeRead::GetSequenceAngle ( TGraph **  aAlpha,
TGraph **  aBeta,
TGraph **  aGamma 
)

Returns the sequence of Euler angles as a function of time.

Three TGraph objects are returned. They described the three Euler angles, \((\alpha, \beta, \gamma)\), as a funtion of time. The time is taken in the middle of the time exposition.

Parameters
[out]aAlphaEuler angle \(\alpha\) [rad] as a function of time.
[out]aBetaEuler angle \(\beta\) [rad] as a function of time.
[out]aGammaEuler angle \(\gamma\) [rad] as a function of time.
Precondition
Only empty pointers should be provided. This function allocates the memory for the TGraph objects. The user should delete the object after use.
Returns
The number of points in the TGraph.

◆ GetSource()

SourceRead* TelescopeRead::GetSource ( const unsigned int  aSourceIndex)
inline

Returns a pointer to a SourceRead object.

Parameters
[in]aSourceIndexSource index.
Returns
A pointer to a SourceRead object, a pointer to NULL if the source index is out of range.

Member Data Documentation

◆ rot_alpha

double TelescopeRead::rot_alpha
private

rotation Euler \(\alpha\) angle \([\mathrm{rad}]\).

◆ rot_beta

double TelescopeRead::rot_beta
private

rotation Euler \(\beta\) angle \([\mathrm{rad}]\).

◆ rot_gamma

double TelescopeRead::rot_gamma
private

rotation Euler \(\gamma\) angle \([\mathrm{rad}]\).

◆ tel_acc

TH2F** TelescopeRead::tel_acc
private

telescope acceptance to sources.

◆ tel_effarea

TGraph** TelescopeRead::tel_effarea
private

telescope on-axis effective area to sources.

◆ tel_foclen

int TelescopeRead::tel_foclen
private

telescope focal length \([\mathrm{mm}]\).

◆ tel_name

string TelescopeRead::tel_name
private

telescope name.

◆ tel_psf

TH3F* TelescopeRead::tel_psf
private

telescope optical point spread function (PSF).

◆ tel_src

vector<SourceRead*> TelescopeRead::tel_src
private

vector of sources.


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