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

Extract dimensionless quantities? #70

Open
andrevidela opened this issue Sep 28, 2023 · 1 comment · May be fixed by #71
Open

Extract dimensionless quantities? #70

andrevidela opened this issue Sep 28, 2023 · 1 comment · May be fixed by #71

Comments

@andrevidela
Copy link

I've got some code that performs a division that removes all dimensions

a :: Mass SI n
b :: Mass SI n
c :: Qu '[] SI n
c = a |/| b

I need to extract this n for further processing by another library. Would it make sense to add

extract :: Qu '[] l n -> n
extract = coerce

?

@goldfirere
Copy link
Owner

Looks reasonable to me. Please do submit a PR! Thanks.

@andrevidela andrevidela linked a pull request Oct 7, 2023 that will close this issue
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

Successfully merging a pull request may close this issue.

2 participants