]> git.uio.no Git - u/mrichter/AliRoot.git/blob - TPC/TPCrec/AliTPCRecoParam.cxx
073ec5d8665898095d7e9e7c557d0d2d121a37fe
[u/mrichter/AliRoot.git] / TPC / TPCrec / AliTPCRecoParam.cxx
1 /**************************************************************************
2  * Copyright(c) 1998-1999, 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 //                                                                           //
19 // Class with TPC reconstruction parameters                                  //
20 //                                                                           //  
21 //
22 /*
23   The reconstruction parameters are used in the AliTPCclusterer and AliTPCtracker
24   
25   They are retrieved:
26   0. User speciefied it in reconstruction macro
27   1. if (not 0) from OCDB  - AliTPCcalibDB::GetRecoParam(eventtype)
28   2. if (not 0 or 1) default parameter - High flux enevironment used  
29
30
31   // Setting for systematic errors addition
32   [0] - systematic RMSY
33   [1] - systematic RMSZ
34   [2] - systematic RMSSNP
35   [3] - systematic RMSTheta
36   [4] - systematic RMSCuravture -  systematic error in 1/cm not in 1/pt
37   //
38   //  How to add it example - 3 mm systematic error y, 3 cm systematic error z (drift)
39   Double_t sysError[5]={0.3,3, 0.3/150., 3./150.,0.3/(150*150.)}
40   param->SetSystematicError(sysError);
41
42 */
43                                                                            //
44 ///////////////////////////////////////////////////////////////////////////////
45
46
47 #include "AliTPCRecoParam.h"
48
49 ClassImp(AliTPCRecoParam)
50
51
52 Bool_t AliTPCRecoParam::fgUseTimeCalibration=kTRUE; // flag usage the time dependent calibration
53                                       // to be switched off for pass 0 reconstruction
54                                       // Use static function, other option will be to use 
55                                       // additional specific storage ?
56
57 //_____________________________________________________________________________
58 AliTPCRecoParam::AliTPCRecoParam():
59   AliDetectorRecoParam(),
60   fUseHLTClusters(4),  // use HLTorRAW data
61   fUseHLTPreSeeding(0), // no pre-seeding for now
62   fBClusterSharing(kTRUE),
63   fCtgRange(1.05),       
64   fMaxSnpTracker(0.95),
65   fMaxSnpTrack(0.999),
66   fUseOuterDetectors(kFALSE),
67   fMaxChi2TPCTRD(36),     // maximal allowed chi2 between the TRD in and TPC out to be accepted for refit
68   fMaxChi2TPCITS(36),     // maximal allowed chi2 between the ITS in and TPC out to be accepted for backpropagation
69   fUseOulierClusterFilter(0),  // swith to use outlier cluster filter
70   fDumpSignal(kFALSE),
71   fFirstBin(0),
72   fLastBin(-1),
73   fBCalcPedestal(kFALSE),
74   fBDoUnfold(kTRUE),
75   fDumpAmplitudeMin(100),
76   fMaxNoise(2.),
77   //
78   fUseOnePadCluster(kTRUE),
79   fUseHLTOnePadCluster(kFALSE),
80   fMinMaxCutAbs(4.),
81   fMinLeftRightCutAbs(6.),
82   fMinUpDownCutAbs(6.),
83   //
84   fMinMaxCutSigma(4.),
85   fMinLeftRightCutSigma(7.),
86   fMinUpDownCutSigma(8.),
87   fMaxC(0.3),
88   fBSpecialSeeding(kFALSE),
89   fBKinkFinder(kTRUE),
90   fLastSeedRowSec(120),
91   fSeedGapPrim(6),
92   fSeedGapSec(6),
93   fUseFieldCorrection(0),      // use field correction
94   fUseComposedCorrection(kFALSE),      // use field correction
95   fUseRPHICorrection(0),      // use rphi correction
96   fUseRadialCorrection(0),    // use radial correction
97   fUseQuadrantAlignment(0),   // use quadrant alignment
98   fUseSectorAlignment(0),     // use sector alignment
99   fUseDriftCorrectionTime(1), // use drift correction time
100   fUseDriftCorrectionGY(1),   // use drif correction global y
101   fUseGainCorrectionTime(0),  // use gain correction time
102   fUseExBCorrection(1),  // use ExB correction
103   fUseMultiplicityCorrectionDedx(kTRUE), // use Dedx multiplicity correction
104   fUseAlignmentTime(kTRUE),              // use time dependent alignment correction
105   fUseIonTailCorrection(0),   // no ion tail correction for now
106   fCrosstalkCorrection(0),   // crosstalk correction factor (from each signal substracted by (mean signal in wite patch)xfCrosstalkCorrection) - Effect important only after removing oc capacitors in 2012
107   fCrosstalkCorrectionMissingCharge(1),   // crosstalk correction factor - missing charge (from each signal substracted by (mean signal in wite patch)xfCrosstalkCorrection) - Effect important only after removing oc capacitors in 2012
108  //
109   fUseTotCharge(kTRUE),          // switch use total or max charge
110   fMinFraction(0.01),           // truncated mean - lower threshold
111   fMaxFaction(0.7),            // truncated mean - upper threshold
112   fNeighborRowsDedx(2),           // neighbour rows for below threshold dEdx calculation
113   fGainCorrectionHVandPTMode(0), // switch for the usage of GainCorrectionHVandPT (see AliTPCcalibDB::GetGainCorrectionHVandPT   
114   fSkipTimeBins(5),              // number of time bins to be skiiped (corrupted signal druing gating opening)
115   fUseTOFCorrection(kTRUE),
116   fUseSystematicCorrelation(kTRUE)
117 {
118   //
119   // constructor
120   //
121   SetName("TPC");
122   SetTitle("TPC");
123   for (Int_t i=0;i<5;i++) fSystematicErrors[i]=0;
124   // systematic error parameterization at INNER wall of the TPC
125   fSystematicErrorClusterInner[0]=0.5;   // 0.5 cm
126   fSystematicErrorClusterInner[1]=5;     // 5 cm slope  
127   //
128   fSystematicErrorCluster[0]=0;   // sy cluster error
129   fSystematicErrorCluster[1]=0;   // sz cluster error  
130
131   //
132   fCutSharedClusters[0]=0.5; // maximal allowed fraction of shared clusters - shorter track
133   fCutSharedClusters[1]=0.25; // maximal allowed fraction of shared clusters - longer  track
134   fClusterMaxRange[0]=1;     // y - pad      range
135   fClusterMaxRange[1]=1;     // z - time bin range
136   fKinkAngleCutChi2[0]=9;    // angular cut for kink finder - to create a kink
137                              // ~ about 5 % rate  for high pt kink finder
138   fKinkAngleCutChi2[1]=12;    // angular cut for kink finder - to use the partial track                             // form kink 
139                              // ~ about 2 % rate  for high pt kink finder
140 }
141
142 //_____________________________________________________________________________
143 AliTPCRecoParam::~AliTPCRecoParam() 
144 {
145   //
146   // destructor
147   //  
148 }
149
150 void AliTPCRecoParam::Print(const Option_t* /*option*/) const{
151   //
152   //
153   //
154   AliTPCRecoParam::Dump();
155   printf("Systematic errors:\n");
156   const char * cherrs[5]={"sy=","sz=","ssnp=","stheta=","s1pt="};
157   for (Int_t i=0; i<5; i++){
158     printf("%s%f\n",cherrs[i],fSystematicErrors[i]);
159   }
160 }
161
162
163 AliTPCRecoParam *AliTPCRecoParam::GetLowFluxParam(){
164   //
165   // make default reconstruction  parameters for low  flux env.
166   //
167   AliTPCRecoParam *param = new AliTPCRecoParam;
168   param->fCtgRange = 10;
169   param->fFirstBin = 0;
170   param->fLastBin  = 1000;
171   param->SetName("Low Flux");
172   param->SetTitle("Low Flux");
173   return param;
174 }
175
176 AliTPCRecoParam *AliTPCRecoParam::GetHighFluxParam(){
177   //
178   // make reco parameters for high flux env.
179   //
180   AliTPCRecoParam *param = new AliTPCRecoParam;
181   param->fCtgRange = 1.05;
182   param->fFirstBin = 0;
183   param->fLastBin  = 1000;  
184   param->fUseTotCharge=kFALSE;
185   param->SetName("High Flux");
186   param->SetTitle("High Flux");
187   return param;
188 }
189
190 AliTPCRecoParam *AliTPCRecoParam::GetHLTParam(){
191   //
192   // make reco parameters for high flux env.
193   //
194   AliTPCRecoParam *param = new AliTPCRecoParam;
195   param->fCtgRange = 1.05;
196   param->fFirstBin = 80;
197   param->fLastBin  = 1000;  
198   param->fMaxSnpTracker = 0.9; 
199   param->fMaxC          = 0.06; 
200   //
201   param->SetName("Hlt Param");
202   param->SetTitle("Hlt Param"); 
203   param->fBKinkFinder   = kFALSE;
204   return param;
205 }
206
207 AliTPCRecoParam *AliTPCRecoParam::GetLaserTestParam(Bool_t bPedestal){
208   //
209   // special setting for laser
210   //
211   AliTPCRecoParam *param = new AliTPCRecoParam;
212   param->fDumpSignal=kTRUE;
213   param->fCtgRange = 10.05;
214   param->fFirstBin = 0;
215   param->fLastBin  = 1000;
216   param->fBCalcPedestal = bPedestal;
217   param->fBDoUnfold     = kFALSE;
218   param->fDumpAmplitudeMin = 150;
219   param->fBKinkFinder   = kFALSE;
220   param->fMaxSnpTracker = 0.98;
221   param->fMaxC          = 0.02;
222   param->fBSpecialSeeding = kTRUE;
223   param->fUseTOFCorrection=kFALSE;
224   param->fUseHLTClusters=1; // always RAW data
225   //
226   //
227   param->SetName("Laser Flux");
228   param->SetTitle("Laser Flux");
229   return param;
230 }
231
232 AliTPCRecoParam *AliTPCRecoParam::GetCosmicTestParam(Bool_t bPedestal){
233   //
234   // special setting for cosmic 
235   // 
236   AliTPCRecoParam *param = new AliTPCRecoParam;
237   param->fDumpSignal=kTRUE;
238   param->fCtgRange = 10.05;    // full TPC
239   param->fFirstBin = 60;
240   param->fLastBin  = 1000;
241   param->fBCalcPedestal = bPedestal;
242   param->fBDoUnfold     = kFALSE;
243   param->fBSpecialSeeding = kTRUE;
244   param->fMaxC          = 0.07;
245   param->fBKinkFinder   = kFALSE;
246   param->fUseTOFCorrection =kFALSE;
247   param->SetName("Cosmic Flux");
248   param->SetTitle("Cosmic Flux");
249
250   return param;
251 }
252
253
254 Bool_t  AliTPCRecoParam::GetUseTimeCalibration(){ 
255   //
256   // get
257   //
258   return fgUseTimeCalibration;
259 }
260 void    AliTPCRecoParam::SetUseTimeCalibration(Bool_t useTimeCalibration) {
261   //
262   // set 
263   //
264   fgUseTimeCalibration = useTimeCalibration;
265 }
266