|
ATLAS Offline Software
|
Go to the documentation of this file.
6 #include <GeoModelHelpers/TransformSorter.h>
7 #include <GaudiKernel/SystemOfUnits.h>
13 #define ORDER_PROP(PROP) \
15 if (std::abs(1.*PROP - 1.*other.PROP) > tolerance) { \
16 return PROP < other.PROP; \
36 static const GeoTrf::TransformSorter trfSorter{};
44 ostr<<
"Strip -- number: "<<
numStrips()<<
", ";
60 if (std::abs(sAngle) < std::numeric_limits<float>::epsilon())
return;
63 m_etaToStereo = Eigen::Rotation2D{sAngle};
64 m_stereoToEta = Eigen::Rotation2D{-sAngle};
78 m_lenSlopEdge = std::hypot(2.*HalfHeight, HalfShortY - HalfLongY);
83 double HalfHeight,
double yCutout) {
85 double HalfLongYuncut = HalfLongY +
yCutout * (HalfLongY - HalfShortY)/(2*HalfHeight -
yCutout);
93 ATH_MSG_WARNING(
"It's impossible to flip a trapezoid twice. Swap short and long lengths");
108 const double stripPitch,
109 const double stripWidth,
111 const int numFirst) {
const Amg::Vector2D & cornerTopLeft() const
Returns the top left corner of the trapezoid.
double m_cutLongEdge
Lenght of the line segment that's cut from the long edge to make the trapezoid diamond shaped.
double stereoAngle() const
Returns the value of the stereo angle.
double m_lenSlopEdge
Length of the edge connecting the short with the long egde.
int m_channelShift
Shift between the 0-th readout channel and the first strip described by the panel.
bool isFlipped() const
Returns whether the trapezoid is flipped.
void defineStripLayout(Amg::Vector2D &&posFirst, const double stripPitch, const double stripWidth, const int numStrips, const int numFirst=1)
Defines the layout of the strip detector by specifing the position of the first strip w....
double m_shortHalfY
Trapezoid dimensions.
const Amg::Vector2D & cornerBotLeft() const
Returns the bottom left corner of the trapezoid.
void setStereoAngle(double stereo)
double m_stereoAngle
Stereo angle of the strip design.
Eigen::Matrix< double, 2, 1 > Vector2D
virtual int numStrips() const
Number of strips on the panel.
void defineDiamond(double HalfShortY, double HalfLongY, double HalfHeight, double yCutout)
Defines the edges of the sTGC diamond L3 sector.
CxxUtils::CachedUniquePtr< Amg::Vector2D > m_dirRightEdge
Vector describing the right edge of the trapezoid (bottom right -> top right)
Amg::Vector2D m_stripNormal
Vector pointing from strip N to the next strip.
Amg::Vector2D m_topLeft
Top right point of the trapezoid.
double m_stripPitch
Distance between 2 adjacent strip centers.
double longHalfHeight() const
Returns the longer half height of the panel.
Amg::Vector2D m_bottomRight
Bottom right point of the trapezoid.
double shortHalfHeight() const
Returns the shorter half height of the panel.
Amg::Vector2D m_firstStripPos
First strip position.
std::string toString(const Translation3D &translation, int precision=4)
GeoPrimitvesToStringConverter.
The ReadoutGeomCnvAlg converts the Run4 Readout geometry build from the GeoModelXML into the legacy M...
CxxUtils::CachedUniquePtr< Amg::Vector2D > m_dirLeftEdge
Vector describing the left adge of the trapezoid (bottom left -> top left)
double yCutout() const
Returns the cutout of the diamond.
double m_yCutout
Stores the diamond cutout length from the SQLite DB file.
double stripWidth() const
Width of a strip.
Class to provide easy MsgStream access and capabilities.
void defineTrapezoid(double HalfShortY, double HalfLongY, double HalfHeight)
Defines the edges of the trapezoid.
int firstStripNumber() const
Returns the number of the first strip.
const Amg::Vector2D & cornerTopRight() const
Returns the top right corner of the trapezoid.
void flipTrapezoid()
Flips the edges of the trapezoid boundaries by 90 degrees clockwise.
CheckVector2D center(int stripNumb) const
Returns the bisector of the strip (Global numbering scheme)
CxxUtils::CachedUniquePtr< Amg::Vector2D > m_dirBotEdge
Vector describing the bottom edge of the trapezoid (bottom left -> bottom right)
bool m_hasStereo
Flag telling whether the strip design has a stereo angle or not.
virtual void print(std::ostream &ostr) const
Dump properties to the ostr.
bool operator<(const MdtTubeLayer::CutTubes &a, const unsigned int tube)
double m_stripWidth
Width of each strip line.
double halfWidth() const
Returns the half height of the strip panel.
bool m_isFlipped
Flag telling whether the trapezoid has been flipped.
CxxUtils::CachedUniquePtr< Amg::Vector2D > m_dirTopEdge
Vector describing the top edge of the trapzoid (top left -> top right)
const Amg::Vector2D & cornerBotRight() const
Returns the bottom right corner of the trapezoid.
void resetDirCache()
Resets the cache of the directions.
Amg::Vector2D m_bottomLeft
Bottom left point of the trapezoid.
#define ATH_MSG_WARNING(x)
Amg::Vector2D m_stripDir
Orientiation of the strips along the panel.
bool hasStereoAngle() const
Returns whether a stereo angle is defined.
#define ORDER_PROP(PROP)
Helper macro to facilliate the ordering.
double stripPitch() const
Distance between two adjacent strips.
std::ostream & operator<<(std::ostream &ostr, const Chamber::defineArgs &args)
Amg::Vector2D m_topRight
Bottom right point of the trapezoid.
int m_numStrips
Number of all strips.
bool operator<(const StripDesign &other) const
Odering operator.