]>
Commit | Line | Data |
---|---|---|
b0f5e3fc | 1 | #ifndef ALIITSRESPONSE_H |
2 | #define ALIITSRESPONSE_H | |
ac8cbb66 | 3 | /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. * |
4 | * See cxx source for full Copyright notice */ | |
5 | ||
6 | /* $Id$ */ | |
b0f5e3fc | 7 | |
b0f5e3fc | 8 | #include <TObject.h> |
703a4e51 | 9 | #include <TString.h> |
e8189707 | 10 | |
703a4e51 | 11 | class AliITSsegmentation; |
1ca7869b | 12 | class TF1; |
b0f5e3fc | 13 | class AliITSgeom; |
14 | ||
15 | //---------------------------------------------- | |
16 | // | |
17 | // ITS response virtual base class | |
18 | // | |
4efc56c1 | 19 | class AliITSresponse : public TObject { |
b0f5e3fc | 20 | public: |
4efc56c1 | 21 | // Default Constructor |
22 | AliITSresponse(); | |
23 | // Standard Constructor | |
24 | AliITSresponse(Double_t Thickness); | |
25 | // Destructor. | |
e8189707 | 26 | virtual ~AliITSresponse() {} |
b0f5e3fc | 27 | // |
28 | // Configuration methods | |
29 | // | |
30 | ||
7551c5b2 | 31 | // Set Electronics |
703a4e51 | 32 | virtual void SetElectronics(Int_t) = 0; |
7551c5b2 | 33 | // Get Electronics |
703a4e51 | 34 | virtual Int_t Electronics() const = 0; |
7551c5b2 | 35 | |
b0f5e3fc | 36 | // Set maximum Adc-count value |
703a4e51 | 37 | virtual void SetMaxAdc(Float_t) = 0; |
b0f5e3fc | 38 | // Get maximum Adc-count value |
703a4e51 | 39 | virtual Float_t MaxAdc() const = 0; |
b0f5e3fc | 40 | |
e8189707 | 41 | // Set maximum Adc-top value |
703a4e51 | 42 | virtual void SetDynamicRange(Float_t) = 0; |
e8189707 | 43 | // Get maximum Adc-top value |
703a4e51 | 44 | virtual Float_t DynamicRange() const = 0; |
7551c5b2 | 45 | |
46 | // Set Charge Loss Linear Coefficient | |
703a4e51 | 47 | virtual void SetChargeLoss(Float_t) = 0; |
7551c5b2 | 48 | // Get Charge Loss Linear Coefficient |
703a4e51 | 49 | virtual Float_t ChargeLoss() const = 0; |
ac8cbb66 | 50 | |
51 | // Set GeVcharge value | |
52 | virtual void SetGeVToCharge(Float_t gc=2.778E+8){fGeVcharge = gc;} | |
53 | // Returns the value fGeVcharge | |
54 | virtual Float_t GetGeVToCharge() const {return fGeVcharge;} | |
55 | // Converts deposited energy to number of electrons liberated | |
56 | virtual Float_t GeVToCharge(Float_t gev) const {return gev*fGeVcharge;} | |
b0f5e3fc | 57 | |
58 | // Diffusion coefficient | |
703a4e51 | 59 | virtual void SetDiffCoeff(Float_t, Float_t) = 0; |
e8189707 | 60 | // Get diffusion coefficients |
703a4e51 | 61 | virtual void DiffCoeff(Float_t &,Float_t &) const = 0; |
b0f5e3fc | 62 | |
4efc56c1 | 63 | // Temperature in [degree K] |
64 | virtual void SetTemperature(Float_t t=300.0) {fT = t;} | |
65 | // Get temperature [degree K] | |
ac8cbb66 | 66 | virtual Float_t Temperature() const {return fT;} |
b0f5e3fc | 67 | // Type of data - real or simulated |
703a4e51 | 68 | virtual void SetDataType(const char *data="simulated") {fDataType=data;} |
4efc56c1 | 69 | // Set the impurity concentrations in [#/cm^3] |
70 | virtual void SetImpurity(Double_t n=0.0){fN = n;} | |
71 | // Returns the impurity consentration in [#/cm^3] | |
ac8cbb66 | 72 | virtual Double_t Impurity() const {return fN;} |
4efc56c1 | 73 | // Sets the applied ratio distance/voltage [cm/volt] |
74 | virtual void SetDistanceOverVoltage(Double_t d,Double_t v){fdv = d/v;} | |
75 | // Sets the applied ration distance/voltage [cm/volt]. Default value | |
76 | // is 300E-4cm/80 volts = 0.000375 cm/volts | |
77 | virtual void SetDistanceOverVoltage(Double_t dv=0.000375){fdv = dv;} | |
78 | // Returns the ration distance/voltage | |
ac8cbb66 | 79 | virtual Double_t DistanceOverVoltage() const {return fdv;} |
b0f5e3fc | 80 | // Get data type |
703a4e51 | 81 | virtual const char *DataType() const {return fDataType.Data();} |
b0f5e3fc | 82 | |
4efc56c1 | 83 | // Set parameters options: "same" or read from "file" or "SetInvalid" or... |
703a4e51 | 84 | virtual void SetParamOptions(const char*,const char*) = 0; |
e8189707 | 85 | // Set noise parameters |
703a4e51 | 86 | virtual void SetNoiseParam(Float_t, Float_t) = 0; |
b0f5e3fc | 87 | // Number of parameters to be set |
703a4e51 | 88 | virtual void SetNDetParam(Int_t) = 0; |
e8189707 | 89 | // Set detector parameters: gain, coupling ... |
703a4e51 | 90 | virtual void SetDetParam(Float_t *) = 0; |
b0f5e3fc | 91 | |
92 | // Parameters options | |
703a4e51 | 93 | virtual void ParamOptions(char *,char*) const = 0; |
94 | virtual Int_t NDetParam() const = 0; | |
95 | virtual void GetDetParam(Float_t *) const = 0; | |
96 | virtual void GetNoiseParam(Float_t&, Float_t&) const = 0; | |
b0f5e3fc | 97 | |
4efc56c1 | 98 | // Zero-suppression option - could be 1D, 2D or non-ZeroSuppressed |
703a4e51 | 99 | virtual void SetZeroSupp(const char*) = 0; |
b0f5e3fc | 100 | // Get zero-suppression option |
703a4e51 | 101 | virtual const char *ZeroSuppOption() const = 0; |
b0f5e3fc | 102 | // Set thresholds |
703a4e51 | 103 | virtual void SetThresholds(Float_t, Float_t) = 0; |
104 | virtual void Thresholds(Float_t &, Float_t &) const = 0; | |
b0f5e3fc | 105 | |
106 | // Set filenames | |
703a4e51 | 107 | virtual void SetFilenames(const char *f1="",const char *f2="",const char *f3=""){ |
108 | // Set filenames - input, output, parameters .... | |
109 | fFileName1=f1; fFileName2=f2; fFileName3=f3;} | |
b0f5e3fc | 110 | // Filenames |
703a4e51 | 111 | virtual void Filenames(char* input,char* baseline,char* param) { |
112 | strcpy(input,fFileName1.Data()); strcpy(baseline,fFileName2.Data()); | |
113 | strcpy(param,fFileName3.Data());} | |
114 | ||
115 | virtual void SetDriftSpeed(Float_t p1) = 0; | |
116 | virtual Float_t DriftSpeed() const = 0; | |
117 | virtual void SetOutputOption(Bool_t write=kFALSE) {// set output option | |
118 | fWrite = write;} | |
119 | virtual Bool_t OutputOption() const {return fWrite;} | |
ac8cbb66 | 120 | virtual Bool_t Do10to8() const {return kTRUE;} |
703a4e51 | 121 | virtual void GiveCompressParam(Int_t *) const =0; |
4efc56c1 | 122 | // |
b0f5e3fc | 123 | // Detector type response methods |
124 | // Set number of sigmas over which cluster disintegration is performed | |
703a4e51 | 125 | virtual void SetNSigmaIntegration(Float_t) = 0; |
b0f5e3fc | 126 | // Get number of sigmas over which cluster disintegration is performed |
703a4e51 | 127 | virtual Float_t NSigmaIntegration() const = 0; |
7551c5b2 | 128 | // Set number of bins for the gaussian lookup table |
703a4e51 | 129 | virtual void SetNLookUp(Int_t) = 0; |
7551c5b2 | 130 | // Get number of bins for the gaussian lookup table |
ac8cbb66 | 131 | virtual Int_t GausNLookUp() const {return 0;} |
7551c5b2 | 132 | // Get scaling factor for bin i-th from the gaussian lookup table |
ac8cbb66 | 133 | virtual Float_t GausLookUp(Int_t) const {return 0.;} |
b0f5e3fc | 134 | // Set sigmas of the charge spread function |
703a4e51 | 135 | virtual void SetSigmaSpread(Float_t, Float_t) = 0; |
4efc56c1 | 136 | // Get sigmas for the charge spread |
703a4e51 | 137 | virtual void SigmaSpread(Float_t &,Float_t &) const = 0; |
b0f5e3fc | 138 | // Pulse height from scored quantity (eloss) |
ac8cbb66 | 139 | virtual Float_t IntPH(Float_t) const {return 0.;} |
4efc56c1 | 140 | // Charge disintegration |
ac8cbb66 | 141 | virtual Float_t IntXZ(AliITSsegmentation *) const {return 0.;} |
4efc56c1 | 142 | // Electron mobility in Si. [cm^2/(Volt Sec)]. T in degree K, N in #/cm^3 |
ac8cbb66 | 143 | virtual Double_t MobilityElectronSiEmp() const ; |
4efc56c1 | 144 | // Hole mobility in Si. [cm^2/(Volt Sec)] T in degree K, N in #/cm^3 |
ac8cbb66 | 145 | virtual Double_t MobilityHoleSiEmp() const ; |
4efc56c1 | 146 | // Einstein relation for Diffusion Coefficient of Electrons. [cm^2/sec] |
147 | // T in degree K, N in #/cm^3 | |
ac8cbb66 | 148 | virtual Double_t DiffusionCoefficientElectron() const ; |
4efc56c1 | 149 | // Einstein relation for Diffusion Coefficient of Holes. [cm^2/sec] |
150 | // T in [degree K], N in [#/cm^3] | |
ac8cbb66 | 151 | virtual Double_t DiffusionCoefficientHole() const ; |
4efc56c1 | 152 | // Electron <speed> under an applied electric field E=Volts/cm. [cm/sec] |
153 | // d distance-thickness in [cm], v in [volts], T in [degree K], | |
154 | // N in [#/cm^3] | |
ac8cbb66 | 155 | virtual Double_t SpeedElectron() const ; |
4efc56c1 | 156 | // Holes <speed> under an applied electric field E=Volts/cm. [cm/sec] |
157 | // d distance-thickness in [cm], v in [volts], T in [degree K], | |
158 | // N in [#/cm^3] | |
ac8cbb66 | 159 | virtual Double_t SpeedHole() const ; |
4efc56c1 | 160 | // Returns the Gaussian sigma == <x^2+z^2> [cm^2] due to the defusion of |
161 | // electrons or holes through a distance l [cm] caused by an applied | |
162 | // voltage v [volt] through a distance d [cm] in any material at a | |
163 | // temperature T [degree K]. | |
703a4e51 | 164 | virtual Double_t SigmaDiffusion3D(Double_t l) const ; |
4efc56c1 | 165 | // Returns the Gaussian sigma == <x^2 +y^2+z^2> [cm^2] due to the |
166 | // defusion of electrons or holes through a distance l [cm] caused by an | |
167 | // applied voltage v [volt] through a distance d [cm] in any material at a | |
168 | // temperature T [degree K]. | |
703a4e51 | 169 | virtual Double_t SigmaDiffusion2D(Double_t l) const ; |
4efc56c1 | 170 | // Returns the Gaussian sigma == <x^2+z^2> [cm^2] due to the defusion of |
171 | // electrons or holes through a distance l [cm] caused by an applied | |
172 | // voltage v [volt] through a distance d [cm] in any material at a | |
173 | // temperature T [degree K]. | |
703a4e51 | 174 | virtual Double_t SigmaDiffusion1D(Double_t l) const ; |
ac8cbb66 | 175 | // Prints out the content of this class in ASCII format. |
703a4e51 | 176 | virtual void Print(ostream *os) const; |
ac8cbb66 | 177 | // Reads in the content of this class in the format of Print |
178 | virtual void Read(istream *is); | |
703a4e51 | 179 | protected: |
180 | void NotImplemented(const char *method) const {if(gDebug>0) | |
181 | Warning(method,"This method is not implemented for this sub-class");} | |
182 | ||
183 | TString fDataType; // data type - real or simulated | |
4efc56c1 | 184 | private: |
185 | Double_t fdv; // The parameter d/v where d is the disance over which the | |
186 | // the potential v is applied d/v [cm/volts] | |
187 | Double_t fN; // the impurity consentration of the material in #/cm^3 | |
188 | Double_t fT; // The temperature of the Si in Degree K. | |
ac8cbb66 | 189 | Double_t fGeVcharge; // Energy to ionize (free an electron). |
703a4e51 | 190 | TString fFileName1; // input keys : run, module # |
191 | TString fFileName2; // baseline & noise val or output code | |
192 | // signal or monitored bgr. | |
193 | TString fFileName3; // param values or output coded signal | |
194 | Bool_t fWrite; // Write option for the compression algorithms | |
4efc56c1 | 195 | |
196 | ClassDef(AliITSresponse,2) // Detector type response virtual base class | |
b0f5e3fc | 197 | }; |
ac8cbb66 | 198 | // Input and output function for standard C++ input/output. |
199 | ostream& operator<<(ostream &os,AliITSresponse &source); | |
200 | istream& operator>>(istream &os,AliITSresponse &source); | |
b0f5e3fc | 201 | #endif |