Commit b8a01d1c authored by Daniel Wortmann's avatar Daniel Wortmann

Merge branch 'develop' into stable

parents 01507889 78e5828a
...@@ -6,7 +6,6 @@ Testing/* ...@@ -6,7 +6,6 @@ Testing/*
build build
build.* build.*
*.o *.o
*.mod
*.x *.x
*.swp *.swp
tags tags
...@@ -5,6 +5,7 @@ stages: ...@@ -5,6 +5,7 @@ stages:
- deploy - deploy
- build-pgi - build-pgi
- test-pgi - test-pgi
- build-intel-static
- build-intel - build-intel
- test-intel - test-intel
...@@ -92,8 +93,30 @@ pages: ...@@ -92,8 +93,30 @@ pages:
# - web # - web
# - triggers # - triggers
build-intel-static:
image: iffregistry.fz-juelich.de/fleur/fleur:intel-static
stage: build-intel-static
cache:
paths:
- build.intel-static
script:
- set +e && source compilervars.sh intel64 && set -e ; ulimit -s unlimited
- cd /builds/fleur/fleur; ./configure.sh -l intel-static INTEL_DOCKER_STATIC ; cd build.intel-static; make -j 4
artifacts:
when: on_success
paths:
- build.intel-static/fleur
- build.intel-static/fleur_MPI
- build.intel-static/inpgen
only:
- schedules
- triggers
- web
build-intel: build-intel:
image: iffregistry.fz-juelich.de/docker-images/centos7-intel-compilers/extended image: iffregistry.fz-juelich.de/fleur/fleur:intel-static
stage: build-intel stage: build-intel
cache: cache:
paths: paths:
...@@ -108,7 +131,7 @@ build-intel: ...@@ -108,7 +131,7 @@ build-intel:
test-intel: test-intel:
image: iffregistry.fz-juelich.de/docker-images/centos7-intel-compilers/extended image: iffregistry.fz-juelich.de/fleur/fleur:intel-static
stage: test-intel stage: test-intel
cache: cache:
paths: paths:
......
...@@ -4,7 +4,78 @@ MODULE m_cdntot ...@@ -4,7 +4,78 @@ MODULE m_cdntot
! vacuum, and mt regions c.l.fu ! vacuum, and mt regions c.l.fu
! ******************************************************** ! ********************************************************
CONTAINS CONTAINS
SUBROUTINE cdntot(mpi,stars,atoms,sym,vacuum,input,cell,oneD,& SUBROUTINE cdntot_integrate(stars,atoms,sym,vacuum,input,cell,oneD, integrand, &
q, qis, qmt, qvac, qtot, qistot)
USE m_intgr, ONLY : intgr3
USE m_constants
USE m_qsf
USE m_pwint
USE m_types
USE m_juDFT
USE m_convol
IMPLICIT NONE
TYPE(t_stars),INTENT(IN) :: stars
TYPE(t_atoms),INTENT(IN) :: atoms
TYPE(t_sym),INTENT(IN) :: sym
TYPE(t_vacuum),INTENT(IN) :: vacuum
TYPE(t_input),INTENT(IN) :: input
TYPE(t_cell),INTENT(IN) :: cell
TYPE(t_oneD),INTENT(IN) :: oneD
TYPE(t_potden),INTENT(IN) :: integrand
REAL, INTENT(out) :: q(input%jspins), qis(input%jspins), qmt(atoms%ntype,input%jspins),&
qvac(2,input%jspins), qtot, qistot
INTEGER :: jsp, j, ivac, nz, n
REAL :: q2(vacuum%nmz), w, rht1(vacuum%nmzd,2,input%jspins)
COMPLEX :: x(stars%ng3)
CALL timestart("cdntot")
qtot = 0.0
qistot = 0.0
DO jsp = 1,input%jspins
q(jsp) = 0.0
! -----mt charge
CALL timestart("MT")
DO n = 1,atoms%ntype
CALL intgr3(integrand%mt(:,0,n,jsp),atoms%rmsh(:,n),atoms%dx(n),atoms%jri(n),w)
qmt(n, jsp) = w*sfp_const
q(jsp) = q(jsp) + atoms%neq(n)*qmt(n,jsp)
ENDDO
CALL timestop("MT")
! -----vacuum region
IF (input%film) THEN
DO ivac = 1,vacuum%nvac
DO nz = 1,vacuum%nmz
IF (oneD%odi%d1) THEN
rht1(nz,ivac,jsp) = (cell%z1+(nz-1)*vacuum%delz)*&
integrand%vacz(nz,ivac,jsp)
ELSE
rht1(nz,ivac,jsp) = integrand%vacz(nz,ivac,jsp)
END IF
END DO
CALL qsf(vacuum%delz,rht1(1,ivac,jsp),q2,vacuum%nmz,0)
qvac(ivac,jsp) = q2(1)*cell%area
IF (.NOT.oneD%odi%d1) THEN
q(jsp) = q(jsp) + qvac(ivac,jsp)*2./real(vacuum%nvac)
ELSE
q(jsp) = q(jsp) + cell%area*q2(1)
END IF
ENDDO
END IF
! -----is region
qis(jsp) = 0.
CALL pwint_all(stars,atoms,sym,oneD,cell,1,stars%ng3,x)
DO j = 1,stars%ng3
qis(jsp) = qis(jsp) + integrand%pw(j,jsp)*x(j)*stars%nstr(j)
ENDDO
qistot = qistot + qis(jsp)
q(jsp) = q(jsp) + qis(jsp)
qtot = qtot + q(jsp)
END DO ! loop over spins
END SUBROUTINE cdntot_integrate
SUBROUTINE cdntot(stars,atoms,sym,vacuum,input,cell,oneD,&
den,l_printData,qtot,qistot) den,l_printData,qtot,qistot)
USE m_intgr, ONLY : intgr3 USE m_intgr, ONLY : intgr3
...@@ -18,7 +89,6 @@ CONTAINS ...@@ -18,7 +89,6 @@ CONTAINS
IMPLICIT NONE IMPLICIT NONE
! .. Scalar Arguments .. ! .. Scalar Arguments ..
TYPE(t_mpi),INTENT(IN) :: mpi
TYPE(t_stars),INTENT(IN) :: stars TYPE(t_stars),INTENT(IN) :: stars
TYPE(t_atoms),INTENT(IN) :: atoms TYPE(t_atoms),INTENT(IN) :: atoms
TYPE(t_sym),INTENT(IN) :: sym TYPE(t_sym),INTENT(IN) :: sym
...@@ -32,84 +102,36 @@ CONTAINS ...@@ -32,84 +102,36 @@ CONTAINS
! .. Local Scalars .. ! .. Local Scalars ..
COMPLEX x(stars%ng3) COMPLEX x(stars%ng3)
REAL q,qis,w,mtCharge REAL q(input%jspins),qis(input%jspins),w,mtCharge
INTEGER i,ivac,j,jspin,n,nz INTEGER i,ivac,j,jsp,n,nz
! .. ! ..
! .. Local Arrays .. ! .. Local Arrays ..
REAL qmt(atoms%ntype),qvac(2),q2(vacuum%nmz),rht1(vacuum%nmzd,2,input%jspins) REAL qmt(atoms%ntype,input%jspins),qvac(2,input%jspins)
INTEGER, ALLOCATABLE :: lengths(:,:) INTEGER, ALLOCATABLE :: lengths(:,:)
CHARACTER(LEN=20) :: attributes(6), names(6) CHARACTER(LEN=20) :: attributes(6), names(6)
! ..
! .. Intrinsic Functions .. call cdntot_integrate(stars,atoms,sym,vacuum,input,cell,oneD, den, &
INTRINSIC real q, qis, qmt, qvac, qtot, qistot)
! ..
!
IF (input%film) THEN IF (input%film) THEN
ALLOCATE(lengths(4+vacuum%nvac,2)) ALLOCATE(lengths(4+vacuum%nvac,2))
ELSE ELSE
ALLOCATE(lengths(4,2)) ALLOCATE(lengths(4,2))
END IF END IF
CALL timestart("cdntot")
qtot = 0.e0
qistot = 0.e0
DO jspin = 1,input%jspins
q = 0.e0
! -----mt charge
CALL timestart("MT")
DO n = 1,atoms%ntype
CALL intgr3(den%mt(:,0,n,jspin),atoms%rmsh(:,n),atoms%dx(n),atoms%jri(n),w)
qmt(n) = w*sfp_const
q = q + atoms%neq(n)*qmt(n)
ENDDO
CALL timestop("MT")
! -----vacuum region
IF (input%film) THEN
DO ivac = 1,vacuum%nvac
DO nz = 1,vacuum%nmz
IF (oneD%odi%d1) THEN
rht1(nz,ivac,jspin) = (cell%z1+(nz-1)*vacuum%delz)*&
den%vacz(nz,ivac,jspin)
ELSE
rht1(nz,ivac,jspin) = den%vacz(nz,ivac,jspin)
END IF
END DO
CALL qsf(vacuum%delz,rht1(1,ivac,jspin),q2,vacuum%nmz,0)
qvac(ivac) = q2(1)*cell%area
IF (.NOT.oneD%odi%d1) THEN
q = q + qvac(ivac)*2./real(vacuum%nvac)
ELSE
q = q + cell%area*q2(1)
END IF
ENDDO
END IF
! -----is region
IF (.FALSE.) THEN !Change this for old way of determination of int-charge
CALL convol(stars,x,den%pw(:,jspin),stars%ufft)
qis = x(1)*cell%omtil
ELSE
qis = 0.
CALL pwint_all(stars,atoms,sym,oneD,cell,1,stars%ng3,x) DO jsp = 1,input%jspins
DO j = 1,stars%ng3 WRITE (6,FMT=8000) jsp,q(jsp),qis(jsp), (qmt(n,jsp),n=1,atoms%ntype)
qis = qis + den%pw(j,jspin)*x(j)*stars%nstr(j) IF (input%film) WRITE (6,FMT=8010) (i,qvac(i,jsp),i=1,vacuum%nvac)
ENDDO mtCharge = SUM(qmt(1:atoms%ntype,jsp) * atoms%neq(1:atoms%ntype))
endif names(1) = 'spin' ; WRITE(attributes(1),'(i0)') jsp ; lengths(1,1)=4 ; lengths(1,2)=1
qistot = qistot + qis names(2) = 'total' ; WRITE(attributes(2),'(f14.7)') q(jsp) ; lengths(2,1)=5 ; lengths(2,2)=14
q = q + qis names(3) = 'interstitial' ; WRITE(attributes(3),'(f14.7)') qis(jsp) ; lengths(3,1)=12 ; lengths(3,2)=14
WRITE (6,FMT=8000) jspin,q,qis, (qmt(n),n=1,atoms%ntype)
IF (input%film) WRITE (6,FMT=8010) (i,qvac(i),i=1,vacuum%nvac)
WRITE (16,FMT=8000) jspin,q,qis, (qmt(n),n=1,atoms%ntype)
IF (input%film) WRITE (16,FMT=8010) (i,qvac(i),i=1,vacuum%nvac)
mtCharge = SUM(qmt(1:atoms%ntype) * atoms%neq(1:atoms%ntype))
names(1) = 'spin' ; WRITE(attributes(1),'(i0)') jspin ; lengths(1,1)=4 ; lengths(1,2)=1
names(2) = 'total' ; WRITE(attributes(2),'(f14.7)') q ; lengths(2,1)=5 ; lengths(2,2)=14
names(3) = 'interstitial' ; WRITE(attributes(3),'(f14.7)') qis ; lengths(3,1)=12 ; lengths(3,2)=14
names(4) = 'mtSpheres' ; WRITE(attributes(4),'(f14.7)') mtCharge ; lengths(4,1)=9 ; lengths(4,2)=14 names(4) = 'mtSpheres' ; WRITE(attributes(4),'(f14.7)') mtCharge ; lengths(4,1)=9 ; lengths(4,2)=14
IF(l_printData) THEN IF(l_printData) THEN
IF(input%film) THEN IF(input%film) THEN
DO i = 1, vacuum%nvac DO i = 1, vacuum%nvac
WRITE(names(4+i),'(a6,i0)') 'vacuum', i WRITE(names(4+i),'(a6,i0)') 'vacuum', i
WRITE(attributes(4+i),'(f14.7)') qvac(i) WRITE(attributes(4+i),'(f14.7)') qvac(i,jsp)
lengths(4+i,1)=7 lengths(4+i,1)=7
lengths(4+i,2)=14 lengths(4+i,2)=14
END DO END DO
...@@ -119,11 +141,8 @@ CONTAINS ...@@ -119,11 +141,8 @@ CONTAINS
CALL writeXMLElementFormPoly('spinDependentCharge',names(1:4),attributes(1:4),lengths) CALL writeXMLElementFormPoly('spinDependentCharge',names(1:4),attributes(1:4),lengths)
END IF END IF
END IF END IF
qtot = qtot + q
END DO ! loop over spins END DO ! loop over spins
DEALLOCATE (lengths)
WRITE (6,FMT=8020) qtot WRITE (6,FMT=8020) qtot
WRITE (16,FMT=8020) qtot
IF(l_printData) THEN IF(l_printData) THEN
CALL writeXMLElementFormPoly('totalCharge',(/'value'/),(/qtot/),reshape((/5,20/),(/1,2/))) CALL writeXMLElementFormPoly('totalCharge',(/'value'/),(/qtot/),reshape((/5,20/),(/1,2/)))
END IF END IF
......
...@@ -154,7 +154,6 @@ SUBROUTINE cdnval(eig_id, mpi,kpts,jspin,noco,input,banddos,cell,atoms,enpara,st ...@@ -154,7 +154,6 @@ SUBROUTINE cdnval(eig_id, mpi,kpts,jspin,noco,input,banddos,cell,atoms,enpara,st
IF (mpi%irank==0) THEN IF (mpi%irank==0) THEN
WRITE (6,FMT=8000) jspin WRITE (6,FMT=8000) jspin
WRITE (16,FMT=8000) jspin
CALL openXMLElementPoly('mtCharges',(/'spin'/),(/jspin/)) CALL openXMLElementPoly('mtCharges',(/'spin'/),(/jspin/))
END IF END IF
8000 FORMAT (/,/,10x,'valence density: spin=',i2) 8000 FORMAT (/,/,10x,'valence density: spin=',i2)
......
...@@ -57,11 +57,9 @@ CONTAINS ...@@ -57,11 +57,9 @@ CONTAINS
my = 2*AIMAG(qa21(itype)) my = 2*AIMAG(qa21(itype))
mz = chmom(itype,1) - chmom(itype,2) mz = chmom(itype,1) - chmom(itype,2)
WRITE (6,8025) mx,my WRITE (6,8025) mx,my
WRITE (16,8025) mx,my
!---> determine the polar angles of the moment vector in the local frame !---> determine the polar angles of the moment vector in the local frame
CALL pol_angle(mx,my,mz,betah,alphh) CALL pol_angle(mx,my,mz,betah,alphh)
WRITE (6,8026) betah,alphh WRITE (6,8026) betah,alphh
WRITE (16,8026) betah,alphh
8025 FORMAT(2x,'--> local frame: ','mx=',f9.5,' my=',f9.5) 8025 FORMAT(2x,'--> local frame: ','mx=',f9.5,' my=',f9.5)
8026 FORMAT(2x,'-->',10x,' delta beta=',f9.5,& 8026 FORMAT(2x,'-->',10x,' delta beta=',f9.5,&
& ' delta alpha=',f9.5) & ' delta alpha=',f9.5)
...@@ -79,9 +77,7 @@ CONTAINS ...@@ -79,9 +77,7 @@ CONTAINS
mz = rho11 - rho22 mz = rho11 - rho22
CALL pol_angle(mx,my,mz,betah,alphh) CALL pol_angle(mx,my,mz,betah,alphh)
WRITE (6,8027) noco%beta(itype),noco%alph(itype)-alphdiff WRITE (6,8027) noco%beta(itype),noco%alph(itype)-alphdiff
WRITE (16,8027) noco%beta(itype),noco%alph(itype)-alphdiff
WRITE (6,8028) betah,alphh-alphdiff WRITE (6,8028) betah,alphh-alphdiff
WRITE (16,8028) betah,alphh-alphdiff
8027 FORMAT(2x,'-->',10x,' input noco%beta=',f9.5, ' input noco%alpha=',f9.5) 8027 FORMAT(2x,'-->',10x,' input noco%beta=',f9.5, ' input noco%alpha=',f9.5)
8028 FORMAT(2x,'-->',10x,'output noco%beta=',f9.5, ' output noco%alpha=',f9.5) 8028 FORMAT(2x,'-->',10x,'output noco%beta=',f9.5, ' output noco%alpha=',f9.5)
...@@ -96,7 +92,6 @@ CONTAINS ...@@ -96,7 +92,6 @@ CONTAINS
my_mix = 2*AIMAG(rho21) my_mix = 2*AIMAG(rho21)
mz_mix = rho11 - rho22 mz_mix = rho11 - rho22
WRITE (6,8031) mx_mix,my_mix WRITE (6,8031) mx_mix,my_mix
WRITE (16,8031) mx_mix,my_mix
8031 FORMAT(2x,'--> global frame: ','mixed mx=',f9.5,' mixed my=',f9.5) 8031 FORMAT(2x,'--> global frame: ','mixed mx=',f9.5,' mixed my=',f9.5)
! if magnetic moment (in local frame!) is negative, direction of quantization ! if magnetic moment (in local frame!) is negative, direction of quantization
! has to be antiparallel! ! has to be antiparallel!
...@@ -109,7 +104,6 @@ CONTAINS ...@@ -109,7 +104,6 @@ CONTAINS
! calculate angles alpha and beta in global frame ! calculate angles alpha and beta in global frame
CALL pol_angle(mx_mix,my_mix,mz_mix,betah,alphh) CALL pol_angle(mx_mix,my_mix,mz_mix,betah,alphh)
WRITE (6,8029) betah,alphh-alphdiff WRITE (6,8029) betah,alphh-alphdiff
WRITE (16,8029) betah,alphh-alphdiff
8029 FORMAT(2x,'-->',10x,' new noco%beta =',f9.5, ' new noco%alpha =',f9.5) 8029 FORMAT(2x,'-->',10x,' new noco%beta =',f9.5, ' new noco%alpha =',f9.5)
noco%alph(itype) = alphh noco%alph(itype) = alphh
noco%beta(itype) = betah noco%beta(itype) = betah
...@@ -129,9 +123,7 @@ CONTAINS ...@@ -129,9 +123,7 @@ CONTAINS
b_con_outy = scale*my b_con_outy = scale*my
!---> mix input and output constraint fields !---> mix input and output constraint fields
WRITE (6,8100) noco%b_con(1,itype),noco%b_con(2,itype) WRITE (6,8100) noco%b_con(1,itype),noco%b_con(2,itype)
WRITE (16,8100) noco%b_con(1,itype),noco%b_con(2,itype)
WRITE (6,8200) b_con_outx,b_con_outy WRITE (6,8200) b_con_outx,b_con_outy
WRITE (16,8200) b_con_outx,b_con_outy
noco%b_con(1,itype) = noco%b_con(1,itype) + noco%mix_b*b_con_outx noco%b_con(1,itype) = noco%b_con(1,itype) + noco%mix_b*b_con_outx
noco%b_con(2,itype) = noco%b_con(2,itype) + noco%mix_b*b_con_outy noco%b_con(2,itype) = noco%b_con(2,itype) + noco%mix_b*b_con_outy
ENDIF ENDIF
......
...@@ -677,7 +677,6 @@ CONTAINS ...@@ -677,7 +677,6 @@ CONTAINS
ENDDO ENDDO
ENDIF ENDIF
WRITE ( 6,'(''bad quality of charge density'',2f13.8)')q0, REAL( cwk(1) ) WRITE ( 6,'(''bad quality of charge density'',2f13.8)')q0, REAL( cwk(1) )
WRITE (16,'(''bad quality of charge density'',2f13.8)')q0, REAL( cwk(1) )
CALL juDFT_warn('pwden: bad quality of charge') CALL juDFT_warn('pwden: bad quality of charge')
ENDIF ENDIF
ENDIF ENDIF
......
...@@ -15,6 +15,7 @@ c This subroutine rotates the direction of the magnetization of the ...@@ -15,6 +15,7 @@ c This subroutine rotates the direction of the magnetization of the
c density matrix by multiplying with the unitary 2x2 spin rotation c density matrix by multiplying with the unitary 2x2 spin rotation
c matrix. --> U*rho*U^dagger c matrix. --> U*rho*U^dagger
c Philipp Kurz 2000-02-03 c Philipp Kurz 2000-02-03
c new method for improved stability (l_new=t) gb'19
c*********************************************************************** c***********************************************************************
use m_constants use m_constants
...@@ -28,11 +29,29 @@ C .. Scalar Arguments .. ...@@ -28,11 +29,29 @@ C .. Scalar Arguments ..
C .. C ..
C .. Local Scalars .. C .. Local Scalars ..
INTEGER ispin INTEGER ispin
REAL eps REAL eps,r11n,r22n
COMPLEX r21n
LOGICAL l_new
C .. C ..
C .. Local Arrays .. C .. Local Arrays ..
COMPLEX u2(2,2),rho(2,2),rhoh(2,2) COMPLEX u2(2,2),rho(2,2),rhoh(2,2)
C .. C ..
l_new = .true.
IF (l_new) THEN
r11n = 0.5*(1.0+cos(beta))*rho11 - sin(beta)*real(rho21) +
+ 0.5*(1.0-cos(beta))*rho22
r22n = 0.5*(1.0-cos(beta))*rho11 + sin(beta)*real(rho21) +
+ 0.5*(1.0+cos(beta))*rho22
r21n = CMPLX(cos(alph),-sin(alph))*(sin(beta)*(rho11-rho22) +
+ 2.0*(cos(beta)*real(rho21)-cmplx(0.0,aimag(rho21))))*0.5
rho11 = r11n
rho22 = r22n
rho21 = r21n
ELSE
eps = 1.0e-10 eps = 1.0e-10
...@@ -66,21 +85,21 @@ c---> check wether the diagonal elements of the rotated density ...@@ -66,21 +85,21 @@ c---> check wether the diagonal elements of the rotated density
c---> are real. c---> are real.
DO ispin = 1,2 DO ispin = 1,2
IF (aimag(rho(ispin,ispin)).GT.eps) THEN IF (aimag(rho(ispin,ispin)).GT.eps) THEN
WRITE(16,8000)
WRITE( 6,8000)
CALL juDFT_error("rotation of mag. failed",calledby CALL juDFT_error("rotation of mag. failed",calledby
+ ="rot_den_mat") + ="rot_den_mat",hint=
+ 'After the rotation of the density matrix in the '//
+ 'muffin-tin sphere one diagonal element of the '//
+ '(hermitian) density matrix is not real. That means '//
+ 'that the density matrix was probably damaged.')
ENDIF ENDIF
ENDDO ENDDO
8000 FORMAT('After the rotation of the density matrix in the'/
+ 'muffin-tin sphere one diagonal element of the'/
+ '(hermitian) density matrix is not real. That means'/
+ 'that the density matrix was probably damaged.')
rho11 = real(rho(1,1)) rho11 = real(rho(1,1))
rho22 = real(rho(2,2)) rho22 = real(rho(2,2))
rho21 = rho(2,1) rho21 = rho(2,1)
ENDIF
END SUBROUTINE rot_den_mat END SUBROUTINE rot_den_mat
END MODULE m_rotdenmat END MODULE m_rotdenmat
...@@ -164,8 +164,7 @@ CONTAINS ...@@ -164,8 +164,7 @@ CONTAINS
eps=0.01 eps=0.01
ic = CMPLX(0.,1.) ic = CMPLX(0.,1.)
! ------------------ ! ------------------
! WRITE (16,'(a,i2)') 'nstars=',nstars
! -----> set up mapping arrays ! -----> set up mapping arrays
IF (noco%l_ss) THEN IF (noco%l_ss) THEN
jsp_start = 1 jsp_start = 1
......
...@@ -12,6 +12,7 @@ SUBROUTINE cdncore(mpi,dimension,oneD,input,vacuum,noco,sym,& ...@@ -12,6 +12,7 @@ SUBROUTINE cdncore(mpi,dimension,oneD,input,vacuum,noco,sym,&
stars,cell,sphhar,atoms,vTot,outDen,moments,results) stars,cell,sphhar,atoms,vTot,outDen,moments,results)
USE m_constants USE m_constants
USE m_judft
USE m_cdn_io USE m_cdn_io
USE m_cdnovlp USE m_cdnovlp
USE m_cored USE m_cored
......
...@@ -225,14 +225,12 @@ CONTAINS ...@@ -225,14 +225,12 @@ CONTAINS
!$OMP END PARALLEL !$OMP END PARALLEL
WRITE (6,FMT=8000) WRITE (6,FMT=8000)
WRITE (16,FMT=8000)
8000 FORMAT (/,5x,'l-like charge',/,t6,'atom',t15,'s',t24,'p',& 8000 FORMAT (/,5x,'l-like charge',/,t6,'atom',t15,'s',t24,'p',&
& t33,'d',t42,'f',t51,'total') & t33,'d',t42,'f',t51,'total')
DO itype = 1,atoms%ntype DO itype = 1,atoms%ntype
DO ispin = jsp_start,jsp_end DO ispin = jsp_start,jsp_end
WRITE ( 6,FMT=8100) itype, (qmtl(l,ispin,itype),l=0,3),moments%chmom(itype,ispin) WRITE ( 6,FMT=8100) itype, (qmtl(l,ispin,itype),l=0,3),moments%chmom(itype,ispin)
WRITE (16,FMT=8100) itype, (qmtl(l,ispin,itype),l=0,3),moments%chmom(itype,ispin)
8100 FORMAT (' -->',i3,2x,4f9.5,2x,f9.5) 8100 FORMAT (' -->',i3,2x,4f9.5,2x,f9.5)
attributes = '' attributes = ''
WRITE(attributes(1),'(i0)') itype WRITE(attributes(1),'(i0)') itype
......
...@@ -28,13 +28,11 @@ SUBROUTINE magMoms(dimension,input,atoms,noco,vTot,moments) ...@@ -28,13 +28,11 @@ SUBROUTINE magMoms(dimension,input,atoms,noco,vTot,moments)
CHARACTER(LEN=20) :: attributes(4) CHARACTER(LEN=20) :: attributes(4)
WRITE (6,FMT=8000) WRITE (6,FMT=8000)
WRITE (16,FMT=8000)
DO iType = 1,atoms%ntype DO iType = 1,atoms%ntype
sval = moments%svdn(iType,1) - moments%svdn(iType,input%jspins) sval = moments%svdn(iType,1) - moments%svdn(iType,input%jspins)
stot = moments%stdn(iType,1) - moments%stdn(iType,input%jspins) stot = moments%stdn(iType,1) - moments%stdn(iType,input%jspins)
scor = stot - sval scor = stot - sval
WRITE (6,FMT=8010) iType,stot,sval,scor,moments%svdn(iType,1),moments%stdn(iType,1) WRITE (6,FMT=8010) iType,stot,sval,scor,moments%svdn(iType,1),moments%stdn(iType,1)
WRITE (16,FMT=8010) iType,stot,sval,scor,moments%svdn(iType,1),moments%stdn(iType,1)
END DO END DO
8000 FORMAT (/,/,10x,'spin density at the nucleus:',/,10x,'type',t25,& 8000 FORMAT (/,/,10x,'spin density at the nucleus:',/,10x,'type',t25,&
...@@ -43,14 +41,12 @@ SUBROUTINE magMoms(dimension,input,atoms,noco,vTot,moments) ...@@ -43,14 +41,12 @@ SUBROUTINE magMoms(dimension,input,atoms,noco,vTot,moments)
8010 FORMAT (i13,2x,3e20.8,5x,2e20.8) 8010 FORMAT (i13,2x,3e20.8,5x,2e20.8)
WRITE (6,FMT=8020) WRITE (6,FMT=8020)
WRITE (16,FMT=8020)
CALL openXMLElement('magneticMomentsInMTSpheres',(/'units'/),(/'muBohr'/)) CALL openXMLElement('magneticMomentsInMTSpheres',(/'units'/),(/'muBohr'/))
iRepAtom = 1 iRepAtom = 1
DO iType = 1, atoms%ntype DO iType = 1, atoms%ntype
smom = moments%chmom(iType,1) - moments%chmom(iType,input%jspins) smom = moments%chmom(iType,1) - moments%chmom(iType,input%jspins)
WRITE (6,FMT=8030) iType,smom, (moments%chmom(iType,j),j=1,input%jspins) WRITE (6,FMT=8030) iType,smom, (moments%chmom(iType,j),j=1,input%jspins)
WRITE (16,FMT=8030) iType,smom, (moments%chmom(iType,j),j=1,input%jspins)
attributes = '' attributes = ''
WRITE(attributes(1),'(i0)') iType WRITE(attributes(1),'(i0)') iType
WRITE(attributes(2),'(f15.10)') smom WRITE(attributes(2),'(f15.10)') smom
......
...@@ -29,7 +29,6 @@ SUBROUTINE orbMagMoms(input,atoms,noco,clmom) ...@@ -29,7 +29,6 @@ SUBROUTINE orbMagMoms(input,atoms,noco,clmom)
thetai = noco%theta thetai = noco%theta
phii = noco%phi phii = noco%phi
WRITE (6,FMT=9020) WRITE (6,FMT=9020)
WRITE (16,FMT=9020)
CALL openXMLElement('orbitalMagneticMomentsInMTSpheres',(/'units'/),(/'muBohr'/)) CALL openXMLElement('orbitalMagneticMomentsInMTSpheres',(/'units'/),(/'muBohr'/))
DO iType = 1, atoms%ntype DO iType = 1, atoms%ntype
IF (noco%l_noco) THEN IF (noco%l_noco) THEN
...@@ -52,7 +51,6 @@ SUBROUTINE orbMagMoms(input,atoms,noco,clmom) ...@@ -52,7 +51,6 @@ SUBROUTINE orbMagMoms(input,atoms,noco,clmom)
sin(phii)*clmom(2,iType,2)) sin(phii)*clmom(2,iType,2))
WRITE (6,FMT=8030) iType,slmom,(clmom(3,iType,j),j=1,2) WRITE (6,FMT=8030) iType,slmom,(clmom(3,iType,j),j=1,2)
WRITE (16,FMT=8030) iType,slmom,(clmom(3,iType,j),j=1,2)
attributes = '' attributes = ''
WRITE(attributes(1),'(i0)') iType WRITE(attributes(1),'(i0)') iType
WRITE(attributes(2),'(f15.10)') slmom WRITE(attributes(2),'(f15.10)') slmom
......
...@@ -59,7 +59,7 @@ kpoints/tetcon.f kpoints/kvecon.f init/boxdim.f global/radsra.f math/intgr.F glo ...@@ -59,7 +59,7 @@ kpoints/tetcon.f kpoints/kvecon.f init/boxdim.f global/radsra.f math/intgr.F glo
) )
set(inpgen_F90 ${inpgen_F90} global/constants.f90 io/xsf_io.f90 set(inpgen_F90 ${inpgen_F90} global/constants.f90 io/xsf_io.f90
eigen/orthoglo.F90 juDFT/usage_data.F90 math/ylm4.F90 eigen/orthoglo.F90 juDFT/usage_data.F90 math/ylm4.F90 mpi/mpi_bc_tool.F90
global/sort.f90 global/chkmt.f90 inpgen/inpgen.f90 inpgen/set_inp.f90 inpgen/inpgen_help.f90 io/rw_inp.f90 juDFT/juDFT.F90 global/find_enpara.f90 global/sort.f90 global/chkmt.f90 inpgen/inpgen.f90 inpgen/set_inp.f90 inpgen/inpgen_help.f90 io/rw_inp.f90 juDFT/juDFT.F90 global/find_enpara.f90
inpgen/closure.f90 inpgen/inpgen_arguments.F90 inpgen/closure.f90 inpgen/inpgen_arguments.F90
juDFT/info.F90 juDFT/stop.F90 juDFT/args.F90 juDFT/time.F90 juDFT/init.F90 juDFT/sysinfo.F90 juDFT/string.f90 io/w_inpXML.f90 kpoints/julia.f90 global/utility.F90 juDFT/info.F90 juDFT/stop.F90 juDFT/args.F90 juDFT/time.F90 juDFT/init.F90 juDFT/sysinfo.F90 juDFT/string.f90 io/w_inpXML.f90 kpoints/julia.f90 global/utility.F90
......
...@@ -12,7 +12,11 @@ if (${CMAKE_Fortran_COMPILER_ID} MATCHES "Intel") ...@@ -12,7 +12,11 @@ if (${CMAKE_Fortran_COMPILER_ID} M