]>
Commit | Line | Data |
---|---|---|
b0f5e3fc | 1 | #ifndef ALIITSRESPONSESDD_H |
2 | #define ALIITSRESPONSESDD_H | |
3 | ||
4 | #include "AliITSresponse.h" | |
5 | ||
1ca7869b | 6 | class TString; |
7 | ||
b0f5e3fc | 8 | // response for SDD |
9 | ||
10 | class AliITSresponseSDD : | |
11 | public AliITSresponse { | |
12 | public: | |
13 | // | |
14 | // Configuration methods | |
15 | // | |
16 | ||
17 | AliITSresponseSDD(); | |
18 | virtual ~AliITSresponseSDD() { | |
19 | // destructor | |
20 | } | |
21 | AliITSresponseSDD(const AliITSresponseSDD &source); // copy constructor | |
22 | AliITSresponseSDD& operator=(const AliITSresponseSDD &source); // ass. op. | |
23 | ||
e8189707 | 24 | virtual void SetMaxAdc(Float_t p1=1024) { |
b0f5e3fc | 25 | // Adc-count saturation value |
26 | fMaxAdc=p1; | |
27 | } | |
28 | virtual Float_t MaxAdc() { | |
29 | // Get maximum Adc-count value | |
30 | return fMaxAdc; | |
31 | } | |
32 | ||
90dea86a | 33 | virtual void SetMagicValue(Float_t p1=900.) { |
e8189707 | 34 | // Set maximum Adc-top value |
b0f5e3fc | 35 | fTopValue=p1; |
90dea86a | 36 | //it was 96.95 |
b0f5e3fc | 37 | } |
38 | virtual Float_t MagicValue() { | |
e8189707 | 39 | // Get maximum Adc-top value |
b0f5e3fc | 40 | return fTopValue; |
41 | } | |
42 | ||
e8189707 | 43 | virtual void SetDiffCoeff(Float_t p1=2.8,Float_t p2=28.) { |
44 | // Diffusion coefficients | |
b0f5e3fc | 45 | fDiffCoeff=p1; |
e8189707 | 46 | fDiffCoeff1=p2; |
b0f5e3fc | 47 | } |
e8189707 | 48 | virtual void DiffCoeff(Float_t&diff,Float_t&diff1) { |
49 | // Get diffusion coefficients | |
50 | diff = fDiffCoeff; | |
51 | diff1 = fDiffCoeff1; | |
b0f5e3fc | 52 | } |
53 | ||
b0f5e3fc | 54 | virtual void SetDriftSpeed(Float_t p1=7.5) { |
55 | // Drift velocity | |
56 | fDriftSpeed=p1; | |
57 | } | |
58 | virtual Float_t DriftSpeed() { | |
59 | // drift speed | |
60 | return fDriftSpeed; | |
61 | } | |
62 | ||
63 | virtual void SetTemperature(Float_t p1=23.) { | |
64 | // Temperature | |
65 | fTemperature=p1; | |
66 | } | |
67 | virtual Float_t Temperature() { | |
68 | // Get temperature | |
69 | return fTemperature; | |
70 | } | |
71 | ||
e8189707 | 72 | virtual void SetDataType(const char *data="simulated") { |
b0f5e3fc | 73 | // Type of data - real or simulated |
74 | fDataType=data; | |
75 | } | |
e8189707 | 76 | virtual const char *DataType() const { |
b0f5e3fc | 77 | // Get data type |
e8189707 | 78 | return fDataType.Data(); |
b0f5e3fc | 79 | } |
80 | ||
e8189707 | 81 | virtual void SetParamOptions(const char *opt1="same",const char *opt2="same"){ |
b0f5e3fc | 82 | // Parameters: "same" or read from "file" |
83 | fParam1=opt1; fParam2=opt2; | |
84 | } | |
e8189707 | 85 | virtual void ParamOptions(char *opt1,char *opt2) { |
b0f5e3fc | 86 | // options |
e8189707 | 87 | strcpy(opt1,fParam1.Data()); strcpy(opt2,fParam2.Data()); |
b0f5e3fc | 88 | } |
89 | ||
90dea86a | 90 | virtual void SetNoiseParam(Float_t n=1.75, Float_t b=10.){ |
b0f5e3fc | 91 | // Noise and baseline |
92 | fNoise=n; fBaseline=b; | |
93 | } | |
94 | virtual void GetNoiseParam(Float_t &n, Float_t &b) { | |
95 | // get noise param | |
96 | n=fNoise; b=fBaseline; | |
fa1750f9 | 97 | } |
98 | ||
99 | virtual void SetDo10to8(Bool_t bitcomp=kTRUE) { | |
100 | // set the option for 10 to 8 bit compression | |
101 | fBitComp = bitcomp; | |
102 | } | |
103 | ||
104 | Bool_t Do10to8() { | |
105 | // get 10 to 8 compression option | |
106 | return fBitComp; | |
b0f5e3fc | 107 | } |
108 | ||
e8189707 | 109 | virtual void SetZeroSupp (const char *opt="2D") { |
b0f5e3fc | 110 | // Zero-suppression option - could be 1D, 2D or non-ZS |
111 | fOption=opt; | |
112 | } | |
e8189707 | 113 | virtual const char *ZeroSuppOption() const { |
b0f5e3fc | 114 | // Get zero-suppression option |
e8189707 | 115 | return fOption.Data(); |
b0f5e3fc | 116 | } |
117 | virtual void SetMinVal(Int_t mv=4) { | |
118 | // Min value used in 2D - could be used as a threshold setting | |
119 | fMinVal = mv; | |
120 | } | |
121 | virtual Int_t MinVal() { | |
122 | // min val | |
123 | return fMinVal; | |
124 | } | |
125 | ||
e8189707 | 126 | virtual void SetFilenames(const char *f1="",const char *f2="",const char *f3="") { |
b0f5e3fc | 127 | // Set filenames - input, output, parameters .... |
128 | fFileName1=f1; fFileName2=f2; fFileName3=f3; | |
129 | } | |
e8189707 | 130 | virtual void Filenames(char *input,char *baseline,char *param) { |
b0f5e3fc | 131 | // Filenames |
e8189707 | 132 | strcpy(input,fFileName1.Data()); strcpy(baseline,fFileName2.Data()); |
133 | strcpy(param,fFileName3.Data()); | |
b0f5e3fc | 134 | } |
135 | ||
136 | ||
137 | virtual void SetOutputOption(Bool_t write=kFALSE) { | |
138 | // set output option | |
139 | fWrite = write; | |
140 | } | |
141 | Bool_t OutputOption() { | |
142 | // output option | |
143 | return fWrite; | |
144 | } | |
145 | // | |
146 | // Compression parameters | |
147 | virtual void SetCompressParam(Int_t cp[8]); | |
148 | void GiveCompressParam(Int_t *x); | |
149 | ||
150 | // | |
151 | // Detector type response methods | |
e8189707 | 152 | virtual void SetNSigmaIntegration(Float_t p1=4.) { |
b0f5e3fc | 153 | // Set number of sigmas over which cluster disintegration is performed |
e8189707 | 154 | fNsigmas=p1; |
b0f5e3fc | 155 | } |
156 | virtual Float_t NSigmaIntegration() { | |
157 | // Get number of sigmas over which cluster disintegration is performed | |
e8189707 | 158 | return fNsigmas; |
b0f5e3fc | 159 | } |
160 | virtual void SetSigmaSpread(Float_t p1, Float_t p2) { | |
161 | // Set sigmas of the charge spread function | |
162 | } | |
163 | virtual void SigmaSpread(Float_t &s1, Float_t &s2) { | |
164 | // Get sigmas for the charge spread | |
165 | } | |
166 | ||
167 | virtual Float_t IntPH(Float_t eloss) { | |
168 | // Pulse height from scored quantity (eloss) | |
169 | return 0.; | |
170 | } | |
171 | virtual Float_t IntXZ(AliITSsegmentation *) { | |
172 | // Charge disintegration | |
173 | return 0.; | |
174 | } | |
175 | ||
176 | ||
177 | protected: | |
178 | ||
179 | Int_t fCPar[8]; // Hardware compression parameters | |
b0f5e3fc | 180 | |
181 | Float_t fNoise; // Noise | |
182 | Float_t fBaseline; // Baseline | |
183 | Float_t fTopValue; // still unclear to me | |
184 | Float_t fTemperature; // Temperature | |
185 | Float_t fDriftSpeed; // Drift velocity | |
186 | ||
187 | Float_t fMaxAdc; // Adc saturation value | |
e8189707 | 188 | Float_t fDiffCoeff; // Diffusion Coefficient (scaling the time) |
189 | Float_t fDiffCoeff1; // Diffusion Coefficient (constant term) | |
190 | Float_t fNsigmas; // Number of sigmas over which charge disintegration | |
191 | // is performed | |
b0f5e3fc | 192 | |
193 | Int_t fZeroSuppFlag; // Zero-suppression flag | |
194 | Int_t fMinVal; // Min value used in 2D zero-suppression algo | |
195 | ||
196 | Bool_t fWrite; // Write option for the compression algorithms | |
fa1750f9 | 197 | Bool_t fBitComp; // 10 to 8 bit compression option |
198 | ||
e8189707 | 199 | TString fOption; // Zero-suppresion option (1D, 2D or none) |
200 | TString fParam1; // Read baselines from file option | |
201 | TString fParam2; // Read compression algo thresholds from file | |
202 | ||
203 | TString fDataType; // data type - real or simulated | |
204 | TString fFileName1; // input keys : run, module # | |
205 | TString fFileName2; // baseline & noise val or output coded // signal or monitored bgr. | |
206 | TString fFileName3; // param values or output coded signal | |
b0f5e3fc | 207 | |
208 | ClassDef(AliITSresponseSDD,1) // SDD response | |
209 | ||
210 | }; | |
211 | #endif | |
212 | ||
213 | ||
214 | ||
215 | ||
216 | ||
217 | ||
218 |