Commit ef8fa644 authored by Gregor Michalicek's avatar Gregor Michalicek
Browse files

Fix vx in vgen/vgen_xcpot.F90

Outside of vgen/vgen_xcpot.F90 this potential contribution is used such
that it is assumed that every entry of the interstitial part is divided
by the number of G vectors contributing to the respective stars.

This fixes an issue in the hybrid functionals calculation. Also for
GW it is needed in this form.
parent 6f8a41aa
......@@ -58,7 +58,7 @@ CONTAINS
! Local type instances
TYPE(t_potden) :: workDen,exc,veff
! Local Scalars
INTEGER ifftd,ifftd2,ifftxc3d,ispin
INTEGER ifftd,ifftd2,ifftxc3d,ispin,i
#ifdef CPP_MPI
include 'mpif.h'
integer:: ierr
......@@ -173,6 +173,13 @@ CONTAINS
exc%mt = exc%mt - xcpot%get_exchange_weight() * exc%mt
DO ispin = 1, input%jspins
DO i = 1, stars%ng3
vx%pw(i,ispin) = vx%pw(i,ispin) / stars%nstr(i)
vx%pw_w(i,ispin) = vx%pw_w(i,ispin) / stars%nstr(i)
results%te_veff = 0.0
DO ispin = 1, input%jspins
WRITE (6,FMT=8050) ispin
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