59 for (
G4int i=0; i<4; i++) {
61 for (
G4int k=0; k<4; k++) {
63 V += C * theG4Pow->
powN(ekin, k);
67 PR += V * theG4Pow->
powN(S, i);
70 return std::sqrt(S) * (PR + (1-PQ)*(S*S*S*S));
76 return 0.76 + 2.2 /
G4cbrt(A);
83 snn = -1174.8 / (e * e) + 3088.5 / e + 5.3107;
85 snn = 93074.0 / (e * e) - 11.148 / e + 22.429;
95 spn = -5057.4 / (e * e) + 9069.2 / e + 6.9466;
97 spn = 239380.0 / (e * e) + 1802.0 / e + 27.147;
109 return C *
G4cbrt(arg*arg);
113 return x==0 ? 0. : (x<0?-1.:1.)*
G4Exp(
G4Log(std::fabs(x))/3.);
123 r1 = r1 > eps ? r1 : eps;
125 r2 = r2 > eps ? r2 : eps;
126 r2 = r2 < 1.0 - eps ? r2 : 1.0 - eps;
128 return sigma * std::sin(
twopi * r1) * std::sqrt(-2.0 *
G4Log(r2));
138 return std::pair<G4double, G4double>(CT, std::sqrt(1.0 - CT*CT));
145 G4double pt = p * std::sqrt(std::fabs(1.0 - ct * ct));
156 pvec.
set(pt*std::cos(phi), pt*std::sin(phi), p*ct);
177 pvec.
set(pt*std::cos(phi), pt*std::sin(phi), p*COS_SIN.first);
void set(double x, double y, double z)
G4double randomGauss(G4double sigma)
static G4Pow * GetInstance()
G4double powN(G4double x, G4int n) const
CLHEP::Hep3Vector G4ThreeVector
G4double csNN(G4double e)
void setVectM(const Hep3Vector &spatial, double mass)
G4double randomInuclPowers(G4double ekin, const G4double(&coeff)[4][4])
G4double csPN(G4double e)
G4LorentzVector generateWithRandomAngles(G4double p, G4double mass=0.)
G4double G4cbrt(G4double x)
G4double G4Log(G4double x)
G4double G4Exp(G4double initial_x)
Exponential Function double precision.
G4LorentzVector generateWithFixedTheta(G4double ct, G4double p, G4double mass=0.)
std::pair< G4double, G4double > randomCOS_SIN()
G4double FermiEnergy(G4int A, G4int Z, G4int ntype)
CLHEP::HepLorentzVector G4LorentzVector