PandaRoot
GeaneTrackRep Class Reference

#include <GeaneTrackRep.h>

Inheritance diagram for GeaneTrackRep:
GFAbsTrackRep

Public Member Functions

 GeaneTrackRep ()
 
 GeaneTrackRep (FairGeanePro *geane, const GFDetPlane &plane, const TVector3 &mom, const TVector3 &poserr, const TVector3 &momerr, double q, int PDGCode)
 
 GeaneTrackRep (FairGeanePro *geane, const GFDetPlane &plane, const TVector3 &mom, const TVector3 &poserr, const TVector3 &momerr, int q, int PDGCode)
 
virtual ~GeaneTrackRep ()
 
virtual GFAbsTrackRepclone () const
 
virtual GFAbsTrackRepprototype () const
 
virtual double extrapolate (const GFDetPlane &, TMatrixT< double > &statePred)
 returns the tracklength spanned in this extrapolation More...
 
virtual double extrapolate (const GFDetPlane &, TMatrixT< double > &statePred, TMatrixT< double > &covPred)
 Extrapolates the track to the given detectorplane. More...
 
void extrapolateToPoint (const TVector3 &pos, TVector3 &poca, TVector3 &dirInPoca)
 This method is to extrapolate the track to point of closest approach to a point in space. More...
 
void extrapolateToLine (const TVector3 &point1, const TVector3 &point2, TVector3 &poca, TVector3 &dirInPoca, TVector3 &poca_onwire)
 This method extrapolates to the point of closest approach to a line. More...
 
TVector3 getPocaOnLine (const TVector3 &p1, const TVector3 &p2, bool back=false)
 
virtual TVector3 getPos (const GFDetPlane &)
 
virtual TVector3 getMom (const GFDetPlane &)
 
virtual void getPosMom (const GFDetPlane &, TVector3 &pos, TVector3 &mom)
 
virtual void getPosMomCov (const GFDetPlane &pl, TVector3 &pos, TVector3 &mom, TMatrixT< double > &cov)
 method which gets position, momentum and 6x6 covariance matrix More...
 
virtual double getCharge () const
 
int getPropDir ()
 
FairGeanePro * getPropagator ()
 
int getPDG ()
 
double getSPU ()
 
void setPropagator (FairGeanePro *g)
 
void setPropDir (int d)
 
void switchDirection ()
 
- Public Member Functions inherited from GFAbsTrackRep
 GFAbsTrackRep ()
 
 GFAbsTrackRep (int)
 
virtual ~GFAbsTrackRep ()
 
virtual double stepalong (double h, TVector3 &point, TVector3 &dir)
 make step of h cm along the track More...
 
double extrapolate (const GFDetPlane &plane)
 This changes the state and cov and plane of the rep. More...
 
unsigned int getDim () const
 returns dimension of state vector More...
 
virtual void Print () const
 
TMatrixT< double > getState () const
 
TMatrixT< double > getCov () const
 
double getStateElem (int i) const
 
double getCovElem (int i, int j) const
 
TVector3 getPos ()
 
TVector3 getMom ()
 
void getPosMomCov (TVector3 &pos, TVector3 &mom, TMatrixT< double > &c)
 
TMatrixT< double > getFirstState () const
 
TMatrixT< double > getFirstCov () const
 
GFDetPlane getFirstPlane () const
 
TMatrixT< double > getLastState () const
 
TMatrixT< double > getLastCov () const
 
GFDetPlane getLastPlane () const
 
double getChiSqu () const
 
double getRedChiSqu () const
 returns chi2/ndf More...
 
unsigned int getNDF () const
 
virtual void setData (const TMatrixT< double > &st, const GFDetPlane &pl, const TMatrixT< double > *cov=nullptr, const TMatrixT< double > *aux=nullptr)
 Puts the track representation in a given state. More...
 
void setCov (const TMatrixT< double > &aCov)
 
void setFirstState (const TMatrixT< double > &aState)
 
void setFirstCov (const TMatrixT< double > &aCov)
 
void setFirstPlane (const GFDetPlane &aPlane)
 
void setLastState (const TMatrixT< double > &aState)
 
void setLastCov (const TMatrixT< double > &aCov)
 
void setLastPlane (const GFDetPlane &aPlane)
 
const GFDetPlanegetReferencePlane () const
 
void setChiSqu (double aChiSqu)
 
void setNDF (unsigned int n)
 
void addChiSqu (double aChiSqu)
 
void addNDF (unsigned int n)
 
void setStatusFlag (int _val)
 
bool setInverted (bool f=true)
 Deprecated. Should be removed soon. More...
 
bool getStatusFlag ()
 
virtual void reset ()
 
virtual bool hasAuxInfo ()
 See if the track representation has auxillary information stored. More...
 
virtual const TMatrixT< double > * getAuxInfo (const GFDetPlane &)
 Get auxillary information from the track representation. More...
 

Friends

std::ostream & operator<< (std::ostream &s, const GeaneTrackRep &me)
 

Additional Inherited Members

- Protected Attributes inherited from GFAbsTrackRep
unsigned int fDimension
 Dimensionality of track representation. More...
 
TMatrixT< double > fState
 The vector of track parameters. More...
 
TMatrixT< double > fCov
 The covariance matrix. More...
 
double fChiSqu
 chiSqu of the track fit More...
 
unsigned int fNdf
 
int fStatusFlag
 status of track representation: 0 means everything's OK More...
 
bool fInverted
 specifies the direction of flight of the particle More...
 
TMatrixT< double > fFirstState
 state, cov and plane for first and last point in fit More...
 
TMatrixT< double > fFirstCov
 
TMatrixT< double > fLastState
 
TMatrixT< double > fLastCov
 
GFDetPlane fFirstPlane
 
GFDetPlane fLastPlane
 
GFDetPlane fRefPlane
 

Detailed Description

Definition at line 34 of file GeaneTrackRep.h.

Constructor & Destructor Documentation

◆ GeaneTrackRep() [1/3]

GeaneTrackRep::GeaneTrackRep ( )

Referenced by clone(), and prototype().

◆ GeaneTrackRep() [2/3]

GeaneTrackRep::GeaneTrackRep ( FairGeanePro *  geane,
const GFDetPlane plane,
const TVector3 &  mom,
const TVector3 &  poserr,
const TVector3 &  momerr,
double  q,
int  PDGCode 
)

◆ GeaneTrackRep() [3/3]

GeaneTrackRep::GeaneTrackRep ( FairGeanePro *  geane,
const GFDetPlane plane,
const TVector3 &  mom,
const TVector3 &  poserr,
const TVector3 &  momerr,
int  q,
int  PDGCode 
)

◆ ~GeaneTrackRep()

virtual GeaneTrackRep::~GeaneTrackRep ( )
virtual

Member Function Documentation

◆ clone()

virtual GFAbsTrackRep* GeaneTrackRep::clone ( ) const
inlinevirtual

Implements GFAbsTrackRep.

Definition at line 48 of file GeaneTrackRep.h.

References GeaneTrackRep().

48 { return new GeaneTrackRep(*this); }

◆ extrapolate() [1/2]

virtual double GeaneTrackRep::extrapolate ( const GFDetPlane plane,
TMatrixT< double > &  statePred 
)
virtual

returns the tracklength spanned in this extrapolation

There is a default implementation in GFAbsTrackRep.cxx which just drops the predicted covaraiance. If your trackrep has a way to extrapolate without giving a correct cov (that would be faster probably), please overwrite it.

Reimplemented from GFAbsTrackRep.

Referenced by prototype().

◆ extrapolate() [2/2]

virtual double GeaneTrackRep::extrapolate ( const GFDetPlane plane,
TMatrixT< double > &  statePred,
TMatrixT< double > &  covPred 
)
virtual

Extrapolates the track to the given detectorplane.

Results are put into statePred and covPred This method does NOT alter the state of the object!

Implements GFAbsTrackRep.

◆ extrapolateToLine()

void GeaneTrackRep::extrapolateToLine ( const TVector3 &  point1,
const TVector3 &  point2,
TVector3 &  poca,
TVector3 &  normVec,
TVector3 &  poca_onwire 
)
virtual

This method extrapolates to the point of closest approach to a line.

This method extrapolates to the POCA to a line, i.e. a wire. There is a default implementation just like for the extrapolateToPoca for trackReps which do not need this feature, which will abort the execution if it is ever called.

Reimplemented from GFAbsTrackRep.

Referenced by prototype().

◆ extrapolateToPoint()

void GeaneTrackRep::extrapolateToPoint ( const TVector3 &  point,
TVector3 &  poca,
TVector3 &  normVec 
)
virtual

This method is to extrapolate the track to point of closest approach to a point in space.

There is an empty implementation of this method in GFAbsTrackRep.cxx, which will just abort with an error message. One can overwrite this method if one wishes to implement a track representation, which should have this feature. An example of an experiment in which you would not need this feature would be track fitting (not so much vertexing) in an experiment with only planar trackers like silicons or planar wire chambers and such. An example where you would need it, would be a TPC where you have to fit the track to space points, or other drift chambers with complicated hit topology.

Reimplemented from GFAbsTrackRep.

Referenced by prototype().

◆ getCharge()

virtual double GeaneTrackRep::getCharge ( ) const
inlinevirtual

Implements GFAbsTrackRep.

Definition at line 78 of file GeaneTrackRep.h.

References GFAbsTrackRep::fState.

78 { return fState[0][0] > 0 ? 1. : -1.; }
TMatrixT< double > fState
The vector of track parameters.
Definition: GFAbsTrackRep.h:88

◆ getMom()

virtual TVector3 GeaneTrackRep::getMom ( const GFDetPlane )
virtual

Implements GFAbsTrackRep.

◆ getPDG()

int GeaneTrackRep::getPDG ( )
inline

Definition at line 81 of file GeaneTrackRep.h.

81 { return _pdg; };

◆ getPocaOnLine()

TVector3 GeaneTrackRep::getPocaOnLine ( const TVector3 &  p1,
const TVector3 &  p2,
bool  back = false 
)

Referenced by prototype().

◆ getPos()

virtual TVector3 GeaneTrackRep::getPos ( const GFDetPlane )
virtual

Implements GFAbsTrackRep.

◆ getPosMom()

virtual void GeaneTrackRep::getPosMom ( const GFDetPlane ,
TVector3 &  pos,
TVector3 &  mom 
)
virtual

Implements GFAbsTrackRep.

Referenced by prototype().

◆ getPosMomCov()

virtual void GeaneTrackRep::getPosMomCov ( const GFDetPlane pl,
TVector3 &  pos,
TVector3 &  mom,
TMatrixT< double > &  cov 
)
virtual

method which gets position, momentum and 6x6 covariance matrix

default implementation in cxx file, if a ConcreteTrackRep can not implement this functionality

Reimplemented from GFAbsTrackRep.

Referenced by prototype().

◆ getPropagator()

FairGeanePro* GeaneTrackRep::getPropagator ( )
inline

Definition at line 80 of file GeaneTrackRep.h.

80 { return _geane; }

◆ getPropDir()

int GeaneTrackRep::getPropDir ( )
inline

Definition at line 79 of file GeaneTrackRep.h.

79 { return _backw; }

◆ getSPU()

double GeaneTrackRep::getSPU ( )
inline

Definition at line 82 of file GeaneTrackRep.h.

82 { return _spu; }

◆ prototype()

virtual GFAbsTrackRep* GeaneTrackRep::prototype ( ) const
inlinevirtual

◆ setPropagator()

void GeaneTrackRep::setPropagator ( FairGeanePro *  g)
inline

Definition at line 84 of file GeaneTrackRep.h.

84 { _geane = g; }

◆ setPropDir()

void GeaneTrackRep::setPropDir ( int  d)
inline

Definition at line 85 of file GeaneTrackRep.h.

85 { _backw = d; }

◆ switchDirection()

void GeaneTrackRep::switchDirection ( )
inlinevirtual

Implements GFAbsTrackRep.

Definition at line 86 of file GeaneTrackRep.h.

86 { _backw = -_backw; }

Friends And Related Function Documentation

◆ operator<<

std::ostream& operator<< ( std::ostream &  s,
const GeaneTrackRep me 
)
friend

Referenced by prototype().


The documentation for this class was generated from the following file: