CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
CastorCluster.h
Go to the documentation of this file.
1 #ifndef CastorReco_CastorCluster_h
2 #define CastorReco_CastorCluster_h
3 
13 #include <vector>
14 #include <memory>
16 
20 
22 
23 namespace reco {
24 
25  class CastorCluster {
26  public:
27 
29  CastorCluster() : energy_(0.), position_(ROOT::Math::XYZPoint(0.,0.,0.)), emEnergy_(0.), hadEnergy_(0.), fem_(0.), width_(0.),
30  depth_(0.), fhot_(0.), sigmaz_(0.) { }
31 
33  CastorCluster(const double energy, const ROOT::Math::XYZPoint& position, const double emEnergy, const double hadEnergy, const double fem,
34  const double width, const double depth, const double fhot, const double sigmaz, const CastorTowerRefVector& usedTowers);
35 
36 
38  virtual ~CastorCluster();
39 
41  double energy() const { return energy_; }
42 
45 
47  double emEnergy() const { return emEnergy_; }
48 
50  double hadEnergy() const { return hadEnergy_; }
51 
53  double fem() const { return fem_; }
54 
56  double width() const { return width_; }
57 
59  double depth() const { return depth_; }
60 
62  double fhot() const { return fhot_; }
63 
65  double sigmaz() const { return sigmaz_; }
66 
69 
72 
75 
77  size_t towersSize() const { return usedTowers_.size(); }
78 
80  void add( const CastorTowerRef & tower ) { usedTowers_.push_back( tower ); }
81 
83  bool operator >=(const CastorCluster& rhs) const { return (energy_>=rhs.energy_); }
84 
86  bool operator > (const CastorCluster& rhs) const { return (energy_> rhs.energy_); }
87 
89  bool operator <=(const CastorCluster& rhs) const { return (energy_<=rhs.energy_); }
90 
92  bool operator < (const CastorCluster& rhs) const { return (energy_< rhs.energy_); }
93 
95  double eta() const { return position_.eta(); }
96 
98  double phi() const { return position_.phi(); }
99 
101  double x() const { return position_.x(); }
102 
104  double y() const { return position_.y(); }
105 
107  double rho() const { return position_.rho(); }
108 
109  private:
110 
112  double energy_;
113 
116 
118  double emEnergy_;
119 
121  double hadEnergy_;
122 
124  double fem_;
125 
127  double width_;
128 
130  double depth_;
131 
133  double fhot_;
134 
136  double sigmaz_;
137 
140  };
141 
143  typedef std::vector<CastorCluster> CastorClusterCollection;
144 
145  // persistent reference to CastorCluster objects
147 
150 
153 }
154 
155 #endif
double depth() const
cluster depth in z
Definition: CastorCluster.h:59
virtual ~CastorCluster()
destructor
double emEnergy() const
cluster em energy
Definition: CastorCluster.h:47
void add(const CastorTowerRef &tower)
add reference to constituent CastorTower
Definition: CastorCluster.h:80
CastorTowerRefVector usedTowers_
references to CastorTower constituents
double width_
cluster width
double y() const
y of cluster centroid
edm::RefVector< CastorClusterCollection > CastorClusterRefVector
vector of references to CastorCluster objects all in the same collection
CastorCluster()
default constructor. Sets energy and position to zero
Definition: CastorCluster.h:29
double phi() const
azimuthal angle of cluster centroid
Definition: CastorCluster.h:98
std::vector< CastorCluster > CastorClusterCollection
collection of CastorCluster objects
double sigmaz() const
cluster sigma z
Definition: CastorCluster.h:65
double sigmaz_
cluster sigma z
CastorTower_iterator towersEnd() const
last iterator over CastorTower constituents
Definition: CastorCluster.h:74
double fhot() const
cluster hotcell/tot ratio
Definition: CastorCluster.h:62
const_iterator end() const
Termination of iteration.
Definition: RefVector.h:249
CastorTower_iterator towersBegin() const
fist iterator over CastorTower constituents
Definition: CastorCluster.h:71
double energy_
cluster energy
double width() const
cluster width in phi
Definition: CastorCluster.h:56
const_iterator begin() const
Initialize an iterator over the RefVector.
Definition: RefVector.h:244
bool operator<=(const CastorCluster &rhs) const
comparison &lt;= operator
Definition: CastorCluster.h:89
double eta() const
pseudorapidity of cluster centroid
Definition: CastorCluster.h:95
edm::Ref< CastorClusterCollection > CastorClusterRef
CastorClusterRefVector::iterator CastorCluster_iterator
iterator over a vector of references to CastorCluster objects all in the same collection ...
double depth_
cluster depth
double fem_
cluster em/tot Ratio
ROOT::Math::XYZPoint position_
cluster centroid position
double fem() const
cluster em/tot ratio
Definition: CastorCluster.h:53
double emEnergy_
cluster em energy
double energy() const
cluster energy
Definition: CastorCluster.h:41
size_t towersSize() const
number of CastorTower constituents
Definition: CastorCluster.h:77
bool operator>(const CastorCluster &rhs) const
comparison &gt; operator
Definition: CastorCluster.h:86
ROOT::Math::XYZPoint position() const
cluster centroid position
Definition: CastorCluster.h:44
CastorTowerRefVector getUsedTowers() const
vector of used Towers
Definition: CastorCluster.h:68
double x() const
x of cluster centroid
bool operator<(const CastorCluster &rhs) const
comparison &lt;= operator
Definition: CastorCluster.h:92
double hadEnergy_
cluster had energy
XYZPointD XYZPoint
point in space with cartesian internal representation
Definition: Point3D.h:13
double rho() const
rho of cluster centroid
double hadEnergy() const
cluster had energy
Definition: CastorCluster.h:50
Transform3DPJ::Point XYZPoint
void push_back(value_type const &ref)
Add a Ref&lt;C, T&gt; to the RefVector.
Definition: RefVector.h:64
size_type size() const
Size of the RefVector.
Definition: RefVector.h:89
double fhot_
cluster hotcell/tot ratio
bool operator>=(const CastorCluster &rhs) const
comparison &gt;= operator
Definition: CastorCluster.h:83