{
//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 iSelParticlesPOI = 0; //number of tracks selected for Diff
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
- //make new AliFLowTrackSimple
- AliFlowTrackSimple* pTrack = new AliFlowTrackSimple();
- pTrack->SetPt(pParticle->Pt() );
- pTrack->SetEta(pParticle->Eta() );
- pTrack->SetPhi(pParticle->Phi() );
+
//check if pParticle passes the cuts
-
if (intCFManager->CheckParticleCuts(AliCFManager::kPartRecCuts,pParticle) &&
intCFManager->CheckParticleCuts(AliCFManager::kPartSelCuts,pParticle)) {
- pTrack->SetForRPSelection(kTRUE);
+ bPassedRPFlowCuts = kTRUE;
}
if (diffCFManager->CheckParticleCuts(AliCFManager::kPartRecCuts,pParticle) &&
diffCFManager->CheckParticleCuts(AliCFManager::kPartSelCuts,pParticle)) {
- pTrack->SetForPOISelection(kTRUE);}
-
- //check if any bits are set
- TBits bFlowBits = pTrack->GetFlowBits();
- if (bFlowBits.CountBits() ==0) {
- delete pTrack; } //track will not be used anymore
- else {
- pEvent->TrackCollection()->Add(pTrack) ;
- iGoodTracks++;
-
- if (pTrack->InRPSelection())
- { iSelParticlesRP++; }
- if (pTrack->InPOISelection())
- { iSelParticlesPOI++; }
-
+ bPassedPOIFlowCuts = kTRUE;
}
+ if (bPassedRPFlowCuts || bPassedPOIFlowCuts) {
+ //make new AliFLowTrackSimple
+ AliFlowTrackSimple* pTrack = new AliFlowTrackSimple();
+ pTrack->SetPt(pParticle->Pt() );
+ pTrack->SetEta(pParticle->Eta() );
+ pTrack->SetPhi(pParticle->Phi() );
+
+ //marking the particles used for int. flow:
+ if(bPassedRPFlowCuts) {
+ pTrack->SetForRPSelection(kTRUE);
+ iSelParticlesRP++;
+ }
+ //marking the particles used for diff. flow:
+ if(bPassedPOIFlowCuts) {
+ 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 if(bPassedIntFlowCuts || bPassedDiffFlowCuts)
itrkN++;
- }
+ bPassedRPFlowCuts = kFALSE;
+ bPassedPOIFlowCuts = kFALSE;
+ }//end of while (itrkN < iNumberOfInputTracks)
- pEvent-> SetEventNSelTracksRP(iSelParticlesRP);
+ pEvent->SetEventNSelTracksRP(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;
Bool_t LYZEP = kFALSE;
Bool_t GFC = kTRUE;
Bool_t QC = kTRUE;
-Bool_t FQD = kFALSE;
-Bool_t MCEP = kFALSE; //not for pp
+Bool_t FQD = kTRUE;
+Bool_t MCEP = kTRUE; //not for pp
Bool_t METHODS[] = {SP,LYZ1SUM,LYZ1PROD,LYZ2SUM,LYZ2PROD,LYZEP,GFC,QC,FQD,MCEP};
Bool_t WEIGHTS[] = {kFALSE,kFALSE,kFALSE}; //Phi, v'(pt), v'(eta)
-void runFlowTask(Int_t mode=mLocal, Int_t nRuns = 40,
+void runFlowTask(Int_t mode=mLocal, Int_t nRuns = 100,
//const Char_t* dataDir="/data/alice2/kolk/PP/LHC09a4/81119", Int_t offset = 0)
- const Char_t* dataDir="/data/alice2/kolk/Therminator_midcentral", Int_t offset = 0)
+ //const Char_t* dataDir="/data/alice2/kolk/Therminator_midcentral", Int_t offset = 0)
+ const Char_t* dataDir="/Users/snelling/alice_data/Therminator_midcentral", Int_t offset = 0)
//void runFlowTask(Int_t mode=mPROOF, Int_t nRuns = 10000,
// const Char_t* dataDir="/COMMON/COMMON/LHC09a4_run8158X", Int_t offset = 0)
//const Char_t* dataDir="/PWG2/akisiel/Therminator_c2030", Int_t offset=0)