StRoot  1
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
PhysicalConstants.h
1 #ifdef _VANILLA_ROOT_
2 
3 #ifndef HEP_PHYSICAL_CONSTANTS_H
4 #ifndef __CINT__
5 #define HEP_PHYSICAL_CONSTANTS_H
6 
8 #include "TMath.h"
9 
11 #include "SystemOfUnits.h"
12 
13 #ifndef ST_NO_NAMESPACES
14 using namespace units;
15 #endif
16 
17 //
18 //
19 //
20 static const double pi = TMath::Pi(); // from <math.h>
21 static const double twopi = 2*pi;
22 static const double halfpi = pi/2;
23 static const double pi2 = pi*pi;
24 
25 //
26 //
27 //
28 static const double Avogadro = 6.0221367e+23/mole;
29 
30 //
31 // c = 299.792458 mm/ns
32 // c^2 = 898.7404 (mm/ns)^2
33 //
34 static const double c_light = 2.99792458e+8 * meter/second;
35 static const double c_squared = c_light * c_light;
36 
37 //
38 // h = 4.13566e-12 MeV*ns
39 // hbar = 6.58212e-13 MeV*ns
40 // hbarc = 197.32705e-12 MeV*mm
41 //
42 static const double h_Planck = 6.6260755e-34 * joule*second;
43 static const double hbar_Planck = h_Planck/twopi;
44 static const double hbarc = hbar_Planck * c_light;
45 static const double hbarc_squared = hbarc * hbarc;
46 
47 //
48 //
49 //
50 static const double electron_charge = - eplus; // see SystemOfUnits.h
51 static const double e_squared = eplus * eplus;
52 
53 //
54 // amu_c2 - atomic equivalent mass unit
55 // amu - atomic mass unit
56 //
57 static const double electron_mass_c2 = 0.51099906 * MeV;
58 static const double proton_mass_c2 = 938.27231 * MeV;
59 static const double neutron_mass_c2 = 939.56563 * MeV;
60 static const double amu_c2 = 931.49432 * MeV;
61 //VP static const double amu = amu_c2/c_squared; //same name in SystemOfUnits.h
62 
63 static const double kaon_0_short_mass_c2 = 497.672 * MeV;
64 static const double pion_plus_mass_c2 = 139.5700 * MeV;
65 static const double pion_minus_mass_c2 = 139.5700 * MeV;
66 static const double lambda_mass_c2 = 1115.684 * MeV;
67 static const double antilambda_mass_c2 = 1115.684 * MeV;
68 static const double xi_minus_mass_c2 = 1321.32 * MeV;
69 
70 
71 //
72 // permeability of free space mu0 = 2.01334e-16 Mev*(ns*eplus)^2/mm
73 // permittivity of free space epsil0 = 5.52636e+10 eplus^2/(MeV*mm)
74 //
75 static const double mu0 = 4*pi*1.e-7 * henry/meter;
76 static const double epsilon0 = 1./(c_squared*mu0);
77 
78 //
79 // electromagnetic coupling = 1.43996e-12 MeV*mm/(eplus^2)
80 //
81 static const double elm_coupling = e_squared/(4*pi*epsilon0);
82 static const double fine_structure_const = elm_coupling/hbarc;
83 static const double classic_electr_radius = elm_coupling/electron_mass_c2;
84 static const double electron_Compton_length = hbarc/electron_mass_c2;
85 static const double Bohr_radius = electron_Compton_length/fine_structure_const;
86 
87 static const double alpha_rcl2 = fine_structure_const
88  *classic_electr_radius
89  *classic_electr_radius;
90 
91 static const double twopi_mc2_rcl2 = twopi*electron_mass_c2
92  *classic_electr_radius
93  *classic_electr_radius;
94 //
95 //
96 //
97 static const double k_Boltzmann = 8.617385e-11 * MeV/kelvin;
98 
99 //
100 //
101 //
102 static const double STP_Temperature = 273.15*kelvin;
103 static const double STP_Pressure = 1.*atmosphere;
104 static const double kGasThreshold = 1.e-2*gram/centimeter3;
105 #endif /* !__CINT__ */
106 inline int dummyPhysicalConstants()
107 {
108 return
109 pi
110 +halfpi
111 +pi2
112 +Avogadro
113 +c_light
114 +c_squared
115 +h_Planck
116 +hbar_Planck
117 +hbarc
118 +hbarc_squared
119 +electron_charge
120 +electron_mass_c2
121 +proton_mass_c2
122 +neutron_mass_c2
123 +amu_c2
124 +kaon_0_short_mass_c2
125 +pion_plus_mass_c2
126 +pion_minus_mass_c2
127 +lambda_mass_c2
128 +antilambda_mass_c2
129 +xi_minus_mass_c2
130 +mu0
131 +epsilon0
132 +elm_coupling
133 +fine_structure_const
134 +classic_electr_radius
135 +electron_Compton_length
136 +Bohr_radius
137 +alpha_rcl2
138 +twopi_mc2_rcl2
139 +k_Boltzmann
140 +STP_Temperature
141 +STP_Pressure
142 +kGasThreshold;
143 }
144 
145 
146 #endif /* HEP_PHYSICAL_CONSTANTS_H */
147 
148 #endif // #ifdef _VANILLA_ROOT_