CaloCluster.h
Go to the documentation of this file.
1 /*
2  * CaloCluster.h
3  *
4  * Created on: Feb 23, 2021
5  * Author: chilgenb
6  */
7 
8 #ifndef GARANA_CALOCLUSTER_H_
9 #define GARANA_CALOCLUSTER_H_
10 
11 #include <TLorentzVector.h>
12 #include <TVector3.h>
13 
14 #include <vector>
15 #include <climits>
16 
17 using std::vector;
18 
19 namespace garana {
20 
21  class CaloCluster {
22 
23  public:
24 
25  CaloCluster();
26 
27  #ifndef __GCCXML__
28 
29  CaloCluster(const TLorentzVector& pos, const int& region, const float& energy, const float& energyErr, const float& timeDiff,
30  const float* shape, const float& theta, const float& phi, const std::vector<TVector3>& eigenVecs,
31  const std::vector<std::pair<int,float>>& edeps);
32 
33  const TLorentzVector* Position() const;
34  int const& Region() const;
35  float const& Energy() const;
36  float const& EnergyError() const;
37  float const& TimeDifference() const;
38  const float* Shape() const;
39  float const& Theta() const;
40  float const& Phi() const;
41  const vector<TVector3>* EigenVecs() const;
42  size_t NIdes() const;
43  const std::pair<int,float>* GetTrackIdEdep(const size_t& iide) const;
44  float TotalTrueEnergy() const;
45  float const& MaxDeposit() const;
46  int const& TrackIdMaxDep() const;
47 
48  #endif
49 
50  private:
51 
52  TLorentzVector fPosition; ///< 4-position of the cluster [cm,ns]
53  int fRegion; ///< what ECal region is it in, barrel or endcap; could add more. e.g, forward vs. backward barrel
54  float fEnergy; ///< energy of the ECal cluster [GeV]
55  float fEnergyError; ///< uncertainty of the cluster energy [GeV]
56  float fTimeDiffFirstLast; ///< time difference between the first and last layer of the cluster [ns]
57  float fShape[6]; ///< cluster shape parameters (Ellipsoid r1, r2, r3, vol, width)
58  float fTheta; ///< intrasic direction of the cluster theta
59  float fPhi; ///< intrasic direction of the cluster phi
60  vector<TVector3> fEigenVecs; ///< Eigenvectors of the cluster in ascending order (principal axis with smallest inertial mass) normalised to 1
61  vector<std::pair<int,float>> fTrueEnergy; ///< true energy (second) [GeV] deposited by MCParticle with trackID (first)
62 
63  }; //class
64 }//namespace
65 
66 #endif /* GARANA_CALOCLUSTER_H_ */
float const & Energy() const
Definition: CaloCluster.cxx:58
float fEnergyError
uncertainty of the cluster energy [GeV]
Definition: CaloCluster.h:55
TLorentzVector fPosition
4-position of the cluster [cm,ns]
Definition: CaloCluster.h:52
float const & Phi() const
Definition: CaloCluster.cxx:78
float const & EnergyError() const
Definition: CaloCluster.cxx:62
struct vector vector
float fEnergy
energy of the ECal cluster [GeV]
Definition: CaloCluster.h:54
float fShape[6]
cluster shape parameters (Ellipsoid r1, r2, r3, vol, width)
Definition: CaloCluster.h:57
vector< std::pair< int, float > > fTrueEnergy
true energy (second) [GeV] deposited by MCParticle with trackID (first)
Definition: CaloCluster.h:61
int fRegion
what ECal region is it in, barrel or endcap; could add more. e.g, forward vs. backward barrel ...
Definition: CaloCluster.h:53
float fTimeDiffFirstLast
time difference between the first and last layer of the cluster [ns]
Definition: CaloCluster.h:56
const float * Shape() const
Definition: CaloCluster.cxx:70
size_t NIdes() const
Definition: CaloCluster.cxx:86
float fTheta
intrasic direction of the cluster theta
Definition: CaloCluster.h:58
const vector< TVector3 > * EigenVecs() const
Definition: CaloCluster.cxx:82
float TotalTrueEnergy() const
Definition: CaloCluster.cxx:94
const std::pair< int, float > * GetTrackIdEdep(const size_t &iide) const
Definition: CaloCluster.cxx:90
float const & MaxDeposit() const
const TLorentzVector * Position() const
Definition: CaloCluster.cxx:50
int const & Region() const
Definition: CaloCluster.cxx:54
float fPhi
intrasic direction of the cluster phi
Definition: CaloCluster.h:59
float const & TimeDifference() const
Definition: CaloCluster.cxx:66
vector< TVector3 > fEigenVecs
Eigenvectors of the cluster in ascending order (principal axis with smallest inertial mass) normalise...
Definition: CaloCluster.h:60
float const & Theta() const
Definition: CaloCluster.cxx:74
int const & TrackIdMaxDep() const