PandaRoot
GFTools.h
Go to the documentation of this file.
1 /* Copyright 2011, Technische Universitaet Muenchen,
2  Author: Karl Bicker
3 
4  This file is part of GENFIT.
5 
6  GENFIT is free software: you can redistribute it and/or modify
7  it under the terms of the GNU Lesser General Public License as published
8  by the Free Software Foundation, either version 3 of the License, or
9  (at your option) any later version.
10 
11  GENFIT is distributed in the hope that it will be useful,
12  but WITHOUT ANY WARRANTY; without even the implied warranty of
13  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14  GNU Lesser General Public License for more details.
15 
16  You should have received a copy of the GNU Lesser General Public License
17  along with GENFIT. If not, see <http://www.gnu.org/licenses/>.
18 */
20 /* @{ */
21 
22 #ifndef GFTOOLS_H
23 #define GFTOOLS_H
24 
25 #include <cmath>
26 #include "GFAbsTrackRep.h"
27 #include <GFDetPlane.h>
28 #include <GFException.h>
29 #include <GFTrack.h>
30 #include <TMath.h>
31 #include <TMatrixT.h>
32 #include <TDecompSVD.h>
33 //#include <TDecompBK.h>
34 //#include <TDecompChol.h>
35 
44 namespace GFTools {
45 
48 TMatrixT<double> getSmoothedPos(GFTrack *trk, unsigned int irep, unsigned int ihit);
49 
52 TMatrixT<double> getSmoothedCov(GFTrack *trk, unsigned int irep, unsigned int ihit);
53 
56 bool getSmoothedData(GFTrack *trk, unsigned int irep, unsigned int ihit, TMatrixT<double> &smoothed_state, TMatrixT<double> &smoothed_cov);
57 
63 bool getSmoothedData(GFTrack *trk, unsigned int irep, unsigned int ihit, TMatrixT<double> &smoothed_state, TMatrixT<double> &smoothed_cov, GFDetPlane &smoothing_plane);
64 
82 bool getSmoothedData(GFTrack *trk, unsigned int irep, unsigned int ihit, TMatrixT<double> &smoothed_state, TMatrixT<double> &smoothed_cov, GFDetPlane &smoothing_plane,
83  TMatrixT<double> &auxInfo);
84 
87 GFDetPlane getSmoothingPlane(GFTrack *trk, unsigned int irep, unsigned int ihit);
88 
91 bool getBiasedSmoothedData(GFTrack *trk, unsigned int irep, unsigned int ihit, TMatrixT<double> &smoothed_state, TMatrixT<double> &smoothed_cov);
92 
98 bool getBiasedSmoothedData(GFTrack *trk, unsigned int irep, unsigned int ihit, TMatrixT<double> &smoothed_state, TMatrixT<double> &smoothed_cov, GFDetPlane &smoothing_plane);
99 
106 bool getBiasedSmoothedData(GFTrack *trk, unsigned int irep, unsigned int ihit, TMatrixT<double> &smoothed_state, TMatrixT<double> &smoothed_cov, GFDetPlane &smoothing_plane,
107  TMatrixT<double> &auxInfo);
108 
111 TMatrixT<double> getBiasedSmoothedPos(GFTrack *trk, unsigned int irep, unsigned int ihit);
112 
115 TMatrixT<double> getBiasedSmoothedCov(GFTrack *trk, unsigned int irep, unsigned int ihit);
116 
119 void invertMatrix(const TMatrixT<double> &mat, TMatrixT<double> &inv);
129 double getSmoothedChiSqu(GFTrack *const trk, unsigned int irep, unsigned int ihit);
130 
131 } // namespace GFTools
132 
133 #endif
134 
bool getBiasedSmoothedData(GFTrack *trk, unsigned int irep, unsigned int ihit, TMatrixT< double > &smoothed_state, TMatrixT< double > &smoothed_cov)
Get biased smoothed state vector and state covariance.
TMatrixT< double > getSmoothedPos(GFTrack *trk, unsigned int irep, unsigned int ihit)
Get smoothed track position in plane coordinates.
GFDetPlane getSmoothingPlane(GFTrack *trk, unsigned int irep, unsigned int ihit)
Get smoothing plane.
Detector plane genfit geometry class.
Definition: GFDetPlane.h:58
Track object for genfit. genfit algorithms work on these objects.
Definition: GFTrack.h:59
Namespace for various tools, mainly smoothing.
bool getSmoothedData(GFTrack *trk, unsigned int irep, unsigned int ihit, TMatrixT< double > &smoothed_state, TMatrixT< double > &smoothed_cov)
Get smoothed state vector and state covariance.
void invertMatrix(const TMatrixT< double > &mat, TMatrixT< double > &inv)
Invert a matrix, throwing GFException when inversion fails.
double getSmoothedChiSqu(GFTrack *const trk, unsigned int irep, unsigned int ihit)
Get smoothed chi2 for a specific hit (ihit).
TMatrixT< double > getSmoothedCov(GFTrack *trk, unsigned int irep, unsigned int ihit)
Get smoothed track covariance in plane coordinates.
TMatrixT< double > getBiasedSmoothedCov(GFTrack *trk, unsigned int irep, unsigned int ihit)
Get biased smoothed track covariance in plane coordinates.
TMatrixT< double > getBiasedSmoothedPos(GFTrack *trk, unsigned int irep, unsigned int ihit)
Get biased smoothed track position in plane coordinates.