|
ATLAS Offline Software
|
Go to the documentation of this file.
6 #include "CLHEP/Units/SystemOfUnits.h"
48 for(
int i=0;
i<nphibins+1;
i++){
55 for(
int i = 0;
i<nbiny;
i++){
61 for(
int i = 0;
i<nbinx;
i++){
99 double frac = 0.8-0.6*ang/12;
105 errphi = 1.1*sqrt(errphi*errphi+delta*delta);
108 else if(deltax == 2){
126 if(ibin < 0)
return -1;
132 if(ibin < 0){
return -1; }
138 if(ibin < 0||m_version>-2)
return -1;
139 if(
static_cast<unsigned int>(ibin) >=
m_ibletaerror.size())
return -2;
144 if(ibin < 0||m_version>-2){
return -1; }
145 if(
static_cast<unsigned int>(ibin) >=
m_iblphierror.size()){
return -2;}
150 int phiClusterSize)
const {
154 for(
int i=0;
i<nang;
i++){
158 int nphi =
m_csx.size();
159 for(
int i=0;
i<nphi;
i++){
160 if(phiClusterSize>
m_csx[
i]) iphi=
i;
163 return nphi*iang+iphi;
167 int phiClusterSize)
const {
171 for(
int i=0;
i<neta;
i++){
175 int nphi =
m_csx.size();
176 for(
int i=0;
i<nphi;
i++){
177 if(phiClusterSize>
m_csx[
i]) iphi=
i;
181 int nz =
m_csy.size();
182 for(
int i=0;
i<nz;
i++){
183 if(etaClusterSize>
m_csy[
i]) iz=
i;
186 return nz*nphi*ieta+nz*iphi+iz;
190 int phiClusterSize)
const {
194 for(
int i=0;
i<nang;
i++){
199 if(phiClusterSize>
m_csx[
i]) iphi=
i;
209 for(
int i=0;
i<neta;
i++){
214 if(etaClusterSize>
m_csy[
i]) iz=
i;
224 const std::vector<float> &
c){
234 for(
int i=0;
i<
n1;
i++){
238 for(
int i=0;
i<n2;
i++){
256 for(
int i=0;
i<n3;
i++){
260 for(
int i=0;
i<n4;
i++){
268 for(
int i = 0;
i<nxbinsibl;
i++){
276 for(
int ib1=0; ib1<nybinsibl; ib1++){
283 for(
int i = 0;
i<nbiny;
i++){
289 for(
int i = 0;
i<nbinx;
i++){
303 std::ofstream*
outfile =
new std::ofstream(
file.c_str());
307 int ncsx =
m_csx.size();
308 int ncsy =
m_csy.size();
316 *
outfile << ncsx <<
" " << ncsy <<
" " << neta <<
" " << nalpha << std::endl;
319 for(
int i=0;
i<ncsx;
i++){
323 for(
int i=0;
i<ncsy;
i++){
337 for(
int i=0;
i<neta;
i++){
341 for(
int i=0;
i<nalpha;
i++){
347 for(
int ib1=0; ib1<nxbinsibl; ib1++){
352 int nb2=ncsx*ncsy*neta;
353 for(
int ib1=0; ib1<nb1; ib1++){
358 for(
int ib1=0; ib1<nybinsibl; ib1++){
362 for(
int ib2=0; ib2<nb2; ib2++){
393 infile >> ncsy >> neta >> nalpha;
402 infile >> ncsx >> ncsy >> neta >> nalpha;
413 for(
int i=0;
i<ncsx && !
infile.eof();
i++){
421 for(
int i=0;
i<ncsy && !
infile.eof();
i++){
445 for(
int i=0;
i<neta && !
infile.eof();
i++){
449 if(nalpha<0)nalpha = 0;
453 for(
int i=0;
i<nalpha && !
infile.eof();
i++){
461 for(
int ib1=0; ib1<nxbinsibl; ib1++){
467 int nb2=ncsx*ncsy*neta;
472 for(
int ib1=0; ib1<nb1; ib1++){
480 for(
int ib1=0; ib1<nybinsibl; ib1++){
485 for(
int ib2=0; ib2<nb2; ib2++){
int getIBLBinPhi(double angle, int phiClusterSize) const
std::vector< float > m_iblphierror
int getBarrelBinEta(double eta, int etaClusterSize, int phiClusterSize) const
int getNumberOfEtaIBLBins() const
int getIBLBinEta(double eta, int etaClusterSize) const
static double getPixelBarrelPhiError(double ang, int phiClusterSize)
std::vector< float > m_ibletaerror
PixelClusterOnTrackErrorData()
~PixelClusterOnTrackErrorData()
std::vector< float > m_ibletaref
void Print(const std::string &file) const
int getNumberOfPhiBarrelBins() const
int getVersion() const
Methods to access the calibration data.
int getBarrelBinPhi(double angle, int phiClusterSize) const
void setParameters(const int ncsx, const int ncsy, const int neta, const int nalpha, int offset, const std::vector< float > &constants)
double angle(const GeoTrf::Vector2D &a, const GeoTrf::Vector2D &b)
int getNumberOfPhiIBLBins() const
float getPixelIBLPhiError(int ibin) const
std::vector< float > m_csx
std::vector< float > m_barreletaerror
void setVersion(int version)
std::vector< float > m_barrelphierror
float getPixelBarrelEtaError(int ibin) const
int getNumberOfEtaBarrelBins() const
std::vector< float > m_etaref
std::vector< float > m_phibins
std::vector< float > m_csy
constexpr int pow(int base, int exp) noexcept
void Load(const std::string &file)
std::vector< float > m_iblphibins
float getPixelIBLEtaError(int ibin) const