ATLAS Offline Software
Loading...
Searching...
No Matches
CurvedLine.h
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2021 CERN for the benefit of the ATLAS collaboration
3*/
4#ifndef MuonCalib_CurvedLineH
5#define MuonCalib_CurvedLineH
6
7//::::::::::::::::::::::
8//:: CLASS CurvedLine ::
9//::::::::::::::::::::::
10
16
17//::::::::::::::::::
18//:: HEADER FILES ::
19//::::::::::::::::::
20
21#include <vector>
22
27
28namespace MuonCalib {
29
30 class CurvedLine {
31 public:
34
35 // Constructors //
36 CurvedLine();
39
40 CurvedLine(std::vector<Amg::Vector3D> &points);
45
46 CurvedLine(std::vector<Amg::Vector3D> &points, std::vector<Amg::Vector3D> &x_and_y_errors);
52
53 // Methods //
54 // get-methods //
55 Amg::Vector3D getPointOnLine(const double loc_z) const;
58
59 MTStraightLine getTangent(const double loc_z) const;
62
64 void setChi2(double chi2);
65 double chi2() const;
66
68 void setNumberOfTrackHits(unsigned int n_hits);
69 unsigned int numberOfTrackHits() const;
71 double chi2PerDegreesOfFreedom() const;
72
73 void setUsedHits(const MdtHitVec &hits);
74 const MdtHitVec &trackHits() const;
75
76 private:
77 Amg::VectorX m_coeff_xz; // coefficients of the straight line in the local
78 // xz plane
79 Amg::VectorX m_coeff_yz; // coefficients of the curved line in the local
80 // yz plane
81
82 double m_chi2{-1};
83 unsigned int m_numTrkHits{0};
85
86 // private methods //
87 void init(std::vector<Amg::Vector3D> &points, std::vector<Amg::Vector3D> &x_and_y_errors);
88 // initialization routine
89 };
90
91} // namespace MuonCalib
92
93#endif
Amg::VectorX m_coeff_yz
Definition CurvedLine.h:79
unsigned int m_numTrkHits
Definition CurvedLine.h:83
void setChi2(double chi2)
Cache the chi2.
double chi2PerDegreesOfFreedom() const
Return chi2 / number of TrackHits - 3.
const MdtHitVec & trackHits() const
double chi2() const
MTStraightLine getTangent(const double loc_z) const
get the tangent to the line a the local z coordinate "loc_z"
unsigned int numberOfTrackHits() const
MuonCalibSegment::MdtHitVec MdtHitVec
Definition CurvedLine.h:32
Amg::VectorX m_coeff_xz
Definition CurvedLine.h:77
void init(std::vector< Amg::Vector3D > &points, std::vector< Amg::Vector3D > &x_and_y_errors)
MuonCalibSegment::MdtHitPtr MdtHitPtr
Definition CurvedLine.h:33
Amg::Vector3D getPointOnLine(const double loc_z) const
get the point on the line a the local z coordinate "loc_z"
void setUsedHits(const MdtHitVec &hits)
CurvedLine()
Default constructor: a straight line through (0,0,0) pointing in in the local x direction of the cham...
void setNumberOfTrackHits(unsigned int n_hits)
cache the number of track hits
std::shared_ptr< MdtCalibHitBase > MdtHitPtr
typedef for a collection of MdtCalibHitBase s
std::vector< MdtHitPtr > MdtHitVec
Eigen::Matrix< double, 3, 1 > Vector3D
Eigen::Matrix< double, Eigen::Dynamic, 1 > VectorX
Dynamic Vector - dynamic allocation.
CscCalcPed - algorithm that finds the Cathode Strip Chamber pedestals from an RDO.