mirror of
https://github.com/LCPQ/quantum_package
synced 2024-12-23 04:43:50 +01:00
Gain a Major 50% in int integral
This commit is contained in:
parent
17155b5ec1
commit
bd95f3f86e
@ -1905,7 +1905,8 @@ double precision function int_prod_bessel(l,gam,n,m,a,b,arg)
|
||||
double precision int,intold,sum,coef_nk,crochet,u,int_prod_bessel_large,freal,arg
|
||||
double precision dump
|
||||
|
||||
double precision, allocatable :: temp_array(:)
|
||||
double precision, allocatable :: temp_array_a(:)
|
||||
double precision, allocatable :: temp_array_b(:)
|
||||
|
||||
logical done
|
||||
|
||||
@ -1935,20 +1936,19 @@ double precision function int_prod_bessel(l,gam,n,m,a,b,arg)
|
||||
done=.false.
|
||||
kcp=0
|
||||
|
||||
allocate( temp_array(0:101))
|
||||
allocate( temp_array_a(0:100))
|
||||
allocate( temp_array_b(0+m:200+m))
|
||||
|
||||
do while (.not.done)
|
||||
|
||||
kcp=kcp+1
|
||||
sum=0.d0
|
||||
|
||||
dump = a**n
|
||||
do k=q,q+1
|
||||
temp_array(k) = coef_nk(n,k)*dump*(a**(2*k))
|
||||
enddo
|
||||
temp_array_a(q) = coef_nk(n,q)*(a**(n+2*q))
|
||||
temp_array_b(m+2*q) = coef_nk(m,q)*b**(m+2*q)
|
||||
|
||||
do k=0,q
|
||||
sum=sum+temp_array(k)*coef_nk(m,q-k)*b**(m-2*k+2*q)
|
||||
sum=sum+temp_array_a(k)*temp_array_b(m-2*k+2*q)
|
||||
enddo
|
||||
|
||||
int=int+sum*crochet(2*q+n+m+l,gam)
|
||||
@ -1963,7 +1963,8 @@ double precision function int_prod_bessel(l,gam,n,m,a,b,arg)
|
||||
|
||||
enddo
|
||||
|
||||
deallocate(temp_array)
|
||||
deallocate(temp_array_a)
|
||||
deallocate(temp_array_b)
|
||||
|
||||
int_prod_bessel=int*freal
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user