![]() |
ATLAS Offline Software
|
Bounds for a annulus-like, planar Surface. More...
#include <AnnulusBounds.h>
Public Types | |
| enum | BoundValues { bv_minR = 0 , bv_maxR = 1 , bv_R = 2 , bv_phi = 3 , bv_phiS = 4 , bv_length = 5 } |
| NB bv_R is the radius of the wafer centre which may different from the assumed surface centre. More... | |
| enum | BoundsType { Cone = 0 , Cylinder = 1 , Diamond = 2 , Disc = 3 , Ellipse = 5 , Rectangle = 6 , RotatedTrapezoid = 7 , Trapezoid = 8 , Triangle = 9 , DiscTrapezoidal = 10 , Annulus = 11 , Other = 12 } |
| This enumerator simplifies the persistency, by saving a dynamic_cast to happen. More... | |
Public Member Functions | |
| AnnulusBounds () | |
| Default Constructor, needed for persistency. | |
| AnnulusBounds (double minR, double maxR, double R, double phi, double phiS) | |
| Constructor for AnnulusBounds. | |
| AnnulusBounds (const AnnulusBounds &annbo)=default | |
| Copy constructor. | |
| AnnulusBounds & | operator= (const AnnulusBounds &sbo)=default |
| Assignment operator. | |
| AnnulusBounds (AnnulusBounds &&annbo)=default | |
| Move constructor. | |
| AnnulusBounds & | operator= (AnnulusBounds &&sbo)=default |
| Move assignment. | |
| virtual | ~AnnulusBounds ()=default |
| Destructor. | |
| virtual AnnulusBounds * | clone () const override |
| Virtual constructor. | |
| virtual BoundsType | type () const override |
| Return the type of the bounds for persistency. | |
| bool | operator== (const SurfaceBounds &annbo) const override |
| Equality operator. | |
| double | minR () const |
| This method returns the smaller radius. | |
| double | maxR () const |
| This method returns the bigger radius. | |
| double | waferCentreR () const |
| This method returns the R-parameter from design of sensors, which is the radius that the original centre of a silicon wafer ends up at. | |
| double | phi () const |
| This method returns the opening angle. | |
| double | phiS () const |
| This method returns the tilt angle. | |
| std::array< std::pair< double, double >, 4 > | corners () const |
| Returns the four corners of the bounds. | |
| virtual double | r () const override |
| This method returns the maximal extension on the local plane. | |
| virtual bool | inside (const Amg::Vector2D &locpo, double tol1=0., double tol2=0.) const override final |
| This method returns the opening angle alpha in point A (negative local phi) | |
| virtual bool | inside (const Amg::Vector2D &locpo, const BoundaryCheck &bchk) const override final |
| virtual bool | insideLoc1 (const Amg::Vector2D &locpo, double tol1=0.) const override final |
| This method checks inside bounds in loc1. | |
| virtual bool | insideLoc2 (const Amg::Vector2D &locpo, double tol2=0.) const override final |
| This method checks inside bounds in loc2. | |
| virtual double | minDistance (const Amg::Vector2D &pos) const override final |
| Minimal distance to boundary ( > 0 if outside and <=0 if inside) | |
| virtual MsgStream & | dump (MsgStream &sl) const override |
| Output Method for MsgStream. | |
| virtual std::ostream & | dump (std::ostream &sl) const override |
| Output Method for std::ostream. | |
| std::array< TDD_real_t, 4 > | getEdgeLines () const |
| Returns the gradient and y-intercept of the left and right module edges. | |
| const std::vector< TDD_real_t > & | getBoundsValues () const |
| virtual bool | operator!= (const SurfaceBounds &sb) const |
| Non-Equality operator. | |
Protected Member Functions | |
| void | swap (double &b1, double &b2) |
| Swap method to be called from DiscBounds or TrapezoidalBounds. | |
| virtual void | initCache () |
| virtual initCache method for object persistency | |
Static Private Member Functions | |
| static bool | isAbove (const Amg::Vector2D &locpo, double tol1, double tol2, double x1, double y1, double x2, double y2) |
| isAbove() method for checking whether a point lies above or under a straight line | |
| static bool | isRight (const Amg::Vector2D &locpo, double tol1, double tol2, double x1, double y1, double x2, double y2) |
| static bool | isLeft (const Amg::Vector2D &locpo, double tol1, double tol2, double x1, double y1, double x2, double y2) |
| static bool | EllipseIntersectLine (const Amg::Vector2D &locpo, double h, double k, double x1, double y1, double x2, double y2) |
| static double | distanceToLine (const Amg::Vector2D &locpo, const std::vector< TDD_real_t > &P1, const std::vector< TDD_real_t > &P2) |
| Distance to line. | |
| static double | distanceToArc (const Amg::Vector2D &locpo, double R, const std::vector< TDD_real_t > &sL, const std::vector< TDD_real_t > &sR) |
| Distance to arc. | |
| static std::vector< double > | circleLineIntersection (double R, double k, double d) |
| Circle and line intersection. | |
Private Attributes | |
| std::vector< TDD_real_t > | m_boundValues |
| TDD_real_t | m_maxYout |
| TDD_real_t | m_minYout |
| TDD_real_t | m_maxXout |
| TDD_real_t | m_minXout |
| TDD_real_t | m_maxYin |
| TDD_real_t | m_minYin |
| TDD_real_t | m_maxXin |
| TDD_real_t | m_minXin |
| TDD_real_t | m_k_L |
| TDD_real_t | m_k_R |
| TDD_real_t | m_d_L |
| TDD_real_t | m_d_R |
| std::vector< TDD_real_t > | m_solution_L_min |
| std::vector< TDD_real_t > | m_solution_L_max |
| std::vector< TDD_real_t > | m_solution_R_min |
| std::vector< TDD_real_t > | m_solution_R_max |
|
inherited |
This enumerator simplifies the persistency, by saving a dynamic_cast to happen.
Other is reserved for the GeometrySurfaces implementation.
| Enumerator | |
|---|---|
| Cone | |
| Cylinder | |
| Diamond | |
| Disc | |
| Ellipse | |
| Rectangle | |
| RotatedTrapezoid | |
| Trapezoid | |
| Triangle | |
| DiscTrapezoidal | |
| Annulus | |
| Other | |
Definition at line 58 of file SurfaceBounds.h.
NB bv_R is the radius of the wafer centre which may different from the assumed surface centre.
e.g. if a single wafer/sensor/mdodule has been split into multiple surfaces
| Enumerator | |
|---|---|
| bv_minR | |
| bv_maxR | |
| bv_R | |
| bv_phi | |
| bv_phiS | |
| bv_length | |
Definition at line 51 of file AnnulusBounds.h.
| Trk::AnnulusBounds::AnnulusBounds | ( | ) |
Default Constructor, needed for persistency.
Definition at line 127 of file AnnulusBounds.cxx.
| Trk::AnnulusBounds::AnnulusBounds | ( | double | minR, |
| double | maxR, | ||
| double | R, | ||
| double | phi, | ||
| double | phiS ) |
Constructor for AnnulusBounds.
Definition at line 151 of file AnnulusBounds.cxx.
|
default |
Copy constructor.
|
default |
Move constructor.
|
virtualdefault |
Destructor.
|
staticprivate |
Circle and line intersection.
Circle is of radius R and centred at the origin. Line takes the form y = kx + d
| R | Radius of the circle |
| k | Gradient of the line |
| d | Intercept of the line |
Definition at line 461 of file AnnulusBounds.cxx.
|
overridevirtual |
Virtual constructor.
Implements Trk::SurfaceBounds.
| std::array< std::pair< double, double >, 4 > Trk::AnnulusBounds::corners | ( | ) | const |
Returns the four corners of the bounds.
Returns the module corners starting from the upper right (max R, pos locX) and proceding clock-wise, i.e. (max R; pos locX), (min R; pos locX), (min R; neg loc X), (max R; neg locX).
This method is only intended for debug purposes. If used for production code, this should be changed to a return-by-reference. This will necessitate the vector being stored in the class.
Definition at line 615 of file AnnulusBounds.cxx.
|
staticprivate |
Distance to arc.
Definition at line 533 of file AnnulusBounds.cxx.
|
staticprivate |
Distance to line.
Definition at line 500 of file AnnulusBounds.cxx.
|
overridevirtual |
Output Method for MsgStream.
Implements Trk::SurfaceBounds.
Definition at line 628 of file AnnulusBounds.cxx.
|
overridevirtual |
Output Method for std::ostream.
Implements Trk::SurfaceBounds.
Definition at line 640 of file AnnulusBounds.cxx.
|
staticprivate |
Definition at line 555 of file AnnulusBounds.cxx.
| const std::vector< TDD_real_t > & Trk::AnnulusBounds::getBoundsValues | ( | ) | const |
| std::array< TDD_real_t, 4 > Trk::AnnulusBounds::getEdgeLines | ( | ) | const |
Returns the gradient and y-intercept of the left and right module edges.
This method is only intended for debug purposes. If used for production code, this should be changed to a return-by-reference. This will necessitate the vector being stored in the class.
This method is only intended for debug purposes. If used for production code, this should be changed to a return-by-reference. This will necessitate the vector being stored in the class.
Definition at line 659 of file AnnulusBounds.cxx.
|
inlineprotectedvirtualinherited |
virtual initCache method for object persistency
Reimplemented in Trk::ConeBounds, Trk::DiamondBounds, Trk::RotatedDiamondBounds, and Trk::RotatedTrapezoidBounds.
Definition at line 129 of file SurfaceBounds.h.
|
finaloverridevirtual |
Implements Trk::SurfaceBounds.
Definition at line 248 of file AnnulusBounds.cxx.
|
finaloverridevirtual |
This method returns the opening angle alpha in point A (negative local phi)
This method returns the opening angle beta in point B (positive local phi) The orientation of the Trapezoid is according to the figure above, in words: the shorter of the two parallel sides of the trapezoid intersects with the negative \( y \) - axis of the local frame.
The cases are:
(0) \( y \) or \( x \) bounds are 0 || 0
(1) LocalPosition is outside \( y \) bounds
(2) LocalPosition is inside \( y \) bounds, but outside maximum \( x \) bounds
(3) LocalPosition is inside \( y \) bounds AND inside minimum \( x \) bounds
(4) LocalPosition is inside \( y \) bounds AND inside maximum \( x \) bounds, so that it depends on the \( eta \) coordinate (5) LocalPosition fails test of (4)
The inside check is done using single equations of straight lines and one has to take care if a point lies on the positive \( x \) half area(I) or the negative one(II). Denoting \( |x_{min}| \) and \( | x_{max} | \) as minHalfX respectively maxHalfX, such as \( | y_{H} | \) as halfY, the equations for the straing lines in (I) and (II) can be written as:
Implements Trk::SurfaceBounds.
Definition at line 210 of file AnnulusBounds.cxx.
|
finaloverridevirtual |
This method checks inside bounds in loc1.
Implements Trk::SurfaceBounds.
|
finaloverridevirtual |
This method checks inside bounds in loc2.
Implements Trk::SurfaceBounds.
|
staticprivate |
isAbove() method for checking whether a point lies above or under a straight line
Definition at line 344 of file AnnulusBounds.cxx.
|
staticprivate |
Definition at line 394 of file AnnulusBounds.cxx.
|
staticprivate |
Definition at line 364 of file AnnulusBounds.cxx.
| double Trk::AnnulusBounds::maxR | ( | ) | const |
This method returns the bigger radius.
|
finaloverridevirtual |
Minimal distance to boundary ( > 0 if outside and <=0 if inside)
Implements Trk::SurfaceBounds.
Definition at line 423 of file AnnulusBounds.cxx.
| double Trk::AnnulusBounds::minR | ( | ) | const |
This method returns the smaller radius.
|
inlinevirtualinherited |
Non-Equality operator.
Reimplemented in Trk::InvalidBounds.
Definition at line 141 of file SurfaceBounds.h.
|
default |
Move assignment.
|
default |
Assignment operator.
|
overridevirtual |
Equality operator.
Implements Trk::SurfaceBounds.
Definition at line 199 of file AnnulusBounds.cxx.
| double Trk::AnnulusBounds::phi | ( | ) | const |
This method returns the opening angle.
| double Trk::AnnulusBounds::phiS | ( | ) | const |
This method returns the tilt angle.
|
overridevirtual |
This method returns the maximal extension on the local plane.
Implements Trk::SurfaceBounds.
|
inlineprotectedinherited |
Swap method to be called from DiscBounds or TrapezoidalBounds.
Definition at line 133 of file SurfaceBounds.h.
|
inlineoverridevirtual |
Return the type of the bounds for persistency.
Implements Trk::SurfaceBounds.
Definition at line 82 of file AnnulusBounds.h.
| double Trk::AnnulusBounds::waferCentreR | ( | ) | const |
This method returns the R-parameter from design of sensors, which is the radius that the original centre of a silicon wafer ends up at.
It is therefore common to all surfaces on the same wafer and can be different from the assume surface centre
|
private |
Definition at line 224 of file AnnulusBounds.h.
|
private |
Definition at line 238 of file AnnulusBounds.h.
|
private |
Definition at line 239 of file AnnulusBounds.h.
|
private |
Definition at line 236 of file AnnulusBounds.h.
|
private |
Definition at line 237 of file AnnulusBounds.h.
|
private |
Definition at line 233 of file AnnulusBounds.h.
|
private |
Definition at line 228 of file AnnulusBounds.h.
|
private |
Definition at line 231 of file AnnulusBounds.h.
|
private |
Definition at line 226 of file AnnulusBounds.h.
|
private |
Definition at line 234 of file AnnulusBounds.h.
|
private |
Definition at line 229 of file AnnulusBounds.h.
|
private |
Definition at line 232 of file AnnulusBounds.h.
|
private |
Definition at line 227 of file AnnulusBounds.h.
|
private |
Definition at line 242 of file AnnulusBounds.h.
|
private |
Definition at line 241 of file AnnulusBounds.h.
|
private |
Definition at line 244 of file AnnulusBounds.h.
|
private |
Definition at line 243 of file AnnulusBounds.h.