adding flag for non-field data
[u/mrichter/AliRoot.git] / PWG0 / dNdEta / AlidNdEtaCorrectionTask.h
CommitLineData
0f67a57c 1/* $Id$ */
2
3#ifndef AlidNdEtaCorrectionTask_H
4#define AlidNdEtaCorrectionTask_H
5
6#include "AliAnalysisTask.h"
7#include <TString.h>
770a1f1d 8#include "AliPWG0Helper.h"
0f67a57c 9
10class AliESDtrackCuts;
11class dNdEtaAnalysis;
12class AlidNdEtaCorrection;
1c15d51a 13class TH1;
0f67a57c 14class TH1F;
15class AliESDEvent;
16class TParticlePDG;
54b096ef 17class TH2F;
a7f69e56 18class TH3F;
54b096ef 19class TProfile;
0f67a57c 20
21class AlidNdEtaCorrectionTask : public AliAnalysisTask {
22 public:
1c15d51a 23 AlidNdEtaCorrectionTask();
24 AlidNdEtaCorrectionTask(const char* opt);
0f67a57c 25 virtual ~AlidNdEtaCorrectionTask();
26
27 virtual void ConnectInputData(Option_t *);
28 virtual void CreateOutputObjects();
29 virtual void Exec(Option_t*);
30 virtual void Terminate(Option_t *);
31
32 void SetTrackCuts(AliESDtrackCuts* cuts) { fEsdTrackCuts = cuts; }
770a1f1d 33 void SetAnalysisMode(AliPWG0Helper::AnalysisMode mode) { fAnalysisMode = mode; }
3d7758c1 34 void SetOnlyPrimaries(Bool_t flag = kTRUE) { fOnlyPrimaries = flag; }
0fc41645 35 void SetTrigger(AliPWG0Helper::Trigger trigger) { fTrigger = trigger; }
69b09e3b 36 void SetFillPhi(Bool_t flag = kTRUE) { fFillPhi = flag; }
37 void SetDeltaPhiCut(Float_t cut) { fDeltaPhiCut = cut; }
0fc41645 38
39 void SetOption(const char* opt) { fOption = opt; }
0f67a57c 40
41 protected:
42 Bool_t SignOK(TParticlePDG* particle);
43
44 AliESDEvent *fESD; //! ESD object
45 TList* fOutput; //! list send on output slot 0
46
47 TString fOption; // option string
770a1f1d 48 AliPWG0Helper::AnalysisMode fAnalysisMode; // detector that is used for analysis
0fc41645 49 AliPWG0Helper::Trigger fTrigger; // trigger used in the analysis
69b09e3b 50 Bool_t fFillPhi; // if true phi is filled as 3rd coordinate in all maps
51 Float_t fDeltaPhiCut; // cut in delta phi (only SPD)
52
0f67a57c 53 Int_t fSignMode; // if 0 process all particles, if +-1 process only particles with that sign
3d7758c1 54 Bool_t fOnlyPrimaries; // only process primaries (syst. studies)
69b09e3b 55 Int_t fStatError; // statistical error evaluation: if set to 1 we only count unique primaries (binomial errors are valid), for 2 all the rest
0f67a57c 56
57 AliESDtrackCuts* fEsdTrackCuts; // Object containing the parameters of the esd track cuts
58
59 AlidNdEtaCorrection* fdNdEtaCorrection; //! contains the intermediate histograms (on each slave)
60
61 dNdEtaAnalysis* fdNdEtaAnalysisMC; //! analysis from MC (only triggered, vertex events)
62 dNdEtaAnalysis* fdNdEtaAnalysisESD; //! analysis from ESD (not yet corrected!)
63
64 // control histograms
65 TH1F* fPIDParticles; //! pid of primary particles
66 TH1F* fPIDTracks; //! pid of reconstructed tracks
1c15d51a 67
54b096ef 68 TH2F* fVertexCorrelation; //! ESD z-vtx vs MC z-vtx
a7f69e56 69 TH3F* fVertexCorrelationShift; //! (MC z-vtx - ESD z-vtx) vs MC z-vtx vs n# rec tracks
54b096ef 70 TProfile* fVertexProfile; //! Profile of MC z-vtx - ESD z-vtx vs. MC z-vtx
1c15d51a 71 TH1F* fVertexShift; //! (MC z-vtx - ESD z-vtx) in +- 10 cm
a7f69e56 72 TH2F* fVertexShiftNorm; //! (MC z-vtx - ESD z-vtx) / (sigma_ESD-z-vtx) vs. no. rec tracks
0f67a57c 73
3d7758c1 74 TH2F* fEtaCorrelation; //! ESD eta vs MC eta
51f6de65 75 TH2F* fEtaCorrelationShift; //! (MC eta - ESD eta) vs MC eta
3d7758c1 76 TProfile* fEtaProfile; //! Profile of MC eta - ESD eta vs. MC eta
1c15d51a 77 TH1F* fEtaResolution; //! MC eta - ESD eta in |eta| < 1
69b09e3b 78 TH2F* fDeltaPhiCorrelation; //! delta phi ESD vs. MC
1c15d51a 79
69b09e3b 80 TH2F* fpTResolution; //! (MC pT - ESD pT) / MC pT vs. MC pT in |eta| < 0.9
1c15d51a 81
82 AliESDtrackCuts* fEsdTrackCutsPrim; //! control histograms for primaries
83 AliESDtrackCuts* fEsdTrackCutsSec; //! control histograms for secondaries
3d7758c1 84
96fcc8a7 85 // histograms for systematic studies (must be enabled with option)
86
1c15d51a 87 TH1* fTemp1; //! temp histogram for quick study of variables
88 TH1* fTemp2; //! temp histogram for quick study of variables
96fcc8a7 89
4ef701a0 90 TH1F* fMultAll; //! primary particles in |eta| < 1 and pT > 0.2 in all events
91 TH1F* fMultTr; //! primary particles in |eta| < 1 and pT > 0.2 in triggered events
92 TH1F* fMultVtx; //! primary particles in |eta| < 1 and pT > 0.2 in triggered events with vertex
93
69b09e3b 94 TH2* fDeltaPhi[8]; //! delta phi of primaries, secondaries, other (= unclear cases)
4ef701a0 95
69b09e3b 96 TH2F* fEventStats; //! some stats on number of events, see CreateOutputObjects for a detailed definition
50ec344d 97
69b09e3b 98 AlidNdEtaCorrection* fdNdEtaCorrectionSpecial[4]; //! correction maps used for systematic studies, may contain:
99 // for specific process type (ND, SD, DD), enable with option: process-types
100 // for particle species (pi, K, p, rest), enable with: particle-species
96fcc8a7 101
0f67a57c 102 private:
103 AlidNdEtaCorrectionTask(const AlidNdEtaCorrectionTask&);
104 AlidNdEtaCorrectionTask& operator=(const AlidNdEtaCorrectionTask&);
105
106 ClassDef(AlidNdEtaCorrectionTask, 1);
107};
108
109#endif