ROOT logo
AliRoot » PWGCF » FEMTOSCOPY » ALIFEMTO » AliFmHelix

class AliFmHelix


AliFmHelix: a helper helix class
Includes all the operations and specifications of the helix. Can be
used to determine path lengths, distance of closest approach etc.


Function Members (Methods)

public:
AliFmHelix(const AliFmHelix&)
AliFmHelix(double c, double dip, double phase, const AliFmThreeVector<double>& o, int h = -1)
virtual~AliFmHelix()
AliFmThreeVector<double>At(double s) const
intBad(double WorldSize = 1.e+5) const
doubleCurvature() const
doubleDipAngle() const
doubleDistance(const AliFmThreeVector<double>& p, bool scanPeriods = true) const
intH() const
virtual voidMoveOrigin(double s)
AliFmHelix&operator=(const AliFmHelix&)
const AliFmThreeVector<double>&Origin() const
pair<double,double>PathLength(double r) const
doublePathLength(const AliFmThreeVector<double>& p, bool scanPeriods = true) const
doublePathLength(const AliFmThreeVector<double>& r, const AliFmThreeVector<double>& n) const
doublePathLength(double x, double y) const
pair<double,double>PathLength(double r, double x, double y, bool scanPeriods = true)
pair<double,double>PathLengths(const AliFmHelix& h, bool scanPeriods = true) const
doublePeriod() const
doublePhase() const
voidSetParameters(double c, double dip, double phase, const AliFmThreeVector<double>& o, int h)
boolValid(double world = 1.e+5) const
doubleX(double s) const
doubleXCenter() const
doubleY(double s) const
doubleYCenter() const
doubleZ(double s) const
protected:
AliFmHelix()
doubleFudgePathLength(const AliFmThreeVector<double>& v) const
voidSetCurvature(double d)
voidSetDipAngle(double d)
voidSetPhase(double d)

Data Members

public:
static const doublefgkNoSolutioncoinstant indicating lack of solution
protected:
doublefCosDipAnglecosine of the dip angle
doublefCosPhasecosine of the phase
doublefCurvaturecurvature
doublefDipAngleHelix dip angle
intfH-sign(q*B);
AliFmThreeVector<double>fOriginHelix origin
doublefPhasephase
doublefSinDipAnglesine of the dip angle
doublefSinPhasesine of the phase
boolfSingularitytrue for straight line case (B=0)

Class Charts

Inheritance Chart:
AliFmHelix
AliFmPhysicalHelix

Function documentation

AliFmHelix()
Default constructor
noop
AliFmHelix(double c, double dip, double phase, const AliFmThreeVector<double>& o, int h = -1)
 Constructor with helix parameters
~AliFmHelix()
 Default destructor
noop
void SetParameters(double c, double dip, double phase, const AliFmThreeVector<double>& o, int h)
  The order in which the parameters are set is important
  since setCurvature might have to adjust the others.

void SetCurvature(double d)
 Set helix curvature
void SetPhase(double d)
 Set helix phase
void SetDipAngle(double d)
 Set helix dip angle
double XCenter() const
 Set helix center in X
double YCenter() const
 Set helix center in Y
double FudgePathLength(const AliFmThreeVector<double>& v) const
 Path length
double Distance(const AliFmThreeVector<double>& p, bool scanPeriods = true) const
 calculate distance between origin an p along the helix
double PathLength(const AliFmThreeVector<double>& p, bool scanPeriods = true) const
  Returns the path length at the distance of closest
  approach between the helix and point p.
  For the case of B=0 (straight line) the path length
  can be calculated analytically. For B>0 there is
  unfortunately no easy solution to the problem.
  Here we use the Newton method to find the root of the
  referring equation. The 'fudgePathLength' serves
  as a starting value.

double Period() const
 period
pair<double, double> PathLength(double r) const
 The math is taken from Maple with C(expr,optimized) and
 some hand-editing. It is not very nice but efficient.
 'first' is the smallest of the two solutions (may be negative)
 'second' is the other.

pair<double, double> PathLength(double r, double x, double y, bool scanPeriods = true)
 path length
double PathLength(const AliFmThreeVector<double>& r, const AliFmThreeVector<double>& n) const
 Vector 'r' defines the position of the center and
 vector 'n' the normal vector of the plane.
 For a straight line there is a simple analytical
 solution. For curvatures > 0 the root is determined
 by Newton method. In case no valid s can be found
 the max. largest value for s is returned.

PathLengths(const AliFmHelix& h, bool scanPeriods = true) const
	Cannot handle case where one is a helix
  and the other one is a straight line.

void MoveOrigin(double s)
 Move the helix origin
int H() const
     Inline functions

{return fH;}
double DipAngle() const
{return fDipAngle;}
double Curvature() const
{return fCurvature;}
double Phase() const
{return fPhase;}
double X(double s) const
double Y(double s) const
double Z(double s) const
const AliFmThreeVector<double>& Origin() const
{return fOrigin;}
AliFmThreeVector<double> At(double s) const
double PathLength(double x, double y) const
int Bad(double WorldSize = 1.e+5) const
AliFmHelix(double c, double dip, double phase, const AliFmThreeVector<double>& o, int h = -1)
 curvature, dip angle, phase, origin, h
bool Valid(double world = 1.e+5) const
 checks for valid parametrization
{return !Bad(world);}