]>
Commit | Line | Data |
---|---|---|
1 | #ifndef ALIEMCALRECPOINT_H | |
2 | #define ALIEMCALRECPOINT_H | |
3 | /* Copyright(c) 1998-2007, ALICE Experiment at CERN, All rights reserved. * | |
4 | * See cxx source for full Copyright notice */ | |
5 | //_________________________________________________________________________ | |
6 | // Base Class for EMCAL Reconstructed Points | |
7 | // A recpoint being equivalent to a cluster in encal terminology | |
8 | //*-- Author: Yves Schutz (SUBATECH) | |
9 | //*-- Author: Dmitri Peressounko (RRC KI & SUBATECH) | |
10 | //*-- Author: Heather Gray (LBL): merged AliEMCALRecPoint and AliEMCALTowerRecPoint 02/04 | |
11 | ||
12 | // --- ROOT system --- | |
13 | #include <TVector3.h> | |
14 | class TGeoManager; | |
15 | class TGeoPhysicalNode; | |
16 | class TPad; | |
17 | class TPaveText; | |
18 | class TGraph; | |
19 | class Riostream; | |
20 | ||
21 | // --- Standard library --- | |
22 | ||
23 | // --- AliRoot header files --- | |
24 | ||
25 | #include "AliCluster.h" | |
26 | class AliEMCALDigit; | |
27 | class AliDigitNew; | |
28 | class AliEMCALGeometry; | |
29 | class AliEMCALHit; | |
30 | ||
31 | class AliEMCALRecPoint : public AliCluster { | |
32 | ||
33 | public: | |
34 | ||
35 | typedef TObjArray RecPointsList ; | |
36 | ||
37 | AliEMCALRecPoint() ; // ctor | |
38 | AliEMCALRecPoint(const char * opt) ; // ctor | |
39 | AliEMCALRecPoint(const AliEMCALRecPoint & rp); | |
40 | ||
41 | AliEMCALRecPoint& operator= (const AliEMCALRecPoint &rp); | |
42 | ||
43 | virtual ~AliEMCALRecPoint(); | |
44 | ||
45 | virtual void AddDigit(AliDigitNew &) const { | |
46 | Fatal("AddDigit", "use AddDigit(AliEMCALDigit & digit, Float_t Energy )") ; | |
47 | } | |
48 | virtual void AddDigit(AliEMCALDigit & digit, Float_t Energy); | |
49 | virtual Int_t Compare(const TObject * obj) const; | |
50 | virtual Int_t DistancetoPrimitive(Int_t px, Int_t py); | |
51 | virtual void Draw(Option_t * option="") ; | |
52 | virtual void ExecuteEvent(Int_t event, Int_t, Int_t) ; | |
53 | ||
54 | virtual void SetClusterType(Int_t ver) { fClusterType = ver; } | |
55 | virtual Int_t GetClusterType() const { return fClusterType; } | |
56 | ||
57 | virtual void EvalAll(Float_t logWeight, TClonesArray * digits); | |
58 | virtual void EvalLocalPosition(Float_t logWeight, TClonesArray * digits); | |
59 | virtual void EvalPrimaries(TClonesArray * digits) ; | |
60 | virtual void EvalParents(TClonesArray * digits) ; | |
61 | ||
62 | virtual int * GetDigitsList(void) const { return fDigitsList ; } | |
63 | virtual Float_t GetEnergy() const {return fAmp; } | |
64 | ||
65 | void EvalLocal2TrackingCSTransform(); | |
66 | void EvalLocalPositionFit(Double_t deff, Double_t w0, Double_t phiSlope,TClonesArray * digits); | |
67 | Bool_t EvalLocalPosition2(TClonesArray *digits, TArrayD &ed); | |
68 | ||
69 | static Bool_t EvalLocalPositionFromDigits(const Double_t esum, const Double_t deff, const Double_t w0, | |
70 | TClonesArray *digits, TArrayD &ed, TVector3 &locPos); | |
71 | static Bool_t EvalLocalPositionFromDigits(TClonesArray *digits, TArrayD &ed, TVector3 &locPos); | |
72 | static void GetDeffW0(const Double_t esum, Double_t &deff, Double_t &w0); | |
73 | ||
74 | virtual void GetGlobalPosition(TVector3 & gpos, TMatrixF & gmat) const; // return global position (x, y, z) in ALICE | |
75 | virtual void GetGlobalPosition(TVector3 & gpos) const; // return global position (x, y, z) in ALICE | |
76 | virtual void GetLocalPosition(TVector3 & lpos) const; // return local position (x, y, z) in EMCAL SM | |
77 | virtual Int_t * GetPrimaries(Int_t & number) const {number = fMulTrack ; | |
78 | return fTracksList ; } | |
79 | virtual Int_t * GetParents(Int_t & number) const {number = fMulParent ; | |
80 | return fParentsList ; } | |
81 | ||
82 | virtual Int_t GetDigitsMultiplicity(void) const { return fMulDigit ; } | |
83 | Int_t GetIndexInList() const { return fIndexInList ; } | |
84 | ||
85 | Float_t GetCoreEnergy()const {return fCoreEnergy ;} | |
86 | virtual Float_t GetDispersion()const {return fDispersion ;} | |
87 | virtual void GetElipsAxis(Float_t * lambda)const {lambda[0] = fLambda[0]; lambda[1] = fLambda[1];}; | |
88 | ||
89 | Float_t * GetEnergiesList() const {return fEnergyList ;} // gets the list of energies making this recpoint | |
90 | Double_t GetPointEnergy() const; // gets point energy (sum of energy list) | |
91 | Float_t * GetTimeList() const {return fTimeList ;} // gets the list of digit times in this recpoint | |
92 | Float_t GetMaximalEnergy(void) const ; // get the highest energy in the cluster | |
93 | Int_t GetMaximumMultiplicity() const {return fMaxDigit ;} // gets the maximum number of digits allowed | |
94 | Int_t GetMultiplicity(void) const { return fMulDigit ; } // gets the number of digits making this recpoint | |
95 | Int_t GetMultiplicityAtLevel(Float_t level) const ; // computes multiplicity of digits with | |
96 | Int_t * GetAbsId() const {return fAbsIdList;} | |
97 | Int_t GetAbsId(int i) const {if(i>=0 && i<fMulDigit)return fAbsIdList[i]; else return -1;} | |
98 | Int_t GetAbsIdMaxDigit() const {return GetAbsId(fDigitIndMax);} | |
99 | Int_t GetIndMaxDigit() const {return fDigitIndMax;} | |
100 | void SetIndMaxDigit(const Int_t ind) {fDigitIndMax = ind;} | |
101 | void SetIndexInList(Int_t val) { fIndexInList = val ; } | |
102 | ||
103 | virtual Int_t GetSuperModuleNumber(void) const { return fSuperModuleNumber;} | |
104 | ||
105 | // energy above relative level | |
106 | virtual Int_t GetNumberOfLocalMax(AliEMCALDigit ** maxAt, Float_t * maxAtEnergy, | |
107 | Float_t locMaxCut,TClonesArray * digits ) const ; | |
108 | // searches for the local maxima | |
109 | ||
110 | Int_t GetPrimaryIndex() const ; | |
111 | Float_t GetTime(void) const{return fTime ; } | |
112 | ||
113 | virtual Bool_t IsEmc(void)const { return kTRUE ; } | |
114 | virtual Bool_t IsSortable() const { | |
115 | // tells that this is a sortable object | |
116 | return kTRUE ; | |
117 | } | |
118 | virtual void Paint(Option_t * option=""); | |
119 | virtual void Print(Option_t * option="") const ; | |
120 | ||
121 | static Double_t TmaxInCm(const Double_t e=0.0, const Int_t key=0); | |
122 | ||
123 | protected: | |
124 | void EvalCoreEnergy(Float_t logWeight,TClonesArray * digits) ; | |
125 | virtual void EvalDispersion(Float_t logWeight,TClonesArray * digits) ; // computes the dispersion of the shower | |
126 | virtual void EvalElipsAxis(Float_t logWeight, TClonesArray * digits ); // computes the axis of shower ellipsoide | |
127 | void EvalTime( TClonesArray * digits ); | |
128 | virtual Bool_t AreNeighbours(AliEMCALDigit * digit1, AliEMCALDigit * digit2 ) const; | |
129 | Float_t ThetaToEta(Float_t arg) const; //Converts Theta (Radians) to Eta(Radians) | |
130 | Float_t EtaToTheta(Float_t arg) const; //Converts Eta (Radians) to Theta(Radians) | |
131 | ||
132 | private: | |
133 | ||
134 | //JLK do we need this? | |
135 | AliEMCALGeometry* fGeomPtr; //! Pointer to geometry for utilities | |
136 | ||
137 | Float_t fAmp ; // summed amplitude of digits | |
138 | Int_t fIndexInList ; // the index of this RecPoint in the | |
139 | // list stored in TreeR (to be set by analysis) | |
140 | TVector3 fLocPos ; // local position in the sub-detector coordinate | |
141 | TMatrixF * fLocPosM ; // covariance matrix ; | |
142 | Int_t fMaxDigit ; //! max initial size of digits array (not saved) | |
143 | Int_t fMulDigit ; // total multiplicity of digits | |
144 | Int_t fMaxTrack ; //! max initial size of tracks array (not saved) | |
145 | Int_t fMulTrack ; // total multiplicity of tracks | |
146 | Int_t * fDigitsList ; //[fMulDigit] list of digit's indexes from which the point was reconstructed | |
147 | Int_t * fTracksList ; //[fMulTrack] list of tracks to which the point was assigned | |
148 | ||
149 | Int_t fClusterType; // type of cluster stored: pseudocluster or v1 | |
150 | Float_t fCoreEnergy ; // energy in a shower core | |
151 | Float_t fLambda[2] ; // shower ellipse axes | |
152 | Float_t fDispersion ; // shower dispersion | |
153 | Float_t *fEnergyList ; //[fMulDigit] energy of digits | |
154 | Float_t *fTimeList ; //[fMulDigit] time of digits | |
155 | Int_t *fAbsIdList; //[fMulDigit] absId of digits | |
156 | Float_t fTime ; // Time of the digit with maximal energy deposition | |
157 | Float_t fCoreRadius; // The radius in which the core energy is evaluated | |
158 | Float_t *fDETracksList ; //[fMulTrack] list of tracks to which the point was assigned | |
159 | Int_t fMulParent; // Multiplicity of the parents | |
160 | Int_t fMaxParent; // Maximum number of parents allowed | |
161 | Int_t * fParentsList; // [fMulParent] list of the parents of the digits | |
162 | Float_t * fDEParentsList; // [fMulParent] list of the parents of the digits | |
163 | Int_t fSuperModuleNumber; // number identifying supermodule containing recpoint | |
164 | // Aug 16, 2007 | |
165 | Int_t fDigitIndMax; // Index of digit with max energy in array fAbsIdList | |
166 | ||
167 | ClassDef(AliEMCALRecPoint,10) // RecPoint for EMCAL (Base Class) | |
168 | ||
169 | }; | |
170 | ||
171 | #endif // AliEMCALRECPOINT_H |