]> git.uio.no Git - u/mrichter/AliRoot.git/blob - PWGHF/hfe/AliAnalysisTaskFlowTPCEMCalEP.h
several updates for HFEv2 by TPC-EMCal EP
[u/mrichter/AliRoot.git] / PWGHF / hfe / AliAnalysisTaskFlowTPCEMCalEP.h
1 /**************************************************************************
2  * Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *               
3  *                                                                        *               
4  * Author: The ALICE Off-line Project.                                    *               
5  * Contributors are mentioned in the code where appropriate.              *               
6  *                                                                        *               
7  * Permission to use, copy, modify and distribute this software and its   *               
8  * documentation strictly for non-commercial purposes is hereby granted   *               
9  * without fee, provided that the above copyright notice appears in all   *               
10  * copies and that both the copyright notice and this permission notice   *               
11  * appear in the supporting documentation. The authors make no claims     *               
12  * about the suitability of this software for any purpose. It is          *               
13  * provided "as is" without express or implied warranty.                  *               
14  **************************************************************************/
15
16 #ifndef ALIANALYSISTASKFlowTPCEMCalEP_H
17 #define ALIANALYSISTASKFlowTPCEMCalEP_HAliPIDResponse.h
18
19 class THnSparse;
20 class TH2F;
21 class TLorentzVector;
22
23 class AliEMCALTrack;
24 class AliMagF;
25 class AliESDEvent;
26 class AliAODEvent;
27 class AliVEvent;
28 class AliEMCALGeometry;
29 class AliEMCALRecoUtils;
30 class AliAnalysisFilter;
31 class AliESDtrackCuts;
32 class AliESDtrack;
33 class AliHFEcontainer;
34 class AliHFEcuts;
35 class AliHFEpid;
36 class AliHFEpidQAmanager;
37 class AliCFManager;
38 class AliSelectNonHFE;
39 class AliPIDResponse;
40
41
42 #include "AliAnalysisTaskSE.h"
43
44 class AliAnalysisTaskFlowTPCEMCalEP : public AliAnalysisTaskSE {
45  public:
46   AliAnalysisTaskFlowTPCEMCalEP();
47   AliAnalysisTaskFlowTPCEMCalEP(const char *name);
48   virtual ~AliAnalysisTaskFlowTPCEMCalEP();
49   
50   virtual void   UserCreateOutputObjects();
51   virtual void   UserExec(Option_t *option);
52   virtual void   Terminate(Option_t *);  
53
54   void SetHFECuts(AliHFEcuts * const cuts) { fCuts = cuts; };
55   void SetOpeningAngleCut(Double_t openingAngle) {fOpeningAngleCut = openingAngle;};
56   void SetInvariantMassCut(Double_t invMass) {fInvmassCut = invMass;};
57   void SetNonHFEalgorithm(TString nonHFEalgorithm)  {fnonHFEalgorithm = nonHFEalgorithm;};
58
59   AliHFEpid *GetPID() const { return fPID; }
60   void SetRejectKinkMother(Bool_t rejectKinkMother = kFALSE) { fRejectKinkMother = rejectKinkMother; };
61   void InitParameters();
62   
63   Double_t GetCos2DeltaPhi(Double_t phiA,Double_t phiB)         const;
64   Double_t GetDeltaPhi(Double_t phiA,Double_t phiB)     const;
65   Double_t GetPi0weight(Double_t mcPi0pT,Float_t cent) const;
66   Double_t GetEtaweight(Double_t mcEtapT,Float_t cent) const;
67   Double_t GetDweight(Int_t whichD, Double_t mcDpT, Float_t cent) const;
68
69
70  private:
71   
72   Bool_t ProcessCutStep(Int_t cutStep, AliVParticle *track);
73   
74
75   AliESDEvent                   *fESD;                          //! ESD object
76   AliAODEvent           *fAOD;                  //! AOD object
77   AliVEvent             *fVevent;               //! VEvent
78   AliPIDResponse        *fpidResponse;          //! PID response
79
80   AliMCEvent            *fMC;                   //! MC object
81     
82   TList                         *fOutputList;                   //! output list
83   
84   AliESDtrackCuts       *fTrackCuts;                      //! ESD track cuts
85   AliHFEcuts                    *fCuts;                 //! Cut Collection
86   AliSelectNonHFE       *fNonHFE;               //! Select non heavy flavour electrons
87
88   Bool_t                            fIdentifiedAsOutInz;    //! Out Of Range in z
89   Bool_t                            fPassTheEventCut;       //! Pass The Event Cut
90   Bool_t                            fRejectKinkMother;      //! Reject Kink Mother
91   Bool_t                            fIsMC;                  //! flag for MC analysis   
92   Bool_t                fIsAOD;                 //! flag for AOD analysis
93
94   Double_t                        fVz;                    //! z position of the primary vertex
95   AliCFManager                *fCFM;                  //! Correction Framework Manager
96   AliHFEpid                     *fPID;                  //! PID
97   AliHFEpidQAmanager      *fPIDqa;                          //! PID QA manager
98   Double_t                        fOpeningAngleCut;           //! openingAngle cut for non-HFE selection
99   Double_t                        fInvmassCut;                  //! invariant mass cut  for non-HFE selection
100   Double_t                        fChi2Cut;               //! Chi2 cut  for non-HFE selection
101   Double_t                        fDCAcut;                //! DCA cut  for non-HFE selection
102   Float_t                           fminCent;               //! min centrality
103   Float_t                           fmaxCent;               //! max centrality
104   TString               fnonHFEalgorithm;       //! algorithm to select non-HFE pairs (KF or DCA) 
105
106   TH1F                              *fNoEvents;                   //! no of events
107   TH1F                              *fTrkpt;                        //! track pt
108   TH2F                              *fTrkEovPBef;                       //! track E/p before HFE pid
109   TH2F                              *fTrkEovPAft;                       //! track E/p after HFE pid
110   TH2F                              *fdEdxBef;                    //! track dEdx vs p before HFE pid
111   TH2F                              *fdEdxAft;                    //! track dEdx vs p after HFE pid
112   TH1F                              *fPhotoElecPt;                    //! photonic elec pt 
113   TH1F                              *fSemiInclElecPt;         //! Semi inclusive ele pt
114   THnSparse                       *fMCphotoElecPt;            //! pt distribution (MC)
115   
116   TH1F                              *fTrackPtBefTrkCuts;          //! Track pt before track cuts        
117   TH1F                              *fTrackPtAftTrkCuts;          //! Track pt after track cuts
118   TH2F                              *fTPCnsigma;                        //! TPC n sigma vs p    
119   
120   TH1F                              *fCent;                                 //! centrality
121   TH1F                              *fevPlaneV0A;                       //! V0A event plane distribution
122   TH1F                              *fevPlaneV0C;                       //! V0C event plane distribution
123   TH1F                              *fevPlaneV0;                        //! V0 event plane distribution
124   TH1F                              *fevPlaneTPC;                       //! TPC event plane distribution
125   TH1F                              *fTPCsubEPres;                    //! TPC event plane resolution
126   THnSparse                       *fEPres;                          //! event plane resolution
127   THnSparse                       *fCorr;                                   //! correlations
128   THnSparse                       *feTPCV2;                         //! inclusive eletron v2 (only TPC PID)
129   THnSparse                       *feV2;                                    //! inclusive eletron v2 (TPC + EMCAL PID)
130   THnSparse                       *fphoteV2;                      //! photonic electron v2 (TPC + EMCAL PID)
131   THnSparse                       *fChargPartV2;                      //! charged particle v2
132     
133   TH2F                              *fGammaWeight;                    //! gamma weight
134   TH2F                              *fPi0Weight;                        //! pi0 weight
135   TH2F                              *fEtaWeight;                        //! eta weight
136   TH2F                              *fD0Weight;                   //! D0 weight
137   TH2F                              *fDplusWeight;                    //! D+ weight
138   TH2F                              *fDminusWeight;                   //! D- weight
139   
140   TH1F                              *fDe[6];
141   TH1F                              *fD0e[6];
142   TH1F                              *fDpluse[6];
143   TH1F                              *fDminuse[6];
144   
145   TH2F                              *fD0_e;
146   
147   TH1F                              *fTot_pi0e;                   //! inclusive electron
148   TH1F                              *fPhot_pi0e;                        //! ULS pair 
149   TH1F                              *fPhotBCG_pi0e;                   //! LS pair
150   TH1F                              *fTot_etae;                   //! inclusive electron
151   TH1F                              *fPhot_etae;                        //! ULS pair 
152   TH1F                              *fPhotBCG_etae;                   //! LS pair
153
154   TH1F                  *fInvMass;                        //! Invariant mass of ULS pairs
155   TH1F                  *fInvMassBack;                //! Invariant mass if LS pairs
156   TH1F                  *fDCA;                        //! DCA of ULS pairs
157   TH1F                  *fDCABack;                        //! DCA of LS pairs
158   TH1F                  *fOpAngle;                        //! Opening angle of ULS pairs
159   TH1F                  *fOpAngleBack;                //! Opening angle of LS pairs
160
161
162   AliAnalysisTaskFlowTPCEMCalEP(const AliAnalysisTaskFlowTPCEMCalEP&); // not implemented
163   AliAnalysisTaskFlowTPCEMCalEP& operator=(const AliAnalysisTaskFlowTPCEMCalEP&); // not implemented
164   
165   ClassDef(AliAnalysisTaskFlowTPCEMCalEP, 1); //!example of analysis
166 };
167
168 #endif