get_formula_inequiv_components

emmet.core.featurization.robocrys.condense.component.get_formula_inequiv_components(components, use_iupac_formula=True, use_common_formulas=True)

Gets and counts the inequivalent components based on their formuula.

Note that the counting of compounds is different to in get_sym_inequiv_equivalent. I.e. the count is not the number of components with the same formula. For example, the count of the formula “GaAs” in a system with two Ga2As2 components would be 4.

Return type:

list[dict[str, Any]]

Parameters:
  • components (list[dict[str, Any]])

  • use_iupac_formula (bool)

  • use_common_formulas (bool)

Args:
components: A list of structure components, generated using

pymatgen.analysis.dimensionality.get_structure_components, with inc_site_ids=True.

use_iupac_formula (bool, optional): Whether to order formulas by the

iupac “electronegativity” series, defined in Table VI of “Nomenclature of Inorganic Chemistry (IUPAC Recommendations 2005)”. This ordering effectively follows the groups and rows of the periodic table, except the Lanthanides, Actanides and hydrogen. If set to False, the elements will be ordered according to the electronegativity values.

use_common_formulas: Whether to use the database of common formulas.

The common formula will be used preferentially to the iupac or reduced formula.

Returns:

A list of the compositionally inequivalent components. Any duplicate components will only be returned once. The component objects are in the same format is given by pymatgen.analysis.dimensionality.get_structure_components but have two additional fields:

  • "count" (int): The number of formula units of this component. Note, this is not the number of components with the same formula. For example, the count of the formula “GaAs” in a system with two Ga2As2 components would be 4.

  • "formula" (list[int]): The reduced formula of the component.