8#include <tracking/trackFindingCDC/eventdata/hits/CDCRLWireHitTriple.h>
10#include <tracking/trackFindingCDC/eventdata/hits/CDCRLWireHit.h>
11#include <tracking/trackFindingCDC/topology/CDCWire.h>
12#include <tracking/trackFindingCDC/topology/WireNeighborKind.h>
13#include <tracking/trackFindingCDC/numerics/Modulo.h>
19using namespace TrackFindingCDC;
22 : m_startToMiddleCellDistance(CHAR_MAX / 2)
23 , m_middleToEndCellDistance(CHAR_MAX / 2)
24 , m_oClockDelta(SHRT_MIN)
29 const short middleToEndCellDistance,
30 const short oClockDelta)
31 : m_startToMiddleCellDistance(startToMiddleCellDistance)
32 , m_middleToEndCellDistance(middleToEndCellDistance)
33 , m_oClockDelta(oClockDelta)
39 return m_startToMiddleCellDistance;
44 return m_middleToEndCellDistance;
49 return m_startToMiddleCellDistance + m_middleToEndCellDistance;
59 return getCellExtend() >= 2 and getCellExtend() <= 4;
104 if (not startToMiddleNeighborKind.
isValid() or
105 not middleToEndNeighborKind.
isValid()) {
111 const short startToMiddleCellDistance = startToMiddleNeighborKind.
getCellDistance();
112 const short middleToEndCellDistance = middleToEndNeighborKind.
getCellDistance();
113 return Shape(startToMiddleCellDistance,
114 middleToEndCellDistance,
115 symmetricModuloFast(oClockDelta, 12));
118std::ostream& TrackFindingCDC::
Type for the different shapes of a triple of neighboring wire hits.
short getMiddleToEndCellDistance() const
Getter for the middle to end cell distance.
bool isValid() const
Check if the shape is considered valid.
short getCellExtend() const
Getter for the sum of cell distances from start to middle and middle to end.
Shape()
Default constructor for an invalid shape.
short getOClockDelta() const
Getter for the o'clock direction difference from start to middle compared to middle to end.
short getStartToMiddleCellDistance() const
Getter for the start to middle cell distance.
Class representing a triple of neighboring wire hits.
void reverse()
Reverses the triple inplace.
CDCRLWireHitTriple()=default
Default constructor for ROOT.
const CDCWire & getStartWire() const
Getter for the wire the first oriented wire hit is based on.
const CDCWire & getMiddleWire() const
Getter for the wire the second oriented wire hit is based on.
void setEndRLWireHit(const CDCRLWireHit &endRLWireHit)
Setter for the third oriented wire hit.
CDCRLWireHit & getStartRLWireHit()
Getter for the first oriented wire hit.
void setMiddleRLWireHit(const CDCRLWireHit &middleRLWireHit)
Setter for the second oriented wire hit.
CDCRLWireHitTriple reversed() const
Constructs the reverse triple from this one.
CDCRLWireHitPair m_rearRLWireHitPair
Memory for the second and third wire hits.
int getICluster() const
Getter for the cluster id.
const CDCWire & getEndWire() const
Getter for the wire the third oriented wire hit is based on.
Shape getShape() const
Getter for the shape of this triple if all three oriented wire hits are neighbors....
CDCRLWireHit & getEndRLWireHit()
Getter for the third oriented wire hit.
CDCRLWireHit & getMiddleRLWireHit()
Getter for the second oriented wire hit.
CDCRLWireHit m_startRLWireHit
Memory for the start oriented wire hit.
CDCRLWireHitTriple getAlias() const
Returns the aliased version of this oriented wire hit triple.
Class representing an oriented hit wire including a hypotheses whether the causing track passes left ...
CDCRLWireHit reversed() const
Returns the oriented wire hit with the opposite right left information.
Class representing a sense wire in the central drift chamber.
WireNeighborKind getNeighborKind(const CDCWire &wire) const
Returns gives the kind of neighborhood relation from this wire to the given wire.
Type for the neighbor relationship from one wire to another.
bool isValid() const
Check if the neighbor kind is in principle valid.
short getOClockDirection() const
Get the direction on the clock to follow to reach the neighbor.
short getCellDistance() const
Get the distance to the wire neighbor counted in number of cells.
Abstract base class for different kinds of events.