 |
Belle II Software
release-05-01-25
|
10 #include <tracking/trackFindingCDC/filters/axialSegmentPair/SimpleAxialSegmentPairFilter.h>
12 #include <tracking/trackFindingCDC/eventdata/tracks/CDCAxialSegmentPair.h>
13 #include <tracking/trackFindingCDC/eventdata/segments/CDCSegment2D.h>
16 using namespace TrackFindingCDC;
28 assert(ptrStartSegment);
29 assert(ptrEndSegment);
42 if (not endSegmentIsCoaligned or not startSegmentIsCoaligned) {
50 if (startFitGap < 0 or startFitGap > 100 or endFitGap < 0 or endFitGap > 100) {
57 if (startFitFrontOffset < 0 or endFitBackOffset < 0) {
61 Vector2D startBackRecoPos2D = startSegment.back().getRecoPos2D();
62 Vector2D endFrontRecoPos2D = endSegment.front().getRecoPos2D();
71 double momAngleAtStartBack = startMom2DAtStartBack.
angleWith(endMom2DAtStartBack);
72 double momAngleAtEndFront = endMom2DAtEndFront.
angleWith(startMom2DAtEndFront);
74 if (fabs(momAngleAtEndFront) > 2.0 or fabs(momAngleAtStartBack) > 2.0) {
79 double startFit_dist2DToFront_endSegment = startFit.
getDist2D(endFrontRecoPos2D);
80 double endFit_dist2DToBack_startSegment = endFit.
getDist2D(startBackRecoPos2D);
82 if (startFit_dist2DToFront_endSegment < 6 and endFit_dist2DToBack_startSegment < 6) {
83 return startSegment.size() + endSegment.size();
106 axialSegmentPair)
const
double getArcLength2DFrontOffset(const AFromHits &fromHits, const AToHits &toHits) const
Calculates the perpendicular travel distance from the first position of the fromHits to the first pos...
double getTotalArcLength2D(const AHits &hits) const
Calculates the perpendicular travel distance from the first position of the hits to the last position...
const CDCAxialSegment2D * getStartSegment() const
Getter for the start segment.
A two dimensional vector which is equipped with functions for correct handeling of orientation relat...
const CDCRiemannFitter & getRiemannFitter() const
Returns the xy fitter instance that is used by this filter.
const CDCTrajectory2D & getFittedTrajectory2D(const CDCAxialSegment2D &segment) const
Returns the trajectory of the axial segment. Also fits it if necessary.
void useOnlyOrientation()
Setup the fitter to use only reference position and the drift length with right left orientation.
Particle trajectory as it is seen in xy projection represented as a circle.
const CDCAxialSegment2D * getEndSegment() const
Getter for the end segment.
void update(CDCTrajectory2D &trajectory2D, const CDCObservations2D &observations2D) const
Update the trajectory with a fit to the observations.
Weight operator()(const CDCAxialSegmentPair &axialSegmentPair) final
Checks if a pair of axial segments is a good combination.
Class representing a pair of reconstructed axial segements in adjacent superlayer.
Abstract base class for different kinds of events.
CDCRiemannFitter m_riemannFitter
Memory of the Riemann fitter for the circle fits.
Vector2D getFlightDirection2D(const Vector2D &point) const
Get the unit direction of flight at the given point, where arcLength2D = 0.
CDCTrajectory2D & getTrajectory2D() const
Getter for the trajectory of the two dimensional trajectory.
bool isFitted() const
Checks if the circle is already set to a valid value.
double getArcLength2DGap(const AFromHits &fromHits, const AToHits &toHits) const
Calculates the perpendicular travel distance from the last position of the fromHits to the first posi...
A reconstructed sequence of two dimensional hits in one super layer.
double getDist2D(const Vector2D &point) const
Calculates the distance from the point to the trajectory as seen from the xy projection.
double angleWith(const Vector2D &rhs) const
The angle between this and rhs.
double getArcLength2DBackOffset(const AFromHits &fromHits, const AToHits &toHits) const
Calculates the perpendicular travel distance from the last position of the fromHits to the last posit...
SimpleAxialSegmentPairFilter()
Constructor.