httk.atomistic.symmetry.standardization¶
Express an asymmetric-unit structure in its IT standard-setting cell.
The operation is exact after any optional recognition step. A setting-local ASU is mapped to the standard Wyckoff table only here, because this operation explicitly requests the standard conventional cell. An untabulated ASU instead uses its stored exact transform.
Classes¶
Store a structure in its space group's IT standard-setting conventional cell. |
Functions¶
|
Return |
Module Contents¶
- class httk.atomistic.symmetry.standardization.ConventionalCellResult[source]¶
Store a structure in its space group’s IT standard-setting conventional cell.
asuis the new standard-setting ASU that was expanded to makestructure.transformis the standard-to-own transform from the ASU that was supplied to, or recognized from, the operation; its orientation is \(f_own = f_std M^T + v\), so this operation undoes it for the cell basis.multiplieris the exact ratio of conventional-cell site count to input-cell site count. For the 527 vendored settings it is at least one; an untabulated, caller-supplied supercell transform may still produce a ratio below one.- Parameters:
structure – The resulting full conventional-cell structure.
asu – The resulting asymmetric-unit structure in the standard setting.
spacegroup – The space group represented by the result.
transform – The standard-to-own transform used for the input structure.
multiplier – The exact ratio of result site count to input site count.
- multiplier: fractions.Fraction[source]¶
- httk.atomistic.symmetry.standardization.conventional_cell(structure, *, tolerance=None, limit_denominator=None)[source]¶
Return
structurein its space group’s IT standard-setting conventional cell.An existing
ASUStructure(including anASUStructureView, an ASU backend, or a full-cell view backed by one) is used exactly as stored. Supplyingtoleranceorlimit_denominatorfor that path raisesValueError, because those arguments belong to recognition. Any otherStructureLikeis first passed torecognize_asu(). That tolerant step may snap measured coordinates onto symmetry positions and chooses the transform recorded in the result; it does not preserve an unstated input transform or promise asame_crystal()match to noisy input coordinates. The optional tolerance is a Cartesian matching distance and the optional denominator limit idealises free parameters.The returned
transformis the existing ASU’s transform, or the transform chosen by recognition for a plain input; the returnedasuhas an identity transform. Construction and expansion are exact, including the rhombohedral case where the standard hexagonal cell contains three primitive cells. Basis precision is multiplied byM.T()and coordinate precision by the maximum absolute column sum ofinv(M.T()); unknown precision remains unknown. Requires a fully 3D-periodic structure.- Parameters:
structure (httk.atomistic.models.structure.like.StructureLike | httk.atomistic.models.structure.asu.ASUStructure) – The structure or asymmetric-unit structure to standardize.
tolerance (float | None) – The Cartesian recognition tolerance, or
Noneto derive it.limit_denominator (int | None) – The maximum denominator for idealised free parameters, or
Noneto retain their exact stated values.
- Returns:
The standardized structure and transform metadata.
- Raises:
ImportError – If recognition is needed and the optional spglib dependency is unavailable.
ValueError – If recognition arguments are supplied for an existing ASU, the structure is not fully periodic, or unsupported site moments are present.
- Return type: