mirror of
https://github.com/pfloos/quack
synced 2024-11-07 06:33:55 +01:00
ppURPA
This commit is contained in:
parent
d4c50fa39e
commit
86f501cb78
@ -1,5 +1,5 @@
|
||||
# RHF UHF KS MOM
|
||||
T F F F
|
||||
F T F F
|
||||
# MP2* MP3 MP2-F12
|
||||
F F F
|
||||
# CCD pCCD DCD CCSD CCSD(T)
|
||||
@ -13,9 +13,9 @@
|
||||
# G0F2* evGF2* qsGF2* G0F3 evGF3
|
||||
F F F F F
|
||||
# G0W0* evGW* qsGW* ufG0W0 ufGW
|
||||
F F F F F
|
||||
T F F F F
|
||||
# G0T0 evGT qsGT
|
||||
T F F
|
||||
F F F
|
||||
# MCMP2
|
||||
F
|
||||
# * unrestricted version available
|
||||
|
@ -1,11 +1,11 @@
|
||||
# HF: maxSCF thresh DIIS n_diis guess_type ortho_type mix_guess level_shift stability
|
||||
256 0.0000001 T 5 2 1 F 0.0 F
|
||||
256 0.0000001 T 5 1 1 T 0.0 F
|
||||
# MP:
|
||||
|
||||
# CC: maxSCF thresh DIIS n_diis
|
||||
64 0.00001 T 5
|
||||
# spin: TDA singlet triplet spin_conserved spin_flip
|
||||
F T T T T
|
||||
T T T T T
|
||||
# GF: maxSCF thresh DIIS n_diis lin eta renorm reg
|
||||
256 0.00001 T 5 T 0.0 3 F
|
||||
# GW: maxSCF thresh DIIS n_diis lin eta COHSEX SOSEX TDA_W G0W GW0 reg
|
||||
@ -15,6 +15,6 @@
|
||||
# ACFDT: AC Kx XBS
|
||||
F F T
|
||||
# BSE: BSE dBSE dTDA evDyn
|
||||
F F T F
|
||||
T F F F
|
||||
# MCMP2: nMC nEq nWalk dt nPrint iSeed doDrift
|
||||
1000000 100000 10 0.3 10000 1234 T
|
||||
|
@ -20,9 +20,10 @@ subroutine print_excitation(method,ispin,nS,Omega)
|
||||
if(ispin == 1) spin_manifold = 'singlet'
|
||||
if(ispin == 2) spin_manifold = 'triplet'
|
||||
if(ispin == 3) spin_manifold = 'alpha-beta'
|
||||
if(ispin == 4) spin_manifold = 'alpha-alpha'
|
||||
if(ispin == 4) spin_manifold = 'alpha-alpha'
|
||||
if(ispin == 5) spin_manifold = 'spin-conserved'
|
||||
if(ispin == 6) spin_manifold = 'spin-flip'
|
||||
if(ispin == 7) spin_manifold = 'beta-beta'
|
||||
|
||||
write(*,*)
|
||||
write(*,*)'-------------------------------------------------------------'
|
||||
|
@ -41,11 +41,7 @@ subroutine unrestricted_linear_response_B_pp(ispin,nBas,nC,nO,nV,nR,nPaa,nPab,nP
|
||||
|
||||
eF = 0d0
|
||||
|
||||
!-----------------------------------------------
|
||||
! Build B matrix for spin-conserved transitions
|
||||
!-----------------------------------------------
|
||||
|
||||
if(ispin == 1) then
|
||||
if(ispin == 3) then
|
||||
|
||||
! abab block
|
||||
|
||||
@ -67,11 +63,8 @@ subroutine unrestricted_linear_response_B_pp(ispin,nBas,nC,nO,nV,nR,nPaa,nPab,nP
|
||||
|
||||
end if
|
||||
|
||||
!-----------------------------------------------
|
||||
! Build B matrix for spin-flip transitions
|
||||
!-----------------------------------------------
|
||||
|
||||
if(ispin == 2) then
|
||||
if(ispin == 4) then
|
||||
|
||||
! aaaa block
|
||||
|
||||
@ -92,7 +85,7 @@ subroutine unrestricted_linear_response_B_pp(ispin,nBas,nC,nO,nV,nR,nPaa,nPab,nP
|
||||
end do
|
||||
end if
|
||||
|
||||
if (ispin == 3) then
|
||||
if (ispin == 7) then
|
||||
|
||||
! bbbb block
|
||||
|
||||
|
@ -37,11 +37,8 @@ subroutine unrestricted_linear_response_C_pp(ispin,nBas,nC,nO,nV,nR,nPaa,nPab,nP
|
||||
|
||||
|
||||
eF = 0d0
|
||||
!-----------------------------------------------
|
||||
! Build C matrix for spin-conserved transitions
|
||||
!-----------------------------------------------
|
||||
|
||||
if(ispin == 1) then
|
||||
if(ispin == 3) then
|
||||
|
||||
! abab block
|
||||
|
||||
@ -62,11 +59,7 @@ subroutine unrestricted_linear_response_C_pp(ispin,nBas,nC,nO,nV,nR,nPaa,nPab,nP
|
||||
|
||||
end if
|
||||
|
||||
!-----------------------------------------------
|
||||
! Build C matrix for spin-flip transitions
|
||||
!-----------------------------------------------
|
||||
|
||||
if(ispin == 2) then
|
||||
if(ispin == 4) then
|
||||
|
||||
! aaaa block
|
||||
|
||||
@ -90,7 +83,7 @@ subroutine unrestricted_linear_response_C_pp(ispin,nBas,nC,nO,nV,nR,nPaa,nPab,nP
|
||||
end if
|
||||
|
||||
|
||||
if (ispin == 3) then
|
||||
if (ispin == 7) then
|
||||
|
||||
! bbbb block
|
||||
|
||||
|
@ -38,11 +38,7 @@ subroutine unrestricted_linear_response_D_pp(ispin,nBas,nC,nO,nV,nR,nHaa,nHab,nH
|
||||
|
||||
eF = 0d0
|
||||
|
||||
!-----------------------------------------------
|
||||
! Build D matrix for spin-conserved transitions
|
||||
!-----------------------------------------------
|
||||
|
||||
if(ispin == 1) then
|
||||
if(ispin == 3) then
|
||||
|
||||
! abab block
|
||||
|
||||
@ -63,12 +59,7 @@ subroutine unrestricted_linear_response_D_pp(ispin,nBas,nC,nO,nV,nR,nHaa,nHab,nH
|
||||
|
||||
end if
|
||||
|
||||
|
||||
!-----------------------------------------------
|
||||
! Build D matrix for spin-flip transitions
|
||||
!-----------------------------------------------
|
||||
|
||||
if(ispin == 2) then
|
||||
if(ispin == 4) then
|
||||
|
||||
! aaaa block
|
||||
|
||||
@ -91,7 +82,7 @@ subroutine unrestricted_linear_response_D_pp(ispin,nBas,nC,nO,nV,nR,nHaa,nHab,nH
|
||||
end do
|
||||
end if
|
||||
|
||||
if (ispin == 3) then
|
||||
if (ispin == 7) then
|
||||
|
||||
! bbbb block
|
||||
|
||||
|
@ -51,82 +51,75 @@ subroutine ppURPA(TDA,doACFDT,spin_conserved,spin_flip,nBas,nC,nO,nV,nR,ENuc,EUH
|
||||
Ec_ppURPA(:) = 0d0
|
||||
EcAC(:) = 0d0
|
||||
|
||||
! Spin-conserved manifold
|
||||
!alpha-beta block
|
||||
|
||||
if(spin_conserved) then
|
||||
ispin = 1
|
||||
iblock = 3
|
||||
|
||||
ispin = 1
|
||||
iblock = 1
|
||||
nPab = nV(1)*nV(2)
|
||||
nHab = nO(1)*nO(2)
|
||||
|
||||
!Spin-conserved quantities
|
||||
|
||||
nPab = nV(1)*nV(2)
|
||||
nHab = nO(1)*nO(2)
|
||||
|
||||
nP_sc = nPab
|
||||
nH_sc = nHab
|
||||
nP_sc = nPab
|
||||
nH_sc = nHab
|
||||
|
||||
! Memory allocation
|
||||
|
||||
allocate(Omega1sc(nP_sc),X1sc(nP_sc,nP_sc),Y1sc(nH_sc,nP_sc), &
|
||||
Omega2sc(nH_sc),X2sc(nP_sc,nH_sc),Y2sc(nH_sc,nH_sc))
|
||||
allocate(Omega1sc(nP_sc),X1sc(nP_sc,nP_sc),Y1sc(nH_sc,nP_sc), &
|
||||
Omega2sc(nH_sc),X2sc(nP_sc,nH_sc),Y2sc(nH_sc,nH_sc))
|
||||
|
||||
call unrestricted_linear_response_pp(iblock,TDA,nBas,nC,nO,nV,nR,nPaa,nPab,nPbb, &
|
||||
nP_sc,nHaa,nHab,nHbb,nH_sc,1d0,e,ERI_aaaa, &
|
||||
ERI_aabb,ERI_bbbb,Omega1sc,X1sc,Y1sc, &
|
||||
Omega2sc,X2sc,Y2sc,Ec_ppURPA(ispin))
|
||||
call unrestricted_linear_response_pp(iblock,TDA,nBas,nC,nO,nV,nR,nPaa,nPab,nPbb, &
|
||||
nP_sc,nHaa,nHab,nHbb,nH_sc,1d0,e,ERI_aaaa, &
|
||||
ERI_aabb,ERI_bbbb,Omega1sc,X1sc,Y1sc, &
|
||||
Omega2sc,X2sc,Y2sc,Ec_ppURPA(ispin))
|
||||
|
||||
call print_excitation('pp-RPA (N+2)',5,nP_sc,Omega1sc)
|
||||
call print_excitation('pp-RPA (N-2)',5,nH_sc,Omega2sc)
|
||||
call print_excitation('pp-RPA (N+2)',iblock,nP_sc,Omega1sc)
|
||||
call print_excitation('pp-RPA (N-2)',iblock,nH_sc,Omega2sc)
|
||||
|
||||
endif
|
||||
!alpha-alpha block
|
||||
|
||||
! Spin-flip manifold
|
||||
ispin = 2
|
||||
iblock = 4
|
||||
|
||||
if(spin_flip) then
|
||||
nPaa = nV(1)*(nV(1)-1)/2
|
||||
nPbb = nV(2)*(nV(2)-1)/2
|
||||
|
||||
ispin = 2
|
||||
iblock = 2
|
||||
nP_sf = nPaa
|
||||
|
||||
!Spin-flip quantities
|
||||
nHaa = nO(1)*(nO(1)-1)/2
|
||||
nHbb = nO(2)*(nO(2)-1)/2
|
||||
|
||||
nPaa = nV(1)*(nV(1)-1)/2
|
||||
nPbb = nV(2)*(nV(2)-1)/2
|
||||
nH_sf = nHaa
|
||||
|
||||
nP_sf = nPaa
|
||||
allocate(Omega1sf(nP_sf),X1sf(nP_sf,nP_sf),Y1sf(nH_sf,nP_sf), &
|
||||
Omega2sf(nH_sf),X2sf(nP_sf,nH_sf),Y2sf(nH_sf,nH_sf))
|
||||
|
||||
nHaa = nO(1)*(nO(1)-1)/2
|
||||
nHbb = nO(2)*(nO(2)-1)/2
|
||||
call unrestricted_linear_response_pp(iblock,TDA,nBas,nC,nO,nV,nR,nPaa,nPab,nPbb, &
|
||||
nP_sf,nHaa,nHab,nHbb,nH_sf,1d0,e,ERI_aaaa, &
|
||||
ERI_aabb,ERI_bbbb,Omega1sf,X1sf,Y1sf, &
|
||||
Omega2sf,X2sf,Y2sf,Ec_ppURPA(ispin))
|
||||
|
||||
nH_sf = nHaa
|
||||
call print_excitation('pp-RPA (N+2)',iblock,nP_sf,Omega1sf)
|
||||
call print_excitation('pp-RPA (N-2)',iblock,nH_sf,Omega2sf)
|
||||
|
||||
allocate(Omega1sf(nP_sf),X1sf(nP_sf,nP_sf),Y1sf(nH_sf,nP_sf), &
|
||||
Omega2sf(nH_sf),X2sf(nP_sf,nH_sf),Y2sf(nH_sf,nH_sf))
|
||||
deallocate(Omega1sf,X1sf,Y1sf,Omega2sf,X2sf,Y2sf)
|
||||
|
||||
call unrestricted_linear_response_pp(iblock,TDA,nBas,nC,nO,nV,nR,nPaa,nPab,nPbb, &
|
||||
nP_sf,nHaa,nHab,nHbb,nH_sf,1d0,e,ERI_aaaa, &
|
||||
ERI_aabb,ERI_bbbb,Omega1sf,X1sf,Y1sf, &
|
||||
Omega2sf,X2sf,Y2sf,Ec_ppURPA(ispin))
|
||||
!beta-beta block
|
||||
|
||||
deallocate(Omega1sf,X1sf,Y1sf,Omega2sf,X2sf,Y2sf)
|
||||
iblock = 7
|
||||
|
||||
iblock = 3
|
||||
nP_sf = nPbb
|
||||
nH_sf = nHbb
|
||||
|
||||
nP_sf = nPbb
|
||||
nH_sf = nHbb
|
||||
allocate(Omega1sf(nP_sf),X1sf(nP_sf,nP_sf),Y1sf(nH_sf,nP_sf), &
|
||||
Omega2sf(nH_sf),X2sf(nP_sf,nH_sf),Y2sf(nH_sf,nH_sf))
|
||||
|
||||
allocate(Omega1sf(nP_sf),X1sf(nP_sf,nP_sf),Y1sf(nH_sf,nP_sf), &
|
||||
Omega2sf(nH_sf),X2sf(nP_sf,nH_sf),Y2sf(nH_sf,nH_sf))
|
||||
call unrestricted_linear_response_pp(iblock,TDA,nBas,nC,nO,nV,nR,nPaa,nPab,nPbb,&
|
||||
nP_sf,nHaa,nHab,nHbb,nH_sf,1d0,e,ERI_aaaa,&
|
||||
ERI_aabb,ERI_bbbb,Omega1sf,X1sf,Y1sf,&
|
||||
Omega2sf,X2sf,Y2sf,Ec_ppURPA(ispin))
|
||||
|
||||
call unrestricted_linear_response_pp(iblock,TDA,nBas,nC,nO,nV,nR,nPaa,nPab,nPbb,&
|
||||
nP_sf,nHaa,nHab,nHbb,nH_sf,1d0,e,ERI_aaaa,&
|
||||
ERI_aabb,ERI_bbbb,Omega1sf,X1sf,Y1sf,&
|
||||
Omega2sf,X2sf,Y2sf,Ec_ppURPA(ispin))
|
||||
|
||||
call print_excitation('pp-RPA (N+2)',6,nP_sf,Omega1sf)
|
||||
call print_excitation('pp-RPA (N-2)',6,nH_sf,Omega2sf)
|
||||
|
||||
endif
|
||||
call print_excitation('pp-RPA (N+2)',iblock,nP_sf,Omega1sf)
|
||||
call print_excitation('pp-RPA (N-2)',iblock,nH_sf,Omega2sf)
|
||||
|
||||
write(*,*)
|
||||
write(*,*)'-------------------------------------------------------------------------------'
|
||||
@ -159,5 +152,4 @@ subroutine ppURPA(TDA,doACFDT,spin_conserved,spin_flip,nBas,nC,nO,nV,nR,ENuc,EUH
|
||||
|
||||
! end if
|
||||
|
||||
|
||||
end subroutine ppURPA
|
||||
|
Loading…
Reference in New Issue
Block a user