3 #include "StjDijetListTriggerBHT.h"
17 if( ! _trg->passed() )
return retList;
19 double maxEt3 = getMaxEtForBEMCTowersThatPassedBHT(item.jet3);
20 double maxEt4 = getMaxEtForBEMCTowersThatPassedBHT(item.jet4);
22 if(maxEt3 == 0 && maxEt4 == 0)
return retList;
28 dijet.jetSameSide = item.jet3;
29 dijet.jetAwaySide = item.jet4;
30 dijet.neuRtSameSide = item.jet3.neuRt;
31 dijet.neuRtAwaySide = item.jet4.neuRt;
35 dijet.jetSameSide = item.jet4;
36 dijet.jetAwaySide = item.jet3;
37 dijet.neuRtSameSide = item.jet4.neuRt;
38 dijet.neuRtAwaySide = item.jet3.neuRt;
41 retList.push_back(dijet);
46 double StjDijetListTriggerBHT::getMaxEtForBEMCTowersThatPassedBHT(
const StjJet& jet)
49 for(StjFourVecList::const_iterator it = jet.fourVecList.begin(); it != jet.fourVecList.end(); ++it)
51 double towerEt = getTowerEtIfFiredBHT(*it);
52 if(towerEt > ret) ret = towerEt;
57 double StjDijetListTriggerBHT::getTowerEtIfFiredBHT(
const StjFourVec& p4)
59 if(p4.type != 2)
return 0;
60 if(p4.detectorId != 9)
return 0;
61 vector<int> towers = _trg->towers();
62 vector<double> towerEt = _trg->towerEt();
63 for(
size_t i = 0; i != towers.size(); ++i)
65 if(p4.towerId == towers[i])
return towerEt[i];