44 fParticleGun(nullptr), fMessenger(nullptr),
45 fPositron(nullptr), fMuon(nullptr), fPion(nullptr),
46 fKaon(nullptr), fProton(nullptr),
48 fSigmaMomentum(50.*
MeV),
50 fRandomizePrimary(
true)
52 G4int nofParticles = 1;
56 fPositron = particleTable->FindParticle(
"e+");
57 fMuon = particleTable->FindParticle(
"mu+");
58 fPion = particleTable->FindParticle(
"pi+");
59 fKaon = particleTable->FindParticle(
"kaon+");
60 fProton = particleTable->FindParticle(
"proton");
128 "Primary generator control");
133 "Mean momentum of primaries.");
142 auto& sigmaMomentumCmd
146 sigmaMomentumCmd.
SetRange(
"sp>=0.");
152 "Sigma angle divergence of primaries.");
161 =
"Boolean flag for randomizing primary particle types.\n";
163 +=
"In case this flag is false, you can select the primary particle\n";
164 guidance +=
" with /gun/particle command.";
165 randomCmd.SetGuidance(guidance);
166 randomCmd.SetParameterName(
"flg",
true);
167 randomCmd.SetDefaultValue(
"true");