Jpp  17.1.1
the software that should make you happy
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Public Member Functions | List of all members
JFIT::JVectorNZ Class Reference

Determination of the time residual vector of hits for a track along z-axis (JFIT::JLine1Z). More...

#include <JVectorNZ.hh>

Inheritance diagram for JFIT::JVectorNZ:
JMATH::JVectorND std::vector< double >

Public Member Functions

 JVectorNZ ()
 Default contructor. More...
 
template<class T >
 JVectorNZ (const JLine1Z &track, T __begin, T __end)
 Constructor. More...
 
template<class T >
void set (const JLine1Z &track, T __begin, T __end)
 Set time residual vector. More...
 
double getDot (const JVectorND &vector) const
 Get dot product. More...
 

Detailed Description

Determination of the time residual vector of hits for a track along z-axis (JFIT::JLine1Z).

Definition at line 21 of file JVectorNZ.hh.

Constructor & Destructor Documentation

JFIT::JVectorNZ::JVectorNZ ( )
inline

Default contructor.

Definition at line 28 of file JVectorNZ.hh.

29  {}
template<class T >
JFIT::JVectorNZ::JVectorNZ ( const JLine1Z track,
T  __begin,
T  __end 
)
inline

Constructor.

The template argument T refers to an iterator of a data structure which should have the following member methods:

  • double getX(); // [m]
  • double getY(); // [m]
  • double getZ(); // [m]
  • double getT(); // [ns]
Parameters
tracktrack
__beginbegin of data
__endend of data

Definition at line 46 of file JVectorNZ.hh.

49  {
50  set(track, __begin, __end);
51  }
void set(const JLine1Z &track, T __begin, T __end)
Set time residual vector.
Definition: JVectorNZ.hh:68

Member Function Documentation

template<class T >
void JFIT::JVectorNZ::set ( const JLine1Z track,
T  __begin,
T  __end 
)
inline

Set time residual vector.

The template argument T refers to an iterator of a data structure which should have the following member methods:

  • double getX(); // [m]
  • double getY(); // [m]
  • double getZ(); // [m]
  • double getT(); // [ns]
Parameters
tracktrack
__beginbegin of data
__endend of data

Definition at line 68 of file JVectorNZ.hh.

71  {
73 
74  this->clear();
75 
76  for (T hit = __begin; hit != __end; ++hit) {
77  this->push_back(hit->getT() - track.getT(JVector3D(hit->getX(),
78  hit->getY(),
79  hit->getZ())));
80  }
81  }
Data structure for vector in three dimensions.
Definition: JVector3D.hh:34
do set_variable OUTPUT_DIRECTORY $WORKDIR T
double getT(const JVector3D &pos) const
Get arrival time of Cherenkov light at given position.
Definition: JLine1Z.hh:114
double JMATH::JVectorND::getDot ( const JVectorND vector) const
inlineinherited

Get dot product.

Parameters
vectorvector
Returns
dot product

Definition at line 48 of file JVectorND.hh.

49  {
50  double dot = 0.0;
51 
52  const double* p = this-> data();
53  const double* q = vector.data();
54 
55  for (size_t i = this->size(); i != 0; --i, ++p, ++q) {
56  dot += (*p) * (*q);
57  }
58 
59  return dot;
60  }

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