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