Skip to content

Sim: add light ions and hypernuclei - #16191

Open
f3sch wants to merge 2 commits into
AliceO2Group:devfrom
f3sch:sim-light-ions-upstream
Open

f3sch wants to merge 2 commits into
AliceO2Group:devfrom
f3sch:sim-light-ions-upstream

Conversation

@f3sch

@f3sch f3sch commented Nov 25, 2026

Copy link
Copy Markdown
Collaborator

Simulation: transport 6Li/7Li and give hypernuclei their physics in Geant4

6Li and 7Li were not transported. Geant4 VMC accepts a primary only if Geant4 has defined the particle. Geant4 defines d, t, 3He and alpha from the start, but a heavier ion only once it is created. FairMCApplication::AddIons skips ions that TDatabasePDG already knows, and O2's ion table lists both. So a generated 6Li/7Li was skipped and the worker aborted ("Inconsistency in primary particles"). O2MCApplicationBase::AddIons now defines them with DefineIon, for Geant4 only: Geant3's DefineIon would give them a new isomer code.

Hypernuclei left no signal. Geant4 11.2 defines the light hypernuclei itself (3LH, 4LH, 4LHe, 5LHe and their antiparticles), so O2's DefineParticle calls for them are ignored. Without G4HadronicParameters::SetEnableHyperNuclei(true) they get only the decay: no ionisation, no multiple scattering, no hadronic interactions. Their hits had zero energy loss and produced no digits. g4Config.C now enables this before the physics is built.

Anti-hypernucleus charges: O2DatabasePDG gave anti-3LH, anti-4LH, anti-4LHe and anti-5LHe a positive charge; they are now negative.

Felix Schlepper and others added 2 commits November 25, 2026 08:32
Geant4 VMC looks a primary up in Geant4's particle table, which holds
d, t, 3He and alpha from the start but a heavier ion only once it is
created. A generated 6Li or 7Li was skipped as unknown, and the stack
then stopped the worker ("Inconsistency in primary particles").
FairMCApplication::AddIons does not define an ion that TDatabasePDG
already knows, and O2's ion table has both. O2MCApplicationBase now
defines them through DefineIon (Geant4 only: Geant3's DefineIon would
give them new isomer codes).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…us charges

Geant4 defines the light hypernuclei itself (hypertriton, hyperH4,
hyperalpha, hyperHe5 and their antiparticles), so O2's DefineParticle
for them is ignored, and it gives them only the decay unless
G4HadronicParameters::SetEnableHyperNuclei is set: no ionisation, no
multiple scattering, no hadronic interactions. Their TRK hits had zero
energy loss and made no digits. g4Config.C now enables them before the
physics is built.

O2DatabasePDG gave the four anti-hypernuclei (3LH, 4LH, 4LHe, 5LHe) a
positive charge; now negative.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@f3sch
f3sch requested review from a team, sawenzel and shahor02 as code owners November 25, 2026 08:13
@f3sch

f3sch commented Nov 27, 2026

Copy link
Copy Markdown
Collaborator Author

@sawenzel Can you take a look if this is fine?

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

Development

Successfully merging this pull request may close these issues.

1 participant