HerdSoftware  0.1.1
Public Member Functions | Private Member Functions | Private Attributes | List of all members
Herd::StkIntersectionsAlgo Class Reference

An algorithm that calculate the intersections between a track and the STK. More...

#include <algorithms/geometry/StkIntersectionsAlgo.h>

Inheritance diagram for Herd::StkIntersectionsAlgo:

Public Member Functions

 StkIntersectionsAlgo (const std::string &name)
 Constructor. More...
 
bool Initialize ()
 Initializes the planes used to compute the STK info. More...
 
bool Process ()
 Computes the STK information, so far the MC truth is used. More...
 
bool Finalize ()
 Do nothing. More...
 

Private Member Functions

bool CheckIfPointIsInStkSurface (const Point &p, const RefFrame::Side &view)
 Check if a Point is inside a STK surface. More...
 
bool CheckIfPointIsInABox (const Point &p1, const Point &p2, const Point p)
 Check if a Point is inside a 3D Box. More...
 
bool CheckIfPointIsInABox_SpecificCorners (const Point &pXNegYNegZNeg, const Point &pXPosYPosZPos, const Point p)
 Check if a Point is inside a 3D Box. More...
 
float PntDistance (const Point &p1, const Point &p2)
 Computes the distance between two points (To be removed from here). More...
 

Private Attributes

observer_ptr< EventDataStore > _evStore
 Pointer to the event data store. More...
 
StkIntersections _stkIntersections
 The stkIntersections object to fill with the computed information. More...
 
SidesArray< std::vector< Plane > > _Planes
 STK surfaces for each side and each layer. More...
 
const float _Prec
 
const unsigned int _NStkLayers
 
const float _topStkZ [12]
 
const float _topStkX
 
const float _topStkY
 
const float _topStkDX
 
const float _topStkDY
 
const float _XnegStkX [12]
 
const float _XnegStkY
 
const float _XnegStkZ
 
const float _XnegStkDY
 
const float _XnegStkDZ
 
const float _XposStkX [12]
 
const float _XposStkY
 
const float _XposStkZ
 
const float _XposStkDY
 
const float _XposStkDZ
 
const float _YnegStkY [12]
 
const float _YnegStkZ
 
const float _YnegStkX
 
const float _YnegStkDZ
 
const float _YnegStkDX
 
const float _YposStkY [12]
 
const float _YposStkZ
 
const float _YposStkX
 
const float _YposStkDZ
 
const float _YposStkDX
 

Detailed Description

An algorithm that calculate the intersections between a track and the STK.

Needed event objects:

name type store optional description
mcTruth MCTruth evStore no Info about MC truth

Produced global objects:

name type store optional description
stkIntersectionsMC StkIntersections evStore no Info about the intersections between a track and a STK.

Constructor & Destructor Documentation

◆ StkIntersectionsAlgo()

Herd::StkIntersectionsAlgo::StkIntersectionsAlgo ( const std::string &  name)

Constructor.

Parameters
nameThe name of the algorithm object.

Member Function Documentation

◆ CheckIfPointIsInABox()

bool Herd::StkIntersectionsAlgo::CheckIfPointIsInABox ( const Point p1,
const Point p2,
const Point  p 
)
private

Check if a Point is inside a 3D Box.

Parameters
p1a corner of the Box.
p2the opposite corner of the Box.
pthe point.
Returns
true if the point is inside the Box, false otherwise.

◆ CheckIfPointIsInABox_SpecificCorners()

bool Herd::StkIntersectionsAlgo::CheckIfPointIsInABox_SpecificCorners ( const Point pXNegYNegZNeg,
const Point pXPosYPosZPos,
const Point  p 
)
private

Check if a Point is inside a 3D Box.

Parameters
pXNegYNegZNegthe bottom corner with the minor X and Y coordinates.
pXPosYPosZPosthe top corner with the major X and Y coordinates.
pthe point.
Returns
true if the point is inside the Box, false otherwise.

◆ CheckIfPointIsInStkSurface()

bool Herd::StkIntersectionsAlgo::CheckIfPointIsInStkSurface ( const Point p,
const RefFrame::Side view 
)
private

Check if a Point is inside a STK surface.

Parameters
pthe point.
viewselect which STK is taken into account.
Returns
true if the point is inside the finite plane, false otherwise.

◆ Finalize()

bool Herd::StkIntersectionsAlgo::Finalize ( )

Do nothing.

Returns
true if no error occurs during finalization, false otherwise.

◆ Initialize()

bool Herd::StkIntersectionsAlgo::Initialize ( )

Initializes the planes used to compute the STK info.

Returns
true if initialization is done without errors, false otherwise.

◆ PntDistance()

float Herd::StkIntersectionsAlgo::PntDistance ( const Point p1,
const Point p2 
)
private

Computes the distance between two points (To be removed from here).

Parameters
p1the first point.
p2the second point.
Returns
the distance.

◆ Process()

bool Herd::StkIntersectionsAlgo::Process ( )

Computes the STK information, so far the MC truth is used.

Returns
true if no error occurs during processing, false otherwise.

Member Data Documentation

◆ _evStore

observer_ptr<EventDataStore> Herd::StkIntersectionsAlgo::_evStore
private

Pointer to the event data store.

◆ _NStkLayers

const unsigned int Herd::StkIntersectionsAlgo::_NStkLayers
private

◆ _Planes

SidesArray<std::vector<Plane> > Herd::StkIntersectionsAlgo::_Planes
private

STK surfaces for each side and each layer.

◆ _Prec

const float Herd::StkIntersectionsAlgo::_Prec
private

◆ _stkIntersections

StkIntersections Herd::StkIntersectionsAlgo::_stkIntersections
private

The stkIntersections object to fill with the computed information.

◆ _topStkDX

const float Herd::StkIntersectionsAlgo::_topStkDX
private

◆ _topStkDY

const float Herd::StkIntersectionsAlgo::_topStkDY
private

◆ _topStkX

const float Herd::StkIntersectionsAlgo::_topStkX
private

◆ _topStkY

const float Herd::StkIntersectionsAlgo::_topStkY
private

◆ _topStkZ

const float Herd::StkIntersectionsAlgo::_topStkZ[12]
private

◆ _XnegStkDY

const float Herd::StkIntersectionsAlgo::_XnegStkDY
private

◆ _XnegStkDZ

const float Herd::StkIntersectionsAlgo::_XnegStkDZ
private

◆ _XnegStkX

const float Herd::StkIntersectionsAlgo::_XnegStkX[12]
private

◆ _XnegStkY

const float Herd::StkIntersectionsAlgo::_XnegStkY
private

◆ _XnegStkZ

const float Herd::StkIntersectionsAlgo::_XnegStkZ
private

◆ _XposStkDY

const float Herd::StkIntersectionsAlgo::_XposStkDY
private

◆ _XposStkDZ

const float Herd::StkIntersectionsAlgo::_XposStkDZ
private

◆ _XposStkX

const float Herd::StkIntersectionsAlgo::_XposStkX[12]
private

◆ _XposStkY

const float Herd::StkIntersectionsAlgo::_XposStkY
private

◆ _XposStkZ

const float Herd::StkIntersectionsAlgo::_XposStkZ
private

◆ _YnegStkDX

const float Herd::StkIntersectionsAlgo::_YnegStkDX
private

◆ _YnegStkDZ

const float Herd::StkIntersectionsAlgo::_YnegStkDZ
private

◆ _YnegStkX

const float Herd::StkIntersectionsAlgo::_YnegStkX
private

◆ _YnegStkY

const float Herd::StkIntersectionsAlgo::_YnegStkY[12]
private

◆ _YnegStkZ

const float Herd::StkIntersectionsAlgo::_YnegStkZ
private

◆ _YposStkDX

const float Herd::StkIntersectionsAlgo::_YposStkDX
private

◆ _YposStkDZ

const float Herd::StkIntersectionsAlgo::_YposStkDZ
private

◆ _YposStkX

const float Herd::StkIntersectionsAlgo::_YposStkX
private

◆ _YposStkY

const float Herd::StkIntersectionsAlgo::_YposStkY[12]
private

◆ _YposStkZ

const float Herd::StkIntersectionsAlgo::_YposStkZ
private

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