47 G4bool F04PrimaryGeneratorAction::fFirst =
false;
53 : fDetector(detectorConstruction), fRndmFlag(
"off"),
54 fXvertex(0.), fYvertex(0.), fZvertex(0.),
66 FindParticle(particleName=
"proton"));
94 GetNavigatorForTracking();
110 CreateTouchableHistoryHandle();
113 fGlobal2local = touchable->GetHistory()->GetTopTransform();
138 if (fRndmFlag ==
"on")
142 x0 = r0*std::cos(phi0);
143 y0 = r0*std::sin(phi0);
158 fVertexdefined =
true;
160 G4cout <<
" X coordinate of the primary vertex = " << fXvertex/
mm <<
168 fVertexdefined =
true;
170 G4cout <<
" Y coordinate of the primary vertex = " << fYvertex/
mm <<
178 fVertexdefined =
true;
180 G4cout <<
" Z coordinate of the primary vertex = " << fZvertex/
mm <<