Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2026-05-03 07:38:29

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/TrackParametrization.hpp"
0013 
0014 namespace Acts {
0015 
0016 /// @class LinearizedTrack
0017 ///
0018 /// Class for linear expansion of track parameters in vicinity of vertex
0019 ///
0020 /// The measurement equation is linearized in the following way:
0021 ///
0022 /// F_k= D_k (x_k - x_0k) + E_k (p_k - p_0k) + F^0_k
0023 ///
0024 /// where F_k are the parameters at perigee nearest to the linearization point,
0025 /// x_k is the position of the vertex, p_k the track momentum at the vertex,
0026 /// and F^0_k is the constant term of expansion. D_k and E_k are matrices
0027 /// of derivatives, denoted hereafter as "positionJacobian" and
0028 /// "momentumJacobian" respectively.
0029 ///
0030 
0031 struct LinearizedTrack {
0032   LinearizedTrack() = default;
0033 
0034   /// @brief Constructor taking perigee parameters and covariance matrix
0035   /// of track propagated to closest approach (PCA) of linearization point,
0036   /// position and momentum Jacobian and const term.
0037   ///
0038   /// @param paramsAtPCA Parameters at point of closest approach
0039   /// @param parCovarianceAtPCA Parameter covariance matrix at point of closest
0040   ///                           approach
0041   /// @param parWeightAtPCA The weight at the point of closest approach
0042   /// @param linPoint Linearization point
0043   /// @param posJacobian Position jacobian
0044   /// @param momJacobian Momentum jacobian
0045   /// @param position Position at point of closest approach
0046   /// @param momentum Momentum at point of closest approach
0047   /// @param constTerm Constant term in taylor expansion
0048   LinearizedTrack(const BoundVector& paramsAtPCA,
0049                   const BoundMatrix& parCovarianceAtPCA,
0050                   const BoundMatrix& parWeightAtPCA, const Vector4& linPoint,
0051                   const Matrix<eBoundSize, 4>& posJacobian,
0052                   const Matrix<eBoundSize, 3>& momJacobian,
0053                   const Vector4& position, const Vector3& momentum,
0054                   const BoundVector& constTerm)
0055       : parametersAtPCA(paramsAtPCA),
0056         covarianceAtPCA(parCovarianceAtPCA),
0057         weightAtPCA(parWeightAtPCA),
0058         linearizationPoint(linPoint),
0059         positionJacobian(posJacobian),
0060         momentumJacobian(momJacobian),
0061         positionAtPCA(position),
0062         momentumAtPCA(momentum),
0063         constantTerm(constTerm) {}
0064 
0065   /// Track parameters at the point of closest approach
0066   BoundVector parametersAtPCA{BoundVector::Zero()};
0067   /// Covariance matrix of track parameters at PCA
0068   BoundMatrix covarianceAtPCA{BoundMatrix::Zero()};
0069   /// Weight matrix (inverse covariance) at PCA
0070   BoundMatrix weightAtPCA{BoundMatrix::Zero()};
0071   /// 4D point where track was linearized for vertex fitting
0072   Vector4 linearizationPoint{Vector4::Zero()};
0073   /// Jacobian of track parameters w.r.t. vertex position
0074   Matrix<eBoundSize, 4> positionJacobian{Matrix<eBoundSize, 4>::Zero()};
0075   /// Jacobian of track parameters w.r.t. track momentum
0076   Matrix<eBoundSize, 3> momentumJacobian{Matrix<eBoundSize, 3>::Zero()};
0077   /// 4D position of track at point of closest approach
0078   Vector4 positionAtPCA{Vector4::Zero()};
0079   /// 3D momentum vector at point of closest approach
0080   Vector3 momentumAtPCA{Vector3::Zero()};
0081   /// Constant term in linearized track equation
0082   BoundVector constantTerm{BoundVector::Zero()};
0083 };
0084 
0085 }  // namespace Acts