CepGen 1.2.5
Central exclusive processes event generator
|
Kinematic information for one particle. More...
#include <CepGen/Event/Particle.h>
Public Types | |
enum class | Status { PrimordialIncoming = -9 , DebugResonance = -5 , Resonance = -4 , Fragmented = -3 , Propagator = -2 , Incoming = -1 , Undefined = 0 , FinalState = 1 , Undecayed = 2 , Unfragmented = 3 } |
Internal status code for a particle. More... | |
enum | Role { UnknownRole = -1 , IncomingBeam1 = 1 , IncomingBeam2 = 2 , OutgoingBeam1 = 3 , OutgoingBeam2 = 5 , CentralSystem = 6 , Intermediate = 4 , Parton1 = 41 , Parton2 = 42 } |
Public Member Functions | |
Particle (Role role=Role::UnknownRole, pdgid_t id=0, Status st=Status::Undefined) | |
Build using the role of the particle in the process and its PDG id. | |
bool | operator< (const Particle &) const |
Comparison operator (from unique identifier) | |
bool | operator== (const Particle &) const |
Equality operator. | |
int | id () const |
Unique identifier (in a Event object context) Set the particle unique identifier in an event. | |
Particle & | setId (int id) |
float | charge () const |
Electric charge (given as a float number, for the quarks and bound states) Set whether we are coping with the particle or its antiparticle. | |
Particle & | setAntiparticle (bool anti) |
Role | role () const |
Role in the considered process Set the particle role in the process. | |
Particle & | setRole (const Role &role) |
Status | status () const |
Particle status Set the particle decay/stability status. | |
Particle & | setStatus (Status status) |
Particle & | setStatus (int status) |
Set the particle decay/stability status. | |
Particle & | setPdgId (pdgid_t pdg, short ch=0) |
Set the PDG identifier (along with the particle's electric charge) | |
pdgid_t | pdgId () const |
Retrieve the objectified PDG identifier Set the PDG identifier (along with the particle's electric charge) | |
Particle & | setIntegerPdgId (long pdg_id) |
long | integerPdgId () const |
Retrieve the integer value of the PDG identifier. | |
float | helicity () const |
Particle's helicity Set the helicity of the particle. | |
Particle & | setHelicity (float heli) |
Momentum & | momentum () |
Retrieve the momentum object associated with this particle Retrieve the momentum object associated with this particle. | |
const Momentum & | momentum () const |
Particle & | setMomentum (const Momentum &, bool offshell=false) |
Associate a momentum object to this particle. | |
Particle & | setMomentum (double px, double py, double pz, double e=-1.) |
Set the 3- or 4-momentum associated to the particle. | |
Particle & | setMomentum (double p[4]) |
Set the 4-momentum associated to the particle. | |
bool | valid () |
Is this particle a valid particle which can be used for kinematic computations? | |
bool | primary () const |
Is this particle a primary particle? | |
Particle & | addMother (Particle &part) |
Set the mother particle. | |
ParticlesIds | mothers () const |
Identifier to the mother particles. | |
ParticlesIds & | mothers () |
Identifier to the mother particles. | |
Particle & | addDaughter (Particle &part) |
Add a decay product. | |
ParticlesIds | daughters () const |
Identifiers list of all daughter particles. | |
ParticlesIds & | daughters () |
Identifiers list of all daughter particles. | |
Protected Attributes | |
int | id_ {-1} |
Unique identifier in an event. | |
bool | antiparticle_ {false} |
Are we dealing with the particle or antiparticle? | |
Momentum | momentum_ |
Momentum properties handler. | |
float | helicity_ {0.} |
Helicity. | |
Role | role_ {UnknownRole} |
Role in the process. | |
int | status_ {(int)Status::Undefined} |
Decay/stability status. | |
ParticlesIds | mothers_ |
List of mother particles. | |
ParticlesIds | daughters_ |
List of daughter particles. | |
pdgid_t | pdg_id_ {(pdgid_t)0} |
PDG id. | |
Friends | |
std::ostream & | operator<< (std::ostream &os, const Status &) |
Human-readable particle's status Role of the particle in the process. | |
std::ostream & | operator<< (std::ostream &os, const Role &) |
Human-readable particle's role in the event. | |
std::ostream & | operator<< (std::ostream &, const Particle &) |
Human-readable dump of particle information. | |
Definition at line 33 of file Particle.h.
enum Role |
Definition at line 50 of file Particle.h.
|
strong |
Enumerator | |
---|---|
PrimordialIncoming | Incoming beam particle. |
DebugResonance | Intermediate resonance (for processes developers) |
Resonance | Already decayed intermediate resonance. |
Fragmented | Already fragmented outgoing beam. |
Propagator | Generic propagator. |
Incoming | Incoming parton. |
Undefined | Undefined particle. |
FinalState | Stable, final state particle. |
Undecayed | Particle to be decayed externally. |
Unfragmented | Particle to be hadronised externally. |
Definition at line 36 of file Particle.h.
|
explicit |
[in] | role | Role of the particle in the process |
[in] | id | PDG identifier |
[in] | st | Current status |
Definition at line 28 of file Particle.cpp.
Definition at line 59 of file Particle.cpp.
Definition at line 47 of file Particle.cpp.
float charge | ( | ) | const |
Definition at line 45 of file Particle.cpp.
ParticlesIds & daughters | ( | ) |
Definition at line 148 of file Particle.h.
ParticlesIds daughters | ( | ) | const |
Definition at line 147 of file Particle.h.
float helicity | ( | ) | const |
Definition at line 116 of file Particle.h.
int id | ( | ) | const |
Definition at line 76 of file Particle.h.
long integerPdgId | ( | ) | const |
Definition at line 102 of file Particle.cpp.
Momentum & momentum | ( | ) |
Definition at line 123 of file Particle.h.
const Momentum & momentum | ( | ) | const |
Definition at line 125 of file Particle.h.
ParticlesIds & mothers | ( | ) |
Definition at line 145 of file Particle.h.
ParticlesIds mothers | ( | ) | const |
Definition at line 144 of file Particle.h.
bool operator< | ( | const Particle & | rhs | ) | const |
Definition at line 30 of file Particle.cpp.
bool operator== | ( | const Particle & | oth | ) | const |
Definition at line 32 of file Particle.cpp.
pdgid_t pdgId | ( | ) | const |
[in] | pdg_id | PDG identifier (incl. electric charge in e) |
Definition at line 91 of file Particle.cpp.
bool primary | ( | ) | const |
Definition at line 142 of file Particle.h.
Role role | ( | ) | const |
Definition at line 88 of file Particle.h.
Particle & setAntiparticle | ( | bool | anti | ) |
Definition at line 84 of file Particle.h.
Particle & setHelicity | ( | float | heli | ) |
Definition at line 118 of file Particle.h.
Particle & setId | ( | int | id | ) |
Definition at line 78 of file Particle.h.
Particle & setIntegerPdgId | ( | long | pdg_id | ) |
Definition at line 95 of file Particle.cpp.
[in] | offshell | allow the 4-momentum mass to compensate for E-p balance? |
Definition at line 77 of file Particle.cpp.
Particle & setMomentum | ( | double | p[4] | ) |
[in] | p | 4-momentum |
Definition at line 137 of file Particle.h.
Particle & setMomentum | ( | double | px, |
double | py, | ||
double | pz, | ||
double | e = -1. |
||
) |
[in] | px | Momentum along the \(x\)-axis, in GeV/c |
[in] | py | Momentum along the \(y\)-axis, in GeV/c |
[in] | pz | Momentum along the \(z\)-axis, in GeV/c |
[in] | e | Energy, in GeV |
Definition at line 84 of file Particle.cpp.
[in] | pdg | PDG identifier |
[in] | ch | Electric charge (0, 1, or -1) |
Definition at line 93 of file Particle.cpp.
Definition at line 90 of file Particle.h.
Particle & setStatus | ( | int | status | ) |
Definition at line 101 of file Particle.h.
Definition at line 96 of file Particle.h.
Status status | ( | ) | const |
Definition at line 94 of file Particle.h.
bool valid | ( | ) |
Definition at line 37 of file Particle.cpp.
|
friend |
Definition at line 104 of file Particle.cpp.
|
friend |
Definition at line 156 of file Particle.cpp.
|
friend |
Definition at line 130 of file Particle.cpp.
|
protected |
Definition at line 156 of file Particle.h.
|
protected |
Definition at line 162 of file Particle.h.
|
protected |
Definition at line 158 of file Particle.h.
|
protected |
Definition at line 155 of file Particle.h.
|
protected |
Definition at line 157 of file Particle.h.
|
protected |
Definition at line 161 of file Particle.h.
Definition at line 163 of file Particle.h.
|
protected |
Definition at line 159 of file Particle.h.
|
protected |
Definition at line 160 of file Particle.h.