Skip to content

More powerful/flexible "parse_formula" #11

@skirklin

Description

@skirklin

RIght now parse_formula just uses regex to run through a string looking for things that look like elements (maybe) followed by a number. I would be good if it could do more though. Things that it would be good if it could do:

Li4(Fe2O3)2 -> {'Li':4, 'Fe':4: 'O':6}
3Gd2O3 + 4Li2O -> {'Li':8, 'Gd':6, 'O':13}

Maybe?
2Li5FeO4 - Fe2O3 -> {'Li':10, 'O':5}

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions