4
1
mirror of https://github.com/pfloos/quack synced 2024-06-26 15:12:17 +02:00
quack/src/MP/UMP.f90

68 lines
2.0 KiB
Fortran
Raw Normal View History

2023-11-11 23:00:00 +01:00
subroutine UMP(dotest,doMP2,doMP3,regularize,nBas,nC,nO,nV,nR,ERI_aaaa,ERI_aabb,ERI_bbbb,ENuc,EHF,epsHF)
2023-07-17 14:21:39 +02:00
! Moller-Plesset module
implicit none
include 'parameters.h'
! Input variables
2023-11-11 23:00:00 +01:00
logical,intent(in) :: dotest
2023-07-17 14:21:39 +02:00
logical,intent(in) :: doMP2
logical,intent(in) :: doMP3
logical,intent(in) :: regularize
integer,intent(in) :: nBas
integer,intent(in) :: nC(nspin)
integer,intent(in) :: nO(nspin)
integer,intent(in) :: nV(nspin)
integer,intent(in) :: nR(nspin)
double precision,intent(in) :: ENuc
double precision,intent(in) :: EHF
double precision,intent(in) :: epsHF(nBas,nspin)
2023-07-17 14:21:39 +02:00
double precision,intent(in) :: ERI_aaaa(nBas,nBas,nBas,nBas)
double precision,intent(in) :: ERI_aabb(nBas,nBas,nBas,nBas)
double precision,intent(in) :: ERI_bbbb(nBas,nBas,nBas,nBas)
! Local variables
2023-07-22 22:19:46 +02:00
double precision :: start_MP ,end_MP ,t_MP
2023-10-27 13:35:10 +02:00
double precision :: Ec(nsp)
2023-07-22 22:19:46 +02:00
2023-07-17 14:21:39 +02:00
! Output variables
!------------------------------------------------------------------------
! Compute MP3 energy
!------------------------------------------------------------------------
if(doMP2) then
2023-07-22 22:19:46 +02:00
2023-07-31 16:01:12 +02:00
call wall_time(start_MP)
2023-11-11 23:00:00 +01:00
call UMP2(dotest,nBas,nC,nO,nV,nR,ERI_aaaa,ERI_aabb,ERI_bbbb,ENuc,EHF,epsHF,Ec)
2023-07-31 16:01:12 +02:00
call wall_time(end_MP)
2023-07-22 22:19:46 +02:00
t_MP = end_MP - start_MP
write(*,'(A65,1X,F9.3,A8)') 'Total CPU time for MP2 = ',t_MP,' seconds'
write(*,*)
2023-07-17 14:21:39 +02:00
end if
!------------------------------------------------------------------------
! Compute MP3 energy
!------------------------------------------------------------------------
if(doMP3) then
2023-07-31 16:01:12 +02:00
call wall_time(start_MP)
write(*,*) 'MP3 NYI for UHF reference'
2023-07-31 16:01:12 +02:00
call wall_time(end_MP)
2023-07-22 22:19:46 +02:00
t_MP = end_MP - start_MP
write(*,'(A65,1X,F9.3,A8)') 'Total CPU time for MP2 = ',t_MP,' seconds'
write(*,*)
2023-07-17 14:21:39 +02:00
end if
end subroutine