]> git.uio.no Git - u/mrichter/AliRoot.git/blame - MUON/AliMUONRecoParam.cxx
code documantation and minor cleanup
[u/mrichter/AliRoot.git] / MUON / AliMUONRecoParam.cxx
CommitLineData
3304fa09 1/**************************************************************************
2* Copyright(c) 1998-2007, ALICE Experiment at CERN, All rights reserved. *
3* *
4* Author: The ALICE Off-line Project. *
5* Contributors are mentioned in the code where appropriate. *
6* *
7* Permission to use, copy, modify and distribute this software and its *
8* documentation strictly for non-commercial purposes is hereby granted *
9* without fee, provided that the above copyright notice appears in all *
10* copies and that both the copyright notice and this permission notice *
11* appear in the supporting documentation. The authors make no claims *
12* about the suitability of this software for any purpose. It is *
13* provided "as is" without express or implied warranty. *
14**************************************************************************/
15
16
17//-----------------------------------------------------------------------------
18/// \class AliMUONRecoParam
19///
20/// Class with MUON reconstruction parameters
21///
22/// \author Philippe Pillot
23//-----------------------------------------------------------------------------
24
25
26
27#include "AliMUONRecoParam.h"
28
29#include "AliLog.h"
30
31#include <Riostream.h>
32
33ClassImp(AliMUONRecoParam)
34
35
36//_____________________________________________________________________________
37AliMUONRecoParam::AliMUONRecoParam()
15d30ed4 38: AliDetectorRecoParam(),
3304fa09 39 fClusteringMode("MLEM"),
40 fTrackingMode("KALMAN"),
0e894e58 41 fMostProbBendingMomentum(0.),
3304fa09 42 fMinBendingMomentum(0.),
43 fMaxBendingMomentum(0.),
9bf6860b 44 fMaxNonBendingSlope(0.),
3304fa09 45 fNonBendingVertexDispersion(0.),
46 fBendingVertexDispersion(0.),
47 fMaxNonBendingDistanceToTrack(0.),
48 fMaxBendingDistanceToTrack(0.),
49 fSigmaCutForTracking(0.),
50 fSigmaCutForImprovement(0.),
fda59e58 51 fSigmaCutForTrigger(0.),
3304fa09 52 fMaxNormChi2MatchTrigger(0.),
0a18ba02 53 fPercentOfFullClusterInESD(10.),
38bcf0ef 54 fCombinedClusterTrackReco(kFALSE),
3304fa09 55 fTrackAllTracks(kFALSE),
56 fRecoverTracks(kFALSE),
57 fMakeTrackCandidatesFast(kFALSE),
9bf6860b 58 fMakeMoreTrackCandidates(kFALSE),
3304fa09 59 fComplementTracks(kFALSE),
60 fImproveTracks(kFALSE),
0a18ba02 61 fUseSmoother(kFALSE),
de98fdc9 62 fSaveFullClusterInESD(kTRUE),
9bf6860b 63 fCalibrationMode("NOGAIN"),
64 fBypassSt45(kFALSE)
3304fa09 65{
66 /// Constructor
15d30ed4 67 SetNameTitle("MUON","MUON");
3304fa09 68
69 // use the default parameters for low flux environment
70 SetLowFluxParam();
71}
72
73//_____________________________________________________________________________
74AliMUONRecoParam::~AliMUONRecoParam()
75{
76 /// Destructor
77}
78
9bf6860b 79//_____________________________________________________________________________
80Option_t*
81AliMUONRecoParam::GetCalibrationMode() const
82{
83 /// Return the calibration mode. Can be :
84 /// NOGAIN : only do pedestal subtraction
85 /// GAIN : do pedestal subtraction, and apply gain correction, but with a
86 /// single capacitance value for all channels
87 /// GAINCONSTANTCAPA : as GAIN, but with a channel-dependent capacitance value
88
89 return fCalibrationMode.Data();
90}
91
3304fa09 92//_____________________________________________________________________________
93AliMUONRecoParam *AliMUONRecoParam::GetLowFluxParam()
94{
95 /// Return default reconstruction parameters for low flux environment
96
97 AliMUONRecoParam *param = new AliMUONRecoParam();
98 param->SetLowFluxParam();
99
100 return param;
101}
102
103//_____________________________________________________________________________
104AliMUONRecoParam *AliMUONRecoParam::GetHighFluxParam()
105{
106 /// Return default reconstruction parameters for high flux environment
107
108 AliMUONRecoParam *param = new AliMUONRecoParam();
109 param->SetHighFluxParam();
110
111 return param;
112}
113
0e894e58 114//_____________________________________________________________________________
115AliMUONRecoParam *AliMUONRecoParam::GetCosmicParam()
116{
117 /// Return default reconstruction parameters for high flux environment
118
119 AliMUONRecoParam *param = new AliMUONRecoParam();
120 param->SetCosmicParam();
121
122 return param;
123}
124
3304fa09 125//_____________________________________________________________________________
126void AliMUONRecoParam::SetLowFluxParam()
127{
128 /// Set reconstruction parameters for low flux environment
129
0e894e58 130 fMostProbBendingMomentum = 2.;
9bf6860b 131 fMinBendingMomentum = 1.;
3304fa09 132 fMaxBendingMomentum = 3000.;
9bf6860b 133 fMaxNonBendingSlope = 0.3;
3304fa09 134 fNonBendingVertexDispersion = 10.;
135 fBendingVertexDispersion = 10.;
9bf6860b 136 fMaxNonBendingDistanceToTrack = 1.;
137 fMaxBendingDistanceToTrack = 1.;
3304fa09 138 fSigmaCutForTracking = 6.;
139 fSigmaCutForImprovement = 5.;
fda59e58 140 fSigmaCutForTrigger = 8.;
3304fa09 141 fMaxNormChi2MatchTrigger = 16.;
6cac085d 142 fCombinedClusterTrackReco = kFALSE;
3304fa09 143 fTrackAllTracks = kTRUE;
144 fRecoverTracks = kTRUE;
145 fMakeTrackCandidatesFast = kFALSE;
9bf6860b 146 fMakeMoreTrackCandidates = kFALSE;
3304fa09 147 fComplementTracks = kTRUE;
148 fImproveTracks = kTRUE;
149 fUseSmoother = kTRUE;
9bf6860b 150 for (Int_t iCh = 0; iCh < 10; iCh++) fUseChamber[iCh] = kTRUE;
151 for (Int_t iSt = 0; iSt < 5; iSt++) fRequestStation[iSt] = kTRUE;
6cac085d 152 fBypassSt45 = kFALSE;
3304fa09 153
154}
155
156//_____________________________________________________________________________
157void AliMUONRecoParam::SetHighFluxParam()
158{
159 /// Set reconstruction parameters for high flux environment
160
0e894e58 161 fMostProbBendingMomentum = 2.;
9bf6860b 162 fMinBendingMomentum = 1.;
3304fa09 163 fMaxBendingMomentum = 3000.;
9bf6860b 164 fMaxNonBendingSlope = 0.3;
3304fa09 165 fNonBendingVertexDispersion = 10.;
166 fBendingVertexDispersion = 10.;
9bf6860b 167 fMaxNonBendingDistanceToTrack = 1.;
168 fMaxBendingDistanceToTrack = 1.;
3304fa09 169 fSigmaCutForTracking = 6.;
170 fSigmaCutForImprovement = 5.;
fda59e58 171 fSigmaCutForTrigger = 8.;
3304fa09 172 fMaxNormChi2MatchTrigger = 16.;
6cac085d 173 fCombinedClusterTrackReco = kFALSE;
3304fa09 174 fTrackAllTracks = kTRUE;
175 fRecoverTracks = kTRUE;
176 fMakeTrackCandidatesFast = kFALSE;
9bf6860b 177 fMakeMoreTrackCandidates = kFALSE;
3304fa09 178 fComplementTracks = kTRUE;
179 fImproveTracks = kTRUE;
180 fUseSmoother = kTRUE;
9bf6860b 181 for (Int_t iCh = 0; iCh < 10; iCh++) fUseChamber[iCh] = kTRUE;
182 for (Int_t iSt = 0; iSt < 5; iSt++) fRequestStation[iSt] = kTRUE;
6cac085d 183 fBypassSt45 = kFALSE;
3304fa09 184
185}
186
0e894e58 187//_____________________________________________________________________________
188void AliMUONRecoParam::SetCosmicParam()
189{
190 /// Set reconstruction parameters for high flux environment
191
192 fMostProbBendingMomentum = 2.;
193 fMinBendingMomentum = 1.;
194 fMaxBendingMomentum = 10000000.;
195 fMaxNonBendingSlope = 0.3;
196 fNonBendingVertexDispersion = 10.;
197 fBendingVertexDispersion = 10.;
198 fMaxNonBendingDistanceToTrack = 10.;
199 fMaxBendingDistanceToTrack = 10.;
200 fSigmaCutForTracking = 20.;
201 fSigmaCutForImprovement = 20.;
202 fSigmaCutForTrigger = 8.;
203 fMaxNormChi2MatchTrigger = 16.;
204 fPercentOfFullClusterInESD = 100.;
205 fCombinedClusterTrackReco = kFALSE;
206 fTrackAllTracks = kTRUE;
207 fRecoverTracks = kTRUE;
208 fMakeTrackCandidatesFast = kFALSE;
209 fMakeMoreTrackCandidates = kFALSE;
210 fComplementTracks = kTRUE;
211 fImproveTracks = kTRUE;
212 fUseSmoother = kTRUE;
213 fSaveFullClusterInESD = kTRUE;
214 for (Int_t iCh = 0; iCh < 10; iCh++) fUseChamber[iCh] = kTRUE;
215 for (Int_t iSt = 0; iSt < 5; iSt++) fRequestStation[iSt] = kTRUE;
216 fBypassSt45 = kFALSE;
217
218}
219
3304fa09 220//_____________________________________________________________________________
221void AliMUONRecoParam::Print(Option_t *option) const
222{
223 /// print reconstruction parameters
224 /// if option = FULL then print also unused parameters
225
226 cout<<endl<<"\t------Reconstruction parameters------"<<endl;
227
de98fdc9 228 cout<<Form("Calibration mode = %s",fCalibrationMode.Data())<<endl;
3304fa09 229 cout<<Form("Clustering mode = %s",fClusteringMode.Data())<<endl;
3304fa09 230 cout<<Form("Tracking mode = %s",fTrackingMode.Data())<<endl;
9bf6860b 231
232 if (BypassSt45()) cout << "Will bypass St45 (replacing their clusters by generated ones from trigger tracks)" << endl;
3304fa09 233
15d30ed4 234 if (fCombinedClusterTrackReco) cout<<"Combined cluster/track reconstruction: ON"<<endl;
235 else cout<<"Combined cluster/track reconstruction: OFF"<<endl;
38bcf0ef 236
0a18ba02 237 if (fSaveFullClusterInESD) cout<<Form("Save all cluster info in ESD for %5.2f %% of events",fPercentOfFullClusterInESD)<<endl;
238 else cout<<"Save partial cluster info in ESD"<<endl;
239
0e894e58 240 cout<<Form("Most probable bending momentum (used only if B=0) = %5.2f",fMostProbBendingMomentum)<<endl;
241
3304fa09 242 cout<<Form("Bending momentum range = [%5.2f,%5.2f]",fMinBendingMomentum,fMaxBendingMomentum)<<endl;
243
9bf6860b 244 cout<<Form("Maximum non bending slope = %5.2f",fMaxNonBendingSlope)<<endl;
245
3304fa09 246 if (strstr(fTrackingMode,"ORIGINAL"))
247 cout<<Form("Vertex dispertion = (%5.2f,%5.2f)",fNonBendingVertexDispersion,fBendingVertexDispersion)<<endl;
248 else if (strstr(option,"FULL"))
249 cout<<Form("Vertex dispertion (used for original tracking only) = (%5.2f,%5.2f)",fNonBendingVertexDispersion,fBendingVertexDispersion)<<endl;
250
251 cout<<Form("Maximum distance to track = (%5.2f,%5.2f)",fMaxNonBendingDistanceToTrack,fMaxBendingDistanceToTrack)<<endl;
252
253 cout<<Form("Sigma cut for tracking = %5.2f",fSigmaCutForTracking)<<endl;
fda59e58 254
255 cout<<Form("Sigma cut for trigger hit pattern = %5.2f",fSigmaCutForTrigger)<<endl;
3304fa09 256
257 if (fTrackAllTracks) cout<<"Track all the possible candidates"<<endl;
258 else cout<<"Track only the best candidates"<<endl;
259
260 if (strstr(option,"FULL")) {
261 cout<<"Make track candidates assuming linear propagation between stations 4 and 5: ";
262 if (fMakeTrackCandidatesFast) cout<<"ON"<<endl;
263 else cout<<"OFF"<<endl;
264 } else if (fMakeTrackCandidatesFast)
265 cout<<"Make track candidates assuming linear propagation between stations 4 and 5"<<endl;
266
9bf6860b 267 if (strstr(option,"FULL")) {
268 cout<<"Make track candidates starting from 1 cluster in each of the stations 4 and 5: ";
269 if (fMakeMoreTrackCandidates) cout<<"ON"<<endl;
270 else cout<<"OFF"<<endl;
271 } else if (fMakeMoreTrackCandidates)
272 cout<<"Make track candidates starting from 1 cluster in each of the stations 4 and 5"<<endl;
273
3304fa09 274 if (strstr(option,"FULL")) {
275 cout<<"Try to recover tracks getting lost during tracking: ";
276 if (fRecoverTracks) cout<<"ON"<<endl;
277 else cout<<"OFF"<<endl;
278 } else if (fRecoverTracks)
279 cout<<"Try to recover tracks getting lost during tracking"<<endl;
280
281 if (strstr(option,"FULL")) {
282 cout<<"Try to complete the reconstructed tracks by adding missing clusters: ";
283 if (fComplementTracks) cout<<"ON"<<endl;
284 else cout<<"OFF"<<endl;
285 } else if (fComplementTracks)
286 cout<<"Try to complete the reconstructed tracks by adding missing clusters"<<endl;
287
288 if (strstr(option,"FULL")) {
289 cout<<"Try to improve the reconstructed tracks by removing bad clusters: ";
290 if (fImproveTracks) cout<<Form("ON (sigma cut = %5.2f)",fSigmaCutForImprovement)<<endl;
291 else cout<<"OFF"<<endl;
292 } else if (fImproveTracks)
293 cout<<Form("Try to improve the reconstructed tracks by removing bad clusters (sigma cut = %5.2f)",fSigmaCutForImprovement)<<endl;
294
295 if (strstr(option,"FULL")) {
296 cout<<"Use smoother to compute final track parameters, etc, at each cluster (used for Kalman tracking only): ";
297 if (fUseSmoother) cout<<"ON"<<endl;
298 else cout<<"OFF"<<endl;
299 } else if (fUseSmoother)
300 cout<<"Use smoother to compute final track parameters, etc, at each cluster"<<endl;
301
302 cout<<Form("Maximum normalized chi2 of tracking/trigger track matching = %5.2f",fMaxNormChi2MatchTrigger)<<endl;
303
9bf6860b 304 Bool_t discardedCh = kFALSE;
305 Int_t ch = 0;
306 do {
307 if (!UseChamber(ch)) {
308 if (!discardedCh) {
309 cout<<"Discarded chambers(1..): "<<ch+1;
310 discardedCh = kTRUE;
311 }
312 else cout<<" "<<ch+1;
313 }
314 } while (++ch < 10);
315 if (discardedCh) cout<<endl;
316
317 Bool_t discardedSt = kFALSE;
318 Int_t st = 0;
319 do {
320 if (!RequestStation(st)) {
321 if (!discardedSt) {
322 cout<<"Not requested stations(1..): "<<st+1;
323 discardedSt = kTRUE;
324 }
325 else cout<<" "<<st+1;
326 }
327 } while (++st < 5);
328 if (discardedSt) cout<<endl;
329
3304fa09 330 cout<<"\t-------------------------------------"<<endl<<endl;
331
332}
333