]> git.uio.no Git - u/mrichter/AliRoot.git/blob - MUON/AliMUONChamber.h
Corrected path to mapping libraries.
[u/mrichter/AliRoot.git] / MUON / AliMUONChamber.h
1 #ifndef ALIMUONCHAMBER_H
2 #define ALIMUONCHAMBER_H
3 /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
4  * See cxx source for full Copyright notice                               */
5
6 /* $Id$ */
7
8 #include "TObjArray.h"
9 #include "AliSegmentation.h"
10 #include "AliMUONResponse.h"
11
12 class AliMUONClusterFinderVS;
13 //class AliMUONResponse ;
14 //class AliSegmentation ;
15
16 class AliMUONChamber:
17 public TObject
18 {
19  public:
20     AliMUONChamber();
21     AliMUONChamber(Int_t id);
22     AliMUONChamber(const AliMUONChamber & rChamber);
23     virtual ~AliMUONChamber();
24     
25 //
26 // Get GEANT id of sensitive volume
27   virtual Int_t   GetGid() {return fGid;}
28 // Set GEANT id of sensitive volume
29   virtual void    SetGid(Int_t id) {fGid=id;}
30 //  
31 // Initialisation
32   virtual void    Init();
33 // Set z-position of chamber  
34   virtual void    SetZ(Float_t Z) {fZ = Z;}
35 // Get z-position of chamber  
36   virtual Float_t Z(){return fZ;}
37 // Set inner radius of sensitive volume 
38   virtual void SetRInner(Float_t rmin) {frMin=rmin;}
39 // Set outer radius of sensitive volum  
40   virtual void SetROuter(Float_t rmax) {frMax=rmax;}  
41
42 // Return inner radius of sensitive volume 
43   virtual  Float_t RInner()            {return frMin;}
44 // Return outer radius of sensitive volum  
45   virtual Float_t ROuter()            {return frMax;}  
46 //  
47 // Set response model
48   virtual void    SetResponseModel(AliMUONResponse* thisResponse) {fResponse=thisResponse;}
49 //  
50 // Set segmentation model
51   virtual void    SetSegmentationModel(Int_t i, AliSegmentation* thisSegmentation) {
52       fSegmentation->AddAt(thisSegmentation,i-1);
53   }
54 // Set Cluster reconstruction model  
55   virtual void    SetReconstructionModel(AliMUONClusterFinderVS *thisReconstruction) {
56       fReconstruction = thisReconstruction;
57   }
58 //  
59 //  Get pointer to response model
60   virtual AliMUONResponse* &ResponseModel(){return fResponse;}
61 //  
62 //  Get reference to segmentation model
63   virtual AliSegmentation*  SegmentationModel(Int_t isec) {
64       return (AliSegmentation *) (*fSegmentation)[isec-1];
65   }
66   virtual TObjArray* ChamberSegmentation() {return fSegmentation;}
67 //  Get pointer to cluster reconstruction model
68   virtual AliMUONClusterFinderVS* &ReconstructionModel(){return fReconstruction;}
69 // Get number of segmentation sectors  
70   virtual Int_t Nsec()              {return fnsec;}
71 // Set number of segmented cathodes (1 or 2)  
72   virtual void  SetNsec(Int_t nsec) {fnsec=nsec;}
73 //
74 // Member function forwarding to the segmentation and response models
75 //
76 // Calculate pulse height from energy loss  
77   virtual Float_t IntPH(Float_t eloss) {return fResponse->IntPH(eloss);}
78 //  
79 // Ask segmentation if signal should be generated  
80   virtual Int_t   SigGenCond(Float_t x, Float_t y, Float_t z);
81 //
82 // Initialisation of segmentation for hit  
83   virtual void    SigGenInit(Float_t x, Float_t y, Float_t z);
84 // Initialisation of charge fluctuation for given hit
85   virtual void    ChargeCorrelationInit();
86
87 // Configuration forwarding
88 //
89 // Define signal distribution region
90 // by number of sigmas of the distribution function
91   virtual void   SetSigmaIntegration(Float_t p1)
92       {fResponse->SetSigmaIntegration(p1);}
93 // Set the single electron pulse-height (ADCchan/e)  
94   virtual void   SetChargeSlope(Float_t p1)              {fResponse->SetChargeSlope(p1);}
95 // Set width of charge distribution function  
96   virtual void   SetChargeSpread(Float_t p1, Float_t p2) {fResponse->SetChargeSpread(p1,p2);}
97 // Set maximum ADC count value
98   virtual void   SetMaxAdc(Int_t p1)                   {fResponse->SetMaxAdc(p1);}
99 // Set Pad size
100   virtual void   SetPadSize(Int_t isec, Float_t p1, Float_t p2) {
101       ((AliSegmentation*) (*fSegmentation)[isec-1])->SetPadSize(p1,p2);
102   }
103 //  
104 // Cluster formation method (charge disintegration)
105   virtual void   DisIntegration(Float_t eloss, Float_t tof,
106                                 Float_t xhit, Float_t yhit, Float_t zhit,
107                                 Int_t& x, Float_t newclust[6][500]);
108 // Initialize geometry related parameters  
109   virtual void    InitGeo(Float_t z);
110 //
111   virtual Float_t DGas() {return fdGas;}
112   virtual Float_t DAlu() {return fdAlu;}  
113   virtual void SetDGas(Float_t DGas) {fdGas = DGas;}
114   virtual void SetDAlu(Float_t DAlu) {fdAlu = DAlu;}  
115   virtual void SetChargeCorrel(Float_t correl) {fResponse->SetChargeCorrel(correl);}
116 // assignment operator  
117   AliMUONChamber& operator =(const AliMUONChamber& rhs);
118   
119  protected:
120   Int_t   fId;   // chamber number
121   Float_t fdGas; // half gaz gap
122   Float_t fdAlu; // half Alu width  
123   Int_t   fGid;  // GEANT volume if for sensitive volume of this chamber
124   Float_t fZ;    // Z position (cm)
125   Int_t   fnsec; // number of semented cathode planes
126   Float_t frMin; // innermost sensitive radius
127   Float_t frMax; // outermost sensitive radius
128   Float_t fCurrentCorrel; //! charge correlation for current hit.
129
130   TObjArray              *fSegmentation;    // pointer to segmentation
131   AliMUONClusterFinderVS *fReconstruction;  // pointer to reconstruction
132   AliMUONResponse        *fResponse;        // pointer to response
133   ClassDef(AliMUONChamber,1) // Muon tracking chamber class
134 };
135
136 #endif