From: gconesab Date: Tue, 18 Jan 2011 16:14:10 +0000 (+0000) Subject: Remove unnecessary print from QA class X-Git-Url: http://git.uio.no/git/?a=commitdiff_plain;h=952615e5605cb0f94f5254270fd313585a995325;p=u%2Fmrichter%2FAliRoot.git Remove unnecessary print from QA class AliMCAnalysisUtils: Add to the method to get first common ancestor of 2 particles the possibility to recover the momentum of this ancestor. --- diff --git a/PWG4/PartCorrBase/AliMCAnalysisUtils.cxx b/PWG4/PartCorrBase/AliMCAnalysisUtils.cxx index d63538dc7cf..cfa43e3f6d1 100755 --- a/PWG4/PartCorrBase/AliMCAnalysisUtils.cxx +++ b/PWG4/PartCorrBase/AliMCAnalysisUtils.cxx @@ -107,7 +107,7 @@ Int_t AliMCAnalysisUtils::CheckOrigin(const Int_t * label, const Int_t nlabels, //_________________________________________________________________________ Int_t AliMCAnalysisUtils::CheckCommonAncestor(const Int_t index1, const Int_t index2, AliCaloTrackReader* reader, - Int_t & ancPDG, Int_t & ancStatus) { + Int_t & ancPDG, Int_t & ancStatus, TLorentzVector & momentum) { //Check the first common ancestor of 2 clusters, given the most likely labels of the primaries generating such clusters. Int_t label1[100]; Int_t label2[100]; @@ -188,6 +188,7 @@ Int_t AliMCAnalysisUtils::CheckCommonAncestor(const Int_t index1, const Int_t in if (mom) { ancPDG = mom->GetPdgCode(); ancStatus = mom->GetStatus(); + momentum.SetPxPyPzE(mom->Px(),mom->Py(),mom->Pz(),mom->E()); } } else { @@ -195,6 +196,7 @@ Int_t AliMCAnalysisUtils::CheckCommonAncestor(const Int_t index1, const Int_t in if (mom) { ancPDG = mom->GetPdgCode(); ancStatus = mom->GetStatusCode(); + mom->Momentum(momentum); } } //First ancestor found, end the loops diff --git a/PWG4/PartCorrBase/AliMCAnalysisUtils.h b/PWG4/PartCorrBase/AliMCAnalysisUtils.h index 00494e931a0..958a7eedcc4 100755 --- a/PWG4/PartCorrBase/AliMCAnalysisUtils.h +++ b/PWG4/PartCorrBase/AliMCAnalysisUtils.h @@ -45,7 +45,7 @@ class AliMCAnalysisUtils : public TObject { //Check only the label of the most significant particle Int_t CheckCommonAncestor(const Int_t index1, const Int_t index2, AliCaloTrackReader* reader, - Int_t & ancPDG, Int_t & ancStatus) ; + Int_t & ancPDG, Int_t & ancStatus, TLorentzVector & momentum) ; Int_t CheckOrigin(const Int_t label, AliCaloTrackReader * reader, const Int_t input) ; //Check the label of the most significant particle but do checks on the rest of the contributing labels Int_t CheckOrigin(const Int_t *label, const Int_t nlabels, AliCaloTrackReader * reader, const Int_t input) ; diff --git a/PWG4/PartCorrDep/AliAnaCalorimeterQA.cxx b/PWG4/PartCorrDep/AliAnaCalorimeterQA.cxx index 63adeedf649..1875d714d7a 100755 --- a/PWG4/PartCorrDep/AliAnaCalorimeterQA.cxx +++ b/PWG4/PartCorrDep/AliAnaCalorimeterQA.cxx @@ -1526,7 +1526,6 @@ void AliAnaCalorimeterQA::MakeAnalysisFillHistograms() if(imax == ipos) continue; absId = indexList[ipos]; Float_t diff = (tmax-cell->GetCellTime(absId))*1e9; - printf("diff time %f %p",diff,fhCellTimeSpreadRespectToCellMax); fhCellTimeSpreadRespectToCellMax->Fill(diff); if(TMath::Abs(TMath::Abs(diff) > 100)) fhCellIdCellLargeTimeSpread->Fill(absId); }// fill cell-cluster histogram loop