4 #ifndef __DMAGNETICFIELDSTEPPER_H__
5 #define __DMAGNETICFIELDSTEPPER_H__
10 #include "JANA/jerror.h"
48 inline double GetRo(
void){
return fabs(
Ro);}
72 #endif // __DMAGNETICFIELDSTEPPER_H__
void GetBField(DVector3 &B)
bool SwimToPlane(DVector3 &pos, DVector3 &mom, const DVector3 &origin, const DVector3 &norm, double *pathlen=NULL)
bool DistToRadius(DVector3 &pos, double R)
double q
electric charge in units of e
DVector3 mom
current location of particle
bool SwimToRadius(DVector3 &pos, DVector3 &mom, double R, double *pathlen=NULL)
void GetPosMom(DVector3 &pos, DVector3 &mom)
DMagneticFieldStepper class.
const DMagneticFieldMap * bfield
pointer to magnetic field map
jerror_t SetStartingParams(double q, const DVector3 *x, const DVector3 *p)
DVector3 start_pos
starting position of track
double last_stepsize
stepsize (cm) used for last step
void CalcDirs(double *Bvals=NULL)
double GetStepSize(void) const
void GetMomentum(DVector3 &mom)
DMagneticFieldStepper(const DMagneticFieldMap *map, double q=1.0)
bool SwimToPOCAtoBeamLine(double q, DVector3 &pos, DVector3 &mom)
double FastStep(double stepsize=0.0)
DVector3 pos
current position of particle
void GetPosition(DVector3 &pos)
double stepsize
maximum distance(cm) to move particle when Step() is called
bool DistToPlane(DVector3 &pos, const DVector3 &origin, const DVector3 &norm)
DVector3 start_mom
starting momentum of track
double Step(DVector3 *newpos=NULL, DVector3 *B=NULL, double stepsize=0.0)
jerror_t SetMagneticFieldMap(const DMagneticFieldMap *map)
jerror_t SetStepSize(double step)
void GetDirs(DVector3 &xdir, DVector3 &ydir, DVector3 &zdir)