mirror of
https://github.com/pfloos/quack
synced 2024-12-23 04:43:42 +01:00
RHF, UHF, and GHF search seem to work
This commit is contained in:
parent
7847710059
commit
925dc64bc8
@ -1,5 +1,5 @@
|
|||||||
# RHF UHF GHF ROHF
|
# RHF UHF GHF ROHF
|
||||||
F T F F
|
F F T F
|
||||||
# MP2 MP3
|
# MP2 MP3
|
||||||
F F
|
F F
|
||||||
# CCD pCCD DCD CCSD CCSD(T)
|
# CCD pCCD DCD CCSD CCSD(T)
|
||||||
|
@ -85,6 +85,7 @@ subroutine GHF_search(maxSCF,thresh,max_diis,guess_type,mix,level_shift,nNuc,ZNu
|
|||||||
|
|
||||||
unstab = .true.
|
unstab = .true.
|
||||||
guess = 0
|
guess = 0
|
||||||
|
mix = 0d0
|
||||||
|
|
||||||
do while(unstab)
|
do while(unstab)
|
||||||
|
|
||||||
@ -130,6 +131,7 @@ subroutine GHF_search(maxSCF,thresh,max_diis,guess_type,mix,level_shift,nNuc,ZNu
|
|||||||
ERI_MO(:,:,:,:) = ERI_MO(:,:,:,:) + ERI_tmp(:,:,:,:)
|
ERI_MO(:,:,:,:) = ERI_MO(:,:,:,:) + ERI_tmp(:,:,:,:)
|
||||||
|
|
||||||
deallocate(Ca,Cb,ERI_tmp)
|
deallocate(Ca,Cb,ERI_tmp)
|
||||||
|
call wall_time(end_AOtoMO)
|
||||||
|
|
||||||
t_AOtoMO = end_AOtoMO - start_AOtoMO
|
t_AOtoMO = end_AOtoMO - start_AOtoMO
|
||||||
write(*,'(A65,1X,F9.3,A8)') 'Total CPU time for AO to MO transformation = ',t_AOtoMO,' seconds'
|
write(*,'(A65,1X,F9.3,A8)') 'Total CPU time for AO to MO transformation = ',t_AOtoMO,' seconds'
|
||||||
@ -141,8 +143,8 @@ subroutine GHF_search(maxSCF,thresh,max_diis,guess_type,mix,level_shift,nNuc,ZNu
|
|||||||
|
|
||||||
ispin = 3
|
ispin = 3
|
||||||
|
|
||||||
call phLR_A(ispin,.false.,nBas,nC,nO,nV,nR,nS,1d0,e,ERI_MO,Aph)
|
call phLR_A(ispin,.false.,nBas2,nC,nO,nV,nR,nS,1d0,e,ERI_MO,Aph)
|
||||||
call phLR_B(ispin,.false.,nBas,nC,nO,nV,nR,nS,1d0,ERI_MO,Bph)
|
call phLR_B(ispin,.false.,nBas2,nC,nO,nV,nR,nS,1d0,ERI_MO,Bph)
|
||||||
|
|
||||||
AB(:,:) = Aph(:,:) + Bph(:,:)
|
AB(:,:) = Aph(:,:) + Bph(:,:)
|
||||||
|
|
||||||
@ -165,6 +167,7 @@ subroutine GHF_search(maxSCF,thresh,max_diis,guess_type,mix,level_shift,nNuc,ZNu
|
|||||||
|
|
||||||
write(*,'(1X,A40,1X)') 'Too bad, GHF solution is unstable!'
|
write(*,'(1X,A40,1X)') 'Too bad, GHF solution is unstable!'
|
||||||
write(*,'(1X,A40,1X,F15.10,A3)') 'Largest negative eigenvalue:',Om(1),' au'
|
write(*,'(1X,A40,1X,F15.10,A3)') 'Largest negative eigenvalue:',Om(1),' au'
|
||||||
|
write(*,'(1X,A40,1X,F15.10,A3)') 'E(GHF) = ',EHF,' au'
|
||||||
write(*,*)
|
write(*,*)
|
||||||
write(*,'(1X,A40,1X,A10)') 'Which one would you like to follow?','[Exit:0]'
|
write(*,'(1X,A40,1X,A10)') 'Which one would you like to follow?','[Exit:0]'
|
||||||
read(*,*) eig
|
read(*,*) eig
|
||||||
@ -179,11 +182,11 @@ subroutine GHF_search(maxSCF,thresh,max_diis,guess_type,mix,level_shift,nNuc,ZNu
|
|||||||
|
|
||||||
step = 1d0
|
step = 1d0
|
||||||
|
|
||||||
do mu=1,nBas
|
do mu=1,nBas2
|
||||||
ia = 0
|
ia = 0
|
||||||
do i=nC+1,nO
|
do i=nC+1,nO
|
||||||
kick = 0d0
|
kick = 0d0
|
||||||
do a=nO+1,nBas-nR
|
do a=nO+1,nBas2-nR
|
||||||
ia = ia + 1
|
ia = ia + 1
|
||||||
kick = kick + AB(ia,eig)*c(mu,a)
|
kick = kick + AB(ia,eig)*c(mu,a)
|
||||||
end do
|
end do
|
||||||
@ -195,6 +198,7 @@ subroutine GHF_search(maxSCF,thresh,max_diis,guess_type,mix,level_shift,nNuc,ZNu
|
|||||||
|
|
||||||
write(*,'(1X,A40,1X)') 'Well done, GHF solution is stable!'
|
write(*,'(1X,A40,1X)') 'Well done, GHF solution is stable!'
|
||||||
write(*,'(1X,A40,1X,F15.10,A3)') 'Smallest eigenvalue: ',Om(1),' au'
|
write(*,'(1X,A40,1X,F15.10,A3)') 'Smallest eigenvalue: ',Om(1),' au'
|
||||||
|
write(*,'(1X,A40,1X,F15.10,A3)') 'E(GHF) = ',EHF,' au'
|
||||||
|
|
||||||
unstab = .false.
|
unstab = .false.
|
||||||
|
|
||||||
|
@ -141,6 +141,7 @@ subroutine RHF_search(maxSCF,thresh,max_diis,guess_type,level_shift,nNuc,ZNuc,rN
|
|||||||
|
|
||||||
write(*,'(1X,A40,1X)') 'Too bad, RHF solution is unstable!'
|
write(*,'(1X,A40,1X)') 'Too bad, RHF solution is unstable!'
|
||||||
write(*,'(1X,A40,1X,F15.10,A3)') 'Largest negative eigenvalue:',Om(1),' au'
|
write(*,'(1X,A40,1X,F15.10,A3)') 'Largest negative eigenvalue:',Om(1),' au'
|
||||||
|
write(*,'(1X,A40,1X,F15.10,A3)') 'E(RHF) = ',EHF,' au'
|
||||||
write(*,*)
|
write(*,*)
|
||||||
write(*,'(1X,A40,1X,A10)') 'Which one would you like to follow?','[Exit:0]'
|
write(*,'(1X,A40,1X,A10)') 'Which one would you like to follow?','[Exit:0]'
|
||||||
read(*,*) eig
|
read(*,*) eig
|
||||||
@ -171,6 +172,7 @@ subroutine RHF_search(maxSCF,thresh,max_diis,guess_type,level_shift,nNuc,ZNuc,rN
|
|||||||
|
|
||||||
write(*,'(1X,A40,1X)') 'Well done, RHF solution is stable!'
|
write(*,'(1X,A40,1X)') 'Well done, RHF solution is stable!'
|
||||||
write(*,'(1X,A40,1X,F15.10,A3)') 'Smallest eigenvalue: ',Om(1),' au'
|
write(*,'(1X,A40,1X,F15.10,A3)') 'Smallest eigenvalue: ',Om(1),' au'
|
||||||
|
write(*,'(1X,A40,1X,F15.10,A3)') 'E(RHF) = ',EHF,' au'
|
||||||
|
|
||||||
unstab = .false.
|
unstab = .false.
|
||||||
|
|
||||||
|
@ -161,7 +161,8 @@ subroutine UHF_search(maxSCF,thresh,max_diis,guess_type,mix,level_shift,nNuc,ZNu
|
|||||||
if(minval(Om_sc(:)) < 0d0) then
|
if(minval(Om_sc(:)) < 0d0) then
|
||||||
|
|
||||||
write(*,'(1X,A40,1X)') 'Too bad, UHF solution is unstable!'
|
write(*,'(1X,A40,1X)') 'Too bad, UHF solution is unstable!'
|
||||||
write(*,'(1X,A40,1X,F10.6,A3)') 'Largest negative eigenvalue:',Om_sc(1),' au'
|
write(*,'(1X,A40,1X,F15.10,A3)') 'Largest negative eigenvalue:',Om_sc(1),' au'
|
||||||
|
write(*,'(1X,A40,1X,F15.10,A3)') 'E(UHF) = ',EHF,' au'
|
||||||
write(*,*)
|
write(*,*)
|
||||||
write(*,'(1X,A40,1X,A10)') 'Which one would you like to follow?','[Exit:0]'
|
write(*,'(1X,A40,1X,A10)') 'Which one would you like to follow?','[Exit:0]'
|
||||||
read(*,*) eig
|
read(*,*) eig
|
||||||
@ -208,6 +209,7 @@ subroutine UHF_search(maxSCF,thresh,max_diis,guess_type,mix,level_shift,nNuc,ZNu
|
|||||||
|
|
||||||
write(*,'(1X,A40,1X)') 'Well done, UHF solution is stable!'
|
write(*,'(1X,A40,1X)') 'Well done, UHF solution is stable!'
|
||||||
write(*,'(1X,A40,1X,F15.10,A3)') 'Smallest eigenvalue: ',Om_sc(1),' au'
|
write(*,'(1X,A40,1X,F15.10,A3)') 'Smallest eigenvalue: ',Om_sc(1),' au'
|
||||||
|
write(*,'(1X,A40,1X,F15.10,A3)') 'E(UHF) = ',EHF,' au'
|
||||||
|
|
||||||
unstab = .false.
|
unstab = .false.
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user