BOSS 7.0.3
BESIII Offline Software System
Loading...
Searching...
No Matches
Event/DstEvent/DstEvent-00-02-51/DstEvent/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"
5#include "EventModel/EventModel.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
ObjectVector< DstMdcDedx > DstMdcDedxCol
const CLID & CLID_DstMdcDedx
Definition: EventModel.cxx:258