From 0aba57ed44fefa694371dba00b08df14c8899060 Mon Sep 17 00:00:00 2001 From: dainese Date: Thu, 24 Feb 2011 14:58:26 +0000 Subject: [PATCH] Use nTPCclsFordEdx instead of nTPCcls (Rossella) --- PWG3/vertexingHF/AliAODPidHF.cxx | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/PWG3/vertexingHF/AliAODPidHF.cxx b/PWG3/vertexingHF/AliAODPidHF.cxx index 477898fd14d..bbad4cc8f8d 100644 --- a/PWG3/vertexingHF/AliAODPidHF.cxx +++ b/PWG3/vertexingHF/AliAODPidHF.cxx @@ -179,13 +179,15 @@ Int_t AliAODPidHF::ApplyPidTPCRaw(AliAODTrack *track,Int_t specie) const{ Double_t mom = pidObj->GetTPCmomentum(); AliTPCPIDResponse tpcResponse; SetBetheBloch(tpcResponse); + UShort_t nTPCClus=pidObj->GetTPCsignalN(); + if(nTPCClus==0) {nTPCClus=track->GetTPCNcls();} Int_t pid=-1; if(specie<0){ // from RawSignalPID : should return the particle specie to wich the de/dx is closer to the bethe-block curve -> performance to be checked Double_t nsigmaMax=fnSigma[0]; for(Int_t ipart=0;ipart<5;ipart++){ AliPID::EParticleType type=AliPID::EParticleType(ipart); - Double_t nsigma = TMath::Abs(tpcResponse.GetNumberOfSigmas(mom,dedx,track->GetTPCNcls(),type)); + Double_t nsigma = TMath::Abs(tpcResponse.GetNumberOfSigmas(mom,dedx,nTPCClus,type)); if((nsigmaGetTPCNcls(),type)); + Double_t nsigma = TMath::Abs(tpcResponse.GetNumberOfSigmas(mom,dedx,nTPCClus,type)); if (nsigma>fnSigma[0]) { pid=-1; }else{ @@ -449,11 +451,13 @@ Bool_t AliAODPidHF::TPCRawAsym(AliAODTrack* track,Int_t specie) const{ AliAODPid *pidObj = track->GetDetPid(); Double_t mom = pidObj->GetTPCmomentum(); Double_t dedx=pidObj->GetTPCsignal(); + UShort_t nTPCClus=pidObj->GetTPCsignalN(); + if(nTPCClus==0) {nTPCClus=track->GetTPCNcls();} AliTPCPIDResponse tpcResponse; SetBetheBloch(tpcResponse); AliPID::EParticleType type=AliPID::EParticleType(specie); - Double_t nsigma = TMath::Abs(tpcResponse.GetNumberOfSigmas(mom,dedx,track->GetTPCNcls(),type)); + Double_t nsigma = TMath::Abs(tpcResponse.GetNumberOfSigmas(mom,dedx,nTPCClus,type)); if(momfPLimit[0] && nsigma