diff options
author | Claudius "keldu" Holeksa <mail@keldu.de> | 2025-04-18 18:23:46 +0200 |
---|---|---|
committer | Claudius "keldu" Holeksa <mail@keldu.de> | 2025-04-18 18:23:46 +0200 |
commit | ae5c44f37053d3df869dd6ac975f74a604c6de9d (patch) | |
tree | 7ed86734e2a1f46f7a6d19cb456a1879904223f1 /c++/lbm_unit.hpp | |
parent | b0a68aba927aaafc97816d18b50b219a595b4dd2 (diff) |
wip which doesn't compile yetdev
Diffstat (limited to 'c++/lbm_unit.hpp')
-rw-r--r-- | c++/lbm_unit.hpp | 44 |
1 files changed, 36 insertions, 8 deletions
diff --git a/c++/lbm_unit.hpp b/c++/lbm_unit.hpp index dc1f8e9..4cb9b52 100644 --- a/c++/lbm_unit.hpp +++ b/c++/lbm_unit.hpp @@ -8,26 +8,54 @@ namespace kel { namespace lbm { namespace lbm_type { struct meter { - static constexpr std::string_view name = "meter_l"; - static constexpr std::string_view short_name = "m_l"; + static constexpr std::string_view name = "meter_lbm"; + static constexpr std::string_view short_name = "m_lbm"; }; struct second { - static constexpr std::string_view name = "second_l"; - static constexpr std::string_view short_name = "s_l"; + static constexpr std::string_view name = "second_lbm"; + static constexpr std::string_view short_name = "s_lbm"; }; } +namespace si_type { +struct meter { + static constexpr std::string_view name = "meter_si"; + static constexpr std::string_view short_name = "m_si"; +}; + +struct second { + static constexpr std::string_view name = "second_si"; + static constexpr std::string_view short_name = "s_si"; +}; +} + +namesapce sch { + +template<typename S> +using SiMeter = schema::Unit<S, schema::UnitElement<si_type::meter, 1>>; + +template<typename S> +using LbmMeter = schema::Unit<S, schema::UnitElement<lbm_type::meter, 1>>; + +template<typename S> +using SiSecond = schema::Unit<S, schema::UnitElement<si_type::meter, 1>>; + template<typename S> -using lbm_meter = unit<S, unit_component<lbm_type::meter, 1>>; +using LbmSecond = schema::Unit<S, schema::UnitElement<lbm_type::second, 1>>; template<typename S> -using lbm_second = unit<S, unit_component<lbm_type::second, 1>>; +using SiVelocity = schema::Unit<S, schema::UnitElement<si_type::meter, 1>, schema::UnitElement<si_type::second, -1>>; template<typename S> -using lbm_velocity = unit<S, unit_component<lbm_type::meter, 1>, unit_component<lbm_type::second, -1>>; +using LbmVelocity = schema::Unit<S, schema::UnitElement<lbm_type::meter, 1>, schema::UnitElement<lbm_type::second, -1>>; template<typename S> -using lbm_acceleration = unit<S, unit_component<lbm_type::meter, 1>, unit_component<lbm_type::second, -2>>; +using SiAcceleration = schema::Unit<S, schema::UnitElement<si_type::meter, 1>, schema::UnitElement<si_type::second, -2>>; + +template<typename S> +using LbmAcceleration = schema::Unit<S, schema::UnitElement<lbm_type::meter, 1>, schema::UnitElement<lbm_type::second, -2>>; + +} } } |