ATLAS Offline Software
Public Member Functions | Private Attributes | List of all members
CaloSwPhioff_v2::Builder Class Reference

Helper class for calculating the energy interpolation table. More...

Inheritance diagram for CaloSwPhioff_v2::Builder:
Collaboration diagram for CaloSwPhioff_v2::Builder:

Public Member Functions

 Builder (const CxxUtils::Array< 3 > &correction, const CxxUtils::Array< 1 > &interp_barriers, int degree, float aeta)
 Constructor. More...
 
virtual float calculate (int energy_ndx, bool &good) const
 Calculate the correction for tabulated energy ENERGY_NDX. More...
 

Private Attributes

const CxxUtils::Array< 3 > m_correction
 Tabulated arrays of function parameters. More...
 
const CxxUtils::Array< 1 > m_interp_barriers
 Allow breaking up the interpolation into independent regions. More...
 
int m_degree
 Degree of the polynomial interpolation. More...
 
float m_aeta
 The abs(eta) at which the correction is being evaluated (in cal-local coordinates). More...
 

Detailed Description

Helper class for calculating the energy interpolation table.

Definition at line 97 of file CaloSwPhioff_v2.h.

Constructor & Destructor Documentation

◆ Builder()

CaloSwPhioff_v2::Builder::Builder ( const CxxUtils::Array< 3 > &  correction,
const CxxUtils::Array< 1 > &  interp_barriers,
int  degree,
float  aeta 
)

Constructor.

Constructor for energy interpolation table helper class.

Gets the correction information, and the abs(eta) at which the correction is being evaluated (in cal-local coordinates).

Parameters
correctionTabulated arrays of function parameters.
interp_barriersAllow breaking up the interpolation into independent regions.
degreeDegree of the polynomial interpolation.
aetaThe absolute value of \(\eta\) at which the correction is being evaluated (in cal-local coordinates).

Definition at line 108 of file CaloSwPhioff_v2.cxx.

113  m_interp_barriers (interp_barriers),
114  m_degree (degree),
115  m_aeta (aeta)
116 {
117 }

Member Function Documentation

◆ calculate()

float CaloSwPhioff_v2::Builder::calculate ( int  energy_ndx,
bool &  good 
) const
virtual

Calculate the correction for tabulated energy ENERGY_NDX.

Calculate the correction for one tabulated energy index.

Parameters
energy_ndxThe tabulated energy index for which the correction should be calculated.
good[out]Set to true if the calculation succeeds.

Implements CaloClusterCorrectionCommon::TableBuilder.

Definition at line 126 of file CaloSwPhioff_v2.cxx.

127 {
128  good = true;
129  return interpolate (m_correction[energy_ndx],
130  m_aeta,
131  m_degree,
132  1,
134 }

Member Data Documentation

◆ m_aeta

float CaloSwPhioff_v2::Builder::m_aeta
private

The abs(eta) at which the correction is being evaluated (in cal-local coordinates).

Definition at line 124 of file CaloSwPhioff_v2.h.

◆ m_correction

const CxxUtils::Array<3> CaloSwPhioff_v2::Builder::m_correction
private

Tabulated arrays of function parameters.

Definition at line 114 of file CaloSwPhioff_v2.h.

◆ m_degree

int CaloSwPhioff_v2::Builder::m_degree
private

Degree of the polynomial interpolation.

Definition at line 120 of file CaloSwPhioff_v2.h.

◆ m_interp_barriers

const CxxUtils::Array<1> CaloSwPhioff_v2::Builder::m_interp_barriers
private

Allow breaking up the interpolation into independent regions.

Definition at line 117 of file CaloSwPhioff_v2.h.


The documentation for this class was generated from the following files:
CaloSwPhioff_v2::Builder::m_aeta
float m_aeta
The abs(eta) at which the correction is being evaluated (in cal-local coordinates).
Definition: CaloSwPhioff_v2.h:124
tools.zlumi_mc_cf.correction
def correction(mu, runmode, campaign, run=None)
Definition: zlumi_mc_cf.py:4
CaloSwPhioff_v2::Builder::m_correction
const CxxUtils::Array< 3 > m_correction
Tabulated arrays of function parameters.
Definition: CaloSwPhioff_v2.h:114
ReadBchFromCool.good
good
Definition: ReadBchFromCool.py:433
CaloClusterCorr::interpolate
float interpolate(const CaloRec::Array< 2 > &a, float x, unsigned int degree, unsigned int ycol=1, const CaloRec::Array< 1 > &regions=CaloRec::Array< 1 >(), int n_points=-1, bool fixZero=false)
Polynomial interpolation in a table.
Definition: interpolate.cxx:75
CaloSwPhioff_v2::Builder::m_interp_barriers
const CxxUtils::Array< 1 > m_interp_barriers
Allow breaking up the interpolation into independent regions.
Definition: CaloSwPhioff_v2.h:117
python.SystemOfUnits.degree
tuple degree
Definition: SystemOfUnits.py:106
CaloSwPhioff_v2::Builder::m_degree
int m_degree
Degree of the polynomial interpolation.
Definition: CaloSwPhioff_v2.h:120