Belle II Software development
TrgEclBeamBKG Class Reference

A Class of ECL Trigger clustering. More...

#include <TrgEclBeamBKG.h>

Public Member Functions

 TrgEclBeamBKG ()
 Constructor.
 
virtual ~TrgEclBeamBKG ()
 Constructor.
 
 TrgEclBeamBKG (TrgEclBeamBKG &)=delete
 Destructor.
 
TrgEclBeamBKGoperator= (TrgEclBeamBKG &)=delete
 Assignment operator, deleted.
 
int getBeamBkg (std::vector< std::vector< double > >)
 get beambkg bit array
 

Private Attributes

int m_Quadrant [3][4]
 4 region along r phi plane
 
TrgEclMappingm_TCMap
 Object of TC Mapping.
 

Detailed Description

A Class of ECL Trigger clustering.

Definition at line 29 of file TrgEclBeamBKG.h.

Constructor & Destructor Documentation

◆ TrgEclBeamBKG() [1/2]

Constructor.

Definition at line 20 of file TrgEclBeamBKG.cc.

21{
22 for (int iii = 0; iii <= 2; iii++) {
23 for (int jjj = 0; jjj <= 3; jjj++) {
24 m_Quadrant[iii][jjj] = 0;
25 }
26 }
27 m_TCMap = new TrgEclMapping();
28
29}
int m_Quadrant[3][4]
4 region along r phi plane
TrgEclMapping * m_TCMap
Object of TC Mapping.

◆ ~TrgEclBeamBKG()

~TrgEclBeamBKG ( )
virtual

Constructor.

Destructor

Definition at line 33 of file TrgEclBeamBKG.cc.

34{
35
36 delete m_TCMap;
37}

◆ TrgEclBeamBKG() [2/2]

Destructor.

Copy constructor, deleted.

Member Function Documentation

◆ getBeamBkg()

int getBeamBkg ( std::vector< std::vector< double > > ThetaRingSum)

get beambkg bit array

Definition at line 41 of file TrgEclBeamBKG.cc.

42{
43
44 // forward
45 for (int iFwd = 0 ; iFwd < 32 ; iFwd++) {
46 int phiid = iFwd + 1;
47 if (ThetaRingSum[0][iFwd] > 0) {
48 if ((phiid >= 1 && phiid <= 9) || phiid == 32) {
49 m_Quadrant[0][0] = 1;
50 }
51 if (phiid >= 8 && phiid <= 17) {
52 m_Quadrant[0][1] = 1;
53 }
54 if (phiid >= 16 && phiid <= 25) {
55 m_Quadrant[0][2] = 1;
56 }
57 // cppcheck-suppress knownConditionTrueFalse
58 if ((phiid >= 24 && phiid <= 32) || phiid == 1) {
59 m_Quadrant[0][3] = 1;
60 }
61 }
62 }
63 // barrel
64 for (int iBr = 0 ; iBr < 36 ; iBr++) {
65 int phiid = iBr + 1;
66 if (ThetaRingSum[1][iBr] > 0) {
67 if ((phiid >= 1 && phiid <= 10) || phiid == 36) {
68 m_Quadrant[1][0] = 1;
69 }
70 if (phiid >= 9 && phiid <= 19) {
71 m_Quadrant[1][1] = 1;
72 }
73 if (phiid >= 18 && phiid <= 28) {
74 m_Quadrant[1][2] = 1;
75 }
76 // cppcheck-suppress knownConditionTrueFalse
77 if ((phiid >= 27 && phiid <= 36) || phiid == 1) {
78 m_Quadrant[1][3] = 1;
79 }
80 }
81 }
82 // selection for forward endcap
83 bool boolForward =
84 ((m_Quadrant[0][0] && m_Quadrant[0][2]) ||
85 (m_Quadrant[0][1] && m_Quadrant[0][3]));
86 // selection for barrel
87 bool boolBarrel =
88 ((m_Quadrant[1][0] && m_Quadrant[1][2]) ||
89 (m_Quadrant[1][1] && m_Quadrant[1][3]));
90 // bkg bit selection
91 int iBeamBkgVeto0 = 0;
92 int iBeamBkgVeto1 = 0;
93 int iBeamBkgVeto2 = 0;
94 if (boolForward || boolBarrel) {
95 iBeamBkgVeto0 = 1;
96 }
97 if ((!boolForward) && boolBarrel) {
98 iBeamBkgVeto1 = 1;
99 }
100 if (boolForward && (!boolBarrel)) {
101 iBeamBkgVeto2 = 1;
102 }
103 // set bkg bit parameter
104 int BeamBkgVeto = 0;
105 BeamBkgVeto |= (iBeamBkgVeto2 & 0x01);
106 BeamBkgVeto <<= 1;
107 BeamBkgVeto |= (iBeamBkgVeto1 & 0x01);
108 BeamBkgVeto <<= 1;
109 BeamBkgVeto |= (iBeamBkgVeto0 & 0x01);
110
111 return BeamBkgVeto;
112}

Member Data Documentation

◆ m_Quadrant

int m_Quadrant[3][4]
private

4 region along r phi plane

Definition at line 52 of file TrgEclBeamBKG.h.

◆ m_TCMap

TrgEclMapping* m_TCMap
private

Object of TC Mapping.

Definition at line 54 of file TrgEclBeamBKG.h.


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