ATLAS Offline Software
Public Member Functions | Public Attributes | Private Attributes | List of all members
python.samplers.EEtaMPhiSampler Class Reference
Inheritance diagram for python.samplers.EEtaMPhiSampler:
Collaboration diagram for python.samplers.EEtaMPhiSampler:

Public Member Functions

def __init__ (self, energy, eta, mass=0.0, phi=[0, TWOPI])
 
def energy (self)
 
def energy (self, x)
 
def eta (self)
 
def eta (self, x)
 
def mass (self)
 
def mass (self, x)
 
def phi (self)
 
def phi (self, x)
 
def shoot (self)
 
def __call__ (self)
 

Public Attributes

 energy
 
 eta
 
 mass
 
 phi
 

Private Attributes

 _e
 
 _eta
 
 _m
 
 _phi
 

Detailed Description

Definition at line 435 of file samplers.py.

Constructor & Destructor Documentation

◆ __init__()

def python.samplers.EEtaMPhiSampler.__init__ (   self,
  energy,
  eta,
  mass = 0.0,
  phi = [0, TWOPI] 
)

Definition at line 440 of file samplers.py.

440  def __init__(self, energy, eta, mass=0.0, phi=[0, TWOPI]):
441  self.energy = energy
442  self.eta = eta
443  self.mass = mass
444  self.phi = phi
445 

Member Function Documentation

◆ __call__()

def python.samplers.Sampler.__call__ (   self)
inherited
This is the call method that will actually be used (so that normal
functions can also be passed in as samplers).

Definition at line 17 of file samplers.py.

17  def __call__(self):
18  """This is the call method that will actually be used (so that normal
19  functions can also be passed in as samplers)."""
20  return self.shoot()
21 

◆ energy() [1/2]

def python.samplers.EEtaMPhiSampler.energy (   self)

Definition at line 447 of file samplers.py.

447  def energy(self):
448  "Energy sampler"
449  return self._e

◆ energy() [2/2]

def python.samplers.EEtaMPhiSampler.energy (   self,
  x 
)

Definition at line 451 of file samplers.py.

451  def energy(self, x):
452  self._e = mksampler(x)
453 

◆ eta() [1/2]

def python.samplers.EEtaMPhiSampler.eta (   self)

Definition at line 455 of file samplers.py.

455  def eta(self):
456  "Pseudorapidity sampler"
457  return self._eta

◆ eta() [2/2]

def python.samplers.EEtaMPhiSampler.eta (   self,
  x 
)

Definition at line 459 of file samplers.py.

459  def eta(self, x):
460  self._eta = mksampler(x)
461 

◆ mass() [1/2]

def python.samplers.EEtaMPhiSampler.mass (   self)

Definition at line 463 of file samplers.py.

463  def mass(self):
464  "Mass sampler"
465  return self._m

◆ mass() [2/2]

def python.samplers.EEtaMPhiSampler.mass (   self,
  x 
)

Definition at line 467 of file samplers.py.

467  def mass(self, x):
468  self._m = mksampler(x)
469 

◆ phi() [1/2]

def python.samplers.EEtaMPhiSampler.phi (   self)

Definition at line 471 of file samplers.py.

471  def phi(self):
472  "Azimuthal angle sampler"
473  return self._phi

◆ phi() [2/2]

def python.samplers.EEtaMPhiSampler.phi (   self,
  x 
)

Definition at line 475 of file samplers.py.

475  def phi(self, x):
476  self._phi = mksampler(x)
477 

◆ shoot()

def python.samplers.EEtaMPhiSampler.shoot (   self)
eta = - ln(tan(theta/2)) / 2
=> theta = 2 atan( exp(-eta) )

Reimplemented from python.samplers.Sampler.

Definition at line 478 of file samplers.py.

478  def shoot(self):
479  """
480  eta = - ln(tan(theta/2)) / 2
481  => theta = 2 atan( exp(-eta) )
482  """
483  eta = self.eta()
484  theta = 2 * math.atan(math.exp(-eta))
485  e = self.energy()
486  m = self.mass()
487  p = math.sqrt( e**2 - m**2 )
488  pz = p * math.cos(theta)
489  pt = p * math.sin(theta)
490  phi = self.phi()
491  px = pt * math.cos(phi)
492  py = pt * math.sin(phi)
493  v4 = ROOT.TLorentzVector(px, py, pz, e)
494  return v4
495 
496 

Member Data Documentation

◆ _e

python.samplers.EEtaMPhiSampler._e
private

Definition at line 452 of file samplers.py.

◆ _eta

python.samplers.EEtaMPhiSampler._eta
private

Definition at line 460 of file samplers.py.

◆ _m

python.samplers.EEtaMPhiSampler._m
private

Definition at line 468 of file samplers.py.

◆ _phi

python.samplers.EEtaMPhiSampler._phi
private

Definition at line 476 of file samplers.py.

◆ energy

python.samplers.EEtaMPhiSampler.energy

Definition at line 441 of file samplers.py.

◆ eta

python.samplers.EEtaMPhiSampler.eta

Definition at line 442 of file samplers.py.

◆ mass

python.samplers.EEtaMPhiSampler.mass

Definition at line 443 of file samplers.py.

◆ phi

python.samplers.EEtaMPhiSampler.phi

Definition at line 444 of file samplers.py.


The documentation for this class was generated from the following file:
Base_Fragment.mass
mass
Definition: Sherpa_i/share/common/Base_Fragment.py:59
ParticleGun_FastCalo_ChargeFlip_Config.energy
energy
Definition: ParticleGun_FastCalo_ChargeFlip_Config.py:78
python.samplers.mksampler
def mksampler(x)
Convenience function for sampler-making from Python literals.
Definition: samplers.py:245
python.processes.powheg.ZZ.ZZ.__init__
def __init__(self, base_directory, **kwargs)
Constructor: all process options are set here.
Definition: ZZ.py:18