mirror of
https://github.com/LCPQ/quantum_package
synced 2024-11-19 04:22:36 +01:00
Merge branch 'scemama-master'
This commit is contained in:
commit
2b32318cb9
4
ocaml/.merlin
Normal file
4
ocaml/.merlin
Normal file
@ -0,0 +1,4 @@
|
|||||||
|
PKG core ZMQ cryptokit
|
||||||
|
B _build/
|
||||||
|
|
||||||
|
|
@ -1,8 +1 @@
|
|||||||
* The atomic orbitals are normalized:
|
|
||||||
|
|
||||||
.. math::
|
|
||||||
|
|
||||||
\int \left(\chi_i({\bf r}) \right)^2 dr = 1
|
|
||||||
|
|
||||||
* The AO coefficients in the EZFIO files are not necessarily normalized and are normalized after reading
|
* The AO coefficients in the EZFIO files are not necessarily normalized and are normalized after reading
|
||||||
* The AO coefficients and exponents are ordered in increasing order of exponents
|
|
||||||
|
@ -17,21 +17,19 @@ The AO coefficients are normalized as:
|
|||||||
|
|
||||||
{\tilde c}_{ki} = \frac{c_{ki}}{ \int \left( (x-X_A)^a (y-Y_A)^b (z-Z_A)^c e^{-\gamma_{ki} |{\bf r} - {\bf R}_A|^2} \right)^2} dr
|
{\tilde c}_{ki} = \frac{c_{ki}}{ \int \left( (x-X_A)^a (y-Y_A)^b (z-Z_A)^c e^{-\gamma_{ki} |{\bf r} - {\bf R}_A|^2} \right)^2} dr
|
||||||
|
|
||||||
|
Warning: ``ao_coef`` contains the AO coefficients given in input. These do not
|
||||||
|
include the normalization constant of the AO. The ``ao_coef_normalized`` includes
|
||||||
|
this normalization factor.
|
||||||
|
|
||||||
|
The AOs are also sorted by increasing exponent to accelerate the calculation of
|
||||||
|
the two electron integrals.
|
||||||
|
|
||||||
Assumptions
|
Assumptions
|
||||||
===========
|
===========
|
||||||
|
|
||||||
.. Do not edit this section. It was auto-generated from the
|
.. Do not edit this section. It was auto-generated from the
|
||||||
.. NEEDED_MODULES file.
|
.. NEEDED_MODULES file.
|
||||||
|
|
||||||
* The atomic orbitals are normalized:
|
|
||||||
|
|
||||||
.. math::
|
|
||||||
|
|
||||||
\int \left(\chi_i({\bf r}) \right)^2 dr = 1
|
|
||||||
|
|
||||||
* The AO coefficients in the EZFIO files are not necessarily normalized and are normalized after reading
|
|
||||||
* The AO coefficients and exponents are ordered in increasing order of exponents
|
|
||||||
|
|
||||||
|
|
||||||
Needed Modules
|
Needed Modules
|
||||||
==============
|
==============
|
||||||
@ -67,45 +65,41 @@ Documentation
|
|||||||
Overlap between atomic basis functions:
|
Overlap between atomic basis functions:
|
||||||
:math:`\int \chi_i(r) \chi_j(r) dr)`
|
:math:`\int \chi_i(r) \chi_j(r) dr)`
|
||||||
|
|
||||||
`ao_coef <http://github.com/LCPQ/quantum_package/tree/master/src/AOs/aos.irp.f#L21>`_
|
`ao_coef <http://github.com/LCPQ/quantum_package/tree/master/src/AOs/aos.irp.f#L62>`_
|
||||||
Coefficients, exponents and powers of x,y and z
|
AO Coefficients, read from input. Those should not be used directly, as
|
||||||
|
the MOs are expressed on the basis of **normalized** AOs.
|
||||||
|
|
||||||
`ao_coef_transp <http://github.com/LCPQ/quantum_package/tree/master/src/AOs/aos.irp.f#L157>`_
|
`ao_coef_normalized <http://github.com/LCPQ/quantum_package/tree/master/src/AOs/aos.irp.f#L84>`_
|
||||||
Transposed ao_coef and ao_expo
|
Coefficients including the AO normalization
|
||||||
|
|
||||||
`ao_coef_unnormalized <http://github.com/LCPQ/quantum_package/tree/master/src/AOs/aos.irp.f#L116>`_
|
`ao_coef_normalized_ordered <http://github.com/LCPQ/quantum_package/tree/master/src/AOs/aos.irp.f#L107>`_
|
||||||
Coefficients, exponents and powers of x,y and z as in the EZFIO file
|
Sorted primitives to accelerate 4 index MO transformation
|
||||||
ao_coef(i,j) = coefficient of the jth primitive on the ith ao
|
|
||||||
|
`ao_coef_normalized_ordered_transp <http://github.com/LCPQ/quantum_package/tree/master/src/AOs/aos.irp.f#L133>`_
|
||||||
|
Transposed ao_coef_normalized_ordered
|
||||||
|
|
||||||
|
`ao_expo <http://github.com/LCPQ/quantum_package/tree/master/src/AOs/aos.irp.f#L41>`_
|
||||||
|
AO Exponents read from input
|
||||||
|
|
||||||
|
`ao_expo_ordered <http://github.com/LCPQ/quantum_package/tree/master/src/AOs/aos.irp.f#L108>`_
|
||||||
|
Sorted primitives to accelerate 4 index MO transformation
|
||||||
|
|
||||||
|
`ao_expo_ordered_transp <http://github.com/LCPQ/quantum_package/tree/master/src/AOs/aos.irp.f#L147>`_
|
||||||
|
Transposed ao_expo_ordered
|
||||||
|
|
||||||
|
`ao_l <http://github.com/LCPQ/quantum_package/tree/master/src/AOs/aos.irp.f#L162>`_
|
||||||
ao_l = l value of the AO: a+b+c in x^a y^b z^c
|
ao_l = l value of the AO: a+b+c in x^a y^b z^c
|
||||||
|
|
||||||
`ao_expo <http://github.com/LCPQ/quantum_package/tree/master/src/AOs/aos.irp.f#L20>`_
|
`ao_l_char <http://github.com/LCPQ/quantum_package/tree/master/src/AOs/aos.irp.f#L163>`_
|
||||||
Coefficients, exponents and powers of x,y and z
|
|
||||||
|
|
||||||
`ao_expo_transp <http://github.com/LCPQ/quantum_package/tree/master/src/AOs/aos.irp.f#L158>`_
|
|
||||||
Transposed ao_coef and ao_expo
|
|
||||||
|
|
||||||
`ao_expo_unsorted <http://github.com/LCPQ/quantum_package/tree/master/src/AOs/aos.irp.f#L117>`_
|
|
||||||
Coefficients, exponents and powers of x,y and z as in the EZFIO file
|
|
||||||
ao_coef(i,j) = coefficient of the jth primitive on the ith ao
|
|
||||||
ao_l = l value of the AO: a+b+c in x^a y^b z^c
|
ao_l = l value of the AO: a+b+c in x^a y^b z^c
|
||||||
|
|
||||||
`ao_l <http://github.com/LCPQ/quantum_package/tree/master/src/AOs/aos.irp.f#L118>`_
|
`ao_l_char_space <http://github.com/LCPQ/quantum_package/tree/master/src/AOs/aos.irp.f#L311>`_
|
||||||
Coefficients, exponents and powers of x,y and z as in the EZFIO file
|
|
||||||
ao_coef(i,j) = coefficient of the jth primitive on the ith ao
|
|
||||||
ao_l = l value of the AO: a+b+c in x^a y^b z^c
|
|
||||||
|
|
||||||
`ao_l_char <http://github.com/LCPQ/quantum_package/tree/master/src/AOs/aos.irp.f#L119>`_
|
|
||||||
Coefficients, exponents and powers of x,y and z as in the EZFIO file
|
|
||||||
ao_coef(i,j) = coefficient of the jth primitive on the ith ao
|
|
||||||
ao_l = l value of the AO: a+b+c in x^a y^b z^c
|
|
||||||
|
|
||||||
`ao_l_char_space <http://github.com/LCPQ/quantum_package/tree/master/src/AOs/aos.irp.f#L309>`_
|
|
||||||
Undocumented
|
Undocumented
|
||||||
|
|
||||||
`ao_md5 <http://github.com/LCPQ/quantum_package/tree/master/src/AOs/aos.irp.f#L400>`_
|
`ao_md5 <http://github.com/LCPQ/quantum_package/tree/master/src/AOs/aos.irp.f#L403>`_
|
||||||
MD5 key characteristic of the AO basis
|
MD5 key characteristic of the AO basis
|
||||||
|
|
||||||
`ao_nucl <http://github.com/LCPQ/quantum_package/tree/master/src/AOs/aos.irp.f#L207>`_
|
`ao_nucl <http://github.com/LCPQ/quantum_package/tree/master/src/AOs/aos.irp.f#L209>`_
|
||||||
Index of the nuclei on which the ao is centered
|
Index of the nuclei on which the ao is centered
|
||||||
|
|
||||||
`ao_num <http://github.com/LCPQ/quantum_package/tree/master/src/AOs/aos.irp.f#L1>`_
|
`ao_num <http://github.com/LCPQ/quantum_package/tree/master/src/AOs/aos.irp.f#L1>`_
|
||||||
@ -115,35 +109,35 @@ Documentation
|
|||||||
Number of atomic orbitals
|
Number of atomic orbitals
|
||||||
|
|
||||||
`ao_power <http://github.com/LCPQ/quantum_package/tree/master/src/AOs/aos.irp.f#L19>`_
|
`ao_power <http://github.com/LCPQ/quantum_package/tree/master/src/AOs/aos.irp.f#L19>`_
|
||||||
Coefficients, exponents and powers of x,y and z
|
Powers of x,y and z read from input
|
||||||
|
|
||||||
`ao_prim_num <http://github.com/LCPQ/quantum_package/tree/master/src/AOs/aos.irp.f#L175>`_
|
`ao_prim_num <http://github.com/LCPQ/quantum_package/tree/master/src/AOs/aos.irp.f#L177>`_
|
||||||
Number of primitives per atomic orbital
|
Number of primitives per atomic orbital
|
||||||
|
|
||||||
`ao_prim_num_max <http://github.com/LCPQ/quantum_package/tree/master/src/AOs/aos.irp.f#L197>`_
|
`ao_prim_num_max <http://github.com/LCPQ/quantum_package/tree/master/src/AOs/aos.irp.f#L199>`_
|
||||||
Undocumented
|
Undocumented
|
||||||
|
|
||||||
`ao_prim_num_max_align <http://github.com/LCPQ/quantum_package/tree/master/src/AOs/aos.irp.f#L198>`_
|
`ao_prim_num_max_align <http://github.com/LCPQ/quantum_package/tree/master/src/AOs/aos.irp.f#L200>`_
|
||||||
Undocumented
|
Undocumented
|
||||||
|
|
||||||
`l_to_charater <http://github.com/LCPQ/quantum_package/tree/master/src/AOs/aos.irp.f#L216>`_
|
`l_to_charater <http://github.com/LCPQ/quantum_package/tree/master/src/AOs/aos.irp.f#L218>`_
|
||||||
character corresponding to the "L" value of an AO orbital
|
character corresponding to the "L" value of an AO orbital
|
||||||
|
|
||||||
`n_aos_max <http://github.com/LCPQ/quantum_package/tree/master/src/AOs/aos.irp.f#L229>`_
|
`n_aos_max <http://github.com/LCPQ/quantum_package/tree/master/src/AOs/aos.irp.f#L231>`_
|
||||||
Number of AOs per atom
|
Number of AOs per atom
|
||||||
|
|
||||||
`nucl_aos <http://github.com/LCPQ/quantum_package/tree/master/src/AOs/aos.irp.f#L242>`_
|
`nucl_aos <http://github.com/LCPQ/quantum_package/tree/master/src/AOs/aos.irp.f#L244>`_
|
||||||
List of AOs attached on each atom
|
List of AOs attached on each atom
|
||||||
|
|
||||||
`nucl_list_shell_aos <http://github.com/LCPQ/quantum_package/tree/master/src/AOs/aos.irp.f#L260>`_
|
`nucl_list_shell_aos <http://github.com/LCPQ/quantum_package/tree/master/src/AOs/aos.irp.f#L262>`_
|
||||||
Index of the shell type Aos and of the corresponding Aos
|
Index of the shell type Aos and of the corresponding Aos
|
||||||
Per convention, for P,D,F and G AOs, we take the index
|
Per convention, for P,D,F and G AOs, we take the index
|
||||||
of the AO with the the corresponding power in the "X" axis
|
of the AO with the the corresponding power in the "X" axis
|
||||||
|
|
||||||
`nucl_n_aos <http://github.com/LCPQ/quantum_package/tree/master/src/AOs/aos.irp.f#L228>`_
|
`nucl_n_aos <http://github.com/LCPQ/quantum_package/tree/master/src/AOs/aos.irp.f#L230>`_
|
||||||
Number of AOs per atom
|
Number of AOs per atom
|
||||||
|
|
||||||
`nucl_num_shell_aos <http://github.com/LCPQ/quantum_package/tree/master/src/AOs/aos.irp.f#L261>`_
|
`nucl_num_shell_aos <http://github.com/LCPQ/quantum_package/tree/master/src/AOs/aos.irp.f#L263>`_
|
||||||
Index of the shell type Aos and of the corresponding Aos
|
Index of the shell type Aos and of the corresponding Aos
|
||||||
Per convention, for P,D,F and G AOs, we take the index
|
Per convention, for P,D,F and G AOs, we take the index
|
||||||
of the AO with the the corresponding power in the "X" axis
|
of the AO with the the corresponding power in the "X" axis
|
||||||
|
@ -21,8 +21,8 @@
|
|||||||
!$OMP overlap_x,overlap_y, overlap_z, overlap, &
|
!$OMP overlap_x,overlap_y, overlap_z, overlap, &
|
||||||
!$OMP alpha, beta,i,j,c) &
|
!$OMP alpha, beta,i,j,c) &
|
||||||
!$OMP SHARED(nucl_coord,ao_power,ao_prim_num, &
|
!$OMP SHARED(nucl_coord,ao_power,ao_prim_num, &
|
||||||
!$OMP ao_overlap_x,ao_overlap_y,ao_overlap_z,ao_overlap,ao_num,ao_coef_transp,ao_nucl, &
|
!$OMP ao_overlap_x,ao_overlap_y,ao_overlap_z,ao_overlap,ao_num,ao_coef_normalized_ordered_transp,ao_nucl, &
|
||||||
!$OMP ao_expo_transp,dim1)
|
!$OMP ao_expo_ordered_transp,dim1)
|
||||||
do j=1,ao_num
|
do j=1,ao_num
|
||||||
A_center(1) = nucl_coord( ao_nucl(j), 1 )
|
A_center(1) = nucl_coord( ao_nucl(j), 1 )
|
||||||
A_center(2) = nucl_coord( ao_nucl(j), 2 )
|
A_center(2) = nucl_coord( ao_nucl(j), 2 )
|
||||||
@ -44,12 +44,12 @@
|
|||||||
power_B(2) = ao_power( i, 2 )
|
power_B(2) = ao_power( i, 2 )
|
||||||
power_B(3) = ao_power( i, 3 )
|
power_B(3) = ao_power( i, 3 )
|
||||||
do n = 1,ao_prim_num(j)
|
do n = 1,ao_prim_num(j)
|
||||||
alpha = ao_expo_transp(n,j)
|
alpha = ao_expo_ordered_transp(n,j)
|
||||||
!DEC$ VECTOR ALIGNED
|
!DEC$ VECTOR ALIGNED
|
||||||
do l = 1, ao_prim_num(i)
|
do l = 1, ao_prim_num(i)
|
||||||
beta = ao_expo_transp(l,i)
|
beta = ao_expo_ordered_transp(l,i)
|
||||||
call overlap_gaussian_xyz(A_center,B_center,alpha,beta,power_A,power_B,overlap_x,overlap_y,overlap_z,overlap,dim1)
|
call overlap_gaussian_xyz(A_center,B_center,alpha,beta,power_A,power_B,overlap_x,overlap_y,overlap_z,overlap,dim1)
|
||||||
c = ao_coef_transp(n,j) * ao_coef_transp(l,i)
|
c = ao_coef_normalized_ordered_transp(n,j) * ao_coef_normalized_ordered_transp(l,i)
|
||||||
ao_overlap(i,j) += c * overlap
|
ao_overlap(i,j) += c * overlap
|
||||||
ao_overlap_x(i,j) += c * overlap_x
|
ao_overlap_x(i,j) += c * overlap_x
|
||||||
ao_overlap_y(i,j) += c * overlap_y
|
ao_overlap_y(i,j) += c * overlap_y
|
||||||
@ -84,8 +84,8 @@ BEGIN_PROVIDER [ double precision, ao_overlap_abs,(ao_num_align,ao_num) ]
|
|||||||
!$OMP overlap_x,overlap_y, overlap_z, overlap, &
|
!$OMP overlap_x,overlap_y, overlap_z, overlap, &
|
||||||
!$OMP alpha, beta,i,j,dx) &
|
!$OMP alpha, beta,i,j,dx) &
|
||||||
!$OMP SHARED(nucl_coord,ao_power,ao_prim_num, &
|
!$OMP SHARED(nucl_coord,ao_power,ao_prim_num, &
|
||||||
!$OMP ao_overlap_abs,ao_num,ao_coef_transp,ao_nucl, &
|
!$OMP ao_overlap_abs,ao_num,ao_coef_normalized_ordered_transp,ao_nucl, &
|
||||||
!$OMP ao_expo_transp,dim1,lower_exp_val)
|
!$OMP ao_expo_ordered_transp,dim1,lower_exp_val)
|
||||||
do j=1,ao_num
|
do j=1,ao_num
|
||||||
A_center(1) = nucl_coord( ao_nucl(j), 1 )
|
A_center(1) = nucl_coord( ao_nucl(j), 1 )
|
||||||
A_center(2) = nucl_coord( ao_nucl(j), 2 )
|
A_center(2) = nucl_coord( ao_nucl(j), 2 )
|
||||||
@ -104,14 +104,14 @@ BEGIN_PROVIDER [ double precision, ao_overlap_abs,(ao_num_align,ao_num) ]
|
|||||||
power_B(2) = ao_power( i, 2 )
|
power_B(2) = ao_power( i, 2 )
|
||||||
power_B(3) = ao_power( i, 3 )
|
power_B(3) = ao_power( i, 3 )
|
||||||
do n = 1,ao_prim_num(j)
|
do n = 1,ao_prim_num(j)
|
||||||
alpha = ao_expo_transp(n,j)
|
alpha = ao_expo_ordered_transp(n,j)
|
||||||
!DEC$ VECTOR ALIGNED
|
!DEC$ VECTOR ALIGNED
|
||||||
do l = 1, ao_prim_num(i)
|
do l = 1, ao_prim_num(i)
|
||||||
beta = ao_expo_transp(l,i)
|
beta = ao_expo_ordered_transp(l,i)
|
||||||
call overlap_x_abs(A_center(1),B_center(1),alpha,beta,power_A(1),power_B(1),overlap_x,lower_exp_val,dx,dim1)
|
call overlap_x_abs(A_center(1),B_center(1),alpha,beta,power_A(1),power_B(1),overlap_x,lower_exp_val,dx,dim1)
|
||||||
call overlap_x_abs(A_center(2),B_center(2),alpha,beta,power_A(2),power_B(2),overlap_y,lower_exp_val,dx,dim1)
|
call overlap_x_abs(A_center(2),B_center(2),alpha,beta,power_A(2),power_B(2),overlap_y,lower_exp_val,dx,dim1)
|
||||||
call overlap_x_abs(A_center(3),B_center(3),alpha,beta,power_A(3),power_B(3),overlap_z,lower_exp_val,dx,dim1)
|
call overlap_x_abs(A_center(3),B_center(3),alpha,beta,power_A(3),power_B(3),overlap_z,lower_exp_val,dx,dim1)
|
||||||
ao_overlap_abs(i,j) += abs(ao_coef_transp(n,j) * ao_coef_transp(l,i)) * overlap_x * overlap_y * overlap_z
|
ao_overlap_abs(i,j) += abs(ao_coef_normalized_ordered_transp(n,j) * ao_coef_normalized_ordered_transp(l,i)) * overlap_x * overlap_y * overlap_z
|
||||||
enddo
|
enddo
|
||||||
enddo
|
enddo
|
||||||
enddo
|
enddo
|
||||||
|
@ -1,152 +1,171 @@
|
|||||||
BEGIN_PROVIDER [ integer, ao_num ]
|
BEGIN_PROVIDER [ integer, ao_num ]
|
||||||
&BEGIN_PROVIDER [ integer, ao_num_align ]
|
&BEGIN_PROVIDER [ integer, ao_num_align ]
|
||||||
implicit none
|
implicit none
|
||||||
|
|
||||||
BEGIN_DOC
|
BEGIN_DOC
|
||||||
! Number of atomic orbitals
|
! Number of atomic orbitals
|
||||||
END_DOC
|
END_DOC
|
||||||
|
|
||||||
ao_num = -1
|
ao_num = -1
|
||||||
PROVIDE ezfio_filename
|
PROVIDE ezfio_filename
|
||||||
call ezfio_get_ao_basis_ao_num(ao_num)
|
call ezfio_get_ao_basis_ao_num(ao_num)
|
||||||
if (ao_num <= 0) then
|
if (ao_num <= 0) then
|
||||||
stop 'Number of contracted gaussians should be > 0'
|
stop 'Number of contracted gaussians should be > 0'
|
||||||
endif
|
endif
|
||||||
integer :: align_double
|
integer :: align_double
|
||||||
ao_num_align = align_double(ao_num)
|
ao_num_align = align_double(ao_num)
|
||||||
END_PROVIDER
|
END_PROVIDER
|
||||||
|
|
||||||
BEGIN_PROVIDER [ integer, ao_power, (ao_num_align,3) ]
|
BEGIN_PROVIDER [ integer, ao_power, (ao_num_align,3) ]
|
||||||
&BEGIN_PROVIDER [ double precision, ao_expo, (ao_num_align,ao_prim_num_max) ]
|
implicit none
|
||||||
&BEGIN_PROVIDER [ double precision, ao_coef, (ao_num_align,ao_prim_num_max) ]
|
BEGIN_DOC
|
||||||
implicit none
|
! Powers of x,y and z read from input
|
||||||
|
END_DOC
|
||||||
BEGIN_DOC
|
PROVIDE ezfio_filename
|
||||||
! Coefficients, exponents and powers of x,y and z
|
|
||||||
END_DOC
|
|
||||||
PROVIDE ezfio_filename
|
|
||||||
|
|
||||||
double precision, allocatable :: buffer(:,:)
|
|
||||||
allocate ( buffer(ao_num,ao_prim_num_max) )
|
|
||||||
integer :: ibuffer(ao_num,3)
|
|
||||||
integer :: i,j,k
|
|
||||||
character*(128) :: give_ao_character_space
|
|
||||||
ibuffer = 0
|
|
||||||
call ezfio_get_ao_basis_ao_power(ibuffer)
|
|
||||||
ao_power = 0
|
|
||||||
do j = 1, 3
|
|
||||||
do i = 1, ao_num
|
|
||||||
ao_power(i,j) = ibuffer(i,j)
|
|
||||||
enddo
|
|
||||||
enddo
|
|
||||||
ao_expo = 0.d0
|
|
||||||
buffer = 0.d0
|
|
||||||
call ezfio_get_ao_basis_ao_expo(buffer)
|
|
||||||
do j = 1, ao_prim_num_max
|
|
||||||
do i = 1, ao_num
|
|
||||||
ao_expo(i,j) = buffer(i,j)
|
|
||||||
enddo
|
|
||||||
enddo
|
|
||||||
|
|
||||||
ao_coef = 0.d0
|
|
||||||
buffer = 0.d0
|
|
||||||
call ezfio_get_ao_basis_ao_coef(buffer)
|
|
||||||
do j = 1, ao_prim_num_max
|
|
||||||
do i = 1, ao_num
|
|
||||||
ao_coef(i,j) = buffer(i,j)
|
|
||||||
enddo
|
|
||||||
enddo
|
|
||||||
|
|
||||||
deallocate(buffer)
|
|
||||||
|
|
||||||
! Normalization of the AO coefficients
|
|
||||||
! ------------------------------------
|
|
||||||
double precision :: norm, norm2,overlap_x,overlap_y,overlap_z,C_A(3)
|
|
||||||
integer :: l, powA(3), nz
|
|
||||||
nz=100
|
|
||||||
C_A(1) = 0.d0
|
|
||||||
C_A(2) = 0.d0
|
|
||||||
C_A(3) = 0.d0
|
|
||||||
do i=1,ao_num
|
|
||||||
powA(1) = ao_power(i,1)
|
|
||||||
powA(2) = ao_power(i,2)
|
|
||||||
powA(3) = ao_power(i,3)
|
|
||||||
do j=1,ao_prim_num(i)
|
|
||||||
call overlap_gaussian_xyz(C_A,C_A,ao_expo(i,j),ao_expo(i,j),powA,powA,overlap_x,overlap_y,overlap_z,norm,nz)
|
|
||||||
ao_coef(i,j) = ao_coef(i,j)/sqrt(norm)
|
|
||||||
enddo
|
|
||||||
enddo
|
|
||||||
|
|
||||||
! Sorting of the exponents for efficient integral calculations
|
|
||||||
integer :: iorder(ao_prim_num_max)
|
|
||||||
double precision :: d(ao_prim_num_max,2)
|
|
||||||
do i=1,ao_num
|
|
||||||
do j=1,ao_prim_num(i)
|
|
||||||
iorder(j) = j
|
|
||||||
d(j,1) = ao_expo(i,j)
|
|
||||||
d(j,2) = ao_coef(i,j)
|
|
||||||
enddo
|
|
||||||
call dsort(d(1,1),iorder,ao_prim_num(i))
|
|
||||||
call dset_order(d(1,2),iorder,ao_prim_num(i))
|
|
||||||
do j=1,ao_prim_num(i)
|
|
||||||
ao_expo(i,j) = d(j,1)
|
|
||||||
ao_coef(i,j) = d(j,2)
|
|
||||||
enddo
|
|
||||||
enddo
|
|
||||||
END_PROVIDER
|
|
||||||
|
|
||||||
|
|
||||||
BEGIN_PROVIDER [ double precision, ao_coef_transp, (ao_prim_num_max_align,ao_num) ]
|
|
||||||
&BEGIN_PROVIDER [ double precision, ao_expo_transp, (ao_prim_num_max_align,ao_num) ]
|
|
||||||
implicit none
|
|
||||||
BEGIN_DOC
|
|
||||||
! Transposed ao_coef and ao_expo
|
|
||||||
END_DOC
|
|
||||||
integer :: i,j
|
|
||||||
do j=1, ao_num
|
|
||||||
do i=1, ao_prim_num_max
|
|
||||||
ao_coef_transp(i,j) = ao_coef(j,i)
|
|
||||||
ao_expo_transp(i,j) = ao_expo(j,i)
|
|
||||||
enddo
|
|
||||||
enddo
|
|
||||||
|
|
||||||
|
integer :: i,j,k
|
||||||
|
integer, allocatable :: ibuffer(:,:)
|
||||||
|
allocate ( ibuffer(ao_num,3) )
|
||||||
|
ibuffer = 0
|
||||||
|
call ezfio_get_ao_basis_ao_power(ibuffer)
|
||||||
|
ao_power = 0
|
||||||
|
do j = 1, 3
|
||||||
|
do i = 1, ao_num
|
||||||
|
ao_power(i,j) = ibuffer(i,j)
|
||||||
|
enddo
|
||||||
|
enddo
|
||||||
|
deallocate(ibuffer)
|
||||||
|
|
||||||
END_PROVIDER
|
END_PROVIDER
|
||||||
|
|
||||||
BEGIN_PROVIDER [ double precision, ao_coef_unnormalized, (ao_num_align,ao_prim_num_max) ]
|
BEGIN_PROVIDER [ double precision, ao_expo, (ao_num_align,ao_prim_num_max) ]
|
||||||
&BEGIN_PROVIDER [ double precision, ao_expo_unsorted, (ao_num_align,ao_prim_num_max) ]
|
implicit none
|
||||||
&BEGIN_PROVIDER [ integer, ao_l, (ao_num) ]
|
BEGIN_DOC
|
||||||
|
! AO Exponents read from input
|
||||||
|
END_DOC
|
||||||
|
PROVIDE ezfio_filename
|
||||||
|
|
||||||
|
double precision, allocatable :: buffer(:,:)
|
||||||
|
allocate ( buffer(ao_num,ao_prim_num_max) )
|
||||||
|
integer :: i,j,k
|
||||||
|
ao_expo = 0.d0
|
||||||
|
buffer = 0.d0
|
||||||
|
call ezfio_get_ao_basis_ao_expo(buffer)
|
||||||
|
do j = 1, ao_prim_num_max
|
||||||
|
do i = 1, ao_num
|
||||||
|
ao_expo(i,j) = buffer(i,j)
|
||||||
|
enddo
|
||||||
|
enddo
|
||||||
|
deallocate(buffer)
|
||||||
|
END_PROVIDER
|
||||||
|
|
||||||
|
BEGIN_PROVIDER [ double precision, ao_coef, (ao_num_align,ao_prim_num_max) ]
|
||||||
|
implicit none
|
||||||
|
BEGIN_DOC
|
||||||
|
! AO Coefficients, read from input. Those should not be used directly, as
|
||||||
|
! the MOs are expressed on the basis of **normalized** AOs.
|
||||||
|
END_DOC
|
||||||
|
PROVIDE ezfio_filename
|
||||||
|
|
||||||
|
double precision, allocatable :: buffer(:,:)
|
||||||
|
allocate ( buffer(ao_num,ao_prim_num_max) )
|
||||||
|
integer :: i,j,k
|
||||||
|
ao_coef = 0.d0
|
||||||
|
buffer = 0.d0
|
||||||
|
call ezfio_get_ao_basis_ao_coef(buffer)
|
||||||
|
do j = 1, ao_prim_num_max
|
||||||
|
do i = 1, ao_num
|
||||||
|
ao_coef(i,j) = buffer(i,j)
|
||||||
|
enddo
|
||||||
|
enddo
|
||||||
|
deallocate(buffer)
|
||||||
|
END_PROVIDER
|
||||||
|
|
||||||
|
BEGIN_PROVIDER [ double precision, ao_coef_normalized, (ao_num_align,ao_prim_num_max) ]
|
||||||
|
implicit none
|
||||||
|
BEGIN_DOC
|
||||||
|
! Coefficients including the AO normalization
|
||||||
|
END_DOC
|
||||||
|
double precision :: norm, norm2,overlap_x,overlap_y,overlap_z,C_A(3)
|
||||||
|
integer :: l, powA(3), nz
|
||||||
|
integer :: i,j
|
||||||
|
nz=100
|
||||||
|
C_A(1) = 0.d0
|
||||||
|
C_A(2) = 0.d0
|
||||||
|
C_A(3) = 0.d0
|
||||||
|
do i=1,ao_num
|
||||||
|
powA(1) = ao_power(i,1)
|
||||||
|
powA(2) = ao_power(i,2)
|
||||||
|
powA(3) = ao_power(i,3)
|
||||||
|
do j=1,ao_prim_num(i)
|
||||||
|
call overlap_gaussian_xyz(C_A,C_A,ao_expo(i,j),ao_expo(i,j),powA,powA,overlap_x,overlap_y,overlap_z,norm,nz)
|
||||||
|
ao_coef_normalized(i,j) = ao_coef(i,j)/sqrt(norm)
|
||||||
|
enddo
|
||||||
|
enddo
|
||||||
|
END_PROVIDER
|
||||||
|
|
||||||
|
BEGIN_PROVIDER [ double precision, ao_coef_normalized_ordered, (ao_num_align,ao_prim_num_max) ]
|
||||||
|
&BEGIN_PROVIDER [ double precision, ao_expo_ordered, (ao_num_align,ao_prim_num_max) ]
|
||||||
|
implicit none
|
||||||
|
BEGIN_DOC
|
||||||
|
! Sorted primitives to accelerate 4 index MO transformation
|
||||||
|
END_DOC
|
||||||
|
|
||||||
|
integer :: iorder(ao_prim_num_max)
|
||||||
|
double precision :: d(ao_prim_num_max,2)
|
||||||
|
integer :: i,j
|
||||||
|
do i=1,ao_num
|
||||||
|
do j=1,ao_prim_num(i)
|
||||||
|
iorder(j) = j
|
||||||
|
d(j,1) = ao_expo(i,j)
|
||||||
|
d(j,2) = ao_coef_normalized(i,j)
|
||||||
|
enddo
|
||||||
|
call dsort(d(1,1),iorder,ao_prim_num(i))
|
||||||
|
call dset_order(d(1,2),iorder,ao_prim_num(i))
|
||||||
|
do j=1,ao_prim_num(i)
|
||||||
|
ao_expo_ordered(i,j) = d(j,1)
|
||||||
|
ao_coef_normalized_ordered(i,j) = d(j,2)
|
||||||
|
enddo
|
||||||
|
enddo
|
||||||
|
END_PROVIDER
|
||||||
|
|
||||||
|
|
||||||
|
BEGIN_PROVIDER [ double precision, ao_coef_normalized_ordered_transp, (ao_prim_num_max_align,ao_num) ]
|
||||||
|
implicit none
|
||||||
|
BEGIN_DOC
|
||||||
|
! Transposed ao_coef_normalized_ordered
|
||||||
|
END_DOC
|
||||||
|
integer :: i,j
|
||||||
|
do j=1, ao_num
|
||||||
|
do i=1, ao_prim_num_max
|
||||||
|
ao_coef_normalized_ordered_transp(i,j) = ao_coef_normalized_ordered(j,i)
|
||||||
|
enddo
|
||||||
|
enddo
|
||||||
|
|
||||||
|
END_PROVIDER
|
||||||
|
|
||||||
|
BEGIN_PROVIDER [ double precision, ao_expo_ordered_transp, (ao_prim_num_max_align,ao_num) ]
|
||||||
|
implicit none
|
||||||
|
BEGIN_DOC
|
||||||
|
! Transposed ao_expo_ordered
|
||||||
|
END_DOC
|
||||||
|
integer :: i,j
|
||||||
|
do j=1, ao_num
|
||||||
|
do i=1, ao_prim_num_max
|
||||||
|
ao_expo_ordered_transp(i,j) = ao_expo_ordered(j,i)
|
||||||
|
enddo
|
||||||
|
enddo
|
||||||
|
|
||||||
|
END_PROVIDER
|
||||||
|
|
||||||
|
|
||||||
|
BEGIN_PROVIDER [ integer, ao_l, (ao_num) ]
|
||||||
&BEGIN_PROVIDER [ character*(128), ao_l_char, (ao_num) ]
|
&BEGIN_PROVIDER [ character*(128), ao_l_char, (ao_num) ]
|
||||||
implicit none
|
implicit none
|
||||||
|
|
||||||
BEGIN_DOC
|
BEGIN_DOC
|
||||||
! Coefficients, exponents and powers of x,y and z as in the EZFIO file
|
|
||||||
! ao_coef(i,j) = coefficient of the jth primitive on the ith ao
|
|
||||||
! ao_l = l value of the AO: a+b+c in x^a y^b z^c
|
! ao_l = l value of the AO: a+b+c in x^a y^b z^c
|
||||||
END_DOC
|
END_DOC
|
||||||
PROVIDE ezfio_filename
|
integer :: i
|
||||||
|
|
||||||
double precision, allocatable :: buffer(:,:)
|
|
||||||
allocate ( buffer(ao_num,ao_prim_num_max) )
|
|
||||||
integer :: i,j,k
|
|
||||||
character*(128) :: give_ao_character_space
|
|
||||||
buffer = 0.d0
|
|
||||||
call ezfio_get_ao_basis_ao_expo(buffer)
|
|
||||||
do j = 1, ao_prim_num_max
|
|
||||||
do i = 1, ao_num
|
|
||||||
ao_expo_unsorted(i,j) = buffer(i,j)
|
|
||||||
enddo
|
|
||||||
enddo
|
|
||||||
|
|
||||||
buffer = 0.d0
|
|
||||||
call ezfio_get_ao_basis_ao_coef(buffer)
|
|
||||||
do j = 1, ao_prim_num_max
|
|
||||||
do i = 1, ao_num
|
|
||||||
ao_coef_unnormalized(i,j) = buffer(i,j)
|
|
||||||
enddo
|
|
||||||
enddo
|
|
||||||
deallocate(buffer)
|
|
||||||
|
|
||||||
do i=1,ao_num
|
do i=1,ao_num
|
||||||
ao_l(i) = ao_power(i,1) + ao_power(i,2) + ao_power(i,3)
|
ao_l(i) = ao_power(i,1) + ao_power(i,2) + ao_power(i,3)
|
||||||
ao_l_char(i) = l_to_charater(ao_l(i))
|
ao_l_char(i) = l_to_charater(ao_l(i))
|
||||||
@ -154,23 +173,6 @@ END_PROVIDER
|
|||||||
END_PROVIDER
|
END_PROVIDER
|
||||||
|
|
||||||
|
|
||||||
BEGIN_PROVIDER [ double precision, ao_coef_transp, (ao_prim_num_max_align,ao_num) ]
|
|
||||||
&BEGIN_PROVIDER [ double precision, ao_expo_transp, (ao_prim_num_max_align,ao_num) ]
|
|
||||||
implicit none
|
|
||||||
BEGIN_DOC
|
|
||||||
! Transposed ao_coef and ao_expo
|
|
||||||
END_DOC
|
|
||||||
integer :: i,j
|
|
||||||
do j=1, ao_num
|
|
||||||
do i=1, ao_prim_num_max
|
|
||||||
ao_coef_transp(i,j) = ao_coef(j,i)
|
|
||||||
ao_expo_transp(i,j) = ao_expo(j,i)
|
|
||||||
enddo
|
|
||||||
enddo
|
|
||||||
|
|
||||||
|
|
||||||
END_PROVIDER
|
|
||||||
|
|
||||||
|
|
||||||
BEGIN_PROVIDER [ integer, ao_prim_num, (ao_num_align) ]
|
BEGIN_PROVIDER [ integer, ao_prim_num, (ao_num_align) ]
|
||||||
implicit none
|
implicit none
|
||||||
@ -303,10 +305,10 @@ END_PROVIDER
|
|||||||
enddo
|
enddo
|
||||||
enddo
|
enddo
|
||||||
|
|
||||||
END_PROVIDER
|
END_PROVIDER
|
||||||
|
|
||||||
|
|
||||||
BEGIN_PROVIDER [ character*(4), ao_l_char_space, (ao_num) ]
|
BEGIN_PROVIDER [ character*(4), ao_l_char_space, (ao_num) ]
|
||||||
implicit none
|
implicit none
|
||||||
integer :: i
|
integer :: i
|
||||||
character*(4) :: give_ao_character_space
|
character*(4) :: give_ao_character_space
|
||||||
@ -397,6 +399,7 @@ END_PROVIDER
|
|||||||
ao_l_char_space(i) = give_ao_character_space
|
ao_l_char_space(i) = give_ao_character_space
|
||||||
enddo
|
enddo
|
||||||
END_PROVIDER
|
END_PROVIDER
|
||||||
|
|
||||||
BEGIN_PROVIDER [ character*(32), ao_md5 ]
|
BEGIN_PROVIDER [ character*(32), ao_md5 ]
|
||||||
BEGIN_DOC
|
BEGIN_DOC
|
||||||
! MD5 key characteristic of the AO basis
|
! MD5 key characteristic of the AO basis
|
||||||
|
@ -42,24 +42,24 @@ double precision function ao_bielec_integral(i,j,k,l)
|
|||||||
|
|
||||||
do p = 1, ao_prim_num(i)
|
do p = 1, ao_prim_num(i)
|
||||||
double precision :: coef1
|
double precision :: coef1
|
||||||
coef1 = ao_coef_transp(p,i)
|
coef1 = ao_coef_normalized_ordered_transp(p,i)
|
||||||
do q = 1, ao_prim_num(j)
|
do q = 1, ao_prim_num(j)
|
||||||
double precision :: coef2
|
double precision :: coef2
|
||||||
coef2 = coef1*ao_coef_transp(q,j)
|
coef2 = coef1*ao_coef_normalized_ordered_transp(q,j)
|
||||||
double precision :: p_inv,q_inv
|
double precision :: p_inv,q_inv
|
||||||
call give_explicit_poly_and_gaussian(P_new,P_center,pp,fact_p,iorder_p,&
|
call give_explicit_poly_and_gaussian(P_new,P_center,pp,fact_p,iorder_p,&
|
||||||
ao_expo_transp(p,i),ao_expo_transp(q,j), &
|
ao_expo_ordered_transp(p,i),ao_expo_ordered_transp(q,j), &
|
||||||
I_power,J_power,I_center,J_center,dim1)
|
I_power,J_power,I_center,J_center,dim1)
|
||||||
p_inv = 1.d0/pp
|
p_inv = 1.d0/pp
|
||||||
do r = 1, ao_prim_num(k)
|
do r = 1, ao_prim_num(k)
|
||||||
double precision :: coef3
|
double precision :: coef3
|
||||||
coef3 = coef2*ao_coef_transp(r,k)
|
coef3 = coef2*ao_coef_normalized_ordered_transp(r,k)
|
||||||
do s = 1, ao_prim_num(l)
|
do s = 1, ao_prim_num(l)
|
||||||
double precision :: coef4
|
double precision :: coef4
|
||||||
coef4 = coef3*ao_coef_transp(s,l)
|
coef4 = coef3*ao_coef_normalized_ordered_transp(s,l)
|
||||||
double precision :: general_primitive_integral
|
double precision :: general_primitive_integral
|
||||||
call give_explicit_poly_and_gaussian(Q_new,Q_center,qq,fact_q,iorder_q,&
|
call give_explicit_poly_and_gaussian(Q_new,Q_center,qq,fact_q,iorder_q,&
|
||||||
ao_expo_transp(r,k),ao_expo_transp(s,l), &
|
ao_expo_ordered_transp(r,k),ao_expo_ordered_transp(s,l), &
|
||||||
K_power,L_power,K_center,L_center,dim1)
|
K_power,L_power,K_center,L_center,dim1)
|
||||||
q_inv = 1.d0/qq
|
q_inv = 1.d0/qq
|
||||||
integral = general_primitive_integral(dim1, &
|
integral = general_primitive_integral(dim1, &
|
||||||
@ -82,15 +82,15 @@ double precision function ao_bielec_integral(i,j,k,l)
|
|||||||
double precision :: ERI
|
double precision :: ERI
|
||||||
|
|
||||||
do p = 1, ao_prim_num(i)
|
do p = 1, ao_prim_num(i)
|
||||||
coef1 = ao_coef_transp(p,i)
|
coef1 = ao_coef_normalized_ordered_transp(p,i)
|
||||||
do q = 1, ao_prim_num(j)
|
do q = 1, ao_prim_num(j)
|
||||||
coef2 = coef1*ao_coef_transp(q,j)
|
coef2 = coef1*ao_coef_normalized_ordered_transp(q,j)
|
||||||
do r = 1, ao_prim_num(k)
|
do r = 1, ao_prim_num(k)
|
||||||
coef3 = coef2*ao_coef_transp(r,k)
|
coef3 = coef2*ao_coef_normalized_ordered_transp(r,k)
|
||||||
do s = 1, ao_prim_num(l)
|
do s = 1, ao_prim_num(l)
|
||||||
coef4 = coef3*ao_coef_transp(s,l)
|
coef4 = coef3*ao_coef_normalized_ordered_transp(s,l)
|
||||||
integral = ERI( &
|
integral = ERI( &
|
||||||
ao_expo_transp(p,i),ao_expo_transp(q,j),ao_expo_transp(r,k),ao_expo_transp(s,l),&
|
ao_expo_ordered_transp(p,i),ao_expo_ordered_transp(q,j),ao_expo_ordered_transp(r,k),ao_expo_ordered_transp(s,l),&
|
||||||
I_power(1),J_power(1),K_power(1),L_power(1), &
|
I_power(1),J_power(1),K_power(1),L_power(1), &
|
||||||
I_power(2),J_power(2),K_power(2),L_power(2), &
|
I_power(2),J_power(2),K_power(2),L_power(2), &
|
||||||
I_power(3),J_power(3),K_power(3),L_power(3))
|
I_power(3),J_power(3),K_power(3),L_power(3))
|
||||||
@ -149,12 +149,12 @@ double precision function ao_bielec_integral_schwartz_accel(i,j,k,l)
|
|||||||
|
|
||||||
schwartz_kl(0,0) = 0.d0
|
schwartz_kl(0,0) = 0.d0
|
||||||
do r = 1, ao_prim_num(k)
|
do r = 1, ao_prim_num(k)
|
||||||
coef1 = ao_coef_transp(r,k)*ao_coef_transp(r,k)
|
coef1 = ao_coef_normalized_ordered_transp(r,k)*ao_coef_normalized_ordered_transp(r,k)
|
||||||
schwartz_kl(0,r) = 0.d0
|
schwartz_kl(0,r) = 0.d0
|
||||||
do s = 1, ao_prim_num(l)
|
do s = 1, ao_prim_num(l)
|
||||||
coef2 = coef1 * ao_coef_transp(s,l) * ao_coef_transp(s,l)
|
coef2 = coef1 * ao_coef_normalized_ordered_transp(s,l) * ao_coef_normalized_ordered_transp(s,l)
|
||||||
call give_explicit_poly_and_gaussian(Q_new,Q_center,qq,fact_q,iorder_q,&
|
call give_explicit_poly_and_gaussian(Q_new,Q_center,qq,fact_q,iorder_q,&
|
||||||
ao_expo_transp(r,k),ao_expo_transp(s,l), &
|
ao_expo_ordered_transp(r,k),ao_expo_ordered_transp(s,l), &
|
||||||
K_power,L_power,K_center,L_center,dim1)
|
K_power,L_power,K_center,L_center,dim1)
|
||||||
q_inv = 1.d0/qq
|
q_inv = 1.d0/qq
|
||||||
schwartz_kl(s,r) = general_primitive_integral(dim1, &
|
schwartz_kl(s,r) = general_primitive_integral(dim1, &
|
||||||
@ -168,13 +168,13 @@ double precision function ao_bielec_integral_schwartz_accel(i,j,k,l)
|
|||||||
|
|
||||||
do p = 1, ao_prim_num(i)
|
do p = 1, ao_prim_num(i)
|
||||||
double precision :: coef1
|
double precision :: coef1
|
||||||
coef1 = ao_coef_transp(p,i)
|
coef1 = ao_coef_normalized_ordered_transp(p,i)
|
||||||
do q = 1, ao_prim_num(j)
|
do q = 1, ao_prim_num(j)
|
||||||
double precision :: coef2
|
double precision :: coef2
|
||||||
coef2 = coef1*ao_coef_transp(q,j)
|
coef2 = coef1*ao_coef_normalized_ordered_transp(q,j)
|
||||||
double precision :: p_inv,q_inv
|
double precision :: p_inv,q_inv
|
||||||
call give_explicit_poly_and_gaussian(P_new,P_center,pp,fact_p,iorder_p,&
|
call give_explicit_poly_and_gaussian(P_new,P_center,pp,fact_p,iorder_p,&
|
||||||
ao_expo_transp(p,i),ao_expo_transp(q,j), &
|
ao_expo_ordered_transp(p,i),ao_expo_ordered_transp(q,j), &
|
||||||
I_power,J_power,I_center,J_center,dim1)
|
I_power,J_power,I_center,J_center,dim1)
|
||||||
p_inv = 1.d0/pp
|
p_inv = 1.d0/pp
|
||||||
schwartz_ij = general_primitive_integral(dim1, &
|
schwartz_ij = general_primitive_integral(dim1, &
|
||||||
@ -189,16 +189,16 @@ double precision function ao_bielec_integral_schwartz_accel(i,j,k,l)
|
|||||||
cycle
|
cycle
|
||||||
endif
|
endif
|
||||||
double precision :: coef3
|
double precision :: coef3
|
||||||
coef3 = coef2*ao_coef_transp(r,k)
|
coef3 = coef2*ao_coef_normalized_ordered_transp(r,k)
|
||||||
do s = 1, ao_prim_num(l)
|
do s = 1, ao_prim_num(l)
|
||||||
double precision :: coef4
|
double precision :: coef4
|
||||||
if (schwartz_kl(s,r)*schwartz_ij < thresh) then
|
if (schwartz_kl(s,r)*schwartz_ij < thresh) then
|
||||||
cycle
|
cycle
|
||||||
endif
|
endif
|
||||||
coef4 = coef3*ao_coef_transp(s,l)
|
coef4 = coef3*ao_coef_normalized_ordered_transp(s,l)
|
||||||
double precision :: general_primitive_integral
|
double precision :: general_primitive_integral
|
||||||
call give_explicit_poly_and_gaussian(Q_new,Q_center,qq,fact_q,iorder_q,&
|
call give_explicit_poly_and_gaussian(Q_new,Q_center,qq,fact_q,iorder_q,&
|
||||||
ao_expo_transp(r,k),ao_expo_transp(s,l), &
|
ao_expo_ordered_transp(r,k),ao_expo_ordered_transp(s,l), &
|
||||||
K_power,L_power,K_center,L_center,dim1)
|
K_power,L_power,K_center,L_center,dim1)
|
||||||
q_inv = 1.d0/qq
|
q_inv = 1.d0/qq
|
||||||
integral = general_primitive_integral(dim1, &
|
integral = general_primitive_integral(dim1, &
|
||||||
@ -222,12 +222,12 @@ double precision function ao_bielec_integral_schwartz_accel(i,j,k,l)
|
|||||||
|
|
||||||
schwartz_kl(0,0) = 0.d0
|
schwartz_kl(0,0) = 0.d0
|
||||||
do r = 1, ao_prim_num(k)
|
do r = 1, ao_prim_num(k)
|
||||||
coef1 = ao_coef_transp(r,k)*ao_coef_transp(r,k)
|
coef1 = ao_coef_normalized_ordered_transp(r,k)*ao_coef_normalized_ordered_transp(r,k)
|
||||||
schwartz_kl(0,r) = 0.d0
|
schwartz_kl(0,r) = 0.d0
|
||||||
do s = 1, ao_prim_num(l)
|
do s = 1, ao_prim_num(l)
|
||||||
coef2 = coef1*ao_coef_transp(s,l)*ao_coef_transp(s,l)
|
coef2 = coef1*ao_coef_normalized_ordered_transp(s,l)*ao_coef_normalized_ordered_transp(s,l)
|
||||||
schwartz_kl(s,r) = ERI( &
|
schwartz_kl(s,r) = ERI( &
|
||||||
ao_expo_transp(r,k),ao_expo_transp(s,l),ao_expo_transp(r,k),ao_expo_transp(s,l),&
|
ao_expo_ordered_transp(r,k),ao_expo_ordered_transp(s,l),ao_expo_ordered_transp(r,k),ao_expo_ordered_transp(s,l),&
|
||||||
K_power(1),L_power(1),K_power(1),L_power(1), &
|
K_power(1),L_power(1),K_power(1),L_power(1), &
|
||||||
K_power(2),L_power(2),K_power(2),L_power(2), &
|
K_power(2),L_power(2),K_power(2),L_power(2), &
|
||||||
K_power(3),L_power(3),K_power(3),L_power(3)) * &
|
K_power(3),L_power(3),K_power(3),L_power(3)) * &
|
||||||
@ -238,11 +238,11 @@ double precision function ao_bielec_integral_schwartz_accel(i,j,k,l)
|
|||||||
enddo
|
enddo
|
||||||
|
|
||||||
do p = 1, ao_prim_num(i)
|
do p = 1, ao_prim_num(i)
|
||||||
coef1 = ao_coef_transp(p,i)
|
coef1 = ao_coef_normalized_ordered_transp(p,i)
|
||||||
do q = 1, ao_prim_num(j)
|
do q = 1, ao_prim_num(j)
|
||||||
coef2 = coef1*ao_coef_transp(q,j)
|
coef2 = coef1*ao_coef_normalized_ordered_transp(q,j)
|
||||||
schwartz_ij = ERI( &
|
schwartz_ij = ERI( &
|
||||||
ao_expo_transp(p,i),ao_expo_transp(q,j),ao_expo_transp(p,i),ao_expo_transp(q,j),&
|
ao_expo_ordered_transp(p,i),ao_expo_ordered_transp(q,j),ao_expo_ordered_transp(p,i),ao_expo_ordered_transp(q,j),&
|
||||||
I_power(1),J_power(1),I_power(1),J_power(1), &
|
I_power(1),J_power(1),I_power(1),J_power(1), &
|
||||||
I_power(2),J_power(2),I_power(2),J_power(2), &
|
I_power(2),J_power(2),I_power(2),J_power(2), &
|
||||||
I_power(3),J_power(3),I_power(3),J_power(3))*coef2*coef2
|
I_power(3),J_power(3),I_power(3),J_power(3))*coef2*coef2
|
||||||
@ -253,14 +253,14 @@ double precision function ao_bielec_integral_schwartz_accel(i,j,k,l)
|
|||||||
if (schwartz_kl(0,r)*schwartz_ij < thresh) then
|
if (schwartz_kl(0,r)*schwartz_ij < thresh) then
|
||||||
cycle
|
cycle
|
||||||
endif
|
endif
|
||||||
coef3 = coef2*ao_coef_transp(r,k)
|
coef3 = coef2*ao_coef_normalized_ordered_transp(r,k)
|
||||||
do s = 1, ao_prim_num(l)
|
do s = 1, ao_prim_num(l)
|
||||||
if (schwartz_kl(s,r)*schwartz_ij < thresh) then
|
if (schwartz_kl(s,r)*schwartz_ij < thresh) then
|
||||||
cycle
|
cycle
|
||||||
endif
|
endif
|
||||||
coef4 = coef3*ao_coef_transp(s,l)
|
coef4 = coef3*ao_coef_normalized_ordered_transp(s,l)
|
||||||
integral = ERI( &
|
integral = ERI( &
|
||||||
ao_expo_transp(p,i),ao_expo_transp(q,j),ao_expo_transp(r,k),ao_expo_transp(s,l),&
|
ao_expo_ordered_transp(p,i),ao_expo_ordered_transp(q,j),ao_expo_ordered_transp(r,k),ao_expo_ordered_transp(s,l),&
|
||||||
I_power(1),J_power(1),K_power(1),L_power(1), &
|
I_power(1),J_power(1),K_power(1),L_power(1), &
|
||||||
I_power(2),J_power(2),K_power(2),L_power(2), &
|
I_power(2),J_power(2),K_power(2),L_power(2), &
|
||||||
I_power(3),J_power(3),K_power(3),L_power(3))
|
I_power(3),J_power(3),K_power(3),L_power(3))
|
||||||
|
@ -181,8 +181,43 @@ subroutine copy_H_apply_buffer_to_wf
|
|||||||
call normalize(psi_coef,N_det)
|
call normalize(psi_coef,N_det)
|
||||||
SOFT_TOUCH N_det psi_det psi_coef
|
SOFT_TOUCH N_det psi_det psi_coef
|
||||||
|
|
||||||
|
call debug_unicity_of_determinants
|
||||||
end
|
end
|
||||||
|
|
||||||
|
subroutine debug_unicity_of_determinants
|
||||||
|
implicit none
|
||||||
|
BEGIN_DOC
|
||||||
|
! This subroutine checks that there are no repetitions in the wave function
|
||||||
|
END_DOC
|
||||||
|
logical :: same, failed
|
||||||
|
integer :: i,k
|
||||||
|
print *, "======= DEBUG UNICITY ========="
|
||||||
|
failed = .False.
|
||||||
|
do i=2,N_det
|
||||||
|
same = .True.
|
||||||
|
do k=1,N_int
|
||||||
|
if ( psi_det_sorted_bit(k,1,i) /= psi_det_sorted_bit(k,1,i-1) ) then
|
||||||
|
same = .False.
|
||||||
|
exit
|
||||||
|
endif
|
||||||
|
if ( psi_det_sorted_bit(k,2,i) /= psi_det_sorted_bit(k,2,i-1) ) then
|
||||||
|
same = .False.
|
||||||
|
exit
|
||||||
|
endif
|
||||||
|
enddo
|
||||||
|
if (same) then
|
||||||
|
failed = .True.
|
||||||
|
call debug_det(psi_det_sorted_bit(1,1,i))
|
||||||
|
endif
|
||||||
|
enddo
|
||||||
|
|
||||||
|
if (failed) then
|
||||||
|
print *, '======= Determinants not unique : Failed ! ========='
|
||||||
|
stop
|
||||||
|
else
|
||||||
|
print *, '======= Determinants are unique : OK ! ========='
|
||||||
|
endif
|
||||||
|
end
|
||||||
|
|
||||||
subroutine fill_H_apply_buffer_no_selection(n_selected,det_buffer,Nint,iproc)
|
subroutine fill_H_apply_buffer_no_selection(n_selected,det_buffer,Nint,iproc)
|
||||||
use bitmasks
|
use bitmasks
|
||||||
|
@ -45,7 +45,10 @@ Documentation
|
|||||||
after calling this function.
|
after calling this function.
|
||||||
After calling this subroutine, N_det, psi_det and psi_coef need to be touched
|
After calling this subroutine, N_det, psi_det and psi_coef need to be touched
|
||||||
|
|
||||||
`fill_h_apply_buffer_no_selection <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/H_apply.irp.f#L187>`_
|
`debug_unicity_of_determinants <http://github.com/LCPQ/quantum_package/tree/master/src/Dets/H_apply.irp.f#L187>`_
|
||||||
|
This subroutine checks that there are no repetitions in the wave function
|
||||||
|
|
||||||
|
`fill_h_apply_buffer_no_selection <http://github.com/LCPQ/quantum_package/tree/master/src/Dets/H_apply.irp.f#L222>`_
|
||||||
Fill the H_apply buffer with determiants for CISD
|
Fill the H_apply buffer with determiants for CISD
|
||||||
|
|
||||||
`h_apply_buffer_allocated <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/H_apply.irp.f#L15>`_
|
`h_apply_buffer_allocated <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/H_apply.irp.f#L15>`_
|
||||||
|
@ -35,8 +35,7 @@ END_PROVIDER
|
|||||||
do i=1,N_det
|
do i=1,N_det
|
||||||
CI_SC2_eigenvectors(i,j) = psi_coef(i,j)
|
CI_SC2_eigenvectors(i,j) = psi_coef(i,j)
|
||||||
enddo
|
enddo
|
||||||
! TODO : check comment
|
CI_SC2_electronic_energy(j) = CI_electronic_energy(j)
|
||||||
! CI_SC2_electronic_energy(j) = CI_electronic_energy(j)
|
|
||||||
enddo
|
enddo
|
||||||
|
|
||||||
call CISD_SC2(psi_det,CI_SC2_eigenvectors,CI_SC2_electronic_energy, &
|
call CISD_SC2(psi_det,CI_SC2_eigenvectors,CI_SC2_electronic_energy, &
|
||||||
|
@ -235,8 +235,8 @@ subroutine filter_connected_davidson(key1,key2,Nint,sze,idx)
|
|||||||
|
|
||||||
else if (Nint==3) then
|
else if (Nint==3) then
|
||||||
|
|
||||||
!DIR$ LOOP COUNT (1000)
|
|
||||||
i = idx(0)
|
i = idx(0)
|
||||||
|
!DIR$ LOOP COUNT (1000)
|
||||||
do j_int=1,N_con_int
|
do j_int=1,N_con_int
|
||||||
itmp = det_connections(j_int,i)
|
itmp = det_connections(j_int,i)
|
||||||
do while (itmp /= 0_8)
|
do while (itmp /= 0_8)
|
||||||
@ -261,8 +261,8 @@ subroutine filter_connected_davidson(key1,key2,Nint,sze,idx)
|
|||||||
|
|
||||||
else
|
else
|
||||||
|
|
||||||
!DIR$ LOOP COUNT (1000)
|
|
||||||
i = idx(0)
|
i = idx(0)
|
||||||
|
!DIR$ LOOP COUNT (1000)
|
||||||
do j_int=1,N_con_int
|
do j_int=1,N_con_int
|
||||||
itmp = det_connections(j_int,i)
|
itmp = det_connections(j_int,i)
|
||||||
do while (itmp /= 0_8)
|
do while (itmp /= 0_8)
|
||||||
|
@ -161,7 +161,7 @@ subroutine save_casino
|
|||||||
if (ao_l(i) == ao_power(i,1)) then
|
if (ao_l(i) == ao_power(i,1)) then
|
||||||
do j=1,ao_prim_num(i)
|
do j=1,ao_prim_num(i)
|
||||||
l+=1
|
l+=1
|
||||||
rtmp(l) = ao_coef(i,ao_prim_num(i)-j+1)
|
rtmp(l) = ao_coef_normalized(i,ao_prim_num(i))
|
||||||
enddo
|
enddo
|
||||||
endif
|
endif
|
||||||
enddo
|
enddo
|
||||||
|
@ -0,0 +1,4 @@
|
|||||||
|
ASSUMPTONS
|
||||||
|
==========
|
||||||
|
|
||||||
|
* The AO basis functions are normalized.
|
@ -8,6 +8,8 @@ Molecular orbitals are expressed as
|
|||||||
|
|
||||||
\phi_k({\bf r}) = \sum_i C_{ik} \chi_k({\bf r})
|
\phi_k({\bf r}) = \sum_i C_{ik} \chi_k({\bf r})
|
||||||
|
|
||||||
|
where :math:`\chi_k` are *normalized* atomic basis set.
|
||||||
|
|
||||||
The current set of molecular orbitals has a label ``mo_label``.
|
The current set of molecular orbitals has a label ``mo_label``.
|
||||||
When the orbitals are modified, the label should also be updated to keep
|
When the orbitals are modified, the label should also be updated to keep
|
||||||
everything consistent.
|
everything consistent.
|
||||||
|
@ -92,9 +92,9 @@ subroutine write_Ao_basis(i_unit_output)
|
|||||||
do k = 1, ao_prim_num(i_ao)
|
do k = 1, ao_prim_num(i_ao)
|
||||||
i_prim +=1
|
i_prim +=1
|
||||||
if(i_prim.lt.100)then
|
if(i_prim.lt.100)then
|
||||||
write(i_unit_output,'(4X,I3,3X,A1,6X,I2,6X,F16.7,2X,F16.12)')i_shell,character_shell,i_prim,ao_expo_unsorted(i_ao,k),ao_coef_unnormalized(i_ao,k)
|
write(i_unit_output,'(4X,I3,3X,A1,6X,I2,6X,F16.7,2X,F16.12)')i_shell,character_shell,i_prim,ao_expo(i_ao,k),ao_coef(i_ao,k)
|
||||||
else
|
else
|
||||||
write(i_unit_output,'(4X,I3,3X,A1,5X,I3,6X,F16.7,2X,F16.12)')i_shell,character_shell,i_prim,ao_expo_unsorted(i_ao,k),ao_coef_unnormalized(i_ao,k)
|
write(i_unit_output,'(4X,I3,3X,A1,5X,I3,6X,F16.7,2X,F16.12)')i_shell,character_shell,i_prim,ao_expo(i_ao,k),ao_coef(i_ao,k)
|
||||||
endif
|
endif
|
||||||
enddo
|
enddo
|
||||||
write(i_unit_output,*)''
|
write(i_unit_output,*)''
|
||||||
|
@ -36,8 +36,8 @@
|
|||||||
!$OMP alpha, beta,i,j,c,d_a_2,d_2,deriv_tmp, &
|
!$OMP alpha, beta,i,j,c,d_a_2,d_2,deriv_tmp, &
|
||||||
!$OMP overlap_x0,overlap_y0,overlap_z0) &
|
!$OMP overlap_x0,overlap_y0,overlap_z0) &
|
||||||
!$OMP SHARED(nucl_coord,ao_power,ao_prim_num, &
|
!$OMP SHARED(nucl_coord,ao_power,ao_prim_num, &
|
||||||
!$OMP ao_deriv2_x,ao_deriv2_y,ao_deriv2_z,ao_num,ao_coef_transp,ao_nucl, &
|
!$OMP ao_deriv2_x,ao_deriv2_y,ao_deriv2_z,ao_num,ao_coef_normalized_ordered_transp,ao_nucl, &
|
||||||
!$OMP ao_expo_transp,dim1)
|
!$OMP ao_expo_ordered_transp,dim1)
|
||||||
do j=1,ao_num
|
do j=1,ao_num
|
||||||
A_center(1) = nucl_coord( ao_nucl(j), 1 )
|
A_center(1) = nucl_coord( ao_nucl(j), 1 )
|
||||||
A_center(2) = nucl_coord( ao_nucl(j), 2 )
|
A_center(2) = nucl_coord( ao_nucl(j), 2 )
|
||||||
@ -58,12 +58,12 @@
|
|||||||
power_B(2) = ao_power( i, 2 )
|
power_B(2) = ao_power( i, 2 )
|
||||||
power_B(3) = ao_power( i, 3 )
|
power_B(3) = ao_power( i, 3 )
|
||||||
do n = 1,ao_prim_num(j)
|
do n = 1,ao_prim_num(j)
|
||||||
alpha = ao_expo_transp(n,j)
|
alpha = ao_expo_ordered_transp(n,j)
|
||||||
!DEC$ VECTOR ALIGNED
|
!DEC$ VECTOR ALIGNED
|
||||||
do l = 1, ao_prim_num(i)
|
do l = 1, ao_prim_num(i)
|
||||||
beta = ao_expo_transp(l,i)
|
beta = ao_expo_ordered_transp(l,i)
|
||||||
call overlap_gaussian_xyz(A_center,B_center,alpha,beta,power_A,power_B,overlap_x0,overlap_y0,overlap_z0,overlap,dim1)
|
call overlap_gaussian_xyz(A_center,B_center,alpha,beta,power_A,power_B,overlap_x0,overlap_y0,overlap_z0,overlap,dim1)
|
||||||
c = ao_coef_transp(n,j) * ao_coef_transp(l,i)
|
c = ao_coef_normalized_ordered_transp(n,j) * ao_coef_normalized_ordered_transp(l,i)
|
||||||
! if (abs(c) < 1.d-8) then
|
! if (abs(c) < 1.d-8) then
|
||||||
! cycle
|
! cycle
|
||||||
! endif
|
! endif
|
||||||
|
@ -25,7 +25,7 @@
|
|||||||
!$OMP DEFAULT (NONE) &
|
!$OMP DEFAULT (NONE) &
|
||||||
!$OMP PRIVATE (i,j,k,l,m,alpha,beta,A_center,B_center,C_center,power_A,power_B, &
|
!$OMP PRIVATE (i,j,k,l,m,alpha,beta,A_center,B_center,C_center,power_A,power_B, &
|
||||||
!$OMP num_A,num_B,Z,c,n_pt_in) &
|
!$OMP num_A,num_B,Z,c,n_pt_in) &
|
||||||
!$OMP SHARED (ao_num,ao_prim_num,ao_expo_transp,ao_power,ao_nucl,nucl_coord,ao_coef_transp, &
|
!$OMP SHARED (ao_num,ao_prim_num,ao_expo_ordered_transp,ao_power,ao_nucl,nucl_coord,ao_coef_normalized_ordered_transp, &
|
||||||
!$OMP n_pt_max_integrals,ao_nucl_elec_integral,nucl_num,nucl_charge)
|
!$OMP n_pt_max_integrals,ao_nucl_elec_integral,nucl_num,nucl_charge)
|
||||||
|
|
||||||
n_pt_in = n_pt_max_integrals
|
n_pt_in = n_pt_max_integrals
|
||||||
@ -33,39 +33,39 @@
|
|||||||
!$OMP DO SCHEDULE (guided)
|
!$OMP DO SCHEDULE (guided)
|
||||||
|
|
||||||
do j = 1, ao_num
|
do j = 1, ao_num
|
||||||
num_A = ao_nucl(j)
|
num_A = ao_nucl(j)
|
||||||
power_A(1:3)= ao_power(j,1:3)
|
power_A(1:3)= ao_power(j,1:3)
|
||||||
A_center(1:3) = nucl_coord(num_A,1:3)
|
A_center(1:3) = nucl_coord(num_A,1:3)
|
||||||
|
|
||||||
do i = 1, ao_num
|
do i = 1, ao_num
|
||||||
|
|
||||||
num_B = ao_nucl(i)
|
num_B = ao_nucl(i)
|
||||||
power_B(1:3)= ao_power(i,1:3)
|
power_B(1:3)= ao_power(i,1:3)
|
||||||
B_center(1:3) = nucl_coord(num_B,1:3)
|
B_center(1:3) = nucl_coord(num_B,1:3)
|
||||||
|
|
||||||
do l=1,ao_prim_num(j)
|
do l=1,ao_prim_num(j)
|
||||||
alpha = ao_expo_transp(l,j)
|
alpha = ao_expo_ordered_transp(l,j)
|
||||||
|
|
||||||
do m=1,ao_prim_num(i)
|
do m=1,ao_prim_num(i)
|
||||||
beta = ao_expo_transp(m,i)
|
beta = ao_expo_ordered_transp(m,i)
|
||||||
|
|
||||||
double precision :: c
|
double precision :: c
|
||||||
c = 0.d0
|
c = 0.d0
|
||||||
|
|
||||||
do k = 1, nucl_num
|
do k = 1, nucl_num
|
||||||
double precision :: Z
|
double precision :: Z
|
||||||
Z = nucl_charge(k)
|
Z = nucl_charge(k)
|
||||||
|
|
||||||
C_center(1:3) = nucl_coord(k,1:3)
|
C_center(1:3) = nucl_coord(k,1:3)
|
||||||
|
|
||||||
c = c - Z*NAI_pol_mult(A_center,B_center,power_A,power_B,alpha,beta,C_center,n_pt_in)
|
c = c - Z*NAI_pol_mult(A_center,B_center,power_A,power_B,alpha,beta,C_center,n_pt_in)
|
||||||
|
|
||||||
|
enddo
|
||||||
|
ao_nucl_elec_integral(i,j) = ao_nucl_elec_integral(i,j) + &
|
||||||
|
ao_coef_normalized_ordered_transp(l,j)*ao_coef_normalized_ordered_transp(m,i)*c
|
||||||
|
enddo
|
||||||
enddo
|
enddo
|
||||||
ao_nucl_elec_integral(i,j) = ao_nucl_elec_integral(i,j) + &
|
enddo
|
||||||
ao_coef_transp(l,j)*ao_coef_transp(m,i)*c
|
|
||||||
enddo
|
|
||||||
enddo
|
|
||||||
enddo
|
|
||||||
enddo
|
enddo
|
||||||
|
|
||||||
!$OMP END DO
|
!$OMP END DO
|
||||||
@ -98,7 +98,7 @@
|
|||||||
!$OMP DEFAULT (NONE) &
|
!$OMP DEFAULT (NONE) &
|
||||||
!$OMP PRIVATE (i,j,l,m,alpha,beta,A_center,B_center,power_A,power_B, &
|
!$OMP PRIVATE (i,j,l,m,alpha,beta,A_center,B_center,power_A,power_B, &
|
||||||
!$OMP num_A,num_B,c,n_pt_in) &
|
!$OMP num_A,num_B,c,n_pt_in) &
|
||||||
!$OMP SHARED (k,ao_num,ao_prim_num,ao_expo_transp,ao_power,ao_nucl,nucl_coord,ao_coef_transp, &
|
!$OMP SHARED (k,ao_num,ao_prim_num,ao_expo_ordered_transp,ao_power,ao_nucl,nucl_coord,ao_coef_normalized_ordered_transp, &
|
||||||
!$OMP n_pt_max_integrals,ao_nucl_elec_integral_per_atom,nucl_num,C_center)
|
!$OMP n_pt_max_integrals,ao_nucl_elec_integral_per_atom,nucl_num,C_center)
|
||||||
n_pt_in = n_pt_max_integrals
|
n_pt_in = n_pt_max_integrals
|
||||||
!$OMP DO SCHEDULE (guided)
|
!$OMP DO SCHEDULE (guided)
|
||||||
@ -122,11 +122,11 @@
|
|||||||
B_center(3) = nucl_coord(num_B,3)
|
B_center(3) = nucl_coord(num_B,3)
|
||||||
c = 0.d0
|
c = 0.d0
|
||||||
do l=1,ao_prim_num(j)
|
do l=1,ao_prim_num(j)
|
||||||
alpha = ao_expo_transp(l,j)
|
alpha = ao_expo_ordered_transp(l,j)
|
||||||
do m=1,ao_prim_num(i)
|
do m=1,ao_prim_num(i)
|
||||||
beta = ao_expo_transp(m,i)
|
beta = ao_expo_ordered_transp(m,i)
|
||||||
c = c + NAI_pol_mult(A_center,B_center,power_A,power_B,alpha,beta,C_center,n_pt_in) &
|
c = c + NAI_pol_mult(A_center,B_center,power_A,power_B,alpha,beta,C_center,n_pt_in) &
|
||||||
* ao_coef_transp(l,j)*ao_coef_transp(m,i)
|
* ao_coef_normalized_ordered_transp(l,j)*ao_coef_normalized_ordered_transp(m,i)
|
||||||
enddo
|
enddo
|
||||||
enddo
|
enddo
|
||||||
ao_nucl_elec_integral_per_atom(i,j,k) = -c
|
ao_nucl_elec_integral_per_atom(i,j,k) = -c
|
||||||
|
@ -26,8 +26,8 @@
|
|||||||
!$OMP overlap_x,overlap_y, overlap_z, overlap, &
|
!$OMP overlap_x,overlap_y, overlap_z, overlap, &
|
||||||
!$OMP alpha, beta,i,j,dx,tmp,c,accu_x,accu_y,accu_z) &
|
!$OMP alpha, beta,i,j,dx,tmp,c,accu_x,accu_y,accu_z) &
|
||||||
!$OMP SHARED(nucl_coord,ao_power,ao_prim_num, &
|
!$OMP SHARED(nucl_coord,ao_power,ao_prim_num, &
|
||||||
!$OMP ao_spread_x,ao_spread_y,ao_spread_z,ao_num,ao_coef_transp,ao_nucl, &
|
!$OMP ao_spread_x,ao_spread_y,ao_spread_z,ao_num,ao_coef_normalized_ordered_transp,ao_nucl, &
|
||||||
!$OMP ao_expo_transp,dim1,lower_exp_val)
|
!$OMP ao_expo_ordered_transp,dim1,lower_exp_val)
|
||||||
do j=1,ao_num
|
do j=1,ao_num
|
||||||
A_center(1) = nucl_coord( ao_nucl(j), 1 )
|
A_center(1) = nucl_coord( ao_nucl(j), 1 )
|
||||||
A_center(2) = nucl_coord( ao_nucl(j), 2 )
|
A_center(2) = nucl_coord( ao_nucl(j), 2 )
|
||||||
@ -48,11 +48,11 @@
|
|||||||
accu_y = 0.d0
|
accu_y = 0.d0
|
||||||
accu_z = 0.d0
|
accu_z = 0.d0
|
||||||
do n = 1,ao_prim_num(j)
|
do n = 1,ao_prim_num(j)
|
||||||
alpha = ao_expo_transp(n,j)
|
alpha = ao_expo_ordered_transp(n,j)
|
||||||
!DEC$ VECTOR ALIGNED
|
!DEC$ VECTOR ALIGNED
|
||||||
do l = 1, ao_prim_num(i)
|
do l = 1, ao_prim_num(i)
|
||||||
c = ao_coef_transp(n,j)*ao_coef_transp(l,i)
|
c = ao_coef_normalized_ordered_transp(n,j)*ao_coef_normalized_ordered_transp(l,i)
|
||||||
beta = ao_expo_transp(l,i)
|
beta = ao_expo_ordered_transp(l,i)
|
||||||
call overlap_gaussian_xyz(A_center,B_center,alpha,beta,power_A,power_B,overlap_x,overlap_y,overlap_z,overlap,dim1)
|
call overlap_gaussian_xyz(A_center,B_center,alpha,beta,power_A,power_B,overlap_x,overlap_y,overlap_z,overlap,dim1)
|
||||||
call overlap_bourrin_spread(A_center(1),B_center(1),alpha,beta,power_A(1),power_B(1),tmp,lower_exp_val,dx,dim1)
|
call overlap_bourrin_spread(A_center(1),B_center(1),alpha,beta,power_A(1),power_B(1),tmp,lower_exp_val,dx,dim1)
|
||||||
accu_x += c*(tmp*overlap_y*overlap_z)
|
accu_x += c*(tmp*overlap_y*overlap_z)
|
||||||
@ -100,8 +100,8 @@
|
|||||||
!$OMP overlap_x,overlap_y, overlap_z, overlap, &
|
!$OMP overlap_x,overlap_y, overlap_z, overlap, &
|
||||||
!$OMP alpha, beta,i,j,dx,tmp,c,accu_x,accu_y,accu_z) &
|
!$OMP alpha, beta,i,j,dx,tmp,c,accu_x,accu_y,accu_z) &
|
||||||
!$OMP SHARED(nucl_coord,ao_power,ao_prim_num, &
|
!$OMP SHARED(nucl_coord,ao_power,ao_prim_num, &
|
||||||
!$OMP ao_dipole_x,ao_dipole_y,ao_dipole_z,ao_num,ao_coef_transp,ao_nucl, &
|
!$OMP ao_dipole_x,ao_dipole_y,ao_dipole_z,ao_num,ao_coef_normalized_ordered_transp,ao_nucl, &
|
||||||
!$OMP ao_expo_transp,dim1,lower_exp_val)
|
!$OMP ao_expo_ordered_transp,dim1,lower_exp_val)
|
||||||
do j=1,ao_num
|
do j=1,ao_num
|
||||||
A_center(1) = nucl_coord( ao_nucl(j), 1 )
|
A_center(1) = nucl_coord( ao_nucl(j), 1 )
|
||||||
A_center(2) = nucl_coord( ao_nucl(j), 2 )
|
A_center(2) = nucl_coord( ao_nucl(j), 2 )
|
||||||
@ -122,11 +122,11 @@
|
|||||||
accu_y = 0.d0
|
accu_y = 0.d0
|
||||||
accu_z = 0.d0
|
accu_z = 0.d0
|
||||||
do n = 1,ao_prim_num(j)
|
do n = 1,ao_prim_num(j)
|
||||||
alpha = ao_expo_transp(n,j)
|
alpha = ao_expo_ordered_transp(n,j)
|
||||||
!DEC$ VECTOR ALIGNED
|
!DEC$ VECTOR ALIGNED
|
||||||
do l = 1, ao_prim_num(i)
|
do l = 1, ao_prim_num(i)
|
||||||
beta = ao_expo_transp(l,i)
|
beta = ao_expo_ordered_transp(l,i)
|
||||||
c = ao_coef_transp(l,i)*ao_coef_transp(n,j)
|
c = ao_coef_normalized_ordered_transp(l,i)*ao_coef_normalized_ordered_transp(n,j)
|
||||||
call overlap_gaussian_xyz(A_center,B_center,alpha,beta,power_A,power_B,overlap_x,overlap_y,overlap_z,overlap,dim1)
|
call overlap_gaussian_xyz(A_center,B_center,alpha,beta,power_A,power_B,overlap_x,overlap_y,overlap_z,overlap,dim1)
|
||||||
|
|
||||||
call overlap_bourrin_dipole(A_center(1),B_center(1),alpha,beta,power_A(1),power_B(1),tmp,lower_exp_val,dx,dim1)
|
call overlap_bourrin_dipole(A_center(1),B_center(1),alpha,beta,power_A(1),power_B(1),tmp,lower_exp_val,dx,dim1)
|
||||||
@ -174,8 +174,8 @@
|
|||||||
!$OMP overlap_x,overlap_y, overlap_z, overlap, &
|
!$OMP overlap_x,overlap_y, overlap_z, overlap, &
|
||||||
!$OMP alpha, beta,i,j,dx,tmp,c,i_component,accu_x,accu_y,accu_z) &
|
!$OMP alpha, beta,i,j,dx,tmp,c,i_component,accu_x,accu_y,accu_z) &
|
||||||
!$OMP SHARED(nucl_coord,ao_power,ao_prim_num, &
|
!$OMP SHARED(nucl_coord,ao_power,ao_prim_num, &
|
||||||
!$OMP ao_deriv_1_x,ao_deriv_1_y,ao_deriv_1_z,ao_num,ao_coef_transp,ao_nucl, &
|
!$OMP ao_deriv_1_x,ao_deriv_1_y,ao_deriv_1_z,ao_num,ao_coef_normalized_ordered_transp,ao_nucl, &
|
||||||
!$OMP ao_expo_transp,dim1,lower_exp_val)
|
!$OMP ao_expo_ordered_transp,dim1,lower_exp_val)
|
||||||
do j=1,ao_num
|
do j=1,ao_num
|
||||||
A_center(1) = nucl_coord( ao_nucl(j), 1 )
|
A_center(1) = nucl_coord( ao_nucl(j), 1 )
|
||||||
A_center(2) = nucl_coord( ao_nucl(j), 2 )
|
A_center(2) = nucl_coord( ao_nucl(j), 2 )
|
||||||
@ -196,12 +196,12 @@
|
|||||||
accu_y = 0.d0
|
accu_y = 0.d0
|
||||||
accu_z = 0.d0
|
accu_z = 0.d0
|
||||||
do n = 1,ao_prim_num(j)
|
do n = 1,ao_prim_num(j)
|
||||||
alpha = ao_expo_transp(n,j)
|
alpha = ao_expo_ordered_transp(n,j)
|
||||||
!DEC$ VECTOR ALIGNED
|
!DEC$ VECTOR ALIGNED
|
||||||
do l = 1, ao_prim_num(i)
|
do l = 1, ao_prim_num(i)
|
||||||
beta = ao_expo_transp(l,i)
|
beta = ao_expo_ordered_transp(l,i)
|
||||||
call overlap_gaussian_xyz(A_center,B_center,alpha,beta,power_A,power_B,overlap_x,overlap_y,overlap_z,overlap,dim1)
|
call overlap_gaussian_xyz(A_center,B_center,alpha,beta,power_A,power_B,overlap_x,overlap_y,overlap_z,overlap,dim1)
|
||||||
c = ao_coef_transp(l,i) * ao_coef_transp(n,j)
|
c = ao_coef_normalized_ordered_transp(l,i) * ao_coef_normalized_ordered_transp(n,j)
|
||||||
i_component = 1
|
i_component = 1
|
||||||
call overlap_bourrin_deriv_x(i_component,A_center,B_center,alpha,beta,power_A,power_B,dx,lower_exp_val,tmp,dim1)
|
call overlap_bourrin_deriv_x(i_component,A_center,B_center,alpha,beta,power_A,power_B,dx,lower_exp_val,tmp,dim1)
|
||||||
accu_x += c*(tmp*overlap_y*overlap_z)
|
accu_x += c*(tmp*overlap_y*overlap_z)
|
||||||
|
@ -79,7 +79,7 @@ BEGIN_PROVIDER [ double precision, ao_integrated_delta_rho_all_points, (ao_num_a
|
|||||||
!$OMP PARALLEL DO DEFAULT(none) &
|
!$OMP PARALLEL DO DEFAULT(none) &
|
||||||
!$OMP PRIVATE(i,j,n,l,A_center,power_A,B_center,power_B,accu_z, &
|
!$OMP PRIVATE(i,j,n,l,A_center,power_A,B_center,power_B,accu_z, &
|
||||||
!$OMP overlap_x,overlap_y,overlap_z,overlap,c,alpha,beta) &
|
!$OMP overlap_x,overlap_y,overlap_z,overlap,c,alpha,beta) &
|
||||||
!$OMP SHARED(ao_num,nucl_coord,ao_nucl,ao_power,ao_prim_num,ao_expo_transp,ao_coef_transp, &
|
!$OMP SHARED(ao_num,nucl_coord,ao_nucl,ao_power,ao_prim_num,ao_expo_ordered_transp,ao_coef_normalized_ordered_transp, &
|
||||||
!$OMP ao_integrated_delta_rho_all_points,N_z_pts,dim1,i_z,z,delta_z)
|
!$OMP ao_integrated_delta_rho_all_points,N_z_pts,dim1,i_z,z,delta_z)
|
||||||
do j=1,ao_num
|
do j=1,ao_num
|
||||||
A_center(1) = nucl_coord( ao_nucl(j), 1 )
|
A_center(1) = nucl_coord( ao_nucl(j), 1 )
|
||||||
@ -98,12 +98,12 @@ BEGIN_PROVIDER [ double precision, ao_integrated_delta_rho_all_points, (ao_num_a
|
|||||||
|
|
||||||
accu_z = 0.d0
|
accu_z = 0.d0
|
||||||
do n = 1,ao_prim_num(j)
|
do n = 1,ao_prim_num(j)
|
||||||
alpha = ao_expo_transp(n,j)
|
alpha = ao_expo_ordered_transp(n,j)
|
||||||
do l = 1, ao_prim_num(i)
|
do l = 1, ao_prim_num(i)
|
||||||
beta = ao_expo_transp(l,i)
|
beta = ao_expo_ordered_transp(l,i)
|
||||||
call overlap_gaussian_xyz(A_center,B_center,alpha,beta,power_A,power_B,overlap_x,overlap_y,overlap_z,overlap,dim1)
|
call overlap_gaussian_xyz(A_center,B_center,alpha,beta,power_A,power_B,overlap_x,overlap_y,overlap_z,overlap,dim1)
|
||||||
|
|
||||||
c = ao_coef_transp(n,j) * ao_coef_transp(l,i)
|
c = ao_coef_normalized_ordered_transp(n,j) * ao_coef_normalized_ordered_transp(l,i)
|
||||||
accu_z += c* overlap_x * overlap_y * SABpartial(z,z+delta_z,A_center,B_center,power_A,power_B,alpha,beta)
|
accu_z += c* overlap_x * overlap_y * SABpartial(z,z+delta_z,A_center,B_center,power_A,power_B,alpha,beta)
|
||||||
enddo
|
enddo
|
||||||
enddo
|
enddo
|
||||||
@ -147,7 +147,7 @@ BEGIN_PROVIDER [ double precision, ao_integrated_delta_rho_one_point, (ao_num_al
|
|||||||
!$OMP PARALLEL DO DEFAULT(none) &
|
!$OMP PARALLEL DO DEFAULT(none) &
|
||||||
!$OMP PRIVATE(i,j,n,l,A_center,power_A,B_center,power_B,accu_z, &
|
!$OMP PRIVATE(i,j,n,l,A_center,power_A,B_center,power_B,accu_z, &
|
||||||
!$OMP overlap_x,overlap_y,overlap_z,overlap,c,alpha,beta) &
|
!$OMP overlap_x,overlap_y,overlap_z,overlap,c,alpha,beta) &
|
||||||
!$OMP SHARED(ao_num,nucl_coord,ao_nucl,ao_power,ao_prim_num,ao_expo_transp,ao_coef_transp, &
|
!$OMP SHARED(ao_num,nucl_coord,ao_nucl,ao_power,ao_prim_num,ao_expo_ordered_transp,ao_coef_normalized_ordered_transp, &
|
||||||
!$OMP ao_integrated_delta_rho_one_point,dim1,z,delta_z)
|
!$OMP ao_integrated_delta_rho_one_point,dim1,z,delta_z)
|
||||||
do j=1,ao_num
|
do j=1,ao_num
|
||||||
A_center(1) = nucl_coord( ao_nucl(j), 1 )
|
A_center(1) = nucl_coord( ao_nucl(j), 1 )
|
||||||
@ -166,12 +166,12 @@ BEGIN_PROVIDER [ double precision, ao_integrated_delta_rho_one_point, (ao_num_al
|
|||||||
|
|
||||||
accu_z = 0.d0
|
accu_z = 0.d0
|
||||||
do n = 1,ao_prim_num(j)
|
do n = 1,ao_prim_num(j)
|
||||||
alpha = ao_expo_transp(n,j)
|
alpha = ao_expo_ordered_transp(n,j)
|
||||||
do l = 1, ao_prim_num(i)
|
do l = 1, ao_prim_num(i)
|
||||||
beta = ao_expo_transp(l,i)
|
beta = ao_expo_ordered_transp(l,i)
|
||||||
call overlap_gaussian_xyz(A_center,B_center,alpha,beta,power_A,power_B,overlap_x,overlap_y,overlap_z,overlap,dim1)
|
call overlap_gaussian_xyz(A_center,B_center,alpha,beta,power_A,power_B,overlap_x,overlap_y,overlap_z,overlap,dim1)
|
||||||
|
|
||||||
c = ao_coef_transp(n,j) * ao_coef_transp(l,i)
|
c = ao_coef_normalized_ordered_transp(n,j) * ao_coef_normalized_ordered_transp(l,i)
|
||||||
accu_z += c* overlap_x * overlap_y * SABpartial(z,z+delta_z,A_center,B_center,power_A,power_B,alpha,beta)
|
accu_z += c* overlap_x * overlap_y * SABpartial(z,z+delta_z,A_center,B_center,power_A,power_B,alpha,beta)
|
||||||
enddo
|
enddo
|
||||||
enddo
|
enddo
|
||||||
|
@ -84,7 +84,7 @@
|
|||||||
!$OMP num_A,num_B,Z,c,n_pt_in, &
|
!$OMP num_A,num_B,Z,c,n_pt_in, &
|
||||||
!$OMP v_k_dump,n_k_dump, dz_k_dump, n_kl_dump, v_kl_dump, dz_kl_dump, &
|
!$OMP v_k_dump,n_k_dump, dz_k_dump, n_kl_dump, v_kl_dump, dz_kl_dump, &
|
||||||
!$OMP wall_0,wall_2,thread_num, output_monoints) &
|
!$OMP wall_0,wall_2,thread_num, output_monoints) &
|
||||||
!$OMP SHARED (ao_num,ao_prim_num,ao_expo_transp,ao_power,ao_nucl,nucl_coord,ao_coef_transp, &
|
!$OMP SHARED (ao_num,ao_prim_num,ao_expo_ordered_transp,ao_power,ao_nucl,nucl_coord,ao_coef_normalized_ordered_transp, &
|
||||||
!$OMP ao_nucl_elec_integral_pseudo,nucl_num,nucl_charge, &
|
!$OMP ao_nucl_elec_integral_pseudo,nucl_num,nucl_charge, &
|
||||||
!$OMP klocmax,lmax,kmax,v_k,n_k, dz_k, n_kl, v_kl, dz_kl, &
|
!$OMP klocmax,lmax,kmax,v_k,n_k, dz_k, n_kl, v_kl, dz_kl, &
|
||||||
!$OMP wall_1)
|
!$OMP wall_1)
|
||||||
@ -104,10 +104,10 @@
|
|||||||
B_center(1:3) = nucl_coord(num_B,1:3)
|
B_center(1:3) = nucl_coord(num_B,1:3)
|
||||||
|
|
||||||
do l=1,ao_prim_num(j)
|
do l=1,ao_prim_num(j)
|
||||||
alpha = ao_expo_transp(l,j)
|
alpha = ao_expo_ordered_transp(l,j)
|
||||||
|
|
||||||
do m=1,ao_prim_num(i)
|
do m=1,ao_prim_num(i)
|
||||||
beta = ao_expo_transp(m,i)
|
beta = ao_expo_ordered_transp(m,i)
|
||||||
double precision :: c
|
double precision :: c
|
||||||
c = 0.d0
|
c = 0.d0
|
||||||
|
|
||||||
@ -133,7 +133,7 @@
|
|||||||
|
|
||||||
enddo
|
enddo
|
||||||
ao_nucl_elec_integral_pseudo(i,j) = ao_nucl_elec_integral_pseudo(i,j) + &
|
ao_nucl_elec_integral_pseudo(i,j) = ao_nucl_elec_integral_pseudo(i,j) + &
|
||||||
ao_coef_transp(l,j)*ao_coef_transp(m,i)*c
|
ao_coef_normalized_ordered_transp(l,j)*ao_coef_normalized_ordered_transp(m,i)*c
|
||||||
enddo
|
enddo
|
||||||
enddo
|
enddo
|
||||||
enddo
|
enddo
|
||||||
|
Loading…
Reference in New Issue
Block a user