BOSS 7.0.6
BESIII Offline Software System
Loading...
Searching...
No Matches
DstMdcDedx.h
Go to the documentation of this file.
1#ifndef DST_DSTMDCDEDX_H
2#define DST_DSTMDCDEDX_H
3#include "GaudiKernel/ObjectVector.h"
4#include "GaudiKernel/ContainedObject.h"
6
7using namespace EventModel;
8extern const CLID &CLID_DstMdcDedx;
10
11class DstMdcDedx : virtual public ContainedObject {
12public:
13
14// ctor and dector
16 virtual ~DstMdcDedx() {}
17
18 virtual const CLID& clID() const { return DstMdcDedx::classID(); }
19 static const CLID& classID() { return CLID_DstMdcDedx; }
20
21// extractors
22 //int getTrackId() const {return m_trackId ;}
23 //int getParticleId() const { return m_particleId; }
24 //int getStatus() const { return m_status; }
25 //int geTruncAlg() const { return m_trunc_alg; }
26 //double getNumChidedx(int i) const { return m_numChidedx[i]; }
27 //int getNumGoodHits() const { return m_numGoodHits; }
28 //int getNumTotalHits() const { return m_numTotalHits; }
29 //double getProbPH() const { return m_probPH; }
30 //double getNormPH() const { return m_normPH; }
31// extractors
32 int trackId() const {return m_trackId ;}
33 int particleId() const { return m_particleId; } // will converge to particleType() later
35 switch(particleId()){
36 case 0:
37 return electron;
38 break;
39 case 1:
40 return muon;
41 break;
42 case 2:
43 return kaon;
44 break;
45 case 3:
46 return pion;
47 break;
48 case 4:
49 return proton;
50 break;
51 default:
52 std::cerr << "the particleType receive an incorrect input!" << std::endl;
53 exit(1);
54 }
55 }
56 int status() const { return m_status; }
57 int truncAlg() const { return m_trunc_alg; }
58 double chi(int i) const { return m_chi[i]; }
59 double chiE() const { return m_chi[0]; }
60 double chiMu() const { return m_chi[1]; }
61 double chiPi() const { return m_chi[2]; }
62 double chiK() const { return m_chi[3]; }
63 double chiP() const { return m_chi[4]; }
64 int numGoodHits() const { return m_numGoodHits; }
65 int numTotalHits() const { return m_numTotalHits; }
66 double probPH() const { return m_probPH; }
67 double normPH() const { return m_normPH; }
68 double errorPH() const { return m_errorPH; }
69 double twentyPH() const { return m_twentyPH; }
70
71// modifiers
75 void setTruncAlg(int trunc_alg) { m_trunc_alg = trunc_alg; }
76
77 void setChi( double* chi) {
78 for(int i =0; i<5 ; i++) m_chi[i]= chi[i];
79 }
80
83 void setProbPH(double probPH) { m_probPH = probPH; }
84 void setNormPH(double normPH) { m_normPH = normPH; }
85 void setErrorPH(double errorPH) { m_errorPH = errorPH; }
87 protected:
88 int m_trackId ; //Track ID Add 2005-10-18
89 int m_particleId; //Particle ID from De/Dx
90 int m_status; //Status
91 int m_trunc_alg; //truncate method
92 double m_chi[5]; //Number of Chi_dEdx for different particles
93 //0: e 1: mu 2: pi 3: K 4:p
94 int m_numGoodHits; //No. of good de/dx hits(exclude overflow)
95 int m_numTotalHits; //No. of good de/dx hits(include overflow)
96 double m_probPH; //Most probable pulse height from truncated mean
97 double m_normPH; //normalized pulse height
98 double m_errorPH; //resolution of truncated mean
99 double m_twentyPH; //de/dx value of bitrunction rate equal to 20%
100};
101
102typedef ObjectVector<DstMdcDedx> DstMdcDedxCol;
103
104#endif //DST_DEDX_H
105
const CLID & CLID_DstMdcDedx
Definition: EventModel.cxx:258
pid_dedx
Definition: DstMdcDedx.h:9
@ electron
Definition: DstMdcDedx.h:9
@ pion
Definition: DstMdcDedx.h:9
@ kaon
Definition: DstMdcDedx.h:9
@ muon
Definition: DstMdcDedx.h:9
@ proton
Definition: DstMdcDedx.h:9
ObjectVector< DstMdcDedx > DstMdcDedxCol
Definition: DstMdcDedx.h:102
double m_chi[5]
Definition: DstMdcDedx.h:92
void setChi(double *chi)
Definition: DstMdcDedx.h:77
int m_numTotalHits
Definition: DstMdcDedx.h:95
void setTruncAlg(int trunc_alg)
Definition: DstMdcDedx.h:75
double probPH() const
Definition: DstMdcDedx.h:66
static const CLID & classID()
Definition: DstMdcDedx.h:19
int m_trackId
Definition: DstMdcDedx.h:88
int m_status
Definition: DstMdcDedx.h:90
double chiE() const
Definition: DstMdcDedx.h:59
void setStatus(int status)
Definition: DstMdcDedx.h:74
double m_errorPH
Definition: DstMdcDedx.h:98
virtual ~DstMdcDedx()
Definition: DstMdcDedx.h:16
void setTwentyPH(double twentyPH)
Definition: DstMdcDedx.h:86
int m_trunc_alg
Definition: DstMdcDedx.h:91
virtual const CLID & clID() const
Definition: DstMdcDedx.h:18
double m_twentyPH
Definition: DstMdcDedx.h:99
int particleId() const
Definition: DstMdcDedx.h:33
void setNumGoodHits(int numGoodHits)
Definition: DstMdcDedx.h:81
double errorPH() const
Definition: DstMdcDedx.h:68
double m_probPH
Definition: DstMdcDedx.h:96
int numTotalHits() const
Definition: DstMdcDedx.h:65
pid_dedx particleType() const
Definition: DstMdcDedx.h:34
void setProbPH(double probPH)
Definition: DstMdcDedx.h:83
int numGoodHits() const
Definition: DstMdcDedx.h:64
void setNormPH(double normPH)
Definition: DstMdcDedx.h:84
double normPH() const
Definition: DstMdcDedx.h:67
int truncAlg() const
Definition: DstMdcDedx.h:57
void setParticleId(int particleId)
Definition: DstMdcDedx.h:73
int status() const
Definition: DstMdcDedx.h:56
double chiPi() const
Definition: DstMdcDedx.h:61
void setTrackId(int trackId)
Definition: DstMdcDedx.h:72
void setNumTotalHits(int numTotalHits)
Definition: DstMdcDedx.h:82
double chiK() const
Definition: DstMdcDedx.h:62
int m_numGoodHits
Definition: DstMdcDedx.h:94
void setErrorPH(double errorPH)
Definition: DstMdcDedx.h:85
double twentyPH() const
Definition: DstMdcDedx.h:69
double chiMu() const
Definition: DstMdcDedx.h:60
int trackId() const
Definition: DstMdcDedx.h:32
int m_particleId
Definition: DstMdcDedx.h:89
double chi(int i) const
Definition: DstMdcDedx.h:58
double chiP() const
Definition: DstMdcDedx.h:63
double m_normPH
Definition: DstMdcDedx.h:97