HepMC3 event record library: GenHeavyIon Class Reference

HepMC3 event record library

Public Member Functions | Data Fields | Protected Member Functions | Private Attributes
GenHeavyIon Class Reference

## Detailed Description

Stores additional information about Heavy Ion generator.

This is an example of event attribute used to store Heavy Ion information

Examples
  HepMC3_fileIO_example.cc.

Definition at line 26 of file GenHeavyIon.h.

`#include <GenHeavyIon.h>`

Inheritance diagram for GenHeavyIon:
[legend]
Collaboration diagram for GenHeavyIon:
[legend]

## Public Member Functions
| GenHeavyIon ()
| Empty default constructor.
bool | from_string (const std::string &att) override
| Implementation of Attribute::from_string.
bool | to_string (std::string &att) const override
| Implementation of Attribute::to_string.
bool | operator== (const GenHeavyIon &) const
| Operator ==.
bool | operator!= (const GenHeavyIon &) const
| Operator !=.
void | set (const int &nh, const int &np, const int &nt, const int &nc, const int &ns, const int &nsp, const int &nnw=0, const int &nwn=0, const int &nwnw=0, const double &im=0., const double &pl=0., const double &ec=0., const double &s=0., const double &cent=0., const double &usrcent=0.)
| Set all fields.
bool | is_valid () const
| Verify that the instance contains non-zero information.
virtual bool | init ()
| Optionally initialize the attribute after from_string.
virtual bool | init (const GenRunInfo &)
| Optionally initialize the attribute after from_string.
bool | is_parsed () const
| Check if this attribute is parsed.
const std::string & | unparsed_string () const
| Get unparsed string.
const GenEvent * | event () const
GenParticlePtr | particle ()
ConstGenParticlePtr | particle () const
GenVertexPtr | vertex ()
ConstGenVertexPtr | vertex () const

## Data Fields
int | Ncoll_hard
| the number of hard nucleon-nucleon collisions.
int | Npart_proj
| the number of participating nucleons in the projectile.
int | Npart_targ
| the number of participating nucleons in the target.
int | Ncoll
| the number of inelastic nucleon-nucleon collisions.
int | spectator_neutrons
| Total number of spectator neutrons.
int | spectator_protons
| Total number of spectator protons.
int | N_Nwounded_collisions
| Collisions with a diffractively excited target nucleon.
int | Nwounded_N_collisions
| Collisions with a diffractively excited projectile nucleon.
int | Nwounded_Nwounded_collisions
| Non-diffractive or doubly diffractive collisions.
double | impact_parameter
| The impact parameter.
double | event_plane_angle
| The event plane angle.
double | eccentricity
| The eccentricity.
double | sigma_inel_NN
| The assumed inelastic nucleon-nucleon cross section.
double | centrality
| The centrality.
double | user_cent_estimate
| A user defined centrality estimator.
int | Nspec_proj_n
| The number of spectator neutrons in the projectile.
int | Nspec_targ_n
| The number of spectator neutrons in the target.
int | Nspec_proj_p
| The number of spectator protons in the projectile.
int | Nspec_targ_p
| The number of spectator protons in the target.
std::map< int, double > | participant_plane_angles
| Participant plane angles.
std::map< int, double > | eccentricities
| Eccentricities.
bool | forceoldformat
| force writing in old format for compatibility purposes.

## Protected Member Functions
void | set_is_parsed (bool flag)
| Set is_parsed flag.
void | set_unparsed_string (const std::string &st)
| Set unparsed string.

## Private Attributes
bool | m_is_parsed
| Is this attribute parsed?
std::string | m_string
| Raw (unparsed) string.
const GenEvent * | m_event
GenParticlePtr | m_particle
| controlling GenEvent object.
GenVertexPtr | m_vertex
| Vertex to which assigned.

## Constructor & Destructor Documentation

## ◆ GenHeavyIon()

GenHeavyIon | ( |  | ) |
| inline

Empty default constructor.

Definition at line 31 of file GenHeavyIon.h.

References centrality, eccentricity, event_plane_angle, forceoldformat, impact_parameter, N_Nwounded_collisions, Ncoll, Ncoll_hard, Npart_proj, Npart_targ, Nspec_proj_n, Nspec_proj_p, Nspec_targ_n, Nspec_targ_p, Nwounded_N_collisions, Nwounded_Nwounded_collisions, sigma_inel_NN, spectator_neutrons, spectator_protons, and user_cent_estimate.

## Member Function Documentation

## ◆ event()

const GenEvent * event | ( |  | ) | const
| inlineinherited

return the GenEvent to which this Attribute belongs, if at all.

Definition at line 108 of file Attribute.h.

References GenEvent, and m_event.

## ◆ from_string()

bool from_string | ( | const std::string & | att | ) |
| overridevirtual

Implementation of Attribute::from_string.

If HEPMC3_NO_DEPRECATED is not defined, those are member variables.

Implements Attribute.

Definition at line 20 of file GenHeavyIon.cc.

References centrality, eccentricities, eccentricity, event_plane_angle, impact_parameter, N_Nwounded_collisions, Ncoll, Ncoll_hard, Npart_proj, Npart_targ, Nspec_proj_n, Nspec_proj_p, Nspec_targ_n, Nspec_targ_p, Nwounded_N_collisions, Nwounded_Nwounded_collisions, participant_plane_angles, sigma_inel_NN, spectator_neutrons, spectator_protons, user_cent_estimate, and HepMC3::version().

## ◆ init() [1/2]

virtual bool init | ( |  | ) |
| inlinevirtualinherited

Optionally initialize the attribute after from_string.

Reimplemented in HEPEUPAttribute.

Definition at line 81 of file Attribute.h.

## ◆ init() [2/2]

virtual bool init | ( | const GenRunInfo & |  | ) |
| inlinevirtualinherited

Optionally initialize the attribute after from_string.

Is passed a reference to the GenRunInfo object to which the Attribute belongs.

Reimplemented in HEPEUPAttribute.

Definition at line 90 of file Attribute.h.

## ◆ is_parsed()

bool is_parsed | ( |  | ) | const
| inlineinherited

Check if this attribute is parsed.

Definition at line 102 of file Attribute.h.

References m_is_parsed.

## ◆ is_valid()

bool is_valid | ( |  | ) | const

Verify that the instance contains non-zero information.

HEPMC3_DEPRECATED("Each filed now have default values meaning that they have not been set")

Definition at line 137 of file GenHeavyIon.cc.

References centrality, eccentricity, event_plane_angle, impact_parameter, N_Nwounded_collisions, Ncoll, Ncoll_hard, Npart_proj, Npart_targ, Nwounded_N_collisions, Nwounded_Nwounded_collisions, sigma_inel_NN, spectator_neutrons, and spectator_protons.

## ◆ operator!=()

bool operator!= | ( | const GenHeavyIon & | a | ) | const

Operator !=.

Definition at line 113 of file GenHeavyIon.cc.

References GenHeavyIon().

## ◆ operator==()

bool operator== | ( | const GenHeavyIon & | a | ) | const

Operator ==.

Definition at line 109 of file GenHeavyIon.cc.

References GenHeavyIon().

## ◆ particle() [1/2]

GenParticlePtr particle | ( |  | ) |
| inlineinherited

return the GenParticle to which this Attribute belongs, if at all.

Definition at line 113 of file Attribute.h.

References m_particle.

## ◆ particle() [2/2]

ConstGenParticlePtr particle | ( |  | ) | const
| inlineinherited

return the GenParticle to which this Attribute belongs, if at all.

Definition at line 118 of file Attribute.h.

References m_particle.

## ◆ set()

void set | ( | const int & | nh,
|  | const int & | np,
|  | const int & | nt,
|  | const int & | nc,
|  | const int & | ns,
|  | const int & | nsp,
|  | const int & | nnw = 0,
|  | const int & | nwn = 0,
|  | const int & | nwnw = 0,
|  | const double & | im = 0.,
|  | const double & | pl = 0.,
|  | const double & | ec = 0.,
|  | const double & | s = 0.,
|  | const double & | cent = 0.,
|  | const double & | usrcent = 0. )

Set all fields.

HEPMC3_DEPRECATED("Set individual fields directly instead.")

Set all fields

Definition at line 117 of file GenHeavyIon.cc.

References centrality, eccentricity, event_plane_angle, impact_parameter, N_Nwounded_collisions, Ncoll, Ncoll_hard, Npart_proj, Npart_targ, Nwounded_N_collisions, Nwounded_Nwounded_collisions, sigma_inel_NN, spectator_neutrons, spectator_protons, and user_cent_estimate.

## ◆ set_is_parsed()

void set_is_parsed | ( | bool | flag | ) |
| inlineprotectedinherited

Set is_parsed flag.

Definition at line 134 of file Attribute.h.

References m_is_parsed.

## ◆ set_unparsed_string()

void set_unparsed_string | ( | const std::string & | st | ) |
| inlineprotectedinherited

Set unparsed string.

Definition at line 137 of file Attribute.h.

References m_string.

## ◆ to_string()

bool to_string | ( | std::string & | att | ) | const
| overridevirtual

Implementation of Attribute::to_string.

Implements Attribute.

Definition at line 68 of file GenHeavyIon.cc.

References centrality, eccentricities, eccentricity, event_plane_angle, forceoldformat, impact_parameter, N_Nwounded_collisions, Ncoll, Ncoll_hard, Npart_proj, Npart_targ, Nspec_proj_n, Nspec_proj_p, Nspec_targ_n, Nspec_targ_p, Nwounded_N_collisions, Nwounded_Nwounded_collisions, participant_plane_angles, sigma_inel_NN, spectator_neutrons, spectator_protons, and user_cent_estimate.

## ◆ unparsed_string()

const std::string & unparsed_string | ( |  | ) | const
| inlineinherited

Get unparsed string.

Definition at line 105 of file Attribute.h.

References m_string.

## ◆ vertex() [1/2]

GenVertexPtr vertex | ( |  | ) |
| inlineinherited

return the GenVertex to which this Attribute belongs, if at all.

Definition at line 123 of file Attribute.h.

References m_vertex.

## ◆ vertex() [2/2]

ConstGenVertexPtr vertex | ( |  | ) | const
| inlineinherited

return the GenVertex to which this Attribute belongs, if at all.

Definition at line 128 of file Attribute.h.

References m_vertex.

## Field Documentation

## ◆ centrality

double centrality

The centrality.

The generated centrality in percentiles, where 0 is the maximally central and 100 is the minimally central. A negative value means that the information is not available.

Definition at line 148 of file GenHeavyIon.h.

## ◆ eccentricities

std::map<int,double> eccentricities

Eccentricities.

Calculated to different orders. The key of the map specifies the order, and the value gives the corresponding eccentricity.

Definition at line 199 of file GenHeavyIon.h.

## ◆ eccentricity

double eccentricity

The eccentricity.

HEPMC3_DEPRECATED("Use eccentricities insted.")

Definition at line 133 of file GenHeavyIon.h.

## ◆ event_plane_angle

double event_plane_angle

The event plane angle.

The angle wrt. the x-axix of the impact parameter vector (pointing frm the target to the projectile). A positive number between 0 and two pi. A negative value means that the information is not available.

Definition at line 127 of file GenHeavyIon.h.

## ◆ forceoldformat

bool forceoldformat

force writing in old format for compatibility purposes.

HEPMC3_DEPRECATED("This should really not be needed");

Definition at line 237 of file GenHeavyIon.h.

## ◆ impact_parameter

double impact_parameter

The impact parameter.

The impact parameter given in units of femtometer. A negative value means that the information is not available.

Definition at line 119 of file GenHeavyIon.h.

## ◆ m_event

const GenEvent* m_event
| privateinherited

Possibility to be aware of the

Definition at line 145 of file Attribute.h.

## ◆ m_is_parsed

bool m_is_parsed
| privateinherited

Is this attribute parsed?

Definition at line 143 of file Attribute.h.

## ◆ m_particle

GenParticlePtr m_particle
| privateinherited

controlling GenEvent object.

Particle to which assigned.

Definition at line 147 of file Attribute.h.

## ◆ m_string

std::string m_string
| privateinherited

Raw (unparsed) string.

Definition at line 144 of file Attribute.h.

## ◆ m_vertex

GenVertexPtr m_vertex
| privateinherited

Vertex to which assigned.

Definition at line 148 of file Attribute.h.

## ◆ N_Nwounded_collisions

int N_Nwounded_collisions

Collisions with a diffractively excited target nucleon.

The number of single diffractive nucleon-nucleon collisions where the target nucleon is excited. A negative value means that the information is not available.

Definition at line 99 of file GenHeavyIon.h.

## ◆ Ncoll

int Ncoll

the number of inelastic nucleon-nucleon collisions.

Note that a one participating nucleon can be involved in many inelastic collisions, and that inelastic also includes diffractive excitation. A negative value means that the information is not available.

Definition at line 80 of file GenHeavyIon.h.

## ◆ Ncoll_hard

int Ncoll_hard

the number of hard nucleon-nucleon collisions.

Model-dependent. Usually the number of nucleon-nucleon collisions containing a special signal process. A negative value means that the information is not available.

Definition at line 57 of file GenHeavyIon.h.

## ◆ Npart_proj

int Npart_proj

the number of participating nucleons in the projectile.

The number of nucleons in the projectile participating in an inelastic collision (see Ncoll). A negative value means that the information is not available.

Definition at line 64 of file GenHeavyIon.h.

## ◆ Npart_targ

int Npart_targ

the number of participating nucleons in the target.

The number of nucleons in the target participating in an inelastic collision (see Ncoll). A negative value means that the information is not available.

Definition at line 71 of file GenHeavyIon.h.

## ◆ Nspec_proj_n

int Nspec_proj_n

The number of spectator neutrons in the projectile.

ie. those that thave not participated in any inelastic nucleon-nucleon collision. A negative value indicatess that the information is not available.

Definition at line 165 of file GenHeavyIon.h.

## ◆ Nspec_proj_p

int Nspec_proj_p

The number of spectator protons in the projectile.

ie. those that thave not participated in any inelastic nucleon-nucleon collision. A negative value indicatess that the information is not available.

Definition at line 179 of file GenHeavyIon.h.

## ◆ Nspec_targ_n

int Nspec_targ_n

The number of spectator neutrons in the target.

ie. those that thave not participated in any inelastic nucleon-nucleon collision. A negative value indicatess that the information is not available.

Definition at line 172 of file GenHeavyIon.h.

## ◆ Nspec_targ_p

int Nspec_targ_p

The number of spectator protons in the target.

ie. those that thave not participated in any inelastic nucleon-nucleon collision. A negative value indicatess that the information is not available.

Definition at line 186 of file GenHeavyIon.h.

## ◆ Nwounded_N_collisions

int Nwounded_N_collisions

Collisions with a diffractively excited projectile nucleon.

The number of single diffractive nucleon-nucleon collisions where the projectile nucleon is excited. A negative value means that the information is not available.

Definition at line 106 of file GenHeavyIon.h.

## ◆ Nwounded_Nwounded_collisions

int Nwounded_Nwounded_collisions

Non-diffractive or doubly diffractive collisions.

The number of nucleon-nucleon collisions where both projectile and target nucleons are wounded. A negative value means that the information is not available.

Definition at line 113 of file GenHeavyIon.h.

## ◆ participant_plane_angles

std::map<int,double> participant_plane_angles

Participant plane angles.

calculated to different orders. The key of the map specifies the order, and the value gives to the angle wrt. the event plane.

Definition at line 193 of file GenHeavyIon.h.

## ◆ sigma_inel_NN

double sigma_inel_NN

The assumed inelastic nucleon-nucleon cross section.

in units of millibarn. As used in a Glauber calculation to simulate the distribution in Ncoll. A negative value means that the information is not available.

Definition at line 141 of file GenHeavyIon.h.

## ◆ spectator_neutrons

int spectator_neutrons

Total number of spectator neutrons.

HEPMC3_DEPRECATED("Use Nspec_proj_n and Nspec_targ_n instead.")

Definition at line 86 of file GenHeavyIon.h.

## ◆ spectator_protons

int spectator_protons

Total number of spectator protons.

HEPMC3_DEPRECATED("Use Nspec_proj_p and Nspec_targ_p instead.")

Definition at line 91 of file GenHeavyIon.h.

## ◆ user_cent_estimate

double user_cent_estimate

A user defined centrality estimator.

This variable may contain anything a generator feels is reasonable for estimating centrality. The value should be non-negative, and a low value corresponds to a low centrality. A negative value indicatess that the information is not available.

Definition at line 157 of file GenHeavyIon.h.

The documentation for this class was generated from the following files:

- GenHeavyIon.h
- GenHeavyIon.cc