From 6c75368ad3fe008a830eaca5e4f2a8bbb6ed486f Mon Sep 17 00:00:00 2001 From: snelling Date: Fri, 3 Jul 2009 08:54:05 +0000 Subject: [PATCH] fix for cuts --- .../AliFlowTasks/AliFlowEventSimpleMaker.cxx | 81 +------------------ 1 file changed, 2 insertions(+), 79 deletions(-) diff --git a/PWG2/FLOW/AliFlowTasks/AliFlowEventSimpleMaker.cxx b/PWG2/FLOW/AliFlowTasks/AliFlowEventSimpleMaker.cxx index 73ddae125df..89023cd8673 100644 --- a/PWG2/FLOW/AliFlowTasks/AliFlowEventSimpleMaker.cxx +++ b/PWG2/FLOW/AliFlowTasks/AliFlowEventSimpleMaker.cxx @@ -150,7 +150,7 @@ AliFlowEventSimple* AliFlowEventSimpleMaker::FillTracks(AliMCEvent* anInput, Ali } //----------------------------------------------------------------------- -/* + AliFlowEventSimple* AliFlowEventSimpleMaker::FillTracks(AliESDEvent* anInput, AliCFManager* intCFManager, AliCFManager* diffCFManager) { //Fills the event from the ESD @@ -239,7 +239,7 @@ AliFlowEventSimple* AliFlowEventSimpleMaker::FillTracks(AliESDEvent* anInput, Al } } -*/ + //----------------------------------------------------------------------- AliFlowEventSimple* AliFlowEventSimpleMaker::FillTracks(AliAODEvent* anInput, AliCFManager* intCFManager, AliCFManager* diffCFManager) { @@ -697,83 +697,6 @@ AliFlowEventSimple* AliFlowEventSimpleMaker::FillTracks(AliESDEvent* anInput) //----------------------------------------------------------------------- -AliFlowEventSimple* AliFlowEventSimpleMaker::FillTracks(AliESDEvent* anInput, AliCFManager* intCFManager, AliCFManager* diffCFManager) -{ - //Fills the event from the ESD - - //flags for particles passing int. and diff. flow cuts - Bool_t bPassedRPFlowCuts = kFALSE; - Bool_t bPassedPOIFlowCuts = kFALSE; - - Int_t iNumberOfInputTracks = anInput->GetNumberOfTracks() ; - - AliFlowEventSimple* pEvent = new AliFlowEventSimple(10); - - Int_t iGoodTracks = 0; //number of good tracks - Int_t itrkN = 0; //track counter - Int_t iSelParticlesRP = 0; //number of tracks selected for Int - Int_t iSelParticlesPOI = 0; //number of tracks selected for Diff - - //normal loop - while (itrkN < iNumberOfInputTracks) { - AliESDtrack* pParticle = anInput->GetTrack(itrkN); //get input particle - - //check if pParticle passes the cuts - if (intCFManager->CheckParticleCuts(AliCFManager::kPartRecCuts,pParticle) && - intCFManager->CheckParticleCuts(AliCFManager::kPartSelCuts,pParticle)) { - bPassedRPFlowCuts = kTRUE; - } - if (diffCFManager->CheckParticleCuts(AliCFManager::kPartRecCuts,pParticle) && - diffCFManager->CheckParticleCuts(AliCFManager::kPartSelCuts,pParticle)) { - bPassedPOIFlowCuts = kTRUE; - } - - if (bPassedRPFlowCuts || bPassedPOIFlowCuts) { - for(Int_t d=0;dSetPt(pParticle->Pt() ); - pTrack->SetEta(pParticle->Eta() ); - pTrack->SetPhi(pParticle->Phi()-fEllipticFlowValue*TMath::Sin(2*(pParticle->Phi()-fMCReactionPlaneAngle)) ); - - //marking the particles used for int. flow: - if(bPassedRPFlowCuts && iSelParticlesRP < fMultiplicityOfEvent) { - pTrack->SetForRPSelection(kTRUE); - iSelParticlesRP++; - } - //marking the particles used for diff. flow: - if(bPassedPOIFlowCuts && iGoodTracks%fNoOfLoops==0) { - pTrack->SetForPOISelection(kTRUE); - iSelParticlesPOI++; - } - //adding a particles which were used either for int. or diff. flow to the list - pEvent->TrackCollection()->Add(pTrack); - iGoodTracks++; - }//end of for(Int_t d=0;dSetEventNSelTracksRP(iSelParticlesRP); - pEvent->SetNumberOfTracks(iGoodTracks); - pEvent->SetMCReactionPlaneAngle(fMCReactionPlaneAngle); - - if ( (++fCount % 100) == 0) { - if (!fMCReactionPlaneAngle == 0) cout<<" MC Reaction Plane Angle = "<< fMCReactionPlaneAngle << endl; - else cout<<" MC Reaction Plane Angle = unknown "<< endl; - cout<<" iGoodTracks = "<