Update responsibles for MCH, MTR, HMP
[u/mrichter/AliRoot.git] / JETAN / AliAnalysisTaskJetBackgroundSubtract.h
CommitLineData
fb10c4b8 1#ifndef ALIANALYSISTASKJETBACKGROUNDSUBTRACT_H
2#define ALIANALYSISTASKJETBACKGROUNDSUBTRACT_H
3
4/* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
5 * See cxx source for full Copyright notice */
6
7// **************************************
8// task used for background subtration of all jets found with clustering algos
9// *******************************************
10
11#include "AliAnalysisTaskSE.h"
12#include "TObjString.h"
13#include "TString.h"
fb10c4b8 14
15
16////////////////
17class AliJetHeader;
18class AliESDEvent;
19class AliAODEvent;
20class AliAODExtension;
21class AliAODJet;
22class AliAODJetEventBackground;
23class AliJetFinder;
24class TList;
25class TChain;
26class TH2F;
27class TH1F;
28class TH3F;
29class TProfile;
30class TRandom3;
31class TRefArray;
f0659f11 32class TObjArray;
fb10c4b8 33
34class AliAnalysisTaskJetBackgroundSubtract : public AliAnalysisTaskSE
35{
36 public:
37 AliAnalysisTaskJetBackgroundSubtract();
38 AliAnalysisTaskJetBackgroundSubtract(const char* name);
39 virtual ~AliAnalysisTaskJetBackgroundSubtract();
40 // Implementation of interface methods
41 virtual void UserCreateOutputObjects();
42 virtual void Init();
43 virtual void LocalInit() { Init(); }
44 virtual void UserExec(Option_t *option);
45 virtual void Terminate(Option_t *option);
46 virtual Bool_t Notify();
47
48 // Task specific methods...
f0659f11 49 virtual void AddJetBranch(const char* c);
fb10c4b8 50 virtual void SetSubtractionMethod(Int_t i){fSubtraction = i;}
51 virtual Int_t GetSubtractionMethod(){return fSubtraction;}
bea24d2d 52 virtual void SetKeepJets(Bool_t b = kTRUE){fKeepJets = b;}
e77ab2dc 53 virtual void SetExclude2Leading(Bool_t b=kTRUE){fExclude2Leading=b;}
fb10c4b8 54 virtual void SetBackgroundBranch(char* c){fBackgroundBranch = c;}
5719a46e 55 virtual void SetNonStdOutputFile(char* c){fNonStdFile = c;}
fb10c4b8 56 virtual void SetToReplace(char* c){fReplaceString1 = c;}
57 const char* GetToReplace(){return fReplaceString1.Data();}
58 virtual void SetReplacementMask(char* c){fReplaceString2 = c;}
a18eedbb 59 const char* GetReplacementMask(){return fReplaceString2.Data();}
fb10c4b8 60
a18eedbb 61 enum {kNoSubtract = 0,kArea,k4Area,kRhoRecalc,kRhoRC};
fb10c4b8 62
63 private:
64
65
66
67 AliAnalysisTaskJetBackgroundSubtract(const AliAnalysisTaskJetBackgroundSubtract&);
68 AliAnalysisTaskJetBackgroundSubtract& operator=(const AliAnalysisTaskJetBackgroundSubtract&);
69 Bool_t RescaleJetMomentum(AliAODJet *jet,Float_t pT);
d73e1768 70 Bool_t RescaleJet4vector(AliAODJet *jet,TLorentzVector backgroundv);
82ac956f 71 Int_t MultFromJetRefs(TClonesArray* jets);
a18eedbb 72 Double_t RecalcRho(TClonesArray* fbkgclusters,Double_t meanarea);
73 Double_t RhoRC(TClonesArray* fbkgclustersRC);
fb10c4b8 74 void ResetOutJets();
1c21a0e7 75 void PrintAODContents();
fb10c4b8 76
77 AliAODEvent *fAODOut; // ! where we take the jets from and they are modified
78 AliAODEvent *fAODIn; // ! where we may take the background from, only in case we do not find it in the output
79 AliAODExtension *fAODExtension; // ! where we take the jets from can be input or output AOD
80 TObjArray *fJBArray; // Array that stores the name of all jet branches to be subtracted
81 TString fBackgroundBranch; // name of the branch used for background subtraction
82 //
83 TString fNonStdFile; // The optional name of the output file the non-std brnach is written to
84 TString fReplaceString1; // To construct the new output name
85 TString fReplaceString2; // To construct the new output name
86 Int_t fSubtraction; // Parameter for subtraction mode
bea24d2d 87 Bool_t fKeepJets; // keeps the jets with negative p_t rescaled to 0.1 GeV
e77ab2dc 88 Bool_t fExclude2Leading; //background excluding 2 leading jets, background 3 in AliAnalysisTaskJetCluster.cxx
fb10c4b8 89 TList *fInJetArrayList; //! transient list to make ease the handling of input jets
90 TList *fOutJetArrayList; //! transient list to make ease the reset of output jets
e77ab2dc 91
d73e1768 92 TH2F* fh2CentvsRho; //! centrality vs background density
93 TH2F* fh2CentvsSigma; //! centrality vs background sigma
82ac956f 94 TH2F* fh2MultvsRho; //! centrality vs background density
95 TH2F* fh2MultvsSigma; //! centrality vs background sigma
d73e1768 96 TH2F* fh2ShiftEta; //! extended correction Eta
97 TH2F* fh2ShiftPhi; //! extended correction Phi
98 TH2F* fh2ShiftEtaLeading; //! extended correction Eta leading jet
99 TH2F* fh2ShiftPhiLeading; //! extended correction Phi leading jet
100
101
fb10c4b8 102 TList *fHistList; //! the histograms output list
103
ac53ce9a 104 ClassDef(AliAnalysisTaskJetBackgroundSubtract, 7)
fb10c4b8 105};
106
107#endif