__init__

class irreptables.__init__.Irrep(line, k_point)[source]

Parses the line containing the description of the irrep and stores the info in its attributes. Contains methods print descriptions of the irrep.

Parameters:
  • f (file object, default=None) – It corresponds to the file containing the info about the space-group and its irreps.

  • nsym_group (int, default=None) – Number of symmetry operations in the “point-group” of the space-group.

  • line (str, default=None) – Line with the description of an irrep, read from the file containing info about the space-group and irreps.

  • k_point (class instance, default=None) – Instance of class KPoint.

k

Direct coordinates of a k-point.

Type:

array, shape=(3,)

kpname

It is the label of a k-point.

Type:

str

name

Label of the irrep.

Type:

str

dim

Dimension of the irrep.

Type:

int

nsym

Number of symmetry operations in the little co-group of the k-point.

Type:

int

reality

True if traces of all symmetry operations are real, False otherwise.

Type:

bool

characters

Each key is the index of a symmetry operation in the little co-group and the corresponding value is the trace of that symmetry in the irrep.

Type:

dict

show()[source]

Print label of the k-point and info about the irrep.

str()[source]

Generate a line describing the irrep and its character.

Returns:

Line describing the irrep, as it is written in the table of the space-group included in IrRep. This line contains the label, dimension and character of the irrep.

Return type:

str

class irreptables.__init__.IrrepTable(SGnumber, spinor, name=None)[source]

Parse file corresponding to a space-group, storing the info in attributes. Also contains methods to print and write this info in a file.

Parameters:
  • SGnumber (int) – Number of the space-group.

  • spinor (bool) – True if the matrix describing the transformation of spinor components should be read.

  • name (str, default=None) – Name of the file from which info about the space-group and irreps should be read. If None, the code will try to open a file already included in it.

number

Number of the space-group.

Type:

int

name

Symbol of the space-group in Hermann-Mauguin notation.

Type:

str

spinor

True if wave-functions are spinors (SOC), False if they are scalars.

Type:

bool

nsym

Number of symmetry operations in the “point-group” of the space-group.

Type:

int

symmetries

Each component is an instance of class SymopTable corresponding to a symmetry operation in the “point-group” of the space-group.

Type:

list

NK

Number of maximal k-points in the Brillouin zone.

Type:

int

irreps

Each component is an instance of class IrRep corresponding to an irrep of the little group of a maximal k-point.

Type:

list

show()[source]

Print info about symmetry operations and irreps.

class irreptables.__init__.KPoint(name=None, k=None, isym=None, line=None)[source]

Organizes the info about a maximal k-point and contains routines to print it. This info is obtained by parsing the parameter line or passed directly as name, k and isym.

Parameters:
  • name (str, default=None) – Label of the k-point.

  • k (array, default=None) – Direct coordinates of the k-point.

  • isym (array, default=None) – Indices of symmetry operations in the little co-group. Indices make reference to the symmetry operations stored in the header of the file and stored in IrrepTable.symmetries.

  • line (str, default=None) – Line to be parsed.

name

Label of the k-point.

Type:

str

k

Direct coordinates of the k-point.

Type:

array, shape=(3,)

isym

Indices of symmetry operations in the little co-group. Indices make reference to the symmetry operations stored in the header of the file and stored in IrrepTable.symmetries.

Type:

array

show()[source]

Create a str containing the values of all attributes.

Returns:

Line showing the values of all attributes.

Return type:

str

str()[source]

Create a str containing the values of all attributes.

Returns:

Line that, when parsed, would lead to an instance of class KPoint with identical values of attributes.

Return type:

str

class irreptables.__init__.SymopTable(line)[source]

Parses a str that describes a symmetry operation of the space-group and stores info about it in attributes.

Parameters:

line (str) – Line to be parsed, which describes a symmetry operation.

R

Rotational part, describing the transformation of basis vectors (not cartesian coordinates!).

Type:

array, shape=(3,3)

t

Direct coordinates of the translation vector.

Type:

array, shape=(3,)

S

SU(2) matrix describing the transformation of spinor components.

Type:

array, shape=(2,2)

str(spinor=True)[source]

Create a str describing the symmetry operation as implemented in the files included in IrRep.

Parameters:

spinor (bool, default=True) – True if the matrix describing the transformation of spinor components should be written.

Return type:

str