fPhysicsSelection(0),
fProtonAnalysisMode(kTPC), fProtonPIDMode(kBayesian),
fAnalysisEtaMode(kFALSE),
+ fRunQAAnalysis(kFALSE),
fVxMax(100.), fVyMax(100.), fVzMax(100.), fMinNumOfContributors(0),
fNBinsX(0), fMinX(0), fMaxX(0),
fNBinsY(0), fMinY(0), fMaxY(0),
fNSigma(0), fNRatio(0),
fElectronFunction(0), fMuonFunction(0),
fPionFunction(0), fKaonFunction(0), fProtonFunction(0),
- fDebugMode(kFALSE), fListVertexQA(new TList()) {
+ fDebugMode(kFALSE), fListVertexQA(0) {
//Default constructor
for(Int_t i = 0; i < 5; i++) fPartFrac[i] = 0.0;
/*for(Int_t i = 0; i < 24; i++) {
fdEdxMean[i] = 0.0;
fdEdxSigma[i] = 0.0;
}*/
+
+ fListVertexQA = new TList();
fListVertexQA->SetName("fListVertexQA");
TH1F *gHistVx = new TH1F("gHistVx",
"Vx distribution;V_{x} [cm];Entries",
if(fKaonFunction) delete fKaonFunction;
if(fProtonFunction) delete fProtonFunction;
if(fListVertexQA) delete fListVertexQA;
+ if(fPtDependentDcaXY) delete fPtDependentDcaXY;
+ if(fPhysicsSelection) delete fPhysicsSelection;
}
//____________________________________________________________________//
//____________________________________________________________________//
Bool_t AliProtonAnalysisBase::IsAccepted(AliESDtrack* track) {
// Checks if the track is excluded from the cuts
- Int_t fIdxInt[200];
- Int_t nClustersITS = track->GetITSclusters(fIdxInt);
- Int_t nClustersTPC = track->GetTPCclusters(fIdxInt);
+ //Int_t fIdxInt[200];
+ //Int_t nClustersITS = track->GetITSclusters(fIdxInt);
+ //Int_t nClustersTPC = track->GetTPCclusters(fIdxInt);
+ Int_t nClustersITS = track->GetITSclusters(0x0);
+ Int_t nClustersTPC = track->GetTPCclusters(0x0);
Float_t chi2PerClusterITS = -1;
if (nClustersITS!=0)
if(fPtDependentDcaXYFlag) {
if(TMath::Abs(dca[0]) > kMicrometer2Centimeter*fNSigmaDCAXY*fPtDependentDcaXY->Eval(gPt)) {
if(fDebugMode)
- Printf("IsPrimary: Track rejected because it has a value of the dca(xy) higher than the %d sigma pt dependent cut: %lf (max. requested: %lf)",TMath::Abs(dca[0]),fNSigmaDCAXY,fNSigmaDCAXY*fPtDependentDcaXY->Eval(gPt));
+ Printf("IsPrimary: Track rejected because it has a value of the dca(xy) higher than the %d sigma pt dependent cut: %lf (max. requested: %lf)",fNSigmaDCAXY,TMath::Abs(dca[0]),fNSigmaDCAXY*fPtDependentDcaXY->Eval(gPt));
return kFALSE;
}
}
fAlephParameters[4] = 4.88663e+00;
}
- AliESDpid *fESDpid = new AliESDpid();
- AliTPCPIDResponse tpcResponse = fESDpid->GetTPCResponse();
- tpcResponse.SetBetheBlochParameters(fAlephParameters[0],fAlephParameters[1],fAlephParameters[2],fAlephParameters[3],fAlephParameters[4]);
+ AliTPCPIDResponse *tpcResponse = new AliTPCPIDResponse();
+ tpcResponse->SetBetheBlochParameters(fAlephParameters[0],fAlephParameters[1],fAlephParameters[2],fAlephParameters[3],fAlephParameters[4]);
Double_t normalizeddEdx = -10.;
- if((track->GetTPCsignal() > 0.0) && (tpcResponse.GetExpectedSignal(gP,AliPID::kProton) > 0.0))
- TMath::Log(track->GetTPCsignal()/tpcResponse.GetExpectedSignal(gP,AliPID::kProton));
-
+ if((track->GetTPCsignal() > 0.0) && (tpcResponse->GetExpectedSignal(gP,AliPID::kProton) > 0.0))
+ normalizeddEdx = TMath::Log(track->GetTPCsignal()/tpcResponse->GetExpectedSignal(gP,AliPID::kProton));
+
+ delete tpcResponse;
+
if(normalizeddEdx >= fNRatio)
return kTRUE;
}//kRatio PID mode
}
Double_t nsigma = 100.0;
- AliESDpid *fESDpid = new AliESDpid();
- fESDpid->GetTPCResponse().SetBetheBlochParameters(fAlephParameters[0],fAlephParameters[1],fAlephParameters[2],fAlephParameters[3],fAlephParameters[4]);
+ AliTPCPIDResponse *tpcResponse = new AliTPCPIDResponse();
+ tpcResponse->SetBetheBlochParameters(fAlephParameters[0],fAlephParameters[1],fAlephParameters[2],fAlephParameters[3],fAlephParameters[4]);
- AliExternalTrackParam *tpcTrack = (AliExternalTrackParam *)track->GetTPCInnerParam();
- if(tpcTrack)
- nsigma = TMath::Abs(fESDpid->NumberOfSigmasTPC(track,AliPID::kProton));
+ Double_t mom = track->GetP();
+ const AliExternalTrackParam *in = track->GetInnerParam();
+ if (in)
+ mom = in->GetP();
+
+ nsigma = TMath::Abs(tpcResponse->GetNumberOfSigmas(mom,track->GetTPCsignal(),track->GetTPCsignalN(),AliPID::kProton));
+ delete tpcResponse;
if(nsigma <= fNSigma)
return kTRUE;
}//kSigma PID method
- //Another definition of an N-sigma area around the dE/dx vs P band
- /*else if(fProtonPIDMode == kSigma2) {
- AliExternalTrackParam *tpcTrack = (AliExternalTrackParam *)track->GetTPCInnerParam();
- if(tpcTrack) {
- gPt = tpcTrack->Pt();
- gP = tpcTrack->P();
- gEta = tpcTrack->Eta();
- }
- Double_t fAlephParameters[5];
- if(fAnalysisMC) {
- fAlephParameters[0] = 2.15898e+00/50.;
- fAlephParameters[1] = 1.75295e+01;
- fAlephParameters[2] = 3.40030e-09;
- fAlephParameters[3] = 1.96178e+00;
- fAlephParameters[4] = 3.91720e+00;
- }
- else {
- fAlephParameters[0] = 0.0283086;
- fAlephParameters[1] = 2.63394e+01;
- fAlephParameters[2] = 5.04114e-11;
- fAlephParameters[3] = 2.12543e+00;
- fAlephParameters[4] = 4.88663e+00;
- }
-
- AliESDpid *fESDpid = new AliESDpid();
- AliTPCPIDResponse tpcResponse = fESDpid->GetTPCResponse();
- tpcResponse.SetBetheBlochParameters(fAlephParameters[0],fAlephParameters[1],fAlephParameters[2],fAlephParameters[3],fAlephParameters[4]);
- Double_t normalizeddEdx = TMath::Log(track->GetTPCsignal()/tpcResponse.GetExpectedSignal(gP,AliPID::kProton));
-
- if(normalizeddEdx >= -0.15)
- return kTRUE;
- }*/
return kFALSE;
}