10
0
mirror of https://github.com/LCPQ/quantum_package synced 2024-11-13 17:43:55 +01:00

Small HF acceleration

This commit is contained in:
Anthony Scemama 2014-09-22 23:38:49 +02:00
parent 466fb8eb50
commit f99c4c16cf
2 changed files with 20 additions and 27 deletions

View File

@ -36,30 +36,24 @@ subroutine bielec_integrals_index_reverse(i,j,k,l,i1)
integer, intent(out) :: i(8),j(8),k(8),l(8)
integer*8, intent(in) :: i1
integer*8 :: i2,i3
real :: x
i = 0
x = 0.5*(sqrt(8.*real(i1)+1.)-1.)
i2 = ceiling(x)
i3 = i1 - ishft(i2*i2-i2,-1)
x = 0.5*(sqrt(8.*real(i2)+1.)-1.)
l(1) = ceiling(x)
i2 = ceiling(0.5*(sqrt(8.*real(i1)+1.)-1.))
l(1) = ceiling(0.5*(sqrt(8.*real(i2)+1.)-1.))
i3 = i1 - ishft(i2*i2-i2,-1)
k(1) = ceiling(0.5*(sqrt(8.*real(i3)+1.)-1.))
j(1) = i2 - ishft(l(1)*l(1)-l(1),-1)
x = 0.5*(sqrt(8.*real(i3)+1.)-1.)
k(1) = ceiling(x)
i(1) = i3 - ishft(k(1)*k(1)-k(1),-1)
!ijkl
i(2) = k(1) !kjil
j(2) = j(1)
k(2) = i(1)
l(2) = l(1)
i(2) = i(1) !ilkj
j(2) = l(1)
k(2) = k(1)
l(2) = j(1)
i(3) = i(1) !ilkj
j(3) = l(1)
k(3) = k(1)
l(3) = j(1)
i(3) = k(1) !kjil
j(3) = j(1)
k(3) = i(1)
l(3) = l(1)
i(4) = k(1) !klij
j(4) = l(1)
@ -71,15 +65,15 @@ subroutine bielec_integrals_index_reverse(i,j,k,l,i1)
k(5) = l(1)
l(5) = k(1)
i(6) = l(1) !lijk
j(6) = i(1)
k(6) = j(1)
l(6) = k(1)
i(6) = j(1) !jkli
j(6) = k(1)
k(6) = l(1)
l(6) = i(1)
i(7) = j(1) !jkli
j(7) = k(1)
k(7) = l(1)
l(7) = i(1)
i(7) = l(1) !lijk
j(7) = i(1)
k(7) = j(1)
l(7) = k(1)
i(8) = l(1) !lkji
j(8) = k(1)

View File

@ -151,7 +151,6 @@ END_PROVIDER
cycle
endif
values(1) = ao_bielec_integral(k,l,i,j)
! values(1) = ao_bielec_integral(k,i,l,j)
if (abs(values(1)) < ao_integrals_threshold) then
cycle
endif