Closed Peter-Knoppers closed 1 year ago
The constants E
, PHI
and PI
have been added as Dimensionless
constants to the Constants
class, and as FloatDimensionless
constants to the FloatConstants
class. Additionally, the FloatConstants
class now contains FloatSIScalar
, FloatDimensionless
, FloatMass
, etc, where the previous version defined double constants (which was clearly wrong).
The unit tests have also been adapted to test the float values in FloatConstants
up to 1 ulp precision for the expected value.
All unit tests for Constants
and FloatConstants
pass, so this issue can be closed.
The file value/vdouble/scalar/base/Constants.java defines a number of physical and mathematical constants. Sorely missing are: pi (but we do have tau) e (Euler's constant) Slighly less important (because it is quite easy to "construct"): phi (The golden ratio; (1+sqrt(5)/2)