Commit ed20b3ac authored by Gregor Michalicek's avatar Gregor Michalicek

Fix io/writeBasis.F90 for maultiple identical k points

parent 09dd6836
......@@ -115,7 +115,7 @@ SUBROUTINE writeBasis(input,noco,kpts,atoms,sym,cell,enpara,vTot,vCoul,vx,mpi,DI
INTEGER :: lmn, na,lm,n,nn, m
complex,parameter :: img=(0.,1.)
LOGICAL l_zref,l_real
LOGICAL l_zref,l_real, link_exists
INTEGER jsp,nk,l,itype
INTEGER numbands, nbasfcn, ndbands !ndbands number of bands without highest (degenerate)
......@@ -316,6 +316,8 @@ SUBROUTINE writeBasis(input,noco,kpts,atoms,sym,cell,enpara,vTot,vCoul,vx,mpi,DI
CALL lapw%init(input,noco,kpts,atoms,sym,nk,cell,l_zref)
!write(kpt_name , '(2a,i0)') TRIM(ADJUSTL(jsp_name)),'/kpt_',nk
write(kpt_name , '(2a,f12.10,a,f12.10,a,f12.10)') TRIM(ADJUSTL(jsp_name)),'/kpt_',kpts%bk(1,nk),',',kpts%bk(2,nk),',',kpts%bk(3,nk)
CALL h5oexists_by_name_f(fileID, TRIM(ADJUSTL(kpt_name)), link_exists, hdfError)
IF (link_exists) CYCLE
CALL h5gcreate_f(fileID, TRIM(ADJUSTL(kpt_name)), kptGroupID, hdfError)
!--------------------enter output gvec etc here--------------------
CALL io_write_attint0(kptGroupID,'nv',lapw%nv(jsp))
......@@ -447,6 +449,8 @@ SUBROUTINE writeBasis(input,noco,kpts,atoms,sym,cell,enpara,vTot,vCoul,vx,mpi,DI
CALL lapw%init(input,noco,kpts,atoms,sym,nk,cell,l_zref)
!write(kpt_name , '(2a,i0)') TRIM(ADJUSTL(jsp_name)),'/kpt_',nk
write(kpt_name , '(2a,f12.10,a,f12.10,a,f12.10)') TRIM(ADJUSTL(jsp_name)),'/kpt_',kpts%bk(1,nk),',',kpts%bk(2,nk),',',kpts%bk(3,nk)
CALL h5oexists_by_name_f(fileID, TRIM(ADJUSTL(kpt_name)), link_exists, hdfError)
IF (link_exists) CYCLE
CALL h5gcreate_f(fileID, TRIM(ADJUSTL(kpt_name)), kptGroupID, hdfError)
!--------------------abcoff, zmat, eig output here-------------------
!,results%neig(nk,jsp),results%eig(:,nk,jsp)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment