ATLAS Offline Software
ApproximateTrackToLayerTool.cxx
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2020 CERN for the benefit of the ATLAS collaboration
3 */
4 
6 
8 {
9 }
10 
12  const EventContext &,
13  const xAOD::TrackParticle &track) const
14 {
15  // The approximation doesn't affect track etas at all
16  double eta = track.eta();
17  double sinDPhi = (m_trackExtrapolationLinear.value() +
20  (track.pt() * track.charge());
21 
22  if (std::abs(sinDPhi) > 1.0)
23  // The track was extrapolated outside of acceptance
24  return TrackExtension{};
25  else
26  return TrackExtension{track.eta(), track.phi() - std::asin(sinDPhi)};
27 }
ApproximateTrackToLayerTool::ApproximateTrackToLayerTool
ApproximateTrackToLayerTool(const std::string &name)
Definition: ApproximateTrackToLayerTool.cxx:7
ApproximateTrackToLayerTool::m_trackExtrapolationLinear
Gaudi::Property< double > m_trackExtrapolationLinear
Definition: ApproximateTrackToLayerTool.h:30
ApproximateTrackToLayerTool::m_trackExtrapolationQuadratic
Gaudi::Property< double > m_trackExtrapolationQuadratic
Definition: ApproximateTrackToLayerTool.h:27
eta
Scalar eta() const
pseudorapidity method
Definition: AmgMatrixBasePlugin.h:83
asg
Definition: DataHandleTestTool.h:28
IExtendTrackToLayerTool::TrackExtension
Helper struct to hold track extrapolation information.
Definition: IExtendTrackToLayerTool.h:27
ApproximateTrackToLayerTool::m_trackExtrapolationQuartic
Gaudi::Property< double > m_trackExtrapolationQuartic
Definition: ApproximateTrackToLayerTool.h:24
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:221
ApproximateTrackToLayerTool::extendTrack
virtual TrackExtension extendTrack(const EventContext &, const xAOD::TrackParticle &track) const override
Extend the track to a given layer.
Definition: ApproximateTrackToLayerTool.cxx:11
xAOD::track
@ track
Definition: TrackingPrimitives.h:512
xAOD::TrackParticle_v1
Class describing a TrackParticle.
Definition: TrackParticle_v1.h:43
ApproximateTrackToLayerTool.h