ATLAS Offline Software
Toggle main menu visibility
Loading...
Searching...
No Matches
MuonSpectrometer
MuonCalib
MdtCalib
MdtCalibData
MdtCalibData
IRtRelation.h
Go to the documentation of this file.
1
/*
2
Copyright (C) 2002-2024 CERN for the benefit of the ATLAS collaboration
3
*/
4
5
#ifndef MUONCALIB_IRTRELATION_H
6
#define MUONCALIB_IRTRELATION_H
7
8
#include "
MdtCalibData/CalibFunc.h
"
9
#include "
MuonCalibMath/UtilFunc.h
"
10
#include "
GeoModelUtilities/TransientConstSharedPtr.h
"
11
12
#include <optional>
13
14
namespace
MuonCalib
{
15
16
class
IRtRelation
;
17
using
IRtRelationPtr
=
GeoModel::TransientConstSharedPtr<IRtRelation>
;
19
class
IRtRelation
:
public
CalibFunc
{
20
public
:
21
using
CalibFunc::CalibFunc
;
22
virtual
~IRtRelation
() =
default
;
23
virtual
std::string
typeName
()
const
override final {
return
"IRtRelation"
; }
24
26
virtual
double
radius
(
double
t)
const
= 0;
28
virtual
double
driftVelocity
(
double
t)
const
= 0;
30
virtual
double
driftAcceleration
(
double
t)
const
= 0;
32
virtual
double
tLower
()
const
= 0;
34
virtual
double
tUpper
()
const
= 0;
36
virtual
double
tBinWidth
()
const
=0;
38
virtual
unsigned
nDoF
()
const
= 0;
40
double
GetTmaxDiff
()
const
{
return
m_tmax_diff
.value_or(0.); }
41
42
bool
hasTmaxDiff
()
const
{
return
m_tmax_diff
.has_value(); }
43
45
void
SetTmaxDiff
(
const
double
d) {
m_tmax_diff
= d; }
46
49
double
getReducedTime
(
const
double
t)
const
{
50
return
mapToUnitInterval
(t,
tLower
(),
tUpper
());
51
}
52
/* @brief Returns the derivative term of the reduced time w.r.t. the time*/
53
double
dReducedTimeDt
()
const
{
54
return
unitIntervalPrime
(
tLower
(),
tUpper
());
55
}
56
57
private
:
58
std::optional<double>
m_tmax_diff
{std::nullopt};
59
protected
:
60
static
constexpr
double
s_tBinWidth
= 1.e-3;
61
};
62
63
}
// namespace MuonCalib
64
65
#endif
CalibFunc.h
TransientConstSharedPtr.h
UtilFunc.h
GeoModel::TransientConstSharedPtr
The TransientConstSharedPtr allows non-const access if the pointer itself is non-const but in the con...
Definition
TransientConstSharedPtr.h:13
MuonCalib::CalibFunc::CalibFunc
CalibFunc(const ParVec &vec)
Definition
CalibFunc.h:36
MuonCalib::IRtRelation
generic interface for a rt-relation
Definition
IRtRelation.h:19
MuonCalib::IRtRelation::nDoF
virtual unsigned nDoF() const =0
Returns the number of degrees of freedom of the relation function.
MuonCalib::IRtRelation::tLower
virtual double tLower() const =0
Returns the lower time covered by the r-t.
MuonCalib::IRtRelation::tBinWidth
virtual double tBinWidth() const =0
Returns the step-size for the sampling.
MuonCalib::IRtRelation::m_tmax_diff
std::optional< double > m_tmax_diff
Definition
IRtRelation.h:58
MuonCalib::IRtRelation::driftAcceleration
virtual double driftAcceleration(double t) const =0
Returns the acceleration of the r-t relation.
MuonCalib::IRtRelation::s_tBinWidth
static constexpr double s_tBinWidth
Definition
IRtRelation.h:60
MuonCalib::IRtRelation::radius
virtual double radius(double t) const =0
returns drift radius for a given time
MuonCalib::IRtRelation::GetTmaxDiff
double GetTmaxDiff() const
return the difference in total dirft time between the two multilayers (ML1 - ML2)
Definition
IRtRelation.h:40
MuonCalib::IRtRelation::SetTmaxDiff
void SetTmaxDiff(const double d)
set the difference in total drift time betwene the two multilayers (ML1 - ML2)
Definition
IRtRelation.h:45
MuonCalib::IRtRelation::hasTmaxDiff
bool hasTmaxDiff() const
Definition
IRtRelation.h:42
MuonCalib::IRtRelation::tUpper
virtual double tUpper() const =0
Returns the upper time covered by the r-t.
MuonCalib::IRtRelation::dReducedTimeDt
double dReducedTimeDt() const
Definition
IRtRelation.h:53
MuonCalib::IRtRelation::~IRtRelation
virtual ~IRtRelation()=default
MuonCalib::IRtRelation::typeName
virtual std::string typeName() const override final
Definition
IRtRelation.h:23
MuonCalib::IRtRelation::CalibFunc
CalibFunc(const ParVec &vec)
Definition
CalibFunc.h:36
MuonCalib::IRtRelation::driftVelocity
virtual double driftVelocity(double t) const =0
Returns the drift velocity for a given time.
MuonCalib::IRtRelation::getReducedTime
double getReducedTime(const double t) const
map the in the interval [tLower;tUpper] onto the interval [-1.;1.
Definition
IRtRelation.h:49
const
MuonCalib
CscCalcPed - algorithm that finds the Cathode Strip Chamber pedestals from an RDO.
Definition
CscCalcPed.cxx:21
MuonCalib::IRtRelationPtr
GeoModel::TransientConstSharedPtr< IRtRelation > IRtRelationPtr
Definition
IRtRelation.h:17
MuonCalib::mapToUnitInterval
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
MuonCalib::unitIntervalPrime
double unitIntervalPrime(const double lowerEdge, const double upperEdge)
Definition
UtilFunc.h:15
Generated on
for ATLAS Offline Software by
1.17.0