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