Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2026-11-09 09:46:42

0001 // This file is part of the ACTS project.
0002 //
0003 // Copyright (C) 2016 CERN for the benefit of the ACTS project
0004 //
0005 // This Source Code Form is subject to the terms of the Mozilla Public
0006 // License, v. 2.0. If a copy of the MPL was not distributed with this
0007 // file, You can obtain one at https://mozilla.org/MPL/2.0/.
0008 
0009 #pragma once
0010 
0011 #include "Acts/Definitions/Algebra.hpp"
0012 #include "Acts/Definitions/Alignment.hpp"
0013 #include "Acts/Definitions/Direction.hpp"
0014 #include "Acts/Definitions/Tolerance.hpp"
0015 #include "Acts/Definitions/TrackParametrization.hpp"
0016 #include "Acts/Geometry/GeometryContext.hpp"
0017 #include "Acts/Geometry/GeometryObject.hpp"
0018 #include "Acts/Geometry/Polyhedron.hpp"
0019 #include "Acts/Material/MaterialSlab.hpp"
0020 #include "Acts/Surfaces/BoundaryTolerance.hpp"
0021 #include "Acts/Surfaces/SurfaceBounds.hpp"
0022 #include "Acts/Surfaces/SurfacePlacementBase.hpp"
0023 #include "Acts/Utilities/AxisDefinitions.hpp"
0024 #include "Acts/Utilities/CloneablePtr.hpp"
0025 #include "Acts/Utilities/Intersection.hpp"
0026 #include "Acts/Utilities/OstreamFormatter.hpp"
0027 #include "Acts/Utilities/Result.hpp"
0028 #include "Acts/Visualization/ViewConfig.hpp"
0029 
0030 #include <array>
0031 #include <memory>
0032 #include <ostream>
0033 #include <string>
0034 #include <string_view>
0035 #include <utility>
0036 
0037 namespace Acts {
0038 
0039 class SurfaceBounds;
0040 class ISurfaceMaterial;
0041 class Layer;
0042 class TrackingVolume;
0043 class IVisualization3D;
0044 
0045 /// @class Surface
0046 ///
0047 /// Abstract Base Class for tracking surfaces
0048 ///
0049 /// The Surface class builds the core of the Acts Tracking Geometry.
0050 /// All other geometrical objects are either extending the surface or
0051 /// are built from it.
0052 ///
0053 /// Surfaces are either owned by Detector elements or the Tracking Geometry,
0054 /// in which case they are not copied within the data model objects.
0055 ///
0056 class Surface : public virtual GeometryObject,
0057                 public std::enable_shared_from_this<Surface> {
0058  public:
0059   friend struct GeometryContextOstreamWrapper<Surface>;
0060 
0061   /// @enum SurfaceType
0062   ///
0063   /// This enumerator simplifies the persistency & calculations,
0064   /// by saving a dynamic_cast, e.g. for persistency
0065   enum SurfaceType {
0066     Cone = 0,
0067     Cylinder = 1,
0068     Disc = 2,
0069     Perigee = 3,
0070     Plane = 4,
0071     Straw = 5,
0072     Curvilinear = 6,
0073     Point = 7,
0074     Other = 8
0075   };
0076 
0077   /// Helper strings for screen output
0078   static constexpr std::array<std::string_view, Surface::SurfaceType::Other + 1>
0079       s_surfaceTypeNames = {"Cone",  "Cylinder",    "Disc",  "Perigee", "Plane",
0080                             "Straw", "Curvilinear", "Point", "Other"};
0081 
0082   friend std::ostream& operator<<(std::ostream& os, SurfaceType type);
0083 
0084  protected:
0085   /// Constructor with Transform3 as a shared object
0086   ///
0087   /// @param transform Transform3 positions the surface in 3D global space
0088   /// @note also acts as default constructor
0089   explicit Surface(const Transform3& transform = Transform3::Identity());
0090 
0091   /// Copy constructor
0092   ///
0093   /// @note copy construction invalidates the association
0094   /// to detector element and layer
0095   ///
0096   /// @param other Source surface for copy.
0097   Surface(const Surface& other) noexcept = default;
0098 
0099   /// Constructor from SurfacePlacement: Element proxy
0100   ///
0101   /// @param placement Reference to the surface placement
0102   /// @note The Surface does not take any ownership over the
0103   ///       `SurfacePlacementBase` it is expected that the user
0104   ///        ensures the life-time of the `SurfacePlacementBase`
0105   ///        and that the `Surface` is actually owned by
0106   ///        the `SurfacePlacementBase` instance
0107   explicit Surface(const SurfacePlacementBase& placement) noexcept;
0108 
0109   /// Copy constructor with optional shift
0110   ///
0111   /// @note copy construction invalidates the association
0112   /// to detector element and layer
0113   ///
0114   /// @param gctx The current geometry context object, e.g. alignment
0115   /// @param other Source surface for copy
0116   /// @param shift Additional transform applied as: shift * transform
0117   explicit Surface(const GeometryContext& gctx, const Surface& other,
0118                    const Transform3& shift) noexcept;
0119 
0120   /// Assignment operator
0121   /// @note copy construction invalidates the association
0122   /// to detector element and layer
0123   ///
0124   /// @param other Source surface for the assignment
0125   /// @return Reference to this surface after assignment
0126   Surface& operator=(const Surface& other) noexcept = default;
0127 
0128  public:
0129   ~Surface() noexcept override;
0130 
0131   /// Factory for producing memory managed instances of Surface.
0132   /// Will forward all parameters and will attempt to find a suitable
0133   /// constructor.
0134   /// @param args Constructor arguments to forward to surface creation
0135   /// @return Shared pointer to the created surface instance
0136   template <class T, typename... Args>
0137   static std::shared_ptr<T> makeShared(Args&&... args) {
0138     return std::shared_ptr<T>(new T(std::forward<Args>(args)...));
0139   }
0140 
0141   /// Retrieve a @c std::shared_ptr for this surface (non-const version)
0142   ///
0143   /// @note Will error if this was not created through the @c makeShared factory
0144   ///       since it needs access to the original reference. In C++14 this is
0145   ///       undefined behavior (but most likely implemented as a @c bad_weak_ptr
0146   ///       exception), in C++17 it is defined as that exception.
0147   /// @note Only call this if you need shared ownership of this object.
0148   ///
0149   /// @return The shared pointer
0150   std::shared_ptr<Surface> getSharedPtr();
0151 
0152   /// Retrieve a @c std::shared_ptr for this surface (const version)
0153   ///
0154   /// @note Will error if this was not created through the @c makeShared factory
0155   ///       since it needs access to the original reference. In C++14 this is
0156   ///       undefined behavior, but most likely implemented as a @c bad_weak_ptr
0157   ///       exception, in C++17 it is defined as that exception.
0158   /// @note Only call this if you need shared ownership of this object.
0159   ///
0160   /// @return The shared pointer
0161   std::shared_ptr<const Surface> getSharedPtr() const;
0162 
0163   /// Comparison (equality) operator
0164   /// The strategy for comparison is
0165   /// (a) first pointer comparison
0166   /// (b) then type comparison
0167   /// (c) then bounds comparison
0168   /// (d) then transform comparison
0169   ///
0170   /// @param other source surface for the comparison
0171   /// @return True if surfaces are equal, false otherwise
0172   bool operator==(const Surface& other) const;
0173 
0174  public:
0175   /// Return method for the Surface type to avoid dynamic casts
0176   /// @return The surface type enumeration value
0177   virtual SurfaceType type() const = 0;
0178 
0179   /// Return method for the surface Transform3 by reference
0180   /// In case a detector element is associated the surface transform
0181   /// is just forwarded to the detector element in order to keep the
0182   /// (mis-)alignment cache cetrally handled
0183   ///
0184   /// @param gctx The current geometry context object, e.g. alignment
0185   ///
0186   /// @return the contextual transform
0187   const Transform3& localToGlobalTransform(const GeometryContext& gctx) const;
0188 
0189   /// Return method for the surface center
0190   /// @note the center is always recalculated in order to not keep a cache
0191   ///
0192   /// @param gctx The current geometry context object, e.g. alignment
0193   ///
0194   /// @return center position by value
0195   virtual Vector3 center(const GeometryContext& gctx) const;
0196 
0197   /// Return the surface normal at a given @p position and @p direction.
0198   /// This method is fully generic, and valid for all surface types.
0199   /// @note For some surface types, the @p direction is ignored, but
0200   ///       it is **not safe** to pass in a zero vector!
0201   /// @param gctx The current geometry context object, e.g. alignment
0202   /// @param pos The position at which to calculate the normal
0203   /// @param direction The direction at which to calculate the normal
0204   /// @return The normal vector at the given position and direction
0205   virtual Vector3 normal(const GeometryContext& gctx, const Vector3& pos,
0206                          const Vector3& direction) const = 0;
0207 
0208   /// Return method for SurfaceBounds
0209   /// @return SurfaceBounds by reference
0210   virtual const SurfaceBounds& bounds() const = 0;
0211 
0212   /// Local axes of the surface
0213   /// @return An array of local axes directions
0214   virtual std::array<AxisDirection, 2> localAxes() const = 0;
0215 
0216   /// Return the associated surface placement if there is any
0217   /// @return Pointer to the surface placement, can be nullptr
0218   const SurfacePlacementBase* surfacePlacement() const;
0219 
0220   /// Return method for the associated Layer in which the surface is embedded
0221   /// @return Layer by plain pointer, can be nullptr
0222   const Layer* associatedLayer() const;
0223 
0224   /// Return the thickness of the surface in the normal direction
0225   /// @return The surface thickness
0226   double thickness() const;
0227 
0228   /// Set Associated Layer
0229   /// Many surfaces can be associated to a Layer, but it might not be known yet
0230   /// during construction of the layer, this can be set afterwards
0231   ///
0232   /// @param lay the assignment Layer by reference
0233   void associateLayer(const Layer& lay);
0234 
0235   /// Check if the surface has an associated material description
0236   /// @return True if the surface has an associated material, false otherwise
0237   bool hasMaterial() const;
0238 
0239   /// Return method for the associated Material to this surface
0240   /// @return SurfaceMaterial as plain pointer, can be nullptr
0241   const ISurfaceMaterial* surfaceMaterial() const;
0242 
0243   /// Return method for the shared pointer to the associated Material
0244   /// @return SurfaceMaterial as shared_pointer, can be nullptr
0245   const std::shared_ptr<const ISurfaceMaterial>& surfaceMaterialSharedPtr()
0246       const;
0247 
0248   /// Assign a placement object which may dynamically align the surface in space
0249   /// @param placement: Placement object defining the surface's position
0250   void assignSurfacePlacement(const SurfacePlacementBase& placement);
0251 
0252   /// Assign the surface material description
0253   ///
0254   /// The material is usually derived in a complicated way and loaded from
0255   /// a framework given source. As various surfaces may share the same source
0256   /// this is provided by a shared pointer
0257   ///
0258   /// @param material Material description associated to this surface
0259   virtual void assignSurfaceMaterial(
0260       std::shared_ptr<const ISurfaceMaterial> material);
0261 
0262   /// Assign whether the surface is sensitive
0263   /// @param isSensitive Boolean flag to set sensitivity
0264   /// @throw logic_error if the surface is associated to a detector element
0265   void assignIsSensitive(bool isSensitive);
0266 
0267   /// Assign the thickness of the surface in the
0268   ///        orthogonal dimension
0269   /// @param thick: Thickness parameter to assign (>=0)
0270   void assignThickness(double thick);
0271 
0272   /// Return method for full material description of the Surface
0273   /// - from local coordinate on the surface
0274   ///
0275   /// @param lp is the local position used for the (eventual) lookup
0276   ///
0277   /// @return const MaterialSlab
0278   virtual const MaterialSlab& materialSlab(const Vector2& lp) const;
0279 
0280   /// Return method for fully scaled material description of the Surface
0281   /// - from local coordinate on the surface
0282   ///
0283   /// @param lp is the local position used for the (eventual) lookup
0284   /// @param pDir is the positive direction through the surface
0285   /// @param mode is the material update directive
0286   ///
0287   /// @return MaterialSlab
0288   virtual MaterialSlab materialSlab(const Vector2& lp, Direction pDir,
0289                                     MaterialUpdateMode mode) const;
0290 
0291   /// The geometric onSurface method
0292   ///
0293   /// Geometrical check whether position is on Surface
0294   ///
0295   /// @param gctx The current geometry context object, e.g. alignment
0296   /// @param position global position to be evaludated
0297   /// @param direction global momentum direction (required for line-type surfaces)
0298   /// @param boundaryTolerance BoundaryTolerance directive for this onSurface check
0299   /// @param tolerance optional tolerance within which a point is considered on surface
0300   ///
0301   /// @return boolean indication if operation was successful
0302   bool isOnSurface(
0303       const GeometryContext& gctx, const Vector3& position,
0304       const Vector3& direction,
0305       const BoundaryTolerance& boundaryTolerance = BoundaryTolerance::None(),
0306       double tolerance = s_onSurfaceTolerance) const;
0307 
0308   /// Calculates the closest point on the boundary of the surface to a given
0309   /// point in local coordinates.
0310   /// @param lposition The local position to check
0311   /// @param metric The metric to use for the calculation
0312   /// @return The closest point on the boundary of the surface
0313   virtual Vector2 closestPointOnBoundary(const Vector2& lposition,
0314                                          const SquareMatrix2& metric) const;
0315 
0316   /// Calculates the distance to the boundary of the surface from a given point
0317   /// in local coordinates.
0318   /// @param lposition The local position to check
0319   /// @return The distance to the boundary of the surface
0320   virtual double distanceToBoundary(const Vector2& lposition) const;
0321 
0322   /// The insideBounds method for local positions
0323   ///
0324   /// @param lposition The local position to check
0325   /// @param boundaryTolerance BoundaryTolerance directive for this onSurface check
0326   /// @return boolean indication if operation was successful
0327   virtual bool insideBounds(const Vector2& lposition,
0328                             const BoundaryTolerance& boundaryTolerance =
0329                                 BoundaryTolerance::None()) const;
0330 
0331   /// Local to global transformation
0332   /// Generalized local to global transformation for the surface types. Since
0333   /// some surface types need the global momentum/direction to resolve sign
0334   /// ambiguity this is also provided
0335   ///
0336   /// @param gctx The current geometry context object, e.g. alignment
0337   /// @param lposition local 2D position in specialized surface frame
0338   /// @param direction global 3D momentum direction
0339   ///
0340   /// @return The global position by value
0341   virtual Vector3 localToGlobal(const GeometryContext& gctx,
0342                                 const Vector2& lposition,
0343                                 const Vector3& direction) const = 0;
0344 
0345   /// Global to local transformation
0346   /// Generalized global to local transformation for the surface types. Since
0347   /// some surface types need the global momentum/direction to resolve sign
0348   /// ambiguity this is also provided
0349   ///
0350   /// @param gctx The current geometry context object, e.g. alignment
0351   /// @param position global 3D position - considered to be on surface but not
0352   /// inside bounds (check is done)
0353   /// @param direction global 3D momentum direction
0354   /// @param tolerance optional tolerance within which a point is considered
0355   /// valid on surface
0356   ///
0357   /// @return a Result<Vector2> which can be !ok() if the operation fails
0358   virtual Result<Vector2> globalToLocal(
0359       const GeometryContext& gctx, const Vector3& position,
0360       const Vector3& direction,
0361       double tolerance = s_onSurfaceTolerance) const = 0;
0362 
0363   /// Return method for the reference frame
0364   /// This is the frame in which the covariance matrix is defined (specialized
0365   /// by all surfaces)
0366   ///
0367   /// @param gctx The current geometry context object, e.g. alignment
0368   /// @param position global 3D position - considered to be on surface but not
0369   /// inside bounds (check is done)
0370   /// @param direction global 3D momentum direction (optionally ignored)
0371   ///
0372   /// @return RotationMatrix3 which defines the three axes of the measurement
0373   /// frame
0374   virtual RotationMatrix3 referenceFrame(const GeometryContext& gctx,
0375                                          const Vector3& position,
0376                                          const Vector3& direction) const;
0377 
0378   /// Calculate the jacobian from local to global which the surface knows best,
0379   /// hence the calculation is done here.
0380   ///
0381   /// @note In principle, the input could also be a free parameters
0382   /// vector as it could be transformed to a bound parameters. But the transform
0383   /// might fail in case the parameters is not on surface. To avoid the check
0384   /// inside this function, it takes directly the bound parameters as input
0385   /// (then the check might be done where this function is called).
0386   ///
0387   /// @todo this mixes track parameterisation and geometry
0388   /// should move to :
0389   /// "Acts/EventData/detail/coordinate_transformations.hpp"
0390   ///
0391   /// @param gctx The current geometry context object, e.g. alignment
0392   /// @param position global 3D position
0393   /// @param direction global 3D momentum direction
0394   ///
0395   /// @return Jacobian from local to global
0396   virtual BoundToFreeMatrix boundToFreeJacobian(const GeometryContext& gctx,
0397                                                 const Vector3& position,
0398                                                 const Vector3& direction) const;
0399 
0400   /// Calculate the jacobian from global to local which the surface knows best,
0401   /// hence the calculation is done here.
0402   ///
0403   /// @note It assumes the input free parameters is on surface, hence no
0404   /// onSurface check is done inside this function.
0405   ///
0406   /// @todo this mixes track parameterisation and geometry
0407   /// should move to :
0408   /// "Acts/EventData/detail/coordinate_transformations.hpp"
0409   ///
0410   /// @param gctx The current geometry context object, e.g. alignment
0411   /// @param position global 3D position
0412   /// @param direction global 3D momentum direction
0413   ///
0414   /// @return Jacobian from global to local
0415   virtual FreeToBoundMatrix freeToBoundJacobian(const GeometryContext& gctx,
0416                                                 const Vector3& position,
0417                                                 const Vector3& direction) const;
0418 
0419   /// Calculate the derivative of path length at the geometry constraint or
0420   /// point-of-closest-approach w.r.t. free parameters. The calculation is
0421   /// identical for all surfaces where the reference frame does not depend on
0422   /// the direction
0423   ///
0424   /// @todo this mixes track parameterisation and geometry
0425   /// should move to :
0426   /// "Acts/EventData/detail/coordinate_transformations.hpp"
0427   ///
0428   /// @param gctx The current geometry context object, e.g. alignment
0429   /// @param position global 3D position
0430   /// @param direction global 3D momentum direction
0431   ///
0432   /// @return Derivative of path length w.r.t. free parameters
0433   virtual FreeToPathMatrix freeToPathDerivative(const GeometryContext& gctx,
0434                                                 const Vector3& position,
0435                                                 const Vector3& direction) const;
0436 
0437   /// Calculation of the path correction for incident
0438   ///
0439   /// @param gctx The current geometry context object, e.g. alignment
0440   /// @param position global 3D position
0441   /// @note The @p position is either ignored, or it is coerced to be on the surface,
0442   ///       depending on the surface type.
0443   /// @param direction global 3D momentum direction
0444   ///
0445   /// @return Path correction with respect to the nominal incident.
0446   virtual double pathCorrection(const GeometryContext& gctx,
0447                                 const Vector3& position,
0448                                 const Vector3& direction) const = 0;
0449 
0450   /// Straight line intersection schema from position/direction
0451   ///
0452   /// @param gctx The current geometry context object, e.g. alignment
0453   /// @param position The position to start from
0454   /// @param direction The direction at start
0455   /// @param boundaryTolerance the BoundaryTolerance
0456   /// @param tolerance the tolerance used for the intersection
0457   ///
0458   /// @return @c MultiIntersection3D intersection object
0459   virtual MultiIntersection3D intersect(
0460       const GeometryContext& gctx, const Vector3& position,
0461       const Vector3& direction,
0462       const BoundaryTolerance& boundaryTolerance =
0463           BoundaryTolerance::Infinite(),
0464       double tolerance = s_onSurfaceTolerance) const = 0;
0465 
0466   /// Helper method for printing: the returned object captures the
0467   /// surface and the geometry context and will print the surface
0468   /// @param gctx The current geometry context object, e.g. alignment
0469   /// @return The wrapper object for printing
0470   GeometryContextOstreamWrapper<Surface> toStream(
0471       const GeometryContext& gctx) const {
0472     return {*this, gctx};
0473   }
0474 
0475   /// Output into a std::string
0476   ///
0477   /// @param gctx The current geometry context object, e.g. alignment
0478   /// @return String representation of the surface
0479   std::string toString(const GeometryContext& gctx) const;
0480 
0481   /// Return properly formatted class name
0482   /// @return The surface class name as a string
0483   virtual std::string name() const = 0;
0484 
0485   /// Returns whether the Surface is sensitive
0486   /// @return True if the surface is sensitive
0487   bool isSensitive() const;
0488 
0489   /// Returns whether the Surface is alignable
0490   /// @return True if the surface is alignable
0491   bool isAlignable() const;
0492 
0493   /// Return a Polyhedron for surface objects
0494   ///
0495   /// @param gctx The current geometry context object, e.g. alignment
0496   /// @param quarterSegments The number of segemtns to approximate a 0.5*pi sector,
0497   /// which represents a quarter of the full circle
0498   ///
0499   /// @note In order to symmetrize the code between sectoral and closed cylinders
0500   /// in case of closed cylinders, both (-pi, pi) are given as separate vertices
0501   ///
0502   /// @note An internal surface transform can invalidate the extrema
0503   /// in the transformed space
0504   ///
0505   /// @return A list of vertices and a face/facett description of it
0506   virtual Polyhedron polyhedronRepresentation(
0507       const GeometryContext& gctx, unsigned int quarterSegments = 2u) const = 0;
0508 
0509   /// The derivative of bound track parameters w.r.t. alignment
0510   /// parameters of its reference surface (i.e. local frame origin in
0511   /// global 3D Cartesian coordinates and its rotation represented with
0512   /// extrinsic Euler angles)
0513   ///
0514   /// @param gctx The current geometry context object, e.g. alignment
0515   /// change of alignment parameters
0516   /// @param position global 3D position
0517   /// @param direction global 3D momentum direction
0518   /// @param pathDerivative is the derivative of free parameters w.r.t. path
0519   /// length
0520   ///
0521   /// @return Derivative of bound track parameters w.r.t. local frame
0522   /// alignment parameters
0523   AlignmentToBoundMatrix alignmentToBoundDerivative(
0524       const GeometryContext& gctx, const Vector3& position,
0525       const Vector3& direction, const FreeVector& pathDerivative) const;
0526 
0527   /// Calculate the derivative of path length at the geometry constraint or
0528   /// point-of-closest-approach w.r.t. alignment parameters of the surface (i.e.
0529   /// local frame origin in global 3D Cartesian coordinates and its rotation
0530   /// represented with extrinsic Euler angles)
0531   ///
0532   /// @note Re-implementation is needed for surface whose intersection with
0533   /// track is not its local xy plane, e.g. LineSurface, CylinderSurface and
0534   /// ConeSurface
0535   ///
0536   /// @param gctx The current geometry context object, e.g. alignment
0537   /// @param position global 3D position
0538   /// @param direction global 3D momentum direction
0539   ///
0540   /// @return Derivative of path length w.r.t. the alignment parameters
0541   virtual AlignmentToPathMatrix alignmentToPathDerivative(
0542       const GeometryContext& gctx, const Vector3& position,
0543       const Vector3& direction) const;
0544 
0545   /// Calculate the derivative of bound track parameters local position w.r.t.
0546   /// position in local 3D Cartesian coordinates
0547   ///
0548   /// @param gctx The current geometry context object, e.g. alignment
0549   /// @param position The position of the parameters in global
0550   ///
0551   /// @return Derivative of bound local position w.r.t. position in local 3D
0552   /// cartesian coordinates
0553   virtual Matrix<2, 3> localCartesianToBoundLocalDerivative(
0554       const GeometryContext& gctx, const Vector3& position) const = 0;
0555 
0556   /// Visualize the surface for debugging and inspection
0557   /// @param helper Visualization helper for 3D rendering
0558   /// @param gctx Geometry context for coordinate transformations
0559   /// @param viewConfig Visual configuration (color, style, etc.)
0560   void visualize(IVisualization3D& helper, const GeometryContext& gctx,
0561                  const ViewConfig& viewConfig = s_viewSurface) const;
0562 
0563  protected:
0564   /// Output Method for std::ostream, to be overloaded by child classes
0565   ///
0566   /// @param gctx The current geometry context object, e.g. alignment
0567   /// @param sl is the ostream to be dumped into
0568   /// @return Reference to the output stream for chaining
0569   virtual std::ostream& toStreamImpl(const GeometryContext& gctx,
0570                                      std::ostream& sl) const;
0571 
0572   /// Transform surface local coordinates to material local coordinates
0573   /// @param surfaceLocal The local coordinates on the surface
0574   /// @return The corresponding local coordinates for material lookup
0575   virtual Vector2 transformSurfaceLocalToMaterialLocal(
0576       const Vector2& surfaceLocal) const;
0577 
0578   /// Transform3 definition that positions
0579   /// (translation, rotation) the surface in global space
0580   CloneablePtr<const Transform3> m_transform;
0581 
0582   /// Possibility to attach a material description
0583   std::shared_ptr<const ISurfaceMaterial> m_surfaceMaterial;
0584 
0585   /// Whether to swap the local coordinates for material lookup
0586   bool m_swapMaterialAxes{false};
0587 
0588  private:
0589   /// Pointer to the a SurfacePlacement
0590   const SurfacePlacementBase* m_placement{nullptr};
0591 
0592   /// The associated layer Layer - layer in which the Surface is be embedded,
0593   /// nullptr if not associated
0594   const Layer* m_associatedLayer{nullptr};
0595 
0596   /// Flag to indicate whether the surface is sensitive
0597   bool m_isSensitive{false};
0598 
0599   /// Thickness of the surface in the normal direction
0600   double m_thickness{0.};
0601 
0602   /// Calculate the derivative of bound track parameters w.r.t.
0603   /// alignment parameters of its reference surface (i.e. origin in global 3D
0604   /// Cartesian coordinates and its rotation represented with extrinsic Euler
0605   /// angles) without any path correction
0606   ///
0607   /// @note This function should be used together with alignment to path
0608   /// derivative to get the full alignment to bound derivatives
0609   ///
0610   /// @param gctx The current geometry context object, e.g. alignment
0611   /// @param position global 3D position
0612   /// @param direction global 3D momentum direction
0613   ///
0614   /// @return Derivative of bound track parameters w.r.t. local frame alignment
0615   /// parameters without path correction
0616   AlignmentToBoundMatrix alignmentToBoundDerivativeWithoutCorrection(
0617       const GeometryContext& gctx, const Vector3& position,
0618       const Vector3& direction) const;
0619 };
0620 
0621 }  // namespace Acts
0622 
0623 ACTS_OSTREAM_FORMATTER(Acts::Surface::SurfaceType);