PandaRoot
GFAbsRecoHit.h
Go to the documentation of this file.
1 //****************************************************************************
2 //* This file is part of PandaRoot. *
3 //* *
4 //* PandaRoot is distributed under the terms of the *
5 //* GNU General Public License (GPL) version 3, *
6 //* copied verbatim in the file "LICENSE". *
7 //* *
8 //* Copyright (C) 2006 - 2024 FAIR GmbH and copyright holders of PandaRoot *
9 //* The copyright holders are listed in the file "COPYRIGHTHOLDERS". *
10 //* The authors are listed in the file "AUTHORS". *
11 //****************************************************************************
12 
13 /* Copyright 2008-2010, Technische Universitaet Muenchen,
14  Authors: Christian Hoeppner & Sebastian Neubert
15 
16  This file is part of GENFIT.
17 
18  GENFIT is free software: you can redistribute it and/or modify
19  it under the terms of the GNU Lesser General Public License as published
20  by the Free Software Foundation, either version 3 of the License, or
21  (at your option) any later version.
22 
23  GENFIT is distributed in the hope that it will be useful,
24  but WITHOUT ANY WARRANTY; without even the implied warranty of
25  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
26  GNU Lesser General Public License for more details.
27 
28  You should have received a copy of the GNU Lesser General Public License
29  along with GENFIT. If not, see <http://www.gnu.org/licenses/>.
30 */
32 /* @{ */
33 
34 #ifndef GFABSRECOHIT_H
35 #define GFABSRECOHIT_H
36 
37 #include <iostream>
38 
39 #include "TMatrixT.h"
40 #include "TObject.h"
41 
42 #include "GFAbsTrackRep.h"
43 #include "GFDetPlane.h"
44 
83 class GFAbsRecoHit : public TObject {
84  protected:
86  TMatrixT<double> fHitCoord;
87 
89  TMatrixT<double> fHitCov;
90 
91  private:
92  int fNparHit;
93 
94  public:
95  virtual ~GFAbsRecoHit();
96 
103  GFAbsRecoHit(int NparHit);
104 
107  GFAbsRecoHit();
108 
134  virtual TMatrixT<double> getHMatrix(const GFAbsTrackRep *stateVector) = 0;
135 
151  virtual TMatrixT<double> residualVector(const GFAbsTrackRep *stateVector, const TMatrixT<double> &state, const GFDetPlane &d)
152  {
153  TMatrixT<double> H = getHMatrix(stateVector);
154  return (getHitCoord(d) - (H * state));
155  }
156 
160  TMatrixT<double> getRawHitCov() const { return fHitCov; }
161 
165  TMatrixT<double> getRawHitCoord() const { return fHitCoord; }
166 
174  virtual TMatrixT<double> getHitCov(const GFDetPlane &) = 0;
175 
183  virtual TMatrixT<double> getHitCoord(const GFDetPlane &) = 0;
184 
199  virtual const GFDetPlane &getDetPlane(GFAbsTrackRep *) = 0;
200 
207  virtual GFAbsRecoHit *clone() = 0;
208 
211  virtual void Print() { fHitCoord.Print(); }
212 
213  virtual const std::string &getPolicyName();
214 
215  int getNparHit() { return fNparHit; }
216 
217  public:
218  ClassDef(GFAbsRecoHit, 3)
219 };
220 
221 #endif // FITTER_ABSHIT_H
222 
Base Class for genfit track representations. Defines interface for track parameterizations.
Definition: GFAbsTrackRep.h:92
virtual TMatrixT< double > residualVector(const GFAbsTrackRep *stateVector, const TMatrixT< double > &state, const GFDetPlane &d)
Calculate residual with respect to a track representation.
Definition: GFAbsRecoHit.h:151
TMatrixT< double > getRawHitCoord() const
Get raw hit coordinates.
Definition: GFAbsRecoHit.h:165
Detector plane genfit geometry class.
Definition: GFDetPlane.h:70
TMatrixT< double > fHitCoord
Vector of raw coordinates of hit.
Definition: GFAbsRecoHit.h:86
virtual const GFDetPlane & getDetPlane(GFAbsTrackRep *)=0
Get detector plane for a given track representation.
virtual const std::string & getPolicyName()
TMatrixT< double > getRawHitCov() const
Get raw hit covariances.
Definition: GFAbsRecoHit.h:160
virtual TMatrixT< double > getHMatrix(const GFAbsTrackRep *stateVector)=0
Get transformation matrix. Transformation between hit coordinates and track representation coordinate...
GFAbsRecoHit()
Default constructor needed for compatibility with ROOT.
virtual ~GFAbsRecoHit()
int getNparHit()
Definition: GFAbsRecoHit.h:215
virtual GFAbsRecoHit * clone()=0
Get clone of this object.
virtual TMatrixT< double > getHitCov(const GFDetPlane &)=0
Get hit covariances in a specific detector plane.
Base Class for representing a Hit in GENFIT.
Definition: GFAbsRecoHit.h:83
virtual void Print()
Print raw hit coordinates.
Definition: GFAbsRecoHit.h:211
virtual TMatrixT< double > getHitCoord(const GFDetPlane &)=0
Get hit coordinates in a specific detector plane.
TMatrixT< double > fHitCov
Covariance of raw hit coordinates.
Definition: GFAbsRecoHit.h:89