hFigure = swplot.plotbond(Name,Value)
swplot.plotbond(Name,Value) plots the magnetic bonds stored in
spinw.coupling. It can plot bonds using different styles, such as
arrows, lines or cylinders and allows controlling the the line style,
cylinder radius, color, etc. The command can also plot cylinders with
radii that are dependent on the strength of the exchange interaction
assigned to the particular bond.
Name-Value Pair Arguments
- String that defines the style of the bond:
'cylinder'bonds are plotted as cylinders connecting the two atoms (default),
'arrow'bonds are plotted as arrows (default if DM interactions are present),
'line'bonds are plotted as lines,
'empty'no bonds are plotted.
- String that defines what object is plotted on the middle of the bond:
'none'don’t plot anything on the bond (default),
'antisym'plot the antisymmetric part (DM vector) of the exchange on the middle point of the bond (default if DM vectors are non-zero),
'sym'plot an ellipsoid (corresponding to the symmetric exchange) on the middle of the bond.
- String that defines how the ellipsoids are generated for exchange
matrices that contain both negative and positive eigenvalues.
Possible values are:
'abs'The absolute value of the eigenvalues is used, this works nicely except that AFM and FM values will have the same radius (default).
'min'If there is a negative eigenvalue, it is shifted to zero with all other egeinvalues equally. This works nicely to emphasize AFM type values in the exchange matrix. Problem is that 0 exchange values can be assigned non-zero radius.
'min', except the positive eigenvalues are shifted to zero. This works nicely to emphasize FM type exchange values, has the same problem as the
- Defines the bond radius if
modeis set to
line, one of the folling strings:
'fix'All lines will have a width defined by the
'lin'Lines will have a width that is depending linearly on the exchange matrix on the bond:
~Width ~ sum(abs(J)), where the largest line width on the strongest bond is given by
'auto', but the line width is a power function of the exchange value:
- Defines the power that determines the linewidth if
linewidthparameter is set to
- Line width in pt used to draw the bond if
'line'. Default value is 0.5.
- Determines the line style when
'line'. Possible values are:
'auto'Bonds are plotted as continuous/dashed lines depending on the label of the corresponding matrix (dashed line is used if the matrix label ends with
'-', otherwise continuous) (default).
'--'Bonds are plotted as dashed lines.
'-'Bonds are plotted as lines.
':'Bonds are plotted using dotted lines.
'-.'Bonds are plotted using dash-dotted lines.
true, bonds with zero exchange matrix will be plotted as well. Default value is
- Radius of the cylinder when
modeparameter is set to
'cylinder'. Default value is 0.05 Å.
- Radius of the DM vector and the minimum radius of the ellipsoid, default value is 0.08 Å.
- Constant atom radius, default value is 0.3 Å.
- Defines the atom radius (important for arrow bonds, to avoid
overlap with the spheres of the atoms), see swplot.plotatom:
'fix'Sets the radius of all atoms to the value given by the
'auto'use radius data from database based on the atom label multiplied by the
- Angle of the arrow head in degree units, default value is 30°.
- Length of the arrow head, default value is 0.3 Å.
- Scaling factor for the length of the DM vector or the size of the ellipsoid relative to the shortest bond length. Default value is 1/3.
- Color of the bonds, one of the following values:
'auto'all bonds gets the color stored in spinw.matrix,
'colorname'all bonds will have the same color defined by the string, e.g.
[R G B]all bonds will have the same color defined by the given RGB code.
- Color of the ellipse or DM vector on the bond:
'auto'all object get the color of the bond,
'colorname'all object will have the same color defined by the string, e.g.
[R G B]all objects will have the same color defined by the given RGB code.
These parameters have the same effect on any of the
- spinw object.
- Unit in which the plotting range is defined. It can be one of the
'lu'plot range is defined in lattice units (default),
'xyz'plot range is defined in the Cartesian coordinate system in Å units.
- Defines the plotting range. Depending on the
unitparameter, the given range can be in lattice units or in units of the Cartesian coordinate system. It is either a matrix with dimensions of where the first and second columns define the lower and upper plot limits respectively. It can be alternatively a vector with three elements
[a,b,c]which is equivalent to
[0 a;0 b;0 c]. Default value is
[0 1;0 1;0 1]to show a single cell.
- Handle of the swplot figure. Default value is the active figure handle.
- Whether to show the plot on the legend, default value is
true, the tooltips will be shown when clicking on the plot objects. Default value is
- Column vector with 3 elements, all object positions will be
shifted by the given value in Å units. Default value is
truethe plot will replace the previous plot of the same type. Default value is
true, the plot will be centered, independent of the range. Default value is
true, the swplot figure will be zoomed to make the plot objects cover the full figure. Default is
true, a clone of the spinw object will be saved in the swplot figure data which can be retwrived using
false, the handle of the original spinw object is saved which is linked to the input
objand so it changes when
objis changed. Default value is
- Mesh of the ellipse surface, a triangulation class object or an
integer that used to generate an icosahedron mesh with
number of additional subdivision into triangles. Default value is
swpref.getpref('nmesh'), see also swplot.icomesh.
- Number of vertices on any patch object that is not the icosahedron,
default value is stored in
- Handle of the swplot figure.
The name of the objects that are created are
To find the handles and the corresponding data on these objects, use e.g.
sObject = swplot.findobj(hFigure,’name’,’bond’)`.