3 /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
4 * See cxx source for full Copyright notice */
7 // Revision of includes 07/05/2004
11 /// \brief AliDetector Class for MUON subsystem
13 ////////////////////////////////////////////////
14 // AliDetector Class for MUON subsystem //
15 ////////////////////////////////////////////////
17 #include <TObjArray.h>
19 #include "AliDetector.h"
20 #include "AliMUONData.h"
21 #include "AliMUONChamber.h"
22 #include "AliMUONTrigger.h"
24 #include <TVectorfwd.h>
30 class AliMUONTriggerCircuit;
32 class AliMUONResponse;
33 class AliMUONSegmentation;
35 class AliMUONRawCluster;
36 class AliMUONGeometry;
37 class AliMUONGeometryTransformer;
38 class AliMUONGeometryBuilder;
39 class AliMUONVGeometryBuilder;
42 class AliMUON : public AliDetector
46 AliMUON(const char *name, const char *title,
47 const char* sDigitizerType="sdigitizer:default",
48 const char* digitizerType="digitizer:default");
52 void AddGeometryBuilder(AliMUONVGeometryBuilder* geomBuilder);
53 virtual void BuildGeometry();
54 virtual Int_t IsVersion() const {return 0;}
56 AliMUONGeometryBuilder* GetGeometryBuilder() const {return fGeometryBuilder;}
57 const AliMUONGeometryTransformer* GetGeometryTransformer() const;
58 AliMUONSegmentation* GetSegmentation() const { return fSegmentation; }
61 AliMUONData* GetMUONData() {return fMUONData;}
63 // MUONLoader definition
64 virtual AliLoader* MakeLoader(const char* topfoldername); //builds standard getter (AliLoader type)
65 // Interface with AliMUONData
66 virtual void MakeBranch(Option_t *opt=" ") {GetMUONData()->MakeBranch(opt);}
67 virtual void SetTreeAddress();
68 virtual void ResetHits() {GetMUONData()->ResetHits();}
69 virtual void ResetDigits() {GetMUONData()->ResetDigits();}
70 virtual void ResetTrigger() {GetMUONData()->ResetTrigger();}
71 virtual void ResetRawClusters() {GetMUONData()->ResetRawClusters();}
72 virtual void SetSplitLevel(Int_t SplitLevel) {fSplitLevel=SplitLevel;}
75 virtual AliDigitizer* CreateDigitizer(AliRunDigitizer* manager) const;
76 virtual void SDigits2Digits();
77 virtual void Hits2SDigits();
78 virtual void Digits2Raw();
81 virtual AliTriggerDetector* CreateTriggerDetector() const
82 { return new AliMUONTrigger(); }
85 // Configuration Methods (per station id)
87 // Set Signal Generation Parameters
88 virtual void SetSigmaIntegration(Int_t id, Float_t p1);
89 virtual void SetChargeSlope(Int_t id, Float_t p1);
90 virtual void SetChargeSpread(Int_t id, Float_t p1, Float_t p2);
91 virtual void SetMaxAdc(Int_t id, Int_t p1);
93 virtual void SetResponseModel(Int_t id, AliMUONResponse *response);
95 // Set Stepping Parameters
96 virtual void SetMaxStepGas(Float_t p1);
97 virtual void SetMaxStepAlu(Float_t p1);
98 virtual void SetMaxDestepGas(Float_t p1);
99 virtual void SetMaxDestepAlu(Float_t p1);
101 // Get Stepping Parameters
102 virtual Float_t GetMaxStepGas() const;
103 virtual Float_t GetMaxStepAlu() const;
104 virtual Float_t GetMaxDestepGas() const;
105 virtual Float_t GetMaxDestepAlu() const;
107 // Set alignement option
108 virtual void SetAlign(Bool_t align = true);
109 virtual void SetAlign(const TString& fileName, Bool_t align = true);
111 // Set scaler event for trigger
112 virtual void SetTriggerScalerEvent(Bool_t scaler = true){fTriggerScalerEvent = scaler;}
114 // Return reference to Chamber #id
115 virtual AliMUONChamber& Chamber(Int_t id)
116 {return *((AliMUONChamber *) (*fChambers)[id]);}
117 // Return reference to Circuit #id
118 virtual AliMUONTriggerCircuit& TriggerCircuit(Int_t id)
119 {return *((AliMUONTriggerCircuit *) (*fTriggerCircuits)[id]);}
120 // Return pointers to digits
121 AliMUONRawCluster *RawCluster(Int_t ichamber, Int_t icathod,
123 // Inherited and overridden from AliModule:
124 //PH virtual void RemapTrackHitIDs(Int_t * map);
126 TString SDigitizerType() const;
127 TString DigitizerType() const;
130 AliMUON(const AliMUON& rMUON);
131 AliMUON& operator = (const AliMUON& rhs);
133 const AliMUONGeometry* GetGeometry() const;
135 Int_t fNCh; // Number of chambers
136 Int_t fNTrackingCh; // Number of tracking chambers*
137 AliMUONData* fMUONData; // Data container for MUON subsystem
138 Int_t fSplitLevel; // Splitlevel when making branches in outfiles.
139 TObjArray* fChambers; // List of Tracking Chambers
140 TObjArray* fTriggerCircuits; // List of Trigger Circuits
141 AliMUONGeometryBuilder* fGeometryBuilder; // Geometry builder
142 AliMUONSegmentation* fSegmentation; // New segmentation
145 Bool_t fAccCut; //Transport acceptance cut
146 Float_t fAccMin; //Minimum acceptance cut used during transport
147 Float_t fAccMax; //Minimum acceptance cut used during transport
149 // Stepping Parameters
150 Float_t fMaxStepGas; // Maximum step size inside the chamber gas
151 Float_t fMaxStepAlu; // Maximum step size inside the chamber aluminum
152 Float_t fMaxDestepGas; // Maximum relative energy loss in gas
153 Float_t fMaxDestepAlu; // Maximum relative energy loss in aluminum
156 Int_t fMaxIterPad; // Maximum pad index
157 Int_t fCurIterPad; // Current pad index
159 // setting scaler for trigger
160 Bool_t fTriggerScalerEvent; // flag to generates scaler event
162 TString fSDigitizerType; // Class to use for SDigitizer
163 TString fDigitizerType; // Class to use for Digitizer
165 ClassDef(AliMUON,11) // MUON Detector base class