httk.atomistic.models.formula.structure

Backend projecting a structure into its elemental composition.

Classes

StructureComposition

Project a structure only when composition data is accessed.

Module Contents

class httk.atomistic.models.formula.structure.StructureComposition(obj, **hints)[source]

Bases: httk.atomistic.models.formula.backend.ChemicalFormulaBackend

Project a structure only when composition data is accessed.

Parameters:
  • obj (Any) – The structure to adapt.

  • **hints (Any) – Backend-selection hints.

property amounts: tuple[tuple[str, fractions.Fraction], Ellipsis][source]

Return the projected elemental amounts.

property uncertainties: tuple[tuple[str, fractions.Fraction | None], Ellipsis][source]

Return the projected amount precisions.

property complete: bool[source]

Return whether all represented elemental material is known.

property exact: bool[source]

Return whether the projected amounts are exact.

property normalized: bool[source]

Return whether the projected composition is normalized.

property normalization_status: str[source]

Return the projected composition’s normalization status.

property diagnostics: tuple[httk.atomistic.models.formula.diagnostics.CompositionDiagnostic, Ellipsis][source]

Return diagnostics produced during projection.

unwrap()[source]

Return the original structure.