updates from Salvatore
[u/mrichter/AliRoot.git] / PWGJE / EMCALJetTasks / UserTasks / AliAnalysisTaskSAQA.h
1 #ifndef ALIANALYSISTASKSAQA_H
2 #define ALIANALYSISTASKSAQA_H
3
4 // $Id$
5
6 class TClonesArray;
7 class TString;
8 class TH1F;
9 class TH2F;
10 class TH3F;
11
12 #include "AliAnalysisTaskEmcalJet.h"
13
14 class AliAnalysisTaskSAQA : public AliAnalysisTaskEmcalJet {
15  public:
16   AliAnalysisTaskSAQA();
17   AliAnalysisTaskSAQA(const char *name);
18   virtual ~AliAnalysisTaskSAQA();
19
20   void                        UserCreateOutputObjects();
21   void                        Terminate(Option_t *option);
22
23   void                        SetTrgClusName(const char *n)                        { fTrgClusName        = n          ; }
24   void                        SetCellEnergyCut(Float_t cut)                        { fCellEnergyCut      = cut        ; }
25   void                        SetDoTrigger(Bool_t trg = kTRUE)                     { fDoTrigger          = trg        ; }
26   void                        SetDoRepropagateTracks(Bool_t p = kTRUE)             { fRepropagateTracks  = p          ; }
27
28  protected:
29
30   Bool_t                      FillHistograms()                                              ;
31   Bool_t                      RetrieveEventObjects()                                        ;
32   Int_t                       DoCellLoop(Float_t &sum, Float_t &sum_cut)                    ;
33   void                        DoTriggerPrimitives(Int_t &maxL1amp, Int_t &maxL1thr)         ;
34   Float_t                     DoTriggerClusLoop()                                           ;
35   Float_t                     DoTrackLoop()                                                 ;
36   Float_t                     DoClusterLoop()                                               ;
37   void                        DoJetLoop()                                                   ;
38   void                        PropagateTrack(AliVTrack *track, Float_t &eta, Float_t &phi)  ;
39
40   Float_t                     fCellEnergyCut;            // Energy cell cut
41   Bool_t                      fDoTrigger;                // Make trigger qa plots
42   Bool_t                      fRepropagateTracks;        // Repropagate tracks to the EMCal surface
43   TString                     fTrgClusName;              // Name of trg clus name
44   TClonesArray               *fTrgClusters;              //!Trg Clusters
45   Int_t                       fNclusters;                //!Number of accepted clusters in the event
46   Int_t                       fNtracks;                  //!Number of accepted tracks in the event
47   Int_t                       fNjets;                    //!Number of accepted jets in the event
48  
49   // General histograms
50   TH1F                       *fHistCentrality;           //!Event centrality distribution
51   TH1F                       *fHistZVertex;              //!Z vertex position
52   TH2F                       *fHistTracksCent;           //!Number of tracks vs. centrality
53   TH2F                       *fHistClusCent;             //!Number of clusters vs. centrality
54   TH2F                       *fHistJetsCent;             //!Number of jets vs. centrality
55   TH2F                       *fHistClusTracks;           //!Number of clusters vs. number of tracks
56   TH2F                       *fHistJetsParts;            //!Number of jets vs. number of particles (tracks+clusters)
57   TH2F                       *fHistCellsCent;            //!Number of cells vs. centrality
58   TH2F                       *fHistCellsTracks;          //!Number of cells vs. number of tracks
59   // EMCAL trigger
60   TH2F                       *fHistMaxL1FastORCent;      //!Maximum L1 trigger FastOR amplitude vs. centrality
61   TH2F                       *fHistMaxL1ClusCent;        //!Maximum L1 trigger cluster amplitude vs. centrality
62   TH2F                       *fHistMaxL1ThrCent;         //!Maximum L1 trigger threshold vs. centrality
63   // Tracks
64   TH1F                       *fHistTracksPt;             //!Pt spectrum of tracks
65   TH2F                       *fHistTrPhiEta;             //!Phi-Eta distribution of tracks
66   TH2F                       *fHistTrEmcPhiEta;          //!Phi-Eta emcal propagated distribution of tracks
67   TH2F                       *fHistTrPhiEtaNonProp;      //!Phi-Eta distribution of non emcal propagated tracks
68   TH2F                       *fHistDeltaEtaPt;           //!Eta-EtaProp vs. Pt
69   TH2F                       *fHistDeltaPhiPt;           //!Phi-PhiProp vs. Pt
70   TH1F                       *fHistDeltaEtaNewProp;      //!NewEtaProp-EtaProp
71   TH1F                       *fHistDeltaPhiNewProp;      //!NewPhiProp-PhiProp
72   // Clusters
73   TH3F                       *fHistClusPhiEtaEnergy;     //!Phi-Eta-Energy distribution of clusters
74   TH2F                       *fHistNCellsEnergy;         //!Number of cells vs. energy of cluster
75   TH2F                       *fHistClusTimeEnergy;       //!Time vs. energy of cluster
76   //Jets
77   TH2F                       *fHistJetsPhiEta[4];        //!Phi-Eta distribution of jets
78   TH1F                       *fHistJetsPtNonBias[4];     //!Non biased inclusive jet pt spectrum
79   TH1F                       *fHistJetsPtClus[4];        //!Inclusive jet pt spectrum cluster biased
80   TH1F                       *fHistJetsPtTrack[4];       //!Inclusive jet pt spectrum track biased
81   TH1F                       *fHistJetsPt[4];            //!Biased inclusive jet pt spectrum
82   TH2F                       *fHistJetsPtAreaNonBias[4]; //!Non biased pt vs. area of jets
83   TH2F                       *fHistJetsPtArea[4];        //!Biased pt vs. area of jets
84   // EMCAL Cells
85   TH1F                       *fHistCellsEnergy;          //!Energy spectrum of cells
86   // Had corr QA
87   TH2F                       *fHistChVSneCells;          //!Charged vs. neutral (cells) energy
88   TH2F                       *fHistChVSneClus;           //!Charged vs. neutral (clusters) energy
89   TH2F                       *fHistChVSneCorrCells;      //!Charged vs. neutral (corrected cells) energy
90   // Hybrid tracks
91   TH1F                       *fHistTrackPhi[5];          //!Phi distribution of hybrid tracks
92   TH1F                       *fHistTrackEta[5];          //!Eta distribution of hybrid tracks
93   TH1F                       *fHistTrackPhiPt[6];        //!Phi distribution of hybrid tracks per pt bins
94   TH1F                       *fHistTrackEtaPt[6];        //!Eta distribution of hybrid tracks per pt bins
95
96  private:
97   AliAnalysisTaskSAQA(const AliAnalysisTaskSAQA&);            // not implemented
98   AliAnalysisTaskSAQA &operator=(const AliAnalysisTaskSAQA&); // not implemented
99
100   ClassDef(AliAnalysisTaskSAQA, 13) // Quality task for Emcal analysis
101 };
102 #endif