1 #ifndef ALIESDCALOCLUSTER_H
2 #define ALIESDCALOCLUSTER_H
3 /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
4 * See cxx source for full Copyright notice */
9 //-------------------------------------------------------------------------
10 // Class AliESDCaloCluster
11 // This is the class to deal with during the physics analysis of data
13 // New container for calorimeter clusters, which are the effective
14 // "tracks" for calorimeter detectors. Can be used by PHOS and EMCAL
17 //-------------------------------------------------------------------------
23 class AliESDCaloCluster : public TObject {
28 AliESDCaloCluster(const AliESDCaloCluster& clus);
29 AliESDCaloCluster & operator=(const AliESDCaloCluster& source);
30 virtual ~AliESDCaloCluster();
32 void SetID(Int_t id) {fID = id;}
33 Int_t GetID() const {return fID;}
35 enum ClusterType {kPseudoCluster, kClusterv1};//Two types of clusters stored
37 void SetClusterType(Int_t type) { fClusterType = type; }
38 Int_t GetClusterType() const {return fClusterType; }
40 void SetEMCAL(Bool_t emc) { fEMCALCluster = emc;}
41 Bool_t IsEMCAL() const {return fEMCALCluster;}
43 void SetPHOS(Bool_t phos) { fPHOSCluster = phos;}
44 Bool_t IsPHOS() const {return fPHOSCluster;}
46 void SetGlobalPosition(const Float_t *pos) {
47 fGlobalPos[0] = pos[0]; fGlobalPos[1] = pos[1]; fGlobalPos[2] = pos[2];
49 void GetGlobalPosition(Float_t *pos) const {
50 pos[0] = fGlobalPos[0]; pos[1] = fGlobalPos[1]; pos[2] = fGlobalPos[2];
53 void SetClusterEnergy(Float_t ene) { fEnergy = ene;}
54 Float_t GetClusterEnergy() const { return fEnergy;}
56 void SetClusterDisp(Float_t disp) { fDispersion = disp; }
57 Float_t GetClusterDisp() const { return fDispersion; }
59 void SetClusterChi2(Float_t chi2) { fChi2 = chi2; }
60 Float_t GetClusterChi2() const { return fChi2; }
62 void SetPid(const Float_t *p);
63 Float_t *GetPid() {return fPID;}
65 void SetPrimaryIndex(Int_t primary) { fPrimaryIndex = primary; }
66 Int_t GetPrimaryIndex() const { return fPrimaryIndex; }
68 void SetM20(Float_t m20) { fM20 = m20; }
69 Float_t GetM20() const { return fM20; }
71 void SetM02(Float_t m02) { fM02 = m02; }
72 Float_t GetM02() const { return fM02; }
74 void SetM11(Float_t m11) { fM11 = m11; }
75 Float_t GetM11() const { return fM11; }
77 void SetNExMax(UShort_t nExMax) { fNExMax = nExMax; }
78 UShort_t GetNExMax() const { return fNExMax; }
80 void SetEmcCpvDistance(Float_t dEmcCpv) { fEmcCpvDistance = dEmcCpv; }
81 Float_t GetEmcCpvDistance() const { return fEmcCpvDistance; }
83 void SetNumberOfDigits(Int_t ndig) { fNumberOfDigits = ndig; }
84 Int_t GetNumberOfDigits() const { return fNumberOfDigits; }
86 void SetDigitAmplitude(UShort_t *adc) { fDigitAmplitude = adc;}
87 UShort_t *GetDigitAmplitude() const { return fDigitAmplitude;}
89 void SetDigitTime(UShort_t *time) { fDigitTime = time;}
90 UShort_t *GetDigitTime() const { return fDigitTime;}
92 void SetDigitIndex(UShort_t *digit) { fDigitIndex = digit;}
93 UShort_t *GetDigitIndex() const { return fDigitIndex; }
97 Int_t fID; // Unique Id of the cluster
98 Int_t fClusterType; // Flag for different clustering versions
99 Bool_t fEMCALCluster; // Is this is an EMCAL cluster?
100 Bool_t fPHOSCluster; // Is this is a PHOS cluster?
101 Float_t fGlobalPos[3]; // position in global coordinate system
102 Float_t fEnergy; // energy measured by calorimeter
103 Float_t fDispersion; // cluster dispersion, for shape analysis
104 Float_t fChi2; // chi2 of cluster fit
105 Float_t fPID[AliPID::kSPECIESN]; //"detector response probabilities" (for the PID)
106 Int_t fPrimaryIndex; // primary track number associated with this cluster
107 Float_t fM20; // 2-nd moment along the main eigen axis
108 Float_t fM02; // 2-nd moment along the second eigen axis
109 Float_t fM11; // 2-nd mixed moment Mxy
110 UShort_t fNExMax ; // number of (Ex-)maxima before unfolding
111 Float_t fEmcCpvDistance; // the distance from PHOS EMC rec.point to the closest CPV rec.point
115 Int_t fNumberOfDigits; // number of calorimeter digits in cluster
116 // Very important! The streamer needs to
117 // know how big these arrays are for
118 // each event that is written out:
119 UShort_t* fDigitAmplitude; //[fNumberOfDigits] digit energy (integer units)
120 UShort_t* fDigitTime; //[fNumberOfDigits] time of this digit (integer units)
121 UShort_t* fDigitIndex; //[fNumberOfDigits] calorimeter digit index
123 ClassDef(AliESDCaloCluster,1) //ESDCaloCluster