The space group generators are stored in the symmetry.dat
file, and spinw.lattice.sym
stores
all symmetry operators of the space group
All 230 standard spacegroups are supported.
204 I m -3 : x+1/2,y+1/2,z+1/2; -x,-y,z; -x,y,-z; z,x,y; -x,-y,-z
205 P a -3 : -x+1/2,-y,z+1/2; -x,y+1/2,-z+1/2; z,x,y; -x,-y,-z
206 I a -3 : x+1/2,y+1/2,z+1/2; -x+1/2,-y,z+1/2; -x,y+1/2,-z+1/2; z,x,y; -x,-y,-z
You can add your own symmetry to the symmetry.dat
file or supply it directly.
Form of symmetry string:
symStr = '-z, y+3/4, x+3/4; z+3/4, -y, x+3/4; z+3/4, y+3/4, -x; y+3/4, x+3/4, -z; x+3/4, -z, y+3/4; -z, x+3/4, y+3/4';
Applying the symmetry:
s.genlattice('lat_const', [3 3 3], 'angled', [90 90 90], 'spgr', symStr, 'label', 'F d -3 m Z')
We have three types of tensor variable: polar vector, axial vector, 2d tensors.
The respective transformation rules using orthogonal matrices are:
$$\begin{aligned} \nu^{'} & = R\nu \\ \nu^{'} & = \det(R)R\nu \\ T^{'} & = RTR^{T} \end{aligned}$$Where $\nu$ is a column vector.
To generate transformation matrices use:
Rotation:
R = sw_rotmat(rotAxis, rotAngle);
Mirroring:
[~, R] = sw_mirror(normalAxis);
Determine the symmetry allowed elements of the matrices with spinw.getmatrix
or spinw.setmatrix
.
Most common usage settings:
Text output of the possible matrix elements.
spinw.getmatrix('mat', 'J1');
Which for example gives the following output:
The symmetry analysis of the coupling between atom 1 and atom 2:
lattice translation vector: [0,0,0]
distance: 3.546 Angstrom
center of bond (in lattice units): [0.500,0.375,0.375]
label of the assigned matrix: 'J1'
allowed elements in the symmetric matrix:
S = | C| 0| 0|
| 0| A| B|
| 0| B| A|
allowed components of the Dzyaloshinskii-Moriya vector:
D = [ 0 , D1,-D1]
Matrix output of the possible modes, D: [3 3 nModes].
normModes = spinw.getmatrix('mat', 'J1');
Assigning pre-factors for the calculated modes and save them into the J1
matrix
A = 1; B = 2; C = 3;
spinw.setmatrix('mat', 'J1', 'pref', [A, B, C]);
sw_tutorial_05
We will demonstrate the symmetry analysis capabilities of SpinW in this script. We determine the allowed elements of the Dzyaloshinskii-Moriya vector on a bond that is perpendicular to a mirror plane. The result is well known and can be compared to the SpinW output. We use here explicitly the mirror plane as the only symmetry operator. Also we will draw the plane to demonstrate the plotting functions of SpinW.
model = spinw;
model.genlattice('lat_const',[6 4 4],'sym','-x,y,z','label','m_x')
model.addatom('r',[3/8 1/2 1/2],'S',1)
plot(model)
model.gencoupling
model.addmatrix('label','DM1','value',1);
model.addcoupling('mat','DM1','bond',1)
plot(model)
model.getmatrix('mat','DM1');
Look at the result of getmatrix
. How many DM vectors are allowed for this bond in this
symmetry?
Add two DM vector that span the allowed plane.
model.addmatrix('label','DM1','value',[0 1 0],'color','blue')
model.addmatrix('label','DM2','value',[0 0 1],'color','purple')
model.addcoupling('mat','DM1','bond',1)
model.addcoupling('mat','DM2','bond',1)
plot(model,'bondScale',1)
The second example show the case when the mirror plane includes the bond.
model = spinw;
model.genlattice('lat_const',[4 6 4],'sym','-x,y,z','label','m_x')
model.addatom('r',[1/2 3/8 1/2],'S',1)
model.addatom('r',[1/2 5/8 1/2],'S',1)
model.quickham(1)
plot(model)
model.getmatrix('mat','J1');
cryst=spinw;
cryst.genlattice('sym','P 4','lat_const',[8 8 6])
cryst.addatom('r',[1/4 1/4 0],'S',1);
cryst.gencoupling;
cryst.addmatrix('label','D','value',[1 -1 0])
cryst.addcoupling('mat','D','bond',2)
plot(cryst,'range',[1 1 1/2])
cryst=spinw;
cryst.genlattice('lat_const',[8 8 6])
cryst.addatom('r',[1/4 1/4 0],'S',1);
cryst.addatom('r',[3/4 1/4 0],'S',1);
cryst.addatom('r',[1/4 3/4 0],'S',1);
cryst.addatom('r',[3/4 3/4 0],'S',1);
cryst.gencoupling
cryst.addmatrix('label','D','value',[1 -1 0])
cryst.addcoupling('mat','D','bond',1,'subIdx',[3 5 7:8])
plot(cryst,'range',[1 1 1/2],'atomLegend',false)
cryst=spinw;
cryst.genlattice('sym','P 4','lat_const',[8 8 6])
cryst.addatom('r',[1/4 1/4 0],'S',1)
cryst.gencoupling
cryst.addmatrix('label','A','value',1-eye(3))
cryst.addaniso('A')
plot(cryst)
cryst=spinw;
cryst.genlattice('lat_const',[8 8 6])
cryst.addatom('r',[1/4 1/4 0],'S',1)
cryst.addatom('r',[3/4 1/4 0],'S',1)
cryst.addatom('r',[1/4 3/4 0],'S',1)
cryst.addatom('r',[3/4 3/4 0],'S',1)
cryst.gencoupling
cryst.addmatrix('label','A','value',1-eye(3))
cryst.addaniso('A')
plot(cryst,'atomLegend',false)
This system is a bit complex, follow the steps in the tutorial and try to understand the plotting options.
We will not try to reproduce the spin wave dispersion presented in the paper, but you can attempt it after the
magnetic structure tutorials.