Magnetism and Magnetic Materials
Getting ready
make pw pp
("make all" is also ok).
tar -zxvf examples_magn.tgz
cd examples_magn
A non-magnetic case first: Si
As a first test, one should verify the effect ot the spin polarization in a case that is known to be non-magnetic, and to verify that a non-magnetic ground-state is effectively found. Let us consider as a simple case: fcc Si, and see three possible magnetic structure: non-magnetic, ferromagnetic, antiferromagnetic. In all cases we will perform "spin-unconstrained" LSDA calculation, that is, we leave the system free to choose the preferred occupancies.
$espresso_dir/bin/pw.x < si_nm.scf.in > si.scf.out
$espresso_dir/bin/pw.x < si_nm.nscf.in > si.nscf.out
$espresso_dir/bin/dos.x < si.dos.in > si.dos.out
$espresso_dir/bin/projwfc.x < si.pdos.in > si.pdos.out
Inspect the input, verify that "pseudo_dir" and "outdir"point
respectively to the directory containing the pseudopotential and
to the scratch directory. Inspect the output: you should get the
usual results, with data written to or read from directory
"outdir"/"prefix".save.
&system
nspin = 2
occupations='smearing', smearing='gauss', degauss=0.02,
starting_magnetization(1) = 0.4
nbnd = 8,
... /
$espresso_dir/bin/pw.x < si_fm.scf.in > si.scf.out
Inspect the output: you will notice several things. First of all,
the number of k-points has doubled with respect to the previous
case. The first half contains states with up spin, the second half
states with down spin. The code prints the total and absolute
magnetizations, ans you will notice that both are nonzero at the
beginning and then the vanish during self-consistency. At the
end, we get the same results as for the non-magnetic case.
$ gnuplot
plot 'si.dos' using 1:2 with lines, 'si.dos' using 1:(-$3) with lines
The resulting plot will be quite the same as for the nomagnetic case,
apart from a 1/2 factor.
&system
ntyp = 2
starting_magnetization(1) = 0.4
starting_magnetization(2) =-0.7
ATOMIC_SPECIES
Si1 1. Si.pbe-rrkj.UPF
Si2 1. Si.pbe-rrkj.UPF
ATOMIC_POSITIONS crystal
Si1 0.00 0.00 0.00
Si2 0.25 0.25 0.25
Now we have two different types of atoms, Si1 and Si2, described by the same
pseudopotential. The code will think that they are different because labels
are different and will not recognize symmetry operations that send Si1 into
Si2 or vice versa. Again, you can run the self-consistency and see how a
nonzero absolute (but not total) magnetization is present in the first stages
of self-consistency, just to disappear at the end.
A ferromagnetic case: BCC iron
Iron (Fe, from Latin ferrum) is a prototypical "ferro"magnet. Iron crystallizes into the body-centered cubic structure. It is a metal, thus it requires a rather accurate sampling of the Brillouin Zone. The "Fe_lsda/" subdirectory contains:
$ gnuplot
plot 'fe.dos' using 1:2 with lines, 'fe.dos' using 1:(-$3) with lines
compare the DOS fon non-magnetic iron:
$ gnuplot
plot 'fe.dos' using 1:2 with lines
The presence of more spin-up than spin-down occupied states is evident
(remember that only states at E < EF are occupied, and
that EF is printed in the output; the small difference between
EF calculated in the scf and non-scf cases is hardly relevant).
For a deeper analysis of the origin of the difference between spin-up and spin-down DOSes, have a look at the output files from "projwfc.x". This codes prints out a number of information and of files. In particular: files '"prefix".pdos_atm#N(X)_wfc#M(L)' contain the DOS projected on atomic orbital X, having angular momentum L, for atom number N, of type X. The following command:
$ gnuplot
plot './fe.pdos_atm#1(Fe)_wfc#2(d)' u 1:2 w l lt 1, \
'./fe.pdos_atm#1(Fe)_wfc#2(d)' u 1:(-$3) w l lt 3, \
'./fe.pdos_atm#1(Fe)_wfc#1(s)' u 1:2 w l lt 2, \
'./fe.pdos_atm#1(Fe)_wfc#1(s)' u 1:(-$3) w l lt 4 \
will clearly show that the l=2 (d) orbitals of Fe are strongly
spin-polarized.The AFM input differs from the two others not only for the starting magnetization, but also for the presence of two iron sublattices. This is straightforward in a BCC lattice, which can be represented as a Simple Cubic (SC) lattice with two sublattices, one at the origin and one in the middle of the cube. You will however notice that iron ends up falling again into the FM state. Notice that the energy of the SC lattice with two sublattices is twice as big as the energy of the BCC lattice, within numerical differences due to the slightly different k-point sampling in the two cases. If however you make a more symmetric choice of starting_magnetization, you may end up into an AFM state, characterized by vanishing total magnetization and large absolute magnetization. The AFM state is however definitely higher in energy than the FM state (remember to account for the differnt cell size! you have to compare EAFM with 2 EFM).
An anti-ferromagnetic case: NiO
NiO is a simple oxide with a rocksalt structure, i.e. comnposed of two fcc lattices. NiO is actually a well-known case of failure of simple DFT approximations (failing to predict its insulator character). Still, the AFM character is correctly predicted. The data reported here, in subdirectory "NiO_lsda/", are for simplicity all referred to the same (4-atom rhombohedral) cell, i.e. the one of the observed magnetic structure, in which <111> planes have alternating magnetization along the diagonal. With different values of "starting_magnetization", one finds AFM, FM, NM states, with EAFM < EFM < ENM. An inspection of the DOS and the PDOS shows that the two Ni sublattices have opposite spin-up and spni-down DOS, while O atoms are non-magnetic.