Skip to content

mp_units::natural

A system of natural units, where the speed of light and the reduced Planck constant are 1

Description

Energy is the only base dimension, so mass, length, and time are all measured in powers of the electronvolt.

using natural::unit_symbols::GeV;

quantity proton_mass = natural::mass(0.938 * GeV);
quantity duration = natural::duration(1. / GeV);  // time is an inverse energy

Types

Functions

NameDescription
cbrt
inverse
operator* scaled_unit specializations have priority in this operation. This means that the library framework prevents passing it as an element to the derived_unit. In such case only the reference unit is passed to the derived unit and the magnitude remains outside forming another scaled unit as a result of the operation.
operator/ scaled_unit specializations have priority in this operation. This means that the library framework prevents passing it as an element to the derived_unit. In such case only the reference unit is passed to the derived unit and the magnitude remains outside forming another scaled unit as a result of the operation.
pow
sqrt
operator<< Stream insertion operator
operator== Equality operator

Variables

See Also