Vertex.cxx
Go to the documentation of this file.
1 //
2 // Vertex.cxx
3 // garsoft-mrb
4 //
5 // Created by Tom Junk on July 12, 2018
6 
8 
9 namespace gar {
10  namespace rec {
11 
12  //--------------------------------------------------------------------------
13  Vertex::Vertex(const float *pos,
14  const float *covmat,
15  const double time)
16  : fTime(time)
17  {
20 
21  size_t icounter = 0;
22  for (size_t i=0;i<3;++i)
23  {
24  fPosition[i] = pos[i];
25  for (size_t j=0; j<3; ++j)
26  {
27  fCovMat[i][j] = covmat[icounter];
28  ++icounter;
29  }
30  }
31  }
32 
33  //--------------------------------------------------------------------------
34  // empty constructor
35 
37  : fTime(0)
38  {
41 
42  for (size_t i=0;i<3;++i)
43  {
44  fPosition[i] = 0;
45  for (size_t j=0; j<3; ++j)
46  {
47  fCovMat[i][j] = 0;
48  }
49  }
50  }
51 
52 
53 
54  //--------------------------------------------------------------------------
55  // ID number methods
56  bool Vertex::operator==(const Vertex& rhs) const {
57  return (this->fIDnumero == rhs.fIDnumero);
58  }
59 
60  bool Vertex::operator!=(const Vertex& rhs) const {
61  return (this->fIDnumero != rhs.fIDnumero);
62  }
63 
65 
66 
67 
68  } // rec
69 } // gar
rec
Definition: tracks.py:88
gar::rec::IDNumber getIDNumber() const
Definition: Vertex.cxx:64
bool operator!=(const Vertex &rhs) const
Definition: Vertex.cxx:60
static IDNumberGen * create(IDNumber iniValue=std::numeric_limits< IDNumber >::max())
Definition: IDNumberGen.cxx:18
gar::rec::IDNumber fIDnumero
Definition: Vertex.h:30
float fCovMat[3][3]
uncertianties on the position
Definition: Vertex.h:33
General GArSoft Utilities.
static gar::rec::IDNumber const FirstNumber
Definition: Vertex.h:29
bool operator==(const Vertex &rhs) const
Definition: Vertex.cxx:56
size_t IDNumber
Definition: IDNumberGen.h:71
double fTime
timestamp (ROOT&#39;s portable version of uint64_t)
Definition: Vertex.h:34
float fPosition[3]
position of vertex
Definition: Vertex.h:32