| 2 |
#define OrbitalInfo_h |
#define OrbitalInfo_h |
| 3 |
|
|
| 4 |
#include <TObject.h> |
#include <TObject.h> |
| 5 |
|
#include <algorithm> // EMILIANO |
| 6 |
#include <OrbitalInfoStruct.h> |
#include <OrbitalInfoStruct.h> |
| 7 |
|
#include <TClonesArray.h> |
| 8 |
|
|
| 9 |
class OrbitalInfo : public TObject { |
class OrbitalInfoTrkVar : public TObject { |
| 10 |
public: |
private: |
|
OrbitalInfo(); |
|
|
OrbitalInfo* GetOrbitalInfo(){return this;}; // Elena |
|
|
|
|
|
UInt_t absTime; //< Absolute Time |
|
|
// EM: added On Board Time and CPU Packet Number |
|
|
UInt_t OBT; //< On Board Time |
|
|
UInt_t pkt_num; //< CPU packet number |
|
|
|
|
|
// Position |
|
|
Float_t lon; // degrees from -180 to 180 |
|
|
Float_t lat; // degrees from -90 to 90 |
|
|
Float_t alt; // meters |
|
|
|
|
|
// Magnetic field |
|
|
|
|
|
// components (gauss) |
|
|
Float_t Bnorth; |
|
|
Float_t Beast; |
|
|
Float_t Bdown; |
|
|
|
|
|
// abs value (guass) |
|
|
Float_t Babs; |
|
|
|
|
|
// Minimum along the field line (that is at the magnetic equator) |
|
|
Float_t BB0; |
|
|
|
|
|
// L shell (in earth radii) |
|
|
Float_t L; |
|
|
|
|
|
// Dipolar magnetic coordinates |
|
|
Float_t londip; // degrees from -180 to 180 |
|
|
Float_t latdip; // degrees from -90 to 90 |
|
|
Float_t altdip; // meters |
|
|
|
|
|
// Corrected magnetic coordinates |
|
|
Float_t loncgm; // degrees from -180 to 180 |
|
|
Float_t latcgm; // degrees from -90 to 90 |
|
|
Float_t altcgm; // meters |
|
| 11 |
|
|
| 12 |
// Corrected B min magnetic coordinates |
public: |
| 13 |
Float_t loncbm; // degrees from -180 to 180 |
// |
| 14 |
Float_t latcbm; // degrees from -90 to 90 |
Int_t trkseqno; // tof sequ. number: -1=ToF standalone, 0=first Tracker track, ... |
| 15 |
Float_t altcbm; // meters |
// |
| 16 |
|
Float_t pitch; |
| 17 |
Float_t cutoff[20]; |
// |
| 18 |
|
OrbitalInfoTrkVar(); |
| 19 |
// Quaternions |
OrbitalInfoTrkVar* GetOrbitalInfoTrkVar(){return this;}; |
| 20 |
Float_t q0, q1, q2, q3; |
// |
| 21 |
|
void Clear(Option_t *t=""); |
| 22 |
|
// |
| 23 |
|
ClassDef(OrbitalInfoTrkVar, 1); |
| 24 |
|
// |
| 25 |
|
}; |
| 26 |
|
|
| 27 |
|
|
|
// Euler angles (nadir reference frame) |
|
|
Float_t theta, phi, etha; |
|
| 28 |
|
|
| 29 |
// Euler angles (local field reference frame) |
/** |
| 30 |
Float_t thetamag, phimag, ethamag; |
* Class that stores position, time, inclination, magnetic field and |
| 31 |
|
* cutoff informations. |
| 32 |
|
*/ |
| 33 |
|
class OrbitalInfo : public TObject { |
| 34 |
|
private: |
| 35 |
|
|
| 36 |
// Useful? |
public: |
| 37 |
Int_t goodAttitude[5]; |
TClonesArray *OrbitalInfoTrk; |
| 38 |
|
|
| 39 |
|
UInt_t absTime; ///< Absolute Time (seconds) |
| 40 |
|
UInt_t OBT; ///< On Board Time (ms) |
| 41 |
|
UInt_t pkt_num; ///< CPU packet number |
| 42 |
|
|
| 43 |
|
Float_t lon; ///< degrees from -180 to 180 |
| 44 |
|
Float_t lat; ///< degrees from -90 to 90 |
| 45 |
|
Float_t alt; ///< meters asl |
| 46 |
|
|
| 47 |
|
// B components. |
| 48 |
|
Float_t Bnorth; ///< gauss |
| 49 |
|
Float_t Beast; ///< gauss |
| 50 |
|
Float_t Bdown; ///< gauss |
| 51 |
|
|
| 52 |
|
Float_t Babs; ///< abs value (guass) |
| 53 |
|
|
| 54 |
|
Float_t BB0; ///< B abs over the B minimum on this field line |
| 55 |
|
|
| 56 |
|
Float_t L; ///< McIlwain's L shell (in earth radii) |
| 57 |
|
|
| 58 |
|
// Dipolar magnetic coordinates (not used). |
| 59 |
|
Float_t londip; ///< degrees from -180 to 180 |
| 60 |
|
Float_t latdip; ///< degrees from -90 to 90 |
| 61 |
|
Float_t altdip; ///< meters |
| 62 |
|
|
| 63 |
|
// Corrected magnetic coordinates (not used). |
| 64 |
|
Float_t loncgm; ///< degrees from -180 to 180 |
| 65 |
|
Float_t latcgm; ///< degrees from -90 to 90 |
| 66 |
|
Float_t altcgm; ///< meters |
| 67 |
|
|
| 68 |
|
// Corrected B min magnetic coordinates (not used). |
| 69 |
|
Float_t loncbm; ///< degrees from -180 to 180 |
| 70 |
|
Float_t latcbm; ///< degrees from -90 to 90 |
| 71 |
|
Float_t altcbm; ///< meters |
| 72 |
|
|
| 73 |
|
Float_t cutoff[17]; |
| 74 |
|
|
| 75 |
|
// Quaternions |
| 76 |
|
Float_t q0; ///< Quaternion 0 |
| 77 |
|
Float_t q1; ///< Quaternion 1 |
| 78 |
|
Float_t q2; ///< Quaternion 2 |
| 79 |
|
Float_t q3; ///< Quaternion 3 |
| 80 |
|
|
| 81 |
|
// Euler angles (Resurs velocity reference frame) |
| 82 |
|
Float_t theta; ///< Euler angle theta in the velocity reference frame (pitch) |
| 83 |
|
Float_t phi; ///< Euler angle phi in the velocity reference frame (yaw) |
| 84 |
|
Float_t etha; ///< Euler angle etha in the velocity reference frame (roll) |
| 85 |
|
|
| 86 |
|
// Pitch angles |
| 87 |
|
Float_t pamzenitangle; |
| 88 |
|
Float_t pamBangle; |
| 89 |
|
|
| 90 |
|
/** |
| 91 |
|
* The variable mode means a character time distant between two quaternions, inside which stay every events |
| 92 |
|
*/ |
| 93 |
|
Int_t mode; // 0 - means that time different pair of quaternions exuals to 0.25 seconds in R10 mode |
| 94 |
|
// (it mean that all quaternions in array is correct) |
| 95 |
|
// 1 - means that we have R10 mode and use just first value of quaternions array |
| 96 |
|
// 2 - means that we have non R10 mode and use every quaternions from array. |
| 97 |
|
// 3 - means normal transition from R10 to non R10 or from non R10 to R10. |
| 98 |
|
// 4 - means that we have eliminable hole between R10 and non R10 or between non R10 and R10 |
| 99 |
|
// 5 - means that we have uneliminable hole between R10 and non R10 or between non R10 and R10 |
| 100 |
|
// 6 - means that we have eliminable hole inside R10 (in such keys eliminable depends from other factors also) |
| 101 |
|
// 7 - means that we have uneliminable hole inside R10 |
| 102 |
|
// 8 - means that we have eliminable hole inside non R10 |
| 103 |
|
// 9 - means that we have uneliminable hole inside non R10 |
| 104 |
|
// 10 - means other unknown problems |
| 105 |
|
|
| 106 |
|
Int_t ntrk(){return OrbitalInfoTrk->GetEntries();}; |
| 107 |
|
/** |
| 108 |
|
\return Returns the B minimum along the field line. |
| 109 |
|
*/ |
| 110 |
Float_t GetB0() { return Babs/BB0; }; |
Float_t GetB0() { return Babs/BB0; }; |
| 111 |
|
|
| 112 |
// Stormer vertical cutoff using L shell: 14.9/L^2 (GeV). |
/** |
| 113 |
|
\return Returns the Stormer vertical cutoff using L shell: |
| 114 |
|
14.9/L^2 (GV/c). |
| 115 |
|
*/ |
| 116 |
Float_t GetCutoffSVL() { return cutoff[0]; }; |
Float_t GetCutoffSVL() { return cutoff[0]; }; |
| 117 |
|
|
| 118 |
void SetFromLevel2Struct(cOrbitalInfo *l2); |
void SetFromLevel2Struct(cOrbitalInfo *l2); |
| 119 |
void GetLevel2Struct(cOrbitalInfo *l2) const; |
void GetLevel2Struct(cOrbitalInfo *l2) const; |
| 120 |
|
// |
| 121 |
|
OrbitalInfo(); |
| 122 |
|
~OrbitalInfo(){Delete();}; //ELENA |
| 123 |
|
// |
| 124 |
|
OrbitalInfo* GetOrbitalInfo(){return this;}; // Elena |
| 125 |
|
void Delete(Option_t *t=""); //ELENA |
| 126 |
|
void Set();//ELENA |
| 127 |
|
// |
| 128 |
|
// |
| 129 |
|
|
| 130 |
void Clear(); // emiliano |
void Clear(Option_t *t=""); // emiliano |
| 131 |
// |
// |
| 132 |
ClassDef(OrbitalInfo, 2) |
ClassDef(OrbitalInfo, 5); |
| 133 |
}; |
}; |
| 134 |
#endif |
#endif |