Crystal#

Class#

Crystal([lattice, atoms])

Crystal class.

Properties#

Hint

All properties and methods of Lattice are accessible directly from the crystal instance. Unless they are defined directly for the Crystal and listed here. The following interfaces are identical:

>>> import radtools as rad
>>> c = rad.Crystal()
>>> c.a
1.0
>>> c.lattice.a
1.0

Crystal.lattice

Lattice of the crystal.

Atom methods#

Crystal.add_atom(new_atom[, relative])

Add atom to the crystall.

Crystal.remove_atom(atom)

Remove atom from the crystal.

Positioning#

Crystal.get_atom_coordinates(atom[, R, relative])

Getter for the atom coordinates.

Crystal.get_distance(atom1, atom2[, R])

Getter for distance between the atom1 and atom2.

Crystal.get_vector(atom1, atom2[, R, relative])

Getter for vector between the atom1 and atom2.

Defining the type#

Crystal.identify([find_primitive])

Identify Bravais lattice type.

Crystal.find_primitive_cell()

Detect primitive cell.

Energy properties#

Crystal.mag_dipdip_energy(na, nb, nc[, ...])

Computes magnetic dipole-dipole energy.

Crystal.converge_mag_dipdip_energy([start, ...])

Converge magnetic dipole-dipole energy.