]>
Commit | Line | Data |
---|---|---|
ba030c0e | 1 | #ifndef ALI_MUON_ST1_RESPONSE_H |
2 | #define ALI_MUON_ST1_RESPONSE_H | |
3 | ||
4 | /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. * | |
5 | * See cxx source for full Copyright notice */ | |
6 | ||
7 | /* $Id$ */ | |
30178c30 | 8 | // Revision of includes 07/05/2004 |
ba030c0e | 9 | |
10 | // Authors: David Guez, Ivana Hrivnacova, Marion MacCormick; IPN Orsay | |
11 | // | |
12 | // Class AliMUONSt1Response | |
13 | // ---------------------------- | |
14 | // Response class for station 1 including electronics and detector response. | |
15 | // Individual pedestals or noise levels can be controlled separately. | |
16 | // The current pulse height responses do not contain any physics | |
17 | ||
79637e23 | 18 | #include <map> |
1df92d74 | 19 | #include <string> |
79637e23 | 20 | #ifndef __HP_aCC |
1df92d74 | 21 | using std::map; |
22 | using std::string; | |
79637e23 | 23 | #endif |
24 | ||
ba030c0e | 25 | #include <TString.h> |
26 | #include <TList.h> | |
79637e23 | 27 | |
ba030c0e | 28 | #include "AliMUONResponseV0.h" |
29 | #include "AliMUONSt1ElectronicElement.h" | |
30 | ||
7b629e21 | 31 | class AliMpSector; |
32 | class AliMpSectorSegmentation; | |
5f91c9e8 | 33 | class AliMpZone; |
34 | class AliMpSector; | |
ba030c0e | 35 | class TArrayF; |
36 | class TObjArray; | |
37 | class AliMUONSt1ResponseParameter; | |
7b629e21 | 38 | class AliMUONChamber; |
ba030c0e | 39 | |
40 | class AliMUONSt1Response : public AliMUONResponseV0 | |
41 | { | |
30178c30 | 42 | public: |
7b629e21 | 43 | AliMUONSt1Response(AliMUONChamber* chamber); |
44 | AliMUONSt1Response(); | |
ba030c0e | 45 | virtual ~AliMUONSt1Response(); |
46 | ||
47 | // | |
48 | // Configuration methods | |
49 | // | |
50 | void SetIniFileName(Int_t plane,const TString& fileName); | |
51 | ||
52 | virtual Float_t IntPH(Float_t eloss); | |
53 | ||
54 | // Noise, zero-suppression, adc saturation | |
55 | virtual Int_t DigitResponse(Int_t digit,AliMUONTransientDigit* where); | |
56 | void PrintStatistics() const; | |
57 | ||
30178c30 | 58 | protected: |
59 | AliMUONSt1Response(const AliMUONSt1Response& rhs); | |
60 | ||
61 | // operators | |
62 | AliMUONSt1Response& operator=(const AliMUONSt1Response & rhs); | |
ba030c0e | 63 | |
30178c30 | 64 | private: |
79637e23 | 65 | // typedefs |
66 | typedef map<string, AliMUONSt1ResponseParameter*> ParamsMap; | |
67 | typedef map<string, TList*> ListMap; | |
68 | ||
3c25381f | 69 | // private methods |
7b629e21 | 70 | const AliMUONGeometrySegmentation* GetGeometrySegmentation(Int_t cathod); |
71 | const AliMpSectorSegmentation* GetMpSegmentation(Int_t detElemId, Int_t cathod); | |
72 | const AliMpSector* GetMpSector(Int_t detElemId, Int_t cathod); | |
73 | AliMpZone* FindZone(const AliMpSector* sector,Int_t posId) const; // to be moved in AliMpSector:: | |
ba030c0e | 74 | void ReadFiles(); |
75 | void ReadIniFile(Int_t plane,const TString& fileName,Bool_t rdParam,Bool_t rdRegion,Bool_t rdRule); | |
76 | void ReadIniFile(Int_t plane); | |
77 | void ReadCouplesOfIntRanges(const string& value,TList* list,AliMUONSt1ElectronicElement::TDescription descr); | |
78 | void ReadCouplesOfFloatRanges(const string& value,TList* list); | |
79 | void SetPairToParam(const string& name,const string& value,AliMUONSt1ResponseParameter* param) const; | |
80 | void SetPairToListElem(const string& name,const string& value,TList* list); | |
81 | ||
3c25381f | 82 | // private constants |
83 | static const Int_t fgkNofZones=4; // number of zones | |
84 | static const TString fgkTopDir; // top directory path | |
85 | static const TString fgkDataDir; // data directory path | |
86 | static const TString fgkConfigBaseName; // config file base name | |
87 | static const TString fgkStandardIniFileName;// standard ini file name | |
ba030c0e | 88 | |
3c25381f | 89 | // static names |
90 | static const TString fgkBaseName ; // base name | |
91 | static const TString fgkIncludeName ; // include name | |
92 | static const TString fgkParameterName ; // parameter name | |
93 | static const TString fgkRegionName ; // region name | |
94 | static const TString fgkRuleName ; // rule name | |
95 | static const TString fgkNameName ; // name name | |
96 | static const TString fgkPedestalName ; // pedestal name | |
97 | static const TString fgkNoiseName ; // noise name | |
98 | static const TString fgkStateName ; // state name | |
99 | static const TString fgkMName ; // M name | |
100 | static const TString fgkMGName ; // MG name | |
101 | static const TString fgkMGCName ; // MGC name | |
102 | static const TString fgkIJName ; // i,j name | |
103 | static const TString fgkXYName ; // x,y name | |
104 | static const TString fgkZoneName ; // zone name | |
105 | static const TString fgkStickyOnName ; // sticky on name | |
106 | static const TString fgkStickyOffName ; // sticky off | |
107 | static const TString fgkFileName ; // file name | |
108 | static const TString fgkValueName ; // value name | |
109 | static const TString fgkGausName ; // gauss name | |
110 | static const TString fgkNotName ; // not name | |
111 | static const TString fgkNofSigmaName ; // nof sigma name | |
112 | ||
113 | // data members | |
ba030c0e | 114 | TString fIniFileName[2];// file names for initialisation of each cathode |
7b629e21 | 115 | Bool_t fReadFiles; // flag to read initalization files only once |
116 | ||
ba030c0e | 117 | AliMUONSt1ResponseParameter* fDefaultParameters[2][fgkNofZones]; // !Response for each zone |
118 | TList fRulesList[2]; //! list of special rules | |
119 | ||
120 | Int_t fCountNofCalls; // number of calls to DigitResponse() | |
121 | Int_t fCountUnknownZone; // ntimes the DigitResponse was called in an unknown zone | |
122 | Int_t fCountUnknownIndices; // ntimes the DigitResponse was called with unknown indices | |
123 | ||
7b629e21 | 124 | AliMUONChamber* fChamber; // The MUON chamber |
ba030c0e | 125 | |
79637e23 | 126 | ParamsMap fParams; //! internal parameter list |
127 | ListMap fRegions; //! internal list of regions | |
128 | TList fTrashList; //! internal trash list | |
ba030c0e | 129 | |
130 | ClassDef(AliMUONSt1Response,1) // Overall detector response | |
131 | }; | |
132 | ||
133 | #endif //ALI_MUON_ST1_RESPONSE_H |