Belle II Software  release-08-01-10
CDCSegmentPair Class Reference

Class representing a pair of one reconstructed axial segement and one stereo segment in adjacent superlayer. More...

#include <CDCSegmentPair.h>

Collaboration diagram for CDCSegmentPair:

Public Member Functions

 CDCSegmentPair ()
 Default constructor - for ROOT compatability.
 
 CDCSegmentPair (const CDCSegment2D *fromSegment, const CDCSegment2D *toSegment)
 Constructor from two segments.
 
 CDCSegmentPair (const CDCSegment2D *fromSegment, const CDCSegment2D *toSegment, const CDCTrajectory3D &trajectory3D)
 Constructor from two segments and an assoziated trajectory.
 
bool operator== (CDCSegmentPair const &rhs) const
 Equality comparision based on the pointers to the stored segments.
 
bool operator< (CDCSegmentPair const &rhs) const
 Total ordering sheme comparing the segment pointers.
 
bool checkSegmentsNonNullptr () const
 Checks if both stored segments are not nullptr. Returns true if check is succeded.
 
bool checkSegmentsStereoKinds () const
 Checks if the two segments are of different axial type.
 
bool checkSegments () const
 Checks the references to the contained three segment for nullptrs and exactly one of them is axial and one is stereo.
 
EStereoKind getFromStereoKind () const
 Getter for the stereo type of the first segment.
 
EStereoKind getToStereoKind () const
 Getter for the stereo type of the second segment.
 
ISuperLayer getFromISuperLayer () const
 Getter for the superlayer id of the from segment.
 
ISuperLayer getToISuperLayer () const
 Getter for the superlayer id of the to segment.
 
std::size_t size () const
 Getter for the total number of hits in this segment pair.
 
const CDCSegment2DgetFromSegment () const
 Getter for the from segment.
 
void setFromSegment (const CDCSegment2D *fromSegment)
 Setter for the from segment.
 
const CDCSegment2DgetToSegment () const
 Getter for the to segment.
 
void setToSegment (const CDCSegment2D *toSegment)
 Setter for the to segment.
 
const CDCSegment2DgetStereoSegment () const
 Getter for the stereo segment.
 
const CDCSegment2DgetAxialSegment () const
 Getter for the axial segment.
 
void setSegments (const CDCSegment2D *fromSegment, const CDCSegment2D *toSegment)
 Setter for both segments simultaniously.
 
double computeDeltaPhiAtSuperLayerBound () const
 Determines the angle between the last reconstructed position of the from segment and the first reconstructed position of the to segment.
 
double computeFromIsBeforeTo () const
 Indicator if the from segment lies before the to segment.
 
double computeToIsAfterFrom () const
 Indicator if the from segment lies before the to segment.
 
double computeIsCoaligned () const
 Indicator if the from segment and the to segment have roughly the same travel direction.
 
double computeFromIsBeforeToFitless () const
 Indicator if the from segment lies before the to segment, build without using the trajectories, which may not have been fitted yet.
 
double computeToIsAfterFromFitless () const
 Indicator if the from segment lies before the to segment, build without using the trajectories, which may not have been fitted yet.
 
double computeIsCoalignedFitless () const
 Indicator if the from segment and the to segment have roughly the same travel direction without using the common fit.
 
EForwardBackward isCoaligned (const CDCTrajectory2D &trajectory2D) const
 Checks if the last entity in the vector lies greater or lower travel distance than the last entity. More...
 
void setTrajectory3D (const CDCTrajectory3D &trajectory3D) const
 Setter for the three dimensional trajectory.
 
CDCTrajectory3DgetTrajectory3D () const
 Getter for the three dimensional trajectory.
 
CDCTrajectory2D getTrajectory2D () const
 Getter for the two dimensional projection of the common three dimensional trajectory.
 
CDCTrajectorySZ getTrajectorySZ () const
 Getter for the sz projection of the common three dimensional trajectory.
 
void clearTrajectory3D () const
 Invalides the currently stored trajectory information.
 
void unsetAndForwardMaskedFlag () const
 Unsets the masked flag of the segment triple's automaton cell and of the three contained segments.
 
void setAndForwardMaskedFlag () const
 Sets the masked flag of the segment triple's automaton cell and of the three contained segments.
 
void receiveMaskedFlag () const
 If one of the contained segments is marked as masked this segment triple is set be masked as well.
 
AutomatonCellgetAutomatonCell () const
 Mutable getter for the automaton cell.
 

Private Attributes

const CDCSegment2Dm_fromSegment
 Reference to the from segment.
 
const CDCSegment2Dm_toSegment
 Reference to the to segment.
 
CDCTrajectory3D m_trajectory3D
 Memory for the common three dimensional trajectory.
 
AutomatonCell m_automatonCell
 Automaton cell assoziated with the pair of segments.
 

Friends

bool operator< (const CDCSegmentPair &segmentPair, const CDCSegment2D *segment)
 Define reconstructed segments and axial stereo segment pairs as coaligned on the from segment.
 
bool operator< (const CDCSegment2D *segment, const CDCSegmentPair &segmentPair)
 Define reconstructed segments and axial stereo segment pairs as coaligned on the from segment.
 

Detailed Description

Class representing a pair of one reconstructed axial segement and one stereo segment in adjacent superlayer.

Definition at line 34 of file CDCSegmentPair.h.

Member Function Documentation

◆ isCoaligned()

EForwardBackward isCoaligned ( const CDCTrajectory2D trajectory2D) const

Checks if the last entity in the vector lies greater or lower travel distance than the last entity.

Returns:

  • EForwardBackward::c_Forward if the last entity lies behind the first.
  • EForwardBackward::c_Backward if the last entity lies before the first.

Definition at line 263 of file CDCSegmentPair.cc.

264 {
265  EForwardBackward fromIsCoaligned = trajectory2D.isForwardOrBackwardTo(*(getFromSegment()));
266  EForwardBackward toIsCoaligned = trajectory2D.isForwardOrBackwardTo(*(getToSegment()));
267 
268  if (fromIsCoaligned == EForwardBackward::c_Forward and
269  toIsCoaligned == EForwardBackward::c_Forward) {
270  return EForwardBackward::c_Forward;
271  } else if (fromIsCoaligned == EForwardBackward::c_Backward and
272  toIsCoaligned == EForwardBackward::c_Backward) {
273  return EForwardBackward::c_Backward;
274  } else {
275  return EForwardBackward::c_Invalid;
276  }
277 }
const CDCSegment2D * getFromSegment() const
Getter for the from segment.
const CDCSegment2D * getToSegment() const
Getter for the to segment.
EForwardBackward isForwardOrBackwardTo(const AHits &hits) const
Calculates if this trajectory and the hits are coaligned Returns:
EForwardBackward
Enumeration to represent the distinct possibilities of the right left passage information.

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