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

Implement ratio strong typing #34

Open
anders-wind opened this issue Dec 20, 2022 · 1 comment
Open

Implement ratio strong typing #34

anders-wind opened this issue Dec 20, 2022 · 1 comment

Comments

@anders-wind
Copy link
Collaborator

In https://www.youtube.com/watch?v=5dhFtSu3wCo Chip Hogg describes that in their strong type library they have built in support for scales and ratios. Furthermore, just like chrono defines different ratios (seconds, milliseconds, days etc. ) as different types with conversions, we wish to implement a system to make this behavior easy to implement

@anders-wind
Copy link
Collaborator Author

Also their approach to the typelist is a bit more elegant. Essentially, instead of repeating the same units multiple times they have <unit, power> to represent: unit^power. This makes a number of operations more efficient (just subtract instead of having to remove each one of them).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant