ATLAS Offline Software
Loading...
Searching...
No Matches
SubtractedCylinderLayer.cxx
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2022 CERN for the benefit of the ATLAS collaboration
3*/
4
6// SubtractedCylinderLayer.cxx, (c) ATLAS Detector software
8
9// Trk
11
15// CLHEP
17
20 const Trk::LayerMaterialProperties& laymatprop, double thickness,
21 std::unique_ptr<Trk::OverlapDescriptor> olap, int laytyp)
23 Layer(laymatprop, thickness, std::move(olap), laytyp) {}
24
26 const Trk::SubtractedCylinderLayer& clay) = default;
27
31
33 const SubtractedCylinderLayer& clay) {
34 if (this != &clay) {
35 // call the assignments of the base classes
38 }
39 return (*this);
40}
41
44{
45 return (*this);
46}
47
53
55 const Trk::TrackParameters& parm, Trk::PropDirection dir) const {
57 // calculate the direction to the normal
58 const Amg::Vector3D& parmPos = parm.position();
59 Amg::Vector3D pastStep(parmPos + dir * parm.momentum().normalized());
60 if (pastStep.perp() > parm.position().perp())
61 return Trk::Layer::m_layerMaterialProperties->alongPreFactor();
62 return Trk::Layer::m_layerMaterialProperties->oppositePreFactor();
63}
64
66 const Trk::TrackParameters& parm, Trk::PropDirection dir) const {
68 const Amg::Vector3D& parmPos = parm.position();
69 Amg::Vector3D pastStep(parmPos + dir * parm.momentum().normalized());
70 if (pastStep.perp() > parm.position().perp())
71 return Trk::Layer::m_layerMaterialProperties->alongPostFactor();
72 return Trk::Layer::m_layerMaterialProperties->oppositePostFactor();
73}
74
77 std::make_unique<Transforms>(shift * (m_transforms->transform));
78}
This virtual base class encapsulates the logics to build pre/post/full update material for Layer stru...
Layer()=default
Default Constructor.
double thickness() const
Return the Thickness of the Layer.
Layer & operator=(const Layer &lay)
Assignment operator for Derived classes.
Definition Layer.cxx:84
std::unique_ptr< LayerMaterialProperties > m_layerMaterialProperties
thickness of the Layer
Definition Layer.h:288
const Amg::Vector3D & momentum() const
Access method for the momentum.
const Amg::Vector3D & position() const
Access method for the position.
Class to describe a cylindrical detector layer for tracking, with subtraction; it inhertis from both,...
virtual const SubtractedCylinderSurface & surfaceRepresentation() const override final
Transforms the layer into a Surface representation for extrapolation.
SubtractedCylinderLayer & operator=(const SubtractedCylinderLayer &)
Assignment operator.
virtual double preUpdateMaterialFactor(const Trk::TrackParameters &par, Trk::PropDirection dir) const override final
getting the MaterialProperties back - for pre-update
SubtractedCylinderLayer()
Default Constructor.
virtual double postUpdateMaterialFactor(const Trk::TrackParameters &par, Trk::PropDirection dir) const override final
getting the MaterialProperties back - for post-update
virtual void moveLayer(Amg::Transform3D &shift) override final
move the Layer
Class for a cylinder subtracted/shared surface in the ATLAS detector.
SubtractedCylinderSurface()=default
Defaults.
SubtractedCylinderSurface & operator=(SubtractedCylinderSurface &&)=default
std::unique_ptr< Transforms > m_transforms
Unique Pointer to the Transforms struct.
Eigen::Affine3d Transform3D
Eigen::Matrix< double, 3, 1 > Vector3D
PropDirection
PropDirection, enum for direction of the propagation.
ParametersBase< TrackParametersDim, Charged > TrackParameters
STL namespace.