Generic conversion utility between different units.
All different codes unit conversion routines should adhere to the same routine names for consistency and readability. This package should supply a subpackage for each code where specific unit conversions are required. I.e. if the codes unit conversion are not the same as the sisl defaults.
The group of units that unit belong to
Factor that takes fr to the units of to
The default unit of the unit group group.
Object for converting between units for a set of unit-tables.
All subsequent subpackages also exposes the above 4 methods. If a subpackage method is used, the unit conversion corresponds to the units defined in the respective code.
units object is by far the easiest version to use since it handles
complex units (Ry/kg/Bohr N) while
unit_convert is the basic unit-conversion
table that only converts simple units. E.g. Ry to eV etc.
This subpackage implements the unit conversions used in Siesta.
To use the unit conversion from Siesta, simply import
>>> from sisl.unit import units >>> from sisl.unit.siesta import units as siesta_units
in which case
units will refer to default unit conversions and
will use the unit definitions in Siesta up to and including 4.1.X versions.