mirror of
https://github.com/pfloos/quack
synced 2024-12-22 12:23:42 +01:00
debugging AC@BSE
This commit is contained in:
parent
0cbd4fb10f
commit
e2617c1113
@ -1,4 +1,4 @@
|
|||||||
2
|
2
|
||||||
|
|
||||||
H 0.00000000 -0.37500000 0.00000000
|
H 0.00000000 0.0 0.0
|
||||||
H 0.00000000 0.37500000 0.00000000
|
H 0.00000000 0.0 0.74031892
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
2
|
2
|
||||||
|
|
||||||
Li 0.0000 0.0000 0.0000
|
Li 0.0000 0.0000 0.0000
|
||||||
F 0.0000 0.0000 1.58753
|
F 0.0000 0.0000 1.5732438
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
2
|
2
|
||||||
|
|
||||||
Li 0.0000 0.0000 0.0000
|
Li 0.0000 0.0000 0.0000
|
||||||
H 0.0000 0.0000 1.5921
|
H 0.0000 0.0000 1.5965276
|
||||||
|
@ -102,8 +102,7 @@ subroutine RG0W0(dotest,doACFDT,exchange_kernel,doXBS,dophBSE,dophBSE2,TDA_W,TDA
|
|||||||
! Compute screening !
|
! Compute screening !
|
||||||
!-------------------!
|
!-------------------!
|
||||||
|
|
||||||
call phLR_A(ispin,dRPA,nBas,nC,nO,nV,nR,nS,1d0,eHF,ERI,Aph)
|
call phLR_A(ispin,dRPA,nBas,nC,nO,nV,nR,nS,1d0,eHF,ERI,Aph)
|
||||||
|
|
||||||
if(.not.TDA_W) call phLR_B(ispin,dRPA,nBas,nC,nO,nV,nR,nS,1d0,ERI,Bph)
|
if(.not.TDA_W) call phLR_B(ispin,dRPA,nBas,nC,nO,nV,nR,nS,1d0,ERI,Bph)
|
||||||
|
|
||||||
call phLR(TDA_W,nS,Aph,Bph,EcRPA,Om,XpY,XmY)
|
call phLR(TDA_W,nS,Aph,Bph,EcRPA,Om,XpY,XmY)
|
||||||
@ -160,8 +159,7 @@ subroutine RG0W0(dotest,doACFDT,exchange_kernel,doXBS,dophBSE,dophBSE2,TDA_W,TDA
|
|||||||
|
|
||||||
! Compute the RPA correlation energy
|
! Compute the RPA correlation energy
|
||||||
|
|
||||||
call phLR_A(ispin,dRPA,nBas,nC,nO,nV,nR,nS,1d0,eGW,ERI,Aph)
|
call phLR_A(ispin,dRPA,nBas,nC,nO,nV,nR,nS,1d0,eGW,ERI,Aph)
|
||||||
|
|
||||||
if(.not.TDA_W) call phLR_B(ispin,dRPA,nBas,nC,nO,nV,nR,nS,1d0,ERI,Bph)
|
if(.not.TDA_W) call phLR_B(ispin,dRPA,nBas,nC,nO,nV,nR,nS,1d0,ERI,Bph)
|
||||||
|
|
||||||
call phLR(TDA_W,nS,Aph,Bph,EcRPA,Om,XpY,XmY)
|
call phLR(TDA_W,nS,Aph,Bph,EcRPA,Om,XpY,XmY)
|
||||||
@ -210,7 +208,7 @@ subroutine RG0W0(dotest,doACFDT,exchange_kernel,doXBS,dophBSE,dophBSE2,TDA_W,TDA
|
|||||||
|
|
||||||
end if
|
end if
|
||||||
|
|
||||||
call RGW_phACFDT(exchange_kernel,doXBS,dRPA,TDA_W,TDA,dophBSE,singlet,triplet,eta,nBas,nC,nO,nV,nR,nS,ERI,eHF,eGW,EcBSE)
|
call RGW_phACFDT(exchange_kernel,doXBS,TDA_W,TDA,singlet,triplet,eta,nBas,nC,nO,nV,nR,nS,ERI,eHF,eGW,EcBSE)
|
||||||
|
|
||||||
write(*,*)
|
write(*,*)
|
||||||
write(*,*)'-------------------------------------------------------------------------------'
|
write(*,*)'-------------------------------------------------------------------------------'
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
subroutine RGW_phACFDT(exchange_kernel,doXBS,dRPA,TDA_W,TDA,BSE,singlet,triplet,eta,nBas,nC,nO,nV,nR,nS,ERI,eW,e,EcAC)
|
subroutine RGW_phACFDT(exchange_kernel,doXBS,TDA_W,TDA,singlet,triplet,eta,nBas,nC,nO,nV,nR,nS,ERI,eW,eGW,EcAC)
|
||||||
|
|
||||||
! Compute the correlation energy via the adiabatic connection fluctuation dissipation theorem
|
! Compute the correlation energy via the adiabatic connection fluctuation dissipation theorem
|
||||||
|
|
||||||
@ -10,10 +10,8 @@ subroutine RGW_phACFDT(exchange_kernel,doXBS,dRPA,TDA_W,TDA,BSE,singlet,triplet,
|
|||||||
|
|
||||||
logical,intent(in) :: doXBS
|
logical,intent(in) :: doXBS
|
||||||
logical,intent(in) :: exchange_kernel
|
logical,intent(in) :: exchange_kernel
|
||||||
logical,intent(in) :: dRPA
|
|
||||||
logical,intent(in) :: TDA_W
|
logical,intent(in) :: TDA_W
|
||||||
logical,intent(in) :: TDA
|
logical,intent(in) :: TDA
|
||||||
logical,intent(in) :: BSE
|
|
||||||
logical,intent(in) :: singlet
|
logical,intent(in) :: singlet
|
||||||
logical,intent(in) :: triplet
|
logical,intent(in) :: triplet
|
||||||
|
|
||||||
@ -25,11 +23,12 @@ subroutine RGW_phACFDT(exchange_kernel,doXBS,dRPA,TDA_W,TDA,BSE,singlet,triplet,
|
|||||||
integer,intent(in) :: nR
|
integer,intent(in) :: nR
|
||||||
integer,intent(in) :: nS
|
integer,intent(in) :: nS
|
||||||
double precision,intent(in) :: eW(nBas)
|
double precision,intent(in) :: eW(nBas)
|
||||||
double precision,intent(in) :: e(nBas)
|
double precision,intent(in) :: eGW(nBas)
|
||||||
double precision,intent(in) :: ERI(nBas,nBas,nBas,nBas)
|
double precision,intent(in) :: ERI(nBas,nBas,nBas,nBas)
|
||||||
|
|
||||||
! Local variables
|
! Local variables
|
||||||
|
|
||||||
|
logical :: dRPA = .false.
|
||||||
logical :: dRPA_W = .true.
|
logical :: dRPA_W = .true.
|
||||||
integer :: ispin
|
integer :: ispin
|
||||||
integer :: isp_W
|
integer :: isp_W
|
||||||
@ -77,7 +76,6 @@ subroutine RGW_phACFDT(exchange_kernel,doXBS,dRPA,TDA_W,TDA,BSE,singlet,triplet,
|
|||||||
! Compute (singlet) RPA screening
|
! Compute (singlet) RPA screening
|
||||||
|
|
||||||
isp_W = 1
|
isp_W = 1
|
||||||
EcRPA = 0d0
|
|
||||||
|
|
||||||
call phLR_A(isp_W,dRPA_W,nBas,nC,nO,nV,nR,nS,1d0,eW,ERI,Aph)
|
call phLR_A(isp_W,dRPA_W,nBas,nC,nO,nV,nR,nS,1d0,eW,ERI,Aph)
|
||||||
if(.not.TDA_W) call phLR_B(isp_W,dRPA_W,nBas,nC,nO,nV,nR,nS,1d0,ERI,Bph)
|
if(.not.TDA_W) call phLR_B(isp_W,dRPA_W,nBas,nC,nO,nV,nR,nS,1d0,ERI,Bph)
|
||||||
@ -120,6 +118,9 @@ subroutine RGW_phACFDT(exchange_kernel,doXBS,dRPA,TDA_W,TDA,BSE,singlet,triplet,
|
|||||||
|
|
||||||
end if
|
end if
|
||||||
|
|
||||||
|
call phLR_A(ispin,dRPA,nBas,nC,nO,nV,nR,nS,lambda,eGW,ERI,Aph)
|
||||||
|
if(.not.TDA) call phLR_B(ispin,dRPA,nBas,nC,nO,nV,nR,nS,lambda,ERI,Bph)
|
||||||
|
|
||||||
Aph(:,:) = Aph(:,:) + KA(:,:)
|
Aph(:,:) = Aph(:,:) + KA(:,:)
|
||||||
if(.not.TDA) Bph(:,:) = Bph(:,:) + KB(:,:)
|
if(.not.TDA) Bph(:,:) = Bph(:,:) + KB(:,:)
|
||||||
|
|
||||||
@ -174,6 +175,9 @@ subroutine RGW_phACFDT(exchange_kernel,doXBS,dRPA,TDA_W,TDA,BSE,singlet,triplet,
|
|||||||
|
|
||||||
end if
|
end if
|
||||||
|
|
||||||
|
call phLR_A(ispin,dRPA,nBas,nC,nO,nV,nR,nS,lambda,eGW,ERI,Aph)
|
||||||
|
if(.not.TDA) call phLR_B(ispin,dRPA,nBas,nC,nO,nV,nR,nS,lambda,ERI,Bph)
|
||||||
|
|
||||||
Aph(:,:) = Aph(:,:) + KA(:,:)
|
Aph(:,:) = Aph(:,:) + KA(:,:)
|
||||||
if(.not.TDA) Bph(:,:) = Bph(:,:) + KB(:,:)
|
if(.not.TDA) Bph(:,:) = Bph(:,:) + KB(:,:)
|
||||||
|
|
||||||
|
@ -46,6 +46,7 @@ subroutine RGW_phBSE_static_kernel_A(eta,nBas,nC,nO,nV,nR,nS,lambda,ERI,Om,rho,K
|
|||||||
chi = chi + rho(i,j,kc)*rho(a,b,kc)*Om(kc)/eps
|
chi = chi + rho(i,j,kc)*rho(a,b,kc)*Om(kc)/eps
|
||||||
end do
|
end do
|
||||||
|
|
||||||
|
! KA(ia,jb) = 4d0*chi
|
||||||
KA(ia,jb) = 4d0*lambda*chi
|
KA(ia,jb) = 4d0*lambda*chi
|
||||||
|
|
||||||
end do
|
end do
|
||||||
|
@ -46,6 +46,7 @@ subroutine RGW_phBSE_static_kernel_B(eta,nBas,nC,nO,nV,nR,nS,lambda,ERI,Om,rho,K
|
|||||||
chi = chi + rho(i,b,kc)*rho(a,j,kc)*Om(kc)/eps
|
chi = chi + rho(i,b,kc)*rho(a,j,kc)*Om(kc)/eps
|
||||||
end do
|
end do
|
||||||
|
|
||||||
|
! KB(ia,jb) = 4d0*chi
|
||||||
KB(ia,jb) = 4d0*lambda*chi
|
KB(ia,jb) = 4d0*lambda*chi
|
||||||
|
|
||||||
end do
|
end do
|
||||||
|
@ -385,8 +385,7 @@ subroutine SRG_qsRGW(dotest,maxSCF,thresh,max_diis,doACFDT,exchange_kernel,doXBS
|
|||||||
|
|
||||||
end if
|
end if
|
||||||
|
|
||||||
call RGW_phACFDT(exchange_kernel, doXBS, .true., TDA_W, TDA, BSE, singlet, triplet, &
|
call RGW_phACFDT(exchange_kernel,doXBS,TDA_W,TDA,singlet,triplet,eta,nOrb,nC,nO,nV,nR,nS,ERI_MO,eGW,eGW,EcBSE)
|
||||||
eta, nOrb, nC, nO, nV, nR, nS, ERI_MO, eGW, eGW, EcBSE)
|
|
||||||
|
|
||||||
write(*,*)
|
write(*,*)
|
||||||
write(*,*)'-------------------------------------------------------------------------------'
|
write(*,*)'-------------------------------------------------------------------------------'
|
||||||
|
@ -255,7 +255,7 @@ subroutine evRGW(dotest,maxSCF,thresh,max_diis,doACFDT,exchange_kernel,doXBS,dop
|
|||||||
|
|
||||||
end if
|
end if
|
||||||
|
|
||||||
call RGW_phACFDT(exchange_kernel,doXBS,dRPA,TDA_W,TDA,dophBSE,singlet,triplet,eta,nBas,nC,nO,nV,nR,nS,ERI,eGW,eGW,EcBSE)
|
call RGW_phACFDT(exchange_kernel,doXBS,TDA_W,TDA,singlet,triplet,eta,nBas,nC,nO,nV,nR,nS,ERI,eGW,eGW,EcBSE)
|
||||||
|
|
||||||
write(*,*)
|
write(*,*)
|
||||||
write(*,*)'-------------------------------------------------------------------------------'
|
write(*,*)'-------------------------------------------------------------------------------'
|
||||||
|
@ -351,8 +351,7 @@ subroutine qsRGW(dotest, maxSCF, thresh, max_diis, doACFDT, exchange_kernel, doX
|
|||||||
|
|
||||||
end if
|
end if
|
||||||
|
|
||||||
call RGW_phACFDT(exchange_kernel, doXBS, .true., TDA_W, TDA, dophBSE, singlet, triplet, &
|
call RGW_phACFDT(exchange_kernel,doXBS,TDA_W,TDA,singlet,triplet,eta,nOrb,nC,nO,nV,nR,nS,ERI_MO,eGW,eGW,EcBSE)
|
||||||
eta, nOrb, nC, nO, nV, nR, nS, ERI_MO, eGW, eGW, EcBSE)
|
|
||||||
|
|
||||||
write(*,*)
|
write(*,*)
|
||||||
write(*,*)'-------------------------------------------------------------------------------'
|
write(*,*)'-------------------------------------------------------------------------------'
|
||||||
|
Loading…
Reference in New Issue
Block a user