Closed ecolner closed 7 years ago
Thanks for pointing that out. While https://github.com/unitsofmeasurement/uom-systems/issues/82 elaborates, that currently LITER_DM3.equals(LITER)
won't work because the underlying definitions are simply not identical, the mathematic equivalence must be true. Somehow thought DECI(CUBIC_METER)
would get it, but that was a misconception. DECI(Units.METRE).pow(3).asType(Volume.class)
is the shorter form and works.
Works now, thanks a lot. I will add a JUnit test based on above assertion, then I'd close this ticket as it is resolved in the master build. An upcoming service release will contain the fix, the 0.7.2-SNAPSHOT already does. In fact, if the conversion-chain between the two units is now the same, https://github.com/unitsofmeasurement/uom-systems/issues/82 could even be solved by this, too.
The calculation is d(m^3) but we think it should be (dm)^3 because this test fails
In
UCUM.java
the LITER_DM3 constant is defined asbut it should look something like this