ATLAS Offline Software
Loading...
Searching...
No Matches
TGCEIFICoincidenceMap.h
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2024 CERN for the benefit of the ATLAS collaboration
3*/
4
5#ifndef TrigT1TGC_TGCEIFICoincidenceMap_hh
6#define TrigT1TGC_TGCEIFICoincidenceMap_hh
7
11
14
16
17#include <string>
18#include <bitset>
19
20namespace LVL1TGC {
21
23{
24 public:
27 const std::string& version, int sideId=0);
28
31
32 const LVL1TGCTrigger::TGCInnerTrackletSlot* getInnerTrackletMask(const unsigned int input,
33 const unsigned int ssc,
34 const unsigned int sec) const;
35 int getFlagPT(const unsigned int pt,
36 const unsigned int ssc,
37 const unsigned int sec) const;
38
39 int getFlagROI(const unsigned int roi,
40 const unsigned int ssc,
41 const unsigned int sec) const;
42
43 int getTriggerBit(const int slot,
44 const int ssc,
45 const int sec,
46 const int reg,
47 const int read,
48 const int bit) const;
49
50 const std::string& getVersion() const { return m_verName; }
51 int getSideId() const { return m_side; }
52 bool isFullCW() const { return m_fullCW; }
53 void setFullCW( bool val) { m_fullCW = val; }
54
55 bool readMap();
56 void dumpMap() const;
57
60
61 protected:
62 static constexpr unsigned int N_INNER_SECTORS = 4;
63
64 private:
65 // The flagPT is a flag whether each pT is applied the coincidence or not.
66 // In each bit (of kNThresholdsR2 bits), 1 applies the coincidence, and 0 is not.
67 // The LSB is the lowest pT threshold, and MSB is the highest pT threshold.
68 std::bitset<kNThresholdsR2> m_flagPT[kNMaxSSC][kNEndcapTrigSector];
69
71 // 1 use; 0: not use; -1: not used for Trigger
72
74
75 std::string m_verName;
76 int m_side;
78
80
82};
83
84
85inline
87 const unsigned int ssc,
88 const unsigned int sec) const
89{
90 if (input >= N_INNER_SECTORS) return 0;
91 if (ssc >= kNMaxSSC) return 0;
92 if (sec >= kNEndcapTrigSector) return 0;
93
94 return &(m_map[input][ssc][sec]);
95}
96
97} //end of namespace bracket
98
99#endif
100
101
AthMessaging(IMessageSvc *msgSvc, const std::string &name)
Constructor.
const LVL1TGCTrigger::TGCArguments * tgcArgs() const
const std::string & getVersion() const
LVL1TGCTrigger::TGCInnerTrackletSlot m_map[N_INNER_SECTORS][kNMaxSSC][kNEndcapTrigSector]
int getTriggerBit(const int slot, const int ssc, const int sec, const int reg, const int read, const int bit) const
int getFlagROI(const unsigned int roi, const unsigned int ssc, const unsigned int sec) const
LVL1TGCTrigger::TGCArguments * m_tgcArgs
int m_flagROI[kNRoiInSSC][kNMaxSSC][kNEndcapTrigSector]
static constexpr unsigned int N_INNER_SECTORS
std::bitset< kNThresholdsR2 > m_flagPT[kNMaxSSC][kNEndcapTrigSector]
int getFlagPT(const unsigned int pt, const unsigned int ssc, const unsigned int sec) const
TGCEIFICoincidenceMap & operator=(const TGCEIFICoincidenceMap &right)
TGCEIFICoincidenceMap(LVL1TGCTrigger::TGCArguments *, const SG::ReadCondHandleKey< TGCTriggerData > &readCondKey)
const LVL1TGCTrigger::TGCInnerTrackletSlot * getInnerTrackletMask(const unsigned int input, const unsigned int ssc, const unsigned int sec) const
LVL1TGCTrigger::TGCArguments * tgcArgs()
const SG::ReadCondHandleKey< TGCTriggerData > & m_readCondKey
static constexpr unsigned int kNEndcapTrigSector
The number of endcap trigger sectors per side.
static constexpr unsigned int kNMaxSSC
The maximim number of SubSector-Clusters (SSC) (i.e.
static constexpr unsigned int kNRoiInSSC
The default number of ROIs in SSC.
IovVectorMap_t read(const Folder &theFolder, const SelectionCriterion &choice, const unsigned int limit=10)