ATLAS Offline Software
Loading...
Searching...
No Matches
RadiusResolutionChebyshev.cxx
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2025 CERN for the benefit of the ATLAS collaboration
3*/
7
8namespace MuonCalib{
11
12 std::string RadiusResolutionChebyshev::name() const {
13 return "RadiusResolutionChebyshev";
14 }
15 double RadiusResolutionChebyshev::resolution(double t, double /*bgRate*/) const {
16 double reso{0.};
17 const double r = m_rtRel->radius(t);
18 const double x = mapToUnitInterval(r, m_r_min, m_r_max);
19 for (unsigned int k = 0; k < nDoF(); ++k) {
20 reso += par(k) * chebyshevPoly1st(k, x);
21 }
22 return reso;
23 }
24 unsigned int RadiusResolutionChebyshev::nDoF() const {
25 return parameters().size();
26 }
27 std::vector<double> RadiusResolutionChebyshev::resParameters() const {
28 return parameters();
29 }
30
31}
std::vector< size_t > vec
#define x
const ParVec & parameters() const
Definition CalibFunc.h:40
double par(unsigned int index) const
Definition CalibFunc.h:41
std::vector< double > ParVec
Definition CalibFunc.h:35
Generic interface to retrieve the resolution on the drift radius as a function of the drift time.
virtual unsigned int nDoF() const override final
get the coefficients of the r(t) polynomial
RadiusResolutionChebyshev(const ParVec &vec, const IRtRelationPtr &rtRel)
initialization constructor,
virtual std::string name() const override final
Initialization from a.
virtual double resolution(double t, double bgRate=0.0) const override final
get the number of parameters used to describe the resolution
int r
Definition globals.cxx:22
CscCalcPed - algorithm that finds the Cathode Strip Chamber pedestals from an RDO.
GeoModel::TransientConstSharedPtr< IRtRelation > IRtRelationPtr
Definition IRtRelation.h:17
constexpr double chebyshevPoly1st(const unsigned int order, const double x)
Returns the n-th Chebyshev polynomial of first kind evaluated at x (c.f.
double mapToUnitInterval(const double x, const double lowerEdge, const double upperEdge)
Maps the number x which is in [lowEdge;upperEdge] to the interval [-1;1].
Definition UtilFunc.h:12