From 69225e677b1327a8cbd172c12fb8e9c2c83b2ec1 Mon Sep 17 00:00:00 2001 From: William Dawson Date: Mon, 22 Jan 2024 18:29:42 +0900 Subject: [PATCH] Fix partial charge in the dense eigensolver --- Source/Fortran/FermiOperatorModule.F90 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Source/Fortran/FermiOperatorModule.F90 b/Source/Fortran/FermiOperatorModule.F90 index 869de65c..b43d6f0b 100644 --- a/Source/Fortran/FermiOperatorModule.F90 +++ b/Source/Fortran/FermiOperatorModule.F90 @@ -156,7 +156,7 @@ SUBROUTINE ComputeDenseFOE(H, ISQ, trace, K, inv_temp_in, & energy_value = energy_value + tlist%DATA(II)%point_value tlist%DATA(II)%point_value = 1.0_NTREAL ELSE IF (tlist%DATA(II)%index_column .EQ. CEILING(trace)) THEN - occ_temp = CEILING(trace) - trace + occ_temp = trace - FLOOR(trace) energy_value = energy_value + & & occ_temp * tlist%DATA(II)%point_value tlist%DATA(II)%point_value = occ_temp