Hi, I hope this is the correct category for this problem. Assume that your program uses the G4GeneralParticleSource for generating primaries and the following commands are given: Idle> /gps/ene/type Mono Idle> /gps/ene/mono 6 MeV Idle> /gps/ene/min 1 keV Idle> /gps/ene/max 10 keV Idle> /run/beamOn 1 Then the program falls into an infite loop, since the energy for the monoenergetic particles is outside the min and max limits (the problem is a "while" loop in file G4SPSEneDistribution.cc, line 1221, function G4double G4SPSEneDistribution::GenerateOne(G4ParticleDefinition* a)). This behavior is counterintuitive, since the min and max are for linear spectrum and may be set in a previous run. Then switching in monoenergetic beam will make the simulation to hang. Best Regards, Thomas V.
Thank you for reporting this issue. The fix will be included in the next public release. Kind regards, Makoto