Skip to content

fix reduced formula in Ion #2864

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

Merged
merged 2 commits into from
Feb 28, 2023
Merged

Conversation

yang-ruoxi
Copy link
Member

Fixed the handling of O-H containing compositions, where the string 'HO' was replaced by 'OH' directly in the reduced formula. This will cause certain materials, e.g. HSbO2, to have the wrong reduced formula of SbOH2.

This fix then adds a condition that the composition must have an equal number of H and O to be handled that way.

yang-ruoxi and others added 2 commits February 27, 2023 16:19
Fixed the handling of O-H containing compositions, where the string 'HO' was replaced by 'OH' directly in the formula. This will cause some materials, e.g. HSbO2, to have the wrong reduced formula of SbOH2.
@janosh janosh merged commit 0b16987 into materialsproject:master Feb 28, 2023
@mkhorton
Copy link
Member

mkhorton commented Mar 2, 2023

Thanks for catching this!

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 this pull request may close these issues.

3 participants