ECCE @ EIC Software
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Acts::AnnulusBounds Class Reference

Class that implements a (potentially asymmetric) bounds with difference between surface bound center and surface coordinate center. More...

#include <acts/blob/master/Core/include/Acts/Surfaces/AnnulusBounds.hpp>

+ Inheritance diagram for Acts::AnnulusBounds:
+ Collaboration diagram for Acts::AnnulusBounds:

Public Types

enum  BoundValues : int {
  eMinR = 0, eMaxR = 1, eMinPhiRel = 2, eMaxPhiRel = 3,
  eAveragePhi = 4, eOriginX = 5, eOriginY = 6, eSize = 7
}
 
using Transform2D = Eigen::Affine2d
 

Public Member Functions

 AnnulusBounds ()=delete
 
 AnnulusBounds (double minR, double maxR, double minPhiRel, double maxPhiRel, const Vector2D &moduleOrigin={0, 0}, double avgPhi=0) noexcept(false)
 Default constructor from parameters.
 
 AnnulusBounds (const AnnulusBounds &source)=default
 
SurfaceBounds::BoundsType type () const final
 
std::vector< double > values () const final
 
virtual bool inside (const Vector2D &lposition, const BoundaryCheck &bcheck) const final
 
virtual double distanceToBoundary (const Vector2D &lposition) const final
 
std::ostream & toStream (std::ostream &sl) const final
 
double get (BoundValues bValue) const
 
double phiMin () const
 Returns the right angular edge of the module.
 
double phiMax () const
 Returns the left angular edge of the module.
 
bool coversFullAzimuth () const final
 Returns true for full phi coverage.
 
bool insideRadialBounds (double R, double tolerance=0.) const final
 
double binningValueR () const final
 Return a reference radius for binning.
 
double binningValuePhi () const final
 Return a reference radius for binning.
 
Vector2D moduleOrigin () const
 Returns moduleOrigin, but rotated out, so averagePhi is already considered. The module origin needs to consider the rotation introduced by averagePhi.
 
std::vector< Vector2Dcorners () const
 
std::vector< Vector2Dvertices (unsigned int lseg) const
 
double rMin () const final
 This method returns inner radius.
 
double rMax () const final
 This method returns outer radius.
 

Private Member Functions

void checkConsistency () noexcept(false)
 
virtual bool inside (const Vector2D &lposition, double tolR, double tolPhi) const final
 
Vector2D stripXYToModulePC (const Vector2D &vStripXY) const
 
Vector2D closestOnSegment (const Vector2D &a, const Vector2D &b, const Vector2D &p, const Eigen::Matrix< double, 2, 2 > &weight) const
 Private helper method.
 
double squaredNorm (const Vector2D &v, const Eigen::Matrix< double, 2, 2 > &weight) const
 Private helper mehtod.
 

Private Attributes

std::array< double, eSizem_values
 
Vector2D m_moduleOrigin
 
Vector2D m_shiftXY
 
Vector2D m_shiftPC
 
double m_phiAvg
 
Transform2D m_rotationStripPC
 
Transform2D m_translation
 
Vector2D m_outLeftStripPC
 
Vector2D m_inLeftStripPC
 
Vector2D m_outRightStripPC
 
Vector2D m_inRightStripPC
 
Vector2D m_outLeftModulePC
 
Vector2D m_inLeftModulePC
 
Vector2D m_outRightModulePC
 
Vector2D m_inRightModulePC
 
Vector2D m_outLeftStripXY
 
Vector2D m_inLeftStripXY
 
Vector2D m_outRightStripXY
 
Vector2D m_inRightStripXY
 

Detailed Description

Class that implements a (potentially asymmetric) bounds with difference between surface bound center and surface coordinate center.

These bounds combine two different systems:

  • module system : radial bounds centred on the moduleOrigin
  • strip system : phi bounds centred on the stripOrigin

The measurement will be done in the strip system, with r/phi local coordinates.

Definition at line 32 of file AnnulusBounds.hpp.

View newest version in sPHENIX GitHub at line 32 of file AnnulusBounds.hpp

Member Typedef Documentation

using Acts::AnnulusBounds::Transform2D = Eigen::Affine2d

Definition at line 34 of file AnnulusBounds.hpp.

View newest version in sPHENIX GitHub at line 34 of file AnnulusBounds.hpp

Member Enumeration Documentation

Enumerator:
eMinR 
eMaxR 
eMinPhiRel 
eMaxPhiRel 
eAveragePhi 
eOriginX 
eOriginY 
eSize 

Definition at line 36 of file AnnulusBounds.hpp.

View newest version in sPHENIX GitHub at line 36 of file AnnulusBounds.hpp

Constructor & Destructor Documentation

Acts::AnnulusBounds::AnnulusBounds ( )
delete
Acts::AnnulusBounds::AnnulusBounds ( double  minR,
double  maxR,
double  minPhiRel,
double  maxPhiRel,
const Vector2D moduleOrigin = {0, 0},
double  avgPhi = 0 
)
inlinenoexcept

Default constructor from parameters.

Parameters
minRinner radius, in module system
maxRouter radius, in module system
minPhiRelright angular edge, in strip system, rel to avgOhi
maxPhiRelleft angular edge, in strip system, rel to avgPhi
moduleOriginThe origin offset between the two systems.
avgPhi(Optional) internal rotation of this bounds object's local frame
Note
For morigin you need to actually calculate the cartesian offset

Definition at line 59 of file AnnulusBounds.hpp.

View newest version in sPHENIX GitHub at line 59 of file AnnulusBounds.hpp

Acts::AnnulusBounds::AnnulusBounds ( const AnnulusBounds source)
default

Member Function Documentation

double Acts::AnnulusBounds::binningValuePhi ( ) const
inlinefinalvirtual

Return a reference radius for binning.

Implements Acts::DiscBounds.

Definition at line 251 of file AnnulusBounds.hpp.

View newest version in sPHENIX GitHub at line 251 of file AnnulusBounds.hpp

References eAveragePhi.

double Acts::AnnulusBounds::binningValueR ( ) const
inlinefinalvirtual

Return a reference radius for binning.

Implements Acts::DiscBounds.

Definition at line 247 of file AnnulusBounds.hpp.

View newest version in sPHENIX GitHub at line 247 of file AnnulusBounds.hpp

References eMaxR, and eMinR.

void Acts::AnnulusBounds::checkConsistency ( )
inlineprivatenoexcept

Check the input values for consistency, will throw a logic_exception if consistency is not given

Definition at line 261 of file AnnulusBounds.hpp.

View newest version in sPHENIX GitHub at line 261 of file AnnulusBounds.hpp

References kdfinder::abs(), eAveragePhi, eMaxPhiRel, eMaxR, eMinPhiRel, eMinR, Acts::detail::radian_sym(), and Acts::s_epsilon.

+ Here is the call graph for this function:

Acts::Vector2D Acts::AnnulusBounds::closestOnSegment ( const Vector2D a,
const Vector2D b,
const Vector2D p,
const Eigen::Matrix< double, 2, 2 > &  weight 
) const
private

Private helper method.

Definition at line 418 of file AnnulusBounds.cpp.

View newest version in sPHENIX GitHub at line 418 of file AnnulusBounds.cpp

References a, f, max, min, n, and Acts::UnitConstants::u.

std::vector< Acts::Vector2D > Acts::AnnulusBounds::corners ( ) const

This method returns the four corners of the bounds in polar coordinates 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)

Definition at line 89 of file AnnulusBounds.cpp.

View newest version in sPHENIX GitHub at line 89 of file AnnulusBounds.cpp

References m_inLeftStripPC, m_inRightStripPC, m_outLeftStripPC, m_outRightStripPC, and m_rotationStripPC.

bool Acts::AnnulusBounds::coversFullAzimuth ( ) const
inlinefinalvirtual

Returns true for full phi coverage.

Implements Acts::DiscBounds.

Definition at line 237 of file AnnulusBounds.hpp.

View newest version in sPHENIX GitHub at line 237 of file AnnulusBounds.hpp

References kdfinder::abs(), eMaxPhiRel, eMinPhiRel, M_PI, and Acts::s_onSurfaceTolerance.

+ Here is the call graph for this function:

double Acts::AnnulusBounds::distanceToBoundary ( const Vector2D lposition) const
finalvirtual

Minimal distance to boundary ( > 0 if outside and <=0 if inside)

Parameters
lpositionis the local position to check for the distance
Returns
is a signed distance parameter

Implements Acts::SurfaceBounds.

Definition at line 325 of file AnnulusBounds.cpp.

View newest version in sPHENIX GitHub at line 325 of file AnnulusBounds.cpp

References kdfinder::abs(), Acts::eLOC_PHI, Acts::eLOC_R, m_inLeftModulePC, m_inLeftStripXY, m_inRightModulePC, m_inRightStripXY, m_outLeftStripXY, m_outRightStripXY, m_rotationStripPC, m_shiftXY, max, norm, Acts::VectorHelpers::phi(), and weight.

+ Here is the call graph for this function:

double Acts::AnnulusBounds::get ( BoundValues  bValue) const
inline

Access to the bound values

Parameters
bValuethe class nested enum for the array access

Definition at line 102 of file AnnulusBounds.hpp.

View newest version in sPHENIX GitHub at line 102 of file AnnulusBounds.hpp

References m_values.

Referenced by Acts::Test::BOOST_AUTO_TEST_CASE(), and Acts::JsonGeometryConverter::DefaultBin().

+ Here is the caller graph for this function:

bool Acts::AnnulusBounds::inside ( const Vector2D lposition,
const BoundaryCheck bcheck 
) const
finalvirtual

Inside check for the bounds object driven by the boundary check directive Each Bounds has a method inside, which checks if a LocalPosition is inside the bounds Inside can be called without/with tolerances.

Parameters
lpositionLocal position (assumed to be in right surface frame)
bcheckboundary check directive
Returns
boolean indicator for the success of this operation

Implements Acts::SurfaceBounds.

Definition at line 165 of file AnnulusBounds.cpp.

View newest version in sPHENIX GitHub at line 165 of file AnnulusBounds.cpp

References A(), B(), C(), Acts::BoundaryCheck::covariance(), Acts::eLOC_PHI, Acts::eLOC_R, Acts::eLOC_X, Acts::eLOC_Y, m_inLeftModulePC, m_inLeftStripPC, m_inRightModulePC, m_inRightStripPC, m_outLeftModulePC, m_outLeftStripPC, m_outRightModulePC, m_outRightStripPC, m_rotationStripPC, m_shiftXY, max, Acts::BoundaryCheck::tolerance(), and Acts::BoundaryCheck::type().

Referenced by Acts::Test::BOOST_AUTO_TEST_CASE().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

bool Acts::AnnulusBounds::inside ( const Vector2D lposition,
double  tolR,
double  tolPhi 
) const
finalprivatevirtual

Inside check for the bounds object driven by the boundary check directive Each Bounds has a method inside, which checks if a LocalPosition is inside the bounds Inside can be called without/with tolerances.

Parameters
lpositionLocal position (assumed to be in right surface frame)
tolRtolerance on the radius
tolPhitolerance on the polar angle phi
Returns
boolean indicator for the success of this operation

Definition at line 129 of file AnnulusBounds.cpp.

View newest version in sPHENIX GitHub at line 129 of file AnnulusBounds.cpp

References Acts::eLOC_PHI, Acts::eLOC_R, m_rotationStripPC, and m_shiftPC.

bool Acts::AnnulusBounds::insideRadialBounds ( double  R,
double  tolerance = 0. 
) const
inlinefinalvirtual

Checks if this is inside the radial coverage given the a tolerance

Implements Acts::DiscBounds.

Definition at line 242 of file AnnulusBounds.hpp.

View newest version in sPHENIX GitHub at line 242 of file AnnulusBounds.hpp

References eMaxR, and eMinR.

Referenced by Acts::Test::BOOST_AUTO_TEST_CASE().

+ Here is the caller graph for this function:

Acts::Vector2D Acts::AnnulusBounds::moduleOrigin ( ) const

Returns moduleOrigin, but rotated out, so averagePhi is already considered. The module origin needs to consider the rotation introduced by averagePhi.

Returns
The origin of the local frame

Definition at line 436 of file AnnulusBounds.cpp.

View newest version in sPHENIX GitHub at line 436 of file AnnulusBounds.cpp

double Acts::AnnulusBounds::phiMax ( ) const
inline

Returns the left angular edge of the module.

Returns
The left side angle

Definition at line 233 of file AnnulusBounds.hpp.

View newest version in sPHENIX GitHub at line 233 of file AnnulusBounds.hpp

References eAveragePhi, and eMaxPhiRel.

Referenced by Acts::JsonGeometryConverter::addSurfaceToJson(), and Acts::ProtoLayer::measure().

+ Here is the caller graph for this function:

double Acts::AnnulusBounds::phiMin ( ) const
inline

Returns the right angular edge of the module.

Returns
The right side angle

Definition at line 229 of file AnnulusBounds.hpp.

View newest version in sPHENIX GitHub at line 229 of file AnnulusBounds.hpp

References eAveragePhi, and eMinPhiRel.

Referenced by Acts::JsonGeometryConverter::addSurfaceToJson(), and Acts::ProtoLayer::measure().

+ Here is the caller graph for this function:

double Acts::AnnulusBounds::rMax ( ) const
inlinefinalvirtual

This method returns outer radius.

Implements Acts::DiscBounds.

Definition at line 225 of file AnnulusBounds.hpp.

View newest version in sPHENIX GitHub at line 225 of file AnnulusBounds.hpp

References eMaxR.

Referenced by Acts::JsonGeometryConverter::addSurfaceToJson(), Acts::JsonGeometryConverter::DefaultBin(), and Acts::ProtoLayer::measure().

+ Here is the caller graph for this function:

double Acts::AnnulusBounds::rMin ( ) const
inlinefinalvirtual

This method returns inner radius.

Implements Acts::DiscBounds.

Definition at line 221 of file AnnulusBounds.hpp.

View newest version in sPHENIX GitHub at line 221 of file AnnulusBounds.hpp

References eMinR.

Referenced by Acts::JsonGeometryConverter::addSurfaceToJson(), Acts::JsonGeometryConverter::DefaultBin(), and Acts::ProtoLayer::measure().

+ Here is the caller graph for this function:

double Acts::AnnulusBounds::squaredNorm ( const Vector2D v,
const Eigen::Matrix< double, 2, 2 > &  weight 
) const
private

Private helper mehtod.

Definition at line 431 of file AnnulusBounds.cpp.

View newest version in sPHENIX GitHub at line 431 of file AnnulusBounds.cpp

References v.

Acts::Vector2D Acts::AnnulusBounds::stripXYToModulePC ( const Vector2D vStripXY) const
private

Transform the strip cartesien into the module polar system

Parameters
vStripXythe position in the cartesian strip system
Returns
the poistion in the module polar coordiante system

Definition at line 412 of file AnnulusBounds.cpp.

View newest version in sPHENIX GitHub at line 412 of file AnnulusBounds.cpp

References m_shiftXY, and Acts::VectorHelpers::phi().

+ Here is the call graph for this function:

std::ostream & Acts::AnnulusBounds::toStream ( std::ostream &  sl) const
finalvirtual

Outstream operator

Parameters
slis the ostream to be dumped into

Implements Acts::SurfaceBounds.

Definition at line 441 of file AnnulusBounds.cpp.

View newest version in sPHENIX GitHub at line 441 of file AnnulusBounds.cpp

References m_shiftPC, m_shiftXY, and Acts::Test::phiMin.

SurfaceBounds::BoundsType Acts::AnnulusBounds::type ( ) const
inlinefinalvirtual

Return the bounds type - for persistency optimization

Returns
is a BoundsType enum

Implements Acts::SurfaceBounds.

Definition at line 217 of file AnnulusBounds.hpp.

View newest version in sPHENIX GitHub at line 217 of file AnnulusBounds.hpp

References Acts::SurfaceBounds::eAnnulus.

Referenced by Acts::Test::BOOST_AUTO_TEST_CASE().

+ Here is the caller graph for this function:

std::vector< double > Acts::AnnulusBounds::values ( ) const
inlinefinalvirtual

Return the bound values as dynamically sized vector

Returns
this returns a copy of the internal values

Implements Acts::SurfaceBounds.

Definition at line 255 of file AnnulusBounds.hpp.

View newest version in sPHENIX GitHub at line 255 of file AnnulusBounds.hpp

References m_values.

std::vector< Acts::Vector2D > Acts::AnnulusBounds::vertices ( unsigned int  lseg) const
virtual

This method returns the xy coordinates of the four corners of the bounds in module coorindates (in x/y) 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)

Parameters
lsegthe number of segments used to approximate and eventually curved line
Note
that the extremas are given, which may slightly alter the number of segments returned
Returns
vector for vertices in 2D

Implements Acts::DiscBounds.

Definition at line 96 of file AnnulusBounds.cpp.

View newest version in sPHENIX GitHub at line 96 of file AnnulusBounds.cpp

References m_inLeftStripXY, m_inRightStripXY, m_outLeftStripXY, m_outRightStripXY, Acts::VectorHelpers::phi(), and Acts::detail::VerticesHelper::phiSegments().

+ Here is the call graph for this function:

Member Data Documentation

Vector2D Acts::AnnulusBounds::m_inLeftModulePC
private

Definition at line 176 of file AnnulusBounds.hpp.

View newest version in sPHENIX GitHub at line 176 of file AnnulusBounds.hpp

Vector2D Acts::AnnulusBounds::m_inLeftStripPC
private

Definition at line 171 of file AnnulusBounds.hpp.

View newest version in sPHENIX GitHub at line 171 of file AnnulusBounds.hpp

Referenced by corners().

Vector2D Acts::AnnulusBounds::m_inLeftStripXY
private

Definition at line 181 of file AnnulusBounds.hpp.

View newest version in sPHENIX GitHub at line 181 of file AnnulusBounds.hpp

Vector2D Acts::AnnulusBounds::m_inRightModulePC
private

Definition at line 178 of file AnnulusBounds.hpp.

View newest version in sPHENIX GitHub at line 178 of file AnnulusBounds.hpp

Vector2D Acts::AnnulusBounds::m_inRightStripPC
private

Definition at line 173 of file AnnulusBounds.hpp.

View newest version in sPHENIX GitHub at line 173 of file AnnulusBounds.hpp

Referenced by corners().

Vector2D Acts::AnnulusBounds::m_inRightStripXY
private

Definition at line 183 of file AnnulusBounds.hpp.

View newest version in sPHENIX GitHub at line 183 of file AnnulusBounds.hpp

Vector2D Acts::AnnulusBounds::m_moduleOrigin
private

Definition at line 162 of file AnnulusBounds.hpp.

View newest version in sPHENIX GitHub at line 162 of file AnnulusBounds.hpp

Vector2D Acts::AnnulusBounds::m_outLeftModulePC
private

Definition at line 175 of file AnnulusBounds.hpp.

View newest version in sPHENIX GitHub at line 175 of file AnnulusBounds.hpp

Vector2D Acts::AnnulusBounds::m_outLeftStripPC
private

Definition at line 170 of file AnnulusBounds.hpp.

View newest version in sPHENIX GitHub at line 170 of file AnnulusBounds.hpp

Referenced by corners().

Vector2D Acts::AnnulusBounds::m_outLeftStripXY
private

Definition at line 180 of file AnnulusBounds.hpp.

View newest version in sPHENIX GitHub at line 180 of file AnnulusBounds.hpp

Vector2D Acts::AnnulusBounds::m_outRightModulePC
private

Definition at line 177 of file AnnulusBounds.hpp.

View newest version in sPHENIX GitHub at line 177 of file AnnulusBounds.hpp

Vector2D Acts::AnnulusBounds::m_outRightStripPC
private

Definition at line 172 of file AnnulusBounds.hpp.

View newest version in sPHENIX GitHub at line 172 of file AnnulusBounds.hpp

Referenced by corners().

Vector2D Acts::AnnulusBounds::m_outRightStripXY
private

Definition at line 182 of file AnnulusBounds.hpp.

View newest version in sPHENIX GitHub at line 182 of file AnnulusBounds.hpp

double Acts::AnnulusBounds::m_phiAvg
private

Definition at line 165 of file AnnulusBounds.hpp.

View newest version in sPHENIX GitHub at line 165 of file AnnulusBounds.hpp

Transform2D Acts::AnnulusBounds::m_rotationStripPC
private

Definition at line 166 of file AnnulusBounds.hpp.

View newest version in sPHENIX GitHub at line 166 of file AnnulusBounds.hpp

Referenced by corners().

Vector2D Acts::AnnulusBounds::m_shiftPC
private

Definition at line 164 of file AnnulusBounds.hpp.

View newest version in sPHENIX GitHub at line 164 of file AnnulusBounds.hpp

Vector2D Acts::AnnulusBounds::m_shiftXY
private

Definition at line 163 of file AnnulusBounds.hpp.

View newest version in sPHENIX GitHub at line 163 of file AnnulusBounds.hpp

Transform2D Acts::AnnulusBounds::m_translation
private

Definition at line 167 of file AnnulusBounds.hpp.

View newest version in sPHENIX GitHub at line 167 of file AnnulusBounds.hpp

std::array<double, eSize> Acts::AnnulusBounds::m_values
private

Definition at line 159 of file AnnulusBounds.hpp.

View newest version in sPHENIX GitHub at line 159 of file AnnulusBounds.hpp

Referenced by get(), and values().


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