]> git.uio.no Git - u/mrichter/AliRoot.git/blob - PWGLF/FORWARD/analysis2/AliForwardMCFlowTaskQC.h
Mega-commit by Alexander - added Event plane to analysis task, and other flow updates...
[u/mrichter/AliRoot.git] / PWGLF / FORWARD / analysis2 / AliForwardMCFlowTaskQC.h
1 //
2 // Calculate the flow in the forward regions using the Q cumulants method
3 //
4 #ifndef ALIFORWARDMCFLOWTASKQC_H
5 #define ALIFORWARDMCFLOWTASKQC_H
6 /**
7  * @file   AliForwardMCFlowTaskQC.h
8  * @author Alexander Hansen alexander.hansen@cern.ch
9  * @date   Tue Feb 14 2012
10  * 
11  * @brief  
12  * 
13  * 
14  * @ingroup pwglf_forward_flow
15  */
16 #include "AliForwardFlowTaskQC.h"
17 #include <TH2D.h>
18 class TGraph;
19
20  /**
21  * @defgroup pwg2_forward_tasks_flow Flow tasks 
22  * @ingroup pwg2_forward_tasks
23  */
24 /**
25  * Calculate the flow in the forward regions using the Q cumulants method
26  *
27  * @par Inputs:
28  *   - AliAODEvent
29  *
30  * Outputs:
31  *   - AnalysisResults.root
32  *
33  * @ingroup pwg2_forward_tasks_flow
34  * @ingroup pwg2_forward_flow
35  *
36  *
37  */
38 class AliForwardMCFlowTaskQC : public AliForwardFlowTaskQC
39 {
40 public:
41   /**
42    * Constructor
43    */
44   AliForwardMCFlowTaskQC();
45   /*
46    * Constructor
47    *
48    * @param name Name of task
49    */
50   AliForwardMCFlowTaskQC(const char* name);
51   /**
52    * Destructor 
53    */
54   virtual ~AliForwardMCFlowTaskQC() {}
55   /** 
56    * @{ 
57    * @name Task interface methods 
58    */
59   /**
60    * Loop over AliAODMCParticle branch object and fill d^2N/detadphi histograms
61    * add flow if arguments are set
62    * 
63    * @return true on success
64    */
65   Bool_t LoopAODMC();
66     /*
67    * Set string to add flow to MC truth particles
68    *
69    * @param type String
70    */
71   void AddFlow(TString type = "") { fAddFlow = type; }
72   /*
73    * Set which function fAddFlow should use
74    *
75    * @param type of AddFlow 
76    */
77   void AddFlowType(Int_t number = 0) { fAddType = number; }
78   /*
79    * Set which order of flow to add
80    *
81    * @param order Flow order 
82    */
83   void AddFlowOrder(Int_t order = 2) { fAddOrder = order; }
84  
85 protected:
86   /*
87    * Copy constructor
88    *
89    * @param o Object to copy from
90    */
91   AliForwardMCFlowTaskQC(const AliForwardMCFlowTaskQC& o);
92   /** 
93    * Assignment operator 
94    * 
95    * @return Reference to this object 
96    */
97   AliForwardMCFlowTaskQC& operator=(const AliForwardMCFlowTaskQC& o);
98   /*
99    * Initiate vertex bin objects
100    */
101   void InitVertexBins();
102    /*
103    * Initiate diagnostics histograms
104    */
105   void InitHists();
106   /*
107    * Analyze event
108    */
109   Bool_t Analyze();
110   /*
111    * Finalize analysis
112    */
113   void Finalize();
114   /**
115    * Add pt dependent flow factor
116    *
117    * @param Pt   @f$ p_T@f$
118    * @param type Type of flow 
119    */
120   Double_t AddptFlow(Double_t pt) const;
121   /**
122    * Add pid dependent flow factor
123    *
124    * @param ID   Particle ID 
125    * @param type Type of flow
126    */
127   Double_t AddpidFlow(Int_t id) const;
128   /**
129    * Add eta dependent flow factor
130    * 
131    * @param Eta  @f$\eta@f$ 
132    * @param type Type of flow 
133    */
134   Double_t AddetaFlow(Double_t eta) const;
135   /**
136    * Get centrality form MC impact parameter
137    */
138   Double_t GetCentFromB() const;
139   
140   TList         fBinsFMDTR;         //  List with FMDTR VertexBin objects
141   TList         fBinsSPDTR;         //  List with SPDTR VertexBin objects
142   TList         fBinsMC;            //  List with MC VertexBin objects
143   TH2D          fdNdedpMC;          //  d^2N/detadphi MC truth histogram
144   TGraph*       fAliceCent4th;      //  Parametrization of ALICE QC4 vs. cent. data
145   TGraph*       fAlicePt2nd4050;    //  Parametrization of ALICE QC2 vs. pT data
146   TGraph*       fAlicePt4th3040;    //  Parametrization of ALICE QC4 vs. pT data
147   TGraph*       fAlicePt4th4050;    //  Parametrization of ALICE QC4 vs. pT data
148   TGraph*       fImpactParToCent;   //  Parametrization of b to centrality datapoints
149   TString       fAddFlow;           //  Add flow string
150   Int_t         fAddType;           //  Add flow type #
151   Int_t         fAddOrder;          //  Add flow order
152
153   ClassDef(AliForwardMCFlowTaskQC, 1); // FMD MC analysis task 
154 };
155  
156 #endif
157 // Local Variables:
158 //   mode: C++ 
159 // End: