You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Is your feature request related to a problem? Please describe.
Converting L/h to SI results in "No units were found for the given UnitSystem"
Describe the solution you'd like
I'd love to see the values as m³/s in the SI case.
The use-case is a .NET tool that collects data from various sources in various units (including some weird ones like hL/min, which causes another problem for the moment) and outputs them on a single channel in SI unit by convention.
This channel is used by multiple tools written in multiple languages, hence the SI convention.
Currently we have to remove the Unit from the value and apply a custom scale factor that we have to set it manually (=little more error prone)
this means: output = input * 4.41631375E-05
instead of output = VolumeFlow.FromOilBarrelsPerHour(input).As(UnitSystem.SI)
The text was updated successfully, but these errors were encountered:
Thanks for describing the usecase. The UnitSystem concept is still quite new and we have not yet mapped all the units that should be the result of converting a quantity to SI base units. We are also debating a redesign of the system, since it can't easily be used to represent other systems than SI - such as CGS, FPS, British Engineering units and so on.
There are some discussions in #651 and #630 on a possible redesign.
However, I believe your scenario can be implemented by adding BaseUnits to the cubic meters per second unit in VolumeFlow.json, such that .As(UnitSystem.SI) will convert to that unit. Remember to run generate-code.bat after changing .json files.
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.
Is your feature request related to a problem? Please describe.
Converting L/h to SI results in "No units were found for the given UnitSystem"
Describe the solution you'd like
I'd love to see the values as m³/s in the SI case.
The use-case is a .NET tool that collects data from various sources in various units (including some weird ones like hL/min, which causes another problem for the moment) and outputs them on a single channel in SI unit by convention.
This channel is used by multiple tools written in multiple languages, hence the SI convention.
Currently we have to remove the Unit from the value and apply a custom scale factor that we have to set it manually (=little more error prone)
this means:
output = input * 4.41631375E-05
instead of
output = VolumeFlow.FromOilBarrelsPerHour(input).As(UnitSystem.SI)
The text was updated successfully, but these errors were encountered: