Commit 0e6ba4e0 authored by Daniel Wortmann's avatar Daniel Wortmann

Work on defaults

parent 63ded4ad
...@@ -49,11 +49,8 @@ CONTAINS ...@@ -49,11 +49,8 @@ CONTAINS
LOGICAL, INTENT(OUT):: l_opti LOGICAL, INTENT(OUT):: l_opti
INTEGER, ALLOCATABLE :: atomTypeSpecies(:)
INTEGER, ALLOCATABLE :: speciesRepAtomType(:)
CHARACTER(len=3), ALLOCATABLE :: noel(:)
! .. Local Scalars .. ! .. Local Scalars ..
INTEGER :: i,n,l,m1,m2,isym,iisym,numSpecies,pc,iAtom,iType INTEGER :: i,n,l,m1,m2,isym,iisym,pc,iAtom,iType
COMPLEX :: cdum COMPLEX :: cdum
CHARACTER(len=4) :: namex CHARACTER(len=4) :: namex
CHARACTER(len=12) :: relcor, tempNumberString CHARACTER(len=12) :: relcor, tempNumberString
...@@ -218,17 +215,15 @@ CONTAINS ...@@ -218,17 +215,15 @@ CONTAINS
WRITE(*,*) 'Also the generated XML input file is not meant to be' WRITE(*,*) 'Also the generated XML input file is not meant to be'
WRITE(*,*) 'beautiful.' WRITE(*,*) 'beautiful.'
WRITE(*,*) '' WRITE(*,*) ''
ALLOCATE(noel(atoms%ntype),atomTypeSpecies(atoms%ntype),speciesRepAtomType(atoms%ntype))
ALLOCATE(hybrid%lcutm1(atoms%ntype),hybrid%lcutwf(atoms%ntype),hybrid%select1(4,atoms%ntype)) ALLOCATE(hybrid%lcutm1(atoms%ntype),hybrid%lcutwf(atoms%ntype),hybrid%select1(4,atoms%ntype))
filename = 'inpConverted.xml' filename = 'inpConverted.xml'
DO i = 1, atoms%nat DO i = 1, atoms%nat
WRITE(atoms%label(i),'(i0)') i WRITE(atoms%label(i),'(i0)') i
END DO END DO
ALLOCATE(atoms%speciesName(atoms%ntype))
DO iType = 1, atoms%ntype DO iType = 1, atoms%ntype
noel(iType) = namat_const(atoms%nz(iType)) WRITE(tempNumberString,'(i0)') iType
atomTypeSpecies(iType) = iType atoms%speciesName(itype) = TRIM(ADJUSTL(namat_const(atoms%nz(iType)))) // '-' // TRIM(ADJUSTL(tempNumberString))
speciesRepAtomType(iType) = iType
hybrid%lcutm1(iType) = 4 hybrid%lcutm1(iType) = 4
hybrid%lcutwf(iType) = atoms%lmax(iType) - atoms%lmax(iType) / 10 hybrid%lcutwf(iType) = atoms%lmax(iType) - atoms%lmax(iType) / 10
hybrid%select1(:,iType) = (/4, 0, 4, 2 /) hybrid%select1(:,iType) = (/4, 0, 4, 2 /)
...@@ -239,27 +234,17 @@ CONTAINS ...@@ -239,27 +234,17 @@ CONTAINS
hybrid%lexp = 16 hybrid%lexp = 16
hybrid%bands1 = max( nint(input%zelec)*10, 60 ) hybrid%bands1 = max( nint(input%zelec)*10, 60 )
numSpecies = SIZE(speciesRepAtomType)
ALLOCATE(atoms%speciesName(numSpecies))
atoms%speciesName = ''
DO i = 1, numSpecies
tempNumberString = ''
WRITE(tempNumberString,'(i0)') i
atoms%speciesName(i) = TRIM(ADJUSTL(noel(speciesRepAtomType(i)))) // '-' // TRIM(ADJUSTL(tempNumberString))
END DO
a1(:) = a1(:) / input%scaleCell a1(:) = a1(:) / input%scaleCell
a2(:) = a2(:) / input%scaleCell a2(:) = a2(:) / input%scaleCell
a3(:) = a3(:) / input%scaleCell a3(:) = a3(:) / input%scaleCell
kpts%specificationType = 3 kpts%specificationType = 3
sym%symSpecType = 3 sym%symSpecType = 3
CALL w_inpXML(& CALL w_inpXML(&
atoms,obsolete,vacuum,input,stars,sliceplot,forcetheo,banddos,& atoms,vacuum,input,stars,sliceplot,forcetheo,banddos,&
cell,sym,xcpot,noco,oneD,hybrid,kpts,kpts%nkpt3,kpts%l_gamma,& cell,sym,xcpot,noco,oneD,hybrid,kpts,kpts%nkpt3,kpts%l_gamma,&
noel,namex,relcor,a1,a2,a3,cell%amat(3,3),input%comment,& namex,relcor,a1,a2,a3,cell%amat(3,3),input%comment,&
atomTypeSpecies,speciesRepAtomType,.FALSE.,filename,& .FALSE.,filename,&
.TRUE.,numSpecies,enpara) .TRUE.,enpara)
DEALLOCATE(atoms%speciesName, atoms%label)
DEALLOCATE(noel,atomTypeSpecies,speciesRepAtomType)
CALL juDFT_end("Fleur inp to XML input conversion completed.") CALL juDFT_end("Fleur inp to XML input conversion completed.")
END IF END IF
END IF ! mpi%irank.eq.0 END IF ! mpi%irank.eq.0
......
...@@ -71,11 +71,11 @@ PROGRAM inpgen ...@@ -71,11 +71,11 @@ PROGRAM inpgen
!All atom related parameters are set here. Note that some parameters might !All atom related parameters are set here. Note that some parameters might
!have been set in the read_input call before by adding defaults to the atompar module !have been set in the read_input call before by adding defaults to the atompar module
CALL make_atomic_defaults(cell,atoms) CALL make_atomic_defaults(input,vacuum,cell,oneD,atoms)
!Set all defaults that have not been specified before or can not be specified in inpgen !Set all defaults that have not been specified before or can not be specified in inpgen
call make_defaults(atoms,vacuum,input,stars,sliceplot,forcetheo,banddos,& call make_defaults(atoms,vacuum,input,stars,sliceplot,forcetheo,banddos,&
& cell,sym,xcpot,noco,oneD,hybrid,kpts) cell,sym,xcpot,noco,oneD,hybrid,kpts)
! !
!Now the IO-section !Now the IO-section
...@@ -83,13 +83,13 @@ PROGRAM inpgen ...@@ -83,13 +83,13 @@ PROGRAM inpgen
!the inp.xml file !the inp.xml file
CALL w_inpxml(& CALL w_inpxml(&
& atoms,vacuum,input,stars,sliceplot,forcetheo,banddos,& atoms,vacuum,input,stars,sliceplot,forcetheo,banddos,&
& cell,sym,xcpot,noco,oneD,hybrid,kpts,& cell,sym,xcpot,noco,oneD,hybrid,kpts,&
& div,l_gamma,& !should be in kpts!? div,l_gamma,& !should be in kpts!?
& namex,relcor,dtild_opt,name_opt,&!?should be somewhere... namex,relcor,dtild_opt,name_opt,&!?should be somewhere...
& l_outFile,"inp.xml",& l_outFile,"inp.xml",&
& l_explicit,enpara) l_explicit,enpara)
!the sym.xml file !the sym.xml file
CALL write_sym() CALL write_sym()
......
...@@ -9,49 +9,19 @@ MODULE m_make_atomic_defaults ...@@ -9,49 +9,19 @@ MODULE m_make_atomic_defaults
IMPLICIT NONE IMPLICIT NONE
CONTAINS CONTAINS
SUBROUTINE make_atomic_defaults(atoms,sym) SUBROUTINE make_atomic_defaults(input,vacuum,cell,oneD,atoms)
USE m_check_mt_radii
USE m_atompar
TYPE(t_atoms),INTENT(INOUT) :: atoms
TYPE(t_input),INTENT(IN) :: input
CHARACTER(len=1) :: lotype(0:3)=(/'s','p','d','f'/) TYPE(t_vacuum),INTENT(IN) :: vacuum
TYPE(t_cell),INTENT(IN) :: cell
ALLOCATE (atomTypeSpecies(atoms%ntype)) TYPE(t_oneD),INTENT(IN) :: oneD
ALLOCATE (speciesRepAtomType(atoms%nat))
ALLOCATE (atoms%speciesName(atoms%nat)) INTEGER :: i,l
elementNumSpecies = 0
numSpecies = 0 CHARACTER(len=1) :: lotype(0:3)=(/'s','p','d','f'/)
speciesRepAtomType = -1 TYPE(t_atompar):: ap
atomTypeSpecies = -1
atoms%speciesName = ''
DO i = 1, atoms%nat
newSpecies = .TRUE.
DO j = 1, i-1
IF(atomid(i).EQ.atomid(j)) THEN
newSpecies = .FALSE.
atomTypeSpecies(natype(i)) = atomTypeSpecies(natype(j))
EXIT
END IF
END DO
IF(newSpecies) THEN
numSpecies = numSpecies + 1
speciesRepAtomType(numSpecies) = natype(i)
atomTypeSpecies(natype(i)) = numSpecies
element = nint(atoms%zatom(natype(i)))
elementNumSpecies(element) = elementNumSpecies(element) + 1
tempNumberString = ''
WRITE(tempNumberString,'(i0)') elementNumSpecies(element)
atoms%speciesName(numSpecies) = &
TRIM(ADJUSTL(namat_const(element))) // '-' // TRIM(ADJUSTL(tempNumberString))
END IF
END DO
DATA xmlCoreRefOccs /2,2,2,4,2,2,4,2,4,6,2,4,2,4,6,2,4,2,6,8,4,&
& 6,2,4,2,6,8,4,6/
xmlElectronStates = noState_const
xmlPrintCoreStates = .FALSE.
xmlCoreOccs = 0.0
atoms%nlod=9 ! This fixed dimensioning might have to be made more dynamical! atoms%nlod=9 ! This fixed dimensioning might have to be made more dynamical!
ALLOCATE(atoms%nz(atoms%ntype)) ALLOCATE(atoms%nz(atoms%ntype))
...@@ -100,7 +70,7 @@ CONTAINS ...@@ -100,7 +70,7 @@ CONTAINS
atoms%nlo(n)len_TRIM(ap%lo)/2 atoms%nlo(n)len_TRIM(ap%lo)/2
DO i=1,atoms%nlo DO i=1,atoms%nlo
DO l = 0, 3 DO l = 0, 3
IF (ap%lo(2*i:2*) == lotype(l)) atoms%llo(i,n) = l IF (ap%lo(2*i:2*i) == lotype(l)) atoms%llo(i,n) = l
ENDDO ENDDO
ENDDO ENDDO
atoms%ulo_der(:,n)=.FALSE. atoms%ulo_der(:,n)=.FALSE.
...@@ -119,7 +89,5 @@ CONTAINS ...@@ -119,7 +89,5 @@ CONTAINS
END DO END DO
END SUBROUTINE make_atomic_defaults END SUBROUTINE make_atomic_defaults
END MODULE m_make_atomic_defaults END MODULE m_make_atomic_defaults
...@@ -12,8 +12,8 @@ MODULE m_make_defaults ...@@ -12,8 +12,8 @@ MODULE m_make_defaults
! help in the out-file. gb`02 ! help in the out-file. gb`02
!--------------------------------------------------------------------- !---------------------------------------------------------------------
CONTAINS CONTAINS
SUBROUTINE make_defaults(atoms,vacuum,input,stars,sliceplot,forcetheo,banddos,& SUBROUTINE make_defaults(atoms,vacuum,input,stars,&
& cell,sym,xcpot,noco,oneD,hybrid,kpts) & cell,sym,xcpot,noco,hybrid,kpts)
& title & title
USE m_types USE m_types
...@@ -61,48 +61,21 @@ CONTAINS ...@@ -61,48 +61,21 @@ CONTAINS
! Set parameters to defaults that can not be given to inpgen ! Set parameters to defaults that can not be given to inpgen
ch_rw = 'w' ch_rw = 'w'
sym%namgrp= 'any ' sym%namgrp= 'any '
banddos%dos = .false. ; banddos%l_mcd = .false. ; banddos%unfoldband = .FALSE. ; input%secvar = .false. vacuum%nstars = 0 ; vacuum%nstm = 0
input%vchk = .false. ; input%cdinf = .false.
input%l_bmt= .false. ; input%eonly = .false.
input%gauss= .false. ; input%tria = .false.
sliceplot%slice= .false. ; input%swsp = .false.
input%lflip= .false. ; banddos%vacdos= .false. ; input%integ = .false.
sliceplot%iplot= .false. ; input%score = .false. ; sliceplot%plpot = .false.
input%pallst = .false. ; obsolete%lwb = .false. ; vacuum%starcoeff = .false.
input%strho = .false. ; input%l_f = .false.
noco%l_noco = noco%l_ss ; input%jspins = 1
input%itmax = 9 ; input%maxiter = 99 ; input%imix = 7 ; input%alpha = 0.05
input%preconditioning_param = 0.0 ; input%minDistance = 1.0e-5
input%spinf = 2.0 ; obsolete%lepr = 0 ; input%coretail_lmax = 0
sliceplot%kk = 0 ; sliceplot%nnne = 0 ; vacuum%nstars = 0 ; vacuum%nstm = 0
nu = 5 ; vacuum%layerd = 1 ; iofile = 6 nu = 5 ; vacuum%layerd = 1 ; iofile = 6
ALLOCATE(vacuum%izlay(vacuum%layerd,2)) ALLOCATE(vacuum%izlay(vacuum%layerd,2))
banddos%ndir = 0 ; vacuum%layers = 0 ; vacuum%izlay(:,:) = 0 vacuum%layers = 0 ; vacuum%izlay(:,:) = 0
banddos%e_mcd_lo = -10.0 ; banddos%e_mcd_up = 0.0
input%epsdisp = 0.00001 ; input%epsforce = 0.00001 ; input%forcealpha = 1.0 ; input%forcemix=0
sliceplot%e1s = 0.0 ; sliceplot%e2s = 0.0 ; banddos%e1_dos = 0.5 ; banddos%e2_dos = -0.5 ; input%tkb = 0.001 vacuum%tworkf = 0.0 ; scpos = 1.0
banddos%sig_dos = 0.015 ; vacuum%tworkf = 0.0 ; input%scaleCell = 1.0 ; scpos = 1.0
input%scaleA1 = 1.0 ; input%scaleA2 = 1.0 ; input%scaleC = 1.0
zc = 0.0 ; vacuum%locx(:) = 0.0 ; vacuum%locy(:) = 0.0 zc = 0.0 ; vacuum%locx(:) = 0.0 ; vacuum%locy(:) = 0.0
kpts%numSpecialPoints = 0 kpts%numSpecialPoints = 0
input%ldauLinMix = .FALSE. ; input%ldauMixParam = 0.05 ; input%ldauSpinf = 1.0
input%l_wann = .FALSE.
input%gw = 0
!+odim
oneD%odd%mb = 0 ; oneD%odd%M = 0 ; oneD%odd%m_cyl = 0 ; oneD%odd%chi = 0 ; oneD%odd%rot = 0
oneD%odd%k3 = 0 ; oneD%odd%n2d= 0 ; oneD%odd%nq2 = 0 ; oneD%odd%nn2d = 0
oneD%odd%nop = 0 ; oneD%odd%kimax2 = 0 ; oneD%odd%nat = 0
oneD%odd%invs = .false. ; oneD%odd%zrfs = .false. ; oneD%odd%d1 = .false.
!-odim
input%delgau = input%tkb input%delgau = input%tkb
DO i = 1, 10 input%comment = title
j = (i-1) * 8 + 1
input%comment(i) = title(j:j+7)
ENDDO
IF (noco%l_noco) input%jspins = 2 IF (noco%l_noco) input%jspins = 2
...@@ -127,13 +100,10 @@ CONTAINS ...@@ -127,13 +100,10 @@ CONTAINS
!HF added for HF and hybrid functionals !HF added for HF and hybrid functionals
hybrid%gcutm1 = input%rkmax - 0.5 hybrid%gcutm1 = input%rkmax - 0.5
hybrid%tolerance1 = 1e-4
ALLOCATE(hybrid%lcutwf(atoms%ntype)) ALLOCATE(hybrid%lcutwf(atoms%ntype))
ALLOCATE(hybrid%lcutm1(atoms%ntype)) ALLOCATE(hybrid%lcutm1(atoms%ntype))
ALLOCATE(hybrid%select1(4,atoms%ntype)) ALLOCATE(hybrid%select1(4,atoms%ntype))
hybrid%lcutwf = atoms%lmax - atoms%lmax / 10 hybrid%lcutwf = atoms%lmax - atoms%lmax / 10
hybrid%ewaldlambda = 3
hybrid%lexp = 16
hybrid%lcutm1 = 4 hybrid%lcutm1 = 4
hybrid%select1(1,:) = 4 hybrid%select1(1,:) = 4
hybrid%select1(2,:) = 0 hybrid%select1(2,:) = 0
...@@ -216,9 +186,6 @@ CONTAINS ...@@ -216,9 +186,6 @@ CONTAINS
ALLOCATE(noco%alphInit(atoms%ntype),noco%alph(atoms%ntype),noco%beta(atoms%ntype)) ALLOCATE(noco%alphInit(atoms%ntype),noco%alph(atoms%ntype),noco%beta(atoms%ntype))
IF (noco%l_ss) input%ctail = .FALSE. IF (noco%l_ss) input%ctail = .FALSE.
noco%l_mperp = .FALSE.
noco%l_constr = .FALSE.
noco%mix_b = 0.0
noco%qss = merge(noco%qss,[0.0,0.0,0.0],noco%l_ss) noco%qss = merge(noco%qss,[0.0,0.0,0.0],noco%l_ss)
noco%l_relax(:) = .FALSE. noco%l_relax(:) = .FALSE.
......
...@@ -98,6 +98,8 @@ CONTAINS ...@@ -98,6 +98,8 @@ CONTAINS
LOGICAL :: kptGamma, l_relcor,ldummy LOGICAL :: kptGamma, l_relcor,ldummy
INTEGER :: iAtomType INTEGER :: iAtomType
CHARACTER(len=100) :: xPosString, yPosString, zPosString CHARACTER(len=100) :: xPosString, yPosString, zPosString
CHARACTER(len=20),ALLOCATABLE :: speciesName(:)
! REAL :: tempTaual(3,atoms%nat) ! REAL :: tempTaual(3,atoms%nat)
TYPE(t_econfig) :: econf TYPE(t_econfig) :: econf
...@@ -262,12 +264,8 @@ CONTAINS ...@@ -262,12 +264,8 @@ CONTAINS
DO i = 1, LEN(TRIM(ADJUSTL(valueString))) DO i = 1, LEN(TRIM(ADJUSTL(valueString)))
IF (valueString(i:i) == ACHAR(10)) valueString(i:i) = ' ' !remove line breaks IF (valueString(i:i) == ACHAR(10)) valueString(i:i) = ' ' !remove line breaks
END DO END DO
valueString = TRIM(ADJUSTL(valueString)) input%comment = TRIM(ADJUSTL(valueString))
DO i = 1, 10
j = (i-1) * 8 + 1
input%comment(i) = valueString(j:j+7)
END DO
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
!!! Start of calculationSetup section !!! Start of calculationSetup section
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
...@@ -1354,8 +1352,8 @@ input%preconditioning_param = evaluateFirstOnly(xmlGetAttributeValue('/fleurInpu ...@@ -1354,8 +1352,8 @@ input%preconditioning_param = evaluateFirstOnly(xmlGetAttributeValue('/fleurInpu
DO iType = 1, atoms%ntype DO iType = 1, atoms%ntype
WRITE(xPathA,*) '/fleurInput/atomGroups/atomGroup[',iType,']/@species' WRITE(xPathA,*) '/fleurInput/atomGroups/atomGroup[',iType,']/@species'
atom%speciesName(iType) = TRIM(ADJUSTL(xmlGetAttributeValue(TRIM(ADJUSTL(xPathA))))) atoms%speciesName(iType) = TRIM(ADJUSTL(xmlGetAttributeValue(TRIM(ADJUSTL(xPathA)))))
IF(TRIM(ADJUSTL(speciesName(iSpecies))).EQ.TRIM(ADJUSTL(atom%speciesName(iType)))) THEN IF(TRIM(ADJUSTL(speciesName(iSpecies))).EQ.TRIM(ADJUSTL(atoms%speciesName(iType)))) THEN
atoms%nz(iType) = atomicNumber atoms%nz(iType) = atomicNumber
atoms%zatom(iType) = atoms%nz(iType) atoms%zatom(iType) = atoms%nz(iType)
IF (atoms%nz(iType).EQ.0) THEN IF (atoms%nz(iType).EQ.0) THEN
......
...@@ -11,7 +11,7 @@ ...@@ -11,7 +11,7 @@
SUBROUTINE rw_inp(& SUBROUTINE rw_inp(&
& ch_rw,atoms,obsolete,vacuum,input,stars,sliceplot,banddos,& & ch_rw,atoms,obsolete,vacuum,input,stars,sliceplot,banddos,&
& cell,sym,xcpot,noco,oneD,hybrid,kpts,& & cell,sym,xcpot,noco,oneD,hybrid,kpts,&
& noel,namex,relcor,a1,a2,a3,dtild_opt,name_opt) & noel,namex,relcor,a1,a2,a3,dtild_opt)!,name_opt)
!********************************************************************* !*********************************************************************
!* This subroutine reads or writes an inp - file on unit iofile * !* This subroutine reads or writes an inp - file on unit iofile *
...@@ -46,11 +46,11 @@ ...@@ -46,11 +46,11 @@
CHARACTER(len=4),INTENT(OUT) :: namex CHARACTER(len=4),INTENT(OUT) :: namex
CHARACTER(len=12),INTENT(OUT):: relcor CHARACTER(len=12),INTENT(OUT):: relcor
REAL,INTENT(IN),OPTIONAL :: dtild_opt REAL,INTENT(IN),OPTIONAL :: dtild_opt
CHARACTER(len=8),INTENT(IN),OPTIONAL:: name_opt(10) !CHARACTER(len=8),INTENT(IN),OPTIONAL:: name_opt(10)
CHARACTER(len=8) :: name(10) CHARACTER(len=80) :: name
!+lda+u !+lda+u
REAL u,j REAL u,j
...@@ -87,7 +87,7 @@ ...@@ -87,7 +87,7 @@
CHARACTER (len=1) :: check CHARACTER (len=1) :: check
IF (PRESENT(dtild_opt)) dtild=dtild_opt IF (PRESENT(dtild_opt)) dtild=dtild_opt
IF (PRESENT(name_opt)) name=name_opt !IF (PRESENT(name_opt)) name=name_opt
! Initialize variables ! Initialize variables
l_hyb = .false. l_hyb = .false.
......
...@@ -60,7 +60,7 @@ SUBROUTINE w_inpXML(& ...@@ -60,7 +60,7 @@ SUBROUTINE w_inpXML(&
INTEGER :: iSpecies, fileNum INTEGER :: iSpecies, fileNum
CHARACTER(len=8) :: name(10) CHARACTER(len=8) :: name(10)
INTEGER :: numSpecies INTEGER :: numSpecies
INTEGER :: speciesRepAtomType(numSpecies) INTEGER :: speciesRepAtomType(atoms%ntype)
CHARACTER(len=20):: speciesNames(atoms%ntype) CHARACTER(len=20):: speciesNames(atoms%ntype)
LOGICAL :: known_species LOGICAL :: known_species
...@@ -438,7 +438,7 @@ SUBROUTINE w_inpXML(& ...@@ -438,7 +438,7 @@ SUBROUTINE w_inpXML(&
speciesNames='' speciesNames=''
numSpecies=0 numSpecies=0
DO n=1,atoms%ntype DO n=1,atoms%ntype
known_species=any(trim(adjustl(atoms%speciesname(n)))==trim(adjustl(speciesNames(:numSpecies)))) known_species=ANY(atoms%speciesname(n)==speciesNames(:numSpecies))
if (.not.known_species) THEN if (.not.known_species) THEN
numSpecies=numSpecies+1 numSpecies=numSpecies+1
speciesNames(numSpecies)=atoms%speciesname(n) speciesNames(numSpecies)=atoms%speciesname(n)
...@@ -455,7 +455,7 @@ SUBROUTINE w_inpXML(& ...@@ -455,7 +455,7 @@ SUBROUTINE w_inpXML(&
! <species name="Si-1" element="Si" atomicNumber="14" coreStates="4" magMom="0.0" flipSpin="F"> ! <species name="Si-1" element="Si" atomicNumber="14" coreStates="4" magMom="0.0" flipSpin="F">
300 FORMAT(' <species name="',a,'" element="',a,'" atomicNumber="',i0,'" magMom="',f0.8,'" flipSpin="',l1,'">') 300 FORMAT(' <species name="',a,'" element="',a,'" atomicNumber="',i0,'" magMom="',f0.8,'" flipSpin="',l1,'">')
speciesName = TRIM(ADJUSTL(atoms%speciesName(iSpecies))) speciesName = TRIM(ADJUSTL(atoms%speciesName(iSpecies)))
WRITE (fileNum,300) TRIM(ADJUSTL(speciesName)),TRIM(ADJUSTL(namat_const(nint(atoms%nz(iAtomType)+1)))),atoms%nz(iAtomType),atoms%bmu(iAtomType),atoms%nflip(iAtomType) WRITE (fileNum,300) TRIM(ADJUSTL(speciesName)),TRIM(ADJUSTL(namat_const(atoms%nz(iAtomType)+1))),atoms%nz(iAtomType),atoms%bmu(iAtomType),atoms%nflip(iAtomType)
! <mtSphere radius="2.160000" gridPoints="521" logIncrement="0.022000"/> ! <mtSphere radius="2.160000" gridPoints="521" logIncrement="0.022000"/>
310 FORMAT(' <mtSphere radius="',f0.8,'" gridPoints="',i0,'" logIncrement="',f0.8,'"/>') 310 FORMAT(' <mtSphere radius="',f0.8,'" gridPoints="',i0,'" logIncrement="',f0.8,'"/>')
...@@ -525,10 +525,9 @@ SUBROUTINE w_inpXML(& ...@@ -525,10 +525,9 @@ SUBROUTINE w_inpXML(&
WRITE (fileNum,'(a)') ' <atomGroups>' WRITE (fileNum,'(a)') ' <atomGroups>'
na = 0 na = 0
DO iAtomType=1, atoms%ntype DO iAtomType=1, atoms%ntype
iSpecies = atomTypeSpecies(iAtomType)
! <atomGroup species="Si-1"> ! <atomGroup species="Si-1">
330 FORMAT(' <atomGroup species="',a,'">') 330 FORMAT(' <atomGroup species="',a,'">')
speciesName = TRIM(ADJUSTL(atoms%speciesName(iSpecies))) speciesName = TRIM(ADJUSTL(atoms%speciesName(iAtomType)))
WRITE (fileNum,330) TRIM(ADJUSTL(speciesName)) WRITE (fileNum,330) TRIM(ADJUSTL(speciesName))
DO ieq=1,atoms%neq(iAtomType) DO ieq=1,atoms%neq(iAtomType)
......
...@@ -178,7 +178,6 @@ ...@@ -178,7 +178,6 @@
atoms,obsolete,vacuum,input,stars,sliceplot,banddos,DIMENSION,forcetheo,field,& atoms,obsolete,vacuum,input,stars,sliceplot,banddos,DIMENSION,forcetheo,field,&
cell,sym,xcpot,noco,oneD,hybrid,kpts,enpara,coreSpecInput,wann,& cell,sym,xcpot,noco,oneD,hybrid,kpts,enpara,coreSpecInput,wann,&
noel,namex,relcor,a1,a2,a3,dtild,& noel,namex,relcor,a1,a2,a3,dtild,&
atomTypeSpecies,speciesRepAtomType,&
l_kpts) l_kpts)
END IF END IF
CALL mpi_bc_xcpot(xcpot,mpi) CALL mpi_bc_xcpot(xcpot,mpi)
...@@ -198,11 +197,11 @@ ...@@ -198,11 +197,11 @@
filename = '' filename = ''
numSpecies = SIZE(speciesRepAtomType) numSpecies = SIZE(speciesRepAtomType)
CALL w_inpXML(& CALL w_inpXML(&
atoms,obsolete,vacuum,input,stars,sliceplot,forcetheo,banddos,& atoms,vacuum,input,stars,sliceplot,forcetheo,banddos,&
cell,sym,xcpot,noco,oneD,hybrid,kpts,kpts%nkpt3,kpts%l_gamma,& cell,sym,xcpot,noco,oneD,hybrid,kpts,kpts%nkpt3,kpts%l_gamma,&
noel,namex,relcor,a1,a2,a3,dtild,input%comment,& namex,relcor,a1,a2,a3,dtild,input%comment,&
atomTypeSpecies,speciesRepAtomType,.TRUE.,filename,& .TRUE.,filename,&
.TRUE.,numSpecies,enpara) .TRUE.,enpara)
DEALLOCATE(atomTypeSpecies,speciesRepAtomType) DEALLOCATE(atomTypeSpecies,speciesRepAtomType)
DEALLOCATE(xmlElectronStates,xmlPrintCoreStates,xmlCoreOccs) DEALLOCATE(xmlElectronStates,xmlPrintCoreStates,xmlCoreOccs)
......
set(fleur_F77 ${fleur_F77} set(fleur_F77 ${fleur_F77}
) )
set(fleur_F90 ${fleur_F90} set(fleur_F90 ${fleur_F90}
types/types.F90 types/types.F90
types/types_mat.F90 types/types_mat.F90
...@@ -28,6 +28,12 @@ types/types_gpumat.F90 ...@@ -28,6 +28,12 @@ types/types_gpumat.F90
types/types_econfig.F90 types/types_econfig.F90
types/types_cell.f90 types/types_cell.f90
types/types_sym.f90 types/types_sym.f90
types/types_input.f90
types/types_sliceplot.f90
types/types_oneD.f90
types/types_hybrid.f90
types/types_noco.f90
types/types_banddos.f90
) )
set(inpgen_F90 ${inpgen_F90} set(inpgen_F90 ${inpgen_F90}
......
!--------------------------------------------------------------------------------
! Copyright (c) 2016 Peter Grünberg Institut, Forschungszentrum Jülich, Germany
! This file is part of FLEUR and available as free software under the conditions
! of the MIT license as expressed in the LICENSE file in more detail.
!--------------------------------------------------------------------------------
MODULE m_types_banddos
TYPE t_banddos
LOGICAL :: dos =.false.
LOGICAL :: band =.false.
LOGICAL :: l_mcd =.false.
LOGICAL :: l_orb =.false.
LOGICAL :: vacdos =.false.
INTEGER :: ndir =0
INTEGER :: orbCompAtom=0
REAL :: e1_dos=0.5
REAL :: e2_dos=-0.5
REAL :: sig_dos=0.015
REAL :: e_mcd_lo =-10.0
REAL :: e_mcd_up= 0.0
LOGICAL :: unfoldband =.false.
INTEGER :: s_cell_x
INTEGER :: s_cell_y
INTEGER :: s_cell_z
REAL :: alpha,beta,gamma !For orbital decomp. (was orbcomprot)
END TYPE t_banddos
END MODULE m_types_banddos
!--------------------------------------------------------------------------------
! Copyright (c) 2016 Peter Grünberg Institut, Forschungszentrum Jülich, Germany
! This file is part of FLEUR and available as free software under the conditions
! of the MIT license as expressed in the LICENSE file in more detail.
!--------------------------------------------------------------------------------
MODULE m_types_hybrid
TYPE t_hybrid
LOGICAL :: l_hybrid = .false.
LOGICAL :: l_subvxc = .false.
LOGICAL :: l_calhf = .false.
LOGICAL :: l_addhf = .false.
INTEGER :: ewaldlambda =3
INTEGER :: lexp =16
INTEGER :: bands1 !Only read in
INTEGER :: nbasp
INTEGER :: maxlcutm1
INTEGER :: maxindxm1
INTEGER :: maxbasm1
INTEGER :: maxindxp1
INTEGER :: maxgptm
INTEGER :: maxgptm1
INTEGER :: maxindx
INTEGER :: maxlmindx
INTEGER :: gptmd
INTEGER, ALLOCATABLE :: nindx(:, :)
INTEGER, ALLOCATABLE :: select1(:, :)
INTEGER, ALLOCATABLE :: lcutm1(:)
INTEGER, ALLOCATABLE :: nindxm1(:, :)
INTEGER, ALLOCATABLE :: gptm(:, :)
INTEGER, ALLOCATABLE :: ngptm1(:)
INTEGER, ALLOCATABLE :: pgptm1(:, :)
INTEGER, ALLOCATABLE :: ngptm(:)
INTEGER, ALLOCATABLE :: pgptm(:, :)
INTEGER, ALLOCATABLE :: lcutwf(:)
INTEGER, ALLOCATABLE :: map(:, :)
INTEGER, ALLOCATABLE :: tvec(:, :, :)
INTEGER, ALLOCATABLE :: nbasm(:)
REAL :: gcutm1