33 #define INCLXX_IN_GEANT4_MODE 1
37 #ifndef G4INCLGlobals_hh
38 #define G4INCLGlobals_hh 1
47 namespace PhysicalConstants {
84 return radians * (180.0 /
pi);
105 return std::log(x + std::sqrt(x*x+1.));
112 return t > 0 ? 1: t < 0 ? -1 : 0;
116 template <
typename T>
inline T
max(
const T
t1,
const T t2) {
117 return t1 > t2 ? t1 : t2;
121 template <
typename T>
inline T
min(
const T
t1,
const T t2) {
122 return t1 < t2 ? t1 : t2;
147 namespace ParticleConfig {
152 void wrap(std::string &str,
const size_t lineLength=78,
const std::string &separators=
" \t");
153 void replaceAll(std::string &str,
const std::string &from,
const std::string &to,
const size_t maxPosition=std::string::npos);
const G4double sqrtThreeFifths
const G4double PfCubed
Fermi momentum cubed [(MeV/c)^3].
const G4double eSquared
Coulomb conversion factor [MeV*fm].
const G4double hc
[MeV*fm]
G4double toDegrees(G4double radians)
G4double pow23(G4double x)
G4double aSinH(G4double x)
const G4double hcSquared
[MeV^2*fm^2]
const G4double sqrtFiveThirds
const G4double oneOverSqrtThree
const G4double PfSquared
Fermi momentum squared [(MeV/c)^2].
T max(const T t1, const T t2)
brief Return the largest of the two arguments
void replaceAll(std::string &str, const std::string &from, const std::string &to, const size_t maxPosition=std::string::npos)
const G4double Pf
Fermi momentum [MeV/c].
T min(const T t1, const T t2)
brief Return the smallest of the two arguments
G4bool isPair(Particle const *const p1, Particle const *const p2, ParticleType t1, ParticleType t2)
G4double pow13(G4double x)
G4double powMinus13(G4double x)
G4double gaussianCDF(const G4double x)
Cumulative distribution function for Gaussian.
const G4double oneOverSqrtTwo
void wrap(std::string &str, const size_t lineLength=78, const std::string &separators=" \t")