ATLAS Offline Software
IUpdator.h
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2021 CERN for the benefit of the ATLAS collaboration
3 */
4 
6 // IUpdator.h
7 // Header file for interface of Updator
9 // (c) ATLAS Detector software
11 // Markus.Elsing@cern.ch
13 
14 #ifndef TRK_IUPDATOR_H
15 #define TRK_IUPDATOR_H
16 
18 #include "GaudiKernel/IAlgTool.h"
19 #include "TrkEventPrimitives/FitQualityOnSurface.h" // typedef
20 #include "TrkParameters/TrackParameters.h" // typedef
21 #include <memory>
22 #include <vector>
23 static const InterfaceID IID_IUpdator("Trk::IUpdator", 1, 0);
24 
25 namespace Trk {
26 
27 #ifndef CreateParDef
28 #define CreateParDef
29 #define CREATE_PARAMETERS(ref, x, cov) \
30  (ref).associatedSurface().createUniqueTrackParameters(x[Trk::loc1], \
31  x[Trk::loc2], \
32  x[Trk::phi], \
33  x[Trk::theta], \
34  x[Trk::qOverP], \
35  cov)
36 #define CLONEWITHOUTCOV(ref) \
37  ref.associatedSurface().createUniqueTrackParameters( \
38  ref.parameters[Trk::loc1], \
39  ref.parameters[Trk::loc2], \
40  ref.parameters[Trk::phi], \
41  ref.parameters[Trk::theta], \
42  ref.parameters[Trk::qOverP])
43 #endif
44 
45 class LocalParameters;
46 
63 class IUpdator : virtual public IAlgTool
64 {
65 public:
67  static const InterfaceID& interfaceID();
70  virtual std::unique_ptr<TrackParameters> addToState(
71  const TrackParameters&,
72  const Amg::Vector2D&,
73  const Amg::MatrixX&) const = 0;
77  virtual std::unique_ptr<TrackParameters> addToState(
78  const TrackParameters&,
79  const LocalParameters&,
80  const Amg::MatrixX&) const = 0;
84  virtual std::unique_ptr<TrackParameters> addToState(
85  const TrackParameters&,
86  const Amg::Vector2D&,
87  const Amg::MatrixX&,
88  FitQualityOnSurface*&) const = 0;
92  virtual std::unique_ptr<TrackParameters> addToState(
93  const TrackParameters&,
94  const LocalParameters&,
95  const Amg::MatrixX&,
96  FitQualityOnSurface*&) const = 0;
97 
102  virtual std::unique_ptr<TrackParameters> removeFromState(
103  const TrackParameters&,
104  const Amg::Vector2D&,
105  const Amg::MatrixX&) const = 0;
111  virtual std::unique_ptr<TrackParameters> removeFromState(
112  const TrackParameters&,
113  const LocalParameters&,
114  const Amg::MatrixX&) const = 0;
120  virtual std::unique_ptr<TrackParameters> removeFromState(
121  const TrackParameters&,
122  const Amg::Vector2D&,
123  const Amg::MatrixX&,
124  FitQualityOnSurface*&) const = 0;
130  virtual std::unique_ptr<TrackParameters> removeFromState(
131  const TrackParameters&,
132  const LocalParameters&,
133  const Amg::MatrixX&,
134  FitQualityOnSurface*&) const = 0;
135 
143  virtual std::unique_ptr<TrackParameters> combineStates(
144  const TrackParameters&,
145  const TrackParameters&) const = 0;
154  virtual std::unique_ptr<TrackParameters> combineStates(
155  const TrackParameters&,
156  const TrackParameters&,
157  FitQualityOnSurface*&) const = 0;
158 
163  const AmgVector(5) &,
164  const AmgSymMatrix(5) &,
165  const Amg::VectorX&,
166  const Amg::MatrixX&,
167  int,
169  bool) const = 0;
170 
178  const TrackParameters&,
179  const Amg::Vector2D&,
180  const Amg::MatrixX&) const = 0;
188  const TrackParameters&,
189  const LocalParameters&,
190  const Amg::MatrixX&) const = 0;
198  const TrackParameters&,
199  const Amg::Vector2D&,
200  const Amg::MatrixX&) const = 0;
208  const TrackParameters&,
209  const LocalParameters&,
210  const Amg::MatrixX&) const = 0;
216  const TrackParameters&,
217  const TrackParameters&) const = 0;
218 
221  virtual std::vector<double> initialErrors() const = 0;
222 };
223 
224 } // end of namespace
225 
226 inline const InterfaceID&
228 {
229  return IID_IUpdator;
230 }
231 
232 #endif // TRK_IUPDATOR_H
Trk::IUpdator::initialErrors
virtual std::vector< double > initialErrors() const =0
let the client tools know how the assumptions on the initial precision for non-measured track paramet...
Trk::IUpdator::removeFromState
virtual std::unique_ptr< TrackParameters > removeFromState(const TrackParameters &, const LocalParameters &, const Amg::MatrixX &, FitQualityOnSurface *&) const =0
the reverse updating or inverse KalmanFilter removes a measurement from the track state,...
Trk::LocalParameters
Definition: LocalParameters.h:98
Trk::IUpdator::interfaceID
static const InterfaceID & interfaceID()
Algtool infrastructure.
Definition: IUpdator.h:227
Amg::VectorX
Eigen::Matrix< double, Eigen::Dynamic, 1 > VectorX
Dynamic Vector - dynamic allocation.
Definition: EventPrimitives.h:30
Amg::MatrixX
Eigen::Matrix< double, Eigen::Dynamic, Eigen::Dynamic > MatrixX
Dynamic Matrix - dynamic allocation.
Definition: EventPrimitives.h:27
TrackParameters.h
Amg::Vector2D
Eigen::Matrix< double, 2, 1 > Vector2D
Definition: GeoPrimitives.h:48
Trk::IUpdator::predictedStateFitQuality
virtual FitQualityOnSurface predictedStateFitQuality(const TrackParameters &, const LocalParameters &, const Amg::MatrixX &) const =0
estimator for FitQuality on Surface from a predicted track state, that is a state which does not cont...
Trk::IUpdator::updateParameterDifference
virtual std::pair< AmgVector(5), AmgSymMatrix(5)> * updateParameterDifference(const AmgVector(5) &, const AmgSymMatrix(5) &, const Amg::VectorX &, const Amg::MatrixX &, int, Trk::FitQualityOnSurface *&, bool) const =0
pure AMG interface for reference-track KF, allowing update of parameter differences
Trk::IUpdator::addToState
virtual std::unique_ptr< TrackParameters > addToState(const TrackParameters &, const LocalParameters &, const Amg::MatrixX &, FitQualityOnSurface *&) const =0
the updator interface with FitQualityOnSurface allows to save the chi2 in one step with the updating ...
FitQualityOnSurface.h
Trk::IUpdator::fullStateFitQuality
virtual FitQualityOnSurface fullStateFitQuality(const TrackParameters &, const LocalParameters &, const Amg::MatrixX &) const =0
estimator for FitQuality on Surface from a full track state, that is a state which contains the curre...
Trk::AmgSymMatrix
AmgSymMatrix(5) &GXFTrackState
Definition: GXFTrackState.h:156
Trk::FitQualityOnSurface
Definition: FitQualityOnSurface.h:19
Trk::IUpdator::predictedStateFitQuality
virtual FitQualityOnSurface predictedStateFitQuality(const TrackParameters &, const TrackParameters &) const =0
estimator for FitQuality on Surface for the situation when a track is fitted to the parameters of ano...
Trk::IUpdator::fullStateFitQuality
virtual FitQualityOnSurface fullStateFitQuality(const TrackParameters &, const Amg::Vector2D &, const Amg::MatrixX &) const =0
estimator for FitQuality on Surface from a full track state, that is a state which contains the curre...
Trk::IUpdator::predictedStateFitQuality
virtual FitQualityOnSurface predictedStateFitQuality(const TrackParameters &, const Amg::Vector2D &, const Amg::MatrixX &) const =0
estimator for FitQuality on Surface from a predicted track state, that is a state which does not cont...
Trk::IUpdator::removeFromState
virtual std::unique_ptr< TrackParameters > removeFromState(const TrackParameters &, const Amg::Vector2D &, const Amg::MatrixX &) const =0
the reverse updating or inverse KalmanFilter removes a measurement from the track state,...
Trk::IUpdator::combineStates
virtual std::unique_ptr< TrackParameters > combineStates(const TrackParameters &, const TrackParameters &, FitQualityOnSurface *&) const =0
adds to a track state the parameters from another state using a statistical combination and determine...
Trk::IUpdator::addToState
virtual std::unique_ptr< TrackParameters > addToState(const TrackParameters &, const Amg::Vector2D &, const Amg::MatrixX &) const =0
updator for Kalman-Filter based algorithms getting the measurement coordinates from Amg::Vector2D (us...
Trk::IUpdator::addToState
virtual std::unique_ptr< TrackParameters > addToState(const TrackParameters &, const Amg::Vector2D &, const Amg::MatrixX &, FitQualityOnSurface *&) const =0
the updator interface with FitQualityOnSurface allows to save the chi2 in one step with the updating ...
AmgVector
AmgVector(4) T2BSTrackFilterTool
Definition: T2BSTrackFilterTool.cxx:114
Trk::ParametersBase
Definition: ParametersBase.h:55
Trk::IUpdator::removeFromState
virtual std::unique_ptr< TrackParameters > removeFromState(const TrackParameters &, const LocalParameters &, const Amg::MatrixX &) const =0
the reverse updating or inverse KalmanFilter removes a measurement from the track state,...
Trk::IUpdator::addToState
virtual std::unique_ptr< TrackParameters > addToState(const TrackParameters &, const LocalParameters &, const Amg::MatrixX &) const =0
updator for Kalman-Filter based algorithms getting the measurement coordinates from LocalParameters (...
EventPrimitives.h
Trk
Ensure that the ATLAS eigen extensions are properly loaded.
Definition: FakeTrackBuilder.h:9
Trk::IUpdator
Set of interfaces for methods operating on track states, mainly for Kalman filtering.
Definition: IUpdator.h:64
Trk::IUpdator::removeFromState
virtual std::unique_ptr< TrackParameters > removeFromState(const TrackParameters &, const Amg::Vector2D &, const Amg::MatrixX &, FitQualityOnSurface *&) const =0
the reverse updating or inverse KalmanFilter removes a measurement from the track state,...
Trk::IUpdator::combineStates
virtual std::unique_ptr< TrackParameters > combineStates(const TrackParameters &, const TrackParameters &) const =0
adds to a track state the parameters from another state using a statistical combination - use with ca...