00001 // -*- C++ -*- 00002 // 00003 // Constants.h is a part of ThePEG - Toolkit for HEP Event Generation 00004 // Copyright (C) 1999-2007 Leif Lonnblad 00005 // 00006 // ThePEG is licenced under version 2 of the GPL, see COPYING for details. 00007 // Please respect the MCnet academic guidelines, see GUIDELINES for details. 00008 // 00009 #ifndef ThePEG_Constants_H 00010 #define ThePEG_Constants_H 00011 00012 // This file defines a number of useful constants, placed in the 00013 // namespace <!id>ThePEG::Constants<!!id>. 00014 00015 #include "Unitsystem.h" 00016 #include <cmath> 00017 #include <cfloat> 00018 00019 namespace ThePEG { 00020 00025 namespace Constants { 00026 00027 using namespace ThePEG::Units; 00028 00030 const Length MaxLength = 1.0e20 * meter; 00031 00033 const Energy MaxEnergy = 1.0e6 * GeV; 00034 00036 const Energy2 MaxEnergy2 = MaxEnergy * MaxEnergy; 00037 00039 const double MaxDouble = DBL_MAX; 00040 00042 const double HugeDouble = DBL_MAX * 1.0e-4; 00043 00045 const double MaxFloat = FLT_MAX; 00046 00048 const double HugeFloat = FLT_MAX * 0.01; 00049 00051 const double MaxRapidity = 100.0; 00052 00054 const double pi = M_PI; 00055 00057 const double twopi = 2.0 * pi; 00058 00060 const long MaxInt = 1000000000L; 00061 00063 const double epsilon = DBL_EPSILON; 00064 00066 const double EulerGamma = 0.5772156649015329; 00067 } 00068 00069 } 00070 00071 #endif /* ThePEG_Constants_H */