HerdSoftware  0.3.2
Functions
Herd::Geom Namespace Reference

Functions

Point ProjectPointToLine (const Point &point, const Line &line)
 Finds the projection of a point to a line. More...
 
bool IsInsideCaloEnvelope (const Point &point, const CaloGeoParams &geoParams)
 Checks if a point is inside the CALO envelope. More...
 
Segment PathInCaloLyso (const Line &line, const CaloGeoParams &geoParams)
 Computes the path of the given line in LYSO. More...
 
Segment PathInCaloEnvelope (const Line &line, const CaloGeoParams &geoParams)
 Computes the path of the given line in the CALO envelope. More...
 
float DistanceToCaloEnvelope (const Point &point, const CaloGeoParams &geoParams)
 Computes the distance of a point from the CALO envelope. More...
 
float CaloPathlengthAfterPoint (const Point &startingPoint, const Vec3D &direction, const CaloGeoParams &geoParams)
 Computes the distance between a point inside CALO and the CALO border along a given direction. More...
 

Function Documentation

◆ CaloPathlengthAfterPoint()

float Herd::Geom::CaloPathlengthAfterPoint ( const Point startingPoint,
const Vec3D direction,
const CaloGeoParams geoParams 
)

Computes the distance between a point inside CALO and the CALO border along a given direction.

The CALO border is defined by the LYSO cubes.

Parameters
startingPointThe point inside CALO.
directionThe direction along which the distance to CALO border is computed.
geoParamsThe CALO geometry parameters.
Returns
The distance between startingPoint and the CALO border computed along direction.

◆ DistanceToCaloEnvelope()

float Herd::Geom::DistanceToCaloEnvelope ( const Point point,
const CaloGeoParams geoParams 
)

Computes the distance of a point from the CALO envelope.

This function computes the distance between the given point and the CALO envelope as given by the geometric parameters object.

Parameters
pointThe point.
geoParamsThe geometric parameters of the CALO.
Returns
The distance between the point and the CALO envelope in cm.

◆ IsInsideCaloEnvelope()

bool Herd::Geom::IsInsideCaloEnvelope ( const Point point,
const CaloGeoParams geoParams 
)

Checks if a point is inside the CALO envelope.

Parameters
pointThe given point
geoParamsThe geometry parameters of the CALO
Returns
true if the point is inside the CALO envelope, false otherwise

◆ PathInCaloEnvelope()

Segment Herd::Geom::PathInCaloEnvelope ( const Line line,
const CaloGeoParams geoParams 
)

Computes the path of the given line in the CALO envelope.

Computes the exact path in the CALO envelope of the given line by checking the intersection of the line with the envelope surface. The path is returned as a #Segment object, whose starting point is the first intersection along the line direction and whose end point is the second one. If the line does not intersect the envelope a default #Segment is returned.

Parameters
lineThe line for which the path in LYSO is computed.
geoParamsThe geometry parameters of the CALO.
Returns
A segment describing the line path in the envelope

◆ PathInCaloLyso()

Segment Herd::Geom::PathInCaloLyso ( const Line line,
const CaloGeoParams geoParams 
)

Computes the path of the given line in LYSO.

Computes the exact path in LYSO of the given line by checking the intersection of the line with each cube and then finding the entrance and exit points from CALO among them.

Parameters
lineThe line for which the path in LYSO is computed.
geoParamsThe geometry parameters of the CALO.
Returns
A segment connecting the line entry and exit points in LYSO.

◆ ProjectPointToLine()

Point Herd::Geom::ProjectPointToLine ( const Point point,
const Line line 
)

Finds the projection of a point to a line.

Parameters
pointThe point to project.
lineThe line to which the point is projected.
Returns
The orthogonal projection of the given point on the given line.