]>
Commit | Line | Data |
---|---|---|
cd2a0045 | 1 | /************************************************************************** |
2 | * Copyright(c) 2007-2009, ALICE Experiment at CERN, All rights reserved. * | |
3 | * * | |
4 | * Author: The ALICE Off-line Project. * | |
5 | * Contributors are mentioned in the code where appropriate. * | |
6 | * * | |
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 | **************************************************************************/ | |
15 | ||
16 | /* $Id:$ */ | |
17 | ||
18 | /////////////////////////////////////////////////////////////////// | |
19 | // // | |
20 | // Implementation of the class to store the parameters used in // | |
21 | // the simulation of SPD, SDD and SSD detectors // | |
22 | // Origin: F.Prino, Torino, prino@to.infn.it // | |
23 | // // | |
24 | /////////////////////////////////////////////////////////////////// | |
25 | ||
26 | #include "AliITSSimuParam.h" | |
27 | #include <TMath.h> | |
28 | ||
29 | const Float_t AliITSSimuParam::fgkSPDBiasVoltageDefault = 18.182; | |
30 | const Double_t AliITSSimuParam::fgkSPDThreshDefault = 3000.; | |
31 | const Double_t AliITSSimuParam::fgkSPDSigmaDefault = 250.; | |
32 | const TString AliITSSimuParam::fgkSPDCouplingOptDefault = "old"; | |
33 | const Double_t AliITSSimuParam::fgkSPDCouplColDefault = 0.; | |
34 | const Double_t AliITSSimuParam::fgkSPDCouplRowDefault = 0.055; | |
35 | const Float_t AliITSSimuParam::fgkSPDEccDiffDefault = 0.85; | |
36 | const Float_t AliITSSimuParam::fgkSDDDiffCoeffDefault = 3.23; | |
37 | const Float_t AliITSSimuParam::fgkSDDDiffCoeff1Default = 30.; | |
38 | const Float_t AliITSSimuParam::fgkSDDJitterErrorDefault = 20.; // 20 um from beam test 2001 | |
39 | const Float_t AliITSSimuParam::fgkSDDDynamicRangeDefault = 132.; | |
40 | const Int_t AliITSSimuParam::fgkSDDMaxAdcDefault = 1024; | |
41 | const Float_t AliITSSimuParam::fgkSDDChargeLossDefault = 0.; | |
42 | const Double_t AliITSSimuParam::fgkSSDCouplingPRDefault = 0.01; | |
43 | const Double_t AliITSSimuParam::fgkSSDCouplingPLDefault = 0.01; | |
44 | const Double_t AliITSSimuParam::fgkSSDCouplingNRDefault = 0.01; | |
45 | const Double_t AliITSSimuParam::fgkSSDCouplingNLDefault = 0.01; | |
46 | const Int_t AliITSSimuParam::fgkSSDZSThresholdDefault = 3; | |
47 | ||
48 | const Float_t AliITSSimuParam::fgkNsigmasDefault = 3.; | |
49 | const Int_t AliITSSimuParam::fgkNcompsDefault = 121; | |
50 | ||
51 | ClassImp(AliITSSimuParam) | |
52 | ||
53 | //______________________________________________________________________ | |
54 | AliITSSimuParam::AliITSSimuParam(): | |
55 | TObject(), | |
56 | fGeVcharge(0.), | |
57 | fDOverV(0.), | |
58 | fSPDBiasVoltage(fgkSPDBiasVoltageDefault), | |
59 | fSPDThresh(fgkSPDThreshDefault), | |
60 | fSPDSigma(fgkSPDSigmaDefault), | |
61 | fSPDCouplOpt(0), | |
62 | fSPDCouplCol(fgkSPDCouplColDefault), | |
63 | fSPDCouplRow(fgkSPDCouplRowDefault), | |
64 | fSPDEccDiff(0.), | |
65 | fSDDElectronics(0), | |
66 | fSDDDiffCoeff(0.), | |
67 | fSDDDiffCoeff1(0.), | |
68 | fSDDJitterError(fgkSDDJitterErrorDefault), | |
69 | fSDDDynamicRange(fgkSDDDynamicRangeDefault), | |
70 | fSDDMaxAdc(0.), | |
71 | fSDDChargeLoss(fgkSDDChargeLossDefault), | |
72 | fSSDADCpereV(0.), | |
73 | fSSDCouplingPR(0), | |
74 | fSSDCouplingPL(0), | |
75 | fSSDCouplingNR(0), | |
76 | fSSDCouplingNL(0), | |
77 | fSSDZSThreshold(fgkSSDZSThresholdDefault), | |
78 | fNsigmas(fgkNsigmasDefault), | |
79 | fNcomps(fgkNcompsDefault), | |
80 | fGaus() | |
81 | { | |
82 | // default constructor | |
83 | SetGeVToCharge(); | |
84 | SetDistanceOverVoltage(); | |
85 | SetSPDCouplingOption(fgkSPDCouplingOptDefault); | |
86 | SetSPDSigmaDiffusionAsymmetry(fgkSPDEccDiffDefault); | |
87 | SetSDDElectronics(); | |
88 | SetSDDDiffCoeff(fgkSDDDiffCoeffDefault,fgkSDDDiffCoeff1Default); | |
89 | SetSDDMaxAdc((Double_t)fgkSDDMaxAdcDefault); | |
90 | SetSSDADCpereV(); | |
91 | SetSSDCouplings(fgkSSDCouplingPRDefault,fgkSSDCouplingPLDefault,fgkSSDCouplingNRDefault,fgkSSDCouplingNLDefault); | |
92 | } | |
93 | //______________________________________________________________________ | |
94 | AliITSSimuParam::AliITSSimuParam(const AliITSSimuParam &simpar): | |
95 | TObject(), | |
96 | fGeVcharge(simpar.fGeVcharge), | |
97 | fDOverV(simpar.fDOverV), | |
98 | fSPDBiasVoltage(simpar.fSPDBiasVoltage), | |
99 | fSPDThresh(simpar.fSPDThresh), | |
100 | fSPDSigma(simpar.fSPDSigma), | |
101 | fSPDCouplOpt(simpar.fSPDCouplOpt), | |
102 | fSPDCouplCol(simpar.fSPDCouplCol), | |
103 | fSPDCouplRow(simpar.fSPDCouplRow), | |
104 | fSPDEccDiff(simpar.fSPDEccDiff), | |
105 | fSDDElectronics(simpar.fSDDElectronics), | |
106 | fSDDDiffCoeff(simpar.fSDDDiffCoeff), | |
107 | fSDDDiffCoeff1(simpar.fSDDDiffCoeff1), | |
108 | fSDDJitterError(simpar.fSDDJitterError), | |
109 | fSDDDynamicRange(simpar.fSDDDynamicRange), | |
110 | fSDDMaxAdc(simpar.fSDDMaxAdc), | |
111 | fSDDChargeLoss(simpar.fSDDChargeLoss), | |
112 | fSSDADCpereV(simpar.fSSDADCpereV), | |
113 | fSSDCouplingPR(simpar.fSSDCouplingPR), | |
114 | fSSDCouplingPL(simpar.fSSDCouplingPL), | |
115 | fSSDCouplingNR(simpar.fSSDCouplingNR), | |
116 | fSSDCouplingNL(simpar.fSSDCouplingNL), | |
117 | fSSDZSThreshold(simpar.fSSDZSThreshold), | |
118 | fNsigmas(simpar.fNsigmas), | |
119 | fNcomps(simpar.fNcomps), | |
120 | fGaus(){ | |
121 | // copy constructor | |
122 | } | |
123 | ||
124 | //______________________________________________________________________ | |
125 | AliITSSimuParam& AliITSSimuParam::operator=(const AliITSSimuParam& source){ | |
126 | // Assignment operator. | |
127 | this->~AliITSSimuParam(); | |
128 | new(this) AliITSSimuParam(source); | |
129 | return *this; | |
130 | ||
131 | } | |
132 | ||
133 | ||
134 | //______________________________________________________________________ | |
135 | AliITSSimuParam::~AliITSSimuParam() { | |
136 | // destructor | |
137 | if(fGaus) delete fGaus; | |
138 | } | |
139 | //________________________________________________________________________ | |
140 | void AliITSSimuParam::SetNLookUp(Int_t p1){ | |
141 | // Set number of sigmas over which cluster disintegration is performed | |
142 | fNcomps=p1; | |
143 | if (fGaus) delete fGaus; | |
144 | fGaus = new TArrayF(fNcomps+1); | |
145 | for(Int_t i=0; i<=fNcomps; i++) { | |
146 | Float_t x = -fNsigmas + (2.*i*fNsigmas)/(fNcomps-1); | |
147 | (*fGaus)[i] = exp(-((x*x)/2)); | |
148 | } | |
149 | } | |
150 | //________________________________________________________________________ | |
151 | void AliITSSimuParam::PrintParameters() const{ | |
152 | printf("GeVToCharge = %G\n",fGeVcharge); | |
153 | printf("DistanveOverVoltage = %f \n",fDOverV); | |
154 | printf("\n"); | |
155 | printf("===== SPD parameters =====\n"); | |
156 | printf("Bias Voltage = %f \n",fSPDBiasVoltage); | |
157 | printf("Threshold and sigma = %f %f\n",fSPDThresh,fSPDSigma); | |
158 | printf("Coupling Option = %s\n",fSPDCouplOpt.Data()); | |
159 | printf("Coupling value (column) = %f\n",fSPDCouplCol); | |
160 | printf("Coupling value (row) = %f\n",fSPDCouplRow); | |
161 | printf("Eccentricity in diffusion = %f\n",fSPDEccDiff); | |
162 | printf("\n"); | |
163 | printf("===== SDD parameters =====\n"); | |
164 | printf("Electronic chips = %d\n",fSDDElectronics); | |
165 | printf("Diffusion Coefficients = %f %f\n",fSDDDiffCoeff,fSDDDiffCoeff1); | |
166 | printf("Jitter Error = %f um\n",fSDDJitterError); | |
167 | printf("Dynamic Range = %f\n",fSDDDynamicRange); | |
168 | printf("Max. ADC = %f\n",fSDDMaxAdc); | |
169 | printf("Charge Loss = %f\n",fSDDChargeLoss); | |
170 | printf("\n"); | |
171 | printf("===== SSD parameters =====\n"); | |
172 | printf("ADC per eV = %f\n",fSSDADCpereV); | |
173 | printf("Coupling PR = %f\n",fSSDCouplingPR); | |
174 | printf("Coupling PL = %f\n",fSSDCouplingPL); | |
175 | printf("Coupling NR = %f\n",fSSDCouplingNR); | |
176 | printf("Coupling NL = %f\n",fSSDCouplingNL); | |
177 | printf("Zero Supp threshold = %d\n",fSSDZSThreshold); | |
178 | } |