10#include <tracking/trackFindingCDC/geometry/Helix.h>
12#include <tracking/trackFindingCDC/geometry/UncertainPerigeeCircle.h>
13#include <tracking/trackFindingCDC/geometry/UncertainSZLine.h>
14#include <tracking/trackFindingCDC/geometry/SZLine.h>
16#include <tracking/trackFindingCDC/geometry/HelixParameters.h>
17#include <tracking/trackFindingCDC/geometry/PerigeeParameters.h>
18#include <tracking/trackFindingCDC/geometry/SZParameters.h>
19#include <tracking/trackFindingCDC/geometry/Vector2D.h>
30 namespace TrackFindingCDC {
47 const double tanLambda,
50 const double chi2 = 0.0,
52 :
m_helix(curvature, phi0, impact, tanLambda, z0)
62 const double chi2 = 0.0,
76 const double tanLambda,
79 const double chi2 = 0.0,
81 :
m_helix(curvature, phi0Vec, impact, tanLambda, z0)
91 const double chi2 = 0.0,
353 std::ostream& operator<<(std::ostream& output,
const UncertainHelix& uncertainHelix);
Extension of the generalized circle also caching the perigee coordinates.
void reverse()
Flips the travel direction of the helix in place, pivot point is unchanged.
Helix reversed() const
Returns a copy of the helix with flips the travel direction, pivot point is the same.
double shiftPeriod(int nPeriods)
Adjust the arclength measure to start n periods later.
HelixParameters helixParameters() const
Getter for the five helix parameters in the order defined by EHelixParameter.h.
void invalidate()
Sets all circle parameters to zero.
double passiveMoveBy(const Vector3D &by)
Moves the coordinates system by the given vector.
HelixJacobian passiveMoveByJacobian(const Vector3D &by) const
Computes the Jacobi matrix for a move of the coordinate system by the given vector.
const SZLine & szLine() const
Getter for the projection into xy space.
A matrix implementation to be used as an interface typ through out the track finder.
SZJacobian passiveMoveByJacobian(const Vector2D &bySZ) const
Computes the Jacobi matrix for a move of the coordinate system by the given vector.
A general helix class including a covariance matrix.
double variance(const EHelixParameter &i) const
Getter for individual diagonal elements of the covariance matrix.
UncertainHelix(const double curvature, const double phi0, const double impact, const double tanLambda, const double z0, const HelixCovariance &helixCovariance=HelixUtil::identity(), const double chi2=0.0, std::size_t ndf=0)
Composes an uncertain perigee circle from the perigee parameters and a 3x3 covariance matrix.
const HelixCovariance & helixCovariance() const
Getter for the whole covariance matrix of the perigee parameters.
UncertainHelix()
Default constructor for ROOT compatibility.
void reverse()
Flips the orientation of the circle in place.
UncertainHelix reversed() const
Returns a copy of the circle with opposite orientation.
UncertainSZLine uncertainSZLine() const
Reduces the helix to an sz line carrying over the relevant parts of the convariance matrix.
UncertainHelix(const UncertainPerigeeCircle &uncertainPerigeeCircle, const UncertainSZLine &uncertainSZLine)
Augments a plain helix with a covariance matrix. Covariance defaults to zero.
UncertainHelix(const HelixParameters ¶meters, const HelixCovariance &helixCovariance=HelixUtil::identity(), const double chi2=0.0, std::size_t ndf=0)
Constructor taking all stored parameters.
double covariance(const EHelixParameter &iRow, const EHelixParameter &iCol) const
Getter for individual elements of the covariance matrix.
static UncertainHelix average(const UncertainHelix &fromHelix, const UncertainHelix &toHelix)
Construct the averages of the two given helices by properly considering their covariance matrix.
void setHelixCovariance(const HelixCovariance &helixCovariance)
Setter for the whole covariance matrix of the perigee parameters.
HelixCovariance m_helixCovariance
Memory for the 5x5 covariance matrix of the helix parameters.
double shiftPeriod(int nPeriods)
Adjust the arclength measure to start n periods later.
void passiveMoveBy(const Vector3D &by)
Moves the coordinate system by the vector by and calculates the new perigee and its covariance matrix...
double m_chi2
Memory for the chi square value of the fit of this helix.
HelixParameters helixParameters() const
Getter for the perigee parameters in the order defined by EPerigeeParameter.h.
void invalidate()
Sets all circle parameters to zero and the covariance matrix to something noninformative.
double chi2() const
Getter for the chi square value of the helix fit.
void setNDF(std::size_t ndf)
Setter for the number of degrees of freediom used in the helix fit.
size_t m_ndf
Memory for the number of degrees of freedom of the fit of this helix.
UncertainHelix(const Helix &helix, const HelixCovariance &helixCovariance=HelixUtil::identity(), const double chi2=0.0, std::size_t ndf=0)
Augments a plain helix with a covariance matrix. Covariance defaults to zero.
UncertainHelix(const double curvature, const Vector2D &phi0Vec, const double impact, const double tanLambda, const double z0, const HelixCovariance &helixCovariance=HelixUtil::identity(), const double chi2=0.0, std::size_t ndf=0)
Composes an uncertain perigee circle from the perigee parameters and a 3x3 covariance matrix.
Helix m_helix
Memory for the underlying helix.
void setChi2(const double chi2)
Setter for the chi square value of the helix fit.
static UncertainHelix average(const UncertainHelix &helix, const UncertainPerigeeCircle &perigeeCircle, const PerigeeHelixAmbiguity &ambiguityMatrix)
Construct the average helix including its covariance matrix incoorporating additional information fro...
std::size_t ndf() const
Getter for the number of degrees of freediom used in the helix fit.
const Helix & helix() const
Getter for the underlying helix.
UncertainPerigeeCircle uncertainCircleXY() const
Projects the helix into the xy plain carrying over the relevant parts of the convariance matrix.
const Helix * operator->() const
Access to the constant interface of the underlying parameter line Allows the user of this "super" cla...
Adds an uncertainty matrix to the circle in perigee parameterisation.
A line in sz where s is the transverse travel distance as seen in the xy projection with uncertaintie...
A two dimensional vector which is equipped with functions for correct handling of orientation relate...
A three dimensional vector.
HepGeom::Vector3D< double > Vector3D
3D Vector
EHelixParameter
Enumeration to address the individual helix parameters in a vector or matrix.
Abstract base class for different kinds of events.
Utility struct for functions and types related to the helix parameters.
static SZUtil::CovarianceMatrix getSZCovariance(const CovarianceMatrix &helixCov)
Get sz covariance matrix.
static HelixUtil::CovarianceMatrix stackBlocks(const PerigeeUtil::CovarianceMatrix &perigeeCov, const SZUtil::CovarianceMatrix &szCov)
Combine covariance matrices from the xy space and the sz space in their respective blocks.
static PerigeeUtil::CovarianceMatrix getPerigeeCovariance(const CovarianceMatrix &helixCov)
Get perigee covariance matrix related to the xy space.
static void transport(const JacobianMatrix &jacobian, CovarianceMatrix &cov)
Transport the covariance matrix inplace with the given jacobian matrix.
static CovarianceMatrix identity()
Returns an identity matrix.
static void reverse(CovarianceMatrix &cov)
Reverse the covariance matrix inplace.
static CovarianceMatrix reversed(const CovarianceMatrix &cov)
Return a copy of the reversed covariance matrix.