Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
811: Update to new SI definition and CODATA 2018 r=hgrecco a=Jellby The SI has been redefined, by giving exact values to the Planck, Boltzmann and Avogadro constants, and the elementary charge. There are also new recommended values for other constants (CODATA 2018). I've rewritten the `constants-en.txt` and `default-en.txt` according to these changes and also, I believe, for a better structure. The most significant changes: * All units and constants defined from a few "experimental" values. * For as much as I could find them, all factors are exact, except when noted. Floating point representation can introduce inaccuracies, though. * US and imperial units may have changed their "reference" (to what I considered is most reasonable or authoritative), in practice values stay the same within floating point errors. * Added some units and quantities. * Fixed some units like Nm or au and parsec. * Set the default Btu to the "ISO" Btu, and the default year to the Julian year (as recommended by the IAU) * Defined units of the Gaussian system consistently, which makes them have different dimensionality from the corresponding SI units. Added a Gaussian context to allow conversions (with some caveats). * Removed some units for which I could find no definition or reasonable use: chemical_faraday, physical_faraday, sidereal_hour, sidereal_minute, sidereal_second, work_year, work_month (they can of course be added back, hopefully with a better formal definition). * Added atomic and Planck systems. * Rearranged the order of units to "importance" (kind of) or field, rather than alphabetic. I'm happy to undo some of the changes if they are considered undesirable. Note if/when #809 is accepted, I'd like to apply some minor fixes here. Had to modify a couple of tests: * For some reason (floating point errors, I guess), 4 mM -> mole/liter is no longer equal to 4e-3 M, only "almost equal". * Updated the value of the Boltzmann constant in a test, a difference of 1.45e-5 % seems to be too much. Co-authored-by: Jellby <[email protected]>
- Loading branch information