4
1
mirror of https://github.com/pfloos/quack synced 2024-06-29 16:34:52 +02:00
This commit is contained in:
Pierre-Francois Loos 2020-01-25 15:49:09 +01:00
parent 9e3c3f9c89
commit 395da84680
11 changed files with 143 additions and 141 deletions

View File

@ -2,4 +2,4 @@
2 9 9 0 0 2 9 9 0 0
# Znuc x y z # Znuc x y z
F 0. 0. 0. F 0. 0. 0.
F 0. 0. 3 F 0. 0. 2.67

View File

@ -2,4 +2,4 @@
2 2 2 0 0 2 2 2 0 0
# Znuc x y z # Znuc x y z
Li 0. 0. 0. Li 0. 0. 0.
H 0. 0. 3.05 H 0. 0. 3.01

View File

@ -2,4 +2,4 @@
2 7 7 0 0 2 7 7 0 0
# Znuc x y z # Znuc x y z
N 0. 0. 0. N 0. 0. 0.
N 0. 0. 2.067 N 0. 0. 3.4

View File

@ -1,58 +1,64 @@
1 6 1 6
S 8 S 9
1 14710.0000000 0.0007210 1 9.046000E+03 7.000000E-04
2 2207.0000000 0.0055530 2 1.357000E+03 5.389000E-03
3 502.8000000 0.0282670 3 3.093000E+02 2.740600E-02
4 142.6000000 0.1064440 4 8.773000E+01 1.032070E-01
5 46.4700000 0.2868140 5 2.856000E+01 2.787230E-01
6 16.7000000 0.4486410 6 1.021000E+01 4.485400E-01
7 6.3560000 0.2647610 7 3.838000E+00 2.782380E-01
8 1.3160000 0.0153330 8 7.466000E-01 1.544000E-02
S 8 9 2.248000E-01 -2.864000E-03
1 14710.0000000 -0.0001650 S 9
2 2207.0000000 -0.0013080 1 9.046000E+03 -1.530000E-04
3 502.8000000 -0.0064950 2 1.357000E+03 -1.208000E-03
4 142.6000000 -0.0266910 3 3.093000E+02 -5.992000E-03
5 46.4700000 -0.0736900 4 8.773000E+01 -2.454400E-02
6 16.7000000 -0.1707760 5 2.856000E+01 -6.745900E-02
7 6.3560000 -0.1123270 6 1.021000E+01 -1.580780E-01
8 1.3160000 0.5628140 7 3.838000E+00 -1.218310E-01
8 7.466000E-01 5.490030E-01
9 2.248000E-01 5.788150E-01
S 1 S 1
1 0.3897000 1.0000000 1 2.248000E-01 1.000000E+00
P 3 P 4
1 22.6700000 0.0448780 1 1.355000E+01 3.991900E-02
2 4.9770000 0.2357180 2 2.917000E+00 2.171690E-01
3 1.3470000 0.5085210 3 7.973000E-01 5.103190E-01
4 2.185000E-01 4.622140E-01
P 1 P 1
1 0.3471000 1.0000000 1 2.185000E-01 1.000000E+00
D 1 D 1
1 1.6400000 1.0000000 1 8.170000E-01 1.0000000
2 6 2 6
S 8 S 9
1 14710.0000000 0.0007210 1 9.046000E+03 7.000000E-04
2 2207.0000000 0.0055530 2 1.357000E+03 5.389000E-03
3 502.8000000 0.0282670 3 3.093000E+02 2.740600E-02
4 142.6000000 0.1064440 4 8.773000E+01 1.032070E-01
5 46.4700000 0.2868140 5 2.856000E+01 2.787230E-01
6 16.7000000 0.4486410 6 1.021000E+01 4.485400E-01
7 6.3560000 0.2647610 7 3.838000E+00 2.782380E-01
8 1.3160000 0.0153330 8 7.466000E-01 1.544000E-02
S 8 9 2.248000E-01 -2.864000E-03
1 14710.0000000 -0.0001650 S 9
2 2207.0000000 -0.0013080 1 9.046000E+03 -1.530000E-04
3 502.8000000 -0.0064950 2 1.357000E+03 -1.208000E-03
4 142.6000000 -0.0266910 3 3.093000E+02 -5.992000E-03
5 46.4700000 -0.0736900 4 8.773000E+01 -2.454400E-02
6 16.7000000 -0.1707760 5 2.856000E+01 -6.745900E-02
7 6.3560000 -0.1123270 6 1.021000E+01 -1.580780E-01
8 1.3160000 0.5628140 7 3.838000E+00 -1.218310E-01
8 7.466000E-01 5.490030E-01
9 2.248000E-01 5.788150E-01
S 1 S 1
1 0.3897000 1.0000000 1 2.248000E-01 1.000000E+00
P 3 P 4
1 22.6700000 0.0448780 1 1.355000E+01 3.991900E-02
2 4.9770000 0.2357180 2 2.917000E+00 2.171690E-01
3 1.3470000 0.5085210 3 7.973000E-01 5.103190E-01
4 2.185000E-01 4.622140E-01
P 1 P 1
1 0.3471000 1.0000000 1 2.185000E-01 1.000000E+00
D 1 D 1
1 1.6400000 1.0000000 1 8.170000E-01 1.0000000

View File

@ -1,5 +1,5 @@
# nAt nEla nElb nCore nRyd # nAt nEla nElb nCore nRyd
2 9 9 0 0 2 7 7 0 0
# Znuc x y z # Znuc x y z
F 0. 0. 0. N 0. 0. 0.
F 0. 0. 3 N 0. 0. 3.4

View File

@ -1,4 +1,4 @@
2 2
F 0.0000000000 0.0000000000 0.0000000000 N 0.0000000000 0.0000000000 0.0000000000
F 0.0000000000 0.0000000000 1.5875317470 N 0.0000000000 0.0000000000 1.7992026466

View File

@ -1,58 +1,64 @@
1 6 1 6
S 8 S 9
1 14710.0000000 0.0007210 1 9.046000E+03 7.000000E-04
2 2207.0000000 0.0055530 2 1.357000E+03 5.389000E-03
3 502.8000000 0.0282670 3 3.093000E+02 2.740600E-02
4 142.6000000 0.1064440 4 8.773000E+01 1.032070E-01
5 46.4700000 0.2868140 5 2.856000E+01 2.787230E-01
6 16.7000000 0.4486410 6 1.021000E+01 4.485400E-01
7 6.3560000 0.2647610 7 3.838000E+00 2.782380E-01
8 1.3160000 0.0153330 8 7.466000E-01 1.544000E-02
S 8 9 2.248000E-01 -2.864000E-03
1 14710.0000000 -0.0001650 S 9
2 2207.0000000 -0.0013080 1 9.046000E+03 -1.530000E-04
3 502.8000000 -0.0064950 2 1.357000E+03 -1.208000E-03
4 142.6000000 -0.0266910 3 3.093000E+02 -5.992000E-03
5 46.4700000 -0.0736900 4 8.773000E+01 -2.454400E-02
6 16.7000000 -0.1707760 5 2.856000E+01 -6.745900E-02
7 6.3560000 -0.1123270 6 1.021000E+01 -1.580780E-01
8 1.3160000 0.5628140 7 3.838000E+00 -1.218310E-01
8 7.466000E-01 5.490030E-01
9 2.248000E-01 5.788150E-01
S 1 S 1
1 0.3897000 1.0000000 1 2.248000E-01 1.000000E+00
P 3 P 4
1 22.6700000 0.0448780 1 1.355000E+01 3.991900E-02
2 4.9770000 0.2357180 2 2.917000E+00 2.171690E-01
3 1.3470000 0.5085210 3 7.973000E-01 5.103190E-01
4 2.185000E-01 4.622140E-01
P 1 P 1
1 0.3471000 1.0000000 1 2.185000E-01 1.000000E+00
D 1 D 1
1 1.6400000 1.0000000 1 8.170000E-01 1.0000000
2 6 2 6
S 8 S 9
1 14710.0000000 0.0007210 1 9.046000E+03 7.000000E-04
2 2207.0000000 0.0055530 2 1.357000E+03 5.389000E-03
3 502.8000000 0.0282670 3 3.093000E+02 2.740600E-02
4 142.6000000 0.1064440 4 8.773000E+01 1.032070E-01
5 46.4700000 0.2868140 5 2.856000E+01 2.787230E-01
6 16.7000000 0.4486410 6 1.021000E+01 4.485400E-01
7 6.3560000 0.2647610 7 3.838000E+00 2.782380E-01
8 1.3160000 0.0153330 8 7.466000E-01 1.544000E-02
S 8 9 2.248000E-01 -2.864000E-03
1 14710.0000000 -0.0001650 S 9
2 2207.0000000 -0.0013080 1 9.046000E+03 -1.530000E-04
3 502.8000000 -0.0064950 2 1.357000E+03 -1.208000E-03
4 142.6000000 -0.0266910 3 3.093000E+02 -5.992000E-03
5 46.4700000 -0.0736900 4 8.773000E+01 -2.454400E-02
6 16.7000000 -0.1707760 5 2.856000E+01 -6.745900E-02
7 6.3560000 -0.1123270 6 1.021000E+01 -1.580780E-01
8 1.3160000 0.5628140 7 3.838000E+00 -1.218310E-01
8 7.466000E-01 5.490030E-01
9 2.248000E-01 5.788150E-01
S 1 S 1
1 0.3897000 1.0000000 1 2.248000E-01 1.000000E+00
P 3 P 4
1 22.6700000 0.0448780 1 1.355000E+01 3.991900E-02
2 4.9770000 0.2357180 2 2.917000E+00 2.171690E-01
3 1.3470000 0.5085210 3 7.973000E-01 5.103190E-01
4 2.185000E-01 4.622140E-01
P 1 P 1
1 0.3471000 1.0000000 1 2.185000E-01 1.000000E+00
D 1 D 1
1 1.6400000 1.0000000 1 8.170000E-01 1.0000000

View File

@ -1,9 +1,9 @@
#! /bin/bash #! /bin/bash
MOL="LiH" MOL="LiH"
BASIS="cc-pvtz" BASIS="cc-pvqz"
R_START=3.00 R_START=3.010
R_END=3.05 R_END=3.020
DR=0.001 DR=0.001
for R in $(seq $R_START $DR $R_END) for R in $(seq $R_START $DR $R_END)

View File

@ -1,10 +1,10 @@
#! /bin/bash #! /bin/bash
MOL="N2" MOL="N2"
BASIS="cc-pvtz" BASIS="cc-pvdz"
R_START=2.060 R_START=1.5
R_END=2.080 R_END=3.5
DR=0.001 DR=0.1
for R in $(seq $R_START $DR $R_END) for R in $(seq $R_START $DR $R_END)
do do

View File

@ -20,7 +20,6 @@ subroutine ACFDT_correlation_energy(ispin,exchange_kernel,nBas,nC,nO,nV,nR,nS,ER
integer :: ia,jb,kc integer :: ia,jb,kc
double precision :: delta_spin double precision :: delta_spin
double precision :: delta_Kx double precision :: delta_Kx
double precision,allocatable :: P(:,:)
double precision,allocatable :: Ap(:,:) double precision,allocatable :: Ap(:,:)
double precision,allocatable :: Bp(:,:) double precision,allocatable :: Bp(:,:)
double precision,allocatable :: X(:,:) double precision,allocatable :: X(:,:)
@ -44,15 +43,7 @@ subroutine ACFDT_correlation_energy(ispin,exchange_kernel,nBas,nC,nO,nV,nR,nS,ER
! Memory allocation ! Memory allocation
allocate(P(nS,nS),Ap(nS,nS),Bp(nS,nS),X(nS,nS),Y(nS,nS)) allocate(Ap(nS,nS),Bp(nS,nS),X(nS,nS),Y(nS,nS))
! Compute P = (X+Y)^T.(X+Y) - 1
P(:,:) = matmul(transpose(XpY),XpY)
do ia=1,nS
P(ia,ia) = P(ia,ia) - 1d0
enddo
! Compute Aiajb = (ia|bj) and Biajb = (ia|jb) ! Compute Aiajb = (ia|bj) and Biajb = (ia|jb)
@ -78,8 +69,6 @@ subroutine ACFDT_correlation_energy(ispin,exchange_kernel,nBas,nC,nO,nV,nR,nS,ER
! Compute Tr(K x P_lambda) ! Compute Tr(K x P_lambda)
! EcAC = trace_matrix(nS,matmul(Ap,P))
X(:,:) = 0.5d0*(XpY(:,:) + XmY(:,:)) X(:,:) = 0.5d0*(XpY(:,:) + XmY(:,:))
Y(:,:) = 0.5d0*(XpY(:,:) - XmY(:,:)) Y(:,:) = 0.5d0*(XpY(:,:) - XmY(:,:))

View File

@ -94,6 +94,7 @@ subroutine RPA(doACFDT,exchange_kernel,singlet_manifold,triplet_manifold,eta, &
write(*,*) write(*,*)
! Compute the correlation energy via the adiabatic connection ! Compute the correlation energy via the adiabatic connection
! Switch off ACFDT for RPA as the trace formula is equivalent
if(doACFDT) then if(doACFDT) then
@ -105,21 +106,21 @@ subroutine RPA(doACFDT,exchange_kernel,singlet_manifold,triplet_manifold,eta, &
call ACFDT(exchange_kernel,.false.,.true.,.false.,.false.,singlet_manifold,triplet_manifold,eta, & call ACFDT(exchange_kernel,.false.,.true.,.false.,.false.,singlet_manifold,triplet_manifold,eta, &
nBas,nC,nO,nV,nR,nS,ERI,e,Omega,XpY,XmY,rho,EcAC) nBas,nC,nO,nV,nR,nS,ERI,e,Omega,XpY,XmY,rho,EcAC)
if(exchange_kernel) then if(exchange_kernel) then
EcAC(1) = 0.5d0*EcAC(1)
EcAC(2) = 1.5d0*EcAC(1)
end if
EcAC(1) = 0.5d0*EcAC(1) write(*,*)
EcAC(2) = 1.5d0*EcAC(1) write(*,*)'-------------------------------------------------------------------------------'
write(*,'(2X,A50,F20.10)') 'AC@RPA correlation energy (singlet) =',EcAC(1)
end if write(*,'(2X,A50,F20.10)') 'AC@RPA correlation energy (triplet) =',EcAC(2)
write(*,'(2X,A50,F20.10)') 'AC@RPA correlation energy =',EcAC(1) + EcAC(2)
write(*,*) write(*,'(2X,A50,F20.10)') 'AC@RPA total energy =',ENuc + ERHF + EcAC(1) + EcAC(2)
write(*,*)'-------------------------------------------------------------------------------' write(*,*)'-------------------------------------------------------------------------------'
write(*,'(2X,A50,F20.10)') 'AC@RPA correlation energy (singlet) =',EcAC(1) write(*,*)
write(*,'(2X,A50,F20.10)') 'AC@RPA correlation energy (triplet) =',EcAC(2)
write(*,'(2X,A50,F20.10)') 'AC@RPA correlation energy =',EcAC(1) + EcAC(2)
write(*,'(2X,A50,F20.10)') 'AC@RPA total energy =',ENuc + ERHF + EcAC(1) + EcAC(2)
write(*,*)'-------------------------------------------------------------------------------'
write(*,*)
end if end if