CMS 3D CMS Logo

List of all members | Public Member Functions | Private Attributes
reco::isodeposit::NumCrystalEtaPhiVeto Class Reference
Inheritance diagram for reco::isodeposit::NumCrystalEtaPhiVeto:
reco::isodeposit::AbsVeto

Public Member Functions

virtual void centerOn (double eta, double phi) override
 
 NumCrystalEtaPhiVeto (const math::XYZVectorD &dir, double iEta, double iPhi)
 
 NumCrystalEtaPhiVeto (Direction dir, double iEta, double iPhi)
 
virtual bool veto (double eta, double phi, float value) const override
 Return "true" if a deposit at specific (eta,phi) with that value must be vetoed in the sum. More...
 
- Public Member Functions inherited from reco::isodeposit::AbsVeto
virtual ~AbsVeto ()
 

Private Attributes

double iEta_
 
double iPhi_
 
Direction vetoDir_
 

Detailed Description

Definition at line 41 of file IsoDepositVetoFactory.cc.

Constructor & Destructor Documentation

reco::isodeposit::NumCrystalEtaPhiVeto::NumCrystalEtaPhiVeto ( const math::XYZVectorD dir,
double  iEta,
double  iPhi 
)
inline

Definition at line 43 of file IsoDepositVetoFactory.cc.

reco::isodeposit::NumCrystalEtaPhiVeto::NumCrystalEtaPhiVeto ( Direction  dir,
double  iEta,
double  iPhi 
)
inline

Member Function Documentation

virtual void reco::isodeposit::NumCrystalEtaPhiVeto::centerOn ( double  eta,
double  phi 
)
inlineoverridevirtual

Relocates this veto so that the new center is at some (eta,phi). Must be implemented on the specific AbsVeto subclass: in this mother class it just throws exception

Reimplemented from reco::isodeposit::AbsVeto.

Definition at line 63 of file IsoDepositVetoFactory.cc.

virtual bool reco::isodeposit::NumCrystalEtaPhiVeto::veto ( double  eta,
double  phi,
float  value 
) const
inlineoverridevirtual

Return "true" if a deposit at specific (eta,phi) with that value must be vetoed in the sum.

Implements reco::isodeposit::AbsVeto.

Definition at line 51 of file IsoDepositVetoFactory.cc.

References M_PI.

51  {
52  double dPhi = phi - vetoDir_.phi();
53  double dEta = eta - vetoDir_.eta();
54  while( dPhi < -M_PI ) dPhi += 2*M_PI;
55  while( dPhi >= M_PI ) dPhi -= 2*M_PI;
56  if( fabs(vetoDir_.eta()) < 1.479) {
57  return ( (fabs(dEta) < 0.0174*iEta_) && (fabs(dPhi) < 0.0174*iPhi_) );
58  } else {
59  return ( (fabs(dEta) < 0.00864*fabs(sinh(eta))*iEta_) &&
60  (fabs(dPhi) < 0.00864*fabs(sinh(eta))*iPhi_) );
61  }
62  }
#define M_PI

Member Data Documentation

double reco::isodeposit::NumCrystalEtaPhiVeto::iEta_
private

Definition at line 66 of file IsoDepositVetoFactory.cc.

double reco::isodeposit::NumCrystalEtaPhiVeto::iPhi_
private

Definition at line 66 of file IsoDepositVetoFactory.cc.

Direction reco::isodeposit::NumCrystalEtaPhiVeto::vetoDir_
private

Definition at line 65 of file IsoDepositVetoFactory.cc.