1 #ifndef __HiEvtPlaneFlatten__
2 #define __HiEvtPlaneFlatten__
75 if(centbin < 0 )
return -1;
78 if(vtx < minvtx_ || ivtx >=
nvtxbins_)
return -1;
80 if(cut<0 || cut>=
hbins_)
return -1;
87 if(centbin < 0 )
return -1;
90 if(ivtx < 0 || ivtx >
nvtxbins_)
return -1;
91 cut = nvtxbins_*ibin + ivtx ;
92 if(cut<0 || cut>
hbins_)
return -1;
96 void fill(
double psi,
double vtx,
int centbin)
98 if(fabs(psi)>4 )
return;
120 void fillPt(
double ptval,
double vtx,
int centbin)
125 pt2_[indx]+=ptval*ptval;
138 double caloCentRefVal_ = 0;
139 for(
int i = refmin;
i<=refmax;
i++) {
142 caloCentRefVal_/=refmax-refmin+1.;
145 if(indx < 0 || caloCentRefVal_ == 0 ||
getPtDB(indx)==0)
return 1.;
146 return caloCentRefVal_/
getPtDB(indx);
149 double getW(
double pt,
double vtx,
int centbin)
const
156 if(ptval>0)
return pt*scale-pt2val/ptval;
163 double correction = 0;
177 if ( indx >= 0 )
return s-
yoffDB_[indx];
184 if ( indx >= 0 )
return c-
xoffDB_[indx];
191 if((fabs(s)<1
e-4) && (fabs(c)<1
e-4)) psi = 0.;
236 while(ang<-range) { ang+=2*range; }
237 while(ang>range) {ang-=2*range; }
void init(int order, int nbins, std::string tag, int vord)
double xoffDB_[MAXCUTOFF]
void fillOffset(double s, double c, uint m, double vtx, int centbin)
static const int MAXCUTOFF
double getCentResErr20(int bin) const
double bounds(double ang) const
double getCentRes25(int bin) const
double getCentRes10(int bin) const
void setCentRes20(int bin, double res, double err)
double getPt2(int bin) const
double getY(int bin) const
double getPtcnt(int bin) const
double getPt(int bin) const
double getSoffset(double s, double vtx, int centbin) const
Sin< T >::type sin(const T &t)
double getOffsetPsi(double s, double c) const
double yoffDB_[MAXCUTOFF]
double getCentRes40(int bin) const
void setCaloCentRefBins(const int caloCentRefMinBin, const int caloCentRefMaxBin)
void setXoffDB(int indx, double val)
std::map< std::string, int, std::less< std::string > > psi
double getCentResErr40(int bin) const
double getCentResErr10(int bin) const
double getCentRes5(int bin) const
double getEtScale(double vtx, int centbin) const
double getXoffDB(int bin) const
void setCentRes2(int bin, double res, double err)
void setCentRes5(int bin, double res, double err)
double getCentRes2(int bin) const
void setCentRes30(int bin, double res, double err)
int getOffsetIndx(int centbin, double vtx) const
double bounds2(double ang) const
void fill(double psi, double vtx, int centbin)
int getCutIndx(int centbin, double vtx, int iord) const
Cos< T >::type cos(const T &t)
double getYoff(int bin) const
double getXYoffcnt(int bin) const
double getCoffset(double c, double vtx, int centbin) const
uint xyoffmult_[MAXCUTOFF]
void setPtDB(int indx, double val)
double getFlatPsi(double psi, double vtx, int centbin) const
void setCentRes25(int bin, double res, double err)
double getCentResErr5(int bin) const
double getPt2DB(int bin) const
void setPt2DB(int indx, double val)
double getW(double pt, double vtx, int centbin) const
double getPtDB(int bin) const
void setXDB(int indx, double val)
void setCentRes10(int bin, double res, double err)
double getX(int bin) const
double getCentRes30(int bin) const
void setCentRes1(int bin, double res, double err)
void setYoffDB(int indx, double val)
double getXoff(int bin) const
double getXYoffmult(int bin) const
double xyoffcnt_[MAXCUTOFF]
double getCnt(int bin) const
double getCentResErr1(int bin) const
double getCentRes1(int bin) const
double getYDB(int bin) const
void setCentRes40(int bin, double res, double err)
double getXDB(int bin) const
double getYoffDB(int bin) const
Power< A, B >::type pow(const A &a, const B &b)
double getCentResErr25(int bin) const
void fillPt(double ptval, double vtx, int centbin)
double getCentResErr2(int bin) const
double getCentRes20(int bin) const
void setYDB(int indx, double val)
double getCentResErr30(int bin) const