]> git.uio.no Git - u/mrichter/AliRoot.git/blob - PWG3/hfe/AliHFEV0cuts.h
Added pass1 and pass2 directories
[u/mrichter/AliRoot.git] / PWG3 / hfe / AliHFEV0cuts.h
1 #ifndef ALIHFEV0CUTS_H
2 #define ALIHFEV0CUTS_H
3
4 /**************************************************************************
5 * Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
6 *                                                                        *
7 * Author: The ALICE Off-line Project.                                    *
8 * Contributors are mentioned in the code where appropriate.              *
9 *                                                                        *
10 * Permission to use, copy, modify and distribute this software and its   *
11 * documentation strictly for non-commercial purposes is hereby granted   *
12 * without fee, provided that the above copyright notice appears in all   *
13 * copies and that both the copyright notice and this permission notice   *
14 * appear in the supporting documentation. The authors make no claims     *
15 * about the suitability of this software for any purpose. It is          *
16 * provided "as is" without express or implied warranty.                  *
17 **************************************************************************/
18
19 /* $Id$ */ 
20
21 //
22 // Class for the V0 cuts - tuned to obtain clean eletron, pion and proton samples.
23 // NOT suitable for V0 analysis
24 //
25 #include "AliHFEcollection.h"
26
27 class TList;
28
29 class AliMCParticle;
30 class AliVEvent;
31 class AliMCEvent;
32 class AliESDtraack;
33 class AliESDv0;
34 class AliKFVertex;
35 class AliKFParticle;
36 class AliVTrack;
37
38 class AliHFEV0cuts : public TObject {
39  public:
40   enum{ // Reconstructed V0
41     kUndef = 0,
42       kRecoGamma = 1,
43       kRecoK0 = 2,
44       kRecoPhi = 3,
45       kRecoLambda = 4,
46       kRecoALambda = -4
47       
48       };
49   enum{ // Identified Daughter particles
50     kRecoElectron = 0,
51       kRecoPionK0 = 1,
52       kRecoPionL = 2,
53       kRecoKaon = 3,
54       kRecoProton = 4
55       };
56   AliHFEV0cuts();
57   ~AliHFEV0cuts();
58   AliHFEV0cuts(const AliHFEV0cuts &ref);
59   AliHFEV0cuts &operator=(const AliHFEV0cuts &ref);
60
61   void Init(const char* name);
62   
63   void RunQA();
64   void SetMCEvent(AliMCEvent* const mce)      { fMCEvent = mce; };
65   void SetInputEvent(AliVEvent* const e)      { fInputEvent = e; };
66   void SetPrimaryVertex(AliKFVertex* const v) { fPrimaryVertex = v; };
67   
68   TList* GetList()    { return fQA->GetList(); };
69   TList* GetListMC()  { return fQAmc->GetList(); };
70   
71   Bool_t   TrackCutsCommon(AliESDtrack* track);
72   Bool_t   V0CutsCommon(AliESDv0 *v0);
73   Bool_t   GammaCuts(AliESDv0 *v0);
74   Bool_t   K0Cuts(AliESDv0 *v0);
75   Bool_t   LambdaCuts(AliESDv0 *v0, Bool_t &isLambda);
76  
77   Bool_t LooseRejectK0(AliESDv0 * const v0) const;
78   Bool_t LooseRejectLambda(AliESDv0 * const v0) const;
79   Bool_t LooseRejectGamma(AliESDv0 * const v0) const;
80
81   void     Armenteros(AliESDv0 *v0, Float_t val[2]);
82
83   Double_t OpenAngle(AliESDv0 *v0) const;//opening angle between V0 daughters; close to zero for conversions
84   Double_t PsiPair(AliESDv0 *v0);
85   
86   Bool_t   CheckSigns(AliESDv0* const v0);
87   Bool_t   GetConvPosXY(AliESDtrack * const ptrack, AliESDtrack * const ntrack, Double_t convpos[2]);
88   Bool_t   GetHelixCenter(AliESDtrack * const track, Double_t b,Int_t charge, Double_t center[2]);
89
90
91   // MC stuff
92   void     SetCurrentV0id(Int_t id) { fCurrentV0id = id; };
93   void     SetDaughtersID(Int_t d[2]) {fPdaughterPDG = d[0]; fNdaughterPDG = d[1]; };
94   
95   AliKFParticle *CreateMotherParticle(AliVTrack* const pdaughter, AliVTrack* const ndaughter, Int_t pspec, Int_t nspec);
96
97  private:
98   void Copy(TObject &ref) const;
99       
100  private:
101   
102   AliHFEcollection     *fQA;            // store QA cut histograms
103   AliHFEcollection     *fQAmc;          // store 
104   AliMCEvent           *fMCEvent;       // MC event
105   AliVEvent            *fInputEvent;    // Input Event
106   AliKFVertex          *fPrimaryVertex; // primary vertex
107
108   Int_t                fCurrentV0id;   // MC flagged V0    
109   Int_t                fPdaughterPDG;   // MC id of the positive daugeter
110   Int_t                fNdaughterPDG;   // MC id of the negative daugeter
111
112
113   ClassDef(AliHFEV0cuts, 1)
114 };
115     
116
117 #endif