Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2025-01-18 09:12:12

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/Geometry/GeometryContext.hpp"
0013 #include "Acts/Surfaces/Surface.hpp"
0014 #include "Acts/Surfaces/SurfaceError.hpp"
0015 
0016 #include <array>
0017 #include <functional>
0018 
0019 namespace ActsFatras {
0020 
0021 /// The PlanarSurfaceDrift takes an intersection in the nominal surface and
0022 /// projects the ends into the readout surface, which can be at : -1, 0, 1
0023 ///
0024 /// A Lorentz drift angle can be applied.
0025 ///
0026 struct PlanarSurfaceDrift {
0027   /// Shorthand for a 2D segment
0028   using Segment2D = std::array<Acts::Vector2, 2>;
0029 
0030   /// Drift the full 3D segment onto a surface 2D readout plane
0031   ///
0032   /// @param gctx The current Geometry context
0033   /// @param surface The nominal intersection surface
0034   /// @param thickness The emulated module/depletion thickness
0035   /// @param pos The position in global coordinates
0036   /// @param dir The direction in global coordinates
0037   /// @param driftdir The drift direction in local (surface) coordinates
0038   /// @note a drift direction of (0,0,0) is drift to central plane
0039   ///       any other a drift direction with driftDir.z() != 0.
0040   ///       will result on a readout on either + 0.5*depletion
0041   ///       or -0.5*depletion
0042   ///
0043   /// @return a Segment on the readout surface @note without masking
0044   Segment2D toReadout(const Acts::GeometryContext& gctx,
0045                       const Acts::Surface& surface, double thickness,
0046                       const Acts::Vector3& pos, const Acts::Vector3& dir,
0047                       const Acts::Vector3& driftdir) const;
0048 };
0049 
0050 }  // namespace ActsFatras