30 return StatusCode::SUCCESS;
44 if (! Decorated.
isAvailable(*particle) || !Decorated(*particle)){
48 Decorated(*particle) =
false;
51 Eta(*particle) = pTag->position().eta();
52 Phi(*particle) = pTag->position().phi();
53 Decorated(*particle) =
true;
68 ATH_MSG_WARNING(
"Pivot plane extrapolation not supported for Truth muons!");
72 if(!muonTrack &&
dynamic_cast<const xAOD::Muon*
>(muon)) {
74 muonTrack = theMuon->
trackParticle( xAOD::Muon::MuonSpectrometerTrackParticle );
78 muonTrack = theMuon->
trackParticle( xAOD::Muon::InnerDetectorTrackParticle );
83 ATH_MSG_WARNING(
"no valid track found for extrapolating the muon to the pivot plane!");
94 return StatusCode::FAILURE;
100 if( muon->pt() > 3500.){
103 ATH_MSG_WARNING(
"Failed to extrapolate+decorate muon with pivot plane coords - Muon params: pt "<<muon->pt()<<
", eta "<< muon->eta()<<
", phi "<< muon->phi());
107 return StatusCode::SUCCESS;
113 const Trk::Perigee& perigee = track.perigeeParameters();
124 ATH_MSG_WARNING(
"extrapolateToTriggerPivotPlane :: new Trk::CylinderSurface failed.");
128 bool boundaryCheck =
true;
144 float SignOfEta = track.eta() > 0 ? 1. : -1.;
148 matrix =
Amg::Transform3D(Amg::RotationMatrix3D::Identity(), SignOfEta * endcapCentre);
150 std::unique_ptr<Trk::DiscSurface> disc =
151 std::make_unique<Trk::DiscSurface>(matrix,
155 ATH_MSG_WARNING(
"extrapolateToTriggerPivotPlane :: new Trk::DiscSurface failed.");
160 boundaryCheck =
false;
161 surface = disc.get();
Scalar eta() const
pseudorapidity method
Scalar phi() const
phi method
#define ATH_CHECK
Evaluate an expression and check for errors.
#define ATH_MSG_WARNING(x)
xAOD::MuonContainer * muonContainer
SG::Decorator< T, ALLOC > Decorator
bool isAvailable(const ELT &e) const
Test to see if this variable exists in the store.
Class for a CylinderSurface in the ATLAS detector.
Abstract Base Class for tracking surfaces.
Class providing the definition of the 4-vector interface.
const TrackParticle * primaryTrackParticle() const
Returns a pointer (which should not usually be NULL, but might be if the muon has been stripped of in...
const TrackParticle * trackParticle(TrackParticleType type) const
Returns a pointer (which can be NULL) to the TrackParticle used in identification of this muon.
Eigen::Affine3d Transform3D
Eigen::Matrix< double, 3, 1 > Vector3D
ParametersT< TrackParametersDim, Charged, PerigeeSurface > Perigee
ParametersBase< TrackParametersDim, Charged > TrackParameters
TrackParticle_v1 TrackParticle
Reference the current persistent version:
TruthParticle_v1 TruthParticle
Typedef to implementation.
Muon_v1 Muon
Reference the current persistent version: