#include <Eigen/Core>
#include <Eigen/Eigenvalues>
#include "RecoTracker/PixelTrackFitting/interface/FitUtils.h"
Go to the source code of this file.
Namespaces | |
riemannFit | |
Functions | |
template<typename M2xN > | |
__host__ __device__ int32_t | riemannFit::charge (const M2xN &p2D, const Vector3d &par_uvr) |
Find particle q considering the sign of cross product between particles velocity (estimated by the first 2 hits) and the vector radius between the first hit and the center of the fitted circle. More... | |
template<typename M2xN , typename V4 , int N> | |
__host__ __device__ CircleFit | riemannFit::circleFit (const M2xN &hits2D, const Matrix2Nd< N > &hits_cov2D, const V4 &fast_fit, const VectorNd< N > &rad, const double bField, const bool error) |
Fit a generic number of 2D points with a circle using Riemann-Chernov algorithm. Covariance matrix of fitted parameter is optionally computed. Multiple scattering (currently only in barrel layer) is optionally handled. More... | |
template<typename VNd1 , typename VNd2 > | |
__host__ __device__ void | riemannFit::computeRadLenUniformMaterial (const VNd1 &length_values, VNd2 &rad_lengths) |
template<typename M2xN , int N> | |
__host__ __device__ VectorNd< N > | riemannFit::cov_carttorad (const M2xN &p2D, const Matrix2Nd< N > &cov_cart, const VectorNd< N > &rad) |
Transform covariance matrix from Cartesian coordinates (only transverse plane component) to radial coordinates (both radial and tangential component but only diagonal terms, correlation between different point are not managed). More... | |
template<typename M2xN , typename V4 , int N> | |
__host__ __device__ VectorNd< N > | riemannFit::cov_carttorad_prefit (const M2xN &p2D, const Matrix2Nd< N > &cov_cart, V4 &fast_fit, const VectorNd< N > &rad) |
Transform covariance matrix from Cartesian coordinates (only transverse plane component) to coordinates system orthogonal to the pre-fitted circle in each point. Further information in attached documentation. More... | |
template<typename M2xN , int N> | |
__host__ __device__ Matrix2Nd< N > | riemannFit::cov_radtocart (const M2xN &p2D, const MatrixNd< N > &cov_rad, const VectorNd< N > &rad) |
Transform covariance matrix from radial (only tangential component) to Cartesian coordinates (only transverse plane component). More... | |
template<typename M3xN , typename V4 > | |
__host__ __device__ void | riemannFit::fastFit (const M3xN &hits, V4 &result) |
A very fast helix fit: it fits a circle by three points (first, middle and last point) and a line by two points (first and last). More... | |
template<int N> | |
HelixFit | riemannFit::helixFit (const Matrix3xNd< N > &hits, const Eigen::Matrix< float, 6, N > &hits_ge, const double bField, const bool error) |
Helix fit by three step: -fast pre-fit (see Fast_fit() for further info); -circle fit of hits projected in the transverse plane by Riemann-Chernov algorithm (see Circle_fit() for further info); -line fit of hits projected on cylinder surface by orthogonal distance regression (see Line_fit for further info). Points must be passed ordered (from inner to outer layer). More... | |
template<typename M3xN , typename M6xN , typename V4 > | |
__host__ __device__ LineFit | riemannFit::lineFit (const M3xN &hits, const M6xN &hits_ge, const CircleFit &circle, const V4 &fast_fit, const double bField, const bool error) |
Perform an ordinary least square fit in the s-z plane to compute the parameters cotTheta and Zip. More... | |
__host__ __device__ Vector2d | riemannFit::min_eigen2D (const Matrix2d &aMat, double &chi2) |
2D version of min_eigen3D(). More... | |
__host__ __device__ Vector3d | riemannFit::min_eigen3D (const Matrix3d &A, double &chi2) |
Compute the eigenvector associated to the minimum eigenvalue. More... | |
__host__ __device__ Vector3d | riemannFit::min_eigen3D_fast (const Matrix3d &A) |
A faster version of min_eigen3D() where double precision is not needed. More... | |
template<typename M2xN , typename V4 , int N> | |
__host__ __device__ MatrixNd< N > | riemannFit::scatter_cov_rad (const M2xN &p2D, const V4 &fast_fit, VectorNd< N > const &rad, double B) |
Compute the covariance matrix (in radial coordinates) of points in the transverse plane due to multiple Coulomb scattering. More... | |
template<typename V4 , typename VNd1 , typename VNd2 , int N> | |
__host__ __device__ auto | riemannFit::scatterCovLine (Matrix2d const *cov_sz, const V4 &fast_fit, VNd1 const &s_arcs, VNd2 const &z_values, const double theta, const double bField, MatrixNd< N > &ret) |
Compute the covariance matrix along cartesian S-Z of points due to multiple Coulomb scattering to be used in the line_fit, for the barrel and forward cases. The input covariance matrix is in the variables s-z, original and unrotated. The multiple scattering component is computed in the usual linear approximation, using the 3D path which is computed as the squared root of the squared sum of the s and z components passed in. Internally a rotation by theta is performed and the covariance matrix returned is the one in the direction orthogonal to the rotated S3D axis, i.e. along the rotated Z axis. The choice of the rotation is not arbitrary, but derived from the fact that putting the horizontal axis along the S3D direction allows the usage of the ordinary least squared fitting techiques with the trivial parametrization y = mx + q, avoiding the patological case with m = +/- inf, that would correspond to the case at eta = 0. More... | |
template<int N> | |
__host__ __device__ VectorNd< N > | riemannFit::weightCircle (const MatrixNd< N > &cov_rad_inv) |
Compute the points' weights' vector for the circle fit when multiple scattering is managed. Further information in attached documentation. More... | |