Note
Go to the end to download the full example code.
RHL1#
Rhombohedral cell is defined by two parameters \(a\) and \(\alpha\).
RHL lattice has variation RHL1 when \(\alpha < 90^{\circ}\).
Cell constructor#
To get an example of the cell use wulfric.cell.SC_RHL().
wulfric.cell.sc_get_example() returns an example where
\(a = \pi\) and \(\alpha = 70^{\circ}\).
import wulfric
cell = wulfric.cell.sc_get_example("RHL1")
atoms = dict(positions=[[0, 0, 0]], spglib_types=[1])
# To avoid multiple calls to spglib one can do it once and then pass spglib_data
# to the functions where it is needed
spglib_data = wulfric.get_spglib_data(cell=cell, atoms=atoms)
kp = wulfric.Kpoints.from_crystal(cell=cell, atoms=atoms, convention="SC")
conv_cell, conv_atoms = wulfric.crystal.get_conventional(
cell=cell, atoms=atoms, convention="SC", spglib_data=spglib_data
)
prim_cell, prim_atoms = wulfric.crystal.get_primitive(
cell=cell, atoms=atoms, convention="SC", spglib_data=spglib_data
)
variation = wulfric.crystal.sc_get_variation(
cell=cell, atoms=atoms, spglib_data=spglib_data
)
assert variation == "RHL1"
print(variation)
RHL1
K-path#
print(kp.path_string)
GAMMA-L-B1|B-Z-GAMMA-X|Q-F-P1-Z|L-P
High-symmetry points#
print(kp.hs_table(decimals=4))
Name rel_b1 rel_b2 rel_b3 k_x k_y k_z
GAMMA 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000
B 0.7031 0.5000 0.2969 1.4687 -0.3541 -0.0214
B1 0.5000 0.2969 -0.2969 0.9728 -0.3541 -1.1005
F 0.5000 0.5000 -0.0000 1.2208 0.0000 -0.5609
L 0.5000 -0.0000 -0.0000 0.6104 -0.8717 -0.2805
L1 -0.0000 -0.0000 -0.5000 -0.0000 -0.0000 -1.1005
P 0.7031 0.3985 0.3985 1.3447 -0.5311 0.2591
P1 0.6015 0.6015 0.2969 1.4687 0.0000 -0.0214
P2 0.3985 0.3985 -0.2969 0.9728 0.0000 -1.1005
Q 0.6015 0.3985 -0.0000 1.2208 -0.3541 -0.5609
X 0.3985 -0.0000 -0.3985 0.4864 -0.6947 -1.1005
Z 0.5000 0.5000 0.5000 1.2208 0.0000 0.5396
Brillouin zone and default k-path#
pe = wulfric.PlotlyEngine(_sphinx_gallery_fix=True)
pe.plot_brillouin_zone(
cell=prim_cell, color="red", legend_label="Brillouin zone of the primitive cell"
)
pe.plot_brillouin_zone(
cell=cell, color="chocolate", legend_label="Brillouin zone of the original cell"
)
pe.plot_kpath(kp=kp)
pe.plot_kpoints(kp=kp, only_from_kpath=True)
pe.show(axes_visible=False)
Cells of real space#
pe = wulfric.PlotlyEngine(_sphinx_gallery_fix=True)
pe.plot_cell(cell=cell, legend_label="Original cell", color="Chocolate")
pe.plot_cell(cell=prim_cell, legend_label="Primitive cell", color="Black")
pe.plot_cell(cell=conv_cell, legend_label="Conventional cell", color="Blue")
pe.plot_wigner_seitz_cell(
cell=prim_cell, legend_label="Wigner-Seitz cell", color="green"
)
pe.show(axes_visible=False)
Edge cases#
In rhombohedral lattice \(a = b = c\) and \(\alpha = \beta = \gamma\), thus three edge cases exist:
If \(\alpha = 60^{\circ}\), then the lattice is FCC.
If \(\alpha \approx 109.47122063^{\circ}\) (\(\cos(\alpha) = -1/3\)), then the lattice is BCC.
If \(\alpha = 90^{\circ}\), then the lattice is CUB.
Total running time of the script: (0 minutes 1.605 seconds)