From bd44ad4ffb2e9689cd5eef8bfef34ee43693f081 Mon Sep 17 00:00:00 2001 From: Pierre-Francois Loos Date: Wed, 8 May 2019 08:59:26 +0200 Subject: [PATCH] correcting bug in read_integrals --- input/basis | 192 +++++-------------------------- input/methods | 8 +- input/molecule | 4 +- input/weight | 34 ++++-- src/IntPak/Makefile | 2 +- src/QuAcK/QuAcK.f90 | 2 +- src/utils/read_integrals.f90 | 11 +- src/utils/read_integrals_sph.f90 | 10 +- 8 files changed, 75 insertions(+), 188 deletions(-) diff --git a/input/basis b/input/basis index 8a72e6e..e220e53 100644 --- a/input/basis +++ b/input/basis @@ -1,163 +1,29 @@ -1 81 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 -S 1 1.00 - 1.0000000 1.0000000 +1 6 +S 8 1.00 + 2940.0000000 0.0006800 + 441.2000000 0.0052360 + 100.5000000 0.0266060 + 28.4300000 0.0999930 + 9.1690000 0.2697020 + 3.1960000 0.4514690 + 1.1590000 0.2950740 + 0.1811000 0.0125870 +S 8 1.00 + 2940.0000000 -0.0001230 + 441.2000000 -0.0009660 + 100.5000000 -0.0048310 + 28.4300000 -0.0193140 + 9.1690000 -0.0532800 + 3.1960000 -0.1207230 + 1.1590000 -0.1334350 + 0.1811000 0.5307670 +S 1 1.00 + 0.0589000 1.0000000 +P 3 1.00 + 3.6190000 0.0291110 + 0.7110000 0.1693650 + 0.1951000 0.5134580 +P 1 1.00 + 0.0601800 1.0000000 +D 1 1.00 + 0.2380000 1.0000000 diff --git a/input/methods b/input/methods index ca18179..3e511cd 100644 --- a/input/methods +++ b/input/methods @@ -1,14 +1,14 @@ # RHF UHF MOM T F F # MP2 MP3 MP2-F12 - T F F + F F F # CCD CCSD CCSD(T) F F F # CIS TDHF ADC - T T F + F F F # GF2 GF3 - T F + F F # G0W0 evGW qsGW - T T F + F F F # MCMP2 F diff --git a/input/molecule b/input/molecule index 50795c8..6a6f6d1 100644 --- a/input/molecule +++ b/input/molecule @@ -1,4 +1,4 @@ # nAt nEla nElb nCore nRyd - 1 16 16 0 0 + 1 2 2 0 0 # Znuc x y z - X 0.0 0.0 0.0 + Be 0.0 0.0 0.0 diff --git a/input/weight b/input/weight index b9ca7b5..e220e53 100644 --- a/input/weight +++ b/input/weight @@ -1,9 +1,29 @@ -1 3 -S 3 1.00 - 38.3600000 0.0238090 - 5.7700000 0.1548910 - 1.2400000 0.4699870 +1 6 +S 8 1.00 + 2940.0000000 0.0006800 + 441.2000000 0.0052360 + 100.5000000 0.0266060 + 28.4300000 0.0999930 + 9.1690000 0.2697020 + 3.1960000 0.4514690 + 1.1590000 0.2950740 + 0.1811000 0.0125870 +S 8 1.00 + 2940.0000000 -0.0001230 + 441.2000000 -0.0009660 + 100.5000000 -0.0048310 + 28.4300000 -0.0193140 + 9.1690000 -0.0532800 + 3.1960000 -0.1207230 + 1.1590000 -0.1334350 + 0.1811000 0.5307670 S 1 1.00 - 0.2976000 1.0000000 + 0.0589000 1.0000000 +P 3 1.00 + 3.6190000 0.0291110 + 0.7110000 0.1693650 + 0.1951000 0.5134580 P 1 1.00 - 1.2750000 1.0000000 + 0.0601800 1.0000000 +D 1 1.00 + 0.2380000 1.0000000 diff --git a/src/IntPak/Makefile b/src/IntPak/Makefile index 96db0e9..6b0ec1d 100644 --- a/src/IntPak/Makefile +++ b/src/IntPak/Makefile @@ -6,7 +6,7 @@ FC = gfortran -I$(IDIR) ifeq ($(DEBUG),1) FFLAGS = -Wall -g -msse4.2 -fcheck=all -Waliasing -Wampersand -Wconversion -Wsurprising -Wintrinsics-std -Wno-tabs -Wintrinsic-shadow -Wline-truncation -Wreal-q-constant else -FFLAGS = -Wall -Wno-unused -Wno-unused-dummy-argument -O2 +FFLAGS = -Wall -Wno-unused -Wno-unused-dummy-argument -O3 endif LIBS = ~/Dropbox/quack/lib/*.a diff --git a/src/QuAcK/QuAcK.f90 b/src/QuAcK/QuAcK.f90 index 310f82c..3bfdb7d 100644 --- a/src/QuAcK/QuAcK.f90 +++ b/src/QuAcK/QuAcK.f90 @@ -90,7 +90,7 @@ program QuAcK ! Spherium calculation? - doSph = .true. + doSph = .false. call cpu_time(start_QuAcK) diff --git a/src/utils/read_integrals.f90 b/src/utils/read_integrals.f90 index c62f78f..e0f6dd0 100644 --- a/src/utils/read_integrals.f90 +++ b/src/utils/read_integrals.f90 @@ -36,7 +36,7 @@ subroutine read_integrals(nEl,nBas,S,T,V,Hc,G) ! Read overlap integrals - S = 0d0 + S(:,:) = 0d0 do read(8,*,end=8) mu,nu,Ov S(mu,nu) = Ov @@ -45,15 +45,16 @@ subroutine read_integrals(nEl,nBas,S,T,V,Hc,G) ! Read kinetic integrals - T = 0d0 + T(:,:) = 0d0 do read(9,*,end=9) mu,nu,Kin + T(mu,nu) = Kin enddo 9 close(unit=9) ! Read nuclear integrals - V = 0d0 + V(:,:) = 0d0 do read(10,*,end=10) mu,nu,Nuc V(mu,nu) = Nuc @@ -62,11 +63,11 @@ subroutine read_integrals(nEl,nBas,S,T,V,Hc,G) ! Define core Hamiltonian - Hc = T + V + Hc(:,:) = T(:,:) + V(:,:) ! Read nuclear integrals - G = 0d0 + G(:,:,:,:) = 0d0 do read(11,*,end=11) mu,nu,la,si,ERI diff --git a/src/utils/read_integrals_sph.f90 b/src/utils/read_integrals_sph.f90 index eb5a15a..0ee515e 100644 --- a/src/utils/read_integrals_sph.f90 +++ b/src/utils/read_integrals_sph.f90 @@ -41,7 +41,7 @@ subroutine read_integrals_sph(nEl,nBas,S,T,V,Hc,G) ! Read overlap integrals - S = 0d0 + S(:,:) = 0d0 do read(8,*,end=8) mu,nu,Ov S(mu,nu) = Ov @@ -50,7 +50,7 @@ subroutine read_integrals_sph(nEl,nBas,S,T,V,Hc,G) ! Read kinetic integrals - T = 0d0 + T(:,:) = 0d0 do read(9,*,end=9) mu,nu,Kin T(mu,nu) = Rinv**2*Kin @@ -59,7 +59,7 @@ subroutine read_integrals_sph(nEl,nBas,S,T,V,Hc,G) ! Read nuclear integrals - V = 0d0 + V(:,:) = 0d0 do read(10,*,end=10) mu,nu,Nuc V(mu,nu) = Nuc @@ -68,11 +68,11 @@ subroutine read_integrals_sph(nEl,nBas,S,T,V,Hc,G) ! Define core Hamiltonian - Hc = T + V + Hc(:,:) = T(:,:) + V(:,:) ! Read nuclear integrals - G = 0d0 + G(:,:,:,:) = 0d0 do read(11,*,end=11) mu,nu,la,si,ERI