I am trying to simulate electron-like particles with different masses, charges and so on. Using ExampleN03 as a base, I added in new source and header files which are just the electron files with the name changed. Everything works fine when the mass is large (eg 1 GeV) but if I use the normal electron mass then I get the following error on running: phot: Total cross sections from Sandia parametrisation. G4ProcessManager::GetAttribute(): particle[m-] index out of range #processes[2] index [-1] G4ProcessManager::GetAttribute(): particle[m-] index out of range #processes[2] index [-1] Segmentation fault (m- is the name of my new particle). The error occurs only when the mass drops below about 10 MeV. If the mass is larger than this then the charge can be changed without any problems. The PhysicsList file I am using is exactly the same as the N03 example, but with my new header included and the line G4MyParticle::MyParticleDefinition(); in ConstructParticle() above the ConstructBosons() etc. I am using Geant4 7.0.p01 on Mandrake Linux 10.1 with g++ 3.4.1. Thank You, Giles Reid
Error message of "index out of range" suggests that G4hIonisation is attached to the new particle m-. But, G4hIonisation can not be attached to particles if its mass is less than 10 MeV. (i.e. G4hIonisation::IsApplicable returns false).