diff --git a/eigen/hlomat.F90 b/eigen/hlomat.F90 index 5af5375c544171a945b968a538946da20140f440..7bf1e2bd9875be24e9ba74f03c1d2961e45cb079 100644 --- a/eigen/hlomat.F90 +++ b/eigen/hlomat.F90 @@ -125,7 +125,7 @@ CONTAINS END DO !+t3e DO nkvec = 1,invsfct* (2*l+1) - locol= lapw%nv(iintsp)+lapw%index_lo(lo,ntyp)+nkvec !this is the column of the matrix + locol= lapw%nv(iintsp)+lapw%index_lo(lo,na)+nkvec !this is the column of the matrix IF (MOD(locol-1,mpi%n_size).EQ.mpi%n_rank) THEN locol=(locol-1)/mpi%n_size+1 !this is the column in local storage !-t3e @@ -172,7 +172,7 @@ CONTAINS !---> calculate the hamiltonian matrix elements with other !---> local orbitals at the same atom and with itself DO nkvec = 1,invsfct* (2*l+1) - locol = lapw%nv(iintsp)+lapw%index_lo(lo,ntyp)+nkvec !this is the column of the matrix + locol = lapw%nv(iintsp)+lapw%index_lo(lo,na)+nkvec !this is the column of the matrix IF (MOD(locol-1,mpi%n_size).EQ.mpi%n_rank) THEN locol=(locol-1)/mpi%n_size+1 !this is the column in local storage !-t3e @@ -181,7 +181,7 @@ CONTAINS DO lop = 1, (lo-1) lp = atoms%llo(lop,ntyp) DO nkvecp = 1,invsfct* (2*lp+1) - lorow=lapw%nv(jintsp)+lapw%index_lo(lop,ntyp)+nkvecp + lorow=lapw%nv(jintsp)+lapw%index_lo(lop,na)+nkvecp DO m = -l,l lm = l* (l+1) + m DO mp = -lp,lp @@ -239,7 +239,7 @@ CONTAINS !---> calculate the hamiltonian matrix elements of one local !---> orbital with itself DO nkvecp = 1,nkvec - lorow=lapw%nv(jintsp)+lapw%index_lo(lop,ntyp)+nkvecp + lorow=lapw%nv(jintsp)+lapw%index_lo(lop,na)+nkvecp DO m = -l,l lm = l* (l+1) + m DO mp = -l,l diff --git a/eigen/slomat.F90 b/eigen/slomat.F90 index 5f5ef73d62df634f73b23aa14833bf0117aed1e8..6d8d32c92f9e1cc22dccb14b0c75384bb171e9e5 100644 --- a/eigen/slomat.F90 +++ b/eigen/slomat.F90 @@ -82,7 +82,7 @@ CONTAINS clo1(lo)* clo1(lo) ) DO nkvec = 1,invsfct* (2*l+1) !Each LO can have several functions !+t3e - locol = lapw%nv(iintsp)+lapw%index_lo(lo,ntyp)+nkvec !this is the column of the matrix + locol = lapw%nv(iintsp)+lapw%index_lo(lo,na)+nkvec !this is the column of the matrix IF (MOD(locol-1,mpi%n_size).EQ.mpi%n_rank) THEN locol=(locol-1)/mpi%n_size+1 !this is the column in local storage !-t3e @@ -119,7 +119,7 @@ CONTAINS clo1(lo)*ud%uloulopn(lop,lo,ntyp,isp))) DO nkvecp = 1,invsfct* (2*lp+1) kp = lapw%kvec(nkvecp,lop,ntyp) - lorow=lapw%nv(jintsp)+lapw%index_lo(lop,ntyp)+nkvecp + lorow=lapw%nv(jintsp)+lapw%index_lo(lop,na)+nkvecp dotp = dot_PRODUCT(lapw%gk(:,k,iintsp),lapw%gk(:,kp,jintsp)) IF (smat%l_real) THEN smat%data_r(lorow,locol) =smat%data_r(lorow,locol)+chi*invsfct*fact3*legpol(l,dotp)* & @@ -136,7 +136,7 @@ CONTAINS !---> orbital with itself DO nkvecp = 1,nkvec kp = lapw%kvec(nkvecp,lo,ntyp) - lorow=lapw%nv(jintsp)+lapw%index_lo(lo,ntyp)+nkvecp + lorow=lapw%nv(jintsp)+lapw%index_lo(lo,na)+nkvecp dotp = dot_PRODUCT(lapw%gk(:,k,iintsp),lapw%gk(:,kp,jintsp)) IF (smat%l_real) THEN smat%data_r(lorow,locol) = smat%data_r(lorow,locol) + chi*invsfct*fact1*legpol(l,dotp) *& diff --git a/io/eig66_hdf.F90 b/io/eig66_hdf.F90 index 8f84c040ad807696e03b7632318299224581d932..45aae412eadc38c2b0ada1f6a5df036689ddbfa9 100644 --- a/io/eig66_hdf.F90 +++ b/io/eig66_hdf.F90 @@ -474,7 +474,6 @@ CONTAINS IF (PRESENT(nmat)) CALL io_write_integer0(& & d%nmatsetid,(/nk,jspin/),(/1,1/),nmat) - ENDIF ! !write eigenvalues ! @@ -608,11 +607,8 @@ CONTAINS ENDIF - IF (PRESENT(nv)) nv=n1 - ELSE - IF (PRESENT(nv)) CALL io_read_integer0(d%nvsetid,(/nk,jspin/),(/1,1/),nv) + IF (PRESENT(nv)) CALL io_read_integer0(d%nvsetid,(/nk,jspin/),(/1,1/),nv) - ENDIF IF (PRESENT(nmat)) & & CALL io_read_integer0(d%nmatsetid,(/nk,jspin/),(/1,1/),nmat) IF (PRESENT(el)) CALL io_read_real2(d%esetid,(/1,1,nk,jspin/),&