54 #ifndef StuProbabilityPidAlgorithm_hh
55 #define StuProbabilityPidAlgorithm_hh
60 #include "TObjString.h"
62 #include "StEventTypes.h"
63 #include "StParticleTable.hh"
64 #include "StParticleTypes.hh"
90 int mostLikelihoodParticleGeantID()
const;
91 int secondLikelihoodParticleGeantID()
const;
92 int thirdLikelihoodParticleGeantID()
const;
93 int getParticleGeantID(
int i)
const;
95 double getProbability(
int i);
96 double mostLikelihoodProbability();
97 double secondLikelihoodProbability();
98 double thirdLikelihoodProbability();
100 double getCentrality(
int theMult);
102 double beingPionMinusProb()
const {
return mPionMinusProb;}
103 double beingElectronProb()
const {
return mElectronProb; }
104 double beingKaonMinusProb()
const {
return mKaonMinusProb;}
105 double beingAntiProtonProb()
const {
return mAntiProtonProb;}
107 double beingPionPlusProb()
const {
return mPionPlusProb; }
108 double beingPositronProb()
const {
return mPositronProb; }
109 double beingKaonPlusProb()
const {
return mKaonPlusProb; }
110 double beingProtonProb()
const {
return mProtonProb; }
115 operator() (
const StTrack&,
const StSPtrVecTrackPidTraits&);
117 void processPIDAsFunction (
double theCent,
double theDca,
int theCharge,
double theRig,
double theEta,
int theNhits,
double theDedx);
119 static void setDedxMethod(StDedxMethod method);
121 static void readParametersFromFile(TString fileName);
123 static bool isPIDTableRead();
130 void fillPIDByLookUpTable(
double myCentrality,
double myDca,
int myCharge,
double myRig,
double myEta,
int myNhits,
double myDedx);
132 void fillPIDHypothis();
136 void fill(
double prob,
int geantId);
137 void fillAsUnknown();
138 void lowRigPID(
double rig,
double dedx,
int theCharge);
140 double getCentrality_P01gl(
int theMult);
141 double getCentrality_P03ia_dAu(
int theMult);
142 int getCentralityBin(
double theCent);
143 int getCalibPosition(
double theEta,
int theNHits);
144 void setCalibrations(
double theEta,
int theNhits);
155 double mPionMinusProb;
156 double mElectronProb;
157 double mKaonMinusProb;
158 double mAntiProtonProb;
159 double mPionPlusProb;
160 double mPositronProb;
161 double mKaonPlusProb;
167 static int thisMultBins;
168 static int thisDcaBins;
169 static int thisChargeBins;
172 static int thisPBins;
173 static int thisEtaBins;
174 static int thisNHitsBins;
178 static double thisDedxStart;
179 static double thisDedxEnd;
180 static double thisPStart;
181 static double thisPEnd;
182 static double thisEtaStart;
183 static double thisEtaEnd;
184 static double thisNHitsStart;
185 static double thisNHitsEnd;
187 static bool mPIDTableRead;
189 static StDedxMethod mDedxMethod;
191 static TVectorD* mEAmp;
192 static TVectorD* mECenter;
193 static TVectorD* mESigma;
195 static TVectorD* mPiAmp;
196 static TVectorD* mPiCenter;
197 static TVectorD* mPiSigma;
199 static TVectorD* mKAmp;
200 static TVectorD* mKCenter;
201 static TVectorD* mKSigma;
203 static TVectorD* mPAmp;
204 static TVectorD* mPCenter;
205 static TVectorD* mPSigma;
208 static TVectorD* mEqualyDividableRangeStartSet;
209 static TVectorD* mEqualyDividableRangeEndSet;
210 static TVectorD* mEqualyDividableRangeNBinsSet;
211 static TVectorD* mNoEqualyDividableRangeNBinsSet;
213 static TVectorD* mMultiBinEdgeSet;
214 static TVectorD* mDcaBinEdgeSet;
217 static TVectorD* mBBPrePar;
218 static TVectorD* mBBTurnOver;
219 static TVectorD* mBBOffSet;
220 static TVectorD* mBBScale;
221 static TVectorD* mBBSaturate;
224 static TObjString* mProductionTag;
231 inline int StuProbabilityPidAlgorithm::mostLikelihoodParticleGeantID()
const {
return PID[0];}
232 inline int StuProbabilityPidAlgorithm::secondLikelihoodParticleGeantID()
const {
return PID[1];}
233 inline int StuProbabilityPidAlgorithm::thirdLikelihoodParticleGeantID()
const {
return PID[2];}
234 inline int StuProbabilityPidAlgorithm::getParticleGeantID(
int i)
const {
235 if (i<4 && i>=0)
return PID[i];
else return -1;}