CMS 3D CMS Logo

PhiWedge.h
Go to the documentation of this file.
1 #ifndef DATAFORMATS_METRECO_PHIWEDGE_H
2 #define DATAFORMATS_METRECO_PHIWEDGE_H
3 /*
4  [class]: PhiWedge
5  [authors]: R. Remington, The University of Florida
6  [description]: Simple class analogous to CaloTower but in z-direction. Stores basic information related to Hcal and Ecal rechits within constant 5-degree phi windows. The idea will be to match these reconstructed phi-wedges with csc tracks for BeamHalo identification.
7  [date]: October 15, 2009
8 */
9 #include "TMath.h"
10 #include <vector>
11 namespace reco {
12 
13  class PhiWedge {
14  public:
15  // Constructors
16  PhiWedge();
17  PhiWedge(float E, int iphi, int constituents);
18  PhiWedge(float E, int iphi, int constituents, float min_time, float max_time);
19  PhiWedge(const PhiWedge&);
20  // Destructors
21 
22  ~PhiWedge() {}
23 
24  // Energy sum of all rechits above threshold in this 5-degree window
25  float Energy() const { return energy_; }
26 
27  // Number of rechits above threshold in this 5-degree window
28  int NumberOfConstituents() const { return constituents_; }
29 
30  // iPhi value of this 5-degree window
31  int iPhi() const { return iphi_; }
32 
33  // Global phi lower bound of this 5-degree window (between 0 and 2Pi)
34  float PhiLow() const { return 2. * TMath::Pi() * (float)((iphi_ * 5) - (5.)); }
35 
36  // Global phi upper bound of this 5-degree window (between 0 and 2Pi
37  float PhiHigh() const { return 2. * TMath::Pi() * (float)((iphi_ * 5)); }
38 
39  // Get Min/Max Time
40  float MinTime() const { return min_time_; }
41  float MaxTime() const { return max_time_; }
42 
43  // Get halo direction confidence based on time ordering of the rechits ( must be within range of -1 to + 1 )
44  // Direction is calculated by counting the number of pair-wise time-ascending rechits from -Z to +Z and then normalizing this count by number of pair-wise combinations
45  // If all pair-wise combinations are consistent with a common z-direction, then this value will be plus or minus 1 exactly. Otherwise it will be somewhere in between.
46  float ZDirectionConfidence() const { return (1. - PlusZOriginConfidence_) * 2. - 1.; }
47  float PlusZDirectionConfidence() const { return 1. - PlusZOriginConfidence_; }
49 
50  // Get halo origin confidence based on time ordering of the rechits
52  float MinusZOriginConfidence() const { return 1. - PlusZOriginConfidence_; }
53 
54  // To be filled later or removed
59 
60  // Setters
65  void SetMinMaxTime(float min, float max) {
66  min_time_ = min;
67  max_time_ = max;
68  }
70 
71  private:
72  float energy_;
73  int iphi_;
75  float min_time_;
76  float max_time_;
82  };
83  typedef std::vector<PhiWedge> PhiWedgeCollection;
84 } // namespace reco
85 #endif
reco::PhiWedge::OverlappingCSCRecHits_
int OverlappingCSCRecHits_
Definition: PhiWedge.h:80
reco::PhiWedge::PhiLow
float PhiLow() const
Definition: PhiWedge.h:34
reco::PhiWedge::PlusZOriginConfidence
float PlusZOriginConfidence() const
Definition: PhiWedge.h:51
reco::PhiWedge::SetOverlappingCSCHaloTriggers
void SetOverlappingCSCHaloTriggers(int x)
Definition: PhiWedge.h:64
reco::PhiWedge::OverlappingCSCSegments_
int OverlappingCSCSegments_
Definition: PhiWedge.h:79
dqmMemoryStats.float
float
Definition: dqmMemoryStats.py:127
reco::PhiWedge::constituents_
int constituents_
Definition: PhiWedge.h:74
reco::PhiWedge::iphi_
int iphi_
Definition: PhiWedge.h:73
min
T min(T a, T b)
Definition: MathUtil.h:58
reco::PhiWedge::~PhiWedge
~PhiWedge()
Definition: PhiWedge.h:22
reco::PhiWedge::SetOverlappingCSCSegments
void SetOverlappingCSCSegments(int x)
Definition: PhiWedge.h:62
reco::PhiWedge::min_time_
float min_time_
Definition: PhiWedge.h:75
reco::PhiWedge::Energy
float Energy() const
Definition: PhiWedge.h:25
reco::PhiWedgeCollection
std::vector< PhiWedge > PhiWedgeCollection
Definition: PhiWedge.h:83
reco::PhiWedge::OverlappingCSCTracks
int OverlappingCSCTracks() const
Definition: PhiWedge.h:55
reco
fixed size matrix
Definition: AlignmentAlgorithmBase.h:45
reco::PhiWedge::PhiHigh
float PhiHigh() const
Definition: PhiWedge.h:37
reco::PhiWedge::OverlappingCSCTracks_
int OverlappingCSCTracks_
Definition: PhiWedge.h:78
reco::PhiWedge::MaxTime
float MaxTime() const
Definition: PhiWedge.h:41
reco::PhiWedge::PlusZDirectionConfidence
float PlusZDirectionConfidence() const
Definition: PhiWedge.h:47
reco::PhiWedge::PlusZOriginConfidence_
float PlusZOriginConfidence_
Definition: PhiWedge.h:77
LEDCalibrationChannels.iphi
iphi
Definition: LEDCalibrationChannels.py:64
reco::PhiWedge::MinusZDirectionConfidence
float MinusZDirectionConfidence() const
Definition: PhiWedge.h:48
reco::PhiWedge
Definition: PhiWedge.h:13
reco::PhiWedge::SetOverlappingCSCRecHits
void SetOverlappingCSCRecHits(int x)
Definition: PhiWedge.h:63
reco::PhiWedge::OverlappingCSCSegments
int OverlappingCSCSegments() const
Definition: PhiWedge.h:56
reco::PhiWedge::PhiWedge
PhiWedge()
Definition: PhiWedge.cc:12
reco::PhiWedge::OverlappingCSCHaloTriggers
int OverlappingCSCHaloTriggers() const
Definition: PhiWedge.h:58
reco::PhiWedge::SetOverlappingCSCTracks
void SetOverlappingCSCTracks(int x)
Definition: PhiWedge.h:61
reco::PhiWedge::SetMinMaxTime
void SetMinMaxTime(float min, float max)
Definition: PhiWedge.h:65
reco::PhiWedge::OverlappingCSCHaloTriggers_
int OverlappingCSCHaloTriggers_
Definition: PhiWedge.h:81
SiStripPI::max
Definition: SiStripPayloadInspectorHelper.h:169
reco::PhiWedge::MinTime
float MinTime() const
Definition: PhiWedge.h:40
reco::PhiWedge::NumberOfConstituents
int NumberOfConstituents() const
Definition: PhiWedge.h:28
reco::PhiWedge::max_time_
float max_time_
Definition: PhiWedge.h:76
reco::PhiWedge::OverlappingCSCRecHits
int OverlappingCSCRecHits() const
Definition: PhiWedge.h:57
reco::PhiWedge::energy_
float energy_
Definition: PhiWedge.h:72
reco::PhiWedge::MinusZOriginConfidence
float MinusZOriginConfidence() const
Definition: PhiWedge.h:52
Pi
const double Pi
Definition: CosmicMuonParameters.h:18
reco::PhiWedge::ZDirectionConfidence
float ZDirectionConfidence() const
Definition: PhiWedge.h:46
reco::PhiWedge::SetPlusZOriginConfidence
void SetPlusZOriginConfidence(float x)
Definition: PhiWedge.h:69
reco::PhiWedge::iPhi
int iPhi() const
Definition: PhiWedge.h:31