1
0
mirror of https://gitlab.com/scemama/qp_plugins_scemama.git synced 2024-12-23 12:54:35 +01:00
qp_plugins_scemama/devel/cc/form_T.irp.f

44 lines
997 B
FortranFixed
Raw Normal View History

2019-09-14 14:15:25 +02:00
subroutine form_T(ub,ubb,EcCCT)
2019-09-09 16:51:15 +02:00
! Compute (T) correction
implicit none
! Input variables
2019-09-14 14:15:25 +02:00
double precision,intent(in) :: ub(spin_occ_num,spin_occ_num,spin_occ_num,spin_vir_num,spin_vir_num,spin_vir_num)
double precision,intent(in) :: ubb(spin_occ_num,spin_occ_num,spin_occ_num,spin_vir_num,spin_vir_num,spin_vir_num)
2019-09-09 16:51:15 +02:00
! Local variables
integer :: i,j,k,l
integer :: a,b,c,d
! Output variables
double precision,intent(out) :: EcCCT
EcCCT = 0d0
2019-09-14 14:15:25 +02:00
do c=1,spin_vir_num
do b=1,spin_vir_num
do a=1,spin_vir_num
do k=1,spin_occ_num
do j=1,spin_occ_num
do i=1,spin_occ_num
2019-09-09 16:51:15 +02:00
EcCCT = EcCCT &
+ (ub(i,j,k,a,b,c) + ubb(i,j,k,a,b,c)) &
* ubb(i,j,k,a,b,c)/delta_OOOVVV(i,j,k,a,b,c)
end do
end do
end do
end do
end do
end do
EcCCT = - EcCCT/36d0
end subroutine form_T