LArSoft  v06_85_00
Liquid Argon Software toolkit - http://larsoft.org/
recob::SpacePoint Class Reference

#include "SpacePoint.h"

Public Types

using ID_t = int
 type of spacepoint ID More...
 

Public Member Functions

 SpacePoint ()
 
 SpacePoint (double const *xyz, double const *err, double chisq, int id=InvalidID)
 
ID_t ID () const
 
const double * XYZ () const
 
const double * ErrXYZ () const
 
double Chisq () const
 

Static Public Attributes

static constexpr ID_t InvalidID = util::kBogusI
 Special value for an invalid ID. More...
 

Private Attributes

ID_t fID
 Default constructor. More...
 
double fXYZ [3]
 position of SpacePoint in xyz More...
 
double fErrXYZ [6]
 Error matrix (triangular). More...
 
double fChisq
 Chisquare. More...
 

Friends

std::ostream & operator<< (std::ostream &o, const SpacePoint &a)
 
bool operator< (const SpacePoint &a, const SpacePoint &b)
 

Detailed Description

Definition at line 21 of file SpacePoint.h.

Member Typedef Documentation

type of spacepoint ID

Definition at line 24 of file SpacePoint.h.

Constructor & Destructor Documentation

recob::SpacePoint::SpacePoint ( )

Definition at line 17 of file SpacePoint.cxx.

References fErrXYZ.

17  :
18  fID(-1),
19  fChisq(0.)
20  {
21  for(int i=0; i<6; ++i)
22  fErrXYZ[i] = 0.;
23  }
ID_t fID
Default constructor.
Definition: SpacePoint.h:33
double fChisq
Chisquare.
Definition: SpacePoint.h:36
double fErrXYZ[6]
Error matrix (triangular).
Definition: SpacePoint.h:35
recob::SpacePoint::SpacePoint ( double const *  xyz,
double const *  err,
double  chisq,
int  id = InvalidID 
)

Definition at line 26 of file SpacePoint.cxx.

References fErrXYZ, and fXYZ.

30  : fID(id)
31  , fChisq(chisq)
32  {
33  for(int i = 0; i < 3; ++i) fXYZ[i] = xyz[i];
34  for(int i = 0; i < 6; ++i) fErrXYZ[i] = err[i];
35  }
ID_t fID
Default constructor.
Definition: SpacePoint.h:33
double fChisq
Chisquare.
Definition: SpacePoint.h:36
double fErrXYZ[6]
Error matrix (triangular).
Definition: SpacePoint.h:35
double fXYZ[3]
position of SpacePoint in xyz
Definition: SpacePoint.h:34

Member Function Documentation

double recob::SpacePoint::Chisq ( ) const
inline

Definition at line 66 of file SpacePoint.h.

References fChisq.

Referenced by trkf::SpacePointAna::analyze(), and trkf::SpacePointAlg::makeSpacePoints().

66 { return fChisq; }
double fChisq
Chisquare.
Definition: SpacePoint.h:36
const double * recob::SpacePoint::ErrXYZ ( ) const
inline

Definition at line 65 of file SpacePoint.h.

References fErrXYZ.

Referenced by trkf::SpacePointAna::analyze().

65 { return fErrXYZ; }
double fErrXYZ[6]
Error matrix (triangular).
Definition: SpacePoint.h:35
recob::SpacePoint::ID_t recob::SpacePoint::ID ( ) const
inline

Definition at line 63 of file SpacePoint.h.

References fID.

Referenced by evd::RecoBaseDrawer::DrawPFParticle3D(), trkf::SpacePointAlg::getAssociatedHits(), recob::operator<(), and recob::operator<<().

63 { return fID; }
ID_t fID
Default constructor.
Definition: SpacePoint.h:33

Friends And Related Function Documentation

bool operator< ( const SpacePoint a,
const SpacePoint b 
)
friend

Definition at line 56 of file SpacePoint.cxx.

57  {
58  if(a.ID() != b. ID())
59  return a.ID()<b.ID();
60 
61  return false; //They are equal
62 
63  }
ID_t ID() const
Definition: SpacePoint.h:63
std::ostream& operator<< ( std::ostream &  o,
const SpacePoint a 
)
friend

Definition at line 40 of file SpacePoint.cxx.

41  {
42  o << std::setiosflags(std::ios::fixed) << std::setprecision(2);
43  o << " SpacePoint ID " << std::setw(5) << std::right << a.ID()
44  << " (X,Y,Z) = (" << std::setw(5) << std::right << a.XYZ()[0]
45  << " , " << std::setw(5) << std::right << a.XYZ()[1]
46  << " , " << std::setw(5) << std::right << a.XYZ()[2]
47  << ")" ;
48 
49  return o;
50  }
constexpr auto const & right(const_AssnsIter< L, R, D, Dir > const &a, const_AssnsIter< L, R, D, Dir > const &b)
Definition: AssnsIter.h:112

Member Data Documentation

double recob::SpacePoint::fChisq
private

Chisquare.

Definition at line 36 of file SpacePoint.h.

Referenced by Chisq().

double recob::SpacePoint::fErrXYZ[6]
private

Error matrix (triangular).

Definition at line 35 of file SpacePoint.h.

Referenced by ErrXYZ(), and SpacePoint().

ID_t recob::SpacePoint::fID
private

Default constructor.

SpacePoint ID

Definition at line 33 of file SpacePoint.h.

Referenced by ID().

double recob::SpacePoint::fXYZ[3]
private

position of SpacePoint in xyz

Definition at line 34 of file SpacePoint.h.

Referenced by SpacePoint(), and XYZ().

constexpr ID_t recob::SpacePoint::InvalidID = util::kBogusI
static

Special value for an invalid ID.

Definition at line 27 of file SpacePoint.h.


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