Merge branch 'master' into chiphogg/switch-to-mag

This commit is contained in:
Chip Hogg committed 2022-05-12 16:12:01 +00:00
commit 5fb468697b
165 files changed
+2468 -1522

No files matched your search

@@ -35,7 +35,7 @@
namespace units::isq::si {
struct gray : named_unit<gray, "Gy", prefix> {};
struct gray : named_unit<gray, "Gy"> {};
struct yoctogray : prefixed_unit<yoctogray, yocto, gray> {};
struct zeptogray : prefixed_unit<zeptogray, zepto, gray> {};
struct attogray : prefixed_unit<attogray, atto, gray> {};
@@ -33,7 +33,7 @@
namespace units::isq::si {
struct metre_per_second_sq : unit<metre_per_second_sq> {};
struct metre_per_second_sq : derived_unit<metre_per_second_sq> {};
struct dim_acceleration : isq::dim_acceleration<dim_acceleration, metre_per_second_sq, dim_length, dim_time> {};
template<UnitOf<dim_acceleration> U, Representation Rep = double>
@@ -34,7 +34,7 @@
namespace units::isq::si {
struct mole : named_unit<mole, "mol", prefix> {};
struct mole : named_unit<mole, "mol"> {};
struct dim_amount_of_substance : isq::dim_amount_of_substance<mole> {};
@@ -29,12 +29,13 @@
// IWYU pragma: end_exports
#include <units/generic/angle.h>
#include <units/isq/si/prefixes.h>
#include <units/isq/si/time.h>
#include <units/unit.h>
namespace units::isq::si {
struct radian_per_second : named_unit<radian_per_second, basic_symbol_text{"ω", "w"}, no_prefix> {};
struct radian_per_second : named_unit<radian_per_second, basic_symbol_text{"ω", "w"}> {};
struct dim_angular_velocity :
isq::dim_angular_velocity<dim_angular_velocity, radian_per_second, dim_angle<>, dim_time> {};
+62 -22
View File
@@ -34,31 +34,35 @@
namespace units::isq::si {
struct square_metre : unit<square_metre> {};
struct square_metre : derived_unit<square_metre> {};
struct dim_area : isq::dim_area<dim_area, square_metre, dim_length> {};
struct square_yoctometre : derived_unit<square_yoctometre, dim_area, yoctometre> {};
struct square_zeptometre : derived_unit<square_zeptometre, dim_area, zeptometre> {};
struct square_attometre : derived_unit<square_attometre, dim_area, attometre> {};
struct square_femtometre : derived_unit<square_femtometre, dim_area, femtometre> {};
struct square_picometre : derived_unit<square_picometre, dim_area, picometre> {};
struct square_nanometre : derived_unit<square_nanometre, dim_area, nanometre> {};
struct square_micrometre : derived_unit<square_micrometre, dim_area, micrometre> {};
struct square_millimetre : derived_unit<square_millimetre, dim_area, millimetre> {};
struct square_centimetre : derived_unit<square_centimetre, dim_area, centimetre> {};
struct square_decimetre : derived_unit<square_decimetre, dim_area, decimetre> {};
struct square_decametre : derived_unit<square_decametre, dim_area, decametre> {};
struct square_hectometre : derived_unit<square_hectometre, dim_area, hectometre> {};
struct square_kilometre : derived_unit<square_kilometre, dim_area, kilometre> {};
struct square_megametre : derived_unit<square_megametre, dim_area, megametre> {};
struct square_gigametre : derived_unit<square_gigametre, dim_area, gigametre> {};
struct square_terametre : derived_unit<square_terametre, dim_area, terametre> {};
struct square_petametre : derived_unit<square_petametre, dim_area, petametre> {};
struct square_exametre : derived_unit<square_exametre, dim_area, exametre> {};
struct square_zettametre : derived_unit<square_zettametre, dim_area, zettametre> {};
struct square_yottametre : derived_unit<square_yottametre, dim_area, yottametre> {};
struct square_yoctometre : derived_scaled_unit<square_yoctometre, dim_area, yoctometre> {};
struct square_zeptometre : derived_scaled_unit<square_zeptometre, dim_area, zeptometre> {};
struct square_attometre : derived_scaled_unit<square_attometre, dim_area, attometre> {};
struct square_femtometre : derived_scaled_unit<square_femtometre, dim_area, femtometre> {};
struct square_picometre : derived_scaled_unit<square_picometre, dim_area, picometre> {};
struct square_nanometre : derived_scaled_unit<square_nanometre, dim_area, nanometre> {};
struct square_micrometre : derived_scaled_unit<square_micrometre, dim_area, micrometre> {};
struct square_millimetre : derived_scaled_unit<square_millimetre, dim_area, millimetre> {};
struct square_centimetre : derived_scaled_unit<square_centimetre, dim_area, centimetre> {};
struct square_decimetre : derived_scaled_unit<square_decimetre, dim_area, decimetre> {};
struct square_decametre : derived_scaled_unit<square_decametre, dim_area, decametre> {};
struct square_hectometre : derived_scaled_unit<square_hectometre, dim_area, hectometre> {};
struct square_kilometre : derived_scaled_unit<square_kilometre, dim_area, kilometre> {};
struct square_megametre : derived_scaled_unit<square_megametre, dim_area, megametre> {};
struct square_gigametre : derived_scaled_unit<square_gigametre, dim_area, gigametre> {};
struct square_terametre : derived_scaled_unit<square_terametre, dim_area, terametre> {};
struct square_petametre : derived_scaled_unit<square_petametre, dim_area, petametre> {};
struct square_exametre : derived_scaled_unit<square_exametre, dim_area, exametre> {};
struct square_zettametre : derived_scaled_unit<square_zettametre, dim_area, zettametre> {};
struct square_yottametre : derived_scaled_unit<square_yottametre, dim_area, yottametre> {};
struct hectare : alias_unit<square_hectometre, "ha", no_prefix> {};
struct are : alias_unit<square_decametre, "a"> {};
struct centiare : prefixed_alias_unit<square_metre, centi, are> {};
struct deciare : prefixed_unit<deciare, deci, are> {};
struct decare : prefixed_unit<decare, deca, are> {};
struct hectare : prefixed_alias_unit<square_hectometre, hecto, are> {};
template<UnitOf<dim_area> U, Representation Rep = double>
using area = quantity<dim_area, U, Rep>;
@@ -235,6 +239,38 @@ constexpr auto operator"" _q_Ym2(unsigned long long l)
}
constexpr auto operator"" _q_Ym2(long double l) { return area<square_yottametre, long double>(l); }
// a
constexpr auto operator"" _q_a(unsigned long long l)
{
gsl_ExpectsAudit(std::in_range<std::int64_t>(l));
return area<are, std::int64_t>(static_cast<std::int64_t>(l));
}
constexpr auto operator"" _q_a(long double l) { return area<are, long double>(l); }
// ca
constexpr auto operator"" _q_ca(unsigned long long l)
{
gsl_ExpectsAudit(std::in_range<std::int64_t>(l));
return area<centiare, std::int64_t>(static_cast<std::int64_t>(l));
}
constexpr auto operator"" _q_ca(long double l) { return area<centiare, long double>(l); }
// da
constexpr auto operator"" _q_da(unsigned long long l)
{
gsl_ExpectsAudit(std::in_range<std::int64_t>(l));
return area<deciare, std::int64_t>(static_cast<std::int64_t>(l));
}
constexpr auto operator"" _q_da(long double l) { return area<deciare, long double>(l); }
// daa
constexpr auto operator"" _q_daa(unsigned long long l)
{
gsl_ExpectsAudit(std::in_range<std::int64_t>(l));
return area<decare, std::int64_t>(static_cast<std::int64_t>(l));
}
constexpr auto operator"" _q_daa(long double l) { return area<decare, long double>(l); }
// ha
constexpr auto operator"" _q_ha(unsigned long long l)
{
@@ -273,6 +309,10 @@ inline constexpr auto Em2 = reference<dim_area, square_exametre>{};
inline constexpr auto Zm2 = reference<dim_area, square_zettametre>{};
inline constexpr auto Ym2 = reference<dim_area, square_yottametre>{};
inline constexpr auto a = reference<dim_area, are>{};
inline constexpr auto ca = reference<dim_area, centiare>{};
inline constexpr auto da = reference<dim_area, deciare>{};
inline constexpr auto daa = reference<dim_area, decare>{};
inline constexpr auto ha = reference<dim_area, hectare>{};
} // namespace area_references
@@ -36,7 +36,7 @@
namespace units::isq::si {
struct farad : named_unit<farad, "F", prefix> {};
struct farad : named_unit<farad, "F"> {};
struct yoctofarad : prefixed_unit<yoctofarad, yocto, farad> {};
struct zeptofarad : prefixed_unit<zeptofarad, zepto, farad> {};
struct attofarad : prefixed_unit<attofarad, atto, farad> {};
@@ -36,7 +36,7 @@
namespace units::isq::si {
struct katal : named_unit<katal, "kat", prefix> {};
struct katal : named_unit<katal, "kat"> {};
struct yoctokatal : prefixed_unit<yoctokatal, yocto, katal> {};
struct zeptokatal : prefixed_unit<zeptokatal, zepto, katal> {};
struct attokatal : prefixed_unit<attokatal, atto, katal> {};
@@ -58,7 +58,7 @@ struct exakatal : prefixed_unit<exakatal, exa, katal> {};
struct zettakatal : prefixed_unit<zettakatal, zetta, katal> {};
struct yottakatal : prefixed_unit<yottakatal, yotta, katal> {};
struct enzyme_unit : named_scaled_unit<enzyme_unit, "U", prefix, as_magnitude<ratio(1, 60, -6)>(), katal> {};
struct enzyme_unit : named_scaled_unit<enzyme_unit, "U", as_magnitude<ratio(1, 60, -6)>(), katal> {};
struct dim_catalytic_activity :
isq::dim_catalytic_activity<dim_catalytic_activity, katal, dim_time, dim_amount_of_substance> {};
@@ -35,8 +35,8 @@
namespace units::isq::si {
struct coulomb_per_metre_cub : unit<coulomb_per_metre_cub> {};
struct coulomb_per_metre_sq : unit<coulomb_per_metre_sq> {};
struct coulomb_per_metre_cub : derived_unit<coulomb_per_metre_cub> {};
struct coulomb_per_metre_sq : derived_unit<coulomb_per_metre_sq> {};
struct dim_charge_density :
isq::dim_charge_density<dim_charge_density, coulomb_per_metre_cub, dim_electric_charge, dim_length> {};
@@ -34,7 +34,7 @@
namespace units::isq::si {
struct mol_per_metre_cub : unit<mol_per_metre_cub> {};
struct mol_per_metre_cub : derived_unit<mol_per_metre_cub> {};
struct dim_concentration :
isq::dim_concentration<dim_concentration, mol_per_metre_cub, dim_amount_of_substance, dim_length> {};
@@ -35,7 +35,7 @@
namespace units::isq::si {
struct siemens : named_unit<siemens, "S", prefix> {};
struct siemens : named_unit<siemens, "S"> {};
struct yoctosiemens : prefixed_unit<yoctosiemens, yocto, siemens> {};
struct zeptosiemens : prefixed_unit<zeptosiemens, zepto, siemens> {};
struct attosiemens : prefixed_unit<attosiemens, atto, siemens> {};
@@ -35,7 +35,7 @@
namespace units::isq::si {
struct ampere_per_metre_sq : unit<ampere_per_metre_sq> {};
struct ampere_per_metre_sq : derived_unit<ampere_per_metre_sq> {};
struct dim_current_density :
isq::dim_current_density<dim_current_density, ampere_per_metre_sq, dim_electric_current, dim_length> {};
@@ -35,7 +35,7 @@
namespace units::isq::si {
struct kilogram_per_metre_cub : unit<kilogram_per_metre_cub> {};
struct kilogram_per_metre_cub : derived_unit<kilogram_per_metre_cub> {};
struct dim_density : isq::dim_density<dim_density, kilogram_per_metre_cub, dim_mass, dim_length> {};
@@ -34,7 +34,7 @@
namespace units::isq::si {
struct pascal_second : unit<pascal_second> {};
struct pascal_second : derived_unit<pascal_second> {};
struct dim_dynamic_viscosity :
isq::dim_dynamic_viscosity<dim_dynamic_viscosity, pascal_second, dim_pressure, dim_time> {};
@@ -35,7 +35,7 @@
namespace units::isq::si {
struct coulomb : named_unit<coulomb, "C", prefix> {};
struct coulomb : named_unit<coulomb, "C"> {};
struct dim_electric_charge : isq::dim_electric_charge<dim_electric_charge, coulomb, dim_time, dim_electric_current> {};
@@ -34,7 +34,7 @@
namespace units::isq::si {
struct ampere : named_unit<ampere, "A", prefix> {};
struct ampere : named_unit<ampere, "A"> {};
struct yoctoampere : prefixed_unit<yoctoampere, yocto, ampere> {};
struct zeptoampere : prefixed_unit<zeptoampere, zepto, ampere> {};
struct attoampere : prefixed_unit<attoampere, atto, ampere> {};
@@ -33,7 +33,7 @@
namespace units::isq::si {
struct volt_per_metre : unit<volt_per_metre> {};
struct volt_per_metre : derived_unit<volt_per_metre> {};
struct dim_electric_field_strength :
isq::dim_electric_field_strength<dim_electric_field_strength, volt_per_metre, dim_voltage, dim_length> {};
+2 -2
View File
@@ -35,7 +35,7 @@
namespace units::isq::si {
struct joule : named_unit<joule, "J", prefix> {};
struct joule : named_unit<joule, "J"> {};
struct yoctojoule : prefixed_unit<yoctojoule, yocto, joule> {};
struct zeptojoule : prefixed_unit<zeptojoule, zepto, joule> {};
struct attojoule : prefixed_unit<attojoule, atto, joule> {};
@@ -56,7 +56,7 @@ struct yottajoule : prefixed_unit<yottajoule, yotta, joule> {};
// N.B. electron charge (and eV) is an exact constant:
// https://www.bipm.org/documents/20126/41483022/SI-Brochure-9.pdf#page=147
struct electronvolt :
named_scaled_unit<electronvolt, "eV", prefix, as_magnitude<ratio(1'602'176'634, 1'000'000'000, -19)>(), joule> {};
named_scaled_unit<electronvolt, "eV", as_magnitude<ratio(1'602'176'634, 1'000'000'000, -19)>(), joule> {};
struct gigaelectronvolt : prefixed_unit<gigaelectronvolt, giga, electronvolt> {};
struct dim_energy : isq::dim_energy<dim_energy, joule, dim_force, dim_length> {};
@@ -34,7 +34,7 @@
namespace units::isq::si {
struct joule_per_metre_cub : unit<joule_per_metre_cub> {};
struct joule_per_metre_cub : derived_unit<joule_per_metre_cub> {};
struct dim_energy_density : isq::dim_energy_density<dim_energy_density, joule_per_metre_cub, dim_energy, dim_volume> {};
template<UnitOf<dim_energy_density> U, Representation Rep = double>
+1 -1
View File
@@ -36,7 +36,7 @@
namespace units::isq::si {
struct newton : named_unit<newton, "N", prefix> {};
struct newton : named_unit<newton, "N"> {};
struct yoctonewton : prefixed_unit<yoctonewton, yocto, newton> {};
struct zeptonewton : prefixed_unit<zeptonewton, zepto, newton> {};
struct attonewton : prefixed_unit<attonewton, atto, newton> {};
@@ -34,7 +34,7 @@
namespace units::isq::si {
struct hertz : named_unit<hertz, "Hz", prefix> {};
struct hertz : named_unit<hertz, "Hz"> {};
struct yoctohertz : prefixed_unit<yoctohertz, yocto, hertz> {};
struct zeptohertz : prefixed_unit<zeptohertz, zepto, hertz> {};
struct attohertz : prefixed_unit<attohertz, atto, hertz> {};
@@ -36,9 +36,9 @@
namespace units::isq::si {
struct joule_per_kelvin : unit<joule_per_kelvin> {};
struct joule_per_kilogram_kelvin : unit<joule_per_kilogram_kelvin> {};
struct joule_per_mole_kelvin : unit<joule_per_mole_kelvin> {};
struct joule_per_kelvin : derived_unit<joule_per_kelvin> {};
struct joule_per_kilogram_kelvin : derived_unit<joule_per_kilogram_kelvin> {};
struct joule_per_mole_kelvin : derived_unit<joule_per_mole_kelvin> {};
struct dim_heat_capacity :
isq::dim_heat_capacity<dim_heat_capacity, joule_per_kelvin, dim_energy, dim_thermodynamic_temperature> {};
@@ -35,7 +35,7 @@
namespace units::isq::si {
struct henry : named_unit<henry, "H", prefix> {};
struct henry : named_unit<henry, "H"> {};
struct yoctohenry : prefixed_unit<yoctohenry, yocto, henry> {};
struct zeptohenry : prefixed_unit<zeptohenry, zepto, henry> {};
+2 -3
View File
@@ -34,7 +34,7 @@
namespace units::isq::si {
struct metre : named_unit<metre, "m", prefix> {};
struct metre : named_unit<metre, "m"> {};
struct yoctometre : prefixed_unit<yoctometre, yocto, metre> {};
struct zeptometre : prefixed_unit<zeptometre, zepto, metre> {};
struct attometre : prefixed_unit<attometre, atto, metre> {};
@@ -56,8 +56,7 @@ struct exametre : prefixed_unit<exametre, exa, metre> {};
struct zettametre : prefixed_unit<zettametre, zetta, metre> {};
struct yottametre : prefixed_unit<yottametre, yotta, metre> {};
struct astronomical_unit :
named_scaled_unit<astronomical_unit, "au", no_prefix, as_magnitude<149'597'870'700>(), metre> {};
struct astronomical_unit : named_scaled_unit<astronomical_unit, "au", as_magnitude<149'597'870'700>(), metre> {};
struct dim_length : isq::dim_length<metre> {};
@@ -34,7 +34,7 @@
namespace units::isq::si {
struct candela_per_metre_sq : unit<candela_per_metre_sq> {};
struct candela_per_metre_sq : derived_unit<candela_per_metre_sq> {};
struct dim_luminance : isq::dim_luminance<dim_luminance, candela_per_metre_sq, dim_luminous_intensity, dim_length> {};
template<UnitOf<dim_luminance> U, Representation Rep = double>
@@ -34,7 +34,7 @@
namespace units::isq::si {
struct candela : named_unit<candela, "cd", prefix> {};
struct candela : named_unit<candela, "cd"> {};
struct yoctocandela : prefixed_unit<yoctocandela, yocto, candela> {};
struct zeptocandela : prefixed_unit<zeptocandela, zepto, candela> {};
struct attocandela : prefixed_unit<attocandela, atto, candela> {};
@@ -35,7 +35,7 @@
namespace units::isq::si {
struct weber : named_unit<weber, "Wb", prefix> {};
struct weber : named_unit<weber, "Wb"> {};
struct yoctoweber : prefixed_unit<yoctoweber, yocto, weber> {};
struct zeptoweber : prefixed_unit<zeptoweber, zepto, weber> {};
@@ -37,7 +37,7 @@
namespace units::isq::si {
struct tesla : named_unit<tesla, "T", prefix> {};
struct tesla : named_unit<tesla, "T"> {};
struct yoctotesla : prefixed_unit<yoctotesla, yocto, tesla> {};
struct zeptotesla : prefixed_unit<zeptotesla, zepto, tesla> {};
@@ -56,7 +56,7 @@ struct exatesla : prefixed_unit<exatesla, exa, tesla> {};
struct zettatesla : prefixed_unit<zettatesla, zetta, tesla> {};
struct yottatesla : prefixed_unit<yottatesla, yotta, tesla> {};
struct gauss : named_scaled_unit<gauss, "G", prefix, as_magnitude<ratio(1, 10'000)>(), tesla> {};
struct gauss : named_scaled_unit<gauss, "G", as_magnitude<ratio(1, 10'000)>(), tesla> {};
struct dim_magnetic_induction :
isq::dim_magnetic_induction<dim_magnetic_induction, tesla, dim_voltage, dim_time, dim_length> {};
+3 -4
View File
@@ -34,7 +34,7 @@
namespace units::isq::si {
struct gram : named_unit<gram, "g", prefix> {};
struct gram : named_unit<gram, "g"> {};
struct yoctogram : prefixed_unit<yoctogram, yocto, gram> {};
struct zeptogram : prefixed_unit<zeptogram, zepto, gram> {};
struct attogram : prefixed_unit<attogram, atto, gram> {};
@@ -56,7 +56,7 @@ struct exagram : prefixed_unit<exagram, exa, gram> {};
struct zettagram : prefixed_unit<zettagram, zetta, gram> {};
struct yottagram : prefixed_unit<yottagram, yotta, gram> {};
struct tonne : alias_unit<megagram, "t", prefix> {};
struct tonne : alias_unit<megagram, "t"> {};
struct yoctotonne : prefixed_alias_unit<attogram, yocto, tonne> {};
struct zeptotonne : prefixed_alias_unit<femtogram, zepto, tonne> {};
struct attotonne : prefixed_alias_unit<picogram, atto, tonne> {};
@@ -79,8 +79,7 @@ struct zettatonne : prefixed_unit<zettatonne, zetta, tonne> {};
struct yottatonne : prefixed_unit<yottatonne, yotta, tonne> {};
struct dalton :
named_scaled_unit<dalton, "Da", no_prefix, as_magnitude<ratio(16'605'390'666'050, 10'000'000'000'000, -27)>(),
kilogram> {};
named_scaled_unit<dalton, "Da", as_magnitude<ratio(16'605'390'666'050, 10'000'000'000'000, -27)>(), kilogram> {};
struct dim_mass : isq::dim_mass<kilogram> {};
@@ -35,7 +35,7 @@
namespace units::isq::si {
struct joule_per_mole : unit<joule_per_mole> {};
struct joule_per_mole : derived_unit<joule_per_mole> {};
struct dim_molar_energy :
isq::dim_molar_energy<dim_molar_energy, joule_per_mole, dim_energy, dim_amount_of_substance> {};
@@ -34,7 +34,7 @@
namespace units::isq::si {
struct kilogram_metre_per_second : unit<kilogram_metre_per_second> {};
struct kilogram_metre_per_second : derived_unit<kilogram_metre_per_second> {};
struct dim_momentum : isq::dim_momentum<dim_momentum, kilogram_metre_per_second, dim_mass, dim_speed> {};
template<UnitOf<dim_momentum> U, Representation Rep = double>
@@ -34,7 +34,7 @@
namespace units::isq::si {
struct henry_per_metre : unit<henry_per_metre> {};
struct henry_per_metre : derived_unit<henry_per_metre> {};
struct dim_permeability : isq::dim_permeability<dim_permeability, henry_per_metre, dim_inductance, dim_length> {};
@@ -34,7 +34,7 @@
namespace units::isq::si {
struct farad_per_metre : unit<farad_per_metre> {};
struct farad_per_metre : derived_unit<farad_per_metre> {};
struct dim_permittivity : isq::dim_permittivity<dim_permittivity, farad_per_metre, dim_capacitance, dim_length> {};
+1 -1
View File
@@ -35,7 +35,7 @@
namespace units::isq::si {
struct watt : named_unit<watt, "W", prefix> {};
struct watt : named_unit<watt, "W"> {};
struct yoctowatt : prefixed_unit<yoctowatt, yocto, watt> {};
struct zeptowatt : prefixed_unit<zeptowatt, zepto, watt> {};
struct attowatt : prefixed_unit<attowatt, atto, watt> {};
+20 -22
View File
@@ -26,29 +26,27 @@
namespace units::isq::si {
struct prefix : prefix_family {};
// clang-format off
struct yocto : units::prefix<yocto, prefix, "y", ratio(1, 1, -24)> {};
struct zepto : units::prefix<zepto, prefix, "z", ratio(1, 1, -21)> {};
struct atto : units::prefix<atto, prefix, "a", ratio(1, 1, -18)> {};
struct femto : units::prefix<femto, prefix, "f", ratio(1, 1, -15)> {};
struct pico : units::prefix<pico, prefix, "p", ratio(1, 1, -12)> {};
struct nano : units::prefix<nano, prefix, "n", ratio(1, 1, -9)> {};
struct micro : units::prefix<micro, prefix, basic_symbol_text{"\u00b5", "u"}, ratio(1, 1, -6)> {};
struct milli : units::prefix<milli, prefix, "m", ratio(1, 1, -3)> {};
struct centi : units::prefix<centi, prefix, "c", ratio(1, 1, -2)> {};
struct deci : units::prefix<deci, prefix, "d", ratio(1, 1, -1)> {};
struct deca : units::prefix<deca, prefix, "da", ratio(1, 1, 1)> {};
struct hecto : units::prefix<hecto, prefix, "h", ratio(1, 1, 2)> {};
struct kilo : units::prefix<kilo, prefix, "k", ratio(1, 1, 3)> {};
struct mega : units::prefix<mega, prefix, "M", ratio(1, 1, 6)> {};
struct giga : units::prefix<giga, prefix, "G", ratio(1, 1, 9)> {};
struct tera : units::prefix<tera, prefix, "T", ratio(1, 1, 12)> {};
struct peta : units::prefix<peta, prefix, "P", ratio(1, 1, 15)> {};
struct exa : units::prefix<exa, prefix, "E", ratio(1, 1, 18)> {};
struct zetta : units::prefix<zetta, prefix, "Z", ratio(1, 1, 21)> {};
struct yotta : units::prefix<yotta, prefix, "Y", ratio(1, 1, 24)> {};
struct yocto : units::prefix<yocto, "y", ratio(1, 1, -24)> {};
struct zepto : units::prefix<zepto, "z", ratio(1, 1, -21)> {};
struct atto : units::prefix<atto, "a", ratio(1, 1, -18)> {};
struct femto : units::prefix<femto, "f", ratio(1, 1, -15)> {};
struct pico : units::prefix<pico, "p", ratio(1, 1, -12)> {};
struct nano : units::prefix<nano, "n", ratio(1, 1, -9)> {};
struct micro : units::prefix<micro, basic_symbol_text{"\u00b5", "u"}, ratio(1, 1, -6)> {};
struct milli : units::prefix<milli, "m", ratio(1, 1, -3)> {};
struct centi : units::prefix<centi, "c", ratio(1, 1, -2)> {};
struct deci : units::prefix<deci, "d", ratio(1, 1, -1)> {};
struct deca : units::prefix<deca, "da", ratio(1, 1, 1)> {};
struct hecto : units::prefix<hecto, "h", ratio(1, 1, 2)> {};
struct kilo : units::prefix<kilo, "k", ratio(1, 1, 3)> {};
struct mega : units::prefix<mega, "M", ratio(1, 1, 6)> {};
struct giga : units::prefix<giga, "G", ratio(1, 1, 9)> {};
struct tera : units::prefix<tera, "T", ratio(1, 1, 12)> {};
struct peta : units::prefix<peta, "P", ratio(1, 1, 15)> {};
struct exa : units::prefix<exa, "E", ratio(1, 1, 18)> {};
struct zetta : units::prefix<zetta, "Z", ratio(1, 1, 21)> {};
struct yotta : units::prefix<yotta, "Y", ratio(1, 1, 24)> {};
// clang-format on
} // namespace units::isq::si
@@ -36,7 +36,7 @@
namespace units::isq::si {
struct pascal : named_unit<pascal, "Pa", prefix> {};
struct pascal : named_unit<pascal, "Pa"> {};
struct yoctopascal : prefixed_unit<yoctopascal, yocto, pascal> {};
struct zeptopascal : prefixed_unit<zeptopascal, zepto, pascal> {};
struct attopascal : prefixed_unit<attopascal, atto, pascal> {};
@@ -34,7 +34,7 @@
namespace units::isq::si {
struct becquerel : named_unit<becquerel, "Bq", prefix> {};
struct becquerel : named_unit<becquerel, "Bq"> {};
struct yoctobecquerel : prefixed_unit<yoctobecquerel, yocto, becquerel> {};
struct zeptobecquerel : prefixed_unit<zeptobecquerel, zepto, becquerel> {};
struct attobecquerel : prefixed_unit<attobecquerel, atto, becquerel> {};
@@ -280,47 +280,47 @@ using namespace radioactivity_references;
namespace units::aliases::isq::si::inline radioactivity {
template<Representation Rep = double>
using Bq = units::isq::radioactivity<units::isq::becquerel, Rep>;
using Bq = units::isq::si::radioactivity<units::isq::si::becquerel, Rep>;
template<Representation Rep = double>
using yBq = units::isq::radioactivity<units::isq::yoctobecquerel, Rep>;
using yBq = units::isq::si::radioactivity<units::isq::si::yoctobecquerel, Rep>;
template<Representation Rep = double>
using zBq = units::isq::radioactivity<units::isq::zeptobecquerel, Rep>;
using zBq = units::isq::si::radioactivity<units::isq::si::zeptobecquerel, Rep>;
template<Representation Rep = double>
using aBq = units::isq::radioactivity<units::isq::attobecquerel, Rep>;
using aBq = units::isq::si::radioactivity<units::isq::si::attobecquerel, Rep>;
template<Representation Rep = double>
using fBq = units::isq::radioactivity<units::isq::femtobecquerel, Rep>;
using fBq = units::isq::si::radioactivity<units::isq::si::femtobecquerel, Rep>;
template<Representation Rep = double>
using pBq = units::isq::radioactivity<units::isq::picobecquerel, Rep>;
using pBq = units::isq::si::radioactivity<units::isq::si::picobecquerel, Rep>;
template<Representation Rep = double>
using nBq = units::isq::radioactivity<units::isq::nanobecquerel, Rep>;
using nBq = units::isq::si::radioactivity<units::isq::si::nanobecquerel, Rep>;
template<Representation Rep = double>
using uBq = units::isq::radioactivity<units::isq::microbecquerel, Rep>;
using uBq = units::isq::si::radioactivity<units::isq::si::microbecquerel, Rep>;
template<Representation Rep = double>
using mBq = units::isq::radioactivity<units::isq::millibecquerel, Rep>;
using mBq = units::isq::si::radioactivity<units::isq::si::millibecquerel, Rep>;
template<Representation Rep = double>
using cBq = units::isq::radioactivity<units::isq::centibecquerel, Rep>;
using cBq = units::isq::si::radioactivity<units::isq::si::centibecquerel, Rep>;
template<Representation Rep = double>
using dBq = units::isq::radioactivity<units::isq::decibecquerel, Rep>;
using dBq = units::isq::si::radioactivity<units::isq::si::decibecquerel, Rep>;
template<Representation Rep = double>
using daBq = units::isq::radioactivity<units::isq::decabecquerel, Rep>;
using daBq = units::isq::si::radioactivity<units::isq::si::decabecquerel, Rep>;
template<Representation Rep = double>
using hBq = units::isq::radioactivity<units::isq::hectobecquerel, Rep>;
using hBq = units::isq::si::radioactivity<units::isq::si::hectobecquerel, Rep>;
template<Representation Rep = double>
using kBq = units::isq::radioactivity<units::isq::kilobecquerel, Rep>;
using kBq = units::isq::si::radioactivity<units::isq::si::kilobecquerel, Rep>;
template<Representation Rep = double>
using MBq = units::isq::radioactivity<units::isq::megabecquerel, Rep>;
using MBq = units::isq::si::radioactivity<units::isq::si::megabecquerel, Rep>;
template<Representation Rep = double>
using GBq = units::isq::radioactivity<units::isq::gigabecquerel, Rep>;
using GBq = units::isq::si::radioactivity<units::isq::si::gigabecquerel, Rep>;
template<Representation Rep = double>
using TBq = units::isq::radioactivity<units::isq::terabecquerel, Rep>;
using TBq = units::isq::si::radioactivity<units::isq::si::terabecquerel, Rep>;
template<Representation Rep = double>
using PBq = units::isq::radioactivity<units::isq::petabecquerel, Rep>;
using PBq = units::isq::si::radioactivity<units::isq::si::petabecquerel, Rep>;
template<Representation Rep = double>
using EBq = units::isq::radioactivity<units::isq::exabecquerel, Rep>;
using EBq = units::isq::si::radioactivity<units::isq::si::exabecquerel, Rep>;
template<Representation Rep = double>
using ZBq = units::isq::radioactivity<units::isq::zettabecquerel, Rep>;
using ZBq = units::isq::si::radioactivity<units::isq::si::zettabecquerel, Rep>;
template<Representation Rep = double>
using YBq = units::isq::radioactivity<units::isq::yottabecquerel, Rep>;
using YBq = units::isq::si::radioactivity<units::isq::si::yottabecquerel, Rep>;
} // namespace units::aliases::isq::si::inline radioactivity
@@ -36,7 +36,7 @@
namespace units::isq::si {
struct ohm : named_unit<ohm, basic_symbol_text{"Ω", "ohm"}, prefix> {};
struct ohm : named_unit<ohm, basic_symbol_text{"Ω", "ohm"}> {};
struct yoctoohm : prefixed_unit<yoctoohm, yocto, ohm> {};
struct zeptoohm : prefixed_unit<zeptoohm, zepto, ohm> {};
struct attoohm : prefixed_unit<attoohm, atto, ohm> {};
+2 -2
View File
@@ -34,10 +34,10 @@
namespace units::isq::si {
struct metre_per_second : unit<metre_per_second> {};
struct metre_per_second : derived_unit<metre_per_second> {};
struct dim_speed : isq::dim_speed<dim_speed, metre_per_second, dim_length, dim_time> {};
struct kilometre_per_hour : derived_unit<kilometre_per_hour, dim_speed, kilometre, hour> {};
struct kilometre_per_hour : derived_scaled_unit<kilometre_per_hour, dim_speed, kilometre, hour> {};
template<UnitOf<dim_speed> U, Representation Rep = double>
using speed = quantity<dim_speed, U, Rep>;
@@ -33,7 +33,7 @@
namespace units::isq::si {
struct newton_per_metre : unit<newton_per_metre> {};
struct newton_per_metre : derived_unit<newton_per_metre> {};
struct dim_surface_tension : isq::dim_surface_tension<dim_surface_tension, newton_per_metre, dim_force, dim_length> {};
@@ -34,7 +34,7 @@
namespace units::isq::si {
struct watt_per_metre_kelvin : unit<watt_per_metre_kelvin> {};
struct watt_per_metre_kelvin : derived_unit<watt_per_metre_kelvin> {};
struct dim_thermal_conductivity :
isq::dim_thermal_conductivity<dim_thermal_conductivity, watt_per_metre_kelvin, dim_power, dim_length,
@@ -29,11 +29,12 @@
#include <units/symbol_text.h>
// IWYU pragma: end_exports
#include <units/isq/si/prefixes.h>
#include <units/unit.h>
namespace units::isq::si {
struct kelvin : named_unit<kelvin, "K", no_prefix> {};
struct kelvin : named_unit<kelvin, "K"> {};
struct dim_thermodynamic_temperature : isq::dim_thermodynamic_temperature<kelvin> {};
+4 -4
View File
@@ -34,7 +34,7 @@
namespace units::isq::si {
struct second : named_unit<second, "s", prefix> {};
struct second : named_unit<second, "s"> {};
struct yoctosecond : prefixed_unit<yoctosecond, yocto, second> {};
struct zeptosecond : prefixed_unit<zeptosecond, zepto, second> {};
struct attosecond : prefixed_unit<attosecond, atto, second> {};
@@ -43,9 +43,9 @@ struct picosecond : prefixed_unit<picosecond, pico, second> {};
struct nanosecond : prefixed_unit<nanosecond, nano, second> {};
struct microsecond : prefixed_unit<microsecond, micro, second> {};
struct millisecond : prefixed_unit<millisecond, milli, second> {};
struct minute : named_scaled_unit<minute, "min", no_prefix, as_magnitude<60>(), second> {};
struct hour : named_scaled_unit<hour, "h", no_prefix, as_magnitude<60>(), minute> {};
struct day : named_scaled_unit<day, "d", no_prefix, as_magnitude<24>(), hour> {};
struct minute : named_scaled_unit<minute, "min", as_magnitude<60>(), second> {};
struct hour : named_scaled_unit<hour, "h", as_magnitude<60>(), minute> {};
struct day : named_scaled_unit<day, "d", as_magnitude<24>(), hour> {};
struct dim_time : isq::dim_time<second> {};
+1 -1
View File
@@ -35,7 +35,7 @@
namespace units::isq::si {
struct newton_metre_per_radian : unit<newton_metre_per_radian> {};
struct newton_metre_per_radian : derived_unit<newton_metre_per_radian> {};
struct dim_torque : isq::dim_torque<dim_torque, newton_metre_per_radian, dim_force, dim_length, dim_angle<>> {};
@@ -36,7 +36,7 @@
namespace units::isq::si {
struct volt : named_unit<volt, "V", prefix> {};
struct volt : named_unit<volt, "V"> {};
struct yoctovolt : prefixed_unit<yoctovolt, yocto, volt> {};
struct zeptovolt : prefixed_unit<zeptovolt, zepto, volt> {};
struct attovolt : prefixed_unit<attovolt, atto, volt> {};
+22 -22
View File
@@ -34,31 +34,31 @@
namespace units::isq::si {
struct cubic_metre : unit<cubic_metre> {};
struct cubic_metre : derived_unit<cubic_metre> {};
struct dim_volume : isq::dim_volume<dim_volume, cubic_metre, dim_length> {};
struct cubic_yoctometre : derived_unit<cubic_yoctometre, dim_volume, yoctometre> {};
struct cubic_zeptometre : derived_unit<cubic_zeptometre, dim_volume, zeptometre> {};
struct cubic_attometre : derived_unit<cubic_attometre, dim_volume, attometre> {};
struct cubic_femtometre : derived_unit<cubic_femtometre, dim_volume, femtometre> {};
struct cubic_picometre : derived_unit<cubic_picometre, dim_volume, picometre> {};
struct cubic_nanometre : derived_unit<cubic_nanometre, dim_volume, nanometre> {};
struct cubic_micrometre : derived_unit<cubic_micrometre, dim_volume, micrometre> {};
struct cubic_millimetre : derived_unit<cubic_millimetre, dim_volume, millimetre> {};
struct cubic_centimetre : derived_unit<cubic_centimetre, dim_volume, centimetre> {};
struct cubic_decimetre : derived_unit<cubic_decimetre, dim_volume, decimetre> {};
struct cubic_decametre : derived_unit<cubic_decametre, dim_volume, decametre> {};
struct cubic_hectometre : derived_unit<cubic_hectometre, dim_volume, hectometre> {};
struct cubic_kilometre : derived_unit<cubic_kilometre, dim_volume, kilometre> {};
struct cubic_megametre : derived_unit<cubic_megametre, dim_volume, megametre> {};
struct cubic_gigametre : derived_unit<cubic_gigametre, dim_volume, gigametre> {};
struct cubic_terametre : derived_unit<cubic_terametre, dim_volume, terametre> {};
struct cubic_petametre : derived_unit<cubic_petametre, dim_volume, petametre> {};
struct cubic_exametre : derived_unit<cubic_exametre, dim_volume, exametre> {};
struct cubic_zettametre : derived_unit<cubic_zettametre, dim_volume, zettametre> {};
struct cubic_yottametre : derived_unit<cubic_yottametre, dim_volume, yottametre> {};
struct cubic_yoctometre : derived_scaled_unit<cubic_yoctometre, dim_volume, yoctometre> {};
struct cubic_zeptometre : derived_scaled_unit<cubic_zeptometre, dim_volume, zeptometre> {};
struct cubic_attometre : derived_scaled_unit<cubic_attometre, dim_volume, attometre> {};
struct cubic_femtometre : derived_scaled_unit<cubic_femtometre, dim_volume, femtometre> {};
struct cubic_picometre : derived_scaled_unit<cubic_picometre, dim_volume, picometre> {};
struct cubic_nanometre : derived_scaled_unit<cubic_nanometre, dim_volume, nanometre> {};
struct cubic_micrometre : derived_scaled_unit<cubic_micrometre, dim_volume, micrometre> {};
struct cubic_millimetre : derived_scaled_unit<cubic_millimetre, dim_volume, millimetre> {};
struct cubic_centimetre : derived_scaled_unit<cubic_centimetre, dim_volume, centimetre> {};
struct cubic_decimetre : derived_scaled_unit<cubic_decimetre, dim_volume, decimetre> {};
struct cubic_decametre : derived_scaled_unit<cubic_decametre, dim_volume, decametre> {};
struct cubic_hectometre : derived_scaled_unit<cubic_hectometre, dim_volume, hectometre> {};
struct cubic_kilometre : derived_scaled_unit<cubic_kilometre, dim_volume, kilometre> {};
struct cubic_megametre : derived_scaled_unit<cubic_megametre, dim_volume, megametre> {};
struct cubic_gigametre : derived_scaled_unit<cubic_gigametre, dim_volume, gigametre> {};
struct cubic_terametre : derived_scaled_unit<cubic_terametre, dim_volume, terametre> {};
struct cubic_petametre : derived_scaled_unit<cubic_petametre, dim_volume, petametre> {};
struct cubic_exametre : derived_scaled_unit<cubic_exametre, dim_volume, exametre> {};
struct cubic_zettametre : derived_scaled_unit<cubic_zettametre, dim_volume, zettametre> {};
struct cubic_yottametre : derived_scaled_unit<cubic_yottametre, dim_volume, yottametre> {};
struct litre : alias_unit<cubic_decimetre, "l", prefix> {};
struct litre : alias_unit<cubic_decimetre, "l"> {};
struct yoctolitre : prefixed_alias_unit<cubic_nanometre, yocto, litre> {};
struct zeptolitre : prefixed_unit<zeptolitre, zepto, litre> {};
struct attolitre : prefixed_unit<attolitre, atto, litre> {};