]> git.uio.no Git - u/mrichter/AliRoot.git/blob - PWGJE/EMCALJetTasks/AliJetResponseMaker.h
Update from Salvatore for full jet embedding
[u/mrichter/AliRoot.git] / PWGJE / EMCALJetTasks / AliJetResponseMaker.h
1 #ifndef ALIJETRESPONSEMAKER_H
2 #define ALIJETRESPONSEMAKER_H
3
4 // $Id$
5
6 class AliGenPythiaEventHeader;
7 class TClonesArray;
8 class TH1;
9 class TH2;
10 class TH3;
11
12 #include "AliAnalysisTaskEmcalJet.h"
13
14 class AliJetResponseMaker : public AliAnalysisTaskEmcalJet {
15  public:
16   AliJetResponseMaker();
17   AliJetResponseMaker(const char *name);
18   virtual ~AliJetResponseMaker();
19
20   void                        UserCreateOutputObjects();
21
22   void                        SetMCJetsName(const char *n)       { fMCJetsName      = n; }
23   void                        SetMCTracksName(const char *n)     { fMCTracksName    = n; }
24   void                        SetMaxDistance(Double_t d)         { fMaxDistance     = d; }
25   void                        SetDoWeighting(Bool_t d = kTRUE)   { fDoWeighting     = d; }
26   void                        SetMCFiducial(Bool_t f = kTRUE)    { fMCFiducial      = f; }
27   void                        SetEventWeightHist(Bool_t h)       { fEventWeightHist = h; }
28   void                        SetPtHardBin(Int_t b)              { fSelectPtHardBin = b; }
29   void                        SetDoMatching(Bool_t b)            { fDoMatching      = b; }
30
31  protected:
32   Bool_t                      IsEventSelected();
33   Bool_t                      AcceptJet(AliEmcalJet* jet)   const;
34   void                        ExecOnce();
35   void                        DoJetLoop(TClonesArray *jets1, TClonesArray *jets2, Bool_t mc);
36   Bool_t                      FillHistograms();
37   Bool_t                      RetrieveEventObjects();
38   Bool_t                      Run();
39
40   TString                     fMCTracksName;                  // name of MC particle collection
41   TString                     fMCJetsName;                    // name of MC jet collection
42   Double_t                    fMaxDistance;                   // maximum distance between matched particle and detector level jets
43   Bool_t                      fDoWeighting;                   // = true, weight using trials and given x section
44   Bool_t                      fEventWeightHist;               // = true create event weight histogram
45   Bool_t                      fMCFiducial;                    // = true MC jets in fiducial acceptance
46   Double_t                    fMCminEta;                      // MC jets minimum eta
47   Double_t                    fMCmaxEta;                      // MC jets maximum eta
48   Double_t                    fMCminPhi;                      // MC jets minimum phi
49   Double_t                    fMCmaxPhi;                      // MC jets maximum phi
50   Int_t                       fSelectPtHardBin;               // select one pt hard bin for analysis
51   Bool_t                      fDoMatching;                    // whether or not it should run the matching between MC and rec jets
52
53   AliGenPythiaEventHeader    *fPythiaHeader;                  //!event Pythia header
54   Double_t                    fEventWeight;                   //!event weight
55   Int_t                       fPtHardBin;                     //!event pt hard bin
56   Int_t                       fNTrials;                       //!event trials
57   TClonesArray               *fMCTracks;                      //!MC particles
58   TClonesArray               *fMCJets;                        //!MC jets
59   // General histograms
60   TH1                        *fHistNTrials;                   //!total number of trials per pt hard bin
61   TH1                        *fHistEvents;                    //!total number of events per pt hard bin
62   TH1                        *fHistEventWeight[11];           //!event weight
63   // Particle level jets
64   TH2                        *fHistMCJetsPhiEta;              //!phi-eta distribution of jets
65   TH2                        *fHistMCJetsPtArea;              //!inclusive jet pt vs area histogram
66   TH2                        *fHistMCJetsPhiEtaFiducial;      //!phi-eta distribution of jets in fiducial acceptance (plus lead hadron bias)
67   TH2                        *fHistMCJetsPtAreaFiducial;      //!inclusive jet pt spectrum in fiducial acceptance (plus lead hadron bias)
68   TH2                        *fHistMCJetsNEFvsPt;             //!jet neutral energy fraction vs. jet pt
69   TH2                        *fHistMCJetsZvsPt;               //!constituent Pt over Jet Pt ratio vs. jet pt
70   // Detector level jets
71   TH2                        *fHistJetsPhiEta;                //!phi-eta distribution of jets
72   TH2                        *fHistJetsPtArea;                //!inclusive jet pt vs. area histogram
73   TH2                        *fHistJetsCorrPtArea;            //!inclusive jet pt vs. area histogram
74   TH2                        *fHistJetsNEFvsPt;               //!jet neutral energy fraction vs. jet pt
75   TH2                        *fHistJetsZvsPt;                 //!constituent Pt over Jet Pt ratio vs. jet pt
76   // Detector-particle level matching
77   TH2                        *fHistMatchingLevelMCPt;         //!matching level vs. particle level pt
78   TH3                        *fHistClosestDeltaEtaPhiMCPt;    //!delta eta-phi between closest particle level to detector level jet vs. particle level pt
79   TH2                        *fHistClosestDeltaPtMCPt;        //!delta pt between closest particle level to detector level jet vs. particle level pt
80   TH2                        *fHistClosestDeltaCorrPtMCPt;    //!delta pt between closest particle level to detector level jet vs. particle level pt
81   TH2                        *fHistNonMatchedMCJetsPtArea;    //!non-matched mc jet pt distribution
82   TH2                        *fHistNonMatchedJetsPtArea;      //!non-matched jet pt distribution
83   TH2                        *fHistNonMatchedJetsCorrPtArea;  //!non-matched jet pt distribution
84   TH2                        *fHistPartvsDetecPt;             //!particle vs detector level jet pt
85   TH2                        *fHistPartvsDetecCorrPt;         //!particle vs detector level jet pt
86   TH2                        *fHistMissedMCJetsPtArea;         //!mc jets not measured
87
88  private:
89   AliJetResponseMaker(const AliJetResponseMaker&);            // not implemented
90   AliJetResponseMaker &operator=(const AliJetResponseMaker&); // not implemented
91
92   ClassDef(AliJetResponseMaker, 9) // Jet response matrix producing task
93 };
94 #endif