126 for(
int i=0;
i<121;
i++)MNxN[
i]=0.0;
133 std::vector<DetId> NxNaroundDC = topology->
getWindow(itID,size,size);
138 std::vector<DetId>::const_iterator theCells;
141 double EnergyMax = 0.0;
143 for(theCells=NxNaroundDC.begin();theCells<NxNaroundDC.end();theCells++){
149 if( goS_it != hit_collection->
end() && goS_it->energy()>=EnergyMax){EnergyMax=goS_it->energy(); EBCellMax = EBCell;}
154 if(EBCellMax.
null()){
return 0;}
165 std::vector<DetId> NxNaroundMaxCont = topology->
getWindow(EBCellMax,FixedSize,FixedSize);
170 std::vector<DetId>::const_iterator itCells;
171 for(itCells=NxNaroundMaxCont.begin();itCells<NxNaroundMaxCont.end();itCells++){
173 int CReta = EBitCell.
ieta();
174 int CRphi = EBitCell.
iphi();
177 if(!EBitCell.
null()){
179 if( goS_it != hit_collection->
end() ) Energy=goS_it->energy();
186 if((CReta * EBCellMax.
ieta()) < 0 && EBCellMax.
ieta()>0 )ietaCorr= -1;
187 if((CReta * EBCellMax.
ieta()) < 0 && EBCellMax.
ieta()<0 )ietaCorr= 1;
188 if((CReta * EBCellMax.
ieta()) > 0 )ietaCorr= 0;
189 int ieta = -( (CReta -ietaCorr) - EBCellMax.
ieta() ) +
int((FixedSize - 1)/2);
192 if((CRphi - EBCellMax.
iphi())> 50)iphiCorr= 360;
193 if((CRphi - EBCellMax.
iphi())<-50)iphiCorr=-360;
194 int iphi = CRphi - EBCellMax.
iphi() - iphiCorr + int((FixedSize - 1)/2);
196 int MIndex = ieta+iphi*FixedSize;
199 if(EBitCell == itID)IndDeadChannel[0]= MIndex;
210 if(theIndex>=48 && theIndex<=50)ESUMis += Energy;
211 if(theIndex>=59 && theIndex<=61)ESUMis += Energy;
212 if(theIndex>=70 && theIndex<=72)ESUMis += Energy;
const CaloTopology * calotopo
std::vector< EcalRecHit >::const_iterator const_iterator
int iphi() const
get the crystal iphi
int ieta() const
get the crystal ieta
const_iterator end() const
virtual std::vector< DetId > getWindow(const DetId &id, const int &northSouthSize, const int &eastWestSize) const
bool null() const
is this a null id ?
const CaloSubdetectorTopology * getSubdetectorTopology(const DetId &id) const
access the subdetector Topology for the given subdetector directly
iterator find(key_type k)
tuple size
Write out results.