[Pw_forum] Sign of magnetization
Ivo Souza
isouza at berkeley.edu
Mon Nov 12 20:59:13 CET 2007
Dear all,
I am trying to understand whether there is a sign error in the
definition of the total magnetization in pwscf. In other words, when the
code tells us that, e.g., the magnetic moment of bcc iron points along
+z, is it really pointing along minus z?
The spin magnetic moment of a state is (n units of the Bohr magneton)
<\mu_z> = -<sigma_z>
(note the minus sign) where sigma_z is the Pauli matrix.
From the subroutine 'compute_magnetization' in electrons.f90:
-------------------------------------------------------
IF ( lsda ) THEN
!
magtot = 0.D0
absmag = 0.D0
!
DO ir = 1, nrxx
!
mag = rho(ir,1) - rho(ir,2)
!
magtot = magtot + mag
absmag = absmag + ABS( mag )
!
END DO
!
magtot = magtot * omega / ( nr1*nr2*nr3 )
absmag = absmag * omega / ( nr1*nr2*nr3 )
-------------------------------------------------------
My understanding is that rho(ir,1) and rho(ir,2) are respectively the
(number) densities for spin-up ("moment-down") and spin-down
("moment-up") electrons. If so, then it seems to me that
mag = rho(ir,1) - rho(ir,2)
should be replaced by
mag = rho(ir,2) - rho(ir,1)
in order to get the correct sign for the magnetic moment per unit cell
'magtot'
The above is for collinear (lsda) calculations, but the same issue with
the sign is present in the definition of the total magnetization in the
non-collinear case:
-------------------------------------------------------
ELSE IF ( noncolin ) THEN
!
magtot_nc = 0.D0
absmag = 0.D0
!
DO ir = 1,nrxx
!
mag = SQRT( rho(ir,2)**2 + rho(ir,3)**2 + rho(ir,4)**2 )
!
DO i = 1, 3
!
magtot_nc(i) = magtot_nc(i) + rho(ir,i+1)
!
END DO
!
absmag = absmag + ABS( mag )
!
END DO
!
CALL mp_sum( magtot_nc, intra_pool_comm )
CALL mp_sum( absmag, intra_pool_comm )
!
DO i = 1, 3
!
magtot_nc(i) = magtot_nc(i) * omega / ( nr1*nr2*nr3 )
!
END DO
!
absmag = absmag * omega / ( nr1*nr2*nr3 )
!
ENDIF
-------------------------------------------------------
Since [see subroutine 'sum_band_k'] rho(ir,2), rho(ir,3) and rho(ir,4)
are respectively the x,y, and z components of the spin polarization
density, proportional to psi^*(r).sigma_i.psi(r) (i=x,y,z), the line
magtot_nc(i) = magtot_nc(i) + rho(ir,i+1)
should be replaced by
magtot_nc(i) = magtot_nc(i) - rho(ir,i+1)
It is quite easy to get confused with signs, so I apologize if the
confusion is on my side! Also, it could just be a matter of semantics,
and what is mean by "magnetic moment" in pwscf is really "spin
polarization." Any clarification would be greatly appreciated.
With thanks and best regards,
Ivo S.
More information about the users
mailing list