UnitsNet
UnitsNet copied to clipboard
Makes life working with units of measurement just a little bit better.
Fixes #1131
**Description** The very first call on Power.From takes up to several seconds. All the following calls are fine (regarding the performance). **Environment** - .net Core 3.1 - 32bit ARM Platform...
.NET 5 is out of active support. So I don't have it installed on my computer but I'm using .NET6 as it is an LTS version. Therefore, I would suggest...
Should/could the structs in this project be made `readonly`. I think they should. All primitive struct types from Microsoft are readonly. Readonly structs have a lot of advantages where there...
As per our discussion over at #875 here's the proof of concept, based on the explicit struct layout proposed by @AndreasLeeb and @pgrawehr (_could you please check my modification -...
According to wikipedia: https://en.wikipedia.org/wiki/Area_density > In the paper and fabric industries, it is called [grammage](https://en.wikipedia.org/wiki/Grammage) and is expressed in grams per square meter (g/m2) According to google/wikipedia it is also...
The documentation here is outdated. Some of the method parameters are deprecated: https://github.com/angularsen/UnitsNet/wiki/Extending-with-Custom-Units Also it is not really clear, if it makes more sense to implement IQuantity instead of IQuantity....
.NET 7 will introduce the [INumber<TSelf>](https://docs.microsoft.com/en-us/dotnet/api/system.numerics.inumber-1?view=net-7.0) interface (along with accompanying with C# 11 features) that make a feature called [generic math](https://devblogs.microsoft.com/dotnet/preview-features-in-net-6-generic-math/) possible. I think this would be a perfect fit...
**Describe the bug** The current implementation of e.g. `Length.Equals(Length other, Length tolerance)` can lead to false negatives at the boundaries of the tolerance (for instance when comparing `a` with `a...
Hey guys, I've mentioned this issue back in #838 where the current implementation of the [CompareTo](https://github.com/angularsen/UnitsNet/blob/1b3647fc1c32cbe737c07beca60ffa65c9c3d477/UnitsNet/GeneratedCode/Quantities/Mass.g.cs#L999) is prone to the same rounding issues as with the old equality contract. Here's...