60 (mass_proton/CLHEP::c_squared);
68 G4cout <<
" magneticMoment: " << magneticMoment/muN <<
G4endl;
72 G4double g_factor = 2 * magneticMoment/muN;
78 G4double anomaly = (g_factor - 2.)/2.;
81 anomaly = (g_factor * (mass_neutron/mass_proton) - 2.)/2.;
84 muN = 0.5*
CLHEP::eplus*CLHEP::hbar_Planck/(mass_neutron/CLHEP::c_squared);
85 g_factor = 2 * magneticMoment/muN;
87 anomaly = (g_factor - 2.)/2.;
96 (mass_muon/CLHEP::c_squared);
99 G4cout <<
" magneticMoment: " << magneticMoment/muB <<
G4endl;
103 g_factor = magneticMoment/muB;
109 anomaly = (g_factor - 2.)/2.;
141 if (phi >
pi/2 && phi <
pi) phi =
pi-phi;
143 G4double z = std::sin(phi)*std::cos(theta);
144 G4double x = std::sin(phi)*std::sin(theta);
G4ParticleDefinition * FindParticle(G4int PDGEncoding)
CLHEP::Hep3Vector G4ThreeVector
F06PrimaryGeneratorAction(void)
void SetParticleMomentumDirection(G4ParticleMomentum aMomentumDirection)
Definition of the F06PrimaryGeneratorAction class.
virtual void GeneratePrimaryVertex(G4Event *evt)
Definition of the F06DetectorConstruction class.
G4ParticleGun * fParticleGun
void SetParticlePolarization(G4ThreeVector aVal)
void SetParticlePosition(G4ThreeVector aPosition)
G4GLOB_DLL std::ostream G4cout
virtual ~F06PrimaryGeneratorAction()
void SetParticleEnergy(G4double aKineticEnergy)
G4double GetPDGMass() const
static G4ParticleTable * GetParticleTable()
const G4double x[NPOINTSGL]
G4double GetPDGMagneticMoment() const
static const double eplus
G4double GetPDGCharge() const
void SetParticleDefinition(G4ParticleDefinition *aParticleDefinition)
virtual void GeneratePrimaries(G4Event *)