mirror of https://gitlab.com/QEF/q-e.git
Hidden dependency of incdrhoscf.f90 on dpsi (passed through a module) is
made explicit passing it as an argument. Calling routines modified accordingly. git-svn-id: http://qeforge.qe-forge.org/svn/q-e/trunk/espresso@7087 c92efa57-630b-4861-b058-cf58834340f0
This commit is contained in:
parent
88e1ea34a2
commit
1ec328bfe4
|
@ -6,7 +6,7 @@
|
|||
! or http://www.gnu.org/copyleft/gpl.txt .
|
||||
!
|
||||
!-----------------------------------------------------------------------
|
||||
subroutine incdrhoscf (drhoscf, weight, ik, dbecsum)
|
||||
subroutine incdrhoscf (drhoscf, weight, ik, dbecsum, dpsi)
|
||||
!-----------------------------------------------------------------------
|
||||
!
|
||||
! This routine computes the change of the charge density due to the
|
||||
|
@ -20,27 +20,27 @@ subroutine incdrhoscf (drhoscf, weight, ik, dbecsum)
|
|||
USE fft_base, ONLY: dffts
|
||||
USE fft_interfaces, ONLY: invfft
|
||||
USE gsmooth, ONLY : nrxxs, nls
|
||||
USE wvfct, ONLY : npw, igk
|
||||
USE wvfct, ONLY : npw, igk, npwx, nbnd
|
||||
USE uspp_param,ONLY: nhm
|
||||
USE wavefunctions_module, ONLY: evc
|
||||
USE eqv, ONLY : dpsi
|
||||
USE qpoint, ONLY : npwq, igkq, ikks
|
||||
USE control_ph, ONLY : nbnd_occ
|
||||
|
||||
implicit none
|
||||
|
||||
! I/O variables
|
||||
integer :: ik
|
||||
! input: the k point
|
||||
|
||||
real(DP) :: weight
|
||||
! input: the weight of the k point
|
||||
complex(DP) :: dpsi (npwx,nbnd)
|
||||
! input: the perturbed wfc for the given k point
|
||||
complex(DP) :: drhoscf (nrxxs), dbecsum (nhm*(nhm+1)/2,nat)
|
||||
! output: the change of the charge densit
|
||||
! inp/out: the accumulated dbec
|
||||
!
|
||||
!
|
||||
! here the local variable
|
||||
!
|
||||
|
||||
real(DP) :: wgt
|
||||
! the effective weight of the k point
|
||||
|
||||
|
|
|
@ -265,7 +265,7 @@ subroutine solve_e
|
|||
dbecsum_nc(1,1,1,1,ipol))
|
||||
ELSE
|
||||
call incdrhoscf (dvscfout(1,current_spin,ipol), wk(ik), &
|
||||
ik, dbecsum(1,1,current_spin,ipol))
|
||||
ik, dbecsum(1,1,current_spin,ipol), dpsi)
|
||||
ENDIF
|
||||
enddo ! on polarizations
|
||||
enddo ! on k points
|
||||
|
|
|
@ -166,7 +166,7 @@ subroutine solve_e2
|
|||
!
|
||||
weight = wk (ik)
|
||||
call incdrhoscf (dvscfout (1,1,ipol), weight, ik, &
|
||||
dbecsum (1, 1))
|
||||
dbecsum (1, 1), dpsi)
|
||||
enddo ! on perturbations
|
||||
enddo ! on k points
|
||||
#ifdef __PARA
|
||||
|
|
|
@ -286,7 +286,7 @@ subroutine solve_e_fpol ( iw )
|
|||
! calculates dvscf, sum over k => dvscf_q_ipert
|
||||
!
|
||||
call incdrhoscf (dvscfout(1,current_spin,ipol), wk(ik), &
|
||||
ik, dbecsum(1,1,current_spin,ipol))
|
||||
ik, dbecsum(1,1,current_spin,ipol), dpsi)
|
||||
enddo ! on polarizations
|
||||
enddo ! on k points
|
||||
#ifdef __PARA
|
||||
|
|
|
@ -354,7 +354,7 @@ SUBROUTINE solve_linter (irr, imode0, npe, drhoscf)
|
|||
dbecsum_nc(1,1,1,1,ipert))
|
||||
ELSE
|
||||
call incdrhoscf (drhoscf(1,current_spin,ipert), weight, ik, &
|
||||
dbecsum(1,1,current_spin,ipert))
|
||||
dbecsum(1,1,current_spin,ipert), dpsi)
|
||||
END IF
|
||||
! on perturbations
|
||||
enddo
|
||||
|
|
|
@ -99,7 +99,8 @@ subroutine zstar_eu_us
|
|||
call incdrhoscf_nc (dvscf(1,1,jpol),weight,ik, &
|
||||
dbecsum_nc(1,1,1,1,jpol))
|
||||
else
|
||||
call incdrhoscf (dvscf(1,current_spin,jpol),weight,ik, dbecsum(1,1,current_spin,jpol))
|
||||
call incdrhoscf (dvscf(1,current_spin,jpol),weight,ik, &
|
||||
dbecsum(1,1,current_spin,jpol), dpsi)
|
||||
endif
|
||||
end do
|
||||
end do
|
||||
|
|
Loading…
Reference in New Issue