added mc info for strong parity violation calculation
authorsnelling <snelling@f7af4fe6-9843-0410-8265-dc069ae4e863>
Tue, 3 Aug 2010 20:15:34 +0000 (20:15 +0000)
committersnelling <snelling@f7af4fe6-9843-0410-8265-dc069ae4e863>
Tue, 3 Aug 2010 20:15:34 +0000 (20:15 +0000)
PWG2/FLOW/AliFlowCommon/AliFlowAnalysisWithMCEventPlane.cxx
PWG2/FLOW/AliFlowCommon/AliFlowAnalysisWithMCEventPlane.h
PWG2/FLOW/AliFlowTasks/AliAnalysisTaskMCEventPlane.cxx
PWG2/FLOW/AliFlowTasks/AliAnalysisTaskMCEventPlane.h
PWG2/FLOW/macros/AddTaskFlow.C

index c9cd270..c1cff56 100644 (file)
@@ -61,9 +61,14 @@ ClassImp(AliFlowAnalysisWithMCEventPlane)
    fHistProDiffFlowEtaPOI(NULL),
    fHistSpreadOfFlow(NULL),
    fHarmonic(2),
-   fResonanceList(NULL),
-   fFlowOfResonances(kFALSE),
-   fResonanceSettings(NULL),
+   fMixedHarmonicsList(NULL),
+   fEvaluateMixedHarmonics(kTRUE),
+   fMixedHarmonicsSettings(NULL),
+   fnBinsMult(10000),
+   fMinMult(0.),  
+   fMaxMult(10000.),   
+   fNinCorrelator(2),
+   fMinCorrelator(2),
    fXinPairAngle(0.5)
 {
 
@@ -72,25 +77,19 @@ ClassImp(AliFlowAnalysisWithMCEventPlane)
 
   fQsum = new TVector2;        // flow vector sum
   
-  fResonanceList = new TList();
-  // Initialize arrays needed for the flow of resonances:
-  for(Int_t cs=0;cs<2;cs++) // cos/sin
-  {
-   fPairCorrelator[cs] = NULL;
-  }
-  
-}
+  fMixedHarmonicsList = new TList();
+  this->InitalizeArraysForMixedHarmonics();  
 
+}
  
- //-----------------------------------------------------------------------
-
+//-----------------------------------------------------------------------
 
- AliFlowAnalysisWithMCEventPlane::~AliFlowAnalysisWithMCEventPlane() 
- {
-   //destructor
-   delete fHistList;
-   delete fQsum;
- }
+AliFlowAnalysisWithMCEventPlane::~AliFlowAnalysisWithMCEventPlane() 
+{
+ //destructor
+  delete fHistList;
+  delete fQsum; 
+}
  
 //-----------------------------------------------------------------------
 
@@ -205,7 +204,7 @@ void AliFlowAnalysisWithMCEventPlane::Init() {
  
   fEventNumber = 0;  //set number of events to zero
   
-  if(fFlowOfResonances) this->BookObjectsForFlowOfResonances();
+  if(fEvaluateMixedHarmonics) this->BookObjectsForMixedHarmonics();
         
   TH1::AddDirectory(oldHistAddStatus);
 } 
@@ -289,7 +288,7 @@ void AliFlowAnalysisWithMCEventPlane::Make(AliFlowEventSimple* anEvent) {
     fHistSpreadOfFlow->Fill(flowEBE->GetBinContent(1),flowEBE->GetBinEntries(1));
     delete flowEBE; 
   
-    if(fFlowOfResonances) FlowOfResonances(anEvent);
+    if(fEvaluateMixedHarmonics) EvaluateMixedHarmonics(anEvent);
   }    
 }
   //--------------------------------------------------------------------    
@@ -341,11 +340,35 @@ void AliFlowAnalysisWithMCEventPlane::GetOutputHistograms(TList *outputListHisto
       cout<<"WARNING: Histograms needed to run Finish() are not accessible!"<<endl;  }
     
     //fListHistos->Print();
+  
+   TList *pMixedHarmonicsList = dynamic_cast<TList*> 
+     (outputListHistos->FindObject("Mixed Harmonics"));
+   if(pMixedHarmonicsList) {this->GetOutputHistoramsForMixedHarmonics(pMixedHarmonicsList);} 
+  
   } else { cout << "histogram list pointer is empty" << endl;}
 
 }
 
-  //--------------------------------------------------------------------    
+//--------------------------------------------------------------------    
+
+void AliFlowAnalysisWithMCEventPlane::GetOutputHistoramsForMixedHarmonics(TList *mixedHarmonicsList)
+{
+ // Get pointers to all objects relevant for mixed harmonics study.
+ if(mixedHarmonicsList)
+ {
+  // ...
+ } else
+   {
+    cout<<endl;
+    cout<<"WARNING (MCEP): mixedHarmonicsList in NULL in MCEP::GetOutputHistoramsForMixedHarmonics() !!!! "<<endl;
+    cout<<endl;
+   } 
+  
+} // end of void AliFlowAnalysisWithMCEventPlane::GetOutputHistoramsForMixedHarmonics(TList *mixedHarmonicsList)
+
+//--------------------------------------------------------------------    
+
 void AliFlowAnalysisWithMCEventPlane::Finish() {
    
   //*************make histograms etc. 
@@ -463,72 +486,136 @@ void AliFlowAnalysisWithMCEventPlane::Finish() {
   //cout<<".....finished"<<endl;
 }
 
-void AliFlowAnalysisWithMCEventPlane::BookObjectsForFlowOfResonances()
+//-----------------------------------------------------------------------
+
+void AliFlowAnalysisWithMCEventPlane::InitalizeArraysForMixedHarmonics()
 {
- // Book all objecsts needed to study flow of resonances.
+ // Iinitialize all arrays for mixed harmonics.
+
+ for(Int_t cs=0;cs<2;cs++) // cos/sin
+ {
+  fPairCorrelator[cs] = NULL;
+  fPairCorrelatorVsM[cs] = NULL;
+  for(Int_t sd=0;sd<2;sd++) // pt sum/difference
+  {
+   fPairCorrelatorVsPtSumDiff[cs][sd] = NULL;
+  }
+ }
+
+} // end of void InitalizeArraysForMixedHarmonics()
+
+//-----------------------------------------------------------------------
+
+void AliFlowAnalysisWithMCEventPlane::BookObjectsForMixedHarmonics()
+{
+ // Book all objects needed for mixed harmonics.
  
- // List:
- fResonanceList->SetName("Resonances");
- fResonanceList->SetOwner(kTRUE);   
- fHistList->Add(fResonanceList); 
+ // List holding all objects relevant for mixed harmonics:
+ fMixedHarmonicsList->SetName("Mixed Harmonics");
+ fMixedHarmonicsList->SetOwner(kTRUE);   
+ fHistList->Add(fMixedHarmonicsList); 
  
- // Profile holding settings for flow of resoances:
- TString resonanceSettingsName = "fResonanceSettings";
- fResonanceSettings = new TProfile(resonanceSettingsName.Data(),"Settings for flow of resonances",2,0,2);
- //fResonanceSettings->GetXaxis()->SetLabelSize(0.025);
- fResonanceSettings->GetXaxis()->SetBinLabel(1,"fFlowOfResonances");
- fResonanceSettings->Fill(0.5,(Int_t)fFlowOfResonances);
- fResonanceSettings->GetXaxis()->SetBinLabel(2,"x in #phi_{pair}"); // phi_{pair} = x*phi1+(1-x)*phi2
- fResonanceSettings->Fill(1.5,fXinPairAngle); 
- fResonanceList->Add(fResonanceSettings);
+ // Profile holding settings relevant for mixed harmonics:
+ TString mixedHarmonicsSettingsName = "fMixedHarmonicsSettings";
+ fMixedHarmonicsSettings = new TProfile(mixedHarmonicsSettingsName.Data(),"Settings for Mixed Harmonics",4,0,4);
+ //fMixedHarmonicsSettings->GetXaxis()->SetLabelSize(0.025);
+ fMixedHarmonicsSettings->GetXaxis()->SetBinLabel(1,"fEvaluateMixedHarmonics");
+ fMixedHarmonicsSettings->Fill(0.5,(Int_t)fEvaluateMixedHarmonics); 
+ fMixedHarmonicsSettings->GetXaxis()->SetBinLabel(2,"fNinCorrelator");
+ fMixedHarmonicsSettings->Fill(1.5,(Int_t)fNinCorrelator);
+ fMixedHarmonicsSettings->GetXaxis()->SetBinLabel(3,"fMinCorrelator");
+ fMixedHarmonicsSettings->Fill(2.5,(Int_t)fMinCorrelator);
+ fMixedHarmonicsSettings->GetXaxis()->SetBinLabel(4,"x in #phi_{pair}"); // phi_{pair} = x*phi1+(1-x)*phi2
+ fMixedHarmonicsSettings->Fill(3.5,fXinPairAngle); 
+ fMixedHarmonicsList->Add(fMixedHarmonicsSettings);
  
- // Profiles used to calculate <cos[n(phi_{pair}-RP)]> and <sin[n(phi_{pair}-RP)]> (0 = cos, 1 = sin), where phi_{pair} = x*phi1+(1-x)*phi2:
+ // Profiles used to calculate <cos[m*phi_{pair}-n*RP]> and <sin[m*phi_{pair}-n*RP]>, where phi_{pair} = x*phi1+(1-x)*phi2:
  TString cosSinFlag[2] = {"Cos","Sin"};
- TString cosSinTitleFlag[2] = {"cos[n(#phi_{pair}-#psi_{RP})]","sin[n(#phi_{pair}-#psi_{RP})]"};
+ TString cosSinTitleFlag[2] = {"cos[m#phi_{pair}-n#psi_{RP}]","sin[m#phi_{pair}-n#psi_{RP}]"};
+ if(fNinCorrelator == 2 && fMinCorrelator == 2 && TMath::Abs(fXinPairAngle-0.5)<1.e-44) // default values
+ {
+  cosSinTitleFlag[0] = "cos[#phi_{1}+#phi_{2}-2#psi_{RP})]";
+  cosSinTitleFlag[1] = "sin[#phi_{1}+#phi_{2}-2#psi_{RP})]";   
+ }
+ TString psdFlag[2] = {"Sum","Diff"};
+ TString psdTitleFlag[2] = {"(p_{t,1}+p_{t,2})/2","#left|p_{t,1}-p_{t,2}#right|"}; 
  TString pairCorrelatorName = "fPairCorrelator";
+ TString pairCorrelatorVsMName = "fPairCorrelatorVsM";
+ TString pairCorrelatorVsPtSumDiffName = "fPairCorrelatorVsPt";
+ Int_t iNbinsPt = AliFlowCommonConstants::GetMaster()->GetNbinsPt();
+ Double_t dPtMin = AliFlowCommonConstants::GetMaster()->GetPtMin();         
+ Double_t dPtMax = AliFlowCommonConstants::GetMaster()->GetPtMax(); 
  for(Int_t cs=0;cs<2;cs++)
  { 
-  fPairCorrelator[cs] = new TProfile(Form("%s%s",pairCorrelatorName.Data(),cosSinFlag[cs].Data()),cosSinTitleFlag[cs].Data(),1,0.,1.);
+  fPairCorrelator[cs] = new TProfile(Form("%s, %s",pairCorrelatorName.Data(),cosSinFlag[cs].Data()),cosSinTitleFlag[cs].Data(),1,0.,1.);
   fPairCorrelator[cs]->GetXaxis()->SetBinLabel(1,cosSinTitleFlag[cs].Data());
-  fResonanceList->Add(fPairCorrelator[cs]); 
- } 
+  fMixedHarmonicsList->Add(fPairCorrelator[cs]); 
+  
+  fPairCorrelatorVsM[cs] = new TProfile(Form("%s, %s",pairCorrelatorVsMName.Data(),cosSinFlag[cs].Data()),cosSinTitleFlag[cs].Data(),fnBinsMult,fMinMult,fMaxMult);
+  fPairCorrelatorVsM[cs]->GetXaxis()->SetTitle("# of RPs");
+  fMixedHarmonicsList->Add(fPairCorrelatorVsM[cs]); 
+  
+  for(Int_t sd=0;sd<2;sd++)
+  {
+   fPairCorrelatorVsPtSumDiff[cs][sd] = new TProfile(Form("%s%s, %s",pairCorrelatorVsPtSumDiffName.Data(),psdFlag[sd].Data(),cosSinFlag[cs].Data()),cosSinTitleFlag[cs].Data(),iNbinsPt,dPtMin,dPtMax);
+   fPairCorrelatorVsPtSumDiff[cs][sd]->GetXaxis()->SetTitle(psdTitleFlag[sd].Data());
+   fMixedHarmonicsList->Add(fPairCorrelatorVsPtSumDiff[cs][sd]); 
+  } // end of for(Int_t sd=0;sd<2;sd++)
+ } // end of for(Int_t cs=0;cs<2;cs++)
 
-} // end of void AliFlowAnalysisWithMCEventPlane::BookObjectsForFlowOfResonances()
+} // end of void AliFlowAnalysisWithMCEventPlane::BookObjectsForMixedHarmonics()
 
-void AliFlowAnalysisWithMCEventPlane::FlowOfResonances(AliFlowEventSimple* anEvent)
+//-----------------------------------------------------------------------
+
+void AliFlowAnalysisWithMCEventPlane::EvaluateMixedHarmonics(AliFlowEventSimple* anEvent)
 {
- // Evaluate correlators relevant for the flow of resonances.
+ // Evaluate correlators relevant for the mixed harmonics.
  
  // Get the MC reaction plane angle:
- Double_t RP = anEvent->GetMCReactionPlaneAngle();  
+ Double_t dReactionPlane = anEvent->GetMCReactionPlaneAngle();  
  // Get the number of tracks:
  Int_t iNumberOfTracks = anEvent->NumberOfTracks(); 
+ Int_t nRP = anEvent->GetEventNSelTracksRP(); // number of Reference Particles
  AliFlowTrackSimple *pTrack = NULL;
  Double_t dPhi1 = 0.;
  Double_t dPhi2 = 0.;
+ Double_t dPt1 = 0.;
+ Double_t dPt2 = 0.;
+ Double_t n = fNinCorrelator; // shortcut
+ Double_t m = fMinCorrelator; // shortcut
  Double_t x = fXinPairAngle; // shortcut
- Double_t n = fHarmonic; // shortcut
  for(Int_t i=0;i<iNumberOfTracks;i++) 
  {
   pTrack = anEvent->GetTrack(i); 
   if(pTrack && pTrack->InRPSelection())
   {
    dPhi1 = pTrack->Phi();
+   dPt1 = pTrack->Pt();
   }
   for(Int_t j=0;j<iNumberOfTracks;j++) 
   {
    if(j==i) continue;
    pTrack = anEvent->GetTrack(j); 
-   if(pTrack && pTrack->InRPSelection())
+   if(pTrack && pTrack->InPOISelection())
    {
     dPhi2 = pTrack->Phi();
+    dPt2 = pTrack->Pt();
    }  
    Double_t dPhiPair = x*dPhi1+(1.-x)*dPhi2;
-   fPairCorrelator[0]->Fill(0.5,TMath::Cos(n*(dPhiPair-RP)),1.); 
-   fPairCorrelator[1]->Fill(0.5,TMath::Sin(n*(dPhiPair-RP)),1.); 
+   Double_t dPtSum = 0.5*(dPt1+dPt2);
+   Double_t dPtDiff = TMath::Abs(dPt1-dPt2);
+   fPairCorrelator[0]->Fill(0.5,TMath::Cos(m*dPhiPair-n*dReactionPlane),1.); 
+   fPairCorrelator[1]->Fill(0.5,TMath::Sin(m*dPhiPair-n*dReactionPlane),1.); 
+   fPairCorrelatorVsM[0]->Fill(nRP+0.5,TMath::Cos(m*dPhiPair-n*dReactionPlane),1.);
+   fPairCorrelatorVsM[1]->Fill(nRP+0.5,TMath::Sin(m*dPhiPair-n*dReactionPlane),1.);
+   fPairCorrelatorVsPtSumDiff[0][0]->Fill(dPtSum,TMath::Cos(m*dPhiPair-n*dReactionPlane),1.);
+   fPairCorrelatorVsPtSumDiff[1][0]->Fill(dPtSum,TMath::Sin(m*dPhiPair-n*dReactionPlane),1.);
+   fPairCorrelatorVsPtSumDiff[0][1]->Fill(dPtDiff,TMath::Cos(m*dPhiPair-n*dReactionPlane),1.);
+   fPairCorrelatorVsPtSumDiff[1][1]->Fill(dPtDiff,TMath::Sin(m*dPhiPair-n*dReactionPlane),1.);
   } // end of for(Int_t j=i+1;j<iNumberOfTracks;j++) 
  } // end of for(Int_t i=0;i<iNumberOfTracks;i++) 
  
-} // end of void AliFlowAnalysisWithMCEventPlane::FlowOfResonances()
+} // end of void AliFlowAnalysisWithMCEventPlane::EvaluateMixedHarmonics()
+
 
 
index d0271df..9324a44 100644 (file)
@@ -100,19 +100,35 @@ class AliFlowAnalysisWithMCEventPlane {
    void SetHarmonic(Int_t const harmonic) {this->fHarmonic = harmonic;};
    Int_t GetHarmonic() const {return this->fHarmonic;};
    
-   // flow of resonances:
+   // mixed harmonics:
    // a) methods:
-   virtual void BookObjectsForFlowOfResonances();
-   virtual void FlowOfResonances(AliFlowEventSimple* anEvent);
+   virtual void InitalizeArraysForMixedHarmonics();
+   virtual void BookObjectsForMixedHarmonics();
+   virtual void EvaluateMixedHarmonics(AliFlowEventSimple* anEvent);
+   virtual void GetOutputHistoramsForMixedHarmonics(TList *mixedHarmonicsList);
    // b) setters and getters:
-   void SetResonanceList(TList* const rl) {this->fResonanceList = rl;}
-   TList* GetResonanceList() const {return this->fResonanceList;}    
-   void SetFlowOfResonances(Bool_t const ffor) {this->fFlowOfResonances = ffor;};
-   Bool_t GetFlowOfResonances() const {return this->fFlowOfResonances;};   
-   void SetResonanceSettings(TProfile* const rs) {this->fResonanceSettings = rs;};
-   TProfile* GetResonanceSettings() const {return this->fResonanceSettings;};
+   void SetMixedHarmonicsList(TList* const mhl) {this->fMixedHarmonicsList = mhl;}
+   TList* GetMixedHarmonicsList() const {return this->fMixedHarmonicsList;}    
+   void SetEvaluateMixedHarmonics(Bool_t const emh) {this->fEvaluateMixedHarmonics = emh;};
+   Bool_t GetEvalauteMixedHarmonics() const {return this->fEvaluateMixedHarmonics;};   
+   void SetMixedHarmonicsSettings(TProfile* const mhs) {this->fMixedHarmonicsSettings = mhs;};
+   TProfile* GetMixedHarmonicsSettings() const {return this->fMixedHarmonicsSettings;};  
    void SetPairCorrelator(TProfile* const spc, Int_t const cs) {this->fPairCorrelator[cs] = spc;};
-   TProfile* GetPairCorrelator(Int_t cs) const {return this->fPairCorrelator[cs];};
+   TProfile* GetPairCorrelator(Int_t const cs) const {return this->fPairCorrelator[cs];};
+   void SetPairCorrelatorVsM(TProfile* const spcVsM, Int_t const cs) {this->fPairCorrelatorVsM[cs] = spcVsM;};
+   TProfile* GetPairCorrelatorVsM(Int_t const cs) const {return this->fPairCorrelatorVsM[cs];};   
+   void SetnBinsMult(Int_t const nbm) {this->fnBinsMult = nbm;};
+   Int_t GetnBinsMult() const {return this->fnBinsMult;};  
+   void SetMinMult(Double_t const minm) {this->fMinMult = minm;};
+   Double_t GetMinMult() const {return this->fMinMult;};
+   void SetMaxMult(Double_t const maxm) {this->fMaxMult = maxm;};
+   Double_t GetMaxMult() const {return this->fMaxMult;};   
+   void SetPairCorrelatorVsPtSumDiff(TProfile* const spcVspsd, Int_t const cs, Int_t const sd) {this->fPairCorrelatorVsPtSumDiff[cs][sd] = spcVspsd;};
+   TProfile* GetPairCorrelatorVsPtSumDiff(Int_t const cs, Int_t const sd) const {return this->fPairCorrelatorVsPtSumDiff[cs][sd];};
+   void SetNinCorrelator(Int_t const n) {this->fNinCorrelator = n;};
+   Int_t GetNinCorrelator() const {return this->fNinCorrelator;};     
+   void SetMinCorrelator(Int_t const m) {this->fMinCorrelator = m;};
+   Int_t GetMinCorrelator() const {return this->fMinCorrelator;};     
    void SetXinPairAngle(Double_t const xipa) {this->fXinPairAngle = xipa;};
    Double_t GetXinPairAngle() const {return this->fXinPairAngle;};   
   
@@ -146,15 +162,23 @@ class AliFlowAnalysisWithMCEventPlane {
    TH1D*        fHistSpreadOfFlow;        // histogram filled with reference flow calculated e-b-e    
    Int_t        fHarmonic;                // harmonic 
    
-   // objects needed for a study of flow of resonances (and in addition for strong parity violation):
-   TList *fResonanceList; // list to hold all objects relevant for a study of flow of resonances 
-   Bool_t fFlowOfResonances; // evaluate and store objects relevant for study of flow of resonances
-   TProfile *fResonanceSettings; // profile used to hold all flags relevant for the flow of resonances
-   TProfile *fPairCorrelator[2]; // profiles used to calculate <cos[n(phi_{pair}-RP)]> and <sin[n(phi_{pair}-RP)]> (0 = cos, 1 = sin), where phi_{pair} = x*phi1+(1-x)*phi2
+   // mixed harmonics:
+   TList *fMixedHarmonicsList; // list to hold all objects relevant for mixed harmonics 
+   Bool_t fEvaluateMixedHarmonics; // evaluate and store objects relevant for mixed harmonics
+   TProfile *fMixedHarmonicsSettings; // profile used to hold all flags relevant for the mixed harmonics
+   TProfile *fPairCorrelator[2]; // profiles used to calculate <cos[m*phi_{pair}-n*RP]> and <sin[m*phi_{pair}-n*RP]> (0 = cos, 1 = sin), where phi_{pair} = x*phi1+(1-x)*phi2
+   TProfile *fPairCorrelatorVsM[2]; // <cos[m*phi_{pair}-n*RP]> and <sin[m*phi_{pair}-n*RP]> versus multiplicity (0 = cos, 1 = sin), where phi_{pair} = x*phi1+(1-x)*phi2
+   Int_t fnBinsMult; // number of multiplicity bins for mixed harmonics analysis versus multiplicity  
+   Double_t fMinMult; // minimal multiplicity for mixed harmonics analysis versus multiplicity  
+   Double_t fMaxMult; // maximal multiplicity for mixed harmonics analysis versus multiplicity    
+   TProfile *fPairCorrelatorVsPtSumDiff[2][2]; // <cos/sin[m*phi_{pair}-n*RP]> vs (1/2)(pt1+pt2) (0) and |pt1-pt2| (1), where phi_{pair} = x*phi1+(1-x)*phi2
+   Int_t fNinCorrelator; // n in <cos[m*phi_{pair}-n*RP]> and <sin[m*phi_{pair}-n*RP]>, where phi_{pair} = x*phi1+(1-x)*phi2
+   Int_t fMinCorrelator; // m in <cos[m*phi_{pair}-n*RP]> and <sin[m*phi_{pair}-n*RP]>, where phi_{pair} = x*phi1+(1-x)*phi2   
    Double_t fXinPairAngle; // x in definition phi_{pair} = x*phi1+(1-x)*phi2
                                        
    ClassDef(AliFlowAnalysisWithMCEventPlane,0)  // Analyse particle distribution versus MC reaction plane
-     };
+  
+  };
 
      
 #endif
index fab5e48..39533c3 100644 (file)
@@ -42,7 +42,14 @@ AliAnalysisTaskMCEventPlane::AliAnalysisTaskMCEventPlane(const char *name) :
   AliAnalysisTaskSE(name), 
   fEvent(NULL),
   fMc(NULL),
-  fListHistos(NULL)
+  fListHistos(NULL),
+  fEvaluateMixedHarmonics(kTRUE),
+  fnBinsMult(10000),
+  fMinMult(0.),  
+  fMaxMult(10000.),    
+  fNinCorrelator(2),
+  fMinCorrelator(2),
+  fXinPairAngle(0.5) 
 {
   // Constructor
   cout<<"AliAnalysisTaskMCEventPlane::AliAnalysisTaskMCEventPlane(const char *name)"<<endl;
@@ -59,7 +66,14 @@ AliAnalysisTaskMCEventPlane::AliAnalysisTaskMCEventPlane() :
   AliAnalysisTaskSE(),
   fEvent(NULL),
   fMc(NULL),
-  fListHistos(NULL)
+  fListHistos(NULL),
+  fEvaluateMixedHarmonics(kFALSE),
+  fnBinsMult(0),
+  fMinMult(0.0),  
+  fMaxMult(0.0),     
+  fNinCorrelator(0),
+  fMinCorrelator(0),
+  fXinPairAngle(0.0) 
 {
   // Constructor
   cout<<"AliAnalysisTaskMCEventPlane::AliAnalysisTaskMCEventPlane()"<<endl;
@@ -82,7 +96,17 @@ void AliAnalysisTaskMCEventPlane::UserCreateOutputObjects()
 
   //Analyser
   fMc  = new AliFlowAnalysisWithMCEventPlane() ;
-      
+  
+  // Setters for mixed harmonics study:
+  fMc->SetEvaluateMixedHarmonics(fEvaluateMixedHarmonics);
+  fMc->SetNinCorrelator(fNinCorrelator);
+  fMc->SetMinCorrelator(fMinCorrelator);
+  fMc->SetXinPairAngle(fXinPairAngle);
+  fMc->SetnBinsMult(fnBinsMult);
+  fMc->SetMinMult(fMinMult);
+  fMc->SetMaxMult(fMaxMult);
+  
+  // Initialized:    
   fMc-> Init();
 
   if (fMc->GetHistList()) {
index ae3d19e..89e2a77 100644 (file)
@@ -28,6 +28,22 @@ class AliAnalysisTaskMCEventPlane : public AliAnalysisTaskSE {
   virtual void   UserCreateOutputObjects();
   virtual void   UserExec(Option_t *option);
   virtual void   Terminate(Option_t *);
+  
+  // Objects needed for mixed harmonics study:
+  void SetEvaluateMixedHarmonics(Bool_t const emh) {this->fEvaluateMixedHarmonics = emh;};
+  Bool_t GetEvalauteMixedHarmonics() const {return this->fEvaluateMixedHarmonics;};
+  void SetNinCorrelator(Int_t const n) {this->fNinCorrelator = n;};
+  Int_t GetNinCorrelator() const {return this->fNinCorrelator;};     
+  void SetMinCorrelator(Int_t const m) {this->fMinCorrelator = m;};
+  Int_t GetMinCorrelator() const {return this->fMinCorrelator;};     
+  void SetXinPairAngle(Double_t const xipa) {this->fXinPairAngle = xipa;};
+  Double_t GetXinPairAngle() const {return this->fXinPairAngle;};       
+  void SetnBinsMult(Int_t const nbm) {this->fnBinsMult = nbm;};
+  Int_t GetnBinsMult() const {return this->fnBinsMult;};  
+  void SetMinMult(Double_t const minm) {this->fMinMult = minm;};
+  Double_t GetMinMult() const {return this->fMinMult;};
+  void SetMaxMult(Double_t const maxm) {this->fMaxMult = maxm;};
+  Double_t GetMaxMult() const {return this->fMaxMult;};     
 
  private:
  
@@ -37,6 +53,15 @@ class AliAnalysisTaskMCEventPlane : public AliAnalysisTaskSE {
   AliFlowEventSimple*               fEvent;        //input event
   AliFlowAnalysisWithMCEventPlane*  fMc;           // MC EP analysis object
   TList*                            fListHistos;   // collection of output
+  
+  // Objects needed for mixed harmonics study:
+  Bool_t fEvaluateMixedHarmonics; // evaluate and store objects relevant for mixed harmonics
+  Int_t fnBinsMult; // number of multiplicity bins for mixed harmonics analysis versus multiplicity  
+  Double_t fMinMult; // minimal multiplicity for mixed harmonics analysis versus multiplicity  
+  Double_t fMaxMult; // maximal multiplicity for mixed harmonics analysis versus multiplicity    
+  Int_t fNinCorrelator; // n in <cos[m*phi_{pair}-n*RP]> and <sin[m*phi_{pair}-n*RP]>, where phi_{pair} = x*phi1+(1-x)*phi2
+  Int_t fMinCorrelator; // m in <cos[m*phi_{pair}-n*RP]> and <sin[m*phi_{pair}-n*RP]>, where phi_{pair} = x*phi1+(1-x)*phi2   
+  Double_t fXinPairAngle; // x in definition phi_{pair} = x*phi1+(1-x)*phi2
 
   ClassDef(AliAnalysisTaskMCEventPlane, 1); // AliAnalysisTaskMCEventPlane class object
 };
index cd776ff..f067d8a 100644 (file)
@@ -750,6 +750,7 @@ AliAnalysisTaskFlowEvent* AddTaskFlow(TString type, Bool_t* METHODS, Bool_t QA,
   }
   if (MCEP){
     AliAnalysisTaskMCEventPlane *taskMCEP = new AliAnalysisTaskMCEventPlane("TaskMCEventPlane");
+    taskMCEP->SetEvaluateMixedHarmonics(kFALSE);
     mgr->AddTask(taskMCEP);
   }
   if (MH){