ATLAS Offline Software
Loading...
Searching...
No Matches
RegSelModule Class Reference

#include <RegSelModule.h>

Inheritance diagram for RegSelModule:
Collaboration diagram for RegSelModule:

Public Member Functions

 RegSelModule ()
 RegSelModule (double zmin, double zmax, double rmin, double rmax, double phimin, double phimax, int layer, int detector, uint32_t robid=0, IdentifierHash hashid=0)
 constructor for a rectangular detector element for backwards compatability
 RegSelModule (double zmin, double zmax, double z2min, double z2max, double rmin, double rmax, double phimin, double phimax, int layer, int detector, uint32_t robid=0, IdentifierHash hashid=0)
 constructor for new trapezoidal detector elements
bool inRoI (const RegSelRoI &roi) const
double phiMin () const
double phiMax () const
double phiWidth () const
int layer () const
int detector () const
uint32_t robID () const
IdentifierHash hashID () const
double rMin () const
double rMin (double rmin)
double rMax () const
double rMax (double rmax)
double zMin () const
double zMin (double zmin)
double zMax () const
double zMax (double zmax)
double z2Min () const
double z2Min (double zmin)
double z2Max () const
double z2Max (double zmax)
bool enabled () const
bool enable ()
bool disable ()
double _etaMin (double z=0) const
double _etaMax (double z=0) const

Protected Attributes

double m_rMin
double m_rMax
double m_zMin
double m_zMax
double m_z2Min
double m_z2Max
bool m_enabled

Private Attributes

double m_phiMin
double m_phiMax
int m_layer
int m_detector
uint32_t m_robID
IdentifierHash m_hashID

Detailed Description

Definition at line 38 of file RegSelModule.h.

Constructor & Destructor Documentation

◆ RegSelModule() [1/3]

RegSelModule::RegSelModule ( )

Definition at line 31 of file RegSelModule.cxx.

31 :
32 ZRObject( 0, 0, 0, 0 ),
33 m_phiMin(0), m_phiMax(0),
34 m_layer(0), m_detector(0),
35 m_robID(0), m_hashID(0) { }
IdentifierHash m_hashID
uint32_t m_robID
ZRObject()
Definition ZRObject.h:45

◆ RegSelModule() [2/3]

RegSelModule::RegSelModule ( double zmin,
double zmax,
double rmin,
double rmax,
double phimin,
double phimax,
int layer,
int detector,
uint32_t robid = 0,
IdentifierHash hashid = 0 )

constructor for a rectangular detector element for backwards compatability

Definition at line 39 of file RegSelModule.cxx.

45 :
46 // ZRObject( std::sqrt(rmin), std::sqrt(rmax), // zmin, zmax ),
47 // ( zmin<0 ? -1 : 1 )*std::sqrt(std::fabs(zmin)),
48 // ( zmax<0 ? -1 : 1 )*std::sqrt(std::fabs(zmax)) ),
49 // ZRObject( std::log10(rmin)-1.6, std::log10(rmax)-1.6, // zmin, zmax ),
50 // ( zmin<0 ? -1 : 1 )*std::log10(std::fabs(zmin)),
51 // ( zmax<0 ? -1 : 1 )*std::log10(std::fabs(zmax)) ),
52 ZRObject( rmin, rmax, zmin, zmax ),
53 m_phiMin(phimin), m_phiMax(phimax),
55 m_robID(robid), m_hashID(hashid)
56{
57 while ( m_phiMax> M_PI ) m_phiMax-=2*M_PI;
58 while ( m_phiMax<-M_PI ) m_phiMax+=2*M_PI;
59 while ( m_phiMin> M_PI ) m_phiMin-=2*M_PI;
60 while ( m_phiMin<-M_PI ) m_phiMin+=2*M_PI;
61 // std::cout << "RegSelModule() " << *this << std::endl;
62}
#define M_PI
int detector() const
int layer() const

◆ RegSelModule() [3/3]

RegSelModule::RegSelModule ( double zmin,
double zmax,
double z2min,
double z2max,
double rmin,
double rmax,
double phimin,
double phimax,
int layer,
int detector,
uint32_t robid = 0,
IdentifierHash hashid = 0 )

constructor for new trapezoidal detector elements

Definition at line 67 of file RegSelModule.cxx.

74 :
75 // ZRObject( std::sqrt(rmin), std::sqrt(rmax), // zmin, zmax ),
76 // ( zmin<0 ? -1 : 1 )*std::sqrt(std::fabs(zmin)),
77 // ( zmax<0 ? -1 : 1 )*std::sqrt(std::fabs(zmax)) ),
78 // ZRObject( std::log10(rmin)-1.6, std::log10(rmax)-1.6, // zmin, zmax ),
79 // ( zmin<0 ? -1 : 1 )*std::log10(std::fabs(zmin)),
80 // ( zmax<0 ? -1 : 1 )*std::log10(std::fabs(zmax)) ),
81 ZRObject( rmin, rmax, zmin, zmax, z2min, z2max ),
82 m_phiMin(phimin), m_phiMax(phimax),
84 m_robID(robid), m_hashID(hashid)
85{
86 while ( m_phiMax> M_PI ) m_phiMax-=2*M_PI;
87 while ( m_phiMax<-M_PI ) m_phiMax+=2*M_PI;
88 while ( m_phiMin> M_PI ) m_phiMin-=2*M_PI;
89 while ( m_phiMin<-M_PI ) m_phiMin+=2*M_PI;
90 // std::cout << "RegSelModule() " << *this << std::endl;
91}

Member Function Documentation

◆ _etaMax()

double ZRObject::_etaMax ( double z = 0) const
inlineinherited

Definition at line 109 of file ZRObject.h.

109 {
110 double eta1 = calceta( rMin(), zMax()-z);
111 double eta2 = calceta( rMax(), z2Max()-z);
112 if ( eta1>eta2 ) return eta1;
113 else return eta2;
114 }
#define z
double calceta(double r, double z)
Definition ZRObject.h:33
double rMax() const
Definition ZRObject.h:81
double rMin() const
Definition ZRObject.h:80
double zMax() const
Definition ZRObject.h:84
double z2Max() const
Definition ZRObject.h:87
setEt setPhi setE277 setWeta2 eta1

◆ _etaMin()

double ZRObject::_etaMin ( double z = 0) const
inlineinherited

Definition at line 102 of file ZRObject.h.

102 {
103 double eta1 = calceta( rMin(), zMin()-z);
104 double eta2 = calceta( rMax(), z2Min()-z);
105 if ( eta1<eta2 ) return eta1;
106 else return eta2;
107 }
double z2Min() const
Definition ZRObject.h:86
double zMin() const
Definition ZRObject.h:83

◆ detector()

int RegSelModule::detector ( ) const
inline

Definition at line 112 of file RegSelModule.h.

112{ return m_detector; }

◆ disable()

bool ZRObject::disable ( )
inlineinherited

Definition at line 100 of file ZRObject.h.

100{ return m_enabled=false; }
bool m_enabled
Definition ZRObject.h:122

◆ enable()

bool ZRObject::enable ( )
inlineinherited

Definition at line 99 of file ZRObject.h.

99{ return m_enabled=true; }

◆ enabled()

bool ZRObject::enabled ( ) const
inlineinherited

Definition at line 98 of file ZRObject.h.

98{ return m_enabled; }

◆ hashID()

IdentifierHash RegSelModule::hashID ( ) const
inline

Definition at line 115 of file RegSelModule.h.

115{ return m_hashID; }

◆ inRoI()

bool RegSelModule::inRoI ( const RegSelRoI & roi) const
inlinevirtual

Reimplemented from ZRObject.

Definition at line 80 of file RegSelModule.h.

80 {
81 if ( roi.getsplit() ) { // roi is split across pi
82 if ( phiMin()>phiMax() ) return ZRObject::inRoI(roi); // module is also split
83 else { // module isn't split
84 if ( ( phiMin()<=M_PI && phiMax()>roi.getphiMin() ) ||
85 ( phiMin()<=roi.getphiMax() && phiMax()>=-M_PI ) ) return ZRObject::inRoI(roi);
86 }
87 }
88 else { // roi is not split
89 if ( phiMin()<phiMax() ) { // module is not split
90 if ( phiMin()<=roi.getphiMax() && phiMax()>=roi.getphiMin() ) return ZRObject::inRoI(roi);
91 }
92 else // module is split NB notice the || rather than the && when not split
93 if ( phiMin()<=roi.getphiMax() || phiMax()>=roi.getphiMin() ) return ZRObject::inRoI(roi);
94 }
95 return false;
96 }
double phiMin() const
double phiMax() const
bool getsplit() const
Definition RegSelRoI.h:52
double getphiMin() const
Definition RegSelRoI.h:46
double getphiMax() const
Definition RegSelRoI.h:47
virtual bool inRoI(const RegSelRoI &roi) const
Definition ZRObject.h:71

◆ layer()

int RegSelModule::layer ( ) const
inline

Definition at line 111 of file RegSelModule.h.

111{ return m_layer; }

◆ phiMax()

double RegSelModule::phiMax ( ) const
inline

Definition at line 101 of file RegSelModule.h.

101{ return m_phiMax; }

◆ phiMin()

double RegSelModule::phiMin ( ) const
inline

Definition at line 100 of file RegSelModule.h.

100{ return m_phiMin; }

◆ phiWidth()

double RegSelModule::phiWidth ( ) const
inline

Definition at line 103 of file RegSelModule.h.

103 {
105 }

◆ rMax() [1/2]

double ZRObject::rMax ( ) const
inlineinherited

Definition at line 81 of file ZRObject.h.

81{ return m_rMax; }
double m_rMax
Definition ZRObject.h:118

◆ rMax() [2/2]

double ZRObject::rMax ( double rmax)
inlineinherited

Definition at line 90 of file ZRObject.h.

90{ m_rMax = rmax; return m_rMax; }

◆ rMin() [1/2]

double ZRObject::rMin ( ) const
inlineinherited

Definition at line 80 of file ZRObject.h.

80{ return m_rMin; }
double m_rMin
Definition ZRObject.h:118

◆ rMin() [2/2]

double ZRObject::rMin ( double rmin)
inlineinherited

Definition at line 89 of file ZRObject.h.

89{ m_rMin = rmin; return m_rMin; }

◆ robID()

uint32_t RegSelModule::robID ( ) const
inline

Definition at line 114 of file RegSelModule.h.

114{ return m_robID; }

◆ z2Max() [1/2]

double ZRObject::z2Max ( ) const
inlineinherited

Definition at line 87 of file ZRObject.h.

87{ return m_z2Max; }
double m_z2Max
Definition ZRObject.h:120

◆ z2Max() [2/2]

double ZRObject::z2Max ( double zmax)
inlineinherited

Definition at line 96 of file ZRObject.h.

◆ z2Min() [1/2]

double ZRObject::z2Min ( ) const
inlineinherited

Definition at line 86 of file ZRObject.h.

86{ return m_z2Min; }
double m_z2Min
Definition ZRObject.h:120

◆ z2Min() [2/2]

double ZRObject::z2Min ( double zmin)
inlineinherited

Definition at line 95 of file ZRObject.h.

◆ zMax() [1/2]

double ZRObject::zMax ( ) const
inlineinherited

Definition at line 84 of file ZRObject.h.

84{ return m_zMax; }
double m_zMax
Definition ZRObject.h:119

◆ zMax() [2/2]

double ZRObject::zMax ( double zmax)
inlineinherited

Definition at line 93 of file ZRObject.h.

93{ m_zMax = zmax; return m_zMax; }

◆ zMin() [1/2]

double ZRObject::zMin ( ) const
inlineinherited

Definition at line 83 of file ZRObject.h.

83{ return m_zMin; }
double m_zMin
Definition ZRObject.h:119

◆ zMin() [2/2]

double ZRObject::zMin ( double zmin)
inlineinherited

Definition at line 92 of file ZRObject.h.

92{ m_zMin = zmin; return m_zMin; }

Member Data Documentation

◆ m_detector

int RegSelModule::m_detector
private

Definition at line 123 of file RegSelModule.h.

◆ m_enabled

bool ZRObject::m_enabled
protectedinherited

Definition at line 122 of file ZRObject.h.

◆ m_hashID

IdentifierHash RegSelModule::m_hashID
private

Definition at line 126 of file RegSelModule.h.

◆ m_layer

int RegSelModule::m_layer
private

Definition at line 122 of file RegSelModule.h.

◆ m_phiMax

double RegSelModule::m_phiMax
private

Definition at line 119 of file RegSelModule.h.

◆ m_phiMin

double RegSelModule::m_phiMin
private

Definition at line 119 of file RegSelModule.h.

◆ m_rMax

double ZRObject::m_rMax
protectedinherited

Definition at line 118 of file ZRObject.h.

◆ m_rMin

double ZRObject::m_rMin
protectedinherited

Definition at line 118 of file ZRObject.h.

◆ m_robID

uint32_t RegSelModule::m_robID
private

Definition at line 125 of file RegSelModule.h.

◆ m_z2Max

double ZRObject::m_z2Max
protectedinherited

Definition at line 120 of file ZRObject.h.

◆ m_z2Min

double ZRObject::m_z2Min
protectedinherited

Definition at line 120 of file ZRObject.h.

◆ m_zMax

double ZRObject::m_zMax
protectedinherited

Definition at line 119 of file ZRObject.h.

◆ m_zMin

double ZRObject::m_zMin
protectedinherited

Definition at line 119 of file ZRObject.h.


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