1 /**************************************************************************
2 * Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
4 * Author: The ALICE Off-line Project. *
5 * Contributors are mentioned in the code where appropriate. *
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 **************************************************************************/
16 #include "AliITSCalibrationSPD.h"
17 ///////////////////////////////////////////////////////////////////////////
18 // Calibration class for set:ITS
19 // Specific subdetector implementation for
22 // Modified by D. Elia, G.E. Bruno, H. Tydesjo
24 // Last mod: H. Tydesjo Oct 2007
25 // September 2007: CouplingRowDefault = 0.055 (was 0.047)
27 ///////////////////////////////////////////////////////////////////////////
28 const Double_t AliITSCalibrationSPD::fgkThreshDefault = 3000.;
29 const Double_t AliITSCalibrationSPD::fgkSigmaDefault = 250.;
30 const Double_t AliITSCalibrationSPD::fgkCouplColDefault = 0.;
31 const Double_t AliITSCalibrationSPD::fgkCouplRowDefault = 0.055;
32 const Double_t AliITSCalibrationSPD::fgkBiasVoltageDefault = 18.182;
34 ClassImp(AliITSCalibrationSPD)
36 //______________________________________________________________________
37 AliITSCalibrationSPD::AliITSCalibrationSPD():
41 fThresh(fgkThreshDefault),
42 fSigma(fgkSigmaDefault),
43 fCouplCol(fgkCouplColDefault),
44 fCouplRow(fgkCouplRowDefault),
45 fBiasVoltage(fgkBiasVoltageDefault),
50 SetThresholds(fgkThreshDefault,fgkSigmaDefault);
51 SetCouplingParam(fgkCouplColDefault,fgkCouplRowDefault);
52 SetBiasVoltage(fgkBiasVoltageDefault);
54 SetDataType("simulated");
56 //____________________________________________________________________________
57 void AliITSCalibrationSPD::AddBad(UInt_t col, UInt_t row) {
61 fBadChannels.Set(fNrBad*2+2);
62 fBadChannels.AddAt(col,fNrBad*2);
63 fBadChannels.AddAt(row,fNrBad*2+1);
66 //____________________________________________________________________________
67 Int_t AliITSCalibrationSPD::GetBadColAt(UInt_t index) {
69 // Get column of index-th bad pixel
72 return fBadChannels.At(index*2);
76 //____________________________________________________________________________
77 Int_t AliITSCalibrationSPD::GetBadRowAt(UInt_t index) {
79 // Get row of index-th bad pixel
82 return fBadChannels.At(index*2+1);
86 //____________________________________________________________________________
87 Bool_t AliITSCalibrationSPD::IsPixelBad(Int_t col, Int_t row) const {
89 // Check if pixel (col,row) is bad
91 for (UInt_t i=0; i<fNrBad; i++) {
92 if (fBadChannels.At(i*2)==col && fBadChannels.At(i*2+1)==row) {