Skip to content

Added gemc short codes for tritium, he3 and alpha in the pdg database - #1586

Open
N-Plx wants to merge 2 commits into
developmentfrom
1584-cj-and-gemc-codes-for-tritium-alpha-he3-mismatch
Open

N-Plx wants to merge 2 commits into
developmentfrom
1584-cj-and-gemc-codes-for-tritium-alpha-he3-mismatch

Conversation

@N-Plx

@N-Plx N-Plx commented Nov 11, 2026

Copy link
Copy Markdown
Collaborator

No description provided.

@N-Plx N-Plx linked an issue Nov 11, 2026 that may be closed by this pull request
@N-Plx

N-Plx commented Nov 11, 2026

Copy link
Copy Markdown
Collaborator Author

Using tritium, he3 or he4 from gemc to CJ was crashing the truth matching since it reads the MC Particle bank that converts PDG codes to short gemc codes, and these codes were not in the pdgdatabase

@baltzell

Copy link
Copy Markdown
Collaborator

I think Whitney added those species a few lines down. Maybe they were never used.

@N-Plx

N-Plx commented Nov 12, 2026 •

Copy link
Copy Markdown
Collaborator Author

@baltzell They were added with the real PDG code, but gemc is writing short codes in the MC::Particle bank that is then used for truth matching, so it crashes when using the truth matching specifically

@c-dilks

c-dilks commented Nov 12, 2026

Copy link
Copy Markdown
Member

#1579 may also be relevant here... @N-Plx are those changes okay?

@N-Plx

N-Plx commented Nov 12, 2026

Copy link
Copy Markdown
Collaborator Author

#1579 may also be relevant here... @N-Plx are those changes okay?

I believe everything that is added there with the PDG/geant4 ID and not the gemc/geant3 ID will crash with the truth matching. The TruthMatch class is reading out the ID from MC::Particle. gemc writes the short (geant3) ID in there. If there is no entry with the corresponding ID in the PDGdatabase, it crashes. This should be the case for all particleMap that are created using the geant4 PID as the first field at least. Maybe another solution is that the comparison is done with the particleIdGeant from the PDGParticle class, and not fields in the hashmap?

@N-Plx
N-Plx marked this pull request as ready for review November 17, 2026 19:09
@N-Plx
N-Plx enabled auto-merge (squash) November 17, 2026 19:09
@baltzell

Copy link
Copy Markdown
Collaborator

Is ALERT using Whitney's 4 PDG particles? That naming follows more the existing naming scheme.

@baltzell

Copy link
Copy Markdown
Collaborator

It's worth mentioning here that gemc does support PDG codes in LUND files. But coatjava probably should support the same "short" (geant3) codes as gemc too.

@baltzell

Copy link
Copy Markdown
Collaborator

see if #1599 is a better option

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

CJ and gemc codes for tritium, alpha, He3 mismatch

3 participants