From 83f30e67ffc1d28290eda2b9242449adb8d2e80d Mon Sep 17 00:00:00 2001 From: "hung.pham" Date: Wed, 6 Dec 2023 06:33:14 +0800 Subject: [PATCH] Bug fix in interactive solver for non-canonical UMP2 --- pyscf/mp/ump2.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/pyscf/mp/ump2.py b/pyscf/mp/ump2.py index 5257f3f194..adbfc3b278 100644 --- a/pyscf/mp/ump2.py +++ b/pyscf/mp/ump2.py @@ -154,9 +154,9 @@ def update_amps(mp, t2, eris): eris_ovov = numpy.asarray(eris.ovov).reshape(nocca,nvira,nocca,nvira).conj() * .5 eris_OVOV = numpy.asarray(eris.OVOV).reshape(noccb,nvirb,noccb,nvirb).conj() * .5 eris_ovOV = numpy.asarray(eris.ovOV).reshape(nocca,nvira,noccb,nvirb).conj().copy() - u2aa = eris_ovov.transpose(0,2,1,3) - eris_ovov.transpose(0,2,3,1) - u2bb = eris_OVOV.transpose(0,2,1,3) - eris_OVOV.transpose(0,2,3,1) - u2ab = eris_ovOV.transpose(0,2,1,3) + u2aa += eris_ovov.transpose(0,2,1,3) - eris_ovov.transpose(0,2,3,1) + u2bb += eris_OVOV.transpose(0,2,1,3) - eris_OVOV.transpose(0,2,3,1) + u2ab += eris_ovOV.transpose(0,2,1,3) u2aa = u2aa + u2aa.transpose(1,0,3,2) u2bb = u2bb + u2bb.transpose(1,0,3,2)