Commit 21ff95f6 authored by Alexander Neukirchen's avatar Alexander Neukirchen

Merge branch 'plot' into source_free

parents 99cd6819 8eedce6f
......@@ -47,8 +47,6 @@ pages:
paths:
- public
only:
- schedules
- triggers
- web
doxygen:
......@@ -65,8 +63,6 @@ doxygen:
- build/fleur_MPI
- build/inpgen
only:
- schedules
- triggers
- web
......@@ -179,4 +175,4 @@ gfortran-coverage:
url: https://fleur.iffgit.fz-juelich.de/fleur/coverage_html
only:
- web
- schedules
\ No newline at end of file
export CRAYPE_LINK_TYPE=dynamic
export CRAYPE_LINK_TYPE=dynamic
#ELPA
if [ $ELPA_MODULES ]
then
CLI_ELPA_OPENMP=1
FLEUR_LIBDIR="$FLEUR_LIBDIR $ELPA_LIB"
FLEUR_INCLUDEDIR="$FLEUR_INCLUDEDIR $ELPA_MODULES"
fi
if module list 2>&1 | grep -q intel
then
if module list 2>&1| grep -q mpi.ibm
then
echo "Please use intelmpi, e.g. do a module switch mpi.ibm mpi.intel"
exit
fi
if module list 2>&1| grep -q mpi.intel/2017
then
echo "There are problems with mpi.intel/2017, try another version"
exit
fi
if module list 2>&1| grep -q mpi.intel
then
export FC=mpif90
export CC=mpicc
fi
fi
if module list 2>&1 | grep -q elpa
then
#ELPA
CLI_ELPA_OPENMP=1
FLEUR_LIBDIR="$FLEUR_LIBDIR $ELPA_LIB"
FLEUR_INCLUDEDIR="$FLEUR_INCLUDEDIR $ELPA_MODULES_OPENMP"
fi
......@@ -2,6 +2,37 @@
try_compile(FLEUR_USE_WANN ${CMAKE_BINARY_DIR} ${CMAKE_SOURCE_DIR}/cmake/tests/test_Wannier90.f90
LINK_LIBRARIES ${FLEUR_LIBRARIES}
)
message("Wannier90 1.2 Library found:${FLEUR_USE_WANN}")
foreach(ADD_String "-lwannier;-lmkl_intel_lp64;-lmkl_sequential;-lmkl_core" )
if (NOT FLEUR_USE_WANN)
set(TEST_LIBRARIES "${FLEUR_LIBRARIES};${ADD_String}")
message("compilation test:${CMAKE_BINARY_DIR} ${CMAKE_SOURCE_DIR}/cmake/tests/test_Wannier90.f90
LINK_LIBRARIES ${TEST_LIBRARIES}")
try_compile(FLEUR_USE_WANN ${CMAKE_BINARY_DIR} ${CMAKE_SOURCE_DIR}/cmake/tests/test_Wannier90.f90
LINK_LIBRARIES ${TEST_LIBRARIES} OUTPUT_VARIABLE TELL_ME
)
message("TELL_ME=${TELL_ME}")
if (FLEUR_USE_WANN)
set(FLEUR_WANNIER90_LIBRARIES ${TEST_LIBRARIES})
set( FLEUR_LIBRARIES "${FLEUR_LIBRARIES};${ADD_String}" )
endif()
endif()
endforeach()
message("Wannier90 1.2 Library found:${FLEUR_USE_WANN}")
......
FROM ubuntu:18.10
FROM iffregistry.fz-juelich.de/fleur/fleur/intel-libs
MAINTAINER d.wortmann@fz-juelich.de
COPY ../fleur /home
COPY ../inpgen /home
COPY fleur /home
RUN echo "#!/bin/sh \n if [ -r /mnt/inp.xml ] ; then cd /mnt ; ulimit -s unlimited ;/home/fleur \$@; else echo 'You should provide your working directory by specifying e.g. -v \$PWD:/mnt ' ; fi " >/home/fleur.sh ; chmod a+x /home/fleur.sh
ENTRYPOINT ["/home/fleur.sh"]
......@@ -74,7 +74,7 @@ CONTAINS
INTEGER,INTENT(IN) :: eig_id
! Local Scalars
INTEGER jsp,nk,nred,ne_all,ne_found
INTEGER jsp,nk,nred,ne_all,ne_found,neigd2
INTEGER ne, nk_i
INTEGER isp,i,j,err
LOGICAL l_wu,l_file,l_real,l_zref
......@@ -257,18 +257,19 @@ CONTAINS
END DO k_loop
END DO ! spin loop ends
neigd2 = MIN(dimension%neigd,dimension%nbasfcn)
#ifdef CPP_MPI
IF (banddos%unfoldband) THEN
results%unfolding_weights = CMPLX(0.0,0.0)
CALL MPI_ALLREDUCE(unfoldingBuffer,results%unfolding_weights,SIZE(results%unfolding_weights,1)*SIZE(results%unfolding_weights,2)*SIZE(results%unfolding_weights,3),CPP_MPI_COMPLEX,MPI_SUM,mpi%mpi_comm,ierr)
END IF
CALL MPI_ALLREDUCE(neigBuffer,results%neig,kpts%nkpt*input%jspins,MPI_INTEGER,MPI_SUM,mpi%mpi_comm,ierr)
CALL MPI_ALLREDUCE(eigBuffer(:dimension%neigd,:,:),results%eig(:dimension%neigd,:,:),dimension%neigd*kpts%nkpt*input%jspins,MPI_DOUBLE_PRECISION,MPI_MIN,mpi%mpi_comm,ierr)
CALL MPI_ALLREDUCE(eigBuffer(:neigd2,:,:),results%eig(:neigd2,:,:),neigd2*kpts%nkpt*input%jspins,MPI_DOUBLE_PRECISION,MPI_MIN,mpi%mpi_comm,ierr)
CALL MPI_BARRIER(mpi%MPI_COMM,ierr)
#else
results%neig(:,:) = neigBuffer(:,:)
results%eig(:dimension%neigd,:,:) = eigBuffer(:dimension%neigd,:,:)
results%eig(:neigd2,:,:) = eigBuffer(:neigd2,:,:)
results%unfolding_weights(:,:,:) = unfoldingBuffer(:,:,:)
#endif
......
MODULE m_anglso
contains
COMPLEX FUNCTION anglso(theta,phi,l1,m1,is1,l2,m2,is2)
COMPLEX FUNCTION anglso(theta,phi,l1,m1,is1,l2,m2,is2,compo)
USE m_juDFT
!
! calculates spin-orbit matrix for theta,phi =/= 0
......@@ -9,6 +9,7 @@ contains
! ..
! .. Scalar Arguments ..
INTEGER, INTENT(IN) :: is1,is2,l1,l2,m1,m2
INTEGER, INTENT(IN),OPTIONAL :: compo
REAL, INTENT(IN) :: theta,phi
! ..
! .. Local Scalars ..
......@@ -63,6 +64,29 @@ contains
ELSE IF (m1.EQ.m2 ) THEN
xlz = m2
END IF
IF(PRESENT(compo))THEN
! Used for the wannier-interpolation of SOC:
! wann_socmat_vec allow us to
! add SOC during the wannier-interpolation.
! Therefore, theta and phi are specified during the
! Wannier-interpolation step and not here.
! Therefore, write out only xlz, xlpl, and xlmn and RETURN
! afterwards, without using theta and phi.
! xlz, xlpl and xlmn are needed in subroutine wann_socmat_vec.F
if(compo.eq.1)then
anglso = CMPLX(xlz,0.0)
elseif(compo.eq.2)then
anglso = CMPLX(xlmn,0.0)
elseif(compo.eq.3)then
anglso = CMPLX(xlpl,0.0)
else
CALL juDFT_error("maucompo",calledby ="anglso")
endif
RETURN
END IF
!
! rotated spin-orbit angular matrix
! <1| |1> or <2| |2>
......
......@@ -94,7 +94,7 @@ CONTAINS
CALL spnorb_angles(atoms,mpi,noco%theta,noco%phi,rsoc%soangl)
END SUBROUTINE spnorb
SUBROUTINE spnorb_angles(atoms,mpi,theta,phi,soangl)
SUBROUTINE spnorb_angles(atoms,mpi,theta,phi,soangl,compo)
USE m_anglso
USE m_sgml
USE m_sorad
......@@ -104,6 +104,7 @@ CONTAINS
TYPE(t_mpi),INTENT(IN) :: mpi
REAL,INTENT(IN) :: theta,phi
COMPLEX,INTENT(INOUT) :: soangl(:,-atoms%lmaxd:,:,:,-atoms%lmaxd:,:)
INTEGER, INTENT(IN),OPTIONAL :: compo
! ..
! ..
! .. Local Scalars ..
......@@ -116,7 +117,8 @@ CONTAINS
DATA ispjsp/1,-1/
IF ((ABS(theta).LT.0.00001).AND.(ABS(phi).LT.0.00001)) THEN
IF ((ABS(theta).LT.0.00001).AND.(ABS(phi).LT.0.00001)&
.AND..NOT.PRESENT(compo)) THEN
!
! TEST for real function sgml(l1,m1,is1,l2,m2,is2)
!
......@@ -151,7 +153,7 @@ CONTAINS
DO m1 = -l1,l1,1
DO m2 = -l2,l2,1
soangl(l1,m1,jspin1,l2,m2,jspin2) =&
anglso(theta,phi,l1,m1,is1,l2,m2,is2)
anglso(theta,phi,l1,m1,is1,l2,m2,is2,compo)
ENDDO
ENDDO
!
......
......@@ -30,6 +30,16 @@ MODULE m_constants
INTEGER, PARAMETER :: POTDEN_TYPE_EnergyDen = 5
INTEGER, PARAMETER :: POTDEN_TYPE_DEN = 1001 ! 1000 < POTDEN_TYPE ==> density
INTEGER, PARAMETER :: PLOT_INPDEN=1
INTEGER, PARAMETER :: PLOT_OUTDEN_Y_CORE=2
INTEGER, PARAMETER :: PLOT_INPDEN_N_CORE=3
INTEGER, PARAMETER :: PLOT_POT_TOT=7
INTEGER, PARAMETER :: PLOT_POT_EXT=8
INTEGER, PARAMETER :: PLOT_POT_COU=9
INTEGER, PARAMETER :: PLOT_POT_VXC=10
CHARACTER(2),DIMENSION(0:103),PARAMETER :: namat_const=(/&
'va',' H','He','Li','Be',' B',' C',' N',' O',' F','Ne',&
'Na','Mg','Al','Si',' P',' S','Cl','Ar',' K','Ca','Sc','Ti',&
......
......@@ -136,7 +136,7 @@ CONTAINS
atoms%nlo(:) = 0
atoms%llo(:,:) = -1
input%eig66(1)=.FALSE.
! HF/hybrid functionals/EXX
ALLOCATE ( hybrid%nindx(0:atoms%lmaxd,atoms%ntype) )
......@@ -184,7 +184,7 @@ CONTAINS
INQUIRE(file="cdn1",exist=l_opti)
IF (noco%l_noco) INQUIRE(file="rhomat_inp",exist=l_opti)
l_opti=.NOT.l_opti
IF ((sliceplot%iplot).OR.(input%strho).OR.(input%swsp).OR.&
IF ((sliceplot%iplot.NE.0).OR.(input%strho).OR.(input%swsp).OR.&
& (input%lflip).OR.(input%l_bmt)) l_opti = .TRUE.
!
......@@ -195,6 +195,7 @@ CONTAINS
#ifdef CPP_MPI
CALL MPI_BCAST(namex,4,MPI_CHARACTER,0,mpi%mpi_comm,ierr)
CALL MPI_BCAST(l_krla,1,MPI_LOGICAL,0,mpi%mpi_comm,ierr)
CALL MPI_BCAST(input%eig66(1),1,MPI_LOGICAL,0,mpi%mpi_comm,ierr)
CALL MPI_BCAST(atoms%ntype,1,MPI_INTEGER,0,mpi%mpi_comm,ierr)
#ifndef CPP_OLDINTEL
CALL mpi_dist_forcetheorem(mpi,forcetheo)
......
......@@ -173,7 +173,7 @@
!
ENDIF ! (mpi%irank == 0)
CALL stepf(sym,stars,atoms,oneD, input,cell, vacuum,mpi)
IF (.NOT.sliceplot%iplot) THEN
IF (sliceplot%iplot.EQ.0) THEN
IF ( mpi%irank == 0 ) THEN
CALL convn(DIMENSION,atoms,stars)
......
......@@ -523,7 +523,7 @@ SUBROUTINE postprocessInput(mpi,input,field,sym,stars,atoms,vacuum,obsolete,kpts
INQUIRE(file="cdn1",exist=l_opti)
if (noco%l_noco) INQUIRE(file="rhomat_inp",exist=l_opti)
l_opti=.not.l_opti
IF ((sliceplot%iplot).OR.(input%strho).OR.(input%swsp).OR.&
IF ((sliceplot%iplot.NE.0).OR.(input%strho).OR.(input%swsp).OR.&
(input%lflip).OR.(input%l_bmt)) l_opti = .TRUE.
IF (.NOT.l_opti) THEN
......@@ -546,12 +546,12 @@ SUBROUTINE postprocessInput(mpi,input,field,sym,stars,atoms,vacuum,obsolete,kpts
CALL timestart("stepf")
CALL stepf(sym,stars,atoms,oneD,input,cell,vacuum,mpi)
CALL timestop("stepf")
IF (.NOT.sliceplot%iplot) THEN
!IF (sliceplot%iplot.EQ.0) THEN
IF (mpi%irank.EQ.0) THEN
CALL convn(DIMENSION,atoms,stars)
CALL e_field(atoms,DIMENSION,stars,sym,vacuum,cell,input,field%efield)
END IF !(mpi%irank.EQ.0)
END IF
!END IF
!At some point this should be enabled for noco as well
#ifdef CPP_MPI
......
......@@ -140,7 +140,7 @@
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.
sliceplot%iplot= 0
input%pallst = .false. ; obsolete%lwb = .false. ; vacuum%starcoeff = .false.
input%strho = .false. ; input%l_f = .false. ; atoms%l_geo(:) = .true.
noco%l_noco = noco%l_ss ; input%jspins = 1
......
......@@ -318,7 +318,7 @@ CONTAINS
DO i=1,SIZE(list)
CALL io_read_real3(d%evsetid,(/1,1,list(i),nk,jspin/),&
& (/2,nmat,1,1,1/),z1)
z(:,i) = CMPLX( z1(1,:,i) ,z1(2,:,i) )
z(:,i) = CMPLX( z1(1,:,1) ,z1(2,:,1) )
ENDDO
END IF
END SUBROUTINE priv_r_vecc
......
......@@ -68,13 +68,6 @@ MODULE m_nocoInputCheck
CALL juDFT_error("Coretail option cannot be used!!!",calledby="nocoInputCheck")
END IF
!---> make sure score is false
IF (input%score) THEN
WRITE (6,*) 'This non-collinear version of the flapw program'
WRITE (6,*) 'cannot be used with the score option!! '
CALL juDFT_error("score must be false!!!",calledby ="nocoInputCheck")
END IF
!---> make sure that moments are not relaxed and constrained
l_relax_any = .FALSE.
DO itype = 1,atoms%ntype
......
......@@ -1924,9 +1924,7 @@ CONTAINS
input%vchk = .FALSE.
input%cdinf = .FALSE.
sliceplot%iplot = .FALSE.
input%score = .FALSE.
sliceplot%plpot = .FALSE.
sliceplot%iplot = 0
input%eonly = .FALSE.
input%l_bmt = .FALSE.
......@@ -1962,9 +1960,7 @@ CONTAINS
numberNodes = xmlGetNumberOfNodes(xPathA)
IF (numberNodes.EQ.1) THEN
sliceplot%iplot = evaluateFirstBoolOnly(xmlGetAttributeValue(TRIM(ADJUSTL(xPathA))//'/@iplot'))
input%score = evaluateFirstBoolOnly(xmlGetAttributeValue(TRIM(ADJUSTL(xPathA))//'/@score'))
sliceplot%plpot = evaluateFirstBoolOnly(xmlGetAttributeValue(TRIM(ADJUSTL(xPathA))//'/@plplot'))
sliceplot%iplot = evaluateFirstIntOnly(xmlGetAttributeValue(TRIM(ADJUSTL(xPathA))//'/@iplot'))
END IF
! Read in optional specialOutput switches
......
......@@ -71,7 +71,7 @@
INTEGER ::nw,idsprs
INTEGER ieq,i,k,na,n,ilo
REAL s3,ah,a,hs2,rest
LOGICAL l_hyb,l_sym,ldum
LOGICAL l_hyb,l_sym,ldum,ldum2
INTEGER :: ierr, intDummy
! ..
!... Local Arrays
......@@ -619,15 +619,17 @@
END IF
!
band = .false.
READ (UNIT=5,FMT=8050,END=992,ERR=992) sliceplot%iplot,input%score,sliceplot%plpot,band
WRITE (6,9240) sliceplot%iplot,input%score,sliceplot%plpot,band
READ (UNIT=5,FMT=8050,END=992,ERR=992) ldum,ldum2,ldum2,band
WRITE (6,9240) ldum,ldum2,ldum2,band
sliceplot%iplot=MERGE(1,0,ldum)
IF (band) THEN
banddos%dos=.true. ; banddos%ndir = -4
ENDIF
GOTO 993
992 BACKSPACE(5)
READ (UNIT=5,FMT=8050,END=99,ERR=99) sliceplot%iplot,input%score,sliceplot%plpot
WRITE (6,9240) sliceplot%iplot,input%score,sliceplot%plpot,band
READ (UNIT=5,FMT=8050,END=99,ERR=99) ldum,ldum2,ldum2
WRITE (6,9240) ldum,ldum2,ldum2,band
sliceplot%iplot=MERGE(1,0,ldum)
!
993 READ (UNIT=5,FMT='(i3,2f10.6,6x,i3,8x,l1)',END=99,ERR=99)&
& sliceplot%kk,sliceplot%e1s,sliceplot%e2s,sliceplot%nnne,input%pallst
......@@ -879,7 +881,7 @@
9120 FORMAT ('vchk=',l1,',cdinf=',l1,',pot8=',l1,',gw=',i1,&
& ',numbands=',i4)
WRITE (5,9130) 0,.false.,input%l_f,input%eonly
9130 FORMAT ('lpr=',i1,',form66=',l1,',l_f=',l1,',eonly=',l1)
9130 FORMAT ('lpr=',i1,',form66=',l1,',l_f=',l1,',eonly=',l1,',eig66',l1)
IF ( l_hyb ) THEN
WRITE (chntype,'(i3)') 2*atoms%ntype
chform = '('//chntype//'i3 )'
......@@ -930,7 +932,7 @@
WRITE (5,*)
END IF
band = .false.
WRITE (5,9240) sliceplot%iplot,input%score,sliceplot%plpot,band
WRITE (5,9240) ldum,ldum2,ldum2,band
9240 FORMAT ('iplot=',l1,',score=',l1,',plpot=',l1,',band=',l1)
WRITE (5,9250) sliceplot%kk,sliceplot%e1s,sliceplot%e2s,sliceplot%nnne,input%pallst
9250 FORMAT (i3,2f10.6,',nnne=',i3,',pallst=',l1)
......
......@@ -679,9 +679,9 @@ SUBROUTINE w_inpXML(&
395 FORMAT(' <unfoldingBand unfoldBand="',l1,'" supercellX="',i0,'" supercellY="',i0,'" supercellZ="',i0,'"/>')
WRITE (fileNum,395) banddos%unfoldband, banddos%s_cell_x, banddos%s_cell_y, banddos%s_cell_z
! <plotting iplot="F" score="F" plplot="F"/>
400 FORMAT(' <plotting iplot="',l1,'" score="',l1,'" plplot="',l1,'"/>')
WRITE (fileNum,400) sliceplot%iplot,input%score,sliceplot%plpot
! <plotting iplot="0">
400 FORMAT(' <plotting iplot="',i0,'"/>')
WRITE (fileNum,400) sliceplot%iplot
! <chargeDensitySlicing numkpt="0" minEigenval="0.000000" maxEigenval="0.000000" nnne="0" pallst="F"/>
410 FORMAT(' <chargeDensitySlicing numkpt="',i0,'" minEigenval="',f0.8,'" maxEigenval="',f0.8,'" nnne="',i0,'" pallst="',l1,'"/>')
......
......@@ -580,9 +580,7 @@
</xsd:complexType>
<xsd:complexType name="PlottingType">
<xsd:attribute default="F" name="iplot" type="FleurBool" use="optional"/>
<xsd:attribute default="F" name="score" type="FleurBool" use="optional"/>
<xsd:attribute default="F" name="plplot" type="FleurBool" use="optional"/>
<xsd:attribute default="0" name="iplot" type="xsd:nonNegativeInteger" use="optional"/>
</xsd:complexType>
<xsd:complexType name="ChargeDensitySlicingType">
......
......@@ -820,9 +820,7 @@
</xsd:complexType>
<xsd:complexType name="PlottingType">
<xsd:attribute default="F" name="iplot" type="FleurBool" use="optional"/>
<xsd:attribute default="F" name="score" type="FleurBool" use="optional"/>
<xsd:attribute default="F" name="plplot" type="FleurBool" use="optional"/>
<xsd:attribute default="0" name="iplot" type="xsd:nonNegativeInteger" use="optional"/>
</xsd:complexType>
<xsd:complexType name="ChargeDensitySlicingType">
......
......@@ -3997,4 +3997,3 @@ unsigned char FleurInputSchema_xsd[] = {
0x61, 0x3e, 0x0a
};
unsigned int FleurInputSchema_xsd_len = 47943;
......@@ -64,6 +64,7 @@ CONTAINS
USE m_dwigner
USE m_ylm
USE m_metagga
USE m_plot
#ifdef CPP_MPI
USE m_mpi_bc_potden
#endif
......@@ -96,7 +97,7 @@ CONTAINS
TYPE(t_mpi) :: mpi
TYPE(t_coreSpecInput) :: coreSpecInput
TYPE(t_wann) :: wann
TYPE(t_potden) :: vTot, vx, vCoul, vTemp
TYPE(t_potden) :: vTot, vx, vCoul, vTemp, vxcForPlotting
TYPE(t_potden) :: inDen, outDen, EnergyDen
TYPE(t_potden), dimension(3):: xcB
CLASS(t_xcpot), ALLOCATABLE :: xcpot
......@@ -153,6 +154,11 @@ CONTAINS
CALL writeDensity(stars,vacuum,atoms,cell,sphhar,input,sym,oneD,archiveType,CDN_INPUT_DEN_const,&
0,-1.0,results%ef,.FALSE.,inDen)
END IF
IF ((sliceplot%iplot.NE.0 ).AND.(mpi%irank==0) ) THEN
CALL makeplots(mpi,sym,stars,vacuum,atoms,sphhar,input,cell,oneD,noco,sliceplot,inDen,PLOT_INPDEN)
END IF
! Initialize and load inDen density (end)
! Initialize potentials (start)
......@@ -165,7 +171,7 @@ CONTAINS
! Open/allocate eigenvector storage (start)
l_real=sym%invs.AND..NOT.noco%l_noco
eig_id=open_eig(mpi%mpi_comm,DIMENSION%nbasfcn,DIMENSION%neigd,kpts%nkpt,input%jspins,&
noco%l_noco,.TRUE.,l_real,noco%l_soc,.FALSE.,mpi%n_size)
noco%l_noco,.NOT.INPUT%eig66(1),l_real,noco%l_soc,INPUT%eig66(1),mpi%n_size)
#ifdef CPP_CHASE
CALL init_chase(mpi,dimension,input,atoms,kpts,noco,sym%invs.AND..NOT.noco%l_noco)
......@@ -222,8 +228,9 @@ CONTAINS
IF(input%l_rdmft) THEN
CALL open_hybrid_io1(DIMENSION,sym%invs)
END IF
CALL reset_eig(eig_id,noco%l_soc) ! This has to be placed after the calc_hybrid call but before eigen
IF(.not.input%eig66(1))THEN
CALL reset_eig(eig_id,noco%l_soc) ! This has to be placed after the calc_hybrid call but before eigen
END IF
!$ call omp_set_num_threads(num_threads)
!#endif
......@@ -244,6 +251,13 @@ CONTAINS
obsolete,cell,oneD,sliceplot,mpi,results,noco,EnergyDen,inDen,vTot,vx,vCoul,xcB)
CALL timestop("generation of potential")
IF ((sliceplot%iplot.NE.0 ).AND.(mpi%irank==0) ) THEN
CALL makeplots(mpi,sym,stars,vacuum,atoms,sphhar,input,cell,oneD,noco,sliceplot,vTot,PLOT_POT_TOT)
! CALL makeplots(mpi,sym,stars,vacuum,atoms,sphhar,input,cell,oneD,noco,sliceplot,vCoul,PLOT_POT_COU)
! CALL subPotDen(vxcForPlotting,vTot,vCoul)
! CALL makeplots(mpi,sym,stars,vacuum,atoms,sphhar,input,cell,oneD,noco,sliceplot,vxcForPlotting,PLOT_POT_VXC
END IF
#ifdef CPP_MPI
CALL MPI_BARRIER(mpi%mpi_comm,ierr)
#endif
......@@ -257,8 +271,10 @@ CONTAINS
CALL timestart("Updating energy parameters")
CALL enpara%update(mpi,atoms,vacuum,input,vToT)
CALL timestop("Updating energy parameters")
CALL eigen(mpi,stars,sphhar,atoms,xcpot,sym,kpts,DIMENSION,vacuum,input,&
IF(.not.input%eig66(1))THEN
CALL eigen(mpi,stars,sphhar,atoms,xcpot,sym,kpts,DIMENSION,vacuum,input,&
cell,enpara,banddos,noco,oneD,hybrid,iter,eig_id,results,inDen,vTemp,vx)
ENDIF
vTot%mmpMat = vTemp%mmpMat
!!$ eig_idList(pc) = eig_id
CALL timestop("eigen")
......@@ -281,7 +297,7 @@ CONTAINS
#endif
! WRITE(6,fmt='(A)') 'Starting 2nd variation ...'
IF (noco%l_soc.AND..NOT.noco%l_noco) &
IF (noco%l_soc.AND..NOT.noco%l_noco.AND..NOT.INPUT%eig66(1)) &
CALL eigenso(eig_id,mpi,DIMENSION,stars,vacuum,atoms,sphhar,&
obsolete,sym,cell,noco,input,kpts, oneD,vTot,enpara,results)
CALL timestop("gen. of hamil. and diag. (total)")
......@@ -365,6 +381,11 @@ CONTAINS
dimension,kpts,atoms,sphhar,stars,sym,&
enpara,cell,noco,vTot,results,oneD,coreSpecInput,&
archiveType,xcpot,outDen,EnergyDen)
IF ((sliceplot%iplot.NE.0 ).AND.(mpi%irank==0) ) THEN
CALL makeplots(mpi,sym,stars,vacuum,atoms,sphhar,input,cell,oneD,noco,sliceplot,outDen,PLOT_OUTDEN_Y_CORE)
! CALL makeplots(mpi,sym,stars,vacuum,atoms,sphhar,input,cell,oneD,noco,sliceplot,outDen,PLOT_OUTDEN_N_CORE)
END IF
IF (input%l_rdmft) THEN
SELECT TYPE(xcpot)
......@@ -467,6 +488,12 @@ CONTAINS
IF (isCurrentXMLElement("iteration")) CALL closeXMLElement('iteration')
END IF
!Break SCF loop if Plots were generated in ongoing run (iplot=/=0).
IF(sliceplot%iplot.NE.0) THEN
CALL juDFT_end("Stopped self consistency loop after plots have been generated.")
END IF
END DO scfloop ! DO WHILE (l_cont)
CALL add_usage_data("Iterations",iter)
......
......@@ -36,7 +36,8 @@
USE m_fleur_init_old
USE m_types_xcpot_inbuild
USE m_mpi_bc_xcpot
USE m_wann_read_inp
#ifdef CPP_MPI
USE m_mpi_bc_all, ONLY : mpi_bc_all
#ifndef CPP_OLDINTEL
......@@ -89,7 +90,8 @@
REAL :: a1(3),a2(3),a3(3)
REAL :: dtild, phi_add
LOGICAL :: l_found, l_kpts, l_exist
LOGICAL :: l_wann_inp
#ifdef CPP_MPI
INCLUDE 'mpif.h'
INTEGER ierr(3)
......@@ -114,7 +116,7 @@
#endif
!call juDFT_check_para()
CALL field%init(input)
input%eig66(1)=.FALSE.
input%gw = -1
input%gw_neigd = 0
!-t3e
......@@ -154,7 +156,7 @@
kpts%ntet = 1
kpts%numSpecialPoints = 1
sliceplot%iplot=.FALSE.
sliceplot%iplot=0
sliceplot%kk = 0
sliceplot%e1s = 0.0
sliceplot%e2s = 0.0
......@@ -533,5 +535,12 @@
!new check mode will only run the init-part of FLEUR
IF (judft_was_argument("-check")) CALL judft_end("Check-mode done",mpi%irank)
INQUIRE (file='wann_inp',exist=l_wann_inp)
input%l_wann = input%l_wann.OR.l_wann_inp
IF(input%l_wann) THEN
CALL wann_read_inp(DIMENSION,input,noco,(mpi%irank.EQ.0),wann)
END IF
END SUBROUTINE fleur_init
END MODULE m_fleur_init
......@@ -94,29 +94,19 @@ CONTAINS
! ..
it = 1
IF (sliceplot%iplot .AND. (mpi%irank==0) ) THEN
IF (noco%l_noco) THEN
CALL pldngen(mpi,sym,stars,atoms,sphhar,vacuum,&
cell,input,noco,oneD,sliceplot)
ENDIF
ENDIF
! IF ((sliceplot%iplot.NE.0 ).AND. (mpi%irank==0) ) THEN
! IF (noco%l_noco) THEN
! CALL pldngen(mpi,sym,stars,atoms,sphhar,vacuum,&
! cell,input,noco,oneD,sliceplot)
! ENDIF
! ENDIF
IF (mpi%irank == 0) THEN
IF (sliceplot%plpot) input%score = .FALSE.
IF (sliceplot%iplot) THEN
CALL timestart("Plotting")
IF (input%strho) CALL juDFT_error("strho = T and iplot=T",calledby = "optional")
CALL plotdop(oneD,dimension,stars,vacuum,sphhar,atoms,&
input,sym,cell,sliceplot,noco)
CALL timestop("Plotting")
END IF
ENDIF ! mpi%irank == 0
!
! --->generate starting charge density
!
strho=input%strho
IF (.NOT.(strho.OR.sliceplot%iplot)) THEN
IF (.NOT.(strho.OR.(sliceplot%iplot.NE.0))) THEN
archiveType = CDN_ARCHIVE_TYPE_CDN1_const
IF (noco%l_noco) THEN
archiveType = CDN_ARCHIVE_TYPE_NOCO_const
......@@ -168,7 +158,6 @@ CONTAINS
ENDIF ! mpi%irank == 0
IF (sliceplot%iplot) CALL juDFT_end("density plot o.k.",mpi%irank)
IF (input%strho) CALL juDFT_end("starting density generated",mpi%irank)
IF (input%swsp) CALL juDFT_end("spin polarised density generated",mpi%irank)
IF (input%lflip) CALL juDFT_end("magnetic moments flipped",mpi%irank)
......
......@@ -38,9 +38,9 @@ CONTAINS
INTEGER n
REAL rdum
! .. Local Arrays ..
INTEGER i(42),ierr(3)
INTEGER i(43),ierr(3)
REAL r(34)
LOGICAL l(46)
LOGICAL l(45)
! ..
! .. External Subroutines..
#ifdef CPP_MPI
......@@ -57,7 +57,7 @@ CONTAINS
i(27)=vacuum%nstars ; i(28)=vacuum%nstm ; i(29)=oneD%odd%nq2 ; i(30)=oneD%odd%nop
i(31)=input%gw ; i(32)=input%gw_neigd ; i(33)=hybrid%ewaldlambda ; i(34)=hybrid%lexp
i(35)=hybrid%bands1 ; i(36)=input%maxiter ; i(37)=input%imix ; i(38)=banddos%orbCompAtom