 |
ATLAS Offline Software
|
Go to the documentation of this file.
22 inline void updateInstanceCounts(std::shared_ptr<const unsigned>& currCounter,
23 std::shared_ptr<unsigned>&& newCounter) {
28 currCounter = std::move(newCounter);
36 m_primaryMeas{primaryMeas},
37 m_secondaryMeas{secondaryMeas},
44 if (primaryMeas->numDimensions() == 1) {
45 uvcov(0,0) = primaryMeas->localCovariance<1>()[0];
47 Jac.col(0) = m_normal.block<2,1>(0,0).
unit();
55 m_pos = pos1 + Amg::intersect<3>(pos2,dir2, pos1,
m_dir).value_or(0) *
m_dir;
57 uvcov(1,1) = secondaryMeas->localCovariance<1>()[0];
60 Jac.col(1) =
m_dir.block<2,1>(0,0).
unit();
65 if (primaryMeas->numDimensions() == 1) {
67 uvcov(1,1) =
strip->measuresPhi() ? 0.5*
strip->readoutElement()->stripPhiLength():
68 0.5*
strip->readoutElement()->stripEtaLength();
72 if (
strip->measuresPhi()) {
73 uvcov(1,1) = 0.5 *
strip->readoutElement()->stripLayout(
strip->gasGap()).stripLength(
strip->channelNumber());
75 uvcov(1,1) = 0.5 *
strip->readoutElement()->wireGangLayout(
strip->gasGap()).stripLength(
strip->channelNumber());
83 case sTgcIdHelper::sTgcChannelTypes::Strip:
86 case sTgcIdHelper::sTgcChannelTypes::Wire:
90 case sTgcIdHelper::sTgcChannelTypes::Pad:
94 uvcov(1,1) =
std::pow(uvcov(1,1), 2);
100 if (primaryMeas->numDimensions() == 2) {
101 uvcov = xAOD::toEigen(primaryMeas->localCovariance<2>());
102 m_secondaryMeas = m_primaryMeas;
104 m_measCovariance = Jac * uvcov * Jac.inverse();
151 return m_measCovariance;
154 std::shared_ptr<unsigned int> phiCounts) {
const MuonGMR4::SpectrometerSector * msSector() const
const Identifier & identify(const UncalibratedMeasurement *meas)
Returns the associated identifier from the muon measurement.
xAOD::UncalibMeasType type() const
const Amg::Vector3D & normalInChamber() const
TDirectory & m_dir
The directory we need to return to.
std::shared_ptr< const unsigned > m_phiInstances
In how many space points is the phi measurement used.
A spectrometer sector forms the envelope of all chambers that are placed in the same MS sector & laye...
virtual double stripLength(int stripNumb) const
Returns length of the strip.
IdentifierHash measurementHash() const
Returns the hash of the measurement channel w.r.t ReadoutElement.
Eigen::Matrix< double, 2, 1 > Vector2D
const StripDesign & stripDesign(const Identifier &measId) const
Retrieves the readoutElement Layer given the Identifier/Hash.
IdentifierHash measurementHash() const
Returns the hash of the measurement channel (tube (x) layer)
Amg::Vector3D planeNormal() const
Returns the vector pointing out of the measurement plane.
double activeTubeLength(const IdentifierHash &hash) const
void setInstanceCounts(std::shared_ptr< unsigned > etaCounts, std::shared_ptr< unsigned > phiCounts)
Set the number of space points built with the same eta / phi prd.
const MuonGMR4::MmReadoutElement * readoutElement() const
Retrieve the associated MmReadoutElement.
const xAOD::UncalibratedMeasurement * secondaryMeasurement() const
const MuonGMR4::SpectrometerSector * m_msSector
Amg::Vector3D channelDirInChamber(const ActsGeometryContext &gctx, const UncalibratedMeasurement *meas)
bool measuresPhi() const
: Does the space point contain a phi measurement
const MuonGMR4::MdtReadoutElement * readoutElement() const
Retrieve the associated MdtReadoutElement.
uint16_t channelNumber() const
Channel number of the Measurement.
const MuonGMR4::Chamber * m_chamber
std::shared_ptr< const unsigned > m_etaInstances
In how many space points is the eta measurement used.
const xAOD::UncalibratedMeasurement * primaryMeasurement() const
const WireGroupDesign & wireDesign(const Identifier &measId) const
Retrieves the readoutElement Layer given the Identifier/Hash.
const xAOD::UncalibratedMeasurement * m_secondaryMeas
virtual sTgcChannelTypes channelType() const =0
Returns the channel type of the measurement (Pad/Wire/Strip)
uint16_t channelNumber() const
returns the number of the central strip
virtual xAOD::UncalibMeasType type() const =0
Returns the type of the measurement type as a simple enumeration.
Amg::Vector3D positionInChamber(const ActsGeometryContext &gctx, const UncalibratedMeasurement *meas)
Returns the position of the uncalibrated muon measurement in the attached Muon chamber frame.
Amg::Vector3D channelNormalInChamber(const ActsGeometryContext &gctx, const UncalibratedMeasurement *meas)
Include the GeoPrimitives which need to be put first.
const StripLayer & stripLayer(const Identifier &measId) const
const Amg::Vector3D & directionInChamber() const
double error(const Amg::MatrixX &mat, int index)
return diagonal error of the matrix caller should ensure the matrix is symmetric and the index is in ...
const MuonGMR4::sTgcReadoutElement * readoutElement() const
Retrieve the associated sTgcReadoutElement.
IdentifierHash measurementHash() const
Returns the hash of the measurement channel.
Eigen::Matrix< double, 3, 1 > Vector3D
const StripDesign & design() const
Returns the underlying strip design.
SpacePoint(const ActsGeometryContext &gctx, const xAOD::UncalibratedMeasurement *primMeas, const xAOD::UncalibratedMeasurement *secondMeas=nullptr)
This header ties the generic definitions in this package.
const Amg::Vector3D & positionInChamber() const
unsigned int nPhiInstanceCounts() const
How many space points have been built in total with the same phi prd
bool m_measEta
Flag indicating that the measurement is an eta measurement.
bool measuresEta() const
: Does the space point contain an eta measurement
const PlainObject unit() const
This is a plugin that makes Eigen look like CLHEP & defines some convenience methods.
unsigned int dimension() const
Is the space point a 1D or combined 2D measurement.
const MuonGMR4::Chamber * chamber() const
: Pointer to the associated chamber
UncalibMeasType
Define the type of the uncalibrated measurement.
Amg::Vector2D uncertainty() const
: Returns the uncertainties on the space point
double driftRadius() const
: Returns the size of the drift radius
https://gitlab.cern.ch/atlas/athena/-/blob/master/MuonSpectrometer/MuonReconstruction/MuonRecEvent/Mu...
const AmgSymMatrix(2) &SpacePoint
constexpr int pow(int base, int exp) noexcept
const xAOD::UncalibratedMeasurement * m_primaryMeas
const Identifier & identify() const
: Identifier of the primary measurement
unsigned int nEtaInstanceCounts() const
How many space points have been built in total with the same eta prd.