CMS 3D CMS Logo

List of all members | Public Member Functions | Public Attributes | Private Attributes
ResonanceBuilder.Resonance Class Reference
Inheritance diagram for ResonanceBuilder.Resonance:

Public Member Functions

def __init__ (self, leg1, leg2, pdgid, status=3)
 
def charge (self)
 
def energy (self)
 
def eta (self)
 
def mass (self)
 
def p4 (self)
 
def pdgId (self)
 
def phi (self)
 
def pt (self)
 

Public Attributes

 leg1
 
 leg2
 

Private Attributes

 _charge
 
 _p4
 
 _pdgid
 
 _status
 

Detailed Description

Resonance decaying into 2 particles.

The interface of this class mimics the interface of the CMS Candidate class. 
In this way Resonance objects or CMS Candidate objects can be processed 
transparently. 

Definition at line 10 of file ResonanceBuilder.py.

Constructor & Destructor Documentation

◆ __init__()

def ResonanceBuilder.Resonance.__init__ (   self,
  leg1,
  leg2,
  pdgid,
  status = 3 
)
Parameters (stored as attributes):
leg1,2 : first and second leg.
pdgid  : pdg code of the resonance
status : status code of the resonance

Definition at line 18 of file ResonanceBuilder.py.

18  def __init__(self, leg1, leg2, pdgid, status=3):
19  '''
20  Parameters (stored as attributes):
21  leg1,2 : first and second leg.
22  pdgid : pdg code of the resonance
23  status : status code of the resonance
24  '''
25  self.leg1 = leg1
26  self.leg2 = leg2
27  self._p4 = leg1.p4() + leg2.p4()
28  self._charge = leg1.charge() + leg2.charge()
29  self._pdgid = pdgid
30  self._status = status
31 

Member Function Documentation

◆ charge()

def ResonanceBuilder.Resonance.charge (   self)

Definition at line 50 of file ResonanceBuilder.py.

50  def charge(self):
51  return self._charge
52 

References ResonanceBuilder.Resonance._charge.

◆ energy()

def ResonanceBuilder.Resonance.energy (   self)

Definition at line 38 of file ResonanceBuilder.py.

38  def energy(self):
39  return self._p4.energy()
40 

References ResonanceBuilder.Resonance._p4.

Referenced by Jet.Jet.rawEnergy().

◆ eta()

def ResonanceBuilder.Resonance.eta (   self)

Definition at line 41 of file ResonanceBuilder.py.

41  def eta(self):
42  return self._p4.eta()
43 

References ResonanceBuilder.Resonance._p4.

Referenced by Particle.Particle.__str__(), Jet.Jet.jetID(), and Jet.Jet.puJetId().

◆ mass()

def ResonanceBuilder.Resonance.mass (   self)

Definition at line 47 of file ResonanceBuilder.py.

47  def mass(self):
48  return self._p4.mass()
49 

References ResonanceBuilder.Resonance._p4.

Referenced by Particle.Particle.__str__(), and DiObject.DiMuon.__str__().

◆ p4()

def ResonanceBuilder.Resonance.p4 (   self)

Definition at line 32 of file ResonanceBuilder.py.

32  def p4(self):
33  return self._p4
34 

References ResonanceBuilder.Resonance._p4.

Referenced by Tau.Tau.dxy_approx(), Tau.Tau.dz(), and Lepton.Lepton.p4WithFSR().

◆ pdgId()

def ResonanceBuilder.Resonance.pdgId (   self)

Definition at line 53 of file ResonanceBuilder.py.

53  def pdgId(self):
54  return self._pdgid
55 
56 

References ResonanceBuilder.Resonance._pdgid.

Referenced by Particle.Particle.__str__().

◆ phi()

def ResonanceBuilder.Resonance.phi (   self)

Definition at line 44 of file ResonanceBuilder.py.

44  def phi(self):
45  return self._p4.phi()
46 

References ResonanceBuilder.Resonance._p4.

Referenced by Particle.Particle.__str__(), and ntupleDataFormat.Track.phiPull().

◆ pt()

def ResonanceBuilder.Resonance.pt (   self)

Member Data Documentation

◆ _charge

ResonanceBuilder.Resonance._charge
private

Definition at line 28 of file ResonanceBuilder.py.

Referenced by ResonanceBuilder.Resonance.charge().

◆ _p4

ResonanceBuilder.Resonance._p4
private

◆ _pdgid

ResonanceBuilder.Resonance._pdgid
private

Definition at line 29 of file ResonanceBuilder.py.

Referenced by ResonanceBuilder.Resonance.pdgId().

◆ _status

ResonanceBuilder.Resonance._status
private

Definition at line 30 of file ResonanceBuilder.py.

◆ leg1

ResonanceBuilder.Resonance.leg1

Definition at line 25 of file ResonanceBuilder.py.

Referenced by DiObject.DiObject.__str__(), and DiObject.DiObject.sumPt().

◆ leg2

ResonanceBuilder.Resonance.leg2

Definition at line 26 of file ResonanceBuilder.py.

Referenced by DiObject.DiObject.__str__(), and DiObject.DiObject.sumPt().

ResonanceBuilder.mass
mass
Definition: ResonanceBuilder.py:8
DiDispStaMuonMonitor_cfi.pt
pt
Definition: DiDispStaMuonMonitor_cfi.py:39
PVValHelper::eta
Definition: PVValidationHelpers.h:70
HCALHighEnergyHPDFilter_cfi.energy
energy
Definition: HCALHighEnergyHPDFilter_cfi.py:5
ALCARECOTkAlJpsiMuMu_cff.charge
charge
Definition: ALCARECOTkAlJpsiMuMu_cff.py:47
p4
double p4[4]
Definition: TauolaWrapper.h:92
EgammaValidation_cff.pdgId
pdgId
Definition: EgammaValidation_cff.py:117