|
ATLAS Offline Software
|
Go to the documentation of this file.
8 #include "CLHEP/Units/SystemOfUnits.h"
28 for(
int i=0;
i<netabins+1;
i++){
33 for(
int i=0;
i<nphibins+1;
i++){
38 for(
int i=0;
i<ncs+1;
i++){
49 for(
int i=0;
i<nxbin;
i++){
53 for(
int i=0;
i<nybin;
i++){
75 const std::vector<float> &
c){
85 for(
int i=0;
i<
n1+1;
i++){
89 for(
int i=0;
i<n2+1;
i++){
107 for(
int i=0;
i<n3+1;
i++){
111 for(
int i=0;
i<n4+1;
i++){
128 for(
int i=0;
i<nxbin;
i++){
132 for(
int i=0;
i<nybin;
i++){
150 if(
static_cast<unsigned int>(
i) >
m_deltax.size()-1)
return 0;
157 if(
static_cast<unsigned int>(
i) >
m_deltay.size()-1)
return 0;
164 if(
static_cast<unsigned int>(
i) >
m_deltax.size()-1)
return 0;
172 if(
static_cast<unsigned int>(
i) >
m_deltay.size()-1)
return 0;
181 if(
static_cast<unsigned int>(
i) >
m_errdeltax.size()-1)
return 0;
188 if(
static_cast<unsigned int>(
i) >
m_errdeltay.size()-1)
return 0;
195 if(
static_cast<unsigned int>(
i) >
m_errdeltax.size()-1)
return 0;
203 if(
static_cast<unsigned int>(
i) >
m_errdeltay.size()-1)
return 0;
236 int iclustersize,
int ilayer)
const{
238 if(ibin < 0)
return 0;
243 int iclustersize,
int ilayer)
const{
245 if(ibin < 0)
return 0;
250 int iclustersize,
int ilayer,
253 if(ibin < 0)
return 0;
258 int iclustersize,
int ilayer,
261 if(ibin < 0)
return 0;
269 int iclustersize,
int ilayer)
const{
271 if(ibin < 0)
return 0;
276 int iclustersize,
int ilayer)
const{
278 if(ibin < 0)
return 0;
283 int iclustersize,
int ilayer,
286 if(ibin < 0)
return 0;
291 int iclustersize,
int ilayer,
294 if(ibin < 0)
return 0;
321 for(
int i=0;
i<nphi;
i++){
330 for(
int i=0;
i<nphi;
i++){
333 int ncsx =
m_csx.size();
334 if(nrows>
m_csx[ncsx-1])
return -1;
335 if(nrows<
m_csx[0])
return -1;
336 for(
int i=0;
i<ncsx;
i++){
357 for(
int i=0;
i<neta;
i++){
369 for(
int i=0;
i<neta;
i++){
372 int ncsy =
m_csy.size();
373 if(ncol <
m_csy[0])
return -1;
374 if(ncol >
m_csy[ncsy-1])
return -1;
375 for(
int i=0;
i<ncsy;
i++){
392 int dl = (ilayer>0) ? 1 : 0;
393 if(nrows >
int(
m_csx.size()-1) || nrows < 0 ||
396 int ncsx =
m_csx.size();
409 int dl = (ilayer>0) ? 1 : 0;
410 if(ncol >
int(
m_csy.size()-1) || ncol < 0 ||
413 int ncsy =
m_csy.size();
423 std::ofstream*
outfile =
new std::ofstream(
file.c_str());
429 int ncsx =
m_csx.size()-1;
430 int ncsy =
m_csy.size()-1;
443 *
outfile <<ncsx<<
" "<<ncsy<<
" "<<neta<<
" "<<nalpha<<std::endl;
517 if(nybins<0)nybins = 0;
542 infile >> ncsx >> ncsy >> neta >> nalpha;
552 m_csx.reserve(ncsx+1);
553 for(
int i=0;
i<ncsx+1 && !
infile.eof();
i++){
560 m_csy.reserve(ncsy+1);
561 for(
int i=0;
i<ncsy+1 && !
infile.eof();
i++){
586 for(
int i=0;
i<neta+1 && !
infile.eof();
i++){
591 if(nalpha<0)nalpha = 0;
594 for(
int i=0;
i<nalpha+1 && !
infile.eof();
i++){
601 int nxbins = 6*ncsx*nalpha + nxbinsibl;
602 int nybins = 6*ncsy*neta + nybinsibl;
607 if(nxbins<0)nxbins = 0;
609 if(nybins<0)nybins = 0;
int getBarrelBinX(int iclustersize, float angle, int ilayer) const
Get the global bin index as a function of the value of the variables of the parametrization.
std::vector< float > m_csy
int setDeltaY(int ieta, int iclustersize, int ilayer, float value)
void setParameters(const int ncsx, const int ncsy, const int neta, const int nalpha, int offset, const std::vector< float > &constants)
std::vector< float > m_iblphibins
float getDeltaY(int ieta, int iclustersize, int ilayer) const
std::vector< float > m_deltay
std::vector< float > m_ibletabins
void Load(const std::string &filename)
float getDeltaX(int iangle, int iclustersize, int ilayer) const
methods to get/set the calibration data as a function of the bin index for the various variables sepa...
static float getDeltaYendcap()
int getNumberOfYbins() const
int getNumberOfXbins() const
PixelChargeInterpolationParameters()
int getBarrelBinY(int iclustersize, float eta, int ilayer) const
void setVersion(int version)
float getErrDeltaY(int ieta, int iclustersize, int ilayer) const
void Print(const std::string &filename) const
int setErrDeltaY(int ieta, int iclustersize, int ilayer, float value)
float getDeltaYbarrel(int nCol, float eta, int ilayer=0) const
float getDeltaXbarrel(int nRows, float angle, int ilayer=0) const
Methods to access the calibration data as a function of the cluster size, angle/pseudorapidity,...
std::vector< float > m_csx
float getErrDeltaX(int iangle, int iclustersize, int ilayer) const
methods to get/set the calibration data as a function of the bin index for the various variables sepa...
int setDeltaX(int iangle, int iclustersize, int ilayer, float value)
std::vector< float > m_etabins
std::vector< float > m_phibins
std::vector< float > m_deltax
std::vector< float > m_errdeltay
static float getDeltaXendcap()
int setErrDeltaX(int iangle, int iclustersize, int ilayer, float value)
std::vector< float > m_errdeltax