-
Notifications
You must be signed in to change notification settings - Fork 24
Use Int64 / C
as default
#20
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
Comments
What about, for example, C = 2^8 * 3^6 * 5^4 * 7^2 * 11^2 * 13 * 15 # = 2385171360000 meaning you could represent any fraction which can be built by a combination of those powers. But you could not represent, say, 1/(15^2). But you could get awfully close. The |
I really think the default should probably be |
(Fixed by #21 but forgot to close this) |
[Diff since v0.4.0](v0.4.0...v0.5.0) **Closed issues:** - Use `Int64 / C` as default (#20) **Merged pull requests:** - Make `AbstractQuantity` and `AbstractDimensions` (#24) (@MilesCranmer)
cc @oscardssmith
I think it would probably be much faster to use
Int64 / C
, for some choice of constantC
, than to useRational{Int16}
as is currently done – as it would avoid repeatedgcd
calls.We would want to pick some constant
C
such that most rationals expressed byRational{Int16}
that people would typically want to use could also be expressed this way.The text was updated successfully, but these errors were encountered: