ATLAS Offline Software
PlaneLayer.cxx
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2023 CERN for the benefit of the ATLAS collaboration
3 */
4 
6 // PlaneLayer.cxx, (c) ATLAS Detector software
8 
9 // Trk
10 #include "TrkGeometry/PlaneLayer.h"
11 
15 // CLHEP
17 
19  const Trk::SurfaceBounds* tbounds,
20  const Trk::LayerMaterialProperties& laymatprop,
21  double thickness, std::unique_ptr<Trk::OverlapDescriptor> olap,
22  int laytyp)
23  : PlaneSurface(transform, tbounds),
24  Layer(laymatprop, thickness, std::move(olap), laytyp) {}
25 
27  const Trk::LayerMaterialProperties& laymatprop,
28  double thickness, std::unique_ptr<Trk::OverlapDescriptor> olap,
29  int laytyp)
30  : PlaneSurface(*plane), Layer(laymatprop, thickness, std::move(olap), laytyp) {}
31 
35  const Trk::LayerMaterialProperties& laymatprop, double thickness,
36  std::unique_ptr<Trk::OverlapDescriptor> olap, int laytyp)
37  : PlaneSurface(transform, tbounds),
38  Layer(laymatprop, thickness, std::move(olap), laytyp) {}
39 
40 Trk::PlaneLayer::PlaneLayer(const Trk::PlaneLayer& play) = default;
41 
43  const Amg::Transform3D& transf)
44  : PlaneSurface(play, transf), Layer(play) {}
45 
47  if (this != &play) {
48  // call the assignments of the base classes
51  m_index = play.m_index;
52  }
53  return (*this);
54 }
55 
56 const Trk::PlaneSurface&
58 {
59  return (*this);
60 }
63 {
64  return (*this);
65 }
66 
68  const Trk::TrackParameters& parm, Trk::PropDirection dir) const {
70  if (Trk::PlaneSurface::normal().dot(dir * parm.momentum().normalized()) > 0.)
71  return Trk::Layer::m_layerMaterialProperties->alongPreFactor();
72  return Trk::Layer::m_layerMaterialProperties->oppositePreFactor();
73 }
74 
76  const Trk::TrackParameters& parm, Trk::PropDirection dir) const {
78  if (Trk::PlaneSurface::normal().dot(dir * parm.momentum().normalized()) > 0.)
79  return Trk::Layer::m_layerMaterialProperties->alongPostFactor();
80  return Trk::Layer::m_layerMaterialProperties->oppositePostFactor();
81 }
82 
84  m_transforms =
85  std::make_unique<Transforms>(shift * (m_transforms->transform));
86 }
87 
TrackParameters.h
Trk::PlaneLayer::surfaceRepresentation
virtual const PlaneSurface & surfaceRepresentation() const override final
Transforms the layer into a Surface representation for extrapolation.
Definition: PlaneLayer.cxx:57
MaterialProperties.h
Trk::Layer::m_layerMaterialProperties
std::unique_ptr< LayerMaterialProperties > m_layerMaterialProperties
thickness of the Layer
Definition: Layer.h:289
Trk::SurfaceBounds
Definition: SurfaceBounds.h:47
Trk::PlaneLayer::preUpdateMaterialFactor
virtual double preUpdateMaterialFactor(const Trk::TrackParameters &par, Trk::PropDirection dir) const override final
getting the MaterialProperties back - for pre-update
Definition: PlaneLayer.cxx:67
GeoPrimitives.h
Trk::PropDirection
PropDirection
Definition: PropDirection.h:19
Trk::LayerMaterialProperties
Definition: LayerMaterialProperties.h:62
Amg::Transform3D
Eigen::Affine3d Transform3D
Definition: GeoPrimitives.h:46
Amg::transform
Amg::Vector3D transform(Amg::Vector3D &v, Amg::Transform3D &tr)
Transform a point from a Trasformation3D.
Definition: GeoPrimitivesHelpers.h:156
Trk::PlaneLayer
Definition: PlaneLayer.h:40
Trk::Layer::operator=
Layer & operator=(const Layer &lay)
Assignment operator for Derived classes.
Definition: Layer.cxx:98
Trk::Surface::normal
virtual const Amg::Vector3D & normal() const
Returns the normal vector of the Surface (i.e.
Trk::PlaneSurface::operator=
PlaneSurface & operator=(const PlaneSurface &psf)=default
Assignment operator.
Trk::PlaneLayer::postUpdateMaterialFactor
virtual double postUpdateMaterialFactor(const Trk::TrackParameters &par, Trk::PropDirection dir) const override final
getting the MaterialProperties back - for post-update
Definition: PlaneLayer.cxx:75
Trk::ParametersBase
Definition: ParametersBase.h:55
Trk::PlaneLayer::moveLayer
virtual void moveLayer(Amg::Transform3D &shift) override final
move the Layer
Definition: PlaneLayer.cxx:83
dot.dot
def dot(G, fn, nodesToHighlight=[])
Definition: dot.py:5
beamspotman.dir
string dir
Definition: beamspotman.py:623
Trk::PlaneLayer::PlaneLayer
PlaneLayer()
Default Constructor.
Definition: PlaneLayer.h:43
Trk::ParametersBase::momentum
const Amg::Vector3D & momentum() const
Access method for the momentum.
Trk::SharedObject
std::shared_ptr< T > SharedObject
Definition: SharedObject.h:24
Trk::PlaneSurface
Definition: PlaneSurface.h:64
Trk::Layer::m_index
LayerIndex m_index
LayerIndex.
Definition: Layer.h:307
LayerMaterialProperties.h
Trk::PlaneLayer::operator=
PlaneLayer & operator=(const PlaneLayer &)
Assignment operator for PlaneLayers.
Definition: PlaneLayer.cxx:46
PlaneLayer.h
Trk::Layer
Definition: Layer.h:73