Belle II Software development
KLMTrackFitter.h
1/**************************************************************************
2 * basf2 (Belle II Analysis Software Framework) *
3 * Author: The Belle II Collaboration *
4 * *
5 * See git log for contributors and copyright holders. *
6 * This file is licensed under LGPL-3.0, see LICENSE.md. *
7 **************************************************************************/
8
9#pragma once
10
11/* KLM headers. */
12#include <klm/geometry/KLMGeometryPar.h>
13#include <klm/dataobjects/KLMHit2d.h>
14#include <klm/dataobjects/KLMElementNumbers.h>
15
16/* CLHEP headers. */
17#include <CLHEP/Matrix/SymMatrix.h>
18#include <CLHEP/Matrix/Vector.h>
19
20/* C++ headers. */
21#include <list>
22
23namespace Belle2 {
31
32 public:
33
36
39
41 double fit(std::list<KLMHit2d*>& listTrackPoint);
42
43
45 double globalDistanceToHit(KLMHit2d* hit,
46 double& error,
47 double& sigma);
48
49
51 double fit1dTrack(std::list< KLMHit2d* > hitList,
52 CLHEP::HepVector& eta,
53 CLHEP::HepSymMatrix& error,
54 int depDir, int indDir);
55
57 CLHEP::HepVector getTrackParam()
58 {
59 return m_GlobalPar;
60 }
61
63 CLHEP::HepSymMatrix getTrackParamErr()
64 {
65 return m_GlobalErr;
66 }
67
68
70 bool isValid()
71 {
72 return m_Valid;
73 }
74
76 bool isGood()
77 {
78 return m_Good;
79 }
80
82 float getChi2()
83 {
84 return m_Chi2;
85 }
86
89 {
90 return m_NumHit;
91 }
92
95 {
96 m_Valid = false;
97 }
98
99
100 private:
101
104
106 bool m_Good;
107
109 float m_Chi2;
110
113
115 CLHEP::HepVector m_GlobalPar;
116
118 CLHEP::HepSymMatrix m_GlobalErr;
119
122
123 };
125} // end of namespace Belle2
KLM 2d hit.
Definition: KLMHit2d.h:33
track fitting procedure
double fit(std::list< KLMHit2d * > &listTrackPoint)
do fit and returns chi square of the fit.
float m_Chi2
Chi square of fit.
float getChi2()
Chi square of the fit.
bool isGood()
Is fit good.
double fit1dTrack(std::list< KLMHit2d * > hitList, CLHEP::HepVector &eta, CLHEP::HepSymMatrix &error, int depDir, int indDir)
do fit in the global system
~KLMTrackFitter()
Destructor.
int m_NumHit
the number of hits on this track
double globalDistanceToHit(KLMHit2d *hit, double &error, double &sigma)
Distance from track to a hit in the global system.
Belle2::KLM::KLMGeometryPar * m_GeoPar
pointer to GeometryPar singleton
CLHEP::HepSymMatrix m_GlobalErr
track params errors in global system
int getNumHit()
number of the hits on this track
CLHEP::HepSymMatrix getTrackParamErr()
Get invariance matrix of track parameters in the global system.
CLHEP::HepVector m_GlobalPar
track params in global system
CLHEP::HepVector getTrackParam()
Get track parameters in the global system. y = p0 + p1 * x; z = p2 + p3 * x.
bool m_Valid
Is fit valid.
void inValidate()
Invalidate track.
KLMTrackFitter()
Default constructor.
bool m_Good
Is fit good.
bool isValid()
Is fit valid.
Wrapper class around bklm::GeometryPar and EKLM::GeometryData.
Abstract base class for different kinds of events.