3 /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
4 * See cxx source for full Copyright notice */
8 ////////////////////////////////////////////////
9 // Manager and hits classes for set: TRD //
10 ////////////////////////////////////////////////
12 #include "AliDetector.h"
15 #include "AliTRDconst.h"
17 //_____________________________________________________________________________
18 class AliTRD : public AliDetector {
21 Int_t fGasMix; // Gas mixture. 0: Xe/Isobutane 1: Xe/CO2
23 Float_t fClengthI[kNplan]; // Length of the inner chambers
24 Float_t fClengthM1[kNplan]; // Length of the middle chambers
25 Float_t fClengthM2[kNplan]; //
26 Float_t fClengthO1[kNplan]; // Length of the outer chambers
27 Float_t fClengthO2[kNplan]; //
28 Float_t fClengthO3[kNplan]; //
29 Float_t fCwidth[kNplan]; // Width of the chambers
31 Int_t fRowMax[kNplan][kNcham][kNsect]; // Number of pad-rows
32 Int_t fColMax[kNplan]; // Number of pad-columns
33 Int_t fTimeMax; // Number of time buckets
35 Float_t fRow0[kNplan][kNcham][kNsect]; // Row-position of pad 0
36 Float_t fCol0[kNplan]; // Column-position of pad 0
37 Float_t fTime0[kNplan]; // Time-position of pad 0
39 Float_t fRowPadSize; // Pad size in z-direction
40 Float_t fColPadSize; // Pad size in rphi-direction
41 Float_t fTimeBinSize; // Size of the time buckets
43 Int_t fHole; // Geometry without (0) / with (1) hole
45 TClonesArray *fClusters; // List of clusters
46 Int_t fNclusters; // Number of clusters
50 AliTRD(const char *name, const char *title);
52 virtual void AddHit(Int_t, Int_t*, Float_t*);
53 virtual void AddDigit(Int_t*, Int_t*);
54 virtual void AddCluster(Int_t*, Int_t*, Float_t*);
55 virtual void BuildGeometry();
56 virtual void CreateGeometry();
57 virtual void CreateMaterials();
58 virtual void DrawModule();
59 Int_t DistancetoPrimitive(Int_t px, Int_t py);
60 TClonesArray *Cluster() { return fClusters; };
62 virtual Int_t IsVersion() const = 0;
63 virtual void MakeBranch(Option_t* option);
64 virtual void StepManager() = 0;
65 virtual void SetTreeAddress();
67 virtual void SetHits(Int_t ) {};
68 virtual void SetSensPlane(Int_t) {};
69 virtual void SetSensChamber(Int_t) {};
70 virtual void SetSensSector(Int_t ) {};
72 virtual void SetGasMix(Int_t imix = 0);
74 virtual void SetRowPadSize(Float_t size) { fRowPadSize = size; };
75 virtual void SetColPadSize(Float_t size) { fColPadSize = size; };
76 virtual void SetTimeBinSize(Float_t size) { fTimeBinSize = size; };
78 virtual Float_t GetRowPadSize() { return fRowPadSize; };
79 virtual Float_t GetColPadSize() { return fColPadSize; };
80 virtual Float_t GetTimeBinSize() { return fTimeBinSize; };
82 virtual Int_t GetRowMax(Int_t p, Int_t c, Int_t s) { return fRowMax[p-1][c-1][s-1]; };
83 virtual Int_t GetColMax(Int_t p) { return fColMax[p-1]; };
84 virtual Int_t GetTimeMax() { return fTimeMax; };
86 virtual Int_t Hole() { return fHole; };
88 ClassDef(AliTRD,1) // Transition Radiation Detector base class
92 //_____________________________________________________________________________
93 class AliTRDhit : public AliHit {
96 Int_t fSector; // TRD sector number
97 Int_t fChamber; // TRD chamber number
98 Int_t fPlane; // TRD plane number
99 Float_t fQ; // Charge created by a hit (slow simulator only)
103 AliTRDhit(Int_t shunt, Int_t track, Int_t *vol, Float_t *hits);
104 virtual ~AliTRDhit() {};
106 ClassDef(AliTRDhit,1) // Hits for Transition Radiation Detector
110 //_____________________________________________________________________________
111 class AliTRDdigit : public AliDigit {
114 Int_t fSector; // TRD sector number
115 Int_t fChamber; // TRD chamber number
116 Int_t fPlane; // TRD plane number
117 Int_t fRow; // Pad row number
118 Int_t fCol; // Pad col number
119 Int_t fTime; // Time bucket
120 Int_t fSignal; // Signal amplitude
124 AliTRDdigit(Int_t *tracks, Int_t *digits);
125 virtual ~AliTRDdigit() {};
127 ClassDef(AliTRDdigit,1) // Digits for Transition Radiation Detector
131 //_____________________________________________________________________________
132 class AliTRDcluster : public TObject {
135 Int_t fSector; // TRD sector number
136 Int_t fChamber; // TRD chamber number
137 Int_t fPlane; // TRD plane number
139 Int_t fTimeSlice; // Timeslice in chamber where cluster has been found
140 Int_t fEnergy; // Charge sum of this cluster
142 Float_t fX; // X coord in ALICE reference frame
143 Float_t fY; // Y coord in ALICE reference frame
144 Float_t fZ; // Z coord in ALICE reference frame
146 Int_t fTracks[3]; // Track information
150 AliTRDcluster(Int_t *tracks, Int_t *cluster, Float_t *pos);
151 virtual ~AliTRDcluster() {};
153 inline virtual Int_t *GetTracks() { return &fTracks[0]; }
155 ClassDef(AliTRDcluster,1) // Cluster for Transition Radiation Detector