wulfric.Kpoints.from_crystal#
method
- static Kpoints.from_crystal(cell, atoms, convention='HPKOT', with_time_reversal=True, n=100, spglib_data=None)[source]#
- Parameters:
- cell(3, 3) array-like
Matrix of a cell, rows are interpreted as vectors.
- atomsdict
Dictionary with N atoms. Expected keys:
"positions" : (N, 3) array-like
Positions of the atoms in the basis of lattice vectors (
cell). In other words - relative coordinates of atoms."names" : (N, ) list of str, optional
See Notes
"species" : (N, ) list of str, optional
See Notes
"spglib_types" : (N, ) list of int, optional
See Notes
Hint
Pass
atoms = dict(positions=[[0, 0, 0]], spglib_types=[1])if you would like to interpret thecellalone (effectively assuming that thecellis a primitive one).- conventionstr, default "HPKOT"
Convention for the definition of the conventional cell. Case-insensitive. Supported:
- with_time_reversalbool, default True
Whether to assume that the system has time reversal symmetry. By default assumes that the system has it. The strategy for extending the path when
with_time_reversal=Falsefor the crystals without inversion symmetry is described in [1]. For the systems with inversion symmetry this parameter does nothing.Added in version 0.6.3.
- nint, default 100
Number of intermediate points between each pair of the high-symmetry points (high-symmetry points excluded).
- spglib_data
SyntacticSugar, optional If you need more control on the parameters passed to the spglib, then you can get
spglib_datamanually and pass it to this function. Use wulfric's interface to spglib asspglib_data = wulfric.get_spglib_data(...)
using the same
cellandatoms["positions"]that you are passing to this function.
Notes
spglib uses
typesto distinguish the atoms. To see how wulfric deduces thetypesfor given atoms seewulfric.get_spglib_types().If two atoms
iandjhave the same spglib_type (i.e.atoms["spglib_types"][i] == atoms["spglib_types"][j]), but they have different property that is stored inatoms[key](i.eatoms[key][i] != atoms[key][j]), then those two atoms are considered equal. In the returnedconventional_atomsthe value of theconventional_atoms[key]are populated based on the last found atom inatomswith each for spglib_type. This rule do not apply to the "positions" key.References
[1] (1,2)Hinuma, Y., Pizzi, G., Kumagai, Y., Oba, F. and Tanaka, I., 2017. Band structure diagram paths based on crystallography. Computational Materials Science, 128, pp.140-184.
[2]Setyawan, W. and Curtarolo, S., 2010. High-throughput electronic band structure calculations: Challenges and tools. Computational materials science, 49(2), pp. 299-312.