MarlinTPC  1.2.0
KalTrackingHelix.h
1 #ifndef HELIKALTRACK_H
2 #define HELIKALTRACK_H
3 
4 #include "KalTrackingTemplate.h"
5 
6 //KalTest
7 #include <kaltest/TKalTrack.h>
8 
9 namespace marlintpc
10 {
11 
19 class KalTrackingHelix : public KalTrackingTemplate<TKalTrack>
20 {
21  public:
22  KalTrackingHelix(const gear::GearMgr &gearMgr,
23  int minTrackHits,
24  int maxSkipRows,
25  double maxDeltaChi2,
26  int hitDistanceFactor,
27  int hitStartingMode,
28  double vDrift,
29  std::string modulesNotUsed);
30 
33  inline int getType()
34  {
35  return 1;
36  }
37 
38  protected:
39 
42  bool doAddAndFilter(TKalTrack * track, ModuleRowHit hit) ;
43 
54  // virtual TKalTrack * createTrackCandidate( ModuleRowHit hit );
55 
58  virtual bool searchTrack(ModuleRowHit hit);
59 
61  virtual TMatrixD calculateStartHelix(ModuleRowHit const & hit1,
62  ModuleRowHit const & hit2,
63  ModuleRowHit const & hit3);
64 
65  // TVector3 getTangent();
66 
69  virtual void printStateVector();
70 
71  static double toBaseRange(double phi);
72 
76  virtual void setLCIOTrackParameters(IMPL::TrackImpl* trk) ;
77 
80  virtual double calculateDeltaChi2(TKalTrack * trackCandidate);
81  virtual Intersection extrapolateIntoNextLayer(int targetDistance,
82  bool useFarHit);
83 
84  virtual const kaldet::GearTPCMeasLayer* extrapolateIntoNextLayer(int targetDistance);
85 
86  virtual gear::Vector2D getNearestPointInNextLayer(ModuleRowHit firstHit);
87 
88  virtual double getTrackTangentAndLayerAngle(TKalTrack* track);
89  virtual TKalTrackSite* createInitialSite(ModuleRowHit& mrh1, ModuleRowHit& mrh2, ModuleRowHit& mrh3);
90 
91  private:
93  KalTrackingHelix & operator=(KalTrackingHelix const &);
94 
95  // a friend class for unit testing the protected member functions
96  friend class KalTrackingHelixTester;
97 };
98 
99 
100 }
101 #endif //HELIKALTRACK_H
virtual TMatrixD calculateStartHelix(ModuleRowHit const &hit1, ModuleRowHit const &hit2, ModuleRowHit const &hit3)
Calculate the initial track state starting from three hits.
int getType()
Get track type: helix.
Definition: KalTrackingHelix.h:33
Class to test KalTrackingHelix.
Definition: KalTrackingHelixTester.h:27
Struct to hold module and row and a hit in this row.
Definition: TPCHitMap.h:79
virtual void setLCIOTrackParameters(IMPL::TrackImpl *trk)
Fill the track state (incl.
virtual void printStateVector()
Print track parameters.
virtual bool searchTrack(ModuleRowHit hit)
Create a track candidate by making a KalHit from the ModuleRowHit and creating a TrackSite from it...
bool doAddAndFilter(TKalTrack *track, ModuleRowHit hit)
Add a new site to track and update track parameters.
This is the helix track class, which inherits from KalTrackingTemplate and TKalTrack.
Definition: KalTrackingHelix.h:19
This is a base KalDet tracking class.
Definition: KalTrackingTemplate.h:31
virtual double calculateDeltaChi2(TKalTrack *trackCandidate)
Get the deltaChi2 from the track candidate.
virtual Intersection extrapolateIntoNextLayer(int targetDistance, bool useFarHit)
Use the current track state of the containerTrack to extrapolate into the next layer.