34 #define INCLXX_IN_GEANT4_MODE 1
38 #ifndef G4INCLGlobals_hh
39 #define G4INCLGlobals_hh 1
49 namespace PhysicalConstants {
80 return radians * (180.0 /
pi);
101 return std::log(x + std::sqrt(x*x+1.));
108 return t > 0 ? 1: t < 0 ? -1 : 0;
112 template <
typename T>
inline T
max(
const T
t1,
const T
t2) {
113 return t1 > t2 ? t1 :
t2;
117 template <
typename T>
inline T
min(
const T
t1,
const T
t2) {
118 return t1 < t2 ? t1 :
t2;
158 namespace ParticleConfig {
162 #ifndef INCLXX_IN_GEANT4_MODE
164 void wrap(std::string &str,
const size_t lineLength=78,
const std::string &separators=
" \t");
165 void replaceAll(std::string &str,
const std::string &from,
const std::string &to,
const size_t maxPosition=std::string::npos);
166 std::vector<std::string> tokenize(std::string
const &str,
const std::string &delimiters);
167 G4bool isInteger(std::string
const &str);
168 std::string expandPath(std::string
const &path);
T max(const T t1, const T t2)
brief Return the largest of the two arguments
const G4double hcSquared
[MeV^2*fm^2]
const G4double Pf
Fermi momentum [MeV/c].
const G4double oneOverSqrtTwo
G4double pow13(G4double x)
G4double arcCos(const G4double x)
Calculates arccos with some tolerance on illegal arguments.
const G4double sqrtThreeFifths
G4double inverseGaussianCDF(const G4double x)
Inverse cumulative distribution function for Gaussian.
G4double toDegrees(G4double radians)
G4double powMinus13(G4double x)
G4double pow23(G4double x)
G4bool isPair(Particle const *const p1, Particle const *const p2, ParticleType t1, ParticleType t2)
const G4double eSquared
Coulomb conversion factor [MeV*fm].
G4double gaussianCDF(const G4double x)
Cumulative distribution function for Gaussian.
const G4double oneOverSqrtThree
const G4double sqrtFiveThirds
G4double arcSin(const G4double x)
Calculates arcsin with some tolerance on illegal arguments.
T min(const T t1, const T t2)
brief Return the smallest of the two arguments
G4double aSinH(G4double x)
const G4double hc
[MeV*fm]