9
3

electromagnetic_constants.hpp 2.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475
  1. // Boost.Units - A C++ library for zero-overhead dimensional analysis and
  2. // unit/quantity manipulation and conversion
  3. //
  4. // Copyright (C) 2003-2008 Matthias Christian Schabel
  5. // Copyright (C) 2008 Steven Watanabe
  6. //
  7. // Distributed under the Boost Software License, Version 1.0. (See
  8. // accompanying file LICENSE_1_0.txt or copy at
  9. // http://www.boost.org/LICENSE_1_0.txt)
  10. #ifndef BOOST_UNITS_CODATA_ELECTROMAGNETIC_CONSTANTS_HPP
  11. #define BOOST_UNITS_CODATA_ELECTROMAGNETIC_CONSTANTS_HPP
  12. ///
  13. /// \file
  14. /// \brief CODATA recommended values of fundamental electromagnetic constants.
  15. /// \details CODATA recommended values of the fundamental physical constants: NIST SP 961
  16. /// CODATA 2006 values as of 2007/03/30
  17. ///
  18. #include <boost/units/quantity.hpp>
  19. #include <boost/units/static_constant.hpp>
  20. #include <boost/units/systems/detail/constants.hpp>
  21. #include <boost/units/systems/si/conductance.hpp>
  22. #include <boost/units/systems/si/current.hpp>
  23. #include <boost/units/systems/si/electric_charge.hpp>
  24. #include <boost/units/systems/si/electric_potential.hpp>
  25. #include <boost/units/systems/si/energy.hpp>
  26. #include <boost/units/systems/si/frequency.hpp>
  27. #include <boost/units/systems/si/magnetic_flux.hpp>
  28. #include <boost/units/systems/si/magnetic_flux_density.hpp>
  29. #include <boost/units/systems/si/resistance.hpp>
  30. #include <boost/units/systems/si/codata/typedefs.hpp>
  31. namespace boost {
  32. namespace units {
  33. namespace si {
  34. namespace constants {
  35. namespace codata {
  36. // ELECTROMAGNETIC
  37. /// elementary charge
  38. BOOST_UNITS_PHYSICAL_CONSTANT(e,quantity<electric_charge>,1.602176487e-19*coulombs,4.0e-27*coulombs);
  39. /// elementary charge to Planck constant ratio
  40. BOOST_UNITS_PHYSICAL_CONSTANT(e_over_h,quantity<current_over_energy>,2.417989454e14*amperes/joule,6.0e6*amperes/joule);
  41. /// magnetic flux quantum
  42. BOOST_UNITS_PHYSICAL_CONSTANT(Phi_0,quantity<magnetic_flux>,2.067833667e-15*webers,5.2e-23*webers);
  43. /// conductance quantum
  44. BOOST_UNITS_PHYSICAL_CONSTANT(G_0,quantity<conductance>,7.7480917004e-5*siemens,5.3e-14*siemens);
  45. /// Josephson constant
  46. BOOST_UNITS_PHYSICAL_CONSTANT(K_J,quantity<frequency_over_electric_potential>,483597.891e9*hertz/volt,1.2e7*hertz/volt);
  47. /// von Klitzing constant
  48. BOOST_UNITS_PHYSICAL_CONSTANT(R_K,quantity<resistance>,25812.807557*ohms,1.77e-5*ohms);
  49. /// Bohr magneton
  50. BOOST_UNITS_PHYSICAL_CONSTANT(mu_B,quantity<energy_over_magnetic_flux_density>,927.400915e-26*joules/tesla,2.3e-31*joules/tesla);
  51. /// nuclear magneton
  52. BOOST_UNITS_PHYSICAL_CONSTANT(mu_N,quantity<energy_over_magnetic_flux_density>,5.05078324e-27*joules/tesla,1.3e-34*joules/tesla);
  53. } // namespace codata
  54. } // namespace constants
  55. } // namespace si
  56. } // namespace units
  57. } // namespace boost
  58. #endif // BOOST_UNITS_CODATA_ELECTROMAGNETIC_CONSTANTS_HPP