10
0
mirror of https://gitlab.com/scemama/eplf synced 2024-10-31 19:23:55 +01:00

Improved AO overlap

This commit is contained in:
Anthony Scemama 2010-10-27 18:16:57 +02:00
parent 42d8ba45ec
commit dad4163808
5 changed files with 16 additions and 29 deletions

Binary file not shown.

Binary file not shown.

View File

@ -241,8 +241,8 @@ BEGIN_PROVIDER [ real, eplf_value_p ]
aa = min(1.d0,aa)
ab = min(1.d0,ab)
aa = -dlog(aa)
ab = -dlog(ab)
aa = dsqrt(aa)
ab = -dlog(ab)
ab = dsqrt(ab)
eplf_value_p = (aa-ab)/(aa+ab+eps)
else
@ -381,28 +381,6 @@ double precision function ao_eplf_integral_primitive_oneD(a,xa,i,b,xb,j,gmma,xr)
end function
double precision function rint(i,xa,a,j,xb,b,xr,gmma)
implicit double precision(a-h,o-z)
include 'constants.F'
beta=a+b+gmma
w=1.d0/dsqrt(beta)
alpha=a*xa**2+b*xb**2+gmma*xr**2
delta=xa*a+xb*b+xr*gmma
u=delta/beta-xa
v=delta/beta-xb
ac=0.d0
do n=0,i
do m=0,j
if(mod(n+m,2).eq.0)then
k=(n+m)/2
f=binom(n,i)*binom(m,j)*fact2(n+m-1)
ac=ac+u**(i-n)*v**(j-m)*w**(n+m)*f/2.d0**k
endif
enddo
enddo
rint=ac*dsqrt(pi)*w*dexp(-alpha+delta**2/beta)
end
double precision function ao_eplf_integral(i,j,gmma,center)
implicit none

View File

@ -141,7 +141,7 @@ double precision function primitive_overlap_oneD(a,xa,i,b,xb,j)
real :: xp
real :: p
double precision :: S(0:i+1,0:j)
double precision :: inv_p, di(max(i,j)), dj(j)
double precision :: inv_p, di(max(i,j)), dj(j), c
ASSERT (a>0.)
ASSERT (b>0.)
@ -153,15 +153,24 @@ double precision function primitive_overlap_oneD(a,xa,i,b,xb,j)
xp = (a*xa+b*xb)
inv_p = 1.d0/p
xp = xp*inv_p
S(0,0) = dexp(-a*b*inv_p*(xa-xb)**2)* dsqrt(pi*inv_p)
c = a*b*inv_p*(xa-xb)**2
!if ( c > 32.d0 ) then ! Cut-off on exp(-32)
! primitive_overlap_oneD = 0.d0
! return
!endif
c = dexp(-c)
S(0,0) = 1.d0
! Obara-Saika recursion
if (i>0) then
S(1,0) = (xp-xa) * S(0,0)
S(1,0) = xp-xa
endif
if (j>0) then
S(0,1) = (xp-xb) * S(0,0)
S(0,1) = xp-xb
endif
do ii=1,max(i,j)
@ -187,7 +196,7 @@ double precision function primitive_overlap_oneD(a,xa,i,b,xb,j)
enddo
enddo
primitive_overlap_oneD = S(i,j)
primitive_overlap_oneD = S(i,j)*c* dsqrt(pi*inv_p)
end function

View File

@ -1 +1 @@
VERSION=1.0.3
VERSION=1.0.4