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 as coordinates. If None, then use "K1", ... "KN", where N = len(coordinates).

labelslist, optional

List of the high symmetry point's labels. Used for plotting. Has to have the same length as coordinates. If None, then use "K$_1$", ... "K$_N$", where N = len(coordinates).

pathstr, optional

K-path. Use elements of names to specify the path. If no names given, then use "K1", ... "KN", where N = 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.Kpoints from cell.

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

Labels of high symmetry points, ready to be plotted.

n

Amount of points between each pair of the high symmetry points (high symmetry points excluded).

path

K points path.

path_string

K points path as a string.