httk.atomistic.spacegroup

One identified space-group setting: its symbols, operations, and Wyckoff positions.

A Spacegroup is a setting, not a space-group type. SG 15 has eighteen tabulated settings, and they are genuinely different coordinate systems: Wyckoff letter e is 0,y,1/4 in the reference setting 15:b1 but 1/4,0,z in 15:c1. Everything a Spacegroup exposes — its symmetry operations, its Wyckoff table — is expressed in its own setting’s coordinates.

ASUStructure holds its Wyckoff data against the IT standard setting, obtained from Spacegroup.standard(), and reaches any other setting through a SettingTransform.

Classes

Spacegroup

A tabulated space-group setting, built from the vendored symmetry data.

Functions

wyckoff_letter_map(→ dict[str, str])

How Wyckoff letters of the standard setting name themselves in another setting.

Module Contents

class httk.atomistic.spacegroup.Spacegroup(record: dict[str, Any])[source]

A tabulated space-group setting, built from the vendored symmetry data.

classmethod standard(it_number: int) Self[source]

The IT standard (reference) setting for a space-group number.

classmethod for_hall_entry(hall_entry: str) Self[source]

The setting named by a normalized Hall symbol, e.g. "-c_2yc".

classmethod for_setting(setting_it_nc: str) Self[source]

The setting named by IT number and coordinate-system code, e.g. "15:c1".

classmethod for_hm_entry(hm_entry: str) Self[source]

The setting named by its Hermann-Mauguin entry, e.g. "C 1 2/c 1".

property record: dict[str, Any][source]

The raw vendored record, for fields this class does not model.

property it_number: int[source]

The International Tables space-group number, 1 to 230.

property setting: str[source]

The setting name — IT number plus coordinate-system code, e.g. "15:c1".

property hall_entry: str[source]

The normalized Hall symbol, which names the setting unambiguously.

property hall_symbol: str[source]

The Hall symbol as conventionally written.

property hermann_mauguin: str[source]

The short Hermann-Mauguin symbol for this setting.

property hermann_mauguin_full: str[source]

The full Hermann-Mauguin symbol for this setting.

property crystal_system: str[source]

The crystal system, e.g. "monoclinic".

property centring_type: str[source]

The lattice centring letter, e.g. "P", "C", "F".

property is_standard_setting: bool[source]

Whether this is the IT standard (reference) setting for its space-group number.

property symmetry_operations: tuple[httk.atomistic.affine_operation.AffineOperation, Ellipsis][source]

Every symmetry operation of the group, in this setting’s coordinates.

The full set with centring translations already folded in, so its length is the group order and no separate centring pass is needed.

property centering_translations: tuple[httk.core.FracVector, Ellipsis][source]

The lattice centring translations, including the zero translation.

property wyckoff: tuple[httk.atomistic.wyckoff.WyckoffPosition, Ellipsis][source]

The Wyckoff positions, ordered most specific first.

Sorted by (free_count, multiplicity, letter), so identifying a coordinate by walking this order returns the most specific position it lies on.

wyckoff_position(letter: str) httk.atomistic.wyckoff.WyckoffPosition[source]

The Wyckoff position with the given letter, e.g. "e".

identify_wyckoff(coordinate: Any) tuple[httk.atomistic.wyckoff.WyckoffPosition, httk.core.FracVector] | None[source]

The most specific Wyckoff position holding an exact coordinate, and its parameters.

Returns None when the coordinate lies on no position, which for a complete table means the input was not an exact rational site of this group. Matching is exact: an approximate coordinate must be snapped first (see ASUStructure’s recognition path), never passed here in the hope that it lands.

property transform_from_standard: httk.atomistic.setting_transform.SettingTransform[source]

The change of basis taking the IT standard setting’s coordinates into this one.

The identity exactly when this is the standard setting.

standard_setting() Spacegroup[source]

The IT standard setting for this space-group number.

httk.atomistic.spacegroup.wyckoff_letter_map(standard: Spacegroup, target: Spacegroup) dict[str, str][source]

How Wyckoff letters of the standard setting name themselves in another setting.

Almost always the identity — but not always, and the exception is silent. Across all 3210 non-reference (setting, letter) pairs in the vendored tables, exactly one setting permutes letters: in 224:1 the standard setting’s j is that setting’s i and vice versa. So a CIF that declares site 24i in setting 224:1 does not mean standard-setting letter i, and taking the letter at face value across a setting boundary produces the wrong structure with no error.

Computed rather than hard-coded, so it survives a data refresh: each standard position is evaluated at generic parameters, mapped through the setting transform, and identified in the target’s own Wyckoff table.