Skip to content

Commit

Permalink
fix a bug in KUGWAC that doesn't generate proper GDF when using LDA/G…
Browse files Browse the repository at this point in the history
…GA functionals
  • Loading branch information
Jiachen Li authored and sunqm committed Nov 24, 2023
1 parent ad72f25 commit ad0f560
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions pyscf/pbc/gw/kugw_ac.py
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,9 @@ def kernel(gw, mo_energy, mo_coeff, orbs=None,
uhf = scf.KUHF(gw.mol, gw.kpts, exxdiv=exxdiv)
uhf.with_df = gw.with_df
uhf.with_df._cderi = gw.with_df._cderi
if uhf.with_df._j_only:
logger.debug(gw, 'Rebuild CDERI for exchange integrals')
uhf.with_df.build(j_only=False)
vk = uhf.get_veff(gw.mol,dm_kpts=dm)
vj = uhf.get_j(gw.mol,dm_kpts=dm)
vk[0] = vk[0] - (vj[0] + vj[1])
Expand Down

0 comments on commit ad0f560

Please sign in to comment.