Particle Properties
A Particle
corresponds to one entry/slot in the
event record. Its properties therefore is a mix of ones belonging
to a particle-as-such, like its identity code or four-momentum,
and ones related to the event-as-a-whole, like which mother it has.
What is stored for each particle is
- the identity code,
- the status code,
- two mother indices,
- two daughter indices,
- a colour and an anticolour index,
- the four-momentum and mass,
- the production vertex and proper lifetime,
- a pointer to the particle kind in the particle data tables.
From these, a number of further quantities may be derived.
Basic methods
The following member functions can be used to extract the information:
method
id()
the identity of a particle, according to the PDG particle codes
[Yao06].
method
status()
status code. The status code includes information on how a particle was
produced, i.e. where in the program execution it was inserted into the
event record, and why. It also tells whether the particle is still present
or not. It does not tell how a particle disappeared, whether by a decay,
a shower branching, a hadronization process, or whatever, but this is
implicit in the status code of its daughter(s). The basic scheme is:
- status = +- (10 * i + j)
- + : still remaining particles
- - : decayed/branched/fragmented/... and not remaining
- i = 1 - 9 : stage of event generation inside PYTHIA
- i = 10 -19 : reserved for future expansion
- i >= 20 : free for add-on programs
- j = 1 - 9 : further specification
In detail, the list of used or foreseen status codes is:
- 11 - 19 : beam particles
- 11 : the event as a whole
- 12 : incoming beam
- 13 : incoming beam-inside-beam (e.g. gamma
inside e)
- 14 : outgoing elastically scattered
- 15 : outgoing diffractively scattered
- 21 - 29 : particles of the hardest subprocess
- 21 : incoming
- 22 : intermediate (intended to have preserved mass)
- 23 : outgoing
- 31 - 39 : particles of subsequent subprocesses
- 31 : incoming
- 32 : intermediate (intended to have preserved mass)
- 33 : outgoing
- 41 - 49 : particles produced by initial-state-showers
- 41 : incoming on spacelike main branch
- 42 : incoming copy of recoiler
- 43 : outgoing produced in timelike sidebranch of shower
- 44 : outgoing shifted by the branching
- 51 - 59 : particles produced by final-state-showers
- 51 : outgoing produced by parton branching
- 52 : outgoing copy of recoiler, with changed momentum
- 53 : copy of recoiler when this is incoming parton,
with changed momentum
- 61 - 69 : particles produced by beam-remnant treatment
- 61 : incoming subprocess particle with primordial kT
included
- 62 : outgoing subprocess particle with primordial kT
included
- 63 : outgoing beam remnant
- 71 - 79 : partons in preparation of hadronization process
- 71 : copied partons to collect into contiguous colour singlet
- 72 : copied recoiling singlet when ministring collapses to
one hadron and momentum has to be reshuffled
- 73 : combination of very nearby partons into one
- 74 : combination of two junction quarks (+ nearby gluons)
to a diquark
- 75 : gluons split to decouple a junction-antijunction pair
- 76 : partons with momentum shuffled to decouple a
junction-antijunction pair
- 77 : temporary opposing parton when fragmenting first two
strings in to junction (should disappear again)
- 78 : temporary combined diquark end when fragmenting last
string in to junction (should disappear again)
- 81 - 89 : primary hadrons produced by hadronization process
- 81 : from ministring into one hadron
- 82 : from ministring into two hadrons
- 83, 84 : from normal string (the difference between the two
is technical, whether fragmented off from the top of the
string system or from the bottom, useful for debug only)
- 85, 86 : primary produced hadrons in junction frogmentation of
the first two string legs in to the junction,
in order of treatment
- 91 - 99 : particles produced in decay process, or by Bose-Einstein
effects
- 91 : normal decay products
- 92 : decay products after oscillation B0 <-> B0bar or
B_s0 <-> B_s0bar
- 93, 94 : decay handled by external program, normally
or with oscillation
- 99 : particles with momenta shifted by Bose-Einstein effects
(not a proper decay, but bookkept as an 1 -> 1 such,
happening after decays of short-lived resonances but before
decays of longer-lived particles)
- 101 - 199 : reserved for future expansion
- 201 - : free to be used by anybody
method
mother1(), mother2()
the indices in the event record where the first and last mothers are
stored, if any. There are five allowed combinations of mother1
and mother2
:
mother1 = mother2 = 0
: for lines 0 - 2, where line 0
represents the event as a whole, and 1 and 2 the two incoming
beam particles;
mother1 = mother2 > 0
: the particle is a "carbon copy"
of its mother, but with changed momentum as a "recoil" effect,
e.g. in a shower;
mother1 > 0, mother2 = 0
: the "normal" mother case, where
it is meaningful to speak of one single mother to several products,
in a shower or decay;
mother1 < mother2
, both > 0, for
abs(status) = 81 - 86
: primary hadrons produced from the
fragmentation of a string spanning the range from mother1
to mother2
, so that all partons in this range should be
considered mothers;
mother1 < mother2
, both > 0, except case 4: particles
with two truly different mothers, in particular the particles emerging
from a hard 2 -> n interaction.
Note 1: in backwards evolution of initial-state showers,
the mother may well appear below the daughter in the event record.
Note 2: the motherList(i)
method of the
Event
class returns a vector of all the mothers,
providing a uniform representation for all five cases.
method
daughter1(), daughter2()
the indices in the event record where the first and last daughters
are stored, if any. There are five allowed combinations of
daughter1
and daughter2
:
daughter1 = daughter2 = 0
: there are no daughters
(so far);
daughter1 = daughter2 > 0
: the particle has a
"carbon copy" as its sole daughter, but with changed momentum
as a "recoil" effect, e.g. in a shower;
daughter1 > 0, daughter2 = 0
: each of the incoming beams
has only (at most) one daughter, namely the initiator parton of the
hardest interaction; further, in a 2 -> 1 hard interaction,
like q qbar -> Z^0, or in a clustering of two nearby partons,
the initial partons only have this one daughter;
daughter1 < daughter2
, both > 0: the particle has
a range of decay products from daughter1
to
daughter2
; daughter2 < daughter1
,
both > 0: the particle has two separately stored decay products (e.g.
in backwards evolution of initial-state showers).
Note 1: in backwards evolution of initial-state showers, the
daughters may well appear below the mother in the event record.
Note 2: the mother-daughter relation normally is reciprocal,
but not always. An example is hadron beams (indices 1 and 2), where each
beam remnant and the initiator of each multiple interaction has the
respective beam as mother, but the beam itself only has the initiator
of the hardest interaction as daughter.
Note 3: the daughterList(i)
method of the
Event
class returns a vector of all the daughters,
providing a uniform representation for all five cases. With this method,
also all the daughters of the beams are caught, with the initiators of
the basic process given first, while the rest are in no guaranteed order
(since they are found by a scanning of the event record for particles
with the beam as mother, with no further information).
method
col(), acol()
the colour and anticolour tags, Les Houches Accord [Boo01]
style (starting from tag 101 by default, see below).
method
px(), py(), pz(), e()
the particle four-momentum components, alternatively extracted as a
Vec4 p()
.
method
m()
the particle mass.
method
scale()
the scale at which a parton was produced, which can be used to restrict
its radiation to lower scales in subsequent steps of the shower evolution.
Note that scale is linear in momenta, not quadratic (i.e. Q,
not Q^2).
method
xProd(), yProd(), zProd(), tProd()
the production vertex coordinates, in mm or mm/c, alternatively extracted
as a Vec4 vProd()
. The initial process is assumed to occur
at the origin.
Note:the Vec4
has components px(), py(),
pz() and e(), which of course should be reinterpreted as above.
method
tau()
the proper lifetime, in mm/c; is assigned for all hadrons with
positive nominal tau, tau_0 > 0, even if not
decayed by PYTHIA (because of one veto or another).
The same method names are overloaded to take an argument, in which case
the corresponding property is set accordingly.
Further methods
There are a few alternative methods for input:
method
statusPos(), statusNeg()
sets the status sign positive or negative, without changing the absolute value.
method
statusCode(code)
changes the absolute value but retains the original sign.
method
mothers(m1, m2)
sets both mothers in one go.
method
daughters(d1, d2)
sets both daughters in one go.
method
cols(c, ac)
sets both colour and anticolour in one go.
method
p( px, py, pz, e)
sets the four-momentum in one go;
alternative input as a Vec4
object.
method
vProd( xProd, yProd, zProd, tProd)
sets the production vertex in one go; alternative input as a
Vec4
object.
In addition, a number of derived quantities can easily be obtained
(but cannot be set), such as:
method
idAbs()
the absolute value of the particle identity code.
method
statusAbs()
the absolute value of the status code.
method
isFinal()
true for a remaining particle, i.e. one with positive status code,
else false. Thus, after an event has been fully generated, it
separates the final-state particles from intermediate-stage ones.
(If used earlier in the generation process, a particle then
considered final may well decay later.)
method
m2()
squared mass.
method
mCalc(), m2Calc()
(squared) mass calculated from the four-momentum; should agree
with m(), m2()
up to roundoff.
method
eCalc()
energy calculated from the mass and three-momentum;
should agree with e()
up to roundoff.
method
pT(), pT2()
(squared) transverse momentum.
method
mT(), mT2()
(squared) transverse mass.
method
pAbs(), pAbs2()
(squared) three-momentum size.
method
theta(), phi()
polar and azimuthal angle.
method
thetaXZ()
angle in the (p_x, p_z) plane, between -pi and
+pi, with 0 along the +z axis
method
pPlus(), pMinus()
E +- p_z.
method
y(), eta()
rapidity and pseudorapidity.
method
xDec(), yDec(), zDec(), tDec()
the decay vertex coordinates, in mm or mm/c, alternatively extracted as
a Vec4 vDec()
; this decay vertex is calculated from the
production vertex, the proper lifetime and the four-momentum assuming
no magnetic field or other detector interference; it can be used to
decide whether a decay should be performed or not, and thus is defined
also for particles which PYTHIA did not let decay.
Each Particle contains a pointer to the respective
ParticleDataEntry
object in the
particle data tables.
This gives access to properties of the particle species as such. It is
there mainly for convenience, and should be thrown if an event is
written to disk, to avoid any problems of object persistency. Should
an event later be read back in, the pointer will be recreated from the
id
code if the normal input methods are used. (Use the
Event::restorePtrs()
method
if your persistency scheme bypasses the normal methods.) This pointer is
used by the following member functions:
method
name()
the name of the particle, as a string.
method
nameWithStatus()
as above, but for negative-status particles the name is given in
brackets to emphasize that they are intermediaries.
method
spinType()
2 *spin + 1 when defined, else 0.
method
charge(), chargeType()
charge, and three times it to make an integer.
method
isCharged(), isNeutral()
charge different from or equal to 0.
method
colType()
0 for colour singlets, 1 for triplets,
-1 for antitriplets and 2 for octets.
method
m0()
the nominal mass of the particle, according to the data tables.
method
mWidth(), mMin(), mMax()
the width of the particle, and the minimum and maximum allowed mass value
for particles with a width, according to the data tables.
method
mass()
the mass of the particle, picked according to a Breit-Wigner
distribution for particles with width, and thus different each
time called.
method
constituentMass()
will give the constituent masses for quarks and diquarks,
else the same masses as with m0()
.
method
isResonance()
particles where the decay is to be treated as part of the hard process,
typically with nominal mass above 20 GeV (W^+-, Z^0, t, ...).
method
mayDecay()
flag whether particle has been declared unstable or not, offering
the main user switch to select which particle species to decay.
method
canDecay()
flag whether decay modes have been declared for a particle,
so that it could be decayed, should that be requested.
method
doExternalDecay()
particles that are decayed by an external program.
method
isVisible()
particles with strong or electric charge, or composed of ones having it,
which thereby should be considered visible in a normal detector.
method
doForceWidth()
resonances that have code to recalculate the width in mWidth
from the nominal mass value m0
, but where nevertheless the
stored mWidth value is used.
method
isLepton()
true for a lepton or an antilepton (including neutrinos).
method
isQuark()
true for a quark or an antiquark.
method
isGluon()
true for a gluon.
method
isHadron()
true for a hadron (made up out of normal quarks and gluons,
i.e. not for R-hadrons and other exotic states).
method
particleData()
a reference to the ParticleDataEntry.
There are some further methods, inherited from Vec4
,
to rotate and boost the four-momentum.
Not part of the event class proper, but obviously tightly linked,
are the metods m(Particle, Particle)
and
m2(Particle, Particle)
to calculate the (squared)
invariant mass of two particles.
The
Event
class also contains a few methods defined for individual particles,
but these may require some search in the event record and therefore
cannot be defined as a Particle
method.
Currently there is no information on polarization states.