cfVtxHF->SetCentralityValue(centValue);
// number of tracklets - multiplicity estimator
- Double_t multiplicity = (Double_t)(aodEvent->GetTracklets()->GetNumberOfTracklets()); // casted to double because the CF is filled with doubles
+ Double_t multiplicity = (Double_t)(AliVertexingHFUtils::GetNumberOfTrackletsInEtaRange(aodEvent,-1.,1.)); // casted to double because the CF is filled with doubles
cfVtxHF->SetMultiplicity(multiplicity);
for (Int_t iPart=0; iPart<mcArray->GetEntriesFast(); iPart++) {
if (fCuts->GetIsUsePID() && fDecayChannel==22) {
fCuts->GetPidHF()->SetPidResponse(localPIDResponse);
- (dynamic_cast<AliRDHFCutsLctoV0*>(fCuts))->GetPidV0pos()->SetPidResponse(localPIDResponse);
- (dynamic_cast<AliRDHFCutsLctoV0*>(fCuts))->GetPidV0neg()->SetPidResponse(localPIDResponse);
fCuts->GetPidHF()->SetOldPid(kFALSE);
- (dynamic_cast<AliRDHFCutsLctoV0*>(fCuts))->GetPidV0pos()->SetOldPid(kFALSE);
- (dynamic_cast<AliRDHFCutsLctoV0*>(fCuts))->GetPidV0neg()->SetOldPid(kFALSE);
+ AliRDHFCutsLctoV0* lcv0Cuts=dynamic_cast<AliRDHFCutsLctoV0*>(fCuts);
+ if(lcv0Cuts){
+ lcv0Cuts->GetPidV0pos()->SetPidResponse(localPIDResponse);
+ lcv0Cuts->GetPidV0neg()->SetPidResponse(localPIDResponse);
+ lcv0Cuts->GetPidV0pos()->SetOldPid(kFALSE);
+ lcv0Cuts->GetPidV0neg()->SetOldPid(kFALSE);
+ }
}
//slot #1