10
1
mirror of https://github.com/pfloos/quack synced 2024-11-04 21:23:55 +01:00

BSE in ppRPA

This commit is contained in:
Pierre-Francois Loos 2020-03-21 21:09:48 +01:00
parent 941ab79dc1
commit a985f27142
14 changed files with 235 additions and 191 deletions

View File

@ -2,4 +2,4 @@
2 7 7 0 0
# Znuc x y z
B 0. 0. 0.
F 0. 0. 2.385
F 0. 0. 3.2

View File

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

View File

@ -2,4 +2,4 @@
2 9 9 0 0
# Znuc x y z
H 0. 0. 0.
Cl 0. 0. 2.399
Cl 0. 0. 3.2

View File

@ -2,4 +2,4 @@
2 6 6 0 0
# Znuc x y z
Li 0. 0. 0.
F 0. 0. 2.965
F 0. 0. 3.5

View File

@ -2,4 +2,4 @@
2 2 2 0 0
# Znuc x y z
Li 0. 0. 0.
H 0. 0. 3.017
H 0. 0. 3.5

View File

@ -2,4 +2,4 @@
2 7 7 0 0
# Znuc x y z
N 0. 0. 0.
N 0. 0. 2.065
N 0. 0. 2.5

View File

@ -1,98 +1,74 @@
1 15
S 9
1 6601.0000000 0.0001170
2 989.7000000 0.0009110
3 225.7000000 0.0047280
4 64.2900000 0.0191970
5 21.1800000 0.0630470
6 7.7240000 0.1632080
7 3.0030000 0.3148270
8 1.2120000 0.3939360
9 0.4930000 0.1969180
S 9
1 6601.0000000 -0.0000180
2 989.7000000 -0.0001420
3 225.7000000 -0.0007410
4 64.2900000 -0.0030200
5 21.1800000 -0.0101230
6 7.7240000 -0.0270940
7 3.0030000 -0.0573590
8 1.2120000 -0.0938950
9 0.4930000 -0.1210910
1 10
S 8
1 19500.0000000 0.0005070
2 2923.0000000 0.0039230
3 664.5000000 0.0202000
4 187.5000000 0.0790100
5 60.6200000 0.2304390
6 21.4200000 0.4328720
7 7.9500000 0.3499640
8 0.8815000 -0.0078920
S 8
1 19500.0000000 -0.0001170
2 2923.0000000 -0.0009120
3 664.5000000 -0.0047170
4 187.5000000 -0.0190860
5 60.6200000 -0.0596550
6 21.4200000 -0.1400100
7 7.9500000 -0.1767820
8 0.8815000 0.6050430
S 1
1 0.0951500 1.0000000
1 2.2570000 1.0000000
S 1
1 0.0479100 1.0000000
S 1
1 0.0222000 1.0000000
1 0.3041000 1.0000000
P 3
1 6.2500000 0.0033880
2 1.3700000 0.0193160
3 0.3672000 0.0791040
1 43.8800000 0.0166650
2 9.9260000 0.1044720
3 2.9300000 0.3172600
P 1
1 0.1192000 1.0000000
1 0.9132000 1.0000000
P 1
1 0.0447400 1.0000000
P 1
1 0.0179500 1.0000000
1 0.2672000 1.0000000
D 1
1 0.3440000 1.0000000
1 3.1070000 1.0000000
D 1
1 0.1530000 1.0000000
D 1
1 0.0680000 1.0000000
1 0.8550000 1.0000000
F 1
1 0.2460000 1.0000000
F 1
1 0.1292000 1.0000000
G 1
1 0.2380000 1.0000000
2 15
S 9
1 74530.0000000 0.0000950
2 11170.0000000 0.0007380
3 2543.0000000 0.0038580
4 721.0000000 0.0159260
5 235.9000000 0.0542890
6 85.6000000 0.1495130
7 33.5500000 0.3082520
8 13.9300000 0.3948530
9 5.9150000 0.2110310
S 9
1 74530.0000000 -0.0000220
2 11170.0000000 -0.0001720
3 2543.0000000 -0.0008910
4 721.0000000 -0.0037480
5 235.9000000 -0.0128620
6 85.6000000 -0.0380610
7 33.5500000 -0.0862390
8 13.9300000 -0.1558650
9 5.9150000 -0.1109140
1 1.9170000 1.0000000
2 10
S 8
1 19500.0000000 0.0005070
2 2923.0000000 0.0039230
3 664.5000000 0.0202000
4 187.5000000 0.0790100
5 60.6200000 0.2304390
6 21.4200000 0.4328720
7 7.9500000 0.3499640
8 0.8815000 -0.0078920
S 8
1 19500.0000000 -0.0001170
2 2923.0000000 -0.0009120
3 664.5000000 -0.0047170
4 187.5000000 -0.0190860
5 60.6200000 -0.0596550
6 21.4200000 -0.1400100
7 7.9500000 -0.1767820
8 0.8815000 0.6050430
S 1
1 1.8430000 1.0000000
1 2.2570000 1.0000000
S 1
1 0.7124000 1.0000000
S 1
1 0.2637000 1.0000000
1 0.3041000 1.0000000
P 3
1 80.3900000 0.0063470
2 18.6300000 0.0442040
3 5.6940000 0.1685140
1 43.8800000 0.0166650
2 9.9260000 0.1044720
3 2.9300000 0.3172600
P 1
1 1.9530000 1.0000000
1 0.9132000 1.0000000
P 1
1 0.6702000 1.0000000
P 1
1 0.2166000 1.0000000
1 0.2672000 1.0000000
D 1
1 5.0140000 1.0000000
1 3.1070000 1.0000000
D 1
1 1.7250000 1.0000000
D 1
1 0.5860000 1.0000000
1 0.8550000 1.0000000
F 1
1 3.5620000 1.0000000
F 1
1 1.1480000 1.0000000
G 1
1 2.3760000 1.0000000
1 1.9170000 1.0000000

View File

@ -1,16 +1,16 @@
# RHF UHF MOM
T F F
# MP2 MP3 MP2-F12
F F F
T F F
# CCD CCSD CCSD(T) ringCCD ladderCCD
F F F F F
# CIS RPA RPAx ppRPA ADC
F F F F F
T T T F F
# G0F2 evGF2 G0F3 evGF3
F F F F
# G0W0 evGW qsGW
F F F
# G0T0 evGT qsGT
T F F
# G0T0 evGT qsGT
F F F
# MCMP2
F

View File

@ -1,5 +1,5 @@
# nAt nEla nElb nCore nRyd
2 6 6 0 0
2 9 9 0 0
# Znuc x y z
Li 0. 0. 0.
F 0. 0. 2.965
F 0. 0. 0.
F 0. 0. 2

View File

@ -1,4 +1,4 @@
2
Li 0.0000000000 0.0000000000 0.0000000000
F 0.0000000000 0.0000000000 1.5690105433
F 0.0000000000 0.0000000000 0.0000000000
F 0.0000000000 0.0000000000 1.0583544980

View File

@ -1,98 +1,74 @@
1 15
S 9
1 6601.0000000 0.0001170
2 989.7000000 0.0009110
3 225.7000000 0.0047280
4 64.2900000 0.0191970
5 21.1800000 0.0630470
6 7.7240000 0.1632080
7 3.0030000 0.3148270
8 1.2120000 0.3939360
9 0.4930000 0.1969180
S 9
1 6601.0000000 -0.0000180
2 989.7000000 -0.0001420
3 225.7000000 -0.0007410
4 64.2900000 -0.0030200
5 21.1800000 -0.0101230
6 7.7240000 -0.0270940
7 3.0030000 -0.0573590
8 1.2120000 -0.0938950
9 0.4930000 -0.1210910
1 10
S 8
1 19500.0000000 0.0005070
2 2923.0000000 0.0039230
3 664.5000000 0.0202000
4 187.5000000 0.0790100
5 60.6200000 0.2304390
6 21.4200000 0.4328720
7 7.9500000 0.3499640
8 0.8815000 -0.0078920
S 8
1 19500.0000000 -0.0001170
2 2923.0000000 -0.0009120
3 664.5000000 -0.0047170
4 187.5000000 -0.0190860
5 60.6200000 -0.0596550
6 21.4200000 -0.1400100
7 7.9500000 -0.1767820
8 0.8815000 0.6050430
S 1
1 0.0951500 1.0000000
1 2.2570000 1.0000000
S 1
1 0.0479100 1.0000000
S 1
1 0.0222000 1.0000000
1 0.3041000 1.0000000
P 3
1 6.2500000 0.0033880
2 1.3700000 0.0193160
3 0.3672000 0.0791040
1 43.8800000 0.0166650
2 9.9260000 0.1044720
3 2.9300000 0.3172600
P 1
1 0.1192000 1.0000000
1 0.9132000 1.0000000
P 1
1 0.0447400 1.0000000
P 1
1 0.0179500 1.0000000
1 0.2672000 1.0000000
D 1
1 0.3440000 1.0000000
1 3.1070000 1.0000000
D 1
1 0.1530000 1.0000000
D 1
1 0.0680000 1.0000000
1 0.8550000 1.0000000
F 1
1 0.2460000 1.0000000
F 1
1 0.1292000 1.0000000
G 1
1 0.2380000 1.0000000
2 15
S 9
1 74530.0000000 0.0000950
2 11170.0000000 0.0007380
3 2543.0000000 0.0038580
4 721.0000000 0.0159260
5 235.9000000 0.0542890
6 85.6000000 0.1495130
7 33.5500000 0.3082520
8 13.9300000 0.3948530
9 5.9150000 0.2110310
S 9
1 74530.0000000 -0.0000220
2 11170.0000000 -0.0001720
3 2543.0000000 -0.0008910
4 721.0000000 -0.0037480
5 235.9000000 -0.0128620
6 85.6000000 -0.0380610
7 33.5500000 -0.0862390
8 13.9300000 -0.1558650
9 5.9150000 -0.1109140
1 1.9170000 1.0000000
2 10
S 8
1 19500.0000000 0.0005070
2 2923.0000000 0.0039230
3 664.5000000 0.0202000
4 187.5000000 0.0790100
5 60.6200000 0.2304390
6 21.4200000 0.4328720
7 7.9500000 0.3499640
8 0.8815000 -0.0078920
S 8
1 19500.0000000 -0.0001170
2 2923.0000000 -0.0009120
3 664.5000000 -0.0047170
4 187.5000000 -0.0190860
5 60.6200000 -0.0596550
6 21.4200000 -0.1400100
7 7.9500000 -0.1767820
8 0.8815000 0.6050430
S 1
1 1.8430000 1.0000000
1 2.2570000 1.0000000
S 1
1 0.7124000 1.0000000
S 1
1 0.2637000 1.0000000
1 0.3041000 1.0000000
P 3
1 80.3900000 0.0063470
2 18.6300000 0.0442040
3 5.6940000 0.1685140
1 43.8800000 0.0166650
2 9.9260000 0.1044720
3 2.9300000 0.3172600
P 1
1 1.9530000 1.0000000
1 0.9132000 1.0000000
P 1
1 0.6702000 1.0000000
P 1
1 0.2166000 1.0000000
1 0.2672000 1.0000000
D 1
1 5.0140000 1.0000000
1 3.1070000 1.0000000
D 1
1 1.7250000 1.0000000
D 1
1 0.5860000 1.0000000
1 0.8550000 1.0000000
F 1
1 3.5620000 1.0000000
F 1
1 1.1480000 1.0000000
G 1
1 2.3760000 1.0000000
1 1.9170000 1.0000000

View File

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

View File

@ -1,4 +1,5 @@
subroutine G0T0(eta,nBas,nC,nO,nV,nR,ENuc,ERHF,ERI,eHF)
subroutine G0T0(doACFDT,exchange_kernel,doXBS,BSE,TDA,singlet_manifold,triplet_manifold, &
linearize,eta,nBas,nC,nO,nV,nR,nS,ENuc,ERHF,ERI,eHF)
! Perform one-shot calculation with a T-matrix self-energy (G0T0)
@ -7,9 +8,22 @@ subroutine G0T0(eta,nBas,nC,nO,nV,nR,ENuc,ERHF,ERI,eHF)
! Input variables
logical,intent(in) :: doACFDT
logical,intent(in) :: exchange_kernel
logical,intent(in) :: doXBS
logical,intent(in) :: BSE
logical,intent(in) :: TDA
logical,intent(in) :: singlet_manifold
logical,intent(in) :: triplet_manifold
logical,intent(in) :: linearize
double precision,intent(in) :: eta
integer,intent(in) :: nBas,nC,nO,nV,nR
integer,intent(in) :: nBas
integer,intent(in) :: nC
integer,intent(in) :: nO
integer,intent(in) :: nV
integer,intent(in) :: nR
integer,intent(in) :: nS
double precision,intent(in) :: ENuc
double precision,intent(in) :: ERHF
double precision,intent(in) :: eHF(nBas)
@ -22,6 +36,7 @@ subroutine G0T0(eta,nBas,nC,nO,nV,nR,ENuc,ERHF,ERI,eHF)
integer :: nVVs,nVVt
double precision :: EcRPA(nspin)
double precision :: EcBSE(nspin)
double precision :: EcAC(nspin)
double precision,allocatable :: Omega1s(:),Omega1t(:)
double precision,allocatable :: X1s(:,:),X1t(:,:)
double precision,allocatable :: Y1s(:,:),Y1t(:,:)
@ -35,6 +50,11 @@ subroutine G0T0(eta,nBas,nC,nO,nV,nR,ENuc,ERHF,ERI,eHF)
double precision,allocatable :: eG0T0(:)
double precision,allocatable :: Omega(:,:)
double precision,allocatable :: XpY(:,:,:)
double precision,allocatable :: XmY(:,:,:)
double precision,allocatable :: rho(:,:,:,:)
! Output variables
! Hello world
@ -113,9 +133,6 @@ subroutine G0T0(eta,nBas,nC,nO,nV,nR,ENuc,ERHF,ERI,eHF)
X1t(:,:),Y1t(:,:),rho1t(:,:,:), &
X2t(:,:),Y2t(:,:),rho2t(:,:,:))
rho2s(:,:,:) = 0d0
rho2t(:,:,:) = 0d0
!----------------------------------------------
! Compute T-matrix version of the self-energy
!----------------------------------------------
@ -136,8 +153,15 @@ subroutine G0T0(eta,nBas,nC,nO,nV,nR,ENuc,ERHF,ERI,eHF)
! Solve the quasi-particle equation
!----------------------------------------------
if(linearize) then
eG0T0(:) = eHF(:) + Z(:)*SigT(:)
else
eG0T0(:) = eHF(:) + SigT(:)
! eG0T0(:) = eHF(:) + Z(:)*SigT(:)
end if
!----------------------------------------------
! Dump results
@ -145,4 +169,70 @@ subroutine G0T0(eta,nBas,nC,nO,nV,nR,ENuc,ERHF,ERI,eHF)
call print_G0T0(nBas,nO,eHF(:),ENuc,ERHF,SigT(:),Z(:),eG0T0(:),EcRPA(:))
! Perform BSE calculation
if(BSE) then
allocate(Omega(nS,nspin),XpY(nS,nS,nspin),XmY(nS,nS,nspin),rho(nBas,nBas,nS,nspin))
call Bethe_Salpeter(TDA,singlet_manifold,triplet_manifold,eta, &
nBas,nC,nO,nV,nR,nS,ERI,eHF,eG0T0,Omega,XpY,XmY,rho,EcRPA,EcBSE)
if(exchange_kernel) then
EcRPA(1) = 0.5d0*EcRPA(1)
EcRPA(2) = 1.5d0*EcRPA(1)
end if
write(*,*)
write(*,*)'-------------------------------------------------------------------------------'
write(*,'(2X,A50,F20.10)') 'Tr@BSE@G0T0 correlation energy (singlet) =',EcBSE(1)
write(*,'(2X,A50,F20.10)') 'Tr@BSE@G0T0 correlation energy (triplet) =',EcBSE(2)
write(*,'(2X,A50,F20.10)') 'Tr@BSE@G0T0 correlation energy =',EcBSE(1) + EcBSE(2)
write(*,'(2X,A50,F20.10)') 'Tr@BSE@G0T0 total energy =',ENuc + ERHF + EcBSE(1) + EcBSE(2)
write(*,*)'-------------------------------------------------------------------------------'
write(*,*)
! Compute the BSE correlation energy via the adiabatic connection
! Compute the BSE correlation energy via the adiabatic connection
if(doACFDT) then
write(*,*) '------------------------------------------------------'
write(*,*) 'Adiabatic connection version of BSE correlation energy'
write(*,*) '------------------------------------------------------'
write(*,*)
if(doXBS) then
write(*,*) '*** scaled screening version (XBS) ***'
write(*,*)
end if
call ACFDT(exchange_kernel,doXBS,.true.,TDA,BSE,singlet_manifold,triplet_manifold,eta, &
nBas,nC,nO,nV,nR,nS,ERI,eHF,eG0T0,Omega,XpY,XmY,rho,EcAC)
if(exchange_kernel) then
EcAC(1) = 0.5d0*EcAC(1)
EcAC(2) = 1.5d0*EcAC(1)
end if
write(*,*)
write(*,*)'-------------------------------------------------------------------------------'
write(*,'(2X,A50,F20.10)') 'AC@BSE@G0T0 correlation energy (singlet) =',EcAC(1)
write(*,'(2X,A50,F20.10)') 'AC@BSE@G0T0 correlation energy (triplet) =',EcAC(2)
write(*,'(2X,A50,F20.10)') 'AC@BSE@G0T0 correlation energy =',EcAC(1) + EcAC(2)
write(*,'(2X,A50,F20.10)') 'AC@BSE@G0T0 total energy =',ENuc + ERHF + EcAC(1) + EcAC(2)
write(*,*)'-------------------------------------------------------------------------------'
write(*,*)
end if
end if
end subroutine G0T0

View File

@ -635,7 +635,9 @@ program QuAcK
if(doG0T0) then
call cpu_time(start_G0T0)
call G0T0(eta,nBas,nC(1),nO(1),nV(1),nR(1),ENuc,ERHF,ERI_MO_basis,eHF)
call G0T0(doACFDT,exchange_kernel,doXBS,BSE,TDA, &
singlet_manifold,triplet_manifold,linGW,eta, &
nBas,nC(1),nO(1),nV(1),nR(1),nS(1),ENuc,ERHF,ERI_MO_basis,eHF)
call soG0T0(eta,nBas,nC(1),nO(1),nV(1),nR(1),ENuc,ERHF,ERI_MO_basis,eHF)
call cpu_time(end_G0T0)