ATLAS Offline Software
Public Member Functions | Static Public Member Functions | Protected Member Functions | Private Attributes | Static Private Attributes | List of all members
TCS::MuonTOB Class Reference

#include <MuonTOB.h>

Inheritance diagram for TCS::MuonTOB:
Collaboration diagram for TCS::MuonTOB:

Public Member Functions

 MuonTOB (uint32_t roiWord=0, const std::string &tobName="MuonTOB")
 
 MuonTOB (unsigned int et, unsigned int isolation, int eta, unsigned int phi, uint32_t roiWord=0, const std::string &tobName="MuonTOB")
 
 MuonTOB (const MuonTOB &muon)
 
virtual ~MuonTOB ()
 
unsigned int nBitsEt () const
 
unsigned int nBitsIsolation () const
 
unsigned int nBitsEta () const
 
unsigned int nBitsPhi () const
 
unsigned int Et () const
 
unsigned int isolation () const
 
int eta () const
 
unsigned int phi () const
 
int bw2or3 () const
 
int innerCoin () const
 
int goodMF () const
 
int charge () const
 
int is2cand () const
 
double EtDouble () const
 
double EtaDouble () const
 
double PhiDouble () const
 
bool isTGC () const
 
void setEt (unsigned int et)
 
void setIsolation (unsigned int iso)
 
void setEta (int eta)
 
void setPhi (unsigned int phi)
 
void setBW2or3 (int bw2or3)
 
void setInnerCoin (int innerCoin)
 
void setGoodMF (int goodMF)
 
void setCharge (int charge)
 
void setIs2cand (int is2cand)
 
void setIsTGC (int isTGC)
 
void setEtDouble (double et)
 
void setEtaDouble (double eta)
 
void setPhiDouble (double phi)
 
void setBitsEt (unsigned int nBitsEt)
 
void setBitsIsolation (unsigned int nBitsIsolation)
 
void setBitsEta (unsigned int nBitsEta)
 
void setBitsPhi (unsigned int nBitsPhi)
 
inputTOBType_t tobType () const
 
virtual void print (std::ostream &o) const
 
uint32_t roiWord () const
 
const std::string & tobName () const
 

Static Public Member Functions

static MuonTOBcreateOnHeap (const MuonTOB &cl)
 
static void clearHeap ()
 
static const Heap< TCS::MuonTOB > & heap ()
 
static size_t instances ()
 

Protected Member Functions

int sizeCheck (int value, unsigned int size) const
 
unsigned int sizeCheck (unsigned int value, unsigned int size) const
 
int sizeCheckM (int value, unsigned int size) const
 

Private Attributes

unsigned int m_nBitsEt {13}
 
unsigned int m_nBitsIsolation {5}
 
unsigned int m_nBitsEta {9}
 
unsigned int m_nBitsPhi {7}
 
unsigned int m_Et {0}
 
unsigned int m_isolation {0}
 
int m_eta {0}
 
unsigned int m_phi {0}
 
int m_bw2or3 {0}
 
int m_innerCoin {0}
 
int m_goodMF {0}
 
int m_charge {0}
 
int m_is2cand {0}
 
int m_isTGC {0}
 
double m_EtDouble {0}
 
double m_etaDouble {0}
 
double m_phiDouble {0}
 
uint32_t m_roiWord
 
std::string m_tobName
 

Static Private Attributes

static thread_local Heap< TCS::MuonTOBfg_heap
 

Detailed Description

Definition at line 14 of file MuonTOB.h.

Constructor & Destructor Documentation

◆ MuonTOB() [1/3]

TCS::MuonTOB::MuonTOB ( uint32_t  roiWord = 0,
const std::string &  tobName = "MuonTOB" 
)

Definition at line 7 of file MuonTOB.cxx.

7  :
9 {}

◆ MuonTOB() [2/3]

TCS::MuonTOB::MuonTOB ( unsigned int  et,
unsigned int  isolation,
int  eta,
unsigned int  phi,
uint32_t  roiWord = 0,
const std::string &  tobName = "MuonTOB" 
)

Definition at line 12 of file MuonTOB.cxx.

12  :
14  , m_Et( sizeCheck(et, nBitsEt()) )
16  , m_eta( sizeCheck(eta, nBitsEta()) )
17  , m_phi( sizeCheck(phi, nBitsPhi()) )
18 {}

◆ MuonTOB() [3/3]

TCS::MuonTOB::MuonTOB ( const MuonTOB muon)
default

◆ ~MuonTOB()

TCS::MuonTOB::~MuonTOB ( )
virtualdefault

Member Function Documentation

◆ bw2or3()

int TCS::MuonTOB::bw2or3 ( ) const
inline

Definition at line 40 of file MuonTOB.h.

40 { return m_bw2or3; }

◆ charge()

int TCS::MuonTOB::charge ( ) const
inline

Definition at line 43 of file MuonTOB.h.

43 { return m_charge; }

◆ clearHeap()

void TCS::MuonTOB::clearHeap ( )
static

Definition at line 33 of file MuonTOB.cxx.

33  {
34  return fg_heap.clear();
35 }

◆ createOnHeap()

TCS::MuonTOB * TCS::MuonTOB::createOnHeap ( const MuonTOB cl)
static

Definition at line 28 of file MuonTOB.cxx.

28  {
29  return fg_heap.create(muon);
30 }

◆ Et()

unsigned int TCS::MuonTOB::Et ( ) const
inline

Definition at line 35 of file MuonTOB.h.

35 { return m_Et; } // Et threshold in units of 100 MeV

◆ eta()

int TCS::MuonTOB::eta ( ) const
inline

Definition at line 37 of file MuonTOB.h.

37 { return m_eta; } // Int eta for L1Topo, granularity = 0.025

◆ EtaDouble()

double TCS::MuonTOB::EtaDouble ( ) const
inline

Definition at line 47 of file MuonTOB.h.

47 { return m_etaDouble; } // Real muon eta

◆ EtDouble()

double TCS::MuonTOB::EtDouble ( ) const
inline

Definition at line 46 of file MuonTOB.h.

46 { return m_EtDouble; } // Et threshold in units of GeV

◆ goodMF()

int TCS::MuonTOB::goodMF ( ) const
inline

Definition at line 42 of file MuonTOB.h.

42 { return m_goodMF; }

◆ heap()

static const Heap<TCS::MuonTOB>& TCS::MuonTOB::heap ( )
inlinestatic

Definition at line 79 of file MuonTOB.h.

79 { return fg_heap; }

◆ innerCoin()

int TCS::MuonTOB::innerCoin ( ) const
inline

Definition at line 41 of file MuonTOB.h.

41 { return m_innerCoin; }

◆ instances()

static size_t TCS::BaseTOB::instances ( )
inlinestaticinherited

Definition at line 25 of file BaseTOB.h.

25 { return 0; }

◆ is2cand()

int TCS::MuonTOB::is2cand ( ) const
inline

Definition at line 44 of file MuonTOB.h.

44 { return m_is2cand; }

◆ isolation()

unsigned int TCS::MuonTOB::isolation ( ) const
inline

Definition at line 36 of file MuonTOB.h.

36 { return m_isolation; }

◆ isTGC()

bool TCS::MuonTOB::isTGC ( ) const
inline

Definition at line 50 of file MuonTOB.h.

50 {return m_isTGC;} // Additonal flag that identifies muons from TGC

◆ nBitsEt()

unsigned int TCS::MuonTOB::nBitsEt ( ) const
inline

Definition at line 30 of file MuonTOB.h.

30 { return m_nBitsEt; }

◆ nBitsEta()

unsigned int TCS::MuonTOB::nBitsEta ( ) const
inline

Definition at line 32 of file MuonTOB.h.

32 { return m_nBitsEta; }

◆ nBitsIsolation()

unsigned int TCS::MuonTOB::nBitsIsolation ( ) const
inline

Definition at line 31 of file MuonTOB.h.

31 { return m_nBitsIsolation; }

◆ nBitsPhi()

unsigned int TCS::MuonTOB::nBitsPhi ( ) const
inline

Definition at line 33 of file MuonTOB.h.

33 { return m_nBitsPhi; }

◆ phi()

unsigned int TCS::MuonTOB::phi ( ) const
inline

Definition at line 38 of file MuonTOB.h.

38 { return m_phi; } // Int phi for L1Topo, granularity = 0.05

◆ PhiDouble()

double TCS::MuonTOB::PhiDouble ( ) const
inline

Definition at line 48 of file MuonTOB.h.

48 { return m_phiDouble; } // Real muon phi

◆ print()

void TCS::MuonTOB::print ( std::ostream &  o) const
virtual

Implements TCS::BaseTOB.

Definition at line 37 of file MuonTOB.cxx.

37  {
38  o << "muon energy: " << Et() << ", eta: " << eta() << ", phi: " << phi() << ", bw2or3: " << bw2or3() << ", innerCoin: " << innerCoin() << ", goodMF: " << goodMF() << ", charge: " << charge() << ", is2cand: " << is2cand() << ", isTGC: " << isTGC();
39 }

◆ roiWord()

uint32_t TCS::BaseTOB::roiWord ( ) const
inlineinherited

Definition at line 21 of file BaseTOB.h.

21 { return m_roiWord; }

◆ setBitsEt()

void TCS::MuonTOB::setBitsEt ( unsigned int  nBitsEt)
inline

Definition at line 69 of file MuonTOB.h.

69 { m_nBitsEt = nBitsEt; }

◆ setBitsEta()

void TCS::MuonTOB::setBitsEta ( unsigned int  nBitsEta)
inline

Definition at line 71 of file MuonTOB.h.

71 { m_nBitsEta = nBitsEta; }

◆ setBitsIsolation()

void TCS::MuonTOB::setBitsIsolation ( unsigned int  nBitsIsolation)
inline

Definition at line 70 of file MuonTOB.h.

◆ setBitsPhi()

void TCS::MuonTOB::setBitsPhi ( unsigned int  nBitsPhi)
inline

Definition at line 72 of file MuonTOB.h.

72 { m_nBitsPhi = nBitsPhi; }

◆ setBW2or3()

void TCS::MuonTOB::setBW2or3 ( int  bw2or3)
inline

Definition at line 58 of file MuonTOB.h.

58 { m_bw2or3 = bw2or3; }

◆ setCharge()

void TCS::MuonTOB::setCharge ( int  charge)
inline

Definition at line 61 of file MuonTOB.h.

61 { m_charge = charge; }

◆ setEt()

void TCS::MuonTOB::setEt ( unsigned int  et)
inline

Definition at line 53 of file MuonTOB.h.

53 { m_Et = sizeCheck(et, nBitsEt()); }

◆ setEta()

void TCS::MuonTOB::setEta ( int  eta)
inline

Definition at line 55 of file MuonTOB.h.

55 { m_eta = sizeCheck(eta, nBitsEta()); }

◆ setEtaDouble()

void TCS::MuonTOB::setEtaDouble ( double  eta)
inline

Definition at line 66 of file MuonTOB.h.

66 { m_etaDouble = eta; }

◆ setEtDouble()

void TCS::MuonTOB::setEtDouble ( double  et)
inline

Definition at line 65 of file MuonTOB.h.

65 { m_EtDouble = et; }

◆ setGoodMF()

void TCS::MuonTOB::setGoodMF ( int  goodMF)
inline

Definition at line 60 of file MuonTOB.h.

60 { m_goodMF = goodMF; }

◆ setInnerCoin()

void TCS::MuonTOB::setInnerCoin ( int  innerCoin)
inline

Definition at line 59 of file MuonTOB.h.

◆ setIs2cand()

void TCS::MuonTOB::setIs2cand ( int  is2cand)
inline

Definition at line 62 of file MuonTOB.h.

62 { m_is2cand = is2cand; }

◆ setIsolation()

void TCS::MuonTOB::setIsolation ( unsigned int  iso)
inline

Definition at line 54 of file MuonTOB.h.

◆ setIsTGC()

void TCS::MuonTOB::setIsTGC ( int  isTGC)
inline

Definition at line 63 of file MuonTOB.h.

63 { m_isTGC = isTGC; }

◆ setPhi()

void TCS::MuonTOB::setPhi ( unsigned int  phi)
inline

Definition at line 56 of file MuonTOB.h.

56 { m_phi = sizeCheck(phi, nBitsPhi()); }

◆ setPhiDouble()

void TCS::MuonTOB::setPhiDouble ( double  phi)
inline

Definition at line 67 of file MuonTOB.h.

67 { m_phiDouble = phi; }

◆ sizeCheck() [1/2]

int TCS::BaseTOB::sizeCheck ( int  value,
unsigned int  size 
) const
protectedinherited

Definition at line 32 of file BaseTOB.cxx.

33 {
34  int max(0x1 << (size-1));
35  int min(~max + 1);
36  --max;
37  if(value>max || value<min) {
38  TCS_EXCEPTION("Integer value " << value << " outside firmware specifications. Maximum number of bits is " << size << " -> range ["<<min<<" - "<<max<<"]" << ", for " << m_tobName);
39  }
40  return value;
41 }

◆ sizeCheck() [2/2]

unsigned int TCS::BaseTOB::sizeCheck ( unsigned int  value,
unsigned int  size 
) const
protectedinherited

Definition at line 44 of file BaseTOB.cxx.

45 {
46  unsigned int max( (0x1 << size)-1 );
47  if(value>max) {
48  TCS_EXCEPTION("Unsigned integer value " << value << " outside firmware specifications. Maximum number of bits is " << size << " -> range [0"<<" - "<<max<<"]" << ", for " << m_tobName);
49  }
50  return value;
51 }

◆ sizeCheckM()

int TCS::BaseTOB::sizeCheckM ( int  value,
unsigned int  size 
) const
protectedinherited

Definition at line 19 of file BaseTOB.cxx.

20 {
21  int max(0x1 << (size-1));
22  int min(~max + 1);
23  --max;
24  if( (-value)>max || (-value)<min) {
25  TCS_EXCEPTION("Integer value " << -value << " outside firmware specifications. Maximum number of bits is " << size << " -> range ["<<min<<" - "<<max<<"]" << ", for " << m_tobName);
26  }
27  return value;
28 }

◆ tobName()

const std::string& TCS::BaseTOB::tobName ( ) const
inlineinherited

Definition at line 23 of file BaseTOB.h.

23 { return m_tobName; }

◆ tobType()

inputTOBType_t TCS::MuonTOB::tobType ( ) const
inlinevirtual

Implements TCS::BaseTOB.

Definition at line 74 of file MuonTOB.h.

74 { return MUON; }

Member Data Documentation

◆ fg_heap

thread_local TCS::Heap< TCS::MuonTOB > TCS::MuonTOB::fg_heap
staticprivate

Definition at line 105 of file MuonTOB.h.

◆ m_bw2or3

int TCS::MuonTOB::m_bw2or3 {0}
private

Definition at line 94 of file MuonTOB.h.

◆ m_charge

int TCS::MuonTOB::m_charge {0}
private

Definition at line 97 of file MuonTOB.h.

◆ m_Et

unsigned int TCS::MuonTOB::m_Et {0}
private

Definition at line 89 of file MuonTOB.h.

◆ m_eta

int TCS::MuonTOB::m_eta {0}
private

Definition at line 91 of file MuonTOB.h.

◆ m_etaDouble

double TCS::MuonTOB::m_etaDouble {0}
private

Definition at line 102 of file MuonTOB.h.

◆ m_EtDouble

double TCS::MuonTOB::m_EtDouble {0}
private

Definition at line 101 of file MuonTOB.h.

◆ m_goodMF

int TCS::MuonTOB::m_goodMF {0}
private

Definition at line 96 of file MuonTOB.h.

◆ m_innerCoin

int TCS::MuonTOB::m_innerCoin {0}
private

Definition at line 95 of file MuonTOB.h.

◆ m_is2cand

int TCS::MuonTOB::m_is2cand {0}
private

Definition at line 98 of file MuonTOB.h.

◆ m_isolation

unsigned int TCS::MuonTOB::m_isolation {0}
private

Definition at line 90 of file MuonTOB.h.

◆ m_isTGC

int TCS::MuonTOB::m_isTGC {0}
private

Definition at line 99 of file MuonTOB.h.

◆ m_nBitsEt

unsigned int TCS::MuonTOB::m_nBitsEt {13}
private

Definition at line 84 of file MuonTOB.h.

◆ m_nBitsEta

unsigned int TCS::MuonTOB::m_nBitsEta {9}
private

Definition at line 86 of file MuonTOB.h.

◆ m_nBitsIsolation

unsigned int TCS::MuonTOB::m_nBitsIsolation {5}
private

Definition at line 85 of file MuonTOB.h.

◆ m_nBitsPhi

unsigned int TCS::MuonTOB::m_nBitsPhi {7}
private

Definition at line 87 of file MuonTOB.h.

◆ m_phi

unsigned int TCS::MuonTOB::m_phi {0}
private

Definition at line 92 of file MuonTOB.h.

◆ m_phiDouble

double TCS::MuonTOB::m_phiDouble {0}
private

Definition at line 103 of file MuonTOB.h.

◆ m_roiWord

uint32_t TCS::BaseTOB::m_roiWord
privateinherited

Definition at line 36 of file BaseTOB.h.

◆ m_tobName

std::string TCS::BaseTOB::m_tobName
privateinherited

Definition at line 37 of file BaseTOB.h.


The documentation for this class was generated from the following files:
TCS::BaseTOB::tobName
const std::string & tobName() const
Definition: BaseTOB.h:23
TCS::MuonTOB::m_innerCoin
int m_innerCoin
Definition: MuonTOB.h:95
TCS::MuonTOB::m_bw2or3
int m_bw2or3
Definition: MuonTOB.h:94
plotBeamSpotCompare.x1
x1
Definition: plotBeamSpotCompare.py:216
TCS::MuonTOB::m_EtDouble
double m_EtDouble
Definition: MuonTOB.h:101
xAOD::muon
@ muon
Definition: TrackingPrimitives.h:195
TCS::MuonTOB::is2cand
int is2cand() const
Definition: MuonTOB.h:44
et
Extra patterns decribing particle interation process.
TCS::MuonTOB::nBitsEt
unsigned int nBitsEt() const
Definition: MuonTOB.h:30
TCS::Heap::clear
void clear()
Definition: Heap.h:32
TCS::MuonTOB::phi
unsigned int phi() const
Definition: MuonTOB.h:38
TCS::MuonTOB::fg_heap
static thread_local Heap< TCS::MuonTOB > fg_heap
Definition: MuonTOB.h:105
TCS::MuonTOB::charge
int charge() const
Definition: MuonTOB.h:43
xAOD::et
et
Definition: TrigEMCluster_v1.cxx:25
TCS::MuonTOB::nBitsPhi
unsigned int nBitsPhi() const
Definition: MuonTOB.h:33
max
constexpr double max()
Definition: ap_fixedTest.cxx:33
min
constexpr double min()
Definition: ap_fixedTest.cxx:26
TCS::MuonTOB::eta
int eta() const
Definition: MuonTOB.h:37
TCS::MuonTOB::m_eta
int m_eta
Definition: MuonTOB.h:91
TCS::MuonTOB::m_goodMF
int m_goodMF
Definition: MuonTOB.h:96
athena.value
value
Definition: athena.py:124
TCS::BaseTOB::roiWord
uint32_t roiWord() const
Definition: BaseTOB.h:21
TCS::MuonTOB::Et
unsigned int Et() const
Definition: MuonTOB.h:35
TCS::MuonTOB::nBitsEta
unsigned int nBitsEta() const
Definition: MuonTOB.h:32
TCS::BaseTOB::sizeCheck
int sizeCheck(int value, unsigned int size) const
Definition: BaseTOB.cxx:32
TCS::MuonTOB::m_isTGC
int m_isTGC
Definition: MuonTOB.h:99
python.setupRTTAlg.size
int size
Definition: setupRTTAlg.py:39
TCS::MuonTOB::isolation
unsigned int isolation() const
Definition: MuonTOB.h:36
TCS::MuonTOB::m_Et
unsigned int m_Et
Definition: MuonTOB.h:89
TCS::MuonTOB::m_nBitsEt
unsigned int m_nBitsEt
Definition: MuonTOB.h:84
TCS::BaseTOB::BaseTOB
BaseTOB(uint32_t roiWord, const std::string &tobType)
Definition: BaseTOB.cxx:11
TCS::MuonTOB::innerCoin
int innerCoin() const
Definition: MuonTOB.h:41
TCS::MuonTOB::nBitsIsolation
unsigned int nBitsIsolation() const
Definition: MuonTOB.h:31
TCS::BaseTOB::m_roiWord
uint32_t m_roiWord
Definition: BaseTOB.h:36
TCS::MuonTOB::m_is2cand
int m_is2cand
Definition: MuonTOB.h:98
TCS::MuonTOB::m_isolation
unsigned int m_isolation
Definition: MuonTOB.h:90
TCS_EXCEPTION
#define TCS_EXCEPTION(MSG)
Definition: Trigger/TrigT1/L1Topo/L1TopoCommon/L1TopoCommon/Exception.h:14
TCS::MuonTOB::isTGC
bool isTGC() const
Definition: MuonTOB.h:50
TCS::MUON
@ MUON
Definition: Trigger/TrigT1/L1Topo/L1TopoCommon/L1TopoCommon/Types.h:17
TCS::MuonTOB::goodMF
int goodMF() const
Definition: MuonTOB.h:42
TCS::MuonTOB::bw2or3
int bw2or3() const
Definition: MuonTOB.h:40
TCS::Heap::create
T * create(const T &obj)
create an object on the heap
Definition: Heap.h:50
TCS::MuonTOB::m_phiDouble
double m_phiDouble
Definition: MuonTOB.h:103
TCS::MuonTOB::m_nBitsIsolation
unsigned int m_nBitsIsolation
Definition: MuonTOB.h:85
TCS::MuonTOB::m_nBitsPhi
unsigned int m_nBitsPhi
Definition: MuonTOB.h:87
TCS::MuonTOB::m_nBitsEta
unsigned int m_nBitsEta
Definition: MuonTOB.h:86
TCS::MuonTOB::m_charge
int m_charge
Definition: MuonTOB.h:97
TCS::MuonTOB::m_phi
unsigned int m_phi
Definition: MuonTOB.h:92
TCS::MuonTOB::m_etaDouble
double m_etaDouble
Definition: MuonTOB.h:102
TCS::BaseTOB::m_tobName
std::string m_tobName
Definition: BaseTOB.h:37