CMS 3D CMS Logo

CaloTower Class Reference

Date
2008/07/10 16:29:01
Revision
1.9
More...

#include <DataFormats/CaloTowers/interface/CaloTower.h>

Inheritance diagram for CaloTower:

reco::LeafCandidate reco::Candidate reco::Particle

List of all members.

Public Types

typedef CaloTowerDetId key_type

Public Member Functions

void addConstituent (DetId id)
void addConstituents (const std::vector< DetId > &ids)
 CaloTower (const CaloTowerDetId &id, double emE, double hadE, double outerE, int ecal_tp, int hcal_tp, const LorentzVector p4, GlobalPoint emPosition, GlobalPoint hadPosition)
 CaloTower (const CaloTowerDetId &id, double emE, double hadE, double outerE, int ecal_tp, int hcal_tp, const PolarLorentzVector p4, GlobalPoint emPosition, GlobalPoint hadPosition)
 CaloTower ()
DetId constituent (size_t i) const
const std::vector< DetId > & constituents () const
size_t constituentsSize () const
float ecalTime () const
double emEnergy () const
double emEt () const
int emLvl1 () const
const GlobalPointemPosition () const
double hadEnergy () const
double hadEnergyHeInnerLayer () const
double hadEnergyHeOuterLayer () const
double hadEt () const
int hadLv11 () const
const GlobalPointhadPosition () const
float hcalTime () const
CaloTowerDetId id () const
int ieta () const
int ietaAbs () const
int iphi () const
int numCrystals () const
double outerEnergy () const
double outerEt () const
void setEcalTime (int t)
void setHcalTime (int t)
int zside () const

Private Attributes

std::vector< DetIdconstituents_
int ecalTime_
Double32_t emE_
int emLvl1_
GlobalPoint emPosition_
Double32_t hadE_
int hadLvl1_
GlobalPoint hadPosition_
int hcalTime_
CaloTowerDetId id_
Double32_t outerE_


Detailed Description

Date
2008/07/10 16:29:01
Revision
1.9

Author:
J. Mans - Minnesota

Definition at line 28 of file CaloTower.h.


Member Typedef Documentation

typedef CaloTowerDetId CaloTower::key_type

Definition at line 30 of file CaloTower.h.


Constructor & Destructor Documentation

CaloTower::CaloTower (  ) 

Definition at line 3 of file CaloTower.cc.

References emE_, emLvl1_, hadE_, hadLvl1_, and outerE_.

00003                      {
00004   emE_=0;
00005   hadE_=0;
00006   outerE_=0;
00007   emLvl1_=0;
00008   hadLvl1_=0;
00009 }

CaloTower::CaloTower ( const CaloTowerDetId id,
double  emE,
double  hadE,
double  outerE,
int  ecal_tp,
int  hcal_tp,
const PolarLorentzVector  p4,
GlobalPoint  emPosition,
GlobalPoint  hadPosition 
)

Definition at line 11 of file CaloTower.cc.

00015                                                 : 
00016   LeafCandidate(0, p4, Point(0,0,0)),  
00017   id_(id),
00018   emE_(emE), hadE_(hadE), outerE_(outerE),
00019   emLvl1_(ecal_tp), hadLvl1_(hcal_tp),
00020   emPosition_(emPos), hadPosition_(hadPos)  {}

CaloTower::CaloTower ( const CaloTowerDetId id,
double  emE,
double  hadE,
double  outerE,
int  ecal_tp,
int  hcal_tp,
const LorentzVector  p4,
GlobalPoint  emPosition,
GlobalPoint  hadPosition 
)

Definition at line 23 of file CaloTower.cc.

00027                                                 : 
00028   LeafCandidate(0, p4, Point(0,0,0)),  
00029   id_(id),
00030   emE_(emE), hadE_(hadE), outerE_(outerE),
00031   emLvl1_(ecal_tp), hadLvl1_(hcal_tp),
00032   emPosition_(emPos), hadPosition_(hadPos)  {}


Member Function Documentation

void CaloTower::addConstituent ( DetId  id  )  [inline]

Definition at line 51 of file CaloTower.h.

References constituents_.

00051 { constituents_.push_back( id ); }

void CaloTower::addConstituents ( const std::vector< DetId > &  ids  ) 

Definition at line 35 of file CaloTower.cc.

References constituents_.

Referenced by CaloTowersCreationAlgo::convert().

00035                                                              {
00036   constituents_.reserve(constituents_.size()+ids.size());
00037   constituents_.insert(constituents_.end(),ids.begin(),ids.end());
00038 }

DetId CaloTower::constituent ( size_t  i  )  const [inline]

Definition at line 60 of file CaloTower.h.

References constituents_.

Referenced by CaloSpecificAlgo::addInfo(), JetToDigiDump::analyze(), JetMatchingTools::getConstituentIds(), JetMatchingTools::getConstituents(), and CaloTowersCreationAlgo::rescale().

00060 { return constituents_[ i ]; }

const std::vector<DetId>& CaloTower::constituents (  )  const [inline]

Definition at line 58 of file CaloTower.h.

References constituents_.

00058 { return constituents_; }

size_t CaloTower::constituentsSize (  )  const [inline]

Definition at line 59 of file CaloTower.h.

References constituents_.

Referenced by CaloSpecificAlgo::addInfo(), JetToDigiDump::analyze(), CaloTowersCreationAlgo::finish(), JetMatchingTools::getConstituentIds(), JetMatchingTools::getConstituents(), and CaloTowersCreationAlgo::rescale().

00059 { return constituents_.size(); }

float CaloTower::ecalTime (  )  const [inline]

Definition at line 78 of file CaloTower.h.

References ecalTime_.

Referenced by CaloTowersCreationAlgo::rescale().

00078 { return float(ecalTime_) * 0.01; }

double CaloTower::emEnergy (  )  const [inline]

Definition at line 62 of file CaloTower.h.

References emE_.

Referenced by JetToDigiDump::analyze(), CaloTowerAnalyzer::analyze(), muonisolation::CaloExtractorByAssociator::deposits(), PFRootEventManager::fillOutEventWithCaloTowers(), FastL1Region::FillTower_Scaled(), JetMaker::makeSpecific(), and CaloTowersCreationAlgo::rescale().

00062 { return emE_ ; }

double CaloTower::emEt (  )  const [inline]

Definition at line 65 of file CaloTower.h.

References emE_, funct::sin(), and reco::Particle::theta().

Referenced by CaloSpecificAlgo::addInfo(), CaloTowerAnalyzer::analyze(), muonisolation::CaloExtractorByAssociator::deposits(), FastL1Region::FillTower(), FastL1Region::FillTower_Scaled(), and operator<<().

00065 { return emE_ * sin( theta() ); }

int CaloTower::emLvl1 (  )  const [inline]

Definition at line 72 of file CaloTower.h.

References emLvl1_.

00072 { return emLvl1_; }

const GlobalPoint& CaloTower::emPosition (  )  const [inline]

Definition at line 69 of file CaloTower.h.

References emPosition_.

00069 { return emPosition_ ; }

double CaloTower::hadEnergy (  )  const [inline]

Definition at line 63 of file CaloTower.h.

References hadE_.

Referenced by JetToDigiDump::analyze(), CaloTowerAnalyzer::analyze(), muonisolation::CaloExtractorByAssociator::deposits(), PFRootEventManager::fillOutEventWithCaloTowers(), FastL1Region::FillTower_Scaled(), JetMaker::makeSpecific(), and CaloTowersCreationAlgo::rescale().

00063 { return hadE_ ; }

double CaloTower::hadEnergyHeInnerLayer (  )  const [inline]

Definition at line 76 of file CaloTower.h.

References hadE_, id_, CaloTowerDetId::ietaAbs(), and outerE_.

00076 { return (id_.ietaAbs()<18 || id_.ietaAbs()>29)? 0 : hadE_ - outerE_; }

double CaloTower::hadEnergyHeOuterLayer (  )  const [inline]

Definition at line 75 of file CaloTower.h.

References id_, CaloTowerDetId::ietaAbs(), and outerE_.

00075 { return (id_.ietaAbs()<18 || id_.ietaAbs()>29)? 0 : outerE_; }

double CaloTower::hadEt (  )  const [inline]

Definition at line 66 of file CaloTower.h.

References hadE_, funct::sin(), and reco::Particle::theta().

Referenced by CaloSpecificAlgo::addInfo(), CaloTowerAnalyzer::analyze(), muonisolation::CaloExtractorByAssociator::deposits(), FastL1Region::FillTower(), FastL1Region::FillTower_Scaled(), and operator<<().

00066 { return hadE_ * sin( theta() ); }

int CaloTower::hadLv11 (  )  const [inline]

Definition at line 73 of file CaloTower.h.

References hadLvl1_.

00073 { return hadLvl1_; }

const GlobalPoint& CaloTower::hadPosition (  )  const [inline]

Definition at line 70 of file CaloTower.h.

References hadPosition_.

00070 { return hadPosition_ ; }

float CaloTower::hcalTime (  )  const [inline]

Definition at line 79 of file CaloTower.h.

References hcalTime_.

Referenced by CaloTowersCreationAlgo::rescale().

00079 { return float(hcalTime_) * 0.01; }

CaloTowerDetId CaloTower::id ( void   )  const [inline]

Definition at line 57 of file CaloTower.h.

References id_.

Referenced by JetToDigiDump::analyze(), CaloTowerAnalyzer::analyze(), muonisolation::CaloExtractorByAssociator::deposits(), FastL1Region::FillTower(), FastL1Region::FillTower_Scaled(), cms::BasePilupSubtractionJetProducer::ieta(), cms::BasePilupSubtractionJetProducer::iphi(), JetMaker::makeSpecific(), operator<<(), operator==(), CaloTowersCreationAlgo::rescale(), and DumpEvent::WriteJets().

00057 { return id_; }

int CaloTower::ieta (  )  const [inline]

Definition at line 81 of file CaloTower.h.

References id_, and CaloTowerDetId::ieta().

00081 { return id_.ieta(); }

int CaloTower::ietaAbs (  )  const [inline]

Definition at line 82 of file CaloTower.h.

References id_, and CaloTowerDetId::ietaAbs().

00082 { return id_.ietaAbs(); }

int CaloTower::iphi (  )  const [inline]

Definition at line 83 of file CaloTower.h.

References id_, and CaloTowerDetId::iphi().

00083 { return id_.iphi(); }

int CaloTower::numCrystals (  )  const

Definition at line 40 of file CaloTower.cc.

References constituents_, DetId::Ecal, id_, CaloTowerDetId::ietaAbs(), and it.

00040                                  {
00041   if (id_.ietaAbs()>29) return 0;
00042   
00043   int nC = 0;
00044   std::vector<DetId>::const_iterator it = constituents_.begin();
00045   for (; it!=constituents_.end(); ++it) {
00046     if (it->det()==DetId::Ecal) ++nC;
00047   }
00048 
00049   return nC;
00050 }

double CaloTower::outerEnergy (  )  const [inline]

Definition at line 64 of file CaloTower.h.

References id_, CaloTowerDetId::ietaAbs(), and outerE_.

Referenced by JetToDigiDump::analyze(), CaloTowerAnalyzer::analyze(), muonisolation::CaloExtractorByAssociator::deposits(), JetMaker::makeSpecific(), and CaloTowersCreationAlgo::rescale().

00064 { return (id_.ietaAbs()<16)? outerE_ : 0.0; }

double CaloTower::outerEt (  )  const [inline]

Definition at line 67 of file CaloTower.h.

References id_, CaloTowerDetId::ietaAbs(), outerE_, funct::sin(), and reco::Particle::theta().

Referenced by CaloSpecificAlgo::addInfo(), muonisolation::CaloExtractorByAssociator::deposits(), FastL1Region::FillTower(), FastL1Region::FillTower_Scaled(), and operator<<().

00067 { return (id_.ietaAbs()<16)? outerE_ * sin( theta() ) : 0.0; }

void CaloTower::setEcalTime ( int  t  )  [inline]

Definition at line 53 of file CaloTower.h.

References ecalTime_.

Referenced by CaloTowersCreationAlgo::convert().

00053 { ecalTime_ = t; };

void CaloTower::setHcalTime ( int  t  )  [inline]

Definition at line 54 of file CaloTower.h.

References hcalTime_.

Referenced by CaloTowersCreationAlgo::convert().

00054 { hcalTime_ = t; };

int CaloTower::zside (  )  const [inline]

Definition at line 84 of file CaloTower.h.

References id_, and CaloTowerDetId::zside().

00084 { return id_.zside(); }


Member Data Documentation

std::vector<DetId> CaloTower::constituents_ [private]

Definition at line 102 of file CaloTower.h.

Referenced by addConstituent(), addConstituents(), constituent(), constituents(), constituentsSize(), and numCrystals().

int CaloTower::ecalTime_ [private]

Definition at line 96 of file CaloTower.h.

Referenced by ecalTime(), and setEcalTime().

Double32_t CaloTower::emE_ [private]

Definition at line 99 of file CaloTower.h.

Referenced by CaloTower(), emEnergy(), and emEt().

int CaloTower::emLvl1_ [private]

Definition at line 101 of file CaloTower.h.

Referenced by CaloTower(), and emLvl1().

GlobalPoint CaloTower::emPosition_ [private]

Definition at line 92 of file CaloTower.h.

Referenced by emPosition().

Double32_t CaloTower::hadE_ [private]

Definition at line 99 of file CaloTower.h.

Referenced by CaloTower(), hadEnergy(), hadEnergyHeInnerLayer(), and hadEt().

int CaloTower::hadLvl1_ [private]

Definition at line 101 of file CaloTower.h.

Referenced by CaloTower(), and hadLv11().

GlobalPoint CaloTower::hadPosition_ [private]

Definition at line 93 of file CaloTower.h.

Referenced by hadPosition().

int CaloTower::hcalTime_ [private]

Definition at line 97 of file CaloTower.h.

Referenced by hcalTime(), and setHcalTime().

CaloTowerDetId CaloTower::id_ [private]

Definition at line 89 of file CaloTower.h.

Referenced by hadEnergyHeInnerLayer(), hadEnergyHeOuterLayer(), id(), ieta(), ietaAbs(), iphi(), numCrystals(), outerEnergy(), outerEt(), and zside().

Double32_t CaloTower::outerE_ [private]

Definition at line 99 of file CaloTower.h.

Referenced by CaloTower(), hadEnergyHeInnerLayer(), hadEnergyHeOuterLayer(), outerEnergy(), and outerEt().


The documentation for this class was generated from the following files:
Generated on Tue Jun 9 18:15:59 2009 for CMSSW by  doxygen 1.5.4