GENFIT Rev: NoNumberAvailable
Loading...
Searching...
No Matches
KalmanFitter.h
Go to the documentation of this file.
1/* Copyright 2013, Ludwig-Maximilians Universität München,
2 Authors: Tobias Schlüter & Johannes Rauch
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*/
22
23#ifndef genfit_KalmanFitter_h
24#define genfit_KalmanFitter_h
25
26#include "AbsKalmanFitter.h"
27
28#include <memory>
29
30
31namespace genfit {
32
35class TrackPoint;
36
41
42 private:
43
44 // These private functions are needed, otherwise strange things happen, no idea why!
47
48 public:
49
50 KalmanFitter(unsigned int maxIterations = 4, double deltaPval = 1e-3, double blowUpFactor = 1e3, bool squareRootFormalism = false)
51 : AbsKalmanFitter(maxIterations, deltaPval, blowUpFactor), currentState_(nullptr),
52 squareRootFormalism_(squareRootFormalism)
53 {}
54
56
58 void processTrackWithRep(Track* tr, const AbsTrackRep* rep, bool resortHits = false) override;
59
62 void processTrackPartially(Track* tr, const AbsTrackRep* rep, int startId = 0, int endId = -1);
63
64 void useSquareRootFormalism(bool squareRootFormalism = true) {squareRootFormalism_ = squareRootFormalism;}
65
66 private:
67 bool fitTrack(Track* tr, const AbsTrackRep* rep, double& chi2, double& ndf, int startId, int endId, int& nFailedHits);
69 const AbsTrackRep* rep, double& chi2, double& ndf, int direction);
70
71 std::unique_ptr<MeasuredStateOnPlane> currentState_;
72
74
75 public:
76 ClassDefOverride(KalmanFitter,1)
77
78};
79
80} /* End of namespace genfit */
82
83#endif //genfit_KalmanFitter_h
AbsKalmanFitter(unsigned int maxIterations=4, double deltaPval=1e-3, double blowUpFactor=1e3)
Abstract base class for a track representation.
Definition AbsTrackRep.h:66
void processTrackPartially(Track *tr, const AbsTrackRep *rep, int startId=0, int endId=-1)
void useSquareRootFormalism(bool squareRootFormalism=true)
KalmanFitter(const KalmanFitter &)
void processTrackWithRep(Track *tr, const AbsTrackRep *rep, bool resortHits=false) override
Hit resorting currently NOT supported.
std::unique_ptr< MeasuredStateOnPlane > currentState_
KalmanFitter & operator=(KalmanFitter const &)
bool fitTrack(Track *tr, const AbsTrackRep *rep, double &chi2, double &ndf, int startId, int endId, int &nFailedHits)
KalmanFitter(unsigned int maxIterations=4, double deltaPval=1e-3, double blowUpFactor=1e3, bool squareRootFormalism=false)
void processTrackPoint(TrackPoint *tp, const AbsTrackRep *rep, double &chi2, double &ndf, int direction)
Collects information needed and produced by a AbsKalmanFitter implementations and is specific to one ...
StateOnPlane with additional covariance matrix.
Collection of TrackPoint objects, AbsTrackRep objects and FitStatus objects.
Definition Track.h:71
Object containing AbsMeasurement and AbsFitterInfo objects.
Definition TrackPoint.h:46
Defines for I/O streams used for error and debug printing.