CalibPPS
AlignmentRelative
interface
LocalTrackFit.h
Go to the documentation of this file.
1
/****************************************************************************
2
* Authors:
3
* Jan Kašpar (jan.kaspar@gmail.com)
4
****************************************************************************/
5
6
#ifndef CalibPPS_AlignmentRelative_LocalTrackFit_h
7
#define CalibPPS_AlignmentRelative_LocalTrackFit_h
8
9
#include "TMath.h"
10
15
struct
LocalTrackFit
{
17
double
z0
;
18
20
double
ax
,
ay
;
21
23
double
bx
,
by
;
24
26
signed
int
ndf
;
27
29
double
chi_sq
;
30
31
LocalTrackFit
(
double
_z0 = 0.,
32
double
_ax = 0.,
33
double
_ay = 0.,
34
double
_bx = 0.,
35
double
_by = 0.,
36
unsigned
int
_ndf = 0,
37
double
_chi_sq = 0.)
38
:
z0
(_z0),
ax
(_ax),
ay
(_ay),
bx
(_bx),
by
(_by),
ndf
(_ndf),
chi_sq
(_chi_sq) {}
39
40
double
pValue
()
const
{
return
TMath::Prob(
chi_sq
,
ndf
); }
41
42
double
chiSqPerNdf
()
const
{
return
(
ndf
> 0) ?
chi_sq
/
ndf
: 0.; }
43
44
void
eval
(
double
z
,
double
&
x
,
double
&
y
) {
45
double
ze =
z
-
z0
;
46
x
=
ax
* ze +
bx
;
47
y
=
ay
* ze +
by
;
48
}
49
};
50
51
#endif
DDAxes::y
LocalTrackFit::ndf
signed int ndf
the number of degrees of freedom
Definition:
LocalTrackFit.h:27
LocalTrackFit::chiSqPerNdf
double chiSqPerNdf() const
Definition:
LocalTrackFit.h:43
DDAxes::x
LocalTrackFit::by
double by
Definition:
LocalTrackFit.h:24
LocalTrackFit::LocalTrackFit
LocalTrackFit(double _z0=0., double _ax=0., double _ay=0., double _bx=0., double _by=0., unsigned int _ndf=0, double _chi_sq=0.)
Definition:
LocalTrackFit.h:32
DDAxes::z
LocalTrackFit::chi_sq
double chi_sq
the residual sum of squares
Definition:
LocalTrackFit.h:30
LocalTrackFit::pValue
double pValue() const
Definition:
LocalTrackFit.h:41
LocalTrackFit::ax
double ax
slopes in rad
Definition:
LocalTrackFit.h:21
LocalTrackFit::eval
void eval(double z, double &x, double &y)
Definition:
LocalTrackFit.h:45
LocalTrackFit::bx
double bx
intercepts in mm
Definition:
LocalTrackFit.h:24
LocalTrackFit
Local (linear) track description (or a fit result). Uses global reference system.
Definition:
LocalTrackFit.h:14
LocalTrackFit::z0
double z0
the point where intercepts are measured, in mm
Definition:
LocalTrackFit.h:18
LocalTrackFit::ay
double ay
Definition:
LocalTrackFit.h:21
Generated for CMSSW Reference Manual by
1.8.16