class to store and solve magnetic Hamiltonians

Syntax

obj = spinw

obj = spinw(obj)

obj = spinw(source)

obj = spinw(figure_handle)

Description

obj = spinw constructs an empty spinw class object.

obj = spinw(obj) constructs a spinw class object from the parameters defined in obj. If obj is spinw class, it only checks the integrity of its internal data structure. If obj is struct type, it creates new spinw object and checks data integrity.

obj = spinw(source) construct new spinw class object, where source is either a file path pointing to a local cif or fst file or a link to an online file.

obj = spinw(figure_handle) copy the spinw object stored in a previous structural 3D plot figure, referenced by figure_handle.

The data structure within the spinw object can be accessed by using spinw.struct method. All fields of the struct type data behind the spinw object are accessible through the main field names of the obj object. For example the lattice parameters can be accessed using:

abc = obj.unit_cell.lat_const

spinw is a handle class, which means that only the handle of the object is copied in an assinment command swobj1 = swobj2. To create a copy (clone) of an spinw object use:

swobj1 = swobj2.copy

Properties

The data within the spinw object is organized into a tree structure with the main groups and the type of data they store are the following:

Methods

Methods are the different commands that require a spinw object as a first input, thus they can be called as method1(obj,...), alternatively the equivalent command is obj.method1(...). The list of public methods is below.

Lattice operations

Plotting

Crystallographic twin operations

Magnetic structure operations

Matrix operations

Spin Hamiltonian generations

Solvers

Fitting spin wave spectrum

Miscellaneous

See also

spinw.copy, spinw.struct, Comparing handle and value classes