Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Consider matching the API of other units software more closely #27

Open
1 of 5 tasks
matterhorn103 opened this issue May 17, 2024 · 0 comments
Open
1 of 5 tasks
Labels
consider Something to think about

Comments

@matterhorn103
Copy link
Owner

matterhorn103 commented May 17, 2024

Areas of the API to consider harmonizing more with other packages:

  • Uncertainties are added in pint with plus_minus(), while in quanstants we have plusminus() (which is an alias for with_uncertainty()) - renamed alias to plus_minus() to match
  • The equivalent of CompoundUnit in astropy is called CompositeUnit; maybe there is an example of the SI naming the product of unit multiplication?
  • Parsing of units - thinking here mainly of GNU units, but pint would be another option to consider
  • astropy has the DimensionlessUnit class, whereas quanstants has UnitlessUnit; they are different though, as a DimensionlessUnit can have a scaling factor and therefore is not necessarily equal to 1; quanstants.unitless is thus equivalent to astropy.units.unscaled_dimensionless
  • astropy considers radians and steradians as base units and angles as a dimension, with an option to consider them dimensionless
@matterhorn103 matterhorn103 added the consider Something to think about label May 17, 2024
@matterhorn103 matterhorn103 changed the title Consider matching parsing of other units software Consider matching the API of other units software more closely Jun 3, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
consider Something to think about
Projects
None yet
Development

No branches or pull requests

1 participant