2 // Base class for classes that calculate the multiplicity in the
3 // forward regions event-by-event
5 #ifndef ALIFORWARDMULTIPLICITYBASE_H
6 #define ALIFORWARDMULTIPLICITYBASE_H
8 * @file AliForwardMultiplicityBase.h
9 * @author Christian Holm Christensen <cholm@dalsgaard.hehi.nbi.dk>
10 * @date Wed Mar 23 14:06:29 2011
15 * @ingroup pwglf_forward_aod
17 #include <AliAnalysisTaskSE.h>
18 class AliFMDEventInspector;
19 class AliFMDEnergyFitter;
20 class AliFMDSharingFilter;
21 class AliFMDDensityCalculator;
22 class AliFMDCorrector;
23 class AliFMDHistCollector;
24 class AliForwardCorrectionManager;
25 class AliFMDEventPlaneFinder;
33 * @mainpage ALICE PWGLF Forward Multiplcity Analysis
35 * This is the analysis code for analysis of the Forward data.
39 * See the <a href="modules.html">Modules</a> page
44 * Usage: Run.sh [OPTIONS]
46 * Do Pass1 and Pass2 on ESD files in current directory.
50 * -n,--events N Number of events (-1)
51 * -1,--pass1 Run pass 1, only AOD (0)
52 * -2,--pass2 Run pass 2, only Hists (0)
53 * -3,--pass3 Draw results (0)
54 * -v,--vz-min CM Minimum value of vz (-10)
55 * -V,--vz-max CM Maximum value of vz (10)
56 * -t,--trigger TYPE Select trigger TYPE (INEL)
57 * -b,--batch Do batch processing (0)
58 * -P,--proof NWORKERS Run in PROOF(Lite) mode (0)
59 * -M,--mc Run over MC data (0)
60 * -g,--gdb Run in GDB mode (0)
61 * -E,--eloss Run energy loss script
62 * -r,--rebin Rebin factor (1)
63 * -C,--use-centrality Run centrality task (0)
64 * -O,--show-older Show older data (0)
65 * -J,--show-published Show ALICE published data (1)
66 * -R,--show-ratios Show ratios to other data (1)
67 * -Z,--show-asymmetry Show asymmetry (1)
68 * -S,--scheme SCHEME Normalisation scheme (full)
69 * -T,--title STRING Title on plots ()
71 * TYPE is a comma or space separated list of
73 * INEL Inelastic triggers (V0A|V0C|SPD)
74 * INEL>0 As above + N_ch > 0 in -0.5<eta<+0.5
75 * NSD Non-single diffractive ((VOA&VOC)|N_ch > 5 -1.9<eta<+1.9)
77 * SCHEME is a comma or space separated list of
79 * NONE No event-level normalization except trivial one
80 * EVENTLEVEL Event-level normalization
81 * ALTEVENTLEVEL Event-level normalization (alternative version)
82 * BACKGROUND Not implemented yet
83 * SHAPE Shape correction
84 * FULL Same as EVENTLEVEL,BACKGROUND,SHAPE
85 * ALTFULL Same as ALTEVENTLEVEL,BACKGROUND,SHAPE
87 * If NWORKERS is 0, then the analysis will be run in local mode.
91 * @defgroup pwglf_forward PWGLF Forward analysis
93 * Code to do the multiplicity analysis in the forward psuedo-rapidity
98 * @defgroup pwglf_forward_tasks Tasks
100 * Code to do the multiplicity analysis in the forward psuedo-rapidity
103 * @ingroup pwglf_forward
106 * @defgroup pwglf_forward_topical Topical
109 * @defgroup pwglf_forward_aod AOD
110 * @ingroup pwglf_forward_topical
113 * Base class for classes that calculate the multiplicity in the
114 * forward regions event-by-event
120 * - AliAODForwardMult
124 * @par Corrections used
126 * @ingroup pwglf_forward_tasks
127 * @ingroup pwglf_forward_aod
130 class AliForwardMultiplicityBase : public AliAnalysisTaskSE
135 * @name Interface methods
138 * Initialize the task
141 virtual void Init() { fFirstEvent = true; }
143 * Create output objects
146 virtual void UserCreateOutputObjects() = 0;
150 * @param option Not used
152 virtual void UserExec(Option_t* option) = 0;
156 * @param option Not used
158 virtual void Terminate(Option_t* option) = 0;
165 * @param option Not used
167 virtual void Print(Option_t* option="") const;
169 * Whether to enable low-flux code
171 * @param use IF true, enable low-flux code
173 virtual void SetEnableLowFlux(Bool_t use=true) { fEnableLowFlux = use; }
176 * @name Access to sub-algorithms
179 * Get reference to the EventInspector algorithm
181 * @return Reference to AliFMDEventInspector object
183 virtual AliFMDEventInspector& GetEventInspector() = 0;
185 * Get reference to the SharingFilter algorithm
187 * @return Reference to AliFMDSharingFilter object
189 virtual AliFMDSharingFilter& GetSharingFilter() = 0;
191 * Get reference to the DensityCalculator algorithm
193 * @return Reference to AliFMDDensityCalculator object
195 virtual AliFMDDensityCalculator& GetDensityCalculator() = 0;
197 * Get reference to the Corrections algorithm
199 * @return Reference to AliFMDCorrector object
201 virtual AliFMDCorrector& GetCorrections() = 0;
203 * Get reference to the HistCollector algorithm
205 * @return Reference to AliFMDHistCollector object
207 virtual AliFMDHistCollector& GetHistCollector() = 0;
209 * Get reference to the EventInspector algorithm
211 * @return Reference to AliFMDEventInspector object
213 virtual const AliFMDEventInspector& GetEventInspector() const = 0;
215 * Get reference to the SharingFilter algorithm
217 * @return Reference to AliFMDSharingFilter object
219 virtual const AliFMDSharingFilter& GetSharingFilter() const = 0;
221 * Get reference to the DensityCalculator algorithm
223 * @return Reference to AliFMDDensityCalculator object
225 virtual const AliFMDDensityCalculator& GetDensityCalculator() const = 0;
227 * Get reference to the Corrections algorithm
229 * @return Reference to AliFMDCorrector object
231 virtual const AliFMDCorrector& GetCorrections() const = 0;
233 * Get reference to the HistCollector algorithm
235 * @return Reference to AliFMDHistCollector object
237 virtual const AliFMDHistCollector& GetHistCollector() const = 0;
239 * Get reference to the EventPlaneFinder algorithm
241 * @return Reference to AliFMDEventPlaneFinder object
243 virtual AliFMDEventPlaneFinder& GetEventPlaneFinder() = 0;
245 * Get reference to the EventPlaneFinder algorithm
247 * @return Reference to AliFMDEventPlaneFinder object
249 virtual const AliFMDEventPlaneFinder& GetEventPlaneFinder() const = 0;
254 virtual void SetDebug(Int_t dbg) = 0;
259 * @param name Name of task
261 AliForwardMultiplicityBase(const char* name);
265 AliForwardMultiplicityBase()
266 : AliAnalysisTaskSE(),
267 fEnableLowFlux(true),
274 * @param o Object to copy from
276 AliForwardMultiplicityBase(const AliForwardMultiplicityBase& o)
277 : AliAnalysisTaskSE(o),
278 fEnableLowFlux(o.fEnableLowFlux),
279 fFirstEvent(o.fFirstEvent),
280 fCorrManager(o.fCorrManager)
283 * Assignment operator
285 * @param o Object to assign from
287 * @return Reference to this object
289 AliForwardMultiplicityBase& operator=(const AliForwardMultiplicityBase& o);
291 * Check if all needed corrections are there and accounted for. If not,
294 * @param what Which corrections is needed
296 * @return true if all present, false otherwise
298 Bool_t CheckCorrections(UInt_t what) const;
303 virtual Bool_t ReadCorrections(const TAxis*& pe,
307 * Get the ESD event. IF this is the first event, initialise
309 virtual AliESDEvent* GetESDEvent();
311 * Initialise the sub objects and stuff. Called on first event
314 virtual void InitializeSubs() = 0;
316 * Mark this event as one to store in the AOD
319 virtual void MarkEventForStore() const;
321 * Make Ring @f$ dN/d\eta @f$ histogram and a stack
323 * @param input List with summed signals
324 * @param output Output list
325 * @param inName Input name
326 * @param outName Output name
329 virtual void MakeRingdNdeta(const TList* input,
333 Int_t style=20) const;
334 Bool_t fEnableLowFlux;// Whether to use low-flux specific code
335 Bool_t fFirstEvent; // Whether the event is the first seen
338 * A pointer to the corrections manager. This is here to make the
339 * corrections manager persistent - that is, when we write the
340 * analysis train to a file (as done in PROOF) we should also write
341 * down the corrections mananger. This pointer ensures that.
344 AliForwardCorrectionManager* fCorrManager; // Pointer to corrections manager
346 ClassDef(AliForwardMultiplicityBase,2) // Forward multiplicity class