42 m_EmcCCount->getClusterId();
67 ISvcLocator* svcLocator = Gaudi::svcLocator();
68 StatusCode sc = svcLocator->service(
"BesGlobalTrigSvc", m_tmpSvc);
72 int nbcluster = 0, necluster = 0;
74 necluster = m_pIBGT->getEmcNweCluster() + m_pIBGT->getEmcNeeCluster();
75 if((nbcluster + necluster)>=1) NClus1 =
true;
76 if((nbcluster + necluster)>=2) NClus2 =
true;
77 if(nbcluster >= 1) NBClus1 =
true;
78 if(necluster >= 1) NEClus1 =
true;
80 double L1ETOT_L = double (m_pIBGT->getL1ETOT_L());
81 double L1ETOT_M = double (m_pIBGT->getL1ETOT_M());
82 double L1EDIFF_BR = double (m_pIBGT->getL1EDIFF_BR());
83 double L1EDIFF_EC = double (m_pIBGT->getL1EDIFF_EC());
100 if((m_EmcESum->getTotE() > L1ETOT_M) ) Etot_M =
true;
102 if((m_EmcESum->getTotE() > L1ETOT_L) ) Etot_L =
true;
104 if((std::abs(m_EmcESum->getLBTotE() - m_EmcESum->getRBTotE())<L1EDIFF_BR))
107 if((std::abs(m_EmcESum->getWETotE() - m_EmcESum->getEETotE())<L1EDIFF_EC))
110 double L1ETOT_BR = double (m_pIBGT->getL1ETOT_BR());
111 double L1ETOT_EC = double (m_pIBGT->getL1ETOT_EC());
126 if((m_EmcESum->getBTotE()>L1ETOT_BR)) BEtot_H =
true;
128 if((m_EmcESum->getETotE()>L1ETOT_EC)) EEtot_H =
true;
134 double L1EBL_EC = double (m_pIBGT->getL1EBL_EC());
135 if((m_EmcESum->getWETotE()>L1EBL_EC && m_EmcESum->getEETotE()>L1EBL_EC))
139 double energy0 = m_EmcESum->getBBLKE(0);
140 double energy1 = m_EmcESum->getBBLKE(1);
141 double energy2 = m_EmcESum->getBBLKE(2);
142 double energy3 = m_EmcESum->getBBLKE(3);
143 double energy4 = m_EmcESum->getBBLKE(4);
144 double energy5 = m_EmcESum->getBBLKE(5);
145 double energy9 = m_EmcESum->getBBLKE(9);
146 double energy10 = m_EmcESum->getBBLKE(10);
147 double energy6 = m_EmcESum->getBBLKE(6);
148 double energy11 = m_EmcESum->getBBLKE(11);
149 double energy7 = m_EmcESum->getBBLKE(7);
150 double energy8 = m_EmcESum->getBBLKE(8);
151 double L1BLK_GATE = double (m_pIBGT->getL1BLK_GATE());
152 if((energy0+energy1)>L1BLK_GATE && (energy9+energy10)>L1BLK_GATE)
154 if((energy1+energy2)>L1BLK_GATE && (energy10+energy11)>L1BLK_GATE)
156 if((energy2+energy3)>L1BLK_GATE && (energy11+energy6)>L1BLK_GATE)
158 if((energy3+energy4)>L1BLK_GATE && (energy6+energy7)>L1BLK_GATE)
160 if((energy4+energy5)>L1BLK_GATE && (energy7+energy8)>L1BLK_GATE)
162 if((energy5+energy0)>L1BLK_GATE && (energy8+energy9)>L1BLK_GATE)
171 for(
int j =0;j<TrigConf::TCPHINO_B;j++)
173 int bphi = m_EmcCCount->getBClusterPhi(j);
174 if(bphi==0)
continue;
178 for(
int k =0;k<15;k++)
180 if((8+k+j)<TrigConf::TCPHINO_B)
181 NCluster+=m_EmcCCount->getBClusterPhi(8+k+j);
183 NCluster+=m_EmcCCount->getBClusterPhi(8+k+j-TrigConf::TCPHINO_B);
190 if(BClus_Phi ==
true)
196 for(
int j = 0;j<TrigConf::TCPHINO_E/2;j++)
198 int wephi = m_EmcCCount->getWEClusterPhi(j);
199 if(wephi == 0)
continue;
205 if((j+5+k)<TrigConf::TCPHINO_E/2)
206 NCluster+= m_EmcCCount->getEEClusterPhi(j+5+k);
208 NCluster+= m_EmcCCount->getEEClusterPhi(j+5+k-TrigConf::TCPHINO_E/2);
215 if(EClus_Phi ==
true)
221 for(
int i=0;i<TrigConf::TCTHETANO_B;i++)
222 for(
int j=0;j<TrigConf::TCPHINO_B;j++)
224 int BClusId = m_EmcCCount->getBClusterId(i,j);
226 if(BClusId==0)
continue;
229 if(i>0&&i<(TrigConf::TCTHETANO_B-1))
233 if(j+13+k<TrigConf::TCPHINO_B)
235 NCluster+= m_EmcCCount->getBClusterId((TrigConf::TCTHETANO_B-1)-i,j+13+k);
236 NCluster+= m_EmcCCount->getBClusterId((TrigConf::TCTHETANO_B-1)-i+1,j+13+k);
237 NCluster+= m_EmcCCount->getBClusterId((TrigConf::TCTHETANO_B-1)-i-1,j+13+k);
241 NCluster+= m_EmcCCount->getBClusterId((TrigConf::TCTHETANO_B-1)-i,j+13+k-TrigConf::TCPHINO_B);
242 NCluster+= m_EmcCCount->getBClusterId((TrigConf::TCTHETANO_B-1)-i+1,j+13+k-TrigConf::TCPHINO_B);
243 NCluster+= m_EmcCCount->getBClusterId((TrigConf::TCTHETANO_B-1)-i-1,j+13+k-TrigConf::TCPHINO_B);
246 if(NCluster>0) { BClusBB =
true;
break; }
252 if(j+13+k<TrigConf::TCPHINO_B)
254 NCluster+= m_EmcCCount->getBClusterId((TrigConf::TCTHETANO_B-1),j+13+k);
255 NCluster+= m_EmcCCount->getBClusterId((TrigConf::TCTHETANO_B-2),j+13+k);
259 NCluster+= m_EmcCCount->getBClusterId((TrigConf::TCTHETANO_B-2),j+13+k-TrigConf::TCPHINO_B);
260 NCluster+= m_EmcCCount->getBClusterId((TrigConf::TCTHETANO_B-1),j+13+k-TrigConf::TCPHINO_B);
263 if(NCluster>0) { BClusBB =
true;
break; }
265 if(i==(TrigConf::TCTHETANO_B-1))
269 if(j+13+k<TrigConf::TCPHINO_B)
271 NCluster+= m_EmcCCount->getBClusterId(0,j+13+k);
272 NCluster+= m_EmcCCount->getBClusterId(1,j+13+k);
276 NCluster+= m_EmcCCount->getBClusterId(0,j+13+k-TrigConf::TCPHINO_B);
277 NCluster+= m_EmcCCount->getBClusterId(1,j+13+k-TrigConf::TCPHINO_B);
280 if(NCluster>0) { BClusBB =
true;
break; }
285 for(
int j = 0;j<TrigConf::TCPHINO_E/2;j++)
288 int EClusId = m_EmcCCount->getWEClusterPhi(j);
290 if(EClusId == 0)
continue;
296 if((j+7+k)<TrigConf::TCPHINO_E/2)
297 NCluster+= m_EmcCCount->getEEClusterPhi(j+7+k);
299 NCluster+= m_EmcCCount->getEEClusterPhi(j+7+k-TrigConf::TCPHINO_E/2);
311 double L1EBL_Z = double (m_pIBGT->getL1EBL_Z());
319 if((m_EmcESum->getRTotE()>=L1EBL_Z && m_EmcESum->getLTotE()>=L1EBL_Z))
324 if(m_EmcCCount->getEClus_Z()&&m_EmcCCount->getWClus_Z())
329 m_pIBGT->setNClus1(NClus1);
330 m_pIBGT->setNClus2(NClus2);
331 m_pIBGT->setNBClus1(NBClus1);
332 m_pIBGT->setNEClus1(NEClus1);
334 m_pIBGT->setBClusBB(BClusBB);
335 m_pIBGT->setEClusBB(EClusBB);
336 m_pIBGT->setClus_Z(Clus_Z);
337 m_pIBGT->setBClus_PHI(BClus_Phi);
338 m_pIBGT->setEClus_PHI(EClus_Phi);
339 m_pIBGT->setBEtot_H(BEtot_H);
340 m_pIBGT->setEEtot_H(EEtot_H);
341 m_pIBGT->setEtot_L(Etot_L);
342 m_pIBGT->setEtot_M(Etot_M);
343 m_pIBGT->setBL_Z(BL_Z);
344 m_pIBGT->setDiff_B(Diff_B);
345 m_pIBGT->setDiff_E(Diff_E);
346 m_pIBGT->setBL_BBLK(BL_BBLK);
347 m_pIBGT->setBL_EBLK(BL_EBLK);