Fix minor bug in SDD raw data writing (F. Prino)
[u/mrichter/AliRoot.git] / PWG4 / JetTasks / AliAnalysisTaskJetSpectrum.h
CommitLineData
f3050824 1#ifndef ALIANALYSISTASKJETSPECTRUM_H
2#define ALIANALYSISTASKJETSPECTRUM_H
3
4/* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
5 * See cxx source for full Copyright notice */
6
7#include "AliAnalysisTaskSE.h"
4dbfdecc 8#include "THnSparse.h"
df65bddb 9////////////////
f3050824 10class AliJetHeader;
11class AliESDEvent;
12class AliAODEvent;
13class AliAODJet;
14class AliGenPythiaEventHeader;
15
16class TList;
17class TChain;
18class TH2F;
19class TH3F;
4dbfdecc 20class TProfile;
21
f3050824 22
23class AliAnalysisTaskJetSpectrum : public AliAnalysisTaskSE
24{
25 public:
26 AliAnalysisTaskJetSpectrum();
27 AliAnalysisTaskJetSpectrum(const char* name);
28 virtual ~AliAnalysisTaskJetSpectrum() {;}
29 // Implementation of interface methods
30 virtual void UserCreateOutputObjects();
31 virtual void Init();
32 virtual void LocalInit() { Init(); }
33 virtual void UserExec(Option_t *option);
34 virtual void Terminate(Option_t *option);
4dbfdecc 35 virtual Bool_t Notify();
36
f3050824 37
38 virtual void SetExternalWeight(Float_t f){fExternalWeight = f;}
39 virtual void SetUseExternalWeightOnly(Bool_t b){fUseExternalWeightOnly = b;}
40 virtual void SetAODInput(Bool_t b){fUseAODInput = b;}
41 virtual void SetLimitGenJetEta(Bool_t b){fLimitGenJetEta = b;}
42 virtual void SetAnalysisType(Int_t i){fAnalysisType = i;}
43 virtual void SetBranchGen(char* c){fBranchGen = c;}
44 virtual void SetBranchRec(char* c){fBranchRec = c;}
45
46 // Helper
47 static void GetClosestJets(AliAODJet *genJets,Int_t &nGenJets,
48 AliAODJet *recJets,Int_t &nRecJets,
49 Int_t *iGenIndex,Int_t *iRecIndex,Int_t iDebug = 0);
50
51 //
52
53 enum {kAnaMC = 0x1};
df65bddb 54 enum {kMaxJets = 5};
55 enum {kMaxCorrelation = 3};
f3050824 56
57 private:
58
59 AliAnalysisTaskJetSpectrum(const AliAnalysisTaskJetSpectrum&);
60 AliAnalysisTaskJetSpectrum& operator=(const AliAnalysisTaskJetSpectrum&);
61
df65bddb 62 static const Float_t fgkJetNpartCut[kMaxCorrelation];
f3050824 63
f3050824 64
65 AliJetHeader *fJetHeaderRec;
66 AliJetHeader *fJetHeaderGen;
67 AliAODEvent *fAOD; // where we take the jets from can be input or output AOD
68
69 TString fBranchRec; // AOD branch name for reconstructed
70 TString fConfigRec; // Name of the Config file
71 TString fBranchGen; // AOD brnach for genereated
72 TString fConfigGen; // Name of the Config file (if any)
73
74 Bool_t fUseAODInput;
75 Bool_t fUseExternalWeightOnly;
76 Bool_t fLimitGenJetEta;
77 Int_t fAnalysisType;
78 Float_t fExternalWeight;
79
4dbfdecc 80 TProfile* fh1Xsec; // pythia cross section and trials
81 TH1F* fh1Trials; // trials are added
f3050824 82 TH1F* fh1PtHard; // Pt har of the event...
83 TH1F* fh1PtHard_NoW; // Pt har of the event...
84 TH1F* fh1PtHard_Trials; // Number of trials
85 TH1F* fh1NGenJets;
86 TH1F* fh1NRecJets;
87 TH1F* fh1E[kMaxJets]; // Jet Energy
88 TH1F* fh1PtRecIn[kMaxJets]; // Jet pt for all
89 TH1F* fh1PtRecOut[kMaxJets]; // Jet pt with corellated generated jet
90 TH1F* fh1PtGenIn[kMaxJets]; // Detection efficiency for given p_T.gen
91 TH1F* fh1PtGenOut[kMaxJets]; //
92
93
94
95 TH2F* fh2PtFGen[kMaxJets]; //
22ceb537 96 TH2F* fh2PhiFGen[kMaxJets]; //
97 TH2F* fh2EtaFGen[kMaxJets]; //
f3050824 98 TH2F* fh2Frag[kMaxJets]; // fragmentation function
99 TH2F* fh2FragLn[kMaxJets]; //
22ceb537 100 TH2F* fh2PtGenDeltaPhi[kMaxJets];
101 TH2F* fh2PtGenDeltaEta[kMaxJets];
f3050824 102
103 TH3F* fh3PtRecGenHard[kMaxJets]; //
104 TH3F* fh3PtRecGenHard_NoW[kMaxJets]; //
105 TH3F* fh3RecEtaPhiPt[kMaxJets]; //
106 TH3F* fh3RecEtaPhiPt_NoGen[kMaxJets]; //
107 TH3F* fh3GenEtaPhiPt_NoFound[kMaxJets]; //
108 TH3F* fh3GenEtaPhiPt[kMaxJets]; //
109 // ========= Multiplicity dependence ======
110
111 // ==========TODO , flavaor dependence ========
112 // ============================================
113
114
115 // ============= TODO , phi dependence ========
116 // ============================================
117
118 TList *fHistList; // Output list
df65bddb 119
120 ///////// For 2 dimensional unfolding //////////////////
121 TH1F* fh1JetMultiplicity;
122 TH2F* fh2ERecZRec;
123 TH2F* fh2EGenZGen;
124 TH2F* fh2Efficiency;
125 TH3F* fh3EGenERecN;
126 THnSparseF* fhnCorrelation[kMaxCorrelation];
127 ///////////////////////////////////////////////////////
f3050824 128
129
130 ClassDef(AliAnalysisTaskJetSpectrum, 1) // Analysis task for standard jet analysis
131};
132
133#endif