]> git.uio.no Git - u/mrichter/AliRoot.git/blob - PWG1/global/AliAnalysisTaskVertexESD.h
fixed seeting of eta cut
[u/mrichter/AliRoot.git] / PWG1 / global / AliAnalysisTaskVertexESD.h
1 #ifndef AliAnalysisTaskVertexESD_cxx
2 #define AliAnalysisTaskVertexESD_cxx
3
4 /* Copyright(c) 1998-2009, ALICE Experiment at CERN, All rights reserved. *
5  * See cxx source for full Copyright notice                               */
6
7 //*************************************************************************
8 // Class AliAnalysisTaskVertexESD
9 // AliAnalysisTask to extract from ESD the information for the analysis
10 // of the primary vertex reconstruction efficiency and resolution
11 // (for MC events) and distributions (for real data). Three vertices:
12 // - SPD tracklets
13 // - ITS+TPC tracks
14 // - TPC-only tracks
15 //
16 // Author: A.Dainese, andrea.dainese@pd.infn.it
17 //*************************************************************************
18
19 class TNtuple;
20 class TH1F;
21 class TH2F;
22 class AliESDEvent;
23 class AliESDVertex;
24
25 #include "AliAnalysisTaskSE.h"
26
27 class AliAnalysisTaskVertexESD : public AliAnalysisTaskSE 
28 {
29  public:
30
31   AliAnalysisTaskVertexESD(const char *name = "AliAnalysisTaskVertexESD");
32   virtual ~AliAnalysisTaskVertexESD(); 
33   
34   virtual void   UserCreateOutputObjects();
35   virtual void   UserExec(Option_t *option);
36   virtual void   Terminate(Option_t *);
37   void           SetCheckEventType(Bool_t check=kTRUE) {fCheckEventType=check;}
38   Bool_t         GetReadMC() const { return fReadMC; }
39   void           SetReadMC(Bool_t flag=kTRUE) { fReadMC=flag; if(flag) fCheckEventType=kFALSE;}
40   void           SetRerecoVertexTPC(Bool_t flag=kTRUE) { fRecoVtxTPC=flag; }
41   void           SetRerecoVertexITSTPC(Bool_t flag=kTRUE) { fRecoVtxITSTPC=flag; }
42   void           SetRerecoVertexITSTPCHalfEvent(Bool_t flag=kTRUE) { fRecoVtxITSTPCHalfEvent=flag; }
43   void           SetOnlyITSTPCTracks() {fOnlyITSTPCTracks=kTRUE;}
44   void           SetOnlyITSSATracks() {fOnlyITSSATracks=kTRUE;}
45   void           SetFillNtuple(Bool_t fill=kTRUE) {fFillNtuple=fill;}  
46   void           SetFillNtupleBeamSpot(Bool_t fillBeamSpot=kFALSE){fFillTreeBeamSpot = fillBeamSpot;}
47
48  protected:
49   Bool_t       fCheckEventType; // read only events of type 7
50   Bool_t       fReadMC;         // read Monte Carlo
51   Bool_t       fRecoVtxTPC;     // reco TPC vertex on the flight
52   Bool_t       fRecoVtxITSTPC;  // reco ITS+TPC vertex on the flight
53   Bool_t       fRecoVtxITSTPCHalfEvent;  // reco ITS+TPC vertex with even and odd tracks
54   Bool_t       fOnlyITSTPCTracks; // only ITS-TPC tracks to redo ITSTPC vertex
55   Bool_t       fOnlyITSSATracks;  // only ITS-SA tracks to redo ITSTPC vertex
56   Bool_t       fFillNtuple;      // fill ntuple  
57   Bool_t       fFillTreeBeamSpot; //beam spot info in a tree
58   AliESDEvent *fESD;            // ESD object
59   TList       *fOutput;         //! list send on output slot 0
60   TNtuple     *fNtupleVertexESD;//! output ntuple
61   TH1F        *fhSPDVertexX; //! output histo
62   TH1F        *fhSPDVertexY; //! output histo
63   TH1F        *fhSPDVertexZ; //! output histo
64   TH1F        *fhTRKVertexX; //! output histo
65   TH1F        *fhTRKVertexY; //! output histo
66   TH1F        *fhTRKVertexZ; //! output histo
67   TH1F        *fhTPCVertexX; //! output histo
68   TH1F        *fhTPCVertexY; //! output histo
69   TH1F        *fhTPCVertexZ; //! output histo
70   TH2F        *fhTrackRefs;     //! output histo
71   TTree       *fTreeBeamSpot;  //! output tree beam spot
72
73   TH1F        *fhTriggeredTrklets; //! output histo
74   TH1F        *fhSPD3DTrklets; //! output histo
75   TH1F        *fhSPDZTrklets; //! output histo
76   TH1F        *fhTRKTrklets; //! output histo
77   TH1F        *fhTRKcTrklets; //! output histo
78   TH1F        *fhTRKncTrklets; //! output histo
79   TH1F        *fhTPCTrklets; //! output histo
80   TH1F        *fhTPCcTrklets; //! output histo
81   TH1F        *fhTPCncTrklets; //! output histo
82   TH1F        *fhSPD3DZreco; //! output histo
83   TH1F        *fhSPDZZreco; //! output histo
84
85
86   TH1F        *fhSPDVertexXPile; //! output histo
87   TH1F        *fhSPDVertexYPile; //! output histo
88   TH1F        *fhSPDVertexZPile; //! output histo
89   TH1F        *fhSPDVertexDiffZPileContr2; //! output histo
90   TH1F        *fhSPDVertexDiffZPileContr3; //! output histo
91   TH1F        *fhSPDVertexDiffZPileContr4; //! output histo
92   TH1F        *fhSPDVertexDiffZPileContr5; //! output histo
93   TH1F        *fhSPDContributorsPile; //! output histo
94   TH2F        *fhSPDDispContributors; //! output histo
95
96  private:    
97
98   AliAnalysisTaskVertexESD(const AliAnalysisTaskVertexESD&); // not implemented
99   AliAnalysisTaskVertexESD& operator=(const AliAnalysisTaskVertexESD&); // not implemented
100   AliESDVertex* ReconstructPrimaryVertexTPC(Bool_t constr=kFALSE) const;
101   AliESDVertex* ReconstructPrimaryVertexITSTPC(Bool_t constr=kFALSE,Int_t mode=0) const;
102   
103   ClassDef(AliAnalysisTaskVertexESD,9); // primary vertex analysis
104 };
105
106 #endif