Implement Beagle baryon particle code
What to do? Make Beagle beam particles and remnant particles correctly encoded in HepMC
Beagle produces actually 3 codes to mark nucleus 2nd (index=1) column IDHKK(I): Code 80000 refers to a nucleus, specified in more detail by A=IDRES(I), Z=IDXRES(I) 15 (index=14) column IDRES(I): Baryon number, or A for a nucleus (IDHKK(I)=80000), fractional B set to 0. 16 (index=15) column IDXRES(I): I - Particle charge, (Z for a nucleus), 0 for fractional charge
Beam particles are given in header with:
Atarg: | I | A of the target nucleus | | Ztarg: | I | Z of the target nucleus |
Full beagle docs: https://eic.github.io/software/beagle.html
In HepMC Particle Data Group (PDG) numbering is using just one code like this:
Nuclear codes are given as 10-digit numbers ±10LZZZAAAI. For a (hyper)nucleus consisting of np protons, nn neutrons and nΛ Λ’s, A = np + nn + nΛ gives the total baryon number, Z = np the total charge and L = nΛ the total number of strange quarks. I gives the isomer level, with I = 0 corresponding to the ground state and I > 0 to excitations, see [4], where states denoted m,n,p,q translate to I = 1 −4. As examples, the deuteron is 1000010020 and235U is 1000922350. To avoid ambiguities, nuclear codes should not be applied to a single hadron, like p, n or Λ0, where quark-contents-based codes already exist.
https://pdg.lbl.gov/2019/reviews/rpp2019-rev-monte-carlo-numbering.pdf