ARTS 2.5.4 (git: 4c0d3b4d)
|
Constants of physical expressions as constexpr. More...
Go to the source code of this file.
Namespaces | |
namespace | Constant |
Namespace containing several constants, physical and mathematical. | |
namespace | Conversion |
Namespace containing several practical unit conversions, physical and mathematical. | |
namespace | Options |
Functions | |
template<class T > | |
constexpr auto | Constant::pow2 (T x) noexcept -> decltype(x *x) |
power of two More... | |
template<class T > | |
constexpr auto | Constant::pow3 (T x) noexcept -> decltype(pow2(x) *x) |
power of three More... | |
template<class T > | |
constexpr auto | Constant::pow4 (T x) noexcept -> decltype(pow2(pow2(x))) |
power of four More... | |
template<class T > | |
constexpr auto | Conversion::deg2rad (T x) noexcept -> decltype(x *one_degree_in_radians) |
Converts degrees to radians. More... | |
template<class T > | |
constexpr auto | Conversion::rad2deg (T x) noexcept -> decltype(x/one_degree_in_radians) |
Converts radians to degrees. More... | |
template<class T > | |
auto | Conversion::cosd (T x) noexcept -> decltype(std::cos(deg2rad(x))) |
Returns the cosine of the deg2rad of the input. More... | |
template<class T > | |
auto | Conversion::sind (T x) noexcept -> decltype(std::sin(deg2rad(x))) |
Returns the sine of the deg2rad of the input. More... | |
template<class T > | |
auto | Conversion::tand (T x) noexcept -> decltype(std::tan(deg2rad(x))) |
Returns the tangent of the deg2rad of the input. More... | |
template<class T > | |
auto | Conversion::acosd (T x) noexcept -> decltype(rad2deg(std::acos(x))) |
Returns rad2deg of the arc-cosine of the input. More... | |
template<class T > | |
auto | Conversion::asind (T x) noexcept -> decltype(rad2deg(std::asin(x))) |
Returns rad2deg of the arc-sine of the input. More... | |
template<class T > | |
auto | Conversion::atand (T x) noexcept -> decltype(rad2deg(std::atan(x))) |
Returns rad2deg of the arc-tangent of the input. More... | |
template<class T1 , class T2 > | |
auto | Conversion::atan2d (T1 y, T2 x) noexcept -> decltype(rad2deg(std::atan2(y, x))) |
Returns rad2deg of the arc-tangent of inputs #T1/#T2 More... | |
template<class T > | |
constexpr auto | Conversion::kaycm2freq (T x) noexcept -> decltype(x *(100 *c)) |
Conversion from Kayser wavenumber to Hz. More... | |
template<class T > | |
constexpr auto | Conversion::freq2kaycm (T x) noexcept -> decltype(x/(100 *c)) |
Conversion from Hz to Kayser wavenumber. More... | |
template<class T > | |
constexpr auto | Conversion::angcm2freq (T x) noexcept -> decltype(kaycm2freq(inv_two_pi)) |
Conversion from Angular wavenumber to Hz. More... | |
template<class T > | |
constexpr auto | Conversion::freq2angcm (T x) noexcept -> decltype(x/kaycm2freq(inv_two_pi)) |
Conversion from Hz to Angular wavenumber. More... | |
template<class T > | |
constexpr auto | Conversion::angfreq2freq (T x) noexcept -> decltype(x *inv_two_pi) |
Conversion from Angular Hz to Hz. More... | |
template<class T > | |
constexpr auto | Conversion::freq2angfreq (T x) noexcept -> decltype(x *two_pi) |
Conversion from Hz to Angular Hz. More... | |
template<class T > | |
constexpr auto | Conversion::wavelen2freq (T x) noexcept -> decltype(c/x) |
Conversion from wavelength to Hz. More... | |
template<class T > | |
constexpr auto | Conversion::freq2wavelen (T x) noexcept -> decltype(c/x) |
Conversion from Hz to wavelength. More... | |
template<class T > | |
constexpr auto | Conversion::hz2ghz (T x) noexcept -> decltype(x *1e-9) |
Conversion from wavelength to Hz. More... | |
template<class T > | |
constexpr auto | Conversion::ghz2hz (T x) noexcept -> decltype(x *1e9) |
Conversion from Hz to wavelength. More... | |
template<class T > | |
constexpr auto | Conversion::atm2pa (T x) noexcept -> decltype(x *101 '325.0) |
Conversion from Atm to Pa. More... | |
template<class T > | |
constexpr auto | Conversion::pa2atm (T x) noexcept -> decltype(x/101 '325.0) |
Conversion from Pa to Atm. More... | |
template<class T > | |
constexpr auto | Conversion::bar2pa (T x) noexcept -> decltype(x *1e5) |
Conversion from bar to Pa. More... | |
template<class T > | |
constexpr auto | Conversion::pa2bar (T x) noexcept -> decltype(x *1e-5) |
Conversion from Pa to bar. More... | |
template<class T > | |
constexpr auto | Conversion::torr2pa (T x) noexcept -> decltype(x *atm2pa(1.0/760.0)) |
Conversion from Torr to Pa. More... | |
template<class T > | |
constexpr auto | Conversion::pa2torr (T x) noexcept -> decltype(x/atm2pa(1.0/760.0)) |
Conversion from Pa to Torr. More... | |
template<class T > | |
constexpr auto | Conversion::mhz_per_torr2hz_per_pa (T x) noexcept -> decltype(x *pa2torr(1e6)) |
Conversion from MHz/Torr to Hz/Pa. More... | |
template<class T > | |
constexpr auto | Conversion::celsius2kelvin (T x) noexcept -> decltype(x+273.15) |
Conversion from C to K. More... | |
template<class T > | |
constexpr auto | Conversion::kelvin2celsius (T x) noexcept -> decltype(x - 273.15) |
Conversion from K to C. More... | |
template<class T > | |
constexpr auto | Conversion::kaycm_per_cmsquared2hz_per_msquared (T x) noexcept -> decltype(x *kaycm2freq(1e-4)) |
Conversion from cm-1 per molecule per cm^2 to Hz per molecule per m^2. More... | |
template<class T > | |
constexpr auto | Conversion::hz_per_msquared2kaycm_per_cmsquared (T x) noexcept -> decltype(x *freq2kaycm(1e4)) |
Conversion from Hz per molecule per m^2 to cm-1 per molecule per cm^2. More... | |
template<class T > | |
constexpr auto | Conversion::kaycm_per_atm2hz_per_pa (T x) noexcept -> decltype(x *kaycm2freq(pa2atm(1))) |
Conversion from cm-1 per atmosphere to Hz per Pascal. More... | |
template<class T > | |
constexpr auto | Conversion::hz_per_pa2kaycm_per_atm (T x) noexcept -> decltype(x *freq2kaycm(atm2pa(1))) |
Conversion from Hz per Pascal to cm-1 per atmosphere. More... | |
template<class T > | |
constexpr auto | Conversion::kaycm2joule (T x) noexcept -> decltype(x *kaycm2freq(h)) |
Conversion from cm-1 to Joule. More... | |
template<class T > | |
constexpr auto | Conversion::hz2joule (T x) noexcept -> decltype(x *h) |
Conversion from MHz to Joule. More... | |
template<class T > | |
constexpr auto | Conversion::mhz2joule (T x) noexcept -> decltype(hz2joule(x) *1e6) |
Conversion from MHz to Joule. More... | |
template<class T > | |
constexpr auto | Conversion::kelvin2joule (T x) noexcept -> decltype(x *k) |
Conversion from Kelvin to Joule. More... | |
template<class T > | |
constexpr auto | Conversion::joule2hz (T x) noexcept -> decltype(x/h) |
Conversion from Hz to Joule. More... | |
template<class T > | |
constexpr auto | Conversion::joule2kaycm (T x) noexcept -> decltype(x/kaycm2freq(h)) |
Conversion from Joule to cm-1. More... | |
template<class T > | |
constexpr auto | Conversion::angstrom2meter (T x) noexcept -> decltype(x *1e-10) |
Conversion from Å to meter. More... | |
template<class T > | |
constexpr auto | Conversion::meter2angstrom (T x) noexcept -> decltype(x *1e10) |
Conversion from meter to Å More... | |
Options::ENUMCLASS (TimeStep, char, hour, hours, h, minute, minutes, min, second, seconds, s) ENUMCLASS(HitranType | |
Keep time options available to switch over them. More... | |
Variables | |
Options::char | |
Options::Pre2004 | |
Options::Post2004 | |
Constants of physical expressions as constexpr.
Following May 2019 reported SI unit updates, several previously important constant are proper constants and not derived constants.
This file contains the intended May 2019 constants update meaning that the Planck constant, Boltzmann constant, elementary charge, Avogadro number, the definition of a luminosity, the frequency of Cesium, and the speed of light have been given constant values.
All other values are derived. To be internally consistent in ARTS, the adaptation of these rules below take the approach that only the fine structure constant and the Rydberg constant are 'measurable' quantities. All other quantities are derived by their formal relationships. As an example, the resting mass of an electron is defined as 2 h R_inf / c alpha^2. This means that they should be constant in their internal relationships to the level permitted by the select floating point accuracy.
Note 1: The constants below contains both named and a few convenience variables
Note 2: Derived constants of convenience, such as the Doppler broadening constant, should also go into here if they have a clear name.
Note 3: The PrintPhysicalConstants convenience function is part of the global ARTS namespace. Please update this if and when new constants are added to this namespace.
Definition in file constants.h.