pyspinw.site#
Representation of sites (e.g. magnetic atoms) within a magnetic system
Classes
|
Lattice site that is implied by symmetry by a specified site |
|
A spin site within a lattice |
- class pyspinw.site.ImpliedLatticeSite(parent_site: Site, i: float, j: float, k: float, sx: float | None = None, sy: float | None = None, sz: float | None = None, supercell_spins: ndarray | None = None, name: str | None = None, g: ArrayLike | None = None, metadata: SiteMetadata | None = None, color: tuple[float, float, float] | None = None, radius: float | None = None, element: str | None = None)#
Bases:
SiteLattice site that is implied by symmetry by a specified site
- static from_coordinates(parent_site: Site, coordinates: ndarray, name: str = '')#
Create ImpliedLatticeSite from coordinates
- property parent_site#
Get the parent of this site
- class pyspinw.site.Site(i: float, j: float, k: float, sx: float | None = None, sy: float | None = None, sz: float | None = None, supercell_spins: ArrayLike | None = None, g: ArrayLike | None = None, name: str = '', metadata: SiteMetadata | None = None, color: tuple[float, float, float] | None = None, radius: float | None = None, element: str | None = None)#
Bases:
SPWSerialisableA spin site within a lattice
- Parameters:
i,j,k – required Fractional coordinates within unit cell
sz (sx, sy,) – Spin components in the Cartesian directions defined by x||a, z perpendicular to a-b
supercell_spins –
Spin for each propagation vector
g –
g-tensor (3x3)
name
metadata – Object containing metadata for this site (can be inferred from the name)
color – Colour to use for rendering (can be inferred from the name, overrides other metadata)
radius – Atomic radius to use for rendering (can be inferred from the name, overrides other metadata)
element – String containing the atomic symbol (can be inferred from the name, overrides other metadata)
- property base_spin#
spins as numpy array
- static from_coordinates(coordinates: ndarray, name: str = '')#
Create from an array of values
- property g: ndarray#
Magnetic g-factor, a 3x3 matrix/tensor
- property i#
Fractional position along first unit cell axis
- property ijk#
ijk values as a numpy array
- property j#
Fractional position along second unit cell axis
- property k#
Fractional position along third unit cell axis
- n_components()#
Number of spin components for this site
- property name#
Name given to this site
- property parent_site#
Get the parent site (just itself for non-implied sites)
- serialisation_name = 'site'#
- property spin: ndarray#
Get the base spin
- property spin_data#
Get all the spin data
- symmetry_transformed(operation: SpaceOperation, unit_cell: UnitCell)#
Transform site using a symmetry operation
- property unique_id#
Unique ID for this site
- property values#
ijk and spins as a numpy 6-vector