some cleanup and renamig of local data members
authorMikolaj Krzewicki <mkrzewic@localhost.localdomain>
Wed, 29 Jan 2014 12:54:40 +0000 (13:54 +0100)
committerMikolaj Krzewicki <mikolaj.krzewicki@cern.ch>
Fri, 31 Jan 2014 09:44:58 +0000 (10:44 +0100)
PWG/FLOW/Base/AliFlowEventSimple.cxx
PWG/FLOW/Base/AliFlowEventSimple.h
PWG/FLOW/Base/AliFlowTrackSimple.cxx
PWG/FLOW/Base/AliFlowTrackSimple.h
PWG/FLOW/Base/AliFlowTrackSimpleCuts.cxx
PWG/FLOW/Base/AliFlowTrackSimpleCuts.h
PWG/FLOW/Base/AliFlowVector.h
PWG/FLOW/Tasks/AliFlowEventCuts.cxx
PWG/FLOW/Tasks/AliFlowEventCuts.h
PWG/FLOW/Tasks/AliFlowTrackCuts.h

index bd74c16..a921fb6 100644 (file)
@@ -68,14 +68,14 @@ AliFlowEventSimple::AliFlowEventSimple():
   fUserModified(kFALSE),
   fNumberOfTracksWrap(NULL),
   fNumberOfRPsWrap(NULL),
-  fNumberOfFlowTagsWrap(NULL),
+  fNumberOfPOIsWrap(NULL),
   fMCReactionPlaneAngleWrap(NULL),
   fShuffledIndexes(NULL),
   fShuffleTracks(kFALSE),
   fMothersCollection(NULL),
   fCentrality(-1.),
-  fNumberOfFlowTagClasses(2),
-  fNumberOfFlowTags(NULL)
+  fNumberOfPOItypes(2),
+  fNumberOfPOIs(NULL)
 {
   cout << "AliFlowEventSimple: Default constructor to be used only by root for io" << endl;
 }
@@ -107,14 +107,14 @@ AliFlowEventSimple::AliFlowEventSimple( Int_t n,
   fUserModified(kFALSE),
   fNumberOfTracksWrap(NULL),
   fNumberOfRPsWrap(NULL),
-  fNumberOfFlowTagsWrap(NULL),
+  fNumberOfPOIsWrap(NULL),
   fMCReactionPlaneAngleWrap(NULL),
   fShuffledIndexes(NULL),
   fShuffleTracks(kFALSE),
   fMothersCollection(new TObjArray()),
   fCentrality(-1.),
-  fNumberOfFlowTagClasses(2),
-  fNumberOfFlowTags(new Int_t[fNumberOfFlowTagClasses])
+  fNumberOfPOItypes(2),
+  fNumberOfPOIs(new Int_t[fNumberOfPOItypes])
 {
   //ctor
   // if second argument is set to AliFlowEventSimple::kGenerate
@@ -147,50 +147,47 @@ AliFlowEventSimple::AliFlowEventSimple(const AliFlowEventSimple& anEvent):
   fUserModified(anEvent.fUserModified),
   fNumberOfTracksWrap(anEvent.fNumberOfTracksWrap),
   fNumberOfRPsWrap(anEvent.fNumberOfRPsWrap),
-  fNumberOfFlowTagsWrap(anEvent.fNumberOfFlowTagsWrap),
+  fNumberOfPOIsWrap(anEvent.fNumberOfPOIsWrap),
   fMCReactionPlaneAngleWrap(anEvent.fMCReactionPlaneAngleWrap),
   fShuffledIndexes(NULL),
   fShuffleTracks(anEvent.fShuffleTracks),
   fMothersCollection(new TObjArray()),
   fCentrality(anEvent.fCentrality),
-  fNumberOfFlowTagClasses(anEvent.fNumberOfFlowTagClasses),
-  fNumberOfFlowTags(new Int_t[fNumberOfFlowTagClasses])
+  fNumberOfPOItypes(anEvent.fNumberOfPOItypes),
+  fNumberOfPOIs(new Int_t[fNumberOfPOItypes])
 {
   //copy constructor
-  memcpy(fNumberOfFlowTags,anEvent.fNumberOfFlowTags,fNumberOfFlowTagClasses*sizeof(Int_t));
+  memcpy(fNumberOfPOIs,anEvent.fNumberOfPOIs,fNumberOfPOItypes*sizeof(Int_t));
 }
 
 //-----------------------------------------------------------------------
-void AliFlowEventSimple::SetNumberOfPOIs( Int_t np, Int_t tagClass)
-{
-  //set the number of POIs increasing the size of the array in necessary
-  if (tagClass>=fNumberOfFlowTagClasses) SetNumberOfFlowTagClasses(tagClass+1);
-  fNumberOfFlowTags[tagClass] = np;
-}
-
-//-----------------------------------------------------------------------
-void AliFlowEventSimple::IncrementNumberOfPOIs(Int_t tagClass)
-{
-  if (tagClass>=fNumberOfFlowTagClasses) SetNumberOfFlowTagClasses(tagClass+1);
-  fNumberOfFlowTags[tagClass]++;
-}
-
-//-----------------------------------------------------------------------
-void AliFlowEventSimple::SetNumberOfFlowTagClasses(Int_t n)
+void AliFlowEventSimple::SetNumberOfPOIs( Int_t numberOfPOIs, Int_t poiType)
 {
   //set the number of poi classes, resize the array if larger is needed
   //never shrink the array
   //never decrease the stored number
-  if (n>fNumberOfFlowTagClasses)
+  if (poiType>=fNumberOfPOItypes)
   {
+    Int_t n = poiType+1;
     Int_t* tmp = new Int_t[n];
     for (Int_t j=0; j<n; j++) { tmp[j]=0; }       
-    memcpy(tmp,fNumberOfFlowTags,fNumberOfFlowTagClasses*sizeof(Int_t));
-    delete [] fNumberOfFlowTags;
-    fNumberOfFlowTags = tmp;
-    fNumberOfFlowTagClasses = n;
+    memcpy(tmp,fNumberOfPOIs,fNumberOfPOItypes*sizeof(Int_t));
+    delete [] fNumberOfPOIs;
+    fNumberOfPOIs = tmp;
+    fNumberOfPOItypes = n;
   }
+  
+  fNumberOfPOIs[poiType] = numberOfPOIs;
 }
+
+//-----------------------------------------------------------------------
+void AliFlowEventSimple::IncrementNumberOfPOIs(Int_t poiType)
+{
+
+  if (poiType>=fNumberOfPOItypes) SetNumberOfPOIs(0,poiType);
+  fNumberOfPOIs[poiType]++;
+}
+
 //-----------------------------------------------------------------------
 AliFlowEventSimple& AliFlowEventSimple::operator=(const AliFlowEventSimple& anEvent)
 {
@@ -201,10 +198,10 @@ AliFlowEventSimple& AliFlowEventSimple::operator=(const AliFlowEventSimple& anEv
   fTrackCollection = (TObjArray*)(anEvent.fTrackCollection)->Clone(); //deep copy
   fReferenceMultiplicity = anEvent.fReferenceMultiplicity;
   fNumberOfTracks = anEvent.fNumberOfTracks;
-  fNumberOfFlowTagClasses = anEvent.fNumberOfFlowTagClasses;
-  delete [] fNumberOfFlowTags;
-  fNumberOfFlowTags=new Int_t[fNumberOfFlowTagClasses];
-  memcpy(fNumberOfFlowTags,anEvent.fNumberOfFlowTags,fNumberOfFlowTagClasses*sizeof(Int_t));
+  fNumberOfPOItypes = anEvent.fNumberOfPOItypes;
+  delete [] fNumberOfPOIs;
+  fNumberOfPOIs=new Int_t[fNumberOfPOItypes];
+  memcpy(fNumberOfPOIs,anEvent.fNumberOfPOIs,fNumberOfPOItypes*sizeof(Int_t));
   fUseGlauberMCSymmetryPlanes = anEvent.fUseGlauberMCSymmetryPlanes;
   fUseExternalSymmetryPlanes = anEvent.fUseExternalSymmetryPlanes;
   fPsi1 = anEvent.fPsi1;
@@ -221,7 +218,7 @@ AliFlowEventSimple& AliFlowEventSimple::operator=(const AliFlowEventSimple& anEv
   fUserModified=anEvent.fUserModified;
   fNumberOfTracksWrap = anEvent.fNumberOfTracksWrap;
   fNumberOfRPsWrap = anEvent.fNumberOfRPsWrap;
-  fNumberOfFlowTagsWrap = anEvent.fNumberOfFlowTagsWrap;
+  fNumberOfPOIsWrap = anEvent.fNumberOfPOIsWrap;
   fMCReactionPlaneAngleWrap=anEvent.fMCReactionPlaneAngleWrap;
   fShuffleTracks=anEvent.fShuffleTracks;
   delete [] fShuffledIndexes;
@@ -236,11 +233,11 @@ AliFlowEventSimple::~AliFlowEventSimple()
   delete fTrackCollection;
   delete fNumberOfTracksWrap;
   delete fNumberOfRPsWrap;
-  delete fNumberOfFlowTagsWrap;
+  delete fNumberOfPOIsWrap;
   delete fMCReactionPlaneAngleWrap;
   delete fShuffledIndexes;
   delete fMothersCollection;
-  delete [] fNumberOfFlowTags;
+  delete [] fNumberOfPOIs;
 }
 
 //-----------------------------------------------------------------------
@@ -514,7 +511,7 @@ AliFlowVector AliFlowEventSimple::GetQ( Int_t n,
   vQ.Set(dQX,dQY);
   vQ.SetMult(sumOfWeights);
   vQ.SetHarmonic(iOrder);
-  vQ.SetFlowTagType(AliFlowTrackSimple::kRP);
+  vQ.SetPOItype(AliFlowTrackSimple::kRP);
   vQ.SetSubeventNumber(-1);
 
   return vQ;
@@ -656,7 +653,7 @@ void AliFlowEventSimple::Get2Qsub( AliFlowVector* Qarray,
     Qarray[s].Set(dQX,dQY);
     Qarray[s].SetMult(sumOfWeights);
     Qarray[s].SetHarmonic(iOrder);
-    Qarray[s].SetFlowTagType(AliFlowTrackSimple::kRP);
+    Qarray[s].SetPOItype(AliFlowTrackSimple::kRP);
     Qarray[s].SetSubeventNumber(s);
 
     //reset
@@ -675,7 +672,7 @@ void AliFlowEventSimple::Print(Option_t *option) const
   //             ===============================================
   //   printf( "TH1.Print Name  = %s, Entries= %d, Total sum= %g\n",GetName(),Int_t(fEntries),GetSumOfWeights());
   printf( "Class.Print Name = %s, #tracks= %d, Number of RPs= %d, Number of POIs = %d, MC EventPlaneAngle= %f\n",
-          GetName(),fNumberOfTracks, fNumberOfFlowTags[0], fNumberOfFlowTags[1], fMCReactionPlaneAngle );
+          GetName(),fNumberOfTracks, fNumberOfPOIs[0], fNumberOfPOIs[1], fMCReactionPlaneAngle );
 
   TString optionstr(option);
   if (!optionstr.Contains("all")) return;
@@ -704,10 +701,10 @@ void AliFlowEventSimple::Browse(TBrowser *b)
     fNumberOfRPsWrap = new TParameter<int>("fNumberOfRPs", GetNumberOfRPs());
     b->Add(fNumberOfRPsWrap);
   }
-  if (!fNumberOfFlowTagsWrap)
+  if (!fNumberOfPOIsWrap)
   {
-    fNumberOfFlowTagsWrap = new TParameter<int>("fNumberOfFlowTags", GetNumberOfPOIs());
-    b->Add(fNumberOfFlowTagsWrap);
+    fNumberOfPOIsWrap = new TParameter<int>("fNumberOfPOIs", GetNumberOfPOIs());
+    b->Add(fNumberOfPOIsWrap);
   }
   if (!fMCReactionPlaneAngleWrap)
   {
@@ -740,14 +737,14 @@ AliFlowEventSimple::AliFlowEventSimple( TTree* inputTree,
   fUserModified(kFALSE),
   fNumberOfTracksWrap(NULL),
   fNumberOfRPsWrap(NULL),
-  fNumberOfFlowTagsWrap(NULL),
+  fNumberOfPOIsWrap(NULL),
   fMCReactionPlaneAngleWrap(NULL),
   fShuffledIndexes(NULL),
   fShuffleTracks(kFALSE),
   fMothersCollection(new TObjArray()),
   fCentrality(-1.),
-  fNumberOfFlowTagClasses(poiCuts->GetNumberOfPOIclasses()+1),
-  fNumberOfFlowTags(new Int_t[fNumberOfFlowTagClasses])
+  fNumberOfPOItypes(2),
+  fNumberOfPOIs(new Int_t[fNumberOfPOItypes])
 {
   //constructor, fills the event from a TTree of kinematic.root files
   //applies RP and POI cuts, tags the tracks
@@ -766,9 +763,10 @@ AliFlowEventSimple::AliFlowEventSimple( TTree* inputTree,
     if (!pParticle->IsPrimary()) continue;
 
     Bool_t rpOK = (rpCuts->PassesCuts(pParticle)>0);
-    Int_t poiType = poiCuts->PassesCuts(pParticle);
+    Bool_t poiOK = poiCuts->PassesCuts(pParticle);
+    Int_t poiType = poiCuts->GetPOItype();
     
-    if (rpOK || poiType>0)
+    if (rpOK || poiOK)
     {
       AliFlowTrackSimple* pTrack = new AliFlowTrackSimple(pParticle);
 
@@ -776,15 +774,15 @@ AliFlowEventSimple::AliFlowEventSimple( TTree* inputTree,
       if(rpOK)
       {
         pTrack->TagRP(kTRUE);
-        fNumberOfFlowTags[0]++;
-        cout<<"numberOfRPs = "<<fNumberOfFlowTags[0]<<endl;
+        IncrementNumberOfPOIs(0);
+        cout<<"numberOfRPs = "<<fNumberOfPOIs[0]<<endl;
       }
       //marking the particles used for diff. flow:
-      if(poiType>0)
+      if(poiOK)
       {
         pTrack->Tag(poiType);
-        fNumberOfFlowTags[poiType]++;
-        printf("fNumberOfFlowTags[%i] = %i",poiType,fNumberOfFlowTags[poiType]);
+        IncrementNumberOfPOIs(poiType);
+        printf("fNumberOfPOIs[%i] = %i",poiType,fNumberOfPOIs[poiType]);
       }
       //adding a particles which were used either for int. or diff. flow to the list
       AddTrack(pTrack);
@@ -993,11 +991,11 @@ void AliFlowEventSimple::TagRP( const AliFlowTrackSimpleCuts* cuts )
     Bool_t rpTrack=track->InRPSelection();
     if (pass) 
     {
-      if (!rpTrack) fNumberOfFlowTags[0]++; //only increase if not already tagged
+      if (!rpTrack) fNumberOfPOIs[0]++; //only increase if not already tagged
     }
     else
     {
-      if (rpTrack) fNumberOfFlowTags[0]--; //only decrease if detagging
+      if (rpTrack) fNumberOfPOIs[0]--; //only decrease if detagging
     }
     track->SetForRPSelection(pass);
   }
@@ -1015,11 +1013,11 @@ void AliFlowEventSimple::TagPOI( const AliFlowTrackSimpleCuts* cuts, Int_t poiTy
     Bool_t poiTrack=track->InPOISelection();
     if (pass) 
     {
-      if (!poiTrack) fNumberOfFlowTags[poiType]++; //only increase if not already tagged
+      if (!poiTrack) fNumberOfPOIs[poiType]++; //only increase if not already tagged
     }
     else
     {
-      if (poiTrack) fNumberOfFlowTags[poiType]--; //only decrease if detagging
+      if (poiTrack) fNumberOfPOIs[poiType]--; //only decrease if detagging
     }
     track->Tag(poiType,pass);
   }
@@ -1040,12 +1038,12 @@ void AliFlowEventSimple::DefineDeadZone( Double_t etaMin,
     Double_t phi = track->Phi();
     if (eta>etaMin && eta<etaMax && phi>phiMin && phi<phiMax)
     {
-      if (track->InRPSelection()) {fNumberOfFlowTags[0]--;}
-      for (Int_t j=1; j<fNumberOfFlowTagClasses; j++)
+      if (track->InRPSelection()) {fNumberOfPOIs[0]--;}
+      for (Int_t j=1; j<fNumberOfPOItypes; j++)
       {
-        if (track->CheckTag(j)) {fNumberOfFlowTags[j]--;}
+        if (track->CheckTag(j)) {fNumberOfPOIs[j]--;}
       }
-      track->ResetFlowTags();
+      track->ResetPOItype();
     }
   }
 }
@@ -1088,9 +1086,9 @@ void AliFlowEventSimple::ClearFast()
   //clear the counters without deleting allocated objects so they can be reused
   fReferenceMultiplicity = 0;
   fNumberOfTracks = 0;
-  for (Int_t i=0; i<fNumberOfFlowTagClasses; i++)
+  for (Int_t i=0; i<fNumberOfPOItypes; i++)
   {
-    fNumberOfFlowTags[i] = 0;
+    fNumberOfPOIs[i] = 0;
   }
   fMCReactionPlaneAngle = 0.0;
   fMCReactionPlaneAngleIsSet = kFALSE;
index ca1ca16..120a48d 100644 (file)
@@ -50,16 +50,15 @@ class AliFlowEventSimple: public TObject {
   Int_t    NumberOfTracks() const                   { return fNumberOfTracks; }
   Int_t    GetReferenceMultiplicity() const         { return fReferenceMultiplicity; }
   void     SetReferenceMultiplicity( Int_t m )      { fReferenceMultiplicity = m; }
-  Int_t    GetEventNSelTracksRP() const             { return fNumberOfFlowTags[0]; } 
-  void     SetEventNSelTracksRP(Int_t nr)           { fNumberOfFlowTags[0] = nr; }  
-  Int_t    GetEventNSelTracksPOI() const            { return fNumberOfFlowTags[0]; } 
-  void     SetEventNSelTracksPOI(Int_t np)          { fNumberOfFlowTags[0] = np; }  
-  Int_t    GetNumberOfRPs() const                   { return fNumberOfFlowTags[0]; }
-  void     SetNumberOfRPs( Int_t nr )               { fNumberOfFlowTags[0]=nr; }
-  Int_t    GetNumberOfPOIs(Int_t i=1) const         { return (i<fNumberOfFlowTagClasses)?fNumberOfFlowTags[i]:0; }
-  void     SetNumberOfPOIs( Int_t np, Int_t tagClass=1 );
-  void     IncrementNumberOfPOIs(Int_t poiType);
-  void     SetNumberOfFlowTagClasses(Int_t n);
+  Int_t    GetEventNSelTracksRP() const             { return fNumberOfPOIs[0]; } 
+  void     SetEventNSelTracksRP(Int_t nr)           { fNumberOfPOIs[0] = nr; }  
+  Int_t    GetEventNSelTracksPOI() const            { return fNumberOfPOIs[0]; } 
+  void     SetEventNSelTracksPOI(Int_t np)          { fNumberOfPOIs[0] = np; }  
+  Int_t    GetNumberOfRPs() const                   { return fNumberOfPOIs[0]; }
+  void     SetNumberOfRPs( Int_t nr )               { fNumberOfPOIs[0]=nr; }
+  Int_t    GetNumberOfPOIs(Int_t i=1) const         { return (i<fNumberOfPOItypes)?fNumberOfPOIs[i]:0; }
+  void     SetNumberOfPOIs( Int_t nubmerOfPOIs, Int_t poiType=1 );
+  void     IncrementNumberOfPOIs(Int_t poiType=1);
 
   void     SetUseGlauberMCSymmetryPlanes()          { fUseGlauberMCSymmetryPlanes = kTRUE; }
   void     SetUseExternalSymmetryPlanes(TF1 *gPsi1Psi3 = 0x0,
@@ -147,7 +146,7 @@ class AliFlowEventSimple: public TObject {
   Bool_t                  fUserModified;              // did we modify the event in any way (afterburner etc) ?
   TParameter<Int_t>*      fNumberOfTracksWrap;        //! number of tracks in TBrowser
   TParameter<Int_t>*      fNumberOfRPsWrap;           //! number of tracks that have passed the RP selection in TBrowser
-  TParameter<Int_t>*      fNumberOfFlowTagsWrap;          //! number of tracks that have passed the POI selection in TBrowser
+  TParameter<Int_t>*      fNumberOfPOIsWrap;          //! number of tracks that have passed the POI selection in TBrowser
   TParameter<Double_t>*   fMCReactionPlaneAngleWrap;  //! the angle of the reaction plane from the MC truth in TBrowser
   Int_t*                  fShuffledIndexes;           //! placeholder for randomized indexes
   Bool_t                  fShuffleTracks;             // do we shuffle tracks on get?
@@ -155,8 +154,8 @@ class AliFlowEventSimple: public TObject {
   Double_t                fCentrality;                //centrality
  
  private:
-  Int_t                   fNumberOfFlowTagClasses;    // how many different flow particle types do we have? (RP,POI,POI_2,...)
-  Int_t*                  fNumberOfFlowTags;          //[fNumberOfFlowTagClasses] number of tracks that have passed the POI selection
+  Int_t                   fNumberOfPOItypes;    // how many different flow particle types do we have? (RP,POI,POI_2,...)
+  Int_t*                  fNumberOfPOIs;          //[fNumberOfPOItypes] number of tracks that have passed the POI selection
 
   ClassDef(AliFlowEventSimple,1)
 };
index 90c8954..1cb219a 100644 (file)
@@ -40,7 +40,7 @@ AliFlowTrackSimple::AliFlowTrackSimple():
   fTrackWeight(1.),
   fCharge(0),
   fMass(-1),
-  fFlowBits(0),
+  fPOItype(0),
   fSubEventBits(0),
   fID(-1)
 {
@@ -56,7 +56,7 @@ AliFlowTrackSimple::AliFlowTrackSimple(Double_t phi, Double_t eta, Double_t pt,
   fTrackWeight(weight),
   fCharge(charge),
   fMass(mass),
-  fFlowBits(0),
+  fPOItype(0),
   fSubEventBits(0),
   fID(-1)
 {
@@ -72,7 +72,7 @@ AliFlowTrackSimple::AliFlowTrackSimple( TParticle* p ):
   fTrackWeight(1.),
   fCharge(0),
   fMass(-1),
-  fFlowBits(0),
+  fPOItype(0),
   fSubEventBits(0),
   fID(-1)
 {
@@ -104,7 +104,7 @@ AliFlowTrackSimple::AliFlowTrackSimple(const AliFlowTrackSimple& aTrack):
   fTrackWeight(aTrack.fTrackWeight),
   fCharge(aTrack.fCharge),
   fMass(aTrack.fMass),
-  fFlowBits(aTrack.fFlowBits),
+  fPOItype(aTrack.fPOItype),
   fSubEventBits(aTrack.fSubEventBits),
   fID(aTrack.fID)
 {
@@ -129,7 +129,7 @@ AliFlowTrackSimple& AliFlowTrackSimple::operator=(const AliFlowTrackSimple& aTra
   fTrackWeight = aTrack.fTrackWeight;
   fCharge = aTrack.fCharge;
   fMass = aTrack.fMass;
-  fFlowBits = aTrack.fFlowBits;
+  fPOItype = aTrack.fPOItype;
   fSubEventBits = aTrack.fSubEventBits;
   fID = aTrack.fID;
 
@@ -377,7 +377,7 @@ void AliFlowTrackSimple::Clear(Option_t*)
   fTrackWeight=1.0;
   fCharge=0;
   fMass=-1;
-  fFlowBits.ResetAllBits();
+  fPOItype.ResetAllBits();
   fSubEventBits.ResetAllBits();
   fID=-1;
 }
index 17ded74..f1b3921 100644 (file)
@@ -17,7 +17,7 @@ class TParticle;
 class AliFlowTrackSimple: public TObject {
 
 public:
-  enum tagType { kInvalid=-1,
+  enum poiTypes { kInvalid=-1,
                  kRP=0,
                  kPOI=1,
                  kPOI1=2,
@@ -52,12 +52,12 @@ public:
   Bool_t InSubevent(Int_t i) const;
   void TagRP(Bool_t b=kTRUE) {SetForRPSelection(b);} 
   void TagPOI(Bool_t b=kTRUE) {SetForPOISelection(b);} 
-  void Tag(Int_t n, Bool_t b=kTRUE) {fFlowBits.SetBitNumber(n,b);}
-  Bool_t CheckTag(Int_t n) {return fFlowBits.TestBitNumber(n);}
+  void Tag(Int_t n, Bool_t b=kTRUE) {fPOItype.SetBitNumber(n,b);}
+  Bool_t CheckTag(Int_t n) {return fPOItype.TestBitNumber(n);}
   void SetForSubevent(Int_t i); 
-  void ResetFlowTags() {fFlowBits.ResetAllBits();}
+  void ResetPOItype() {fPOItype.ResetAllBits();}
   void ResetSubEventTags() {fSubEventBits.ResetAllBits();}
-  Bool_t IsDead() const {return (fFlowBits.CountBits()==0);}
+  Bool_t IsDead() const {return (fPOItype.CountBits()==0);}
       
   void SetEta(Double_t eta);
   void SetPt(Double_t pt); 
@@ -119,7 +119,8 @@ public:
                 Double_t precision,
                 Int_t maxNumberOfIterations=100 );
 
-  const TBits* GetFlowBits() const {return &fFlowBits;}
+  const TBits* GetPOItype() const {return &fPOItype;}
+  const TBits* GetFlowBits() const {return GetPOItype();}
 
   void  SetID(Int_t i) {fID=i;}
   Int_t GetID() const {return fID;}
@@ -136,9 +137,9 @@ public:
   Double_t fPt;          // pt
   Double_t fPhi;         // phi
   Double_t fTrackWeight; // weight
-  Int_t fCharge;         //charge
+  Int_t    fCharge;      //charge
   Double_t fMass;        // mass
-  TBits    fFlowBits;    // bits to set if track is selected
+  TBits    fPOItype;    // bits to set if track is selected
   TBits    fSubEventBits;// bits to set if track is selected for a subevent
   Int_t    fID;          // Unique track ID, point back to the ESD track
 
@@ -161,11 +162,11 @@ inline Double_t AliFlowTrackSimple::Mass() const {
   return this->fMass; }
 //TBits
 inline Bool_t AliFlowTrackSimple::InRPSelection() const { 
-  return fFlowBits.TestBitNumber(kRP); }
+  return fPOItype.TestBitNumber(kRP); }
 inline Bool_t AliFlowTrackSimple::InPOISelection(Int_t poiType) const { 
-  return fFlowBits.TestBitNumber(poiType); }
+  return fPOItype.TestBitNumber(poiType); }
 inline Bool_t AliFlowTrackSimple::IsPOItype(Int_t poiType) const {
-  return fFlowBits.TestBitNumber(poiType); }
+  return fPOItype.TestBitNumber(poiType); }
 inline Bool_t AliFlowTrackSimple::InSubevent(Int_t i) const { 
   return this->fSubEventBits.TestBitNumber(i); }
 
@@ -185,14 +186,14 @@ inline void AliFlowTrackSimple::SetMass(Double_t val) {
 
   //TBits
 inline void AliFlowTrackSimple::SetForRPSelection(Bool_t val) {
-  fFlowBits.SetBitNumber(kRP,val); }
+  fPOItype.SetBitNumber(kRP,val); }
 inline void AliFlowTrackSimple::SetForPOISelection(Bool_t val) {
-  fFlowBits.SetBitNumber(kPOI,val); }
+  fPOItype.SetBitNumber(kPOI,val); }
 inline void AliFlowTrackSimple::SetForSubevent(Int_t i) {
   fSubEventBits.SetBitNumber(i,kTRUE); }
 
 inline void AliFlowTrackSimple::SetPOItype(Int_t poiType, Bool_t b) {
-  fFlowBits.SetBitNumber(poiType,b); }
+  fPOItype.SetBitNumber(poiType,b); }
 
 #endif
 
index feb5f52..017943f 100644 (file)
@@ -51,7 +51,7 @@ AliFlowTrackSimpleCuts::AliFlowTrackSimpleCuts(const char* name):
   fCutMass(kFALSE),
   fMassMax(FLT_MAX),
   fMassMin(-FLT_MAX),
-  fNumberOfPOIclasses(1)
+  fPOItype(1)
 {
   //constructor 
 }
@@ -109,7 +109,7 @@ Bool_t AliFlowTrackSimpleCuts::IsSelected(TObject* obj, Int_t)
 }
 
 //----------------------------------------------------------------------- 
-Int_t AliFlowTrackSimpleCuts::PassesCuts(const AliFlowTrackSimple *track) const
+Bool_t AliFlowTrackSimpleCuts::PassesCuts(const AliFlowTrackSimple *track) const
 {
   //simple method to check if the simple track passes the simple cuts
   if(fCutPt) {if (track->Pt() < fPtMin || track->Pt() >= fPtMax ) return 0;}
@@ -122,7 +122,7 @@ Int_t AliFlowTrackSimpleCuts::PassesCuts(const AliFlowTrackSimple *track) const
 }
 
 //----------------------------------------------------------------------- 
-Int_t AliFlowTrackSimpleCuts::PassesCuts(TParticle* track) const
+Bool_t AliFlowTrackSimpleCuts::PassesCuts(TParticle* track) const
 {
   //simple method to check if the simple track passes the simple cuts
   if(fCutPt)  {if (track->Pt() < fPtMin || track->Pt() >= fPtMax ) return 0;}
index c12a53c..3986b86 100644 (file)
@@ -49,10 +49,11 @@ class AliFlowTrackSimpleCuts : public TNamed {
   Double_t GetMassMin() const   {return this->fMassMin; }
   
   //simple method to check if the simple track passes the simple cuts:
-  Int_t PassesCuts(const AliFlowTrackSimple *track) const;
-  Int_t PassesCuts(TParticle* p) const;
+  Bool_t PassesCuts(const AliFlowTrackSimple *track) const;
+  Bool_t PassesCuts(TParticle* p) const;
 
-  Int_t GetNumberOfPOIclasses() const {return fNumberOfPOIclasses;}
+  Int_t GetPOItype() const {return fPOItype;}
+  void SetPOItype(Int_t t) {fPOItype=t;}
 
   virtual Bool_t IsSelected(TObject* obj, Int_t id=-1);
 
@@ -73,7 +74,7 @@ class AliFlowTrackSimpleCuts : public TNamed {
   Bool_t   fCutMass; // cut on mass?
   Double_t fMassMax; //max mass
   Double_t fMassMin; //min mass
-  Int_t    fNumberOfPOIclasses; //how many different POI classes do we recognize?
+  Int_t    fPOItype; //how many different POI classes do we recognize?
 
   ClassDef(AliFlowTrackSimpleCuts,2)
 };
index 06b23a3..c6f3520 100644 (file)
@@ -46,8 +46,8 @@ class AliFlowVector: public TVector2 {
   Double_t GetMult() const {return fMult;};                    // Get sum of weights
   void SetHarmonic(Int_t h) {fHarmonic = h;}             //set the harmonic
   Int_t GetHarmonic() const {return fHarmonic;}          //get the harmonic
-  void SetFlowTagType(Int_t t) {fPOItype=t;}
-  Int_t GetFlowTagType() const {return fPOItype;}
+  void SetPOItype(Int_t t) {fPOItype=t;}
+  Int_t GetPOItype() const {return fPOItype;}
   void SetSubeventNumber(Int_t n) {fSubeventNumber=n;}
   Int_t GetSubeventNumber() const {return fSubeventNumber;}
   void Clear(Option_t* option="");
index c0e4a66..8f0780e 100644 (file)
@@ -261,11 +261,8 @@ AliFlowEventCuts& AliFlowEventCuts::operator=(const AliFlowEventCuts& that)
   fCutSPDvertexerAnomaly=that.fCutSPDvertexerAnomaly;
   fCutSPDTRKVtxZ=that.fCutSPDTRKVtxZ;
   fCutTPCmultiplicityOutliers=that.fCutTPCmultiplicityOutliers;
-  fCutCentralityPercentile=that.fCutCentralityPercentile;
   fUseCentralityUnchecked=that.fUseCentralityUnchecked;
   fCentralityPercentileMethod=that.fCentralityPercentileMethod;
-  fCentralityPercentileMax=that.fCentralityPercentileMax;
-  fCentralityPercentileMin=that.fCentralityPercentileMin;
   fCutZDCtiming=that.fCutZDCtiming;
   fhistTPCvsGlobalMult=that.fhistTPCvsGlobalMult;
   fData2011=that.fData2011;
index 82d7c42..72e2ed1 100644 (file)
@@ -83,9 +83,6 @@ class AliFlowEventCuts : public AliFlowEventSimpleCuts {
   //Int_t GetRefMult() {return fRefMult;}
   Int_t GetReferenceMultiplicity(AliVEvent* event, AliMCEvent *mcEvent) {return RefMult(event,mcEvent);}
   const char* CentrMethName(refMultMethod method) const;
-  void SetCentralityPercentileRange(Float_t min, Float_t max){ fCentralityPercentileMin=min;
-                                                               fCentralityPercentileMax=max;
-                                                               fCutCentralityPercentile=kTRUE; }
   void SetCentralityPercentileMethod( refMultMethod m) {fCentralityPercentileMethod=m;}
   void SetUseCentralityUnchecked(Bool_t b=kTRUE) {fUseCentralityUnchecked=b;}
 
@@ -130,11 +127,8 @@ class AliFlowEventCuts : public AliFlowEventSimpleCuts {
   Bool_t fCutSPDvertexerAnomaly; //cut on the spd vertexer anomaly
   Bool_t fCutSPDTRKVtxZ; //require compatibility between SPDvertexz TRKvertexz
   Bool_t fCutTPCmultiplicityOutliers; //cut TPC multiplicity outliers
-  Bool_t fCutCentralityPercentile; //cut on centrality perc. from AliESDCentrality
   Bool_t fUseCentralityUnchecked; //use the unchecked method
   refMultMethod fCentralityPercentileMethod; //where to get the percentile from
-  Float_t fCentralityPercentileMax; // max centr. perc
-  Float_t fCentralityPercentileMin; // min centr. perc
   Bool_t fCutZDCtiming;   //cut on ZDC timing
   AliTriggerAnalysis fTrigAna; //trigger analysis object
   Bool_t fCutImpactParameter; //cut on impact parameter (MC header)
index c3d8d02..c118a0a 100644 (file)
@@ -228,9 +228,6 @@ class AliFlowTrackCuts : public AliFlowTrackSimpleCuts {
   Double_t GetPmdEta(Float_t xPos, Float_t yPos, Float_t zPos);
   Double_t GetPmdPhi(Float_t xPos, Float_t yPos);  
 
-  Int_t GetPOItype() const {return fPOItype;}
-  void SetPOItype(Int_t t) {fPOItype=t;}
-
   //PID
   void SetPID(AliPID::EParticleType pid, PIDsource s=kTOFpid, Double_t prob=0.9)
              {fParticleID=pid; fPIDsource=s; fParticleProbability=prob; fCutPID=kTRUE; InitPIDcuts();}
@@ -365,8 +362,6 @@ class AliFlowTrackCuts : public AliFlowTrackSimpleCuts {
   Bool_t  fCutPmdNcell; //cut on cluster ncell
   Float_t fPmdNcell;    //value of cluster ncell
 
-  Int_t fPOItype;          //what kind of POI do we have? (1,2,3,...) for RP re still return 1 or so
-
   Double_t fMinKinkAngle; //max kink angle
   Double_t fMinKinkRadius; //min kink radius
   Double_t fMaxKinkRadius; //max kink radius