1 #ifndef MarlinDDKalTestTrack_h
2 #define MarlinDDKalTestTrack_h
21 class MarlinDDKalTest;
43 #ifdef MARLINTRK_DIAGNOSTICS_ON
44 friend class DiagnosticsController;
105 int fit(
double maxChi2Increment=DBL_MAX ) ;
126 int addAndFit( DDVTrackHit* kalhit,
double& chi2increment, TKalTrackSite*& site,
double maxChi2Increment=DBL_MAX ) ;
331 while( phi <= -
M_PI ){ phi += 2. *
M_PI ; }
332 while( phi >
M_PI ){ phi -= 2. *
M_PI ; }
int getHitsInFit(std::vector< std::pair< EVENT::TrackerHit *, double > > &hits)
get the list of hits included in the fit, together with the chi2 contributions of the hits...
MarlinDDKalTestTrack(MarlinDDKalTest *ktest)
int intersectionWithDetElement(int detElementID, Vector3D &point, int mode=modeClosest)
extrapolate the fit to numbered sensitive detector element, returning intersection point in global co...
int getSiteFromLCIOHit(EVENT::TrackerHit *trkhit, TKalTrackSite *&site) const
get the measurement site associated with the given lcio TrackerHit trkhit
std::string toString()
Dump this track to a string for debugging.
MarlinDDKalTestTrack & operator=(const MarlinDDKalTestTrack &)
int propagateToLayer(int layerID, IMPL::TrackStateImpl &ts, double &chi2, int &ndf, int &detElementID, int mode=modeClosest)
propagate the fit to the numbered sensitive layer, returning TrackState, chi2, ndf and integer ID of ...
int findIntersection(std::vector< DDVMeasLayer const * > &meas_modules, const TKalTrackSite &site, Vector3D &point, int &detElementID, const DDVMeasLayer *&ml, int mode=modeClosest)
extrapolate the fit at the measurement site, to sensitive detector elements contained in the std::vec...
std::map< EVENT::TrackerHit *, DDVTrackHit * > _lcio_hits_to_kaltest_hits
map to store relation between lcio hits kaltest hits
EVENT::TrackerHitVec _lcioHits
int extrapolate(const Vector3D &point, IMPL::TrackStateImpl &ts, double &chi2, int &ndf)
extrapolate the fit to the point of closest approach to the given point, returning TrackState...
bool _fitDirection
used to store the fit direction supplied to intialise
void ToLCIOTrackState(const TKalTrackSite &site, IMPL::TrackStateImpl &ts, double &chi2, int &ndf) const
fill LCIO Track State with parameters from helix and cov matrix
int getNDF(int &ndf)
get the current number of degrees of freedom for the fit.
static const int modeClosest
int fit(double maxChi2Increment=DBL_MAX)
perform the fit of all current hits, returns error code ( IMarlinTrack::success if no error ) ...
int addHit(EVENT::TrackerHit *hit)
add hit to track - the hits have to be added ordered in time ( i.e.
std::map< EVENT::TrackerHit *, TKalTrackSite * > _hit_used_for_sites
map to store relation between lcio hits and measurement sites
void setMass(double mass)
set the mass of the charged particle (GeV) that is used for energy loss and multiple scattering - def...
bool _initialised
used to store whether initial track state has been supplied or created
int _hitIndexAtPositiveNDF
int testChi2Increment(EVENT::TrackerHit *hit, double &chi2increment)
obtain the chi2 increment which would result in adding the hit to the fit.
int extrapolateToDetElement(int detElementID, IMPL::TrackStateImpl &ts, double &chi2, int &ndf, int mode=modeClosest)
extrapolate the fit to sensitive detector element, returning TrackState, chi2 and ndf via reference ...
Interface for generic tracks in MarlinTrk.
double getMass()
return the of the charged particle (GeV) that is used for energy loss and multiple scattering...
int initialise(bool fitDirection)
initialise the fit using the hits added up to this point - the fit direction has to be specified usin...
int getTrackerHitAtPositiveNDF(EVENT::TrackerHit *&trkhit)
get TrackeHit at which fit became constrained, i.e.
EVENT::TrackerHit * _trackHitAtPositiveNDF
std::vector< std::pair< EVENT::TrackerHit *, double > > _outlier_chi2_values
vector to store the chi-sqaure increment for measurement sites
double toBaseRange(double phi) const
helper function to restrict the range of the azimuthal angle to ]-pi,pi]
int propagate(const Vector3D &point, IMPL::TrackStateImpl &ts, double &chi2, int &ndf)
propagate the fit to the point of closest approach to the given point, returning TrackState, chi2 and ndf via reference
Interface to KaltTest Kalman fitter - instantiates and holds the detector geometry.
int propagateToDetElement(int detElementID, IMPL::TrackStateImpl &ts, double &chi2, int &ndf, int mode=modeClosest)
propagate the fit to sensitive detector element, returning TrackState, chi2 and ndf via reference ...
int smooth()
smooth all track states
int getOutliers(std::vector< std::pair< EVENT::TrackerHit *, double > > &hits)
get the list of hits which have been rejected by from the fit due to the a chi2 increment greater tha...
int addAndFit(EVENT::TrackerHit *hit, double &chi2increment, double maxChi2Increment=DBL_MAX)
update the current fit using the supplied hit, return code via int.
std::vector< EVENT::TrackerHit * > _hit_not_used_for_sites
vector to store lcio hits rejected for measurement sites
std::vector< std::pair< EVENT::TrackerHit *, double > > _hit_chi2_values
vector to store the chi-sqaure increment for measurement sites
int extrapolateToLayer(int layerID, IMPL::TrackStateImpl &ts, double &chi2, int &ndf, int &detElementID, int mode=modeClosest)
extrapolate the fit to numbered sensitive layer, returning TrackState via provided reference ...
bool _smoothed
used to store whether smoothing has been performed
int getTrackState(IMPL::TrackStateImpl &ts, double &chi2, int &ndf)
get track state, returning TrackState, chi2 and ndf via reference
int intersectionWithLayer(int layerID, Vector3D &point, int &detElementID, int mode=modeClosest)
extrapolate the fit to numbered sensitive layer, returning intersection point in global coordinates a...