LArSoft  v07_13_02
Liquid Argon Software toolkit - http://larsoft.org/
recob::Trajectory Class Reference

A trajectory in space reconstructed from hits. More...

#include "Trajectory.h"

Inheritance diagram for recob::Trajectory:
recob::TrackTrajectory

Public Types

enum  Ends_t { kStart, kVertex = kStart, kEnd, NEnds }
 Mnemonics for the access to begin and end of trajectory. More...
 
using Coord_t = tracking::Coord_t
 Type used for coordinates and values in general. More...
 
using Point_t = tracking::Point_t
 Type for representation of position in physical 3D space. More...
 
using Vector_t = tracking::Vector_t
 Type for representation of momenta in 3D space. More...
 
using Positions_t = tracking::Positions_t
 Type of trajectory point list. More...
 
using Momenta_t = tracking::Momenta_t
 Type of momentum list. More...
 
using TrajectoryPoint_t = tracking::TrajectoryPoint_t
 A point in the trajectory, with position and momentum. More...
 
using Rotation_t = tracking::Rotation_t
 Type for representation of space rotations. More...
 

Public Member Functions

 Trajectory ()=default
 Default constructor; do not use it! it's needed by ROOT I/O. More...
 
 Trajectory (Positions_t &&positions, Momenta_t &&momenta, bool hasMomenta)
 Constructor: specifies all the data for the trajectory. More...
 
 Trajectory (Positions_t const &positions, Momenta_t const &momenta, bool hasMomenta)
 Constructor: copies positions and momenta. More...
 
template<typename Stream >
void Dump (Stream &&out, unsigned int verbosity, std::string indent, std::string indentFirst) const
 Prints trajectory content into a stream. More...
 
template<typename Stream >
void Dump (Stream &&out, unsigned int verbosity=1, std::string indent={}) const
 Prints trajectory content into a stream. More...
 
template<typename Stream >
void LowLevelDump (Stream &&out, std::string indent, std::string indentFirst) const
 Prints low-level trajectory content into a stream. More...
 
Access to trajectory information
size_t NumberTrajectoryPoints () const
 Returns the number of stored trajectory points. More...
 
size_t NPoints () const
 Returns the number of stored trajectory points. More...
 
size_t FirstPoint () const
 Returns the index of the first point in the trajectory (yep, it's 0). More...
 
size_t LastPoint () const
 Returns the index of the last point in the trajectory. More...
 
bool HasPoint (size_t i) const
 Returns whether the specified trajectory point is available. More...
 
const Positions_tPositions () const
 Returns reference to stored vector of positions. More...
 
const Momenta_tMomenta () const
 Returns reference to stored vector of momenta. More...
 
TrajectoryPoint_t TrajectoryPoint (size_t i) const
 Returns position and momentum at the specified trajectory point. More...
 
Point_t const & Vertex () const
 Returns the position of the first point of the trajectory [cm]. More...
 
Point_t const & Start () const
 Returns the position of the first point of the trajectory [cm]. More...
 
Point_t const & End () const
 Returns the position of the last point of the trajectory [cm]. More...
 
Point_t const & LocationAtPoint (size_t i) const
 Returns the position at the specified trajectory point. More...
 
template<typename T >
std::pair< T, T > Extent () const
 Fills the first and last point in the trajectory. More...
 
std::pair< Point_t, Point_tExtent () const
 Returns a copy of the first and last point in the trajectory. More...
 
double Length (size_t startAt=0) const
 Returns the approximate length of the trajectory. More...
 
Access to direction and momentum information
Vector_t VertexDirection () const
 Returns the direction of the trajectory at the first point. More...
 
Vector_t StartDirection () const
 Returns the direction of the trajectory at the first point. More...
 
Vector_t EndDirection () const
 Returns the direction of the trajectory at the last point. More...
 
double Theta (size_t p=0) const
 Trajectory angle at point, with respect to positive z direction. More...
 
double Phi (size_t p=0) const
 Azimuthal angle at a point on the trajectory, with respect to z. More...
 
double ZenithAngle (size_t p=0) const
 "Zenith" angle of trajectory, with respect to the vertical axis. More...
 
double AzimuthAngle (size_t p=0) const
 "Azimuth" angle of trajectory, with respect to the sky. More...
 
Vector_t const & VertexMomentumVector () const
 Returns the momentum of the trajectory at the first point [GeV/c]. More...
 
Vector_t const & StartMomentumVector () const
 Returns the momentum of the trajectory at the first point [GeV/c]. More...
 
Vector_t const & EndMomentumVector () const
 Returns the momentum of the trajectory at the last point [GeV/c]. More...
 
double VertexMomentum () const
 Computes and returns the modulus of momentum at the first point [GeV/c]. More...
 
double StartMomentum () const
 Computes and returns the modulus of momentum at the first point [GeV/c]. More...
 
double EndMomentum () const
 Computes and returns the modulus of momentum at the last point [GeV/c]. More...
 
Vector_t DirectionAtPoint (size_t i) const
 Computes and returns the direction of the trajectory at a point. More...
 
bool HasMomentum () const
 Returns whether information about the momentum is available. More...
 
double MomentumAtPoint (size_t i) const
 Computes and returns the modulus of the momentum at a point. More...
 
Vector_t const & MomentumVectorAtPoint (size_t i) const
 Returns the momentum vector at a point. More...
 
template<typename T >
std::pair< T, T > Direction () const
 Fills the starting and ending direction of the trajectory. More...
 
std::pair< Vector_t, Vector_tDirection () const
 Returns the trajectory directions at first and last point. More...
 
Rotation_t GlobalToLocalRotationAtPoint (size_t p) const
 Returns a rotation matrix that brings trajectory direction along z. More...
 
Rotation_t LocalToGlobalRotationAtPoint (size_t p) const
 Returns a rotation matrix bringing relative directions to global. More...
 
Templated version of homonymous functions to access to position, direction, and momentum information.
template<typename T >
Start () const
 Start position. Use e.g. as: More...
 
template<typename T >
Vertex () const
 Start position. Use e.g. as: More...
 
template<typename T >
End () const
 End position. Use e.g. as: More...
 
template<typename T >
LocationAtPoint (unsigned int p) const
 Position at point p. Use e.g. as: More...
 
template<typename T >
StartDirection () const
 Start direction. Use e.g. as: More...
 
template<typename T >
VertexDirection () const
 Start direction. Use e.g. as: More...
 
template<typename T >
EndDirection () const
 End direction. Use e.g. as: More...
 
template<typename T >
DirectionAtPoint (unsigned int p) const
 Direction at point p. Use e.g. as: More...
 
template<typename T >
StartMomentumVector () const
 Momentum vector at start point. Use e.g. as: More...
 
template<typename T >
VertexMomentumVector () const
 Momentum vector at start point. Use e.g. as: More...
 
template<typename T >
EndMomentumVector () const
 Momentum vector at end point. Use e.g. as: More...
 
template<typename T >
MomentumVectorAtPoint (unsigned int p) const
 Momentum vector at point p. Use e.g. as: More...
 
template<typename T >
GlobalToLocalRotationAtPoint (unsigned int p) const
 Returns a rotation matrix that brings trajectory direction along z. Use e.g. as: More...
 
template<typename T >
LocalToGlobalRotationAtPoint (unsigned int p) const
 Returns a rotation matrix bringing relative directions to global. Use e.g. as: More...
 

Static Public Attributes

static constexpr unsigned int MaxDumpVerbosity = 6
 Largest verbosity level supported by Dump(). More...
 

Private Attributes

Positions_t fPositions
 List of points the trajectory goes through. More...
 
Momenta_t fMomenta
 Momentum of each of the points in trajectory. More...
 
bool fHasMomentum = true
 Whether we have momentum modulus information. More...
 

Detailed Description

A trajectory in space reconstructed from hits.


See also
recob::Track, recob::trackutil::makeTrajectory()

The trajectory class contains a trajectory in 6D space representing the path walked by a particle. A trajectory point is made of a 3D position component (measured in centimeters) and a momentum component (measured in GeV/c); for a discussion on the object type for coordinates see: recob::tracking::Coord_t.

The object contains information about the trajectory, and no uncertainty, as that is considered a fit result (see recob::Track). By convention the first point is considered "start" (or "vertex") and the last point "end", although this assignment can be arbitrary and should not be relied upon for physics decisions.

The momentum content is in part optional: the trajectory creating algorithm may decide not to provide information about the modulus of the momentum. In that case, Trajectory::HasMomentum() will return false and every attempt to access the momentum vector will yield only the trajectory direction.

Invariants

  • there must be at least two trajectory points;
  • there must be one momentum per position; recob::trackutil::makeTrajectory() can make up a simple momentum vector from the trajectory, for algorithms reconstructing the trajectory which do not estimate momenta; Trajectory::HasMomentum() reports whether momentum modulus information is available;
  • a list of hits associated with the trajectory is considered a mandatory part of the trajectory information; see recob::TrajectoryCollectionMaker.

Definition at line 73 of file Trajectory.h.

Member Typedef Documentation

Type used for coordinates and values in general.

Definition at line 76 of file Trajectory.h.

Type of momentum list.

Definition at line 88 of file Trajectory.h.

Type for representation of position in physical 3D space.

Definition at line 79 of file Trajectory.h.

Type of trajectory point list.

Definition at line 85 of file Trajectory.h.

Type for representation of space rotations.

Definition at line 103 of file Trajectory.h.

A point in the trajectory, with position and momentum.

Definition at line 100 of file Trajectory.h.

Type for representation of momenta in 3D space.

Definition at line 82 of file Trajectory.h.

Member Enumeration Documentation

Mnemonics for the access to begin and end of trajectory.

Enumerator
kStart 

Index representing the start of the trajectory.

kVertex 

Index representing the start of the trajectory.

kEnd 

Index representing the end of the trajectory.

NEnds 

Number of ends.

Definition at line 91 of file Trajectory.h.

91  {
92  kStart,
93  kVertex = kStart,
94  kEnd,
95  NEnds
96  }; // enum Ends_t
Index representing the end of the trajectory.
Definition: Trajectory.h:94
Index representing the start of the trajectory.
Definition: Trajectory.h:92
Index representing the start of the trajectory.
Definition: Trajectory.h:93
Number of ends.
Definition: Trajectory.h:95

Constructor & Destructor Documentation

recob::Trajectory::Trajectory ( )
default

Default constructor; do not use it! it's needed by ROOT I/O.

recob::Trajectory::Trajectory ( Positions_t &&  positions,
Momenta_t &&  momenta,
bool  hasMomenta 
)

Constructor: specifies all the data for the trajectory.

Parameters
positions(moved) trajectory as a sorted list of points
momenta(moved) momentum along the trajectory, one per point
hasMomentawhether the information on momentum modulus is provided
Exceptions
std::runtime_errorif the invariants are violated
See also
recob::trackutil::makeTrajectory()

The most convenient way to create a recob::Trajectory is to use recob::trackutil::makeTrajectory().

Requirements

  • one momentum is required for each trajectory point
  • at least two points must be provided

Definition at line 25 of file Trajectory.cxx.

References util::flags::to_string().

26  : fPositions(std::move(positions))
27  , fMomenta(std::move(momenta))
28  , fHasMomentum(hasMomenta)
29 {
30  // invariant check
31  if (fPositions.size() != fMomenta.size()) {
32  throw std::runtime_error("recob::Trajectory constructed with "
33  + std::to_string(fPositions.size()) + " positions and "
34  + std::to_string(fMomenta.size())
35  + " momenta! it requires the same number for both."
36  );
37  }
38  if (fPositions.size() < 2) {
39  throw std::runtime_error("recob::Trajectory constructed with "
40  + std::to_string(fPositions.size())
41  + " trajectory points! it requires at least 2."
42  );
43  }
44 } // recob::Trajectory::Trajectory()
Momenta_t fMomenta
Momentum of each of the points in trajectory.
Definition: Trajectory.h:676
Positions_t fPositions
List of points the trajectory goes through.
Definition: Trajectory.h:675
bool fHasMomentum
Whether we have momentum modulus information.
Definition: Trajectory.h:678
std::string to_string(Flag_t< Storage > const flag)
Convert a flag into a stream (shows its index).
Definition: BitMask.h:187
recob::Trajectory::Trajectory ( Positions_t const &  positions,
Momenta_t const &  momenta,
bool  hasMomenta 
)
inline

Constructor: copies positions and momenta.

Parameters
positionstrajectory as a sorted list of points
momentamomentum along the trajectory, one per point
hasMomentawhether the information on momentum modulus is provided
Exceptions
std::runtime_errorif the invariants are violated

Definition at line 142 of file Trajectory.h.

147  : Trajectory(Positions_t(positions), Momenta_t(momenta), hasMomenta)
148  {}
Trajectory()=default
Default constructor; do not use it! it&#39;s needed by ROOT I/O.
tracking::Positions_t Positions_t
Type of trajectory point list.
Definition: Trajectory.h:85
tracking::Momenta_t Momenta_t
Type of momentum list.
Definition: Trajectory.h:88

Member Function Documentation

double recob::Trajectory::AzimuthAngle ( size_t  p = 0) const

"Azimuth" angle of trajectory, with respect to the sky.

Parameters
pthe point index to extract the angle from (default: start)
Returns
the azimuth angle, in $ [-\pi,\pi[ $ [radians]
See also
ZenithAngle()

The angle is defined on the plane orthogonal to the y direction. It describes the angle of the trajectory at the specified point. The angle is measured starting from the positive z direction, counterclockwise. Therefore, a trajectory start lying on the demiplane of y axis and positive z axis returns 0 radians, while one lying on the demiplane of y axis and positive x axis returns $ +\pi/2 $ radians.

If the point number is invalid, the behaviour is undefined.

Definition at line 97 of file Trajectory.cxx.

References DirectionAtPoint().

Referenced by recob::TrackTrajectory::AzimuthAngle(), and Phi().

97  {
98  //
99  // std::atan2(y, x) returns the angle of a point (x,y) respect to x axis.
100  // In our case, the definition of the angle (0 for z axis, pi/2 for x axis)
101  // translates atan2's y into our x, and x into z.
102  //
103  decltype(auto) startDir = DirectionAtPoint(p);
104  return std::atan2(startDir.X(), startDir.Z());
105 } // recob::Trajectory::AzimuthAngle()
STL namespace.
Vector_t DirectionAtPoint(size_t i) const
Computes and returns the direction of the trajectory at a point.
Definition: Trajectory.cxx:118
Float_t Z
Definition: plot.C:39
Float_t X
Definition: plot.C:39
template<typename T >
std::pair<T,T> recob::Trajectory::Direction ( ) const
inline

Fills the starting and ending direction of the trajectory.

Parameters
start(output) direction at the beginning of the trajectory
end(output) direction at the end of the trajectory

The two arguments are expected to point each one to an area with room for at least three double numbers. The two filled vectors have norm 1.

The labelling of start and end is consistent within the trajectory but is not guaranteed to be physically correct.

Definition at line 478 of file Trajectory.h.

478 { return { VertexDirection<T>(),EndDirection<T>() }; }
std::pair<Vector_t, Vector_t> recob::Trajectory::Direction ( ) const
inline

Returns the trajectory directions at first and last point.

Returns
a pair with the first and last direction

The two returned vectors have norm 1. The labelling of start and end is consistent within the trajectory but is not guaranteed to be physically correct.

Example:

recob::Trajectory::Vector_t startDir, endDir;
std::tie(startDir, endDir) = traj.Direction(); // assign start and end

Definition at line 498 of file Trajectory.h.

References EndDirection(), GlobalToLocalRotationAtPoint(), LocalToGlobalRotationAtPoint(), and StartDirection().

499  { return { StartDirection(), EndDirection() }; }
Vector_t EndDirection() const
Returns the direction of the trajectory at the last point.
Definition: Trajectory.h:309
Vector_t StartDirection() const
Returns the direction of the trajectory at the first point.
Definition: Trajectory.h:305
recob::Trajectory::Vector_t recob::Trajectory::DirectionAtPoint ( size_t  i) const

Computes and returns the direction of the trajectory at a point.

Parameters
iindex of the point in the trajectory
Returns
the direction at that point

The direction is computed as unit vector parallel to the momentum at that trajectory point. If the index is not contained in the trajectory, the result is undefined.

Definition at line 118 of file Trajectory.cxx.

References GlobalToLocalRotationAtPoint(), HasMomentum(), and MomentumVectorAtPoint().

Referenced by AzimuthAngle(), EndDirection(), EndMomentum(), recob::TrackTrajectory::EndMomentum(), trkf::BezierTrack::FillSeedVector(), GlobalToLocalRotationAtPoint(), LocalToGlobalRotationAtPoint(), trkf::KalmanFilterFinalTrackFitter::restoreInputPoints(), StartDirection(), and ZenithAngle().

119 {
120 
121  auto const& mom = MomentumVectorAtPoint(i);
122  return HasMomentum()? (mom / mom.R()): mom;
123 
124 } // recob::Trajectory::DirectionAtPoint()
Vector_t const & MomentumVectorAtPoint(size_t i) const
Returns the momentum vector at a point.
Definition: Trajectory.h:463
bool HasMomentum() const
Returns whether information about the momentum is available.
Definition: Trajectory.h:431
template<typename T >
T recob::Trajectory::DirectionAtPoint ( unsigned int  p) const
inline

Direction at point p. Use e.g. as:

TVector3 dir = traj.DirectionAtPoint<TVector3>(p);

.

Definition at line 570 of file Trajectory.h.

References dir, and DirectionAtPoint().

Referenced by DirectionAtPoint().

570 { auto dir = DirectionAtPoint(p); return T(dir.X(),dir.Y(),dir.Z()); }
Vector_t DirectionAtPoint(size_t i) const
Computes and returns the direction of the trajectory at a point.
Definition: Trajectory.cxx:118
TDirectory * dir
Definition: macro.C:5
template<typename Stream >
void recob::Trajectory::Dump ( Stream &&  out,
unsigned int  verbosity,
std::string  indent,
std::string  indentFirst 
) const

Prints trajectory content into a stream.

Template Parameters
Streamtype of the output stream
Parameters
outstream to output the information into
verbosityverbosity level (default: 1)
indentindentation string (default: none)
indentFirstindentation for first output line (default: as indent)

The amount of information dumped to screen is regulated by the Indentation string is prepended to each line, and the first line has its own special indentation string (indentFirst).

The output can be multi-line, it ends with no end-of-line and it does not inserts an end-of-line at its beginning (unless that is explicitly inside indentFirst). The lowest verbosity is guaranteed to be on a single line.

Information printed out (verbosity argument)

  • level 0: start position, direction, momentum modulus and number of points
  • level 1: also end position, direction and momentum modulus
  • level 2: also trajectory length
  • level 3: also angles at start
  • level 4: also 9 intermediate trajectory points
  • level 5: also 10 more intermediate trajectory points (19 total)
  • level 6: all trajectory points

Referenced by lar::example::CheatTrack::dump(), Dump(), and LocalToGlobalRotationAtPoint().

template<typename Stream >
void recob::Trajectory::Dump ( Stream &&  out,
unsigned int  verbosity = 1,
std::string  indent = {} 
) const
inline

Prints trajectory content into a stream.

Template Parameters
Streamtype of the output stream
Parameters
outstream to output the information into
verbosityverbosity level (default: 1)
indentindentation string (default: none)
See also
Dump(Stream&&, unsigned int, std::string, std::string)

Implementation detail for Dump(Stream&&, unsigned int, std::string).

Definition at line 651 of file Trajectory.h.

References Dump(), and LowLevelDump().

651  {})
652  const
653  { Dump(std::forward<Stream>(out), verbosity, indent, indent); }
std::string indent(std::size_t const i)
void Dump(Stream &&out, unsigned int verbosity, std::string indent, std::string indentFirst) const
Prints trajectory content into a stream.
Point_t const& recob::Trajectory::End ( ) const
inline

Returns the position of the last point of the trajectory [cm].

Definition at line 232 of file Trajectory.h.

References LastPoint(), and LocationAtPoint().

Referenced by Extent(), trkf::BezierTrack::GetTrackPoint(), and Length().

233  { return LocationAtPoint(LastPoint()); }
size_t LastPoint() const
Returns the index of the last point in the trajectory.
Definition: Trajectory.h:181
Point_t const & LocationAtPoint(size_t i) const
Returns the position at the specified trajectory point.
Definition: Trajectory.h:242
template<typename T >
T recob::Trajectory::End ( ) const
inline

End position. Use e.g. as:

TVector3 end = traj.End<TVector3>();

.

Definition at line 555 of file Trajectory.h.

References End().

Referenced by End().

555 { auto& loc = End(); return T(loc.X(),loc.Y(),loc.Z()); }
Point_t const & End() const
Returns the position of the last point of the trajectory [cm].
Definition: Trajectory.h:232
Vector_t recob::Trajectory::EndDirection ( ) const
inline

Returns the direction of the trajectory at the last point.

Definition at line 309 of file Trajectory.h.

References DirectionAtPoint(), and LastPoint().

Referenced by Direction().

310  { return DirectionAtPoint(LastPoint()); }
Vector_t DirectionAtPoint(size_t i) const
Computes and returns the direction of the trajectory at a point.
Definition: Trajectory.cxx:118
size_t LastPoint() const
Returns the index of the last point in the trajectory.
Definition: Trajectory.h:181
template<typename T >
T recob::Trajectory::EndDirection ( ) const
inline

End direction. Use e.g. as:

TVector3 enddir = traj.EndDirection<TVector3>();

.

Definition at line 567 of file Trajectory.h.

References dir, and EndDirection().

Referenced by EndDirection().

567 { auto dir = EndDirection(); return T(dir.X(),dir.Y(),dir.Z()); }
Vector_t EndDirection() const
Returns the direction of the trajectory at the last point.
Definition: Trajectory.h:309
TDirectory * dir
Definition: macro.C:5
double recob::Trajectory::EndMomentum ( ) const
inline

Computes and returns the modulus of momentum at the last point [GeV/c].

Definition at line 407 of file Trajectory.h.

References DirectionAtPoint(), and EndMomentumVector().

408  { return EndMomentumVector().R(); }
Vector_t const & EndMomentumVector() const
Returns the momentum of the trajectory at the last point [GeV/c].
Definition: Trajectory.h:394
Vector_t const& recob::Trajectory::EndMomentumVector ( ) const
inline

Returns the momentum of the trajectory at the last point [GeV/c].

Definition at line 394 of file Trajectory.h.

References LastPoint(), and MomentumVectorAtPoint().

Referenced by EndMomentum().

395  { return MomentumVectorAtPoint(LastPoint()); }
size_t LastPoint() const
Returns the index of the last point in the trajectory.
Definition: Trajectory.h:181
Vector_t const & MomentumVectorAtPoint(size_t i) const
Returns the momentum vector at a point.
Definition: Trajectory.h:463
template<typename T >
T recob::Trajectory::EndMomentumVector ( ) const
inline

Momentum vector at end point. Use e.g. as:

TVector3 endmom = traj.EndMomentumVector<TVector3>();

.

Definition at line 579 of file Trajectory.h.

References EndMomentumVector().

Referenced by EndMomentumVector().

579 { auto mom = EndMomentumVector(); return T(mom.X(),mom.Y(),mom.Z()); }
Vector_t const & EndMomentumVector() const
Returns the momentum of the trajectory at the last point [GeV/c].
Definition: Trajectory.h:394
template<typename T >
std::pair<T,T> recob::Trajectory::Extent ( ) const
inline

Fills the first and last point in the trajectory.

Parameters
start(output) position of the beginning of the trajectory
end(output) position of the end of the trajectory

The labelling of start and end is consistent within the trajectory but is not guaranteed to be physically correct.

Definition at line 254 of file Trajectory.h.

254 { return { Vertex<T>(),End<T>() }; }
std::pair<Point_t, Point_t> recob::Trajectory::Extent ( ) const
inline

Returns a copy of the first and last point in the trajectory.

Returns
a pair: the first and last point in the trajectory

The labelling of start and end is consistent within the trajectory but is not guaranteed to be physically correct.

Example:

std::tie(start, end) = traj.Extent(); // assign both start and end

Definition at line 272 of file Trajectory.h.

References End(), Length(), and Start().

273  { return { Start(), End() }; }
Point_t const & End() const
Returns the position of the last point of the trajectory [cm].
Definition: Trajectory.h:232
Point_t const & Start() const
Returns the position of the first point of the trajectory [cm].
Definition: Trajectory.h:228
size_t recob::Trajectory::FirstPoint ( ) const
inline

Returns the index of the first point in the trajectory (yep, it's 0).

Definition at line 177 of file Trajectory.h.

Referenced by recob::Track::FirstPoint(), Start(), StartDirection(), StartMomentumVector(), and recob::TrackTrajectory::Trajectory().

178  { return 0U; }
recob::Trajectory::Rotation_t recob::Trajectory::GlobalToLocalRotationAtPoint ( size_t  p) const

Returns a rotation matrix that brings trajectory direction along z.

Parameters
pindex of the trajectory point where to apply the rotation
Returns
a rotation matrix suitable to point the trajectory along z

The returned rotation matrix, applied to the direction vector of the trajectory at point p, will make that direction point toward the positive z axis direction, in a sort of "first person view" of the trajectory at that point. If p does not denote a valid trajectory point, the result is undefined.

The return value can be used on a Vector_t to rotate it. For example:

auto rot = traj.GlobalToLocalRotationAtPoint(0);
auto local = rot * traj.DirectionAtPoint(0);

local will be a Vector_t object (like the direction at the right side of the product) that points to (0, 0, 1).

While the transformation that yields the rotation matrix is continuous, the direction of the new "local" x and y axes is not defined.

Definition at line 129 of file Trajectory.cxx.

References DirectionAtPoint(), recob::tracking::Plane::Global3DToLocal3DRotation(), and LocalToGlobalRotationAtPoint().

Referenced by Direction(), recob::TrackTrajectory::Direction(), DirectionAtPoint(), and GlobalToLocalRotationAtPoint().

130 {
132 } // recob::Trajectory::GlobalToLocalRotationAtPoint()
Rotation_t Global3DToLocal3DRotation() const
Calculate rotation matrices from global (x,y,z) to local (u,v,w) coordinates.
Vector_t DirectionAtPoint(size_t i) const
Computes and returns the direction of the trajectory at a point.
Definition: Trajectory.cxx:118
template<typename T >
T recob::Trajectory::GlobalToLocalRotationAtPoint ( unsigned int  p) const
inline

Returns a rotation matrix that brings trajectory direction along z. Use e.g. as:

TMatrixD rot = traj.GlobalToLocalRotationAtPoint<TMatrixD>(p);

.

Definition at line 585 of file Trajectory.h.

References GlobalToLocalRotationAtPoint().

585  {
586  T rot(3,3);
587  GlobalToLocalRotationAtPoint(p).GetRotationMatrix(rot);
588  return rot;
589  }
Rotation_t GlobalToLocalRotationAtPoint(size_t p) const
Returns a rotation matrix that brings trajectory direction along z.
Definition: Trajectory.cxx:129
bool recob::Trajectory::HasMomentum ( ) const
inline

Returns whether information about the momentum is available.

Returns
whether information about the momentum is available

The trajectory may or may not store valid momentum information. If not, the methods returning momentum information will stick to a modulus 1 GeV/c and the momentum numerically matches the direction.

Definition at line 431 of file Trajectory.h.

References fHasMomentum.

Referenced by recob::Track::DirectionAtPoint(), DirectionAtPoint(), recob::TrackTrajectory::EndMomentum(), and trkmkr::KalmanFilterFitTrackMaker::restoreInputPoints().

432  { return fHasMomentum; }
bool fHasMomentum
Whether we have momentum modulus information.
Definition: Trajectory.h:678
bool recob::Trajectory::HasPoint ( size_t  i) const
inline

Returns whether the specified trajectory point is available.

Parameters
iindex of the trajectory point
Returns
whether the specified trajectory point is available.

Definition at line 189 of file Trajectory.h.

References NPoints().

Referenced by recob::Track::HasPoint(), recob::TrackTrajectory::HasValidPoint(), and recob::TrackTrajectory::Trajectory().

190  { return i < NPoints(); }
size_t NPoints() const
Returns the number of stored trajectory points.
Definition: Trajectory.h:173
size_t recob::Trajectory::LastPoint ( ) const
inline

Returns the index of the last point in the trajectory.

Definition at line 181 of file Trajectory.h.

References NPoints().

Referenced by End(), EndDirection(), EndMomentumVector(), recob::Track::LastPoint(), recob::TrackTrajectory::LastValidPoint(), Length(), recob::TrackTrajectory::Length(), and recob::TrackTrajectory::Trajectory().

182  { return NPoints() - 1; }
size_t NPoints() const
Returns the number of stored trajectory points.
Definition: Trajectory.h:173
double recob::Trajectory::Length ( size_t  startAt = 0) const

Returns the approximate length of the trajectory.

Parameters
startAt(default: 0, from beginning) point to start from
Returns
the approximate length of the trajectory [cm]

The residual length from the trajectory point startAt to the end of the trajectory is computed and returned. By default, the whole trajectory length is returned. If a non-existing point is specified, 0 is returned.

The length approximation is just the sum of Euclidean distances between all consecutive trajectory points (starting from the one with index startAt).

This operation is slow, and the result should be stored in a variable.

Definition at line 64 of file Trajectory.cxx.

References End(), LastPoint(), LocationAtPoint(), and R.

Referenced by Extent(), and opdet::TrackTimeAssoc::ScanMIPHypotheses().

64  {
65 
66  // sanity check
67  if (startAt >= LastPoint()) return 0.;
68 
69  // just sum the distance between all locations in the trajectory
70  Point_t const* curr = &(LocationAtPoint(startAt));
71  Point_t const* next = curr;
72  Point_t const* last = &(End());
73  Coord_t length = 0.0;
74  while (next++ != last) {
75  length += (*next - *curr).R();
76  curr = next;
77  } // while
78  return length;
79 } // recob::Trajectory::Length()
tracking::Coord_t Coord_t
Type used for coordinates and values in general.
Definition: Trajectory.h:76
Point_t const & End() const
Returns the position of the last point of the trajectory [cm].
Definition: Trajectory.h:232
recob::tracking::Point_t Point_t
size_t LastPoint() const
Returns the index of the last point in the trajectory.
Definition: Trajectory.h:181
Double_t R
Point_t const & LocationAtPoint(size_t i) const
Returns the position at the specified trajectory point.
Definition: Trajectory.h:242
recob::Trajectory::Rotation_t recob::Trajectory::LocalToGlobalRotationAtPoint ( size_t  p) const

Returns a rotation matrix bringing relative directions to global.

Parameters
pindex of the trajectory point where to apply the rotation
Returns
a rotation matrix suitable to convert directions to global

The returned rotation matrix, applied to the unit vector (0, 0, 1) (local z axis direction), will turn it into the trajectory direction at point p. If p does not denote a valid trajectory point, the result is undefined.

While the transformation that yields the rotation matrix is continuous, the conversion of the directions orthogonal to the local z is not defined.

Definition at line 137 of file Trajectory.cxx.

References DirectionAtPoint(), and recob::tracking::Plane::Local3DToGlobal3DRotation().

Referenced by Direction(), recob::TrackTrajectory::Direction(), GlobalToLocalRotationAtPoint(), and LocalToGlobalRotationAtPoint().

138 {
140 } // recob::Trajectory::GlobalToLocalRotationAtPoint()
Vector_t DirectionAtPoint(size_t i) const
Computes and returns the direction of the trajectory at a point.
Definition: Trajectory.cxx:118
Rotation_t Local3DToGlobal3DRotation() const
Calculate rotation matrices from local (u,v,w) to global (x,y,z) coordinates.
template<typename T >
T recob::Trajectory::LocalToGlobalRotationAtPoint ( unsigned int  p) const
inline

Returns a rotation matrix bringing relative directions to global. Use e.g. as:

TMatrixD rot = traj.LocalToGlobalRotationAtPoint<TMatrixD>(p);

.

Definition at line 592 of file Trajectory.h.

References Dump(), art::detail::indent(), and LocalToGlobalRotationAtPoint().

592  {
593  T rot(3,3);
594  LocalToGlobalRotationAtPoint(p).GetRotationMatrix(rot);
595  return rot;
596  }
Rotation_t LocalToGlobalRotationAtPoint(size_t p) const
Returns a rotation matrix bringing relative directions to global.
Definition: Trajectory.cxx:137
Point_t const& recob::Trajectory::LocationAtPoint ( size_t  i) const
inline

Returns the position at the specified trajectory point.

Parameters
iindex of the point in the trajectory
Returns
position at the specified trajectory point [cm]

If the point index is invalid, the result is undefined.

Definition at line 242 of file Trajectory.h.

References fPositions.

Referenced by End(), recob::TrackTrajectory::End(), trkf::BezierTrack::FillSeedVector(), Length(), trkf::KalmanFilterFinalTrackFitter::restoreInputPoints(), Start(), and TrajectoryPoint().

243  { return fPositions[i]; }
Positions_t fPositions
List of points the trajectory goes through.
Definition: Trajectory.h:675
template<typename T >
T recob::Trajectory::LocationAtPoint ( unsigned int  p) const
inline

Position at point p. Use e.g. as:

TVector3 pos = traj.LocationAtPoint<TVector3>(p);

.

Definition at line 558 of file Trajectory.h.

References LocationAtPoint().

Referenced by LocationAtPoint().

558 { auto& loc = LocationAtPoint(p); return T(loc.X(),loc.Y(),loc.Z()); }
Point_t const & LocationAtPoint(size_t i) const
Returns the position at the specified trajectory point.
Definition: Trajectory.h:242
template<typename Stream >
void recob::Trajectory::LowLevelDump ( Stream &&  out,
std::string  indent,
std::string  indentFirst 
) const

Prints low-level trajectory content into a stream.

Template Parameters
Streamtype of the output stream
Parameters
outstream to output the information into
indentindentation string (default: none)
indentFirstindentation for first output line (default: as indent)

Referenced by Dump().

const Momenta_t& recob::Trajectory::Momenta ( ) const
inline

Returns reference to stored vector of momenta.

Returns
reference to stored vector of momenta

Definition at line 202 of file Trajectory.h.

References fMomenta.

202 { return fMomenta; }
Momenta_t fMomenta
Momentum of each of the points in trajectory.
Definition: Trajectory.h:676
double recob::Trajectory::MomentumAtPoint ( size_t  i) const
inline

Computes and returns the modulus of the momentum at a point.

Parameters
iindex of the point in the trajectory
Returns
modulus of the momentum at that point [GeV/c]
See also
HasMomentum()

The modulus of the momentum at the specified trajectory point is computed and returned. If the trajectory does not have momentum information, the value 1 GeV/c is always returned. This can be tested trajectory by trajectory by HasMomentum(). If the index is not valid in the trajectory, the result is undefined.

Definition at line 448 of file Trajectory.h.

References MomentumVectorAtPoint().

Referenced by recob::TrackTrajectory::EndMomentum(), and recob::Track::MomentumAtPoint().

449  { return MomentumVectorAtPoint(i).R(); }
Vector_t const & MomentumVectorAtPoint(size_t i) const
Returns the momentum vector at a point.
Definition: Trajectory.h:463
Vector_t const& recob::Trajectory::MomentumVectorAtPoint ( size_t  i) const
inline

Returns the momentum vector at a point.

Parameters
iindex of the point in the trajectory
Returns
the momentum at that point [GeV/c]
See also
HasMomentum(), MomentumAtPoint(), DirectionAtPoint()

The momentum at the specified trajectory point is returned. If the trajectory does not have momentum information, the returned value will represent the direction, that is a momentum with modulus 1 GeV/c. This can be tested trajectory by trajectory by HasMomentum(). If the index is not valid in the trajectory, the result is undefined.

Definition at line 463 of file Trajectory.h.

References fMomenta.

Referenced by DirectionAtPoint(), recob::TrackTrajectory::EndMomentum(), EndMomentumVector(), MomentumAtPoint(), Phi(), StartMomentumVector(), Theta(), and TrajectoryPoint().

464  { return fMomenta[i]; }
Momenta_t fMomenta
Momentum of each of the points in trajectory.
Definition: Trajectory.h:676
template<typename T >
T recob::Trajectory::MomentumVectorAtPoint ( unsigned int  p) const
inline

Momentum vector at point p. Use e.g. as:

TVector3 mom = traj.MomentumVectorAtPoint<TVector3>(p);

.

Definition at line 582 of file Trajectory.h.

References MomentumVectorAtPoint().

Referenced by MomentumVectorAtPoint().

582 { auto mom = MomentumVectorAtPoint(p); return T(mom.X(),mom.Y(),mom.Z()); }
Vector_t const & MomentumVectorAtPoint(size_t i) const
Returns the momentum vector at a point.
Definition: Trajectory.h:463
size_t recob::Trajectory::NPoints ( ) const
inline

Returns the number of stored trajectory points.

Returns
the number of stored trajectory points
See also
PositionAtPoint(), MomentumVectorAtPoint(), DirectionAtPoint()

For each point, both position and momentum are available.

Definition at line 173 of file Trajectory.h.

References fPositions.

Referenced by recob::TrackTrajectory::AtLeastValidTrajectoryPoints(), recob::TrackTrajectory::CountValidPoints(), trkf::TrajectoryMCSFitter::fitMcs(), HasPoint(), trkmkr::TrackMaker::initEvent(), LastPoint(), trkmkr::TrackMaker::makeTrack(), recob::Track::NPoints(), NumberTrajectoryPoints(), recob::TrackTrajectory::TrackTrajectory(), and recob::TrackTrajectory::Trajectory().

174  { return fPositions.size(); }
Positions_t fPositions
List of points the trajectory goes through.
Definition: Trajectory.h:675
size_t recob::Trajectory::NumberTrajectoryPoints ( ) const
inline

Returns the number of stored trajectory points.

Returns
the number of stored trajectory points
See also
PositionAtPoint(), MomentumVectorAtPoint(), DirectionAtPoint()

For each point, both position and momentum are available.

Definition at line 162 of file Trajectory.h.

References NPoints().

Referenced by trkf::BezierTrack::NSegments(), recob::Track::Trajectory(), and recob::TrackTrajectory::Trajectory().

163  { return NPoints(); }
size_t NPoints() const
Returns the number of stored trajectory points.
Definition: Trajectory.h:173
double recob::Trajectory::Phi ( size_t  p = 0) const
inline

Azimuthal angle at a point on the trajectory, with respect to z.

Parameters
pthe point index to extract the angle from (default: start)
Returns
the azimuthal angle, in $ [-\pi,\pi[ $ [radians]
See also
Theta(), ZenithAngle()

The angle is measured on the plane orthogonal to the z axis, in the same reference where Theta() is measured. The angle is measured counterclockwise from the x axis. Skyward direction is expected to be $ +\pi/2 $ radians in this system, provided that the standard reference frame with the y axis pointing skyward is chosen.

If the point number is invalid, the behaviour is undefined.

Definition at line 343 of file Trajectory.h.

References AzimuthAngle(), MomentumVectorAtPoint(), and ZenithAngle().

Referenced by recob::TrackTrajectory::Phi().

344  { return MomentumVectorAtPoint(p).Phi(); }
Vector_t const & MomentumVectorAtPoint(size_t i) const
Returns the momentum vector at a point.
Definition: Trajectory.h:463
const Positions_t& recob::Trajectory::Positions ( ) const
inline

Returns reference to stored vector of positions.

Returns
reference to stored vector of positions

Definition at line 196 of file Trajectory.h.

References fPositions.

196 { return fPositions; }
Positions_t fPositions
List of points the trajectory goes through.
Definition: Trajectory.h:675
Point_t const& recob::Trajectory::Start ( ) const
inline

Returns the position of the first point of the trajectory [cm].

Definition at line 228 of file Trajectory.h.

References FirstPoint(), and LocationAtPoint().

Referenced by Extent(), trkf::BezierTrack::GetTrackPoint(), opdet::TrackTimeAssoc::ScanMIPHypotheses(), and Vertex().

229  { return LocationAtPoint(FirstPoint()); }
Point_t const & LocationAtPoint(size_t i) const
Returns the position at the specified trajectory point.
Definition: Trajectory.h:242
size_t FirstPoint() const
Returns the index of the first point in the trajectory (yep, it&#39;s 0).
Definition: Trajectory.h:177
template<typename T >
T recob::Trajectory::Start ( ) const
inline

Start position. Use e.g. as:

TVector3 start = traj.Start<TVector3>();

.

Definition at line 549 of file Trajectory.h.

References Start().

Referenced by Start().

549 { auto& loc = Start(); return T(loc.X(),loc.Y(),loc.Z()); }
Point_t const & Start() const
Returns the position of the first point of the trajectory [cm].
Definition: Trajectory.h:228
Vector_t recob::Trajectory::StartDirection ( ) const
inline

Returns the direction of the trajectory at the first point.

Definition at line 305 of file Trajectory.h.

References DirectionAtPoint(), and FirstPoint().

Referenced by Direction(), and VertexDirection().

306  { return DirectionAtPoint(FirstPoint()); }
Vector_t DirectionAtPoint(size_t i) const
Computes and returns the direction of the trajectory at a point.
Definition: Trajectory.cxx:118
size_t FirstPoint() const
Returns the index of the first point in the trajectory (yep, it&#39;s 0).
Definition: Trajectory.h:177
template<typename T >
T recob::Trajectory::StartDirection ( ) const
inline

Start direction. Use e.g. as:

TVector3 startdir = traj.StartDirection<TVector3>();

.

Definition at line 561 of file Trajectory.h.

References dir, and StartDirection().

Referenced by StartDirection().

561 { auto dir = StartDirection(); return T(dir.X(),dir.Y(),dir.Z()); }
Vector_t StartDirection() const
Returns the direction of the trajectory at the first point.
Definition: Trajectory.h:305
TDirectory * dir
Definition: macro.C:5
double recob::Trajectory::StartMomentum ( ) const
inline

Computes and returns the modulus of momentum at the first point [GeV/c].

Definition at line 403 of file Trajectory.h.

References StartMomentumVector().

Referenced by lar::example::CheatTrack::momentum(), and VertexMomentum().

404  { return StartMomentumVector().R(); }
Vector_t const & StartMomentumVector() const
Returns the momentum of the trajectory at the first point [GeV/c].
Definition: Trajectory.h:390
Vector_t const& recob::Trajectory::StartMomentumVector ( ) const
inline

Returns the momentum of the trajectory at the first point [GeV/c].

Definition at line 390 of file Trajectory.h.

References FirstPoint(), and MomentumVectorAtPoint().

Referenced by StartMomentum(), and VertexMomentumVector().

391  { return MomentumVectorAtPoint(FirstPoint()); }
size_t FirstPoint() const
Returns the index of the first point in the trajectory (yep, it&#39;s 0).
Definition: Trajectory.h:177
Vector_t const & MomentumVectorAtPoint(size_t i) const
Returns the momentum vector at a point.
Definition: Trajectory.h:463
template<typename T >
T recob::Trajectory::StartMomentumVector ( ) const
inline

Momentum vector at start point. Use e.g. as:

TVector3 startmom = traj.StartMomentumVector<TVector3>();

.

Definition at line 573 of file Trajectory.h.

References StartMomentumVector().

Referenced by StartMomentumVector().

573 { auto mom = StartMomentumVector(); return T(mom.X(),mom.Y(),mom.Z()); }
Vector_t const & StartMomentumVector() const
Returns the momentum of the trajectory at the first point [GeV/c].
Definition: Trajectory.h:390
double recob::Trajectory::Theta ( size_t  p = 0) const
inline

Trajectory angle at point, with respect to positive z direction.

Parameters
pthe index point to extract the angle from (default: start)
Returns
angle with respect to positive z, in $ [0,\pi] $ [radians]

The reference direction is the positive z axis. Although this usually matches the beam direction, this is not guaranteed and if the explicit angle from beam direction is needed, the scalar product of the beam direction and the direction from StartDirection() should be used instead.

If the point number is invalid, the behaviour is undefined.

Definition at line 326 of file Trajectory.h.

References MomentumVectorAtPoint().

Referenced by recob::TrackTrajectory::Theta().

327  { return MomentumVectorAtPoint(p).Theta(); }
Vector_t const & MomentumVectorAtPoint(size_t i) const
Returns the momentum vector at a point.
Definition: Trajectory.h:463
TrajectoryPoint_t recob::Trajectory::TrajectoryPoint ( size_t  i) const
inline

Returns position and momentum at the specified trajectory point.

Parameters
iindex of the trajectory point
Returns
the information at the specified trajectory point

Note that this method returns the momentum, not the direction.

auto trajPoint = traj.TrajectoryPoint(0);
std::cout << "Start of trajectory at " << trajPoint.position
<< " cm, with momentum " << trajPoint.momentum << " GeV/c"
<< std::endl;

If the specified index is not valid, result is undefined.

Definition at line 219 of file Trajectory.h.

References LocationAtPoint(), and MomentumVectorAtPoint().

Referenced by recob::Track::CountValidPoints(), and recob::TrackTrajectory::LastValidPoint().

220  { return { LocationAtPoint(i), MomentumVectorAtPoint(i) }; }
Point_t const & LocationAtPoint(size_t i) const
Returns the position at the specified trajectory point.
Definition: Trajectory.h:242
Vector_t const & MomentumVectorAtPoint(size_t i) const
Returns the momentum vector at a point.
Definition: Trajectory.h:463
Point_t const& recob::Trajectory::Vertex ( ) const
inline

Returns the position of the first point of the trajectory [cm].

Definition at line 224 of file Trajectory.h.

References Start().

225  { return Start(); }
Point_t const & Start() const
Returns the position of the first point of the trajectory [cm].
Definition: Trajectory.h:228
template<typename T >
T recob::Trajectory::Vertex ( ) const
inline

Start position. Use e.g. as:

TVector3 vertex = traj.Vertex<TVector3>();

.

Definition at line 552 of file Trajectory.h.

References Vertex().

Referenced by Vertex().

552 { auto& loc = Vertex(); return T(loc.X(),loc.Y(),loc.Z()); }
Point_t const & Vertex() const
Returns the position of the first point of the trajectory [cm].
Definition: Trajectory.h:224
Vector_t recob::Trajectory::VertexDirection ( ) const
inline

Returns the direction of the trajectory at the first point.

Definition at line 301 of file Trajectory.h.

References StartDirection().

302  { return StartDirection(); }
Vector_t StartDirection() const
Returns the direction of the trajectory at the first point.
Definition: Trajectory.h:305
template<typename T >
T recob::Trajectory::VertexDirection ( ) const
inline

Start direction. Use e.g. as:

TVector3 vertexdir = traj.VertexDirection<TVector3>();

.

Definition at line 564 of file Trajectory.h.

References dir, and VertexDirection().

Referenced by VertexDirection().

564 { auto dir = VertexDirection(); return T(dir.X(),dir.Y(),dir.Z()); }
Vector_t VertexDirection() const
Returns the direction of the trajectory at the first point.
Definition: Trajectory.h:301
TDirectory * dir
Definition: macro.C:5
double recob::Trajectory::VertexMomentum ( ) const
inline

Computes and returns the modulus of momentum at the first point [GeV/c].

Definition at line 399 of file Trajectory.h.

References StartMomentum().

400  { return StartMomentum(); }
double StartMomentum() const
Computes and returns the modulus of momentum at the first point [GeV/c].
Definition: Trajectory.h:403
Vector_t const& recob::Trajectory::VertexMomentumVector ( ) const
inline

Returns the momentum of the trajectory at the first point [GeV/c].

Definition at line 386 of file Trajectory.h.

References StartMomentumVector().

387  { return StartMomentumVector(); }
Vector_t const & StartMomentumVector() const
Returns the momentum of the trajectory at the first point [GeV/c].
Definition: Trajectory.h:390
template<typename T >
T recob::Trajectory::VertexMomentumVector ( ) const
inline

Momentum vector at start point. Use e.g. as:

TVector3 vertexmom = traj.VertexMomentumVector<TVector3>();

.

Definition at line 576 of file Trajectory.h.

References VertexMomentumVector().

Referenced by VertexMomentumVector().

576 { auto mom = VertexMomentumVector(); return T(mom.X(),mom.Y(),mom.Z()); }
Vector_t const & VertexMomentumVector() const
Returns the momentum of the trajectory at the first point [GeV/c].
Definition: Trajectory.h:386
double recob::Trajectory::ZenithAngle ( size_t  p = 0) const

"Zenith" angle of trajectory, with respect to the vertical axis.

Parameters
pthe point index to extract the angle from (default: start)
Returns
opposite of the actual zenith angle, in $ [0,\pi] $ [radians]
See also
AzimuthAngle()

The angle is defined with respect to the negative y direction. It describes the angle at the specified point on the trajectory. Therefore, a trajectory starting along the positive y direction returns $ \pi $ radians, while a trajectory going downward along the negative y direction returns 0.

This is designed so that vertical cosmic rays produce trajectories with angle 0 radians.

If the point number is invalid, the behaviour is undefined.

Definition at line 83 of file Trajectory.cxx.

References DirectionAtPoint().

Referenced by Phi(), and recob::TrackTrajectory::ZenithAngle().

83  {
84 
85  // The zenith angle is defined by the angle between the track starting
86  // direction and the y axis.
87  // The y component of the starting direction is in fact the cosine of that
88  // angle (and std::acos() conveniently returns a value in [0;pi]).
89  // Our convention has the zenith angle the supplemental of the standard one.
90 
91  return util::pi<Coord_t>() - std::acos(DirectionAtPoint(p).Y());
92 
93 } // recob::Trajectory::ZenithAngle()
Vector_t DirectionAtPoint(size_t i) const
Computes and returns the direction of the trajectory at a point.
Definition: Trajectory.cxx:118

Member Data Documentation

bool recob::Trajectory::fHasMomentum = true
private

Whether we have momentum modulus information.

Definition at line 678 of file Trajectory.h.

Referenced by HasMomentum().

Momenta_t recob::Trajectory::fMomenta
private

Momentum of each of the points in trajectory.

Definition at line 676 of file Trajectory.h.

Referenced by Momenta(), and MomentumVectorAtPoint().

Positions_t recob::Trajectory::fPositions
private

List of points the trajectory goes through.

Definition at line 675 of file Trajectory.h.

Referenced by LocationAtPoint(), NPoints(), and Positions().

constexpr unsigned int recob::Trajectory::MaxDumpVerbosity = 6
static

Largest verbosity level supported by Dump().

Definition at line 668 of file Trajectory.h.


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