]>
Commit | Line | Data |
---|---|---|
1 | #ifndef ALIITSRESPONSESDD_H | |
2 | #define ALIITSRESPONSESDD_H | |
3 | ||
4 | /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. * | |
5 | * See cxx source for full Copyright notice */ | |
6 | ||
7 | ||
8 | #include <AliITSresponse.h> | |
9 | #include <TArrayF.h> | |
10 | ||
11 | ///////////////////////////////////////////////////////////// | |
12 | // Base settings for the ITS response classes. // | |
13 | // The data member of this class are static and set once // | |
14 | // for all the modules. // | |
15 | ///////////////////////////////////////////////////////////// | |
16 | ||
17 | class AliITSresponseSDD : public AliITSresponse { | |
18 | public: | |
19 | ||
20 | AliITSresponseSDD(); | |
21 | virtual ~AliITSresponseSDD(); | |
22 | ||
23 | virtual void SetElectronics(Int_t p1=1) | |
24 | {fElectronics=p1; /* Electronics: Pascal (1) or OLA (2) */ } | |
25 | virtual Int_t Electronics() const {// Electronics: 1 = Pascal; 2 = OLA | |
26 | return fElectronics;} | |
27 | virtual void SetMaxAdc(Double_t p1) {// Adc-count saturation value | |
28 | fMaxAdc=p1;} | |
29 | virtual Float_t MaxAdc() const {// Get maximum Adc-count value | |
30 | return fMaxAdc;} | |
31 | virtual void SetChargeLoss(Double_t p1) { | |
32 | // Set Linear Charge Loss Steepness // 0.01 for 20% | |
33 | fChargeLoss=p1;} | |
34 | virtual Float_t ChargeLoss() const {// Get Charge Loss Coefficient | |
35 | return fChargeLoss;} | |
36 | virtual void SetDynamicRange(Double_t p1) {// Set Dynamic Range | |
37 | fDynamicRange = p1;} | |
38 | virtual Float_t DynamicRange() const {// Get Dynamic Range | |
39 | return fDynamicRange;} | |
40 | virtual void SetDriftSpeed(Double_t p1) {// Drift velocity | |
41 | fDriftSpeed=p1;} | |
42 | virtual Float_t DriftSpeed() const {// drift speed | |
43 | return fDriftSpeed;} | |
44 | virtual void SetParamOptions(const char *opt1,const char *opt2) { | |
45 | // Parameters: "same" or read from "file" | |
46 | fParam1=opt1; fParam2=opt2;} | |
47 | virtual void ParamOptions(char *opt1,char *opt2) const {// options | |
48 | strcpy(opt1,fParam1.Data()); strcpy(opt2,fParam2.Data());} | |
49 | ||
50 | virtual Bool_t Do10to8() const {// get 10 to 8 compression option | |
51 | return fBitComp;} | |
52 | void SetZeroSupp (const char *opt) { | |
53 | // Zero-suppression option - could be 1D, 2D or non-ZS | |
54 | fOption=opt;} | |
55 | const char *ZeroSuppOption() const {// Get zero-suppression option | |
56 | return fOption.Data();} | |
57 | // Detector type response methods | |
58 | virtual void SetNSigmaIntegration(Double_t p1) { | |
59 | // Set number of sigmas over which cluster disintegration is performed | |
60 | fNsigmas=p1;} | |
61 | virtual Float_t NSigmaIntegration() const { | |
62 | // Get number of sigmas over which cluster disintegration is performed | |
63 | return fNsigmas;} | |
64 | virtual void SetNLookUp(Int_t p1); | |
65 | // Get number of intervals in which the gaussian lookup table is divided | |
66 | virtual Int_t GausNLookUp() const {return fNcomps;} | |
67 | virtual Float_t GausLookUp(Int_t i) { | |
68 | if (!fGaus) SetNLookUp(fgkNcompsDefault); | |
69 | if(i<0 || i>=fNcomps) return 0.;return fGaus->At(i); | |
70 | } | |
71 | ||
72 | Int_t Convert8to10(Int_t signal) const; //undo 10 to 8 bit SDD compresion | |
73 | ||
74 | void SetJitterError(Float_t jitter=20) { | |
75 | // set Jitter error (20 um for ALICE from beam test measurements 2001) | |
76 | fJitterError=jitter;} | |
77 | Float_t JitterError() const {// set Jitter error | |
78 | return fJitterError;} | |
79 | void SetDo10to8(Bool_t bitcomp=kTRUE) { | |
80 | // set the option for 10 to 8 bit compression | |
81 | fBitComp = bitcomp;} | |
82 | ||
83 | protected: | |
84 | ||
85 | static const Int_t fgkMaxAdcDefault; // default for fMaxAdc | |
86 | static const Float_t fgkDynamicRangeDefault; // default for fDynamicRange | |
87 | static const Float_t fgkfChargeLossDefault; // default for fChargeLoss | |
88 | static const Float_t fgkDiffCoeffDefault; // default for fDiffCoeff | |
89 | static const Float_t fgkDiffCoeff1Default; // default for fDiffCoeff1 | |
90 | static const TString fgkParam1Default; // default for fParam1 | |
91 | static const TString fgkParam2Default; // default for fParam2 | |
92 | static const TString fgkOptionDefault; // default for fOption | |
93 | static const Float_t fgkDriftSpeedDefault; // default for fDriftSpeed | |
94 | static const Float_t fgkNsigmasDefault; //default for fNsigmas | |
95 | static const Int_t fgkNcompsDefault; //default for fNcomps | |
96 | ||
97 | ||
98 | Float_t fJitterError; // jitter error | |
99 | Float_t fDynamicRange; // Set Dynamic Range | |
100 | Float_t fChargeLoss; // Set Linear Coefficient for Charge Loss | |
101 | Float_t fDriftSpeed; // Drift velocity | |
102 | Int_t fElectronics; // Electronics | |
103 | Float_t fMaxAdc; // Adc saturation value | |
104 | Float_t fNsigmas; // Number of sigmas over which charge disintegration | |
105 | // is performed | |
106 | TArrayF *fGaus; // Gaussian lookup table for signal generation | |
107 | Int_t fNcomps; // Number of samplings along the gaussian | |
108 | Bool_t fBitComp; // 10 to 8 bit compression option | |
109 | TString fOption; // Zero-suppresion option (1D, 2D or none) | |
110 | TString fParam1; // Read baselines from file option | |
111 | TString fParam2; // Read compression algo thresholds from file | |
112 | ||
113 | private: | |
114 | ||
115 | AliITSresponseSDD(const AliITSresponseSDD &ob); // copy constructor | |
116 | AliITSresponseSDD& operator=(const AliITSresponseSDD & /* source */); // ass. op. | |
117 | ||
118 | ClassDef(AliITSresponseSDD,7) // Base response class | |
119 | ||
120 | }; | |
121 | #endif |