wulfric.Kpoints#
- class wulfric.Kpoints(rcell, coordinates=None, names=None, labels=None, path=None, n=100)[source]#
Interface for convenient manipulation with the high symmetry kpoints and K-path in reciprocal space.
- Parameters:
- rcell(3, 3) array-like
Reciprocal cell. Rows are interpreted as vectors.
- coordinateslist, optional
Coordinates of high symmetry points given in relative coordinates in reciprocal space.
- names: list, optional
Names of the high symmetry points. Used in
path. Has to have the same length ascoordinates. IfNone, then use "K1", ... "KN", whereN = len(coordinates).- labelslist, optional
List of the high symmetry point's labels. Used for plotting. Has to have the same length as
coordinates. IfNone, then use "K$_1$", ... "K$_N$", whereN = len(coordinates).- pathstr, optional
K-path. Use elements of
namesto specify the path. If no names given, then use "K1", ... "KN", whereN = len(coordinates).- nint
Number of intermediate points between each pair of the high symmetry points (high symmetry points excluded).
- Attributes:
- rcell(3, 3) numpy.ndarray
Reciprocal cell. Rows are interpreted as vectors.
- hs_nameslist
Names of the high symmetry points. Used for programming, not for plotting.
- hs_coordinatesdict
Dictionary of the high symmetry points coordinates.
{"name": [k_a, k_b, k_c], ... }
- hs_labelsdict
Dictionary of the high symmetry points labels for plotting.
{"name": "label", ... }
Methods:
add_hs_point(name, coordinate, label[, relative])Adds high symmetry point.
copy()Creates a copy of the kpoints.
flatten_points([relative])Flatten coordinates of all points with n points between each pair of the high symmetry points (high symmetry points excluded).
from_cell(cell[, lattice_type, ...])Creates an instance of the
wulf.Kpointsfromcell.hs_table([decimals])Table of the high symmetry points.
points([relative])Coordinates of all points with n points between each pair of the high symmetry points (high symmetry points excluded).
remove_hs_point(name)Removes high symmetry point.
ticks([relative])Tick's positions of the high symmetry points, ready to be plotted.
Properties:
Labels of high symmetry points, ready to be plotted.
Amount of points between each pair of the high symmetry points (high symmetry points excluded).
K points path.
K points path as a string.