AliRoot Core  3abf5b4 (3abf5b4)
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
AliMFTCluster.h
Go to the documentation of this file.
1 #ifndef AliMFTCluster_H
2 #define AliMFTCluster_H
3 
4 /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
5  * See cxx source for full Copyright notice */
6 
7 //====================================================================================================================================================
8 //
9 // Class for the description of the clusters of the ALICE Muon Forward Tracker
10 //
11 // Contact author: antonio.uras@cern.ch
12 //
13 //====================================================================================================================================================
14 
15 #include "AliMUONRawCluster.h"
16 #include "AliMUONVCluster.h"
17 #include "AliMFTDigit.h"
18 #include "TClonesArray.h"
19 #include "TObject.h"
20 #include "AliMFTConstants.h"
21 
22 //====================================================================================================================================================
23 
24 class AliMFTCluster : public TObject {
25 
26 public:
27 
28  AliMFTCluster();
32 
33  virtual void Clear(const Option_t* /*opt*/) { if(fDigitsInCluster) {fDigitsInCluster->Delete(); delete fDigitsInCluster; fDigitsInCluster = 0x0;} }
34 
35  void SetXYZ(Double_t x, Double_t y, Double_t z) { fX=x; fY=y; fZ=z; }
36 
37  void SetX(Double_t x) { if(fIsClusterEditable) fX = x; }
38  void SetY(Double_t y) { if(fIsClusterEditable) fY = y; }
39  void SetZ(Double_t z) { if(fIsClusterEditable) fZ = z; }
40 
41  Double_t GetX() const { return fX; }
42  Double_t GetY() const { return fY; }
43  Double_t GetZ() const { return fZ; }
44 
45  void SetErrXYZ(Double_t errX, Double_t errY, Double_t errZ) { if(fIsClusterEditable) { fErrX = errX; fErrY = errY; fErrZ = errZ; } }
46 
47  void SetErrX(Double_t errX) { if(fIsClusterEditable) fErrX = errX; }
48  void SetErrY(Double_t errY) { if(fIsClusterEditable) fErrY = errY; }
49  void SetErrZ(Double_t errZ) { if(fIsClusterEditable) fErrZ = errZ; }
50 
51  Double_t GetErrX() const { return fErrX; }
52  Double_t GetErrY() const { return fErrY; }
53  Double_t GetErrZ() const { return fErrZ; }
54  Double_t GetErrX2() const { return fErrX*fErrX; }
55  Double_t GetErrY2() const { return fErrY*fErrY; }
56  Double_t GetErrZ2() const { return fErrZ*fErrZ; }
57 
58  void SetNElectrons(Double_t nElectrons) { if(fIsClusterEditable) fNElectrons = nElectrons; }
59  Double_t GetNElectrons() const { return fNElectrons; }
60 
61  void AddMCLabel(Int_t label);
62  Int_t GetNMCTracks() const { return fNMCTracks; }
63  Int_t GetMCLabel(Int_t track) const { if (track<fNMCTracks && track>=0) return fMCLabel[track]; else return -1; }
64  void SetMCLabel(Int_t track, Int_t labelMC) { if (track<fNMCTracks && track>=0) fMCLabel[track]=labelMC; }
65 
66  void SetPlane(Int_t plane) { if(fIsClusterEditable) fPlane = plane; }
67  Int_t GetPlane() const { return fPlane; }
68 
69  void SetDetElemID(Int_t detElemID) { fDetElemID = detElemID; }
70  Int_t GetDetElemID() { return fDetElemID; }
71 
72  void SetSize(Int_t size) { if(fIsClusterEditable) fSize = size; }
73  Int_t GetSize() const { return fSize; }
74 
75  void SetLocalChi2(Double_t chi2) { fLocalChi2 = chi2; }
76  void SetTrackChi2(Double_t chi2) { fTrackChi2 = chi2; }
77 
78  Double_t GetLocalChi2() { return fLocalChi2; }
79  Double_t GetTrackChi2() { return fTrackChi2; }
80 
81  Bool_t AddPixel(AliMFTDigit *pixel);
82 
84  void SetClusterEditable(Bool_t isClusterEditable) { fIsClusterEditable = isClusterEditable; }
85  void TerminateCluster();
86 
87  Double_t GetDistanceFromPixel(AliMFTDigit *pixel);
88 
89  void SetClusterFront(Bool_t clusterFront) { if(fIsClusterEditable) fIsClusterFront = clusterFront; }
90  Bool_t IsClusterFront() { return fIsClusterFront; }
91 
93 
94 private:
95 
98 
99  Double_t fX, fY, fZ; // cluster global coordinates
100  Double_t fErrX, fErrY, fErrZ;
101 
102  Double_t fNElectrons;
103  Int_t fNMCTracks;
106 
107  Int_t fSize; // the number of digits composing the cluster
108 
109  Double_t fTrackChi2; // Chi2 of the track when the associated cluster was attached
110  Double_t fLocalChi2; // Local chi2 of the associated cluster with respect to the track
111 
112  TClonesArray *fDigitsInCluster;
113 
115 
116  ClassDef(AliMFTCluster, 1)
117 
118 };
119 
120 //====================================================================================================================================================
121 
122 #endif
123 
Bool_t fIsClusterEditable
(Temporary) Array of the digits composing the cluster
Double_t fErrY
void SetSize(Int_t size)
Definition: AliMFTCluster.h:72
static const Int_t fNMaxMCTracksPerCluster
max number of MC tracks sharing the same MFT cluster
void SetPlane(Int_t plane)
Definition: AliMFTCluster.h:66
void TerminateCluster()
Int_t GetSize() const
Definition: AliMFTCluster.h:73
Double_t GetErrZ2() const
Definition: AliMFTCluster.h:56
void SetZ(Double_t z)
Definition: AliMFTCluster.h:39
Int_t GetDetElemID()
Definition: AliMFTCluster.h:70
Double_t GetNElectrons() const
Definition: AliMFTCluster.h:59
Double_t fTrackChi2
Double_t GetY() const
Definition: AliMFTCluster.h:42
Double_t GetTrackChi2()
Definition: AliMFTCluster.h:79
AliTPCfastTrack * track
Double_t GetErrX2() const
Definition: AliMFTCluster.h:54
void SetY(Double_t y)
Definition: AliMFTCluster.h:38
virtual void Clear(const Option_t *)
Definition: AliMFTCluster.h:33
Bool_t IsClusterEditable()
Definition: AliMFTCluster.h:83
Bool_t IsClusterFront()
Definition: AliMFTCluster.h:90
void SetMCLabel(Int_t track, Int_t labelMC)
Definition: AliMFTCluster.h:64
static const Int_t fNMaxDigitsPerCluster
Definition: AliMFTCluster.h:97
Double_t fErrZ
void AddMCLabel(Int_t label)
Int_t GetNMCTracks() const
Definition: AliMFTCluster.h:62
void SetNElectrons(Double_t nElectrons)
Definition: AliMFTCluster.h:58
AliMUONRawCluster * CreateMUONCluster()
Double_t chi2
Definition: AnalyzeLaser.C:7
virtual ~AliMFTCluster()
Definition: AliMFTCluster.h:31
Int_t fMCLabel[fNMaxMCTracks]
Double_t GetDistanceFromPixel(AliMFTDigit *pixel)
void SetLocalChi2(Double_t chi2)
Definition: AliMFTCluster.h:75
MUON raw cluster.
Double_t GetX() const
Definition: AliMFTCluster.h:41
Double_t GetErrZ() const
Definition: AliMFTCluster.h:53
Double_t GetErrY() const
Definition: AliMFTCluster.h:52
void SetXYZ(Double_t x, Double_t y, Double_t z)
Definition: AliMFTCluster.h:35
Bool_t fIsClusterFront
void SetErrX(Double_t errX)
Definition: AliMFTCluster.h:47
void SetClusterFront(Bool_t clusterFront)
Definition: AliMFTCluster.h:89
Double_t GetErrY2() const
Definition: AliMFTCluster.h:55
Double_t GetErrX() const
Definition: AliMFTCluster.h:51
void SetTrackChi2(Double_t chi2)
Definition: AliMFTCluster.h:76
void SetErrZ(Double_t errZ)
Definition: AliMFTCluster.h:49
void SetErrY(Double_t errY)
Definition: AliMFTCluster.h:48
Double_t fErrX
Bool_t AddPixel(AliMFTDigit *pixel)
void SetDetElemID(Int_t detElemID)
Definition: AliMFTCluster.h:69
void SetX(Double_t x)
Definition: AliMFTCluster.h:37
static const Int_t fNMaxDigitsPerCluster
max number of digits per cluster
Double_t GetZ() const
Definition: AliMFTCluster.h:43
Double_t fLocalChi2
TClonesArray * fDigitsInCluster
static const Int_t fNMaxMCTracks
Definition: AliMFTCluster.h:96
void SetErrXYZ(Double_t errX, Double_t errY, Double_t errZ)
Definition: AliMFTCluster.h:45
Int_t GetMCLabel(Int_t track) const
Definition: AliMFTCluster.h:63
Double_t fNElectrons
void SetClusterEditable(Bool_t isClusterEditable)
Definition: AliMFTCluster.h:84
Int_t GetPlane() const
Definition: AliMFTCluster.h:67
AliMFTCluster & operator=(const AliMFTCluster &)
Double_t GetLocalChi2()
Definition: AliMFTCluster.h:78