Spin¶
-
class
sisl.physics.Spin(kind='', dtype=<type 'numpy.float64'>)[source]¶ Spin class to determine configurations and spin components.
The basic class
Spinimplements a generic method to determine a spin configuration.Its usage can be summarized in these few examples:
>>> Spin(Spin.UNPOLARIZED) == Spin('unpolarized') == Spin() True >>> Spin(Spin.POLARIZED) == Spin('polarized') == Spin('p') True >>> Spin(Spin.NONCOLINEAR, dtype=np.complex128) == Spin('non-colinear') == Spin('nc') True >>> Spin(Spin.SPINORBIT, dtype=np.complex128) == Spin('spin-orbit') == Spin('so') True
Note that a data-type may be associated with a spin-object. This is not to say that the data-type is used in the configuration, but merely that it helps any sub-classed or classes who use the spin-object to determine the usage of the different spin-components.
Attributes
NONCOLINEARPOLARIZEDSPINORBITUNPOLARIZEDdkindData-type kind dtypeData-type of the spin configuration is_colinearTrue if the configuration is polarized is_noncolinearTrue if the configuration non-colinear is_polarizedTrue if the configuration is polarized is_spinorbitTrue if the configuration is spin-orbit is_unpolarizedTrue if the configuration is not polarized kindA unique ID for the kind of spin configuration spinsNumber of spin-components Methods
__init__([kind, dtype])copy()-
NONCOLINEAR= 2¶
-
POLARIZED= 1¶
-
SPINORBIT= 3¶
-
UNPOLARIZED= 0¶
-
dkind¶ Data-type kind
-
dtype¶ Data-type of the spin configuration
-
is_colinear¶ True if the configuration is polarized
-
is_noncolinear¶ True if the configuration non-colinear
-
is_polarized¶ True if the configuration is polarized
-
is_spinorbit¶ True if the configuration is spin-orbit
-
is_unpolarized¶ True if the configuration is not polarized
-
kind¶ A unique ID for the kind of spin configuration
-
spins¶ Number of spin-components
-