From d27591b14cb3e421a303b44c953c3f8a60cab807 Mon Sep 17 00:00:00 2001 From: Pierre-Francois Loos Date: Sun, 31 Mar 2019 22:28:04 +0200 Subject: [PATCH] IntPak read geom fixed --- examples/molecule.BN.1.2 | 5 ---- examples/molecule.Be | 2 +- examples/molecule.sph | 6 ++--- input/basis | 46 ++++++++++++++++++------------------- input/methods | 4 ++-- input/molecule | 4 ++-- input/options | 2 +- input/weight | 46 ++++++++++++++++++------------------- src/IntPak/Compute2eInt.f90 | 2 ++ src/IntPak/ComputeKin.f90 | 1 + src/IntPak/ComputeNuc.f90 | 1 + src/IntPak/ComputeOv.f90 | 1 + src/IntPak/IntPak.f90 | 2 +- src/utils/elements.f90 | 31 ++++++++++++++++--------- src/utils/read_geometry.f90 | 2 +- 15 files changed, 82 insertions(+), 73 deletions(-) delete mode 100644 examples/molecule.BN.1.2 diff --git a/examples/molecule.BN.1.2 b/examples/molecule.BN.1.2 deleted file mode 100644 index 4038213..0000000 --- a/examples/molecule.BN.1.2 +++ /dev/null @@ -1,5 +0,0 @@ -# nAt nEl nCore nRyd - 2 12 4 0 -# Znuc x y z -5. 0. 0. 0.6 -7. 0. 0. -0.6 \ No newline at end of file diff --git a/examples/molecule.Be b/examples/molecule.Be index 7c4725d..6a6f6d1 100644 --- a/examples/molecule.Be +++ b/examples/molecule.Be @@ -1,4 +1,4 @@ # nAt nEla nElb nCore nRyd 1 2 2 0 0 # Znuc x y z - Be 0.0 0.0 0.0 + Be 0.0 0.0 0.0 diff --git a/examples/molecule.sph b/examples/molecule.sph index fa48962..9bc4ca6 100644 --- a/examples/molecule.sph +++ b/examples/molecule.sph @@ -1,4 +1,4 @@ -# nAt nEl nCore nRyd - 1 2 0 0 +# nAt nEla nElb nCore nRyd + 1 1 1 0 0 # Znuc x y z - 0. 0.0 0.0 0.0 + X 0.0 0.0 0.0 diff --git a/input/basis b/input/basis index 17fdf8c..e220e53 100644 --- a/input/basis +++ b/input/basis @@ -1,29 +1,29 @@ -1 6 +1 6 S 8 1.00 - 1469.0000000 0.0007660 - 220.5000000 0.0058920 - 50.2600000 0.0296710 - 14.2400000 0.1091800 - 4.5810000 0.2827890 - 1.5800000 0.4531230 - 0.5640000 0.2747740 - 0.0734500 0.0097510 + 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 - 1469.0000000 -0.0001200 - 220.5000000 -0.0009230 - 50.2600000 -0.0046890 - 14.2400000 -0.0176820 - 4.5810000 -0.0489020 - 1.5800000 -0.0960090 - 0.5640000 -0.1363800 - 0.0734500 0.5751020 + 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.0280500 1.0000000 + 0.0589000 1.0000000 P 3 1.00 - 1.5340000 0.0227840 - 0.2749000 0.1391070 - 0.0736200 0.5003750 + 3.6190000 0.0291110 + 0.7110000 0.1693650 + 0.1951000 0.5134580 P 1 1.00 - 0.0240300 1.0000000 + 0.0601800 1.0000000 D 1 1.00 - 0.1239000 1.0000000 + 0.2380000 1.0000000 diff --git a/input/methods b/input/methods index 31b24aa..40fd2a7 100644 --- a/input/methods +++ b/input/methods @@ -1,5 +1,5 @@ # RHF UHF MOM - F T F + T F F # MP2 MP3 MP2-F12 F F F # CCD CCSD CCSD(T) @@ -9,6 +9,6 @@ # GF2 GF3 F F # G0W0 evGW qsGW - F F F + T T F # MCMP2 F diff --git a/input/molecule b/input/molecule index 058d6dd..6a6f6d1 100644 --- a/input/molecule +++ b/input/molecule @@ -1,4 +1,4 @@ # nAt nEla nElb nCore nRyd - 1 2 1 0 0 + 1 2 2 0 0 # Znuc x y z - Li 0.0 0.0 0.0 + Be 0.0 0.0 0.0 diff --git a/input/options b/input/options index b67a3c4..55951ff 100644 --- a/input/options +++ b/input/options @@ -9,6 +9,6 @@ # GF: maxSCF thresh DIIS n_diis renormalization 64 0.00001 T 5 3 # GW: maxSCF thresh DIIS n_diis COHSEX SOSEX BSE TDA G0W GW0 linearize - 64 0.00001 T 15 F F F F F F F + 64 0.00001 T 5 F F F F F F F # MCMP2: nMC nEq nWalk dt nPrint iSeed doDrift 1000000 100000 10 0.3 10000 1234 T diff --git a/input/weight b/input/weight index 17fdf8c..e220e53 100644 --- a/input/weight +++ b/input/weight @@ -1,29 +1,29 @@ -1 6 +1 6 S 8 1.00 - 1469.0000000 0.0007660 - 220.5000000 0.0058920 - 50.2600000 0.0296710 - 14.2400000 0.1091800 - 4.5810000 0.2827890 - 1.5800000 0.4531230 - 0.5640000 0.2747740 - 0.0734500 0.0097510 + 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 - 1469.0000000 -0.0001200 - 220.5000000 -0.0009230 - 50.2600000 -0.0046890 - 14.2400000 -0.0176820 - 4.5810000 -0.0489020 - 1.5800000 -0.0960090 - 0.5640000 -0.1363800 - 0.0734500 0.5751020 + 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.0280500 1.0000000 + 0.0589000 1.0000000 P 3 1.00 - 1.5340000 0.0227840 - 0.2749000 0.1391070 - 0.0736200 0.5003750 + 3.6190000 0.0291110 + 0.7110000 0.1693650 + 0.1951000 0.5134580 P 1 1.00 - 0.0240300 1.0000000 + 0.0601800 1.0000000 D 1 1.00 - 0.1239000 1.0000000 + 0.2380000 1.0000000 diff --git a/src/IntPak/Compute2eInt.f90 b/src/IntPak/Compute2eInt.f90 index 5827d39..35f684c 100644 --- a/src/IntPak/Compute2eInt.f90 +++ b/src/IntPak/Compute2eInt.f90 @@ -248,6 +248,7 @@ subroutine Compute2eInt(debug,chemist_notation,iType,nShell, & if(chemist_notation) then write(iFile,'(I6,I6,I6,I6,F20.15)') iBasA1,iBasB1,iBasA2,iBasB2,c2eInt +! write(iFile,'(F20.15,I6,I6,I6,I6)') c2eInt,iBasA1,iBasB1,iBasA2,iBasB2 if(debug) then write(*,'(A10,1X,F16.10,1X,I6,1X,I6,1X,I6,1X,I6)') & @@ -257,6 +258,7 @@ subroutine Compute2eInt(debug,chemist_notation,iType,nShell, & else write(iFile,'(I6,I6,I6,I6,F20.15)') iBasA1,iBasA2,iBasB1,iBasB2,c2eInt +! write(iFile,'(F20.15,I6,I6,I6,I6)') c2eInt,iBasA1,iBasA2,iBasB1,iBasB2 if(debug) then write(*,'(A10,1X,F16.10,1X,I6,1X,I6,1X,I6,1X,I6)') & diff --git a/src/IntPak/ComputeKin.f90 b/src/IntPak/ComputeKin.f90 index b50c4fb..11e3b34 100644 --- a/src/IntPak/ComputeKin.f90 +++ b/src/IntPak/ComputeKin.f90 @@ -136,6 +136,7 @@ subroutine ComputeKin(debug,nShell, & nSigcKin = nSigcKin + 1 t_cKin = end_cKin - start_cKin write(9,'(I6,I6,F20.15)') iBasA,iBasB,cKin +! write(9,'(F20.15,I6,I6)') cKin,iBasA,iBasB if(debug) then write(*,'(A10,1X,F16.10,1X,I6,1X,I6)') '(a|T|b) = ',cKin,iBasA,iBasB end if diff --git a/src/IntPak/ComputeNuc.f90 b/src/IntPak/ComputeNuc.f90 index 92b649f..fd402b0 100644 --- a/src/IntPak/ComputeNuc.f90 +++ b/src/IntPak/ComputeNuc.f90 @@ -160,6 +160,7 @@ subroutine ComputeNuc(debug,nShell, & nSigcNuc = nSigcNuc + 1 t_cNuc = end_cNuc - start_cNuc write(10,'(I6,I6,F20.15)') iBasA,iBasB,cNuc +! write(10,'(F20.15,I6,I6)') cNuc,iBasA,iBasB if(debug) then write(*,'(A10,1X,F16.10,1X,I6,1X,I6)') '(a|V|b) = ',cNuc,iBasA,iBasB write(*,*) diff --git a/src/IntPak/ComputeOv.f90 b/src/IntPak/ComputeOv.f90 index 9995899..5879729 100644 --- a/src/IntPak/ComputeOv.f90 +++ b/src/IntPak/ComputeOv.f90 @@ -139,6 +139,7 @@ subroutine ComputeOv(debug,nBas,nShell, & nSigcOv = nSigcOv + 1 t_cOv = end_cOv - start_cOv write(8,'(I6,I6,F20.15)') iBasA,iBasB,cOv +! write(8,'(F20.15,I6,I6)') cOv,iBasA,iBasB if(debug) then write(*,'(A10,1X,F16.10,1X,I6,1X,I6)') '(a|b) = ',cOv,iBasA,iBasB end if diff --git a/src/IntPak/IntPak.f90 b/src/IntPak/IntPak.f90 index 25ac6b2..6973651 100644 --- a/src/IntPak/IntPak.f90 +++ b/src/IntPak/IntPak.f90 @@ -19,7 +19,7 @@ program IntPak logical :: do4eInt(n4eInt) integer :: nNuc,nBas,iType - integer :: nEl,nO,nV,nC,nR + integer :: nEl(nspin),nC(nspin),nO(nspin),nV(nspin),nR(nspin),nS(nspin) double precision :: ExpS double precision :: ENuc integer :: KG diff --git a/src/utils/elements.f90 b/src/utils/elements.f90 index 22953dc..5ecf30f 100644 --- a/src/utils/elements.f90 +++ b/src/utils/elements.f90 @@ -23,18 +23,27 @@ function element_number(element_name) integer :: ielement !===== - ielement=1 - do while( ADJUSTL(element_name) /= ADJUSTL(element_list(ielement)) ) - if( ielement == nelement_max ) then - write(*,'(a,a)') ' Input symbol ',element_name - write(*,'(a,i3,a)') ' Element symbol is not one of first ',nelement_max,' elements' - write(*,*) '!!! element symbol not understood !!!' - stop - endif - ielement = ielement + 1 - enddo + ielement = 1 - element_number = ielement + if(ADJUSTL(element_name) == ADJUSTL('X')) then + + element_number = 0 + + else + + do while( ADJUSTL(element_name) /= ADJUSTL(element_list(ielement)) ) + if( ielement == nelement_max ) then + write(*,'(a,a)') ' Input symbol ',element_name + write(*,'(a,i3,a)') ' Element symbol is not one of first ',nelement_max,' elements' + write(*,*) '!!! element symbol not understood !!!' + stop + end if + ielement = ielement + 1 + end do + + element_number = ielement + + end if end function element_number diff --git a/src/utils/read_geometry.f90 b/src/utils/read_geometry.f90 index a3a4cf9..f510ea1 100644 --- a/src/utils/read_geometry.f90 +++ b/src/utils/read_geometry.f90 @@ -33,7 +33,7 @@ subroutine read_geometry(nNuc,ZNuc,rNuc,ENuc) do i=1,nNuc read(1,*) El,rNuc(i,1),rNuc(i,2),rNuc(i,3) - ZNuc(i) = element_number(El) + ZNuc(i) = dble(element_number(El)) enddo ! Compute nuclear repulsion energy