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

\per\molar is not inverting the units correctly #577

Open
biditism opened this issue Jan 24, 2022 · 3 comments
Open

\per\molar is not inverting the units correctly #577

biditism opened this issue Jan 24, 2022 · 3 comments
Assignees
Labels
enhancement New feature or request

Comments

@biditism
Copy link

\molar gives the unit correctly as mol dm-3 but using \per\molar only inverts the mole and not the cubic decimeter i.e. the output is mol-1 dm-3 where actually it should be mol-1 dm3.

@josephwright
Copy link
Owner

You don't say how you define \molar, but assuming \DeclareSIUnit\molar{\mole\per\cubic\deci\metre}, your output is exactly as expected. Units don't 'group': \molar is simply replaced by \mole\per\cubic\deci\metre, they the \per you've added applies only to the \mole.

@biditism
Copy link
Author

Thank you. I thought \molar was a pre-defined unit as I had not defined it myself. I now realize that it is defined by chemmacros. Is it possible to define the units so that they are grouped?

@josephwright
Copy link
Owner

At present no, I can log it as a feature request, but I'm worried it might be confusing overall.

@josephwright josephwright added the enhancement New feature or request label Jan 24, 2022
@josephwright josephwright self-assigned this Jan 24, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants