PCHit.h
Go to the documentation of this file.
1 ///////////////////////////////////////////////////////////////////////////
2 /// \brief A PCHit contains the basic information from cosmic track data
3 /// needed for calibration.
4 /// \author rtoner@physics.harvard.edu
5 /// \date Jan. 2013
6 ///////////////////////////////////////////////////////////////////////////
7 #ifndef PCHIT_H
8 #define PCHIT_H
9 
11 
12 /// Calibration data products
13 namespace caldp
14 {
15  /// "Pre-calibration hit". Common input to calibration procedures
16  class PCHit
17  {
18  public:
19  PCHit();
20 
21  ~PCHit();
22 
23  /// Return plane value
24  int Plane () const {return plane; };
25  /// Return cell value
26  int Cell () const {return cell; };
27  /// Return diblock value
28  int Diblock () const {return diblock; };
29  /// Return dcm value
30  int DCM () const {return dcm; };
31  /// Return apd value
32  int APD () const {return apd; };
33  /// Return pixel value
34  int Pixel () const {return pixel; };
35  /// Return view
36  geo::View_t View () const {return view; };
37  /// Return PE value
38  float PE () const {return pe; };
39  /// Return ADC value
40  float ADC () const {return adc; };
41  /// Return Path value
42  float Path () const {return path; };
43  /// Return W value
44  float W () const {return w; };
45  /// Return True energy (MeV) value
46  float TrueMeV () const {return trueMeV; };
47  /// Return True PE value
48  float TruePE () const {return truePE; };
49  /// Return True Pathlength value
50  float TruePath () const {return truePath; };
51  /// Return True W value
52  float TrueW () const {return trueW; };
53  /// Return uncorrected hit time
54  float TNS () const {return tns; };
55  /// Return quality of timing fit for cell
56  bool GoodTime () const {return goodTime; };
57  /// Return path from start of track to current cell
58  float FlightLen() const {return flightLen; };
59  /// Return distance to readout, with pigtail
60  float ReadDist () const {return readDist; };
61  /// Return number of simulated photons at readout before fluctuations
62  float PoissonLambda () const { return poissonLambda; }
63 
64  /// Set plane value
65  void SetPlane (int aPlane ) { plane = aPlane; };
66  /// Set cell value
67  void SetCell (int aCell ) { cell = aCell; };
68  /// Set diblock value
69  void SetDiblock (int aDiblock ) { diblock = aDiblock; };
70  /// Set dcm value
71  void SetDCM (int aDCM ) { dcm = aDCM; };
72  /// Set apd value
73  void SetAPD (int aAPD ) { apd = aAPD; };
74  /// Set pixel value
75  void SetPixel (int aPixel ) { pixel = aPixel; };
76  /// Set view value
77  void SetView (geo::View_t aView ) { view = aView; };
78  /// Set PE value
79  void SetPE (float aPE ) { pe = aPE; };
80  /// Set ADC value
81  void SetADC (int aADC ) { adc = aADC; };
82  /// Set Path value
83  void SetPath (float aPath ) { path = aPath; };
84  /// Set W value
85  void SetW (float aW ) { w = aW; };
86  /// Set True energy (MeV) value
87  void SetTrueMeV (float aTrueMeV ) { trueMeV = aTrueMeV; };
88  /// Set True PE value
89  void SetTruePE (float aTruePE ) { truePE = aTruePE; };
90  /// Set True path length value
91  void SetTruePath (float aTruePath) { truePath = aTruePath;};
92  /// Set True W value
93  void SetTrueW (float aTrueW ) { trueW = aTrueW; };
94  /// Set hit time (ns)
95  void SetTNS (float aTNS ) { tns = aTNS; };
96  /// Set quality of timing fit
97  void SetGoodTime (bool aGoodT ) { goodTime = aGoodT; };
98  /// Set path length from start of track
99  void SetFlightLen(float aLen ) { flightLen= aLen; };
100  /// Set distance to cell readout
101  void SetReadDist (float aDist ) { readDist = aDist; };
102  /// Set number of simulated photons at readout before fluctuations
103  void SetPoissonLambda(float aLambda ) { poissonLambda = aLambda; }
104  protected:
105  int plane; ///< plane number
106  int cell; ///< cell number
107  int diblock; ///< diblock number
108  int dcm; ///< number of dcm on diblock
109  int apd; ///< number of apd on dcm
110  int pixel; ///< number pixel on apd
111  geo::View_t view; ///< hit view
112  float pe; ///< uncalibrated PEs
113  float adc; ///< ADC
114  float path; ///< Path length
115  float w; ///< Unmeasured coordinate of hit
116  float trueMeV; ///< True energy of hit (MC Truth)
117  float truePE; ///< True number of photoelectrons (MC Truth)
118  float truePath; ///< True pathlength through the cell
119  float trueW; ///< True position along cell W (W)
120  float tns; ///< Time of pchit (ns)
121  bool goodTime; ///< True if the time fit for the hit was good
122  float flightLen; ///< path length from the start of track (cm)
123  float readDist; ///< distance from hit to readout(including pigtail) (cm)
124  float poissonLambda; ///< Number of simulated photons at readout in the absence of fluctuations
125  };
126 
127 } // end namespace
128 
129 #endif // PCHIT_H
int apd
number of apd on dcm
Definition: PCHit.h:109
int Pixel() const
Return pixel value.
Definition: PCHit.h:34
float TrueMeV() const
Return True energy (MeV) value.
Definition: PCHit.h:46
int diblock
diblock number
Definition: PCHit.h:107
float TNS() const
Return uncorrected hit time.
Definition: PCHit.h:54
void SetTNS(float aTNS)
Set hit time (ns)
Definition: PCHit.h:95
float FlightLen() const
Return path from start of track to current cell.
Definition: PCHit.h:58
void SetPE(float aPE)
Set PE value.
Definition: PCHit.h:79
float truePath
True pathlength through the cell.
Definition: PCHit.h:118
void SetADC(int aADC)
Set ADC value.
Definition: PCHit.h:81
float TruePath() const
Return True Pathlength value.
Definition: PCHit.h:50
int pixel
number pixel on apd
Definition: PCHit.h:110
void SetAPD(int aAPD)
Set apd value.
Definition: PCHit.h:73
void SetPixel(int aPixel)
Set pixel value.
Definition: PCHit.h:75
int APD() const
Return apd value.
Definition: PCHit.h:32
void SetFlightLen(float aLen)
Set path length from start of track.
Definition: PCHit.h:99
float poissonLambda
Number of simulated photons at readout in the absence of fluctuations.
Definition: PCHit.h:124
int plane
plane number
Definition: PCHit.h:105
enum geo::_plane_proj View_t
Enumerate the possible plane projections.
void SetPoissonLambda(float aLambda)
Set number of simulated photons at readout before fluctuations.
Definition: PCHit.h:103
void SetTruePE(float aTruePE)
Set True PE value.
Definition: PCHit.h:89
bool GoodTime() const
Return quality of timing fit for cell.
Definition: PCHit.h:56
float trueW
True position along cell W (W)
Definition: PCHit.h:119
int Cell() const
Return cell value.
Definition: PCHit.h:26
float readDist
distance from hit to readout(including pigtail) (cm)
Definition: PCHit.h:123
float trueMeV
True energy of hit (MC Truth)
Definition: PCHit.h:116
bool goodTime
True if the time fit for the hit was good.
Definition: PCHit.h:121
int cell
cell number
Definition: PCHit.h:106
float truePE
True number of photoelectrons (MC Truth)
Definition: PCHit.h:117
float TrueW() const
Return True W value.
Definition: PCHit.h:52
float flightLen
path length from the start of track (cm)
Definition: PCHit.h:122
void SetTrueW(float aTrueW)
Set True W value.
Definition: PCHit.h:93
float tns
Time of pchit (ns)
Definition: PCHit.h:120
"Pre-calibration hit". Common input to calibration procedures
Definition: PCHit.h:16
float Path() const
Return Path value.
Definition: PCHit.h:42
float W() const
Return W value.
Definition: PCHit.h:44
float w
Unmeasured coordinate of hit.
Definition: PCHit.h:115
float PoissonLambda() const
Return number of simulated photons at readout before fluctuations.
Definition: PCHit.h:62
void SetView(geo::View_t aView)
Set view value.
Definition: PCHit.h:77
void SetReadDist(float aDist)
Set distance to cell readout.
Definition: PCHit.h:101
void SetPath(float aPath)
Set Path value.
Definition: PCHit.h:83
float PE() const
Return PE value.
Definition: PCHit.h:38
float TruePE() const
Return True PE value.
Definition: PCHit.h:48
void SetGoodTime(bool aGoodT)
Set quality of timing fit.
Definition: PCHit.h:97
float pe
uncalibrated PEs
Definition: PCHit.h:112
void SetDCM(int aDCM)
Set dcm value.
Definition: PCHit.h:71
float ADC() const
Return ADC value.
Definition: PCHit.h:40
void SetDiblock(int aDiblock)
Set diblock value.
Definition: PCHit.h:69
int Plane() const
Return plane value.
Definition: PCHit.h:24
geo::View_t View() const
Return view.
Definition: PCHit.h:36
int Diblock() const
Return diblock value.
Definition: PCHit.h:28
int dcm
number of dcm on diblock
Definition: PCHit.h:108
Histograms used by attenuation calibration.
float path
Path length.
Definition: PCHit.h:114
float ReadDist() const
Return distance to readout, with pigtail.
Definition: PCHit.h:60
geo::View_t view
hit view
Definition: PCHit.h:111
void SetPlane(int aPlane)
Set plane value.
Definition: PCHit.h:65
void SetW(float aW)
Set W value.
Definition: PCHit.h:85
int DCM() const
Return dcm value.
Definition: PCHit.h:30
float adc
ADC.
Definition: PCHit.h:113
void SetTruePath(float aTruePath)
Set True path length value.
Definition: PCHit.h:91
void SetCell(int aCell)
Set cell value.
Definition: PCHit.h:67
void SetTrueMeV(float aTrueMeV)
Set True energy (MeV) value.
Definition: PCHit.h:87