BornAgain  1.19.0
Simulate and fit neutron and x-ray scattering at grazing incidence
PhysicalConstants.h
Go to the documentation of this file.
1 // ************************************************************************************************
2 //
3 // BornAgain: simulate and fit reflection and scattering
4 //
5 //! @file Base/Const/PhysicalConstants.h
6 //! @brief Defines the values of physical constants (SI)
7 //!
8 //! @homepage http://www.bornagainproject.org
9 //! @license GNU General Public License v3 or higher (see COPYING)
10 //! @copyright Forschungszentrum Jülich GmbH 2018
11 //! @authors Scientific Computing Group at MLZ (see CITATION, AUTHORS)
12 //
13 // ************************************************************************************************
14 
15 #ifdef SWIG
16 #error no need to expose this header to Swig
17 #endif
18 
19 #ifndef USER_API
20 #ifndef BORNAGAIN_BASE_CONST_PHYSICALCONSTANTS_H
21 #define BORNAGAIN_BASE_CONST_PHYSICALCONSTANTS_H
22 
23 //! Physical constants.
24 
25 namespace PhysConsts {
26 
27 constexpr double m_n = 1.67492749804e-27; //!< Neutron mass, kg
28 constexpr double h_bar = 1.054571817e-34; //!< Reduced Plank constant, J s
29 constexpr double mu_N = 5.0507837461e-27; //!< Nuclear magneton (\f$ \mu_N \f$), J/T
30 constexpr double mu_B = 9.2740100783e-24; //!< Bohr magneton (\f$ \mu_B \f$), J/T
31 constexpr double r_e = 2.8179403262e-15; //!< Thomson scattering length (\f$ r_e \f$), m
32 constexpr double gamma_n = 1.91304272; //!< \f$\gamma\f$ factor for neutron magnetic moment,
33  //!< \f$\mu_n = \gamma \cdot \mu_N\f$
34 constexpr double g_factor_n = -3.82608545; //!< neutron g-factor
35 
36 } // namespace PhysConsts
37 
38 #endif // BORNAGAIN_BASE_CONST_PHYSICALCONSTANTS_H
39 #endif // USER_API
Physical constants.
constexpr double mu_B
Bohr magneton ( ), J/T.
constexpr double g_factor_n
neutron g-factor
constexpr double h_bar
Reduced Plank constant, J s.
constexpr double r_e
Thomson scattering length ( ), m.
constexpr double m_n
Neutron mass, kg.
constexpr double mu_N
Nuclear magneton ( ), J/T.
constexpr double gamma_n
factor for neutron magnetic moment,