]> git.uio.no Git - u/mrichter/AliRoot.git/blame - PWGLF/STRANGENESS/Hypernuclei/AliAODMCNuclExReplicator.h
Adding Tasks to create NuclexAOD from MC productions and first Task to read Nuclex AOD
[u/mrichter/AliRoot.git] / PWGLF / STRANGENESS / Hypernuclei / AliAODMCNuclExReplicator.h
CommitLineData
36f902bc 1#ifndef ALIAODMCNUCLEXREPLICATOR_H
2#define ALIAODMCNUCLEXREPLICATOR_H
3
4/* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
5* See cxx source for full Copyright notice */
6
7#ifndef ALIDAODBRANCHREPLICATOR_H
8# include "AliAODBranchReplicator.h"
9#endif
10#ifndef ROOT_TExMap
11# include "TExMap.h"
12#endif
13
14
15//
16// Implementation of a branch replicator
17// to produce aods with only few branches.
18//
19// Authors: S. Bufalino (stefania.bufalino@cern.ch)
20// R. Lea (ramona.lea@cern.ch)
21//
22// Based on AliAODMuonReplicator.h (L. Aphecetche (Subatech))
23
24//class AliAnalysisCuts;
25class TClonesArray;
26class AliAODMCHeader;
27class AliAODVZERO;
28class AliAODTZERO;
29//class AliPIDResponse;
30class AliESDv0;
31class TArrayI;
32class AliAODv0;
33class TRefArray;
34class AliAODRecoDecay;
35class AliAODRecoDecayLF;
36class AliAODRecoDecayLF2Prong;
37class AliVertexerTracks;
38class AliAODHeader;
39
40class AliESDVertex;
41class AliESDtrack;
42class AliVEvent;
43class AliAODVertex;
44class AliVertexerTracks;
45class AliESDv0;
46class AliAODv0;
47
48class TH1F;
49
50// TODO add new constructor for the 3 prong case (it will write an AliAODRecoDecayLF3Prong
51
52class AliAODMCNuclExReplicator : public AliAODBranchReplicator
53{
54 public:
55
56 AliAODMCNuclExReplicator(const char* name="AliAODMCNuclExReplicator",
57 const char* title="Branch Replicator for muon related branches",
58 /* AliAnalysisCuts* trackCut=0x0, */
59 /* AliAnalysisCuts* vertexCut=0x0, */
60 Int_t mcMode=0,
61 Int_t nsigmaTrk1=3, Int_t partType1 = 2,
62 Int_t nsigmaTrk2=3, Int_t partType2 = 7
63 );
64 // Int_t partType; // 0 = e; 1 = mu; 2 = pi; 3 = K; 4= p; 5 = d; 6 =t ; 7 = 3He; 8=4He;
65
66 virtual ~AliAODMCNuclExReplicator();
67
68 virtual TList* GetList() const;
69
70 virtual void ReplicateAndFilter(const AliAODEvent& source);
71
72 virtual void Terminate();
73
74 private:
75
76 // TO DO : Implemet MC
77 // void FilterMC(const AliAODEvent& source);
78 void SelectParticle(Int_t i);
79 Bool_t IsParticleSelected(Int_t i);
80 void CreateLabelMap(const AliAODEvent& source);
81 Int_t GetNewLabel(Int_t i);
82
83
84 Double_t fBzkG; // z componenent of field in kG
85
86 Double_t fCosMin ;
87 Double_t fDCAtracksMin ;
88 Double_t fRmax ;
89 Double_t fRmin ;
90 Double_t fDNmin ;
91 Double_t fDPmin ;
92
93 private:
94
95 mutable AliAODHeader* fHeader; //! internal header object
96
97 // AliAnalysisCuts* fVertexCut; // decides which vertices to keep
98 mutable TClonesArray* fVertices; //! internal array of vertices
99
100 mutable TClonesArray* fNuclei; //! internal array of nuclei tracks
101
102 // AliAnalysisCuts* fTrackCut; // decides which tracks to keep
103 mutable TClonesArray* fSecondaryVerices; //! internal array of secondary vertices canditates
104
105 mutable TClonesArray* fDaughterTracks; //! internal SV daughter tracks
106
107
108
109 mutable TList* fList; //! internal list of managed objects (fVertices and fTracks)
110
111 mutable TClonesArray* fMCParticles; //! internal array of MC particles
112 mutable AliAODMCHeader* fMCHeader; //! internal array of MC header
113 Int_t fMCMode; // MC filtering switch (0=none=no mc information,1=normal=simple copy,>=2=aggressive=filter out)
114
115 TExMap fLabelMap; //! for MC label remapping (in case of aggressive filtering)
116 TExMap fParticleSelected; //! List of selected MC particles
117
118 Bool_t fReplicateHeader; //! whether or not the replicate the AOD Header
119
120 Int_t fnSigmaTrk1;
121 Int_t fnSigmaTrk2;
122 Int_t fpartType1;
123 Int_t fpartType2;
124
125
126
127 Bool_t fSecVtxWithKF; // if kTRUE use KF vertexer, else AliVertexerTracks
128 AliVertexerTracks* fVertexerTracks; // vertexer, to compute secondary vertices
129 AliESDVertex *fV1; // primary vertex
130
131 Int_t fAODMapSize; // size of fAODMap
132 Int_t *fAODMap; //[fAODMapSize] map between index and ID for AOD tracks
133
134 AliAODVertex* ReconstructSecondaryVertex(TObjArray *trkArray,Double_t &dispersion,Bool_t useTRefArray=kTRUE) const;
135
136 AliAODRecoDecayLF2Prong* Make2Prong(TObjArray *twoTrackArray,const AliAODEvent &evento,
137 AliAODVertex *secVert,Double_t dca);
138
139 /* AliAODRecoDecayLF2Prong* Make2Prong(TObjArray *twoTrackArray,AliAODEvent *evento, */
140 /* AliAODVertex *secVert,Double_t dca); */
141
142
143 void AddDaughterRefs(AliAODVertex *v, const AliAODEvent &event, const TObjArray *trkArray) const;
144 /* void AddDaughterRefs(AliAODVertex *v, AliAODEvent *event, const TObjArray *trkArray) const; */
145 void AddRefs(AliAODVertex *v,AliAODRecoDecayLF *rd, const AliAODEvent &event, const TObjArray *trkArray) const;
146 /* void AddRefs(AliAODVertex *v,AliAODRecoDecayLF *rd, AliAODEvent *event, const TObjArray *trkArray) const; */
147
148 private:
149
150 // AliPIDResponse *fPIDResponse; //! PID response object
151
152 AliAODMCNuclExReplicator(const AliAODMCNuclExReplicator&);
153 AliAODMCNuclExReplicator& operator=(const AliAODMCNuclExReplicator&);
154
155 ClassDef(AliAODMCNuclExReplicator,5) // Branch replicator for ESD to muon AOD.
156 };
157
158#endif