QwGeant4
QweakSimUserCerenkov_RadiatorEvent.hh
Go to the documentation of this file.
1 /**
2  \class QweakSimUserCerenkov_RadiatorEvent
3 
4  \ingroup root
5 
6  \brief ROOT Subtree structure for Cerenkov radiator event
7 
8  */
9 
10 #ifndef QweakSimUserCerenkov_RadiatorEvent_h
11 #define QweakSimUserCerenkov_RadiatorEvent_h
12 
13 // system includes
14 #include <vector>
15 
16 // root includes
17 #include "TObject.h"
18 #include "TString.h"
19 
21 {
22 private:
23 
24  std::vector<Int_t> DetectorID; ///< ID of the detector in which this hit was registered
25  Int_t TrackID; ///< ID of the track from which this hit was generated
26 
27  std::vector<Float_t> GlobalTimeOfHit; ///< Global time when this hit was generated (ns)
28 
29  Int_t HasBeenHit; ///< Has this detector been hit? 0 = no, 5 = yes
30  std::vector<Int_t> EdgeEventFlag; ///< Was the distance between hit and exit position below 1.5 cm? 0 = no, 1 = yes
31  Int_t NbOfHits; ///< Number of hits in this detector
32 
33  /// \name Position of the hit in local coordinates (cm)
34  /// The local coordinates are defined in the \ref local_coordinate_system.
35  //@{
36  std::vector<Float_t> HitLocalPositionX; ///< (cm)
37  std::vector<Float_t> HitLocalPositionY; ///< (cm)
38  std::vector<Float_t> HitLocalPositionZ; ///< (cm)
39  //@}
40 
41  /// \name Position where the track exits the volume in local coordinates (cm)
42  /// The local coordinates are defined in the \ref local_coordinate_system.
43  //@{
44  std::vector<Float_t> HitLocalExitPositionX; ///< (cm)
45  std::vector<Float_t> HitLocalExitPositionY; ///< (cm)
46  std::vector<Float_t> HitLocalExitPositionZ; ///< (cm)
47  //@}
48 
49  /// \name Position of the hit in global coordinates
50  /// The global coordinates are defined in the \ref global_coordinate_system.
51  //@{
52  std::vector<Float_t> HitGlobalPositionX; ///< (cm)
53  std::vector<Float_t> HitGlobalPositionY; ///< (cm)
54  std::vector<Float_t> HitGlobalPositionZ; ///< (cm)
55  //@}
56 
57  /// \name Position in global coordinates of original vertex of the track from which this hit was generated
58  /// The global coordinates are defined in the \ref global_coordinate_system.
59  //@{
60  std::vector<Float_t> OriginVertexPositionX; ///< (cm)
61  std::vector<Float_t> OriginVertexPositionY; ///< (cm)
62  std::vector<Float_t> OriginVertexPositionZ; ///< (cm)
63  //@}
64 
65  /// \name Direction in global coordinates of original vertex of the track from which this hit was generated
66  /// The global coordinates are defined in the \ref global_coordinate_system.
67  //@{
68  std::vector<Float_t> OriginVertexMomentumDirectionX;
69  std::vector<Float_t> OriginVertexMomentumDirectionY;
70  std::vector<Float_t> OriginVertexMomentumDirectionZ;
71  std::vector<Float_t> OriginVertexThetaAngle; ///< (degrees)
72  std::vector<Float_t> OriginVertexPhiAngle; ///< (degrees)
73  //@}
74 
75  std::vector<Float_t> OriginVertexKineticEnergy;
76  std::vector<Float_t> OriginVertexTotalEnergy;
77 
78  /// \name Direction of the hit in local coordinates
79  /// The local coordinates are defined in the \ref local_coordinate_system.
80  //@{
81  std::vector<Float_t> LocalMomentumX; ///< (GeV/c)
82  std::vector<Float_t> LocalMomentumY; ///< (GeV/c)
83  std::vector<Float_t> LocalMomentumZ; ///< (GeV/c)
84  std::vector<Float_t> LocalThetaAngle; ///< (degrees)
85  std::vector<Float_t> LocalPhiAngle; ///< (degrees, but 90 degrees rotated to keep things interesting)
86  //@}
87 
88  /// \name Direction of the hit in global coordinates
89  /// The global coordinates are defined in the \ref global_coordinate_system.
90  //@{
91  std::vector<Float_t> GlobalMomentumX; ///< (GeV/c)
92  std::vector<Float_t> GlobalMomentumY; ///< (GeV/c)
93  std::vector<Float_t> GlobalMomentumZ; ///< (GeV/c)
94  std::vector<Float_t> GlobalThetaAngle; ///< (degrees)
95  std::vector<Float_t> GlobalPhiAngle; ///< (degrees, but 90 degrees rotated to keep things interesting)
96  //@}
97 
98  /// \name Particle name and type at the hit
99  //@{
100  std::vector<TString> ParticleName; ///< Name of the particle type of this hit
101  std::vector<Int_t> ParticleType; ///< \ref Lund_type of the particle type of this hit
102  std::vector<Int_t> ParticleID; ///< Id of this hit
103  std::vector<Int_t> ParentID; ///< Id of the parent of this hit
104  std::vector<TString> CreatorProcessName; ///< Process name that created this hit
105  //@}
106 
107  /// \name Polarization of the hit in local coordinates
108  /// The local coordinates are defined in the \ref local_coordinate_system.
109  //@{
110  std::vector<Float_t> PolarizationX; ///< (dimensionless, normalized)
111  std::vector<Float_t> PolarizationY; ///< (dimensionless, normalized)
112  std::vector<Float_t> PolarizationZ; ///< (dimensionless, normalized)
113  std::vector<Float_t> LongitudinalPolarization; ///< (dimensionless, normalized)
114  std::vector<Float_t> TransversePolarization; ///< (dimensionless, normalized)
115  std::vector<Float_t> TransversePolarizationX; ///< (dimensionless, normalized)
116  std::vector<Float_t> TransversePolarizationY; ///< (dimensionless, normalized)
117  std::vector<Float_t> TransversePolarizationZ; ///< (dimensionless, normalized)
118  std::vector<Float_t> TransversePolarizationPhiAngle; ///< (degrees)
119 
120  //@}
121 
122  /// \name Total and kinetic energy of the track at the hit
123  //@{
124  std::vector<Float_t> TotalEnergy; ///< (MeV)
125  std::vector<Float_t> KineticEnergy; ///< (MeV)
126  //@}
127 
128 public:
129 
130  // Constructor
132  // Destructor
134 
135  void Initialize();
136 
137  //-----------------
138  void StoreDetectorID(Int_t did) { DetectorID.push_back(did); }
139  std::vector<Int_t> GetDetectorID() const {return DetectorID;}
140  //-----------------
141 
142  void StoreTrackID(Int_t tid) { TrackID = tid; }
143  Int_t GetTrackID() const {return TrackID;}
144 
145  void StoreParticleName(TString pn) { ParticleName.push_back(pn); }
146  std::vector<TString> GetParticleName() const {return ParticleName;}
147 
148  void StoreParticleType(Int_t pt) { ParticleType.push_back(pt); }
149  std::vector<Int_t> GetParticleType() const {return ParticleType;}
150 
151  void StoreParentID(Int_t Pid) { ParentID.push_back(Pid); }
152  std::vector<Int_t> GetParentID() const {return ParentID;}
153 
154  void StoreCreatorProcessName(TString name) { CreatorProcessName.push_back(name); }
155  std::vector<TString> GetCreatorProcessName() const {return CreatorProcessName;}
156 
157  void StoreParticleID(Int_t pid) { ParticleID.push_back(pid); }
158  std::vector<Int_t> GetParticleID() const {return ParticleID;}
159 
160  void StoreGlobalTimeOfHit(Float_t gtime) { GlobalTimeOfHit.push_back(gtime); }
161  std::vector<Float_t> GetGloablTimeOfHit() const {return GlobalTimeOfHit;}
162 
163  void StoreTotalEnergy(Float_t te) { TotalEnergy.push_back(te); }
164  std::vector<Float_t> GetTotalEnergy() const {return TotalEnergy;}
165 
166  void StoreKineticEnergy(Float_t ke) { KineticEnergy.push_back(ke); }
167  std::vector<Float_t> GetKineticEnergy() const {return KineticEnergy;}
168 
169  //-----------------
170 
171  void StorePolarizationX(Float_t px) { PolarizationX.push_back(px); }
172  std::vector<Float_t> GetPolarizationX() const {return PolarizationX;}
173 
174  void StorePolarizationY(Float_t py) { PolarizationY.push_back(py); }
175  std::vector<Float_t> GetPolarizationY() const {return PolarizationY;}
176 
177  void StorePolarizationZ(Float_t pz) { PolarizationZ.push_back(pz); }
178  std::vector<Float_t> GetPolarizationZ() const {return PolarizationZ;}
179 
180  void StoreLongitudinalPolarization(Float_t pl) { LongitudinalPolarization.push_back(pl); }
181  std::vector<Float_t> GetLongitudinalPolarization() const {return LongitudinalPolarization;}
182 
183  void StoreTransversePolarization(Float_t pt) { TransversePolarization.push_back(pt); }
184  std::vector<Float_t> GetTransversePolarization() const {return TransversePolarization;}
185 
186  void StoreTransversePolarizationX(Float_t pt) { TransversePolarizationX.push_back(pt); }
187  std::vector<Float_t> GetTransversePolarizationX() const {return TransversePolarizationX;}
188 
189  void StoreTransversePolarizationY(Float_t pt) { TransversePolarizationY.push_back(pt); }
190  std::vector<Float_t> GetTransversePolarizationY() const {return TransversePolarizationY;}
191 
192  void StoreTransversePolarizationZ(Float_t pt) { TransversePolarizationZ.push_back(pt); }
193  std::vector<Float_t> GetTransversePolarizationZ() const {return TransversePolarizationZ;}
194 
197 
198  //-----------------
199 
200  void StoreDetectorHasBeenHit(Int_t n) { HasBeenHit = n; }
201  Int_t GetDetectorHasBeenHit() const {return HasBeenHit;}
202  //-----------------
203  void StoreDetectorNbOfHits(Int_t nd) { NbOfHits = nd; }
204  Int_t GetDetectorNbOfHits() const {return NbOfHits;}
205  //-----------------
206  void StoreDetectorLocalPositionX(Float_t lx) { HitLocalPositionX.push_back(lx); }
207  std::vector<Float_t> GetDetectorLocalPositionX() const {return HitLocalPositionX;}
208 
209  void StoreDetectorLocalPositionY(Float_t ly) { HitLocalPositionY.push_back(ly); }
210  std::vector<Float_t> GetDetectorLocalPositionY() const {return HitLocalPositionY;}
211 
212  void StoreDetectorLocalPositionZ(Float_t lz) { HitLocalPositionZ.push_back(lz); }
213  std::vector<Float_t> GetDetectorLocalPositionZ() const {return HitLocalPositionZ;}
214  //-----------------
215  void StoreDetectorLocalExitPositionX(Float_t lx) { HitLocalExitPositionX.push_back(lx); }
216  std::vector<Float_t> GetDetectorLocalExitPositionX() const {return HitLocalExitPositionX;}
217 
218  void StoreDetectorLocalExitPositionY(Float_t ly) { HitLocalExitPositionY.push_back(ly); }
219  std::vector<Float_t> GetDetectorLocalExitPositionY() const {return HitLocalExitPositionY;}
220 
221  void StoreDetectorLocalExitPositionZ(Float_t lz) { HitLocalExitPositionZ.push_back(lz); }
222  std::vector<Float_t> GetDetectorLocalExitPositionZ() const {return HitLocalExitPositionZ;}
223  //---
224  void StoreDetectorGlobalPositionX(Float_t lx) { HitGlobalPositionX.push_back(lx); }
225  std::vector<Float_t> GetDetectorGlobalPositionX() const {return HitGlobalPositionX;}
226 
227  void StoreDetectorGlobalPositionY(Float_t ly) { HitGlobalPositionY.push_back(ly); }
228  std::vector<Float_t> GetDetectorGlobalPositionY() const {return HitGlobalPositionY;}
229 
230  void StoreDetectorGlobalPositionZ(Float_t lz) { HitGlobalPositionZ.push_back(lz); }
231  std::vector<Float_t> GetDetectorGlobalPositionZ() const {return HitGlobalPositionZ;}
232  //-----------------
233  void StoreOriginVertexPositionX(Float_t vx) { OriginVertexPositionX.push_back(vx); }
234  std::vector<Float_t> GetOriginVertexPositionX() const {return OriginVertexPositionX;}
235 
236  void StoreOriginVertexPositionY(Float_t vy) { OriginVertexPositionY.push_back(vy); }
237  std::vector<Float_t> GetOriginVertexPositionY() const {return OriginVertexPositionY;}
238 
239  void StoreOriginVertexPositionZ(Float_t vz) { OriginVertexPositionZ.push_back(vz); }
240  std::vector<Float_t> GetOriginVertexPositionZ() const {return OriginVertexPositionZ;}
241  //-----------------
244 
247 
250  //-----------------
251  void StoreOriginVertexThetaAngle(Float_t theta) { OriginVertexThetaAngle.push_back(theta); }
252  std::vector<Float_t> GetOriginVertexThetaAngle() const {return OriginVertexThetaAngle;}
253 
254  void StoreOriginVertexPhiAngle(Float_t phi) { OriginVertexPhiAngle.push_back(phi); }
255  std::vector<Float_t> GetOriginVertexPhiAngle() const {return OriginVertexPhiAngle;}
256  //-----------------
257  void StoreOriginVertexKineticEnergy(Float_t ekin) { OriginVertexKineticEnergy.push_back(ekin); }
258  std::vector<Float_t> GetOriginVertexKineticEnergy() const {return OriginVertexKineticEnergy;}
259 
260  void StoreOriginVertexTotalEnergy(Float_t etot) { OriginVertexTotalEnergy.push_back(etot); }
261  std::vector<Float_t> GetOriginVertexTotalEnergy() const {return OriginVertexTotalEnergy;}
262 
263  //----------------
264 
265  void StoreLocalMomentumX(Float_t px) { LocalMomentumX.push_back(px); }
266  std::vector<Float_t> GetLocalMomentumX() const {return LocalMomentumX;}
267 
268  void StoreLocalMomentumY(Float_t py) { LocalMomentumY.push_back(py); }
269  std::vector<Float_t> GetLocalMomentumY() const {return LocalMomentumY;}
270 
271  void StoreLocalMomentumZ(Float_t pz) { LocalMomentumZ.push_back(pz); }
272  std::vector<Float_t> GetLocalMomentumZ() const {return LocalMomentumZ;}
273 
274  void StoreLocalThetaAngle(Float_t theta) { LocalThetaAngle.push_back(theta); }
275  std::vector<Float_t> GetLocalThetaAngle() const {return LocalThetaAngle;}
276 
277  void StoreLocalPhiAngle(Float_t phi) { LocalPhiAngle.push_back(phi); }
278  std::vector<Float_t> GetLocalPhiAngle() const {return LocalPhiAngle;}
279 
280  //----------------
281 
282  void StoreGlobalMomentumX(Float_t px) { GlobalMomentumX.push_back(px); }
283  std::vector<Float_t> GetGlobalMomentumX() const {return GlobalMomentumX;}
284 
285  void StoreGlobalMomentumY(Float_t py) { GlobalMomentumY.push_back(py); }
286  std::vector<Float_t> GetGlobalMomentumY() const {return GlobalMomentumY;}
287 
288  void StoreGlobalMomentumZ(Float_t pz) { GlobalMomentumZ.push_back(pz); }
289  std::vector<Float_t> GetGlobalMomentumZ() const {return GlobalMomentumZ;}
290 
291  void StoreGlobalThetaAngle(Float_t theta) { GlobalThetaAngle.push_back(theta); }
292  std::vector<Float_t> GetGlobalThetaAngle() const {return GlobalThetaAngle;}
293 
294  void StoreGlobalPhiAngle(Float_t phi) { GlobalPhiAngle.push_back(phi); }
295  std::vector<Float_t> GetGlobalPhiAngle() const {return GlobalPhiAngle;}
296 
297  //----------------
298 
299  // define a new Class known to ROOT
301 
302 }; // end class QweakSimUserCerenkov_RadiatorEvent
303 
304 #endif
std::vector< Float_t > GlobalTimeOfHit
Global time when this hit was generated (ns)
std::vector< Int_t > DetectorID
ID of the detector in which this hit was registered.
std::vector< Float_t > LongitudinalPolarization
(dimensionless, normalized)
std::vector< Float_t > GetOriginVertexTotalEnergy() const
std::vector< Int_t > ParentID
Id of the parent of this hit.
std::vector< Float_t > GetOriginVertexPhiAngle() const
Int_t NbOfHits
Number of hits in this detector.
std::vector< Float_t > GetDetectorLocalExitPositionX() const
std::vector< TString > ParticleName
Name of the particle type of this hit.
ROOT Subtree structure for Cerenkov radiator event.
std::vector< Float_t > LocalPhiAngle
(degrees, but 90 degrees rotated to keep things interesting)
std::vector< Float_t > TransversePolarizationX
(dimensionless, normalized)
std::vector< Float_t > GetOriginVertexThetaAngle() const
std::vector< Float_t > GetOriginVertexPositionY() const
std::vector< Float_t > GetOriginVertexMomentumDirectionX() const
std::vector< Float_t > TransversePolarizationY
(dimensionless, normalized)
std::vector< Float_t > GetDetectorLocalPositionX() const
std::vector< Float_t > GetOriginVertexPositionZ() const
std::vector< Int_t > EdgeEventFlag
Was the distance between hit and exit position below 1.5 cm? 0 = no, 1 = yes.
std::vector< Float_t > GetDetectorGlobalPositionX() const
std::vector< Float_t > PolarizationZ
(dimensionless, normalized)
std::vector< Float_t > GetDetectorLocalPositionY() const
std::vector< Float_t > GetDetectorLocalPositionZ() const
std::vector< Float_t > GetOriginVertexMomentumDirectionY() const
std::vector< Float_t > PolarizationY
(dimensionless, normalized)
std::vector< Float_t > OriginVertexThetaAngle
(degrees)
std::vector< Float_t > GlobalPhiAngle
(degrees, but 90 degrees rotated to keep things interesting)
std::vector< Float_t > GetDetectorLocalExitPositionY() const
std::vector< Float_t > GetTransversePolarizationX() const
std::vector< Float_t > GetOriginVertexMomentumDirectionZ() const
std::vector< Float_t > GetLongitudinalPolarization() const
Int_t TrackID
ID of the track from which this hit was generated.
std::vector< Float_t > TransversePolarizationPhiAngle
(degrees)
std::vector< Float_t > GetOriginVertexKineticEnergy() const
Int_t HasBeenHit
Has this detector been hit? 0 = no, 5 = yes.
std::vector< Float_t > GetDetectorGlobalPositionY() const
std::vector< Float_t > PolarizationX
(dimensionless, normalized)
std::vector< Float_t > GetTransversePolarizationY() const
std::vector< Float_t > GetTransversePolarization() const
std::vector< Int_t > ParticleID
Id of this hit.
std::vector< Float_t > GetTransversePolarizationZ() const
std::vector< Float_t > GetOriginVertexPositionX() const
std::vector< Float_t > TransversePolarization
(dimensionless, normalized)
std::vector< Float_t > TransversePolarizationZ
(dimensionless, normalized)
std::vector< Float_t > GetDetectorLocalExitPositionZ() const
std::vector< Float_t > GetTransversePolarizationPhiAngle() const
std::vector< Float_t > GetDetectorGlobalPositionZ() const
std::vector< Float_t > OriginVertexPhiAngle
(degrees)
std::vector< TString > CreatorProcessName
Process name that created this hit.
std::vector< Int_t > ParticleType
Lund type of the particle type of this hit