![Logo](../../ATLAS-Logo-Square-Blue-RGB.png) |
ATLAS Offline Software
|
Go to the documentation of this file.
29 #include "CaloEvent/CaloTowerContainer.h"
30 #include "GaudiKernel/Bootstrap.h"
31 #include "GaudiKernel/Service.h"
76 IMessageSvc* theMsgSvc;
77 StatusCode sc = Gaudi::svcLocator()->service(
"MessageSvc",theMsgSvc);
79 std::cout <<
"LArFCalTowerStore: could not initialize the MessageSvc " << std::endl;
81 MsgStream
msg(theMsgSvc,
"LArFCalTowerStore");
94 msg << MSG::ERROR <<
"cannot initialize internal store properly, index offset = " <<
m_indxOffset <<
", index boundary = "
133 msg << MSG::ERROR<<
"Can't find element for index " << cellIndex
137 double xCell = theElement->
x();
138 double yCell = theElement->
y();
139 double zCell = theElement->
z();
140 double dxCell = theElement->
dx();
141 double dyCell = theElement->
dy();
157 for (
double x = xCell-dxCell/2.;
x < xCell+(dxCell-theXBin/8.)/2.;
x += theXBin ){
158 for (
double y = yCell-dyCell/2.;
y < yCell+(dyCell-theYBin/8.)/2.;
y += theYBin ){
160 double r = sqrt(
x *
x +
y *
y + zCell * zCell );
161 double eta = -0.5 *
log((
r-zCell)/(
r+zCell));
162 double phi = correctPhi.
fix(atan2(
y,
x));
174 if (
i->first==cellIndex){
175 i->second+=theWeight;
181 m_TTCmatrix[towerIndex].push_back(std::make_pair(cellIndex,theWeight));
JetConstituentVector::iterator iterator
Iterator over a rectangular window of towers.
This class defines the phi convention for Calorimeters.
Scalar phi() const
phi method
static SubSegIterator make(TOWER_ITERATOR beg, const SubSeg &subseg)
Construct a new iterator for iterating over a window.
Scalar eta() const
pseudorapidity method
tower_iterator towers() const
This class groups all DetDescr information related to a CaloCell. Provides a generic interface for al...
const CaloDetDescrElement * get_element(const Identifier &cellId) const
get element by its identifier
int module(const Identifier id) const
module [1,3]
index_t getTowerIndex(const CaloTower *aTower) const
Returns the combined index of a tower on the grid.
Definition of CaloDetDescrManager.
A rectangular window within the segmentation.
tower_table_t m_TTCmatrix
Identifier identify() const override final
cell identifier
Storable container class for CaloTower.
void calo_cell_hash_range(const Identifier id, IdentifierHash &caloCellMin, IdentifierHash &caloCellMax) const
to loop on 'global' cell hashes of one sub-calorimeter alone
::StatusCode StatusCode
StatusCode definition for legacy code.
bool getTowerIndices(const CaloTower *aTower, index_t &indexEta, index_t &indexPhi) const
Returns both and indices for a given tower.
CaloPhiRange class declaration.
Helper class for offline cell identifiers.
static double fix(double phi)
std::vector< unsigned int > m_ndxFCal
unsigned int phiIndex(float phi, float binsize)
calculate phi index for a given phi
size_t index_t
Tower map index type.
This class provides the client interface for accessing the detector description information common to...
std::vector< unsigned int > m_ndyFCal
~LArFCalTowerStore()
destructor
Helper class for LArFCAL offline identifiers.
LArFCalTowerStore()
constructor
size_type size() const noexcept
Returns the number of elements in the collection.
const LArFCAL_ID * fcal_idHelper() const
access to FCAL idHelper
index_t flagOutOfRange() const
Returns the index out-of-range indicator.
bool buildLookUp(const CaloCell_ID &cellIdHelper, const CaloDetDescrManager &theManager, CaloTowerContainer *theTowers)
setup trigger