10
0
mirror of https://github.com/QuantumPackage/qp2.git synced 2024-06-30 00:44:37 +02:00

Merge branch 'develop' of https://github.com/QuantumPackage/qp2 into develop

This commit is contained in:
eginer 2019-01-30 11:47:08 +01:00
commit ab5fd75524
114 changed files with 954 additions and 665 deletions

View File

@ -12,7 +12,6 @@
.. _Irene: http://www-hpc.cea.fr/en/complexe/tgcc-Irene.htm .. _Irene: http://www-hpc.cea.fr/en/complexe/tgcc-Irene.htm
.. _IRPF90: http://irpf90.ups-tlse.fr .. _IRPF90: http://irpf90.ups-tlse.fr
.. _LAPACK: http://www.netlib.org/lapack/ .. _LAPACK: http://www.netlib.org/lapack/
.. _Molden: http://cheminf.cmbi.ru.nl/molden/
.. _NECI: https://github.com/ghb24/NECI_STABLE .. _NECI: https://github.com/ghb24/NECI_STABLE
.. _Ninja: https://ninja-build.org/ .. _Ninja: https://ninja-build.org/
.. _NWChem: http://www.nwchem-sw.org/ .. _NWChem: http://www.nwchem-sw.org/
@ -53,12 +52,15 @@
.. |CIPSI| replace:: :abbr:`CIPSI (Configuration Interaction using a Perturbative Selection)` .. |CIPSI| replace:: :abbr:`CIPSI (Configuration Interaction using a Perturbative Selection)`
.. |CI| replace:: :abbr:`CI (Configuration Interaction)` .. |CI| replace:: :abbr:`CI (Configuration Interaction)`
.. |CISD| replace:: :abbr:`CISD (Configuration Interaction with Single and Double Excitations)` .. |CISD| replace:: :abbr:`CISD (Configuration Interaction with Single and Double Excitations)`
.. |CASSCF| replace:: |CAS| - |SCF|
.. |CIS| replace:: :abbr:`CIS (Configuration Interaction with Single Excitations)` .. |CIS| replace:: :abbr:`CIS (Configuration Interaction with Single Excitations)`
.. |DFT| replace:: :abbr:`DFT (Density Functional Theory)`
.. |DDCI| replace:: :abbr:`DDCI (Difference Dedicated Configuration Interaction)` .. |DDCI| replace:: :abbr:`DDCI (Difference Dedicated Configuration Interaction)`
.. |DFT| replace:: :abbr:`DFT (Density Functional Theory)`
.. |DIIS| replace:: :abbr:`DIIS (Direct Inversion of the Iterative Subspace)` .. |DIIS| replace:: :abbr:`DIIS (Direct Inversion of the Iterative Subspace)`
.. |FCIQMC| replace:: |FCI| - |QMC|
.. |FCI| replace:: :abbr:`FCI (Full Configuration Interaction)` .. |FCI| replace:: :abbr:`FCI (Full Configuration Interaction)`
.. |HF| replace:: :abbr:`HF (Hartree-Fock)` .. |HF| replace:: :abbr:`HF (Hartree-Fock)`
.. |KS-DFT| replace:: :abbr:`KS-DFT (Kohn-Sham Density Functional Theory)`
.. |MO| replace:: :abbr:`MO (Molecular Orbital)` .. |MO| replace:: :abbr:`MO (Molecular Orbital)`
.. |MOs| replace:: :abbr:`MOs (Molecular Orbitals)` .. |MOs| replace:: :abbr:`MOs (Molecular Orbitals)`
.. |MP2| replace:: :abbr:`MP2 (Moller-Plesset second order perturbative correction)` .. |MP2| replace:: :abbr:`MP2 (Moller-Plesset second order perturbative correction)`
@ -67,15 +69,13 @@
.. |MRPT| replace:: :abbr:`MRPT (Multi-Reference Perturbation Theory)` .. |MRPT| replace:: :abbr:`MRPT (Multi-Reference Perturbation Theory)`
.. |PT2| replace:: :abbr:`PT2 (Second order perturbative correction)` .. |PT2| replace:: :abbr:`PT2 (Second order perturbative correction)`
.. |QMC| replace:: :abbr:`QMC (Quantum Monte Carlo)` .. |QMC| replace:: :abbr:`QMC (Quantum Monte Carlo)`
.. |ROHF| replace:: :abbr:`ROHF (Restricted Open-Shell Hartree-Fock)`
.. |RSDFT| replace:: :abbr:`RSDFT (Range Separated Density Functional Theory)`
.. |RSH| replace:: :abbr:`RSH (Range Separated Hybrids)`
.. |rst| replace:: :abbr:`RST (ReStructured Text)` .. |rst| replace:: :abbr:`RST (ReStructured Text)`
.. |SCF| replace:: :abbr:`SCF (Self Consistent Field)` .. |SCF| replace:: :abbr:`SCF (Self Consistent Field)`
.. |RSH| replace:: :abbr:`RSH (Range Separated Hybrids)`
.. |RSDFT| replace:: :abbr:`RSDFT (Range Separated Density Functional Theory)`
.. |KS-DFT| replace:: :abbr:`KS-DFT (Kohn-Sham Density Functional Theory)`
.. |sCI| replace:: :abbr:`sCI (Selected-CI)` .. |sCI| replace:: :abbr:`sCI (Selected-CI)`
.. |WFT| replace:: :abbr:`WFT (Wave Function Theory)` .. |WFT| replace:: :abbr:`WFT (Wave Function Theory)`
.. |CASSCF| replace:: |CAS| - |SCF|
.. |FCIQMC| replace:: |FCI| - |QMC|
.. |kalpha| replace:: :math:`|\alpha \rangle` .. |kalpha| replace:: :math:`|\alpha \rangle`
.. |H| replace:: :math:`\hat H` .. |H| replace:: :math:`\hat H`

View File

@ -171,7 +171,7 @@ for f in os.listdir("users_guide"):
for f in os.listdir("programs"): for f in os.listdir("programs"):
name = f.split('.')[0] name = f.split('.')[0]
if name not in []: if name not in [""]:
filename = os.path.join("programs",name) filename = os.path.join("programs",name)
man_pages.append( (filename, name, qpdoc, [author], 1) ) man_pages.append( (filename, name, qpdoc, [author], 1) )

View File

@ -55,8 +55,6 @@ Simple Algorithm
.. |SetDI| replace:: `\{|D_I\rangle\}^{(n)}` .. |SetDI| replace:: `\{|D_I\rangle\}^{(n)}`
.. |Psi_n| replace:: `|\Psi^{(n)}\rangle` .. |Psi_n| replace:: `|\Psi^{(n)}\rangle`
.. |H| replace:: `\hat H`
.. |kalpha| replace:: `|\alpha\rangle`
.. |kalpha_star| replace:: `\{ |\alpha \rangle \}_\star ^{(n)}` .. |kalpha_star| replace:: `\{ |\alpha \rangle \}_\star ^{(n)}`
.. |ealpha| replace:: `e_\alpha` .. |ealpha| replace:: `e_\alpha`
.. |EPT| replace:: `E_\text{PT2}` .. |EPT| replace:: `E_\text{PT2}`

View File

@ -23,9 +23,13 @@ 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` provider includes .. warning::
this normalization factor.
`ao_coef` contains the |AO| coefficients given in input. These do not
include the normalization constant of the |AO|. The `ao_coef_normalized`
provider includes this normalization factor.
The |AOs| are also sorted by increasing exponent to accelerate the calculation of The |AOs| are also sorted by increasing exponent to accelerate the calculation of
the two electron integrals. the two electron integrals.
@ -1076,7 +1080,7 @@ Subroutines / functions
double precision function ao_value(i,r) double precision function ao_value(i,r)
return the value of the ith ao at point r Returns the value of the i-th ao at point $\textbf{r}$
Needs: Needs:
@ -1101,9 +1105,12 @@ Subroutines / functions
subroutine give_all_aos_and_grad_and_lapl_at_r(r,aos_array,aos_grad_array,aos_lapl_array) subroutine give_all_aos_and_grad_and_lapl_at_r(r,aos_array,aos_grad_array,aos_lapl_array)
input : r(1) ==> r(1) = x, r(2) = y, r(3) = z input : r(1) ==> r(1) = x, r(2) = y, r(3) = z
output : aos_array(i) = ao(i) evaluated at r
: aos_grad_array(1,i) = gradient X of the ao(i) evaluated at r output :
* aos_array(i) = ao(i) evaluated at $\textbf{r}$
* aos_grad_array(1,i) = $\nabla_x$ of the ao(i) evaluated at $\textbf{r}$
Needs: Needs:
@ -1138,9 +1145,13 @@ Subroutines / functions
subroutine give_all_aos_and_grad_at_r(r,aos_array,aos_grad_array) subroutine give_all_aos_and_grad_at_r(r,aos_array,aos_grad_array)
input : r(1) ==> r(1) = x, r(2) = y, r(3) = z input : r(1) ==> r(1) = x, r(2) = y, r(3) = z
output : aos_array(i) = ao(i) evaluated at r
: aos_grad_array(1,i) = gradient X of the ao(i) evaluated at r output :
* aos_array(i) = ao(i) evaluated at ro
* aos_grad_array(1,i) = gradient X of the ao(i) evaluated at $\textbf{r}$
Needs: Needs:
@ -1175,8 +1186,9 @@ Subroutines / functions
subroutine give_all_aos_at_r(r,aos_array) subroutine give_all_aos_at_r(r,aos_array)
input : r == r(1) = x and so on input : r == r(1) = x and so on
aos_array(i) = aos(i) evaluated in r
output : aos_array(i) = aos(i) evaluated in $\textbf{r}$
Needs: Needs:
@ -1211,7 +1223,7 @@ Subroutines / functions
subroutine give_all_aos_at_r_old(r,aos_array) subroutine give_all_aos_at_r_old(r,aos_array)
gives the values of aos at a given point r Gives the values of |AOs| at a given point $\textbf{r}$
Needs: Needs:
@ -1231,7 +1243,8 @@ Subroutines / functions
double precision function primitive_value(i,j,r) double precision function primitive_value(i,j,r)
return the value of the jth primitive of ith ao at point r WITHOUT THE COEF Returns the value of the j-th primitive of the i-th |AO| at point $\textbf{r}
**without the coefficient**
Needs: Needs:

View File

@ -232,8 +232,10 @@ Providers
Second derivative matrix elements in the |AO| basis. Second derivative matrix elements in the |AO| basis.
:math:`{\tt ao\_deriv2\_x} = .. math::
\langle \chi_i(x,y,z) | \frac{\partial^2}{\partial x^2} |\chi_j (x,y,z) \rangle`
{\tt ao\_deriv2\_x} =
\langle \chi_i(x,y,z) | \frac{\partial^2}{\partial x^2} |\chi_j (x,y,z) \rangle
Needs: Needs:
@ -271,8 +273,10 @@ Providers
Second derivative matrix elements in the |AO| basis. Second derivative matrix elements in the |AO| basis.
:math:`{\tt ao\_deriv2\_x} = .. math::
\langle \chi_i(x,y,z) | \frac{\partial^2}{\partial x^2} |\chi_j (x,y,z) \rangle`
{\tt ao\_deriv2\_x} =
\langle \chi_i(x,y,z) | \frac{\partial^2}{\partial x^2} |\chi_j (x,y,z) \rangle
Needs: Needs:
@ -310,8 +314,10 @@ Providers
Second derivative matrix elements in the |AO| basis. Second derivative matrix elements in the |AO| basis.
:math:`{\tt ao\_deriv2\_x} = .. math::
\langle \chi_i(x,y,z) | \frac{\partial^2}{\partial x^2} |\chi_j (x,y,z) \rangle`
{\tt ao\_deriv2\_x} =
\langle \chi_i(x,y,z) | \frac{\partial^2}{\partial x^2} |\chi_j (x,y,z) \rangle
Needs: Needs:
@ -644,6 +650,7 @@ Providers
:math:`\langle \chi_i |\hat{T}| \chi_j \rangle` :math:`\langle \chi_i |\hat{T}| \chi_j \rangle`
Needs: Needs:
.. hlist:: .. hlist::
@ -1331,7 +1338,8 @@ Providers
power_A,power_B,C_center,n_pt_in,d,n_pt_out,mu_in) power_A,power_B,C_center,n_pt_in,d,n_pt_out,mu_in)
Returns the explicit polynomial in terms of the $t$ variable of the following polynomial: Returns the explicit polynomial in terms of the $t$ variable of the
following polynomial:
$I_{x1}(a_x, d_x,p,q) \times I_{x1}(a_y, d_y,p,q) \times I_{x1}(a_z, d_z,p,q)$. $I_{x1}(a_x, d_x,p,q) \times I_{x1}(a_y, d_y,p,q) \times I_{x1}(a_z, d_z,p,q)$.
@ -1355,7 +1363,8 @@ Providers
power_A,power_B,C_center,n_pt_in,d,n_pt_out,mu_in,p,p_inv,p_inv_2,p_new,P_center) power_A,power_B,C_center,n_pt_in,d,n_pt_out,mu_in,p,p_inv,p_inv_2,p_new,P_center)
Returns the explicit polynomial in terms of the $t$ variable of the following polynomial: Returns the explicit polynomial in terms of the $t$ variable of the
following polynomial:
$I_{x1}(a_x, d_x,p,q) \times I_{x1}(a_y, d_y,p,q) \times I_{x1}(a_z, d_z,p,q)$. $I_{x1}(a_x, d_x,p,q) \times I_{x1}(a_y, d_y,p,q) \times I_{x1}(a_z, d_z,p,q)$.
@ -1724,7 +1733,7 @@ Subroutines / functions
Subroutine that returns all integrals over $r$ of type Subroutine that returns all integrals over $r$ of type
$\frac{ \erf(\mu * |r-R_C|) }{ |r-R_C| }$ $\frac{ \erf(\mu * | r - R_C | ) }{ | r - R_C | }$
Needs: Needs:
@ -1812,8 +1821,12 @@ Subroutines / functions
Computes the following integral : Computes the following integral :
$\int dr (x-A_x)^a (x-B_x)^b \exp(-\alpha (x-A_x)^2 - \beta (x-B_x)^2 )
\frac{\erf(\mu |r-R_C|)}{|r-R_c|}$. .. math::
\int dr (x-A_x)^a (x-B_x)^b \exp(-\alpha (x-A_x)^2 - \beta (x-B_x)^2 )
\frac{\erf(\mu | r - R_C | )}{ | r - R_C | }$.
Calls: Calls:
@ -1834,7 +1847,7 @@ Subroutines / functions
Computes the following integral : Computes the following integral :
$\int_{-\infty}^{infty} dr \chi_i(r) \chi_j(r) \frac{\erf(\mu |r-R_C|)}{|r-R_C|}$. $\int_{-\infty}^{infty} dr \chi_i(r) \chi_j(r) \frac{\erf(\mu | r - R_C | )}{ | r - R_C | }$.
Needs: Needs:

View File

@ -587,11 +587,13 @@ Subroutines / functions
double precision function ERI_erf(alpha,beta,delta,gama,a_x,b_x,c_x,d_x,a_y,b_y,c_y,d_y,a_z,b_z,c_z,d_z) double precision function ERI_erf(alpha,beta,delta,gama,a_x,b_x,c_x,d_x,a_y,b_y,c_y,d_y,a_z,b_z,c_z,d_z)
ATOMIC PRIMTIVE two-electron integral between the 4 primitives :: Atomic primtive two-electron integral between the 4 primitives :
primitive_1 = x1**(a_x) y1**(a_y) z1**(a_z) exp(-alpha * r1**2)
primitive_2 = x1**(b_x) y1**(b_y) z1**(b_z) exp(- beta * r1**2) * primitive 1 : $x_1^{a_x} y_1^{a_y} z_1^{a_z} \exp(-\alpha * r1^2)$
primitive_3 = x2**(c_x) y2**(c_y) z2**(c_z) exp(-delta * r2**2) * primitive 2 : $x_1^{b_x} y_1^{b_y} z_1^{b_z} \exp(- \beta * r1^2)$
primitive_4 = x2**(d_x) y2**(d_y) z2**(d_z) exp(- gama * r2**2) * primitive 3 : $x_2^{c_x} y_2^{c_y} z_2^{c_z} \exp(-\delta * r2^2)$
* primitive 4 : $x_2^{d_x} y_2^{d_y} z_2^{d_z} \exp(-\gamma * r2^2)$
Needs: Needs:
@ -776,9 +778,11 @@ Subroutines / functions
subroutine integrale_new_erf(I_f,a_x,b_x,c_x,d_x,a_y,b_y,c_y,d_y,a_z,b_z,c_z,d_z,p,q,n_pt) subroutine integrale_new_erf(I_f,a_x,b_x,c_x,d_x,a_y,b_y,c_y,d_y,a_z,b_z,c_z,d_z,p,q,n_pt)
calculate the integral of the polynom :: Calculate the integral of the polynomial :
I_x1(a_x+b_x, c_x+d_x,p,q) * I_x1(a_y+b_y, c_y+d_y,p,q) * I_x1(a_z+b_z, c_z+d_z,p,q)
between ( 0 ; 1) $I_x1(a_x+b_x, c_x+d_x,p,q) \, I_x1(a_y+b_y, c_y+d_y,p,q) \, I_x1(a_z+b_z, c_z+d_z,p,q)$
between $( 0 ; 1)$
Needs: Needs:

View File

@ -362,7 +362,7 @@ Providers
recursive subroutine I_x1_pol_mult_a1(c,B_10,B_01,B_00,C_00,D_00,d,nd,n_pt_in) recursive subroutine I_x1_pol_mult_a1(c,B_10,B_01,B_00,C_00,D_00,d,nd,n_pt_in)
recursive function involved in the two-electron integral Recursive function involved in the two-electron integral
Called by: Called by:
@ -392,7 +392,7 @@ Providers
recursive subroutine I_x1_pol_mult_a2(c,B_10,B_01,B_00,C_00,D_00,d,nd,n_pt_in) recursive subroutine I_x1_pol_mult_a2(c,B_10,B_01,B_00,C_00,D_00,d,nd,n_pt_in)
recursive function involved in the two-electron integral Recursive function involved in the two-electron integral
Called by: Called by:
@ -422,7 +422,7 @@ Providers
recursive subroutine I_x1_pol_mult_recurs(a,c,B_10,B_01,B_00,C_00,D_00,d,nd,n_pt_in) recursive subroutine I_x1_pol_mult_recurs(a,c,B_10,B_01,B_00,C_00,D_00,d,nd,n_pt_in)
recursive function involved in the two-electron integral Recursive function involved in the two-electron integral
Called by: Called by:
@ -487,7 +487,7 @@ Providers
recursive subroutine I_x2_pol_mult(c,B_10,B_01,B_00,C_00,D_00,d,nd,dim) recursive subroutine I_x2_pol_mult(c,B_10,B_01,B_00,C_00,D_00,d,nd,dim)
recursive function involved in the two-electron integral Recursive function involved in the two-electron integral
Called by: Called by:
@ -1027,7 +1027,8 @@ Subroutines / functions
subroutine that returns the explicit polynom in term of the "t" subroutine that returns the explicit polynom in term of the "t"
variable of the following polynomw : variable of the following polynomw :
I_x1(a_x, d_x,p,q) * I_x1(a_y, d_y,p,q) * I_x1(a_z, d_z,p,q)
$I_{x_1}(a_x,d_x,p,q) \, I_{x_1}(a_y,d_y,p,q) \ I_{x_1}(a_z,d_z,p,q)$
Called by: Called by:
@ -1055,7 +1056,7 @@ Subroutines / functions
subroutine I_x1_pol_mult(a,c,B_10,B_01,B_00,C_00,D_00,d,nd,n_pt_in) subroutine I_x1_pol_mult(a,c,B_10,B_01,B_00,C_00,D_00,d,nd,n_pt_in)
recursive function involved in the two-electron integral Recursive function involved in the two-electron integral
Called by: Called by:
@ -1119,9 +1120,10 @@ Subroutines / functions
subroutine integrale_new(I_f,a_x,b_x,c_x,d_x,a_y,b_y,c_y,d_y,a_z,b_z,c_z,d_z,p,q,n_pt) subroutine integrale_new(I_f,a_x,b_x,c_x,d_x,a_y,b_y,c_y,d_y,a_z,b_z,c_z,d_z,p,q,n_pt)
calculate the integral of the polynom :: Calculates the integral of the polynomial :
I_x1(a_x+b_x, c_x+d_x,p,q) * I_x1(a_y+b_y, c_y+d_y,p,q) * I_x1(a_z+b_z, c_z+d_z,p,q)
between ( 0 ; 1) $I_{x_1}(a_x+b_x,c_x+d_x,p,q) \, I_{x_1}(a_y+b_y,c_y+d_y,p,q) \, I_{x_1}(a_z+b_z,c_z+d_z,p,q)$
in $( 0 ; 1)$
Needs: Needs:
@ -1186,8 +1188,9 @@ Subroutines / functions
Returns the upper boundary of the degree of the polynomial involved in the Returns the upper boundary of the degree of the polynomial involved in the
bielctronic integral : two-electron integral :
Ix(a_x,b_x,c_x,d_x) * Iy(a_y,b_y,c_y,d_y) * Iz(a_z,b_z,c_z,d_z)
$I_x(a_x,b_x,c_x,d_x) \, I_y(a_y,b_y,c_y,d_y) \, I_z(a_z,b_z,c_z,d_z)$
.. c:function:: push_integrals: .. c:function:: push_integrals:

View File

@ -10,21 +10,22 @@ aux_quantities
This module contains some global variables (such as densities and energies) This module contains some global variables (such as densities and energies)
which are stored in the EZFIO folder in a different place than determinants. which are stored in the |EZFIO| directory in a different place than determinants.
This is used in practice to store density matrices which can be obtained from This is used in practice to store density matrices which can be obtained from
any methods, as long as they are stored in the same MO basis which is used for any method, as long as they are stored in the same |MO| basis which is used for
the calculations. In |RSDFT| calculations, this can be done to perform damping the calculations. In |RSDFT| calculations, this can be done to perform damping
on the density in order to speed up convergence. on the density in order to speed up the convergence.
The main providers of that module are: The main providers of that module are:
* `data_one_e_dm_alpha_mo` and `data_one_e_dm_beta_mo` which are the * :c:data:`data_one_e_dm_alpha_mo` and :c:data:`data_one_e_dm_beta_mo` which
one-body alpha and beta densities which are necessary read from the EZFIO are the one-body alpha and beta densities which are necessary read from the
folder. |EZFIO| directory.
Thanks to these providers you can use any density matrix that does not Thanks to these providers you can use any density matrix that does not
necessary corresponds to that of the current wave function. necessarily corresponds to that of the current wave function.

View File

@ -49,7 +49,7 @@ By default, the program will stop when more than one million determinants have
been selected, or when the |PT2| energy is below :math:`10^{-4}`. been selected, or when the |PT2| energy is below :math:`10^{-4}`.
The variational and |PT2| energies of the iterations are stored in the The variational and |PT2| energies of the iterations are stored in the
|EZFIO| database, in the :ref:`iterations` module. |EZFIO| database, in the :ref:`module_iterations` module.
@ -180,55 +180,6 @@ Providers
.. c:function:: pt2_collector:
File : :file:`cipsi/pt2_stoch_routines.irp.f`
.. code:: fortran
subroutine pt2_collector(zmq_socket_pull, E, relative_error, pt2, error, &
variance, norm, b, N_)
Needs:
.. hlist::
:columns: 3
* :c:data:`pt2_j`
* :c:data:`pt2_stoch_istate`
* :c:data:`n_states`
* :c:data:`pt2_f`
* :c:data:`pt2_w`
* :c:data:`n_det_generators`
* :c:data:`pt2_n_teeth`
* :c:data:`pt2_u`
Called by:
.. hlist::
:columns: 3
* :c:func:`zmq_pt2`
Calls:
.. hlist::
:columns: 3
* :c:func:`add_to_selection_buffer`
* :c:func:`check_mem`
* :c:func:`create_selection_buffer`
* :c:func:`delete_selection_buffer`
* :c:func:`end_zmq_to_qp_run_socket`
* :c:func:`pull_pt2_results`
* :c:func:`sleep`
* :c:func:`sort_selection_buffer`
* :c:func:`wall_time`
.. c:var:: pt2_cw .. c:var:: pt2_cw
@ -311,7 +262,6 @@ Providers
* :c:data:`n_core_orb` * :c:data:`n_core_orb`
* :c:data:`n_det_generators` * :c:data:`n_det_generators`
* :c:data:`n_det_selectors` * :c:data:`n_det_selectors`
* :c:data:`n_states`
* :c:data:`psi_det_sorted_gen` * :c:data:`psi_det_sorted_gen`
@ -455,7 +405,6 @@ Providers
* :c:data:`n_core_orb` * :c:data:`n_core_orb`
* :c:data:`n_det_generators` * :c:data:`n_det_generators`
* :c:data:`n_det_selectors` * :c:data:`n_det_selectors`
* :c:data:`n_states`
* :c:data:`psi_det_sorted_gen` * :c:data:`psi_det_sorted_gen`
@ -1164,6 +1113,54 @@ Subroutines / functions
* :c:func:`run_slave_cipsi` * :c:func:`run_slave_cipsi`
.. c:function:: pt2_collector:
File : :file:`cipsi/pt2_stoch_routines.irp.f`
.. code:: fortran
subroutine pt2_collector(zmq_socket_pull, E, relative_error, pt2, error, variance, norm, b, N_)
Needs:
.. hlist::
:columns: 3
* :c:data:`pt2_j`
* :c:data:`pt2_stoch_istate`
* :c:data:`n_states`
* :c:data:`pt2_f`
* :c:data:`pt2_w`
* :c:data:`n_det_generators`
* :c:data:`pt2_n_teeth`
* :c:data:`pt2_u`
Called by:
.. hlist::
:columns: 3
* :c:func:`zmq_pt2`
Calls:
.. hlist::
:columns: 3
* :c:func:`add_to_selection_buffer`
* :c:func:`check_mem`
* :c:func:`create_selection_buffer`
* :c:func:`delete_selection_buffer`
* :c:func:`end_zmq_to_qp_run_socket`
* :c:func:`pull_pt2_results`
* :c:func:`sleep`
* :c:func:`sort_selection_buffer`
* :c:func:`wall_time`
.. c:function:: pt2_find_sample: .. c:function:: pt2_find_sample:
@ -1633,21 +1630,31 @@ Subroutines / functions
.. hlist:: .. hlist::
:columns: 3 :columns: 3
* :c:data:`pt2_stoch_istate`
* :c:data:`psi_det`
* :c:data:`zmq_state`
* :c:data:`psi_coef` * :c:data:`psi_coef`
* :c:data:`mpi_rank` * :c:data:`mpi_rank`
* :c:data:`zmq_state`
* :c:data:`state_average_weight`
* :c:data:`mpi_master` * :c:data:`mpi_master`
* :c:data:`pt2_stoch_istate`
* :c:data:`n_states`
* :c:data:`n_det` * :c:data:`n_det`
* :c:data:`pt2_e0_denominator`
* :c:data:`n_det_selectors`
* :c:data:`n_det_generators`
* :c:data:`psi_det`
* :c:data:`n_states_diag`
* :c:data:`zmq_context` * :c:data:`zmq_context`
* :c:data:`n_det_selectors`
* :c:data:`psi_occ_pattern_hii`
* :c:data:`state_average_weight`
* :c:data:`mo_num`
* :c:data:`nthreads_pt2`
* :c:data:`elec_alpha_num`
* :c:data:`pt2_e0_denominator`
* :c:data:`qp_max_mem`
* :c:data:`n_states_diag`
* :c:data:`s2_eig`
* :c:data:`threshold_generators` * :c:data:`threshold_generators`
* :c:data:`det_to_occ_pattern`
* :c:data:`n_states`
* :c:data:`pt2_f`
* :c:data:`n_det_generators`
* :c:data:`n_int`
* :c:data:`psi_det_hii`
Called by: Called by:
@ -1661,9 +1668,11 @@ Subroutines / functions
.. hlist:: .. hlist::
:columns: 3 :columns: 3
* :c:func:`check_mem`
* :c:func:`davidson_slave_tcp` * :c:func:`davidson_slave_tcp`
* :c:func:`mpi_print` * :c:func:`mpi_print`
* :c:func:`omp_set_nested` * :c:func:`omp_set_nested`
* :c:func:`resident_memory`
* :c:func:`run_pt2_slave` * :c:func:`run_pt2_slave`
* :c:func:`run_selection_slave` * :c:func:`run_selection_slave`
* :c:func:`sleep` * :c:func:`sleep`
@ -1832,13 +1841,12 @@ Subroutines / functions
* :c:data:`n_states` * :c:data:`n_states`
* :c:data:`n_det` * :c:data:`n_det`
* :c:data:`psi_bilinear_matrix_transp_values` * :c:data:`psi_bilinear_matrix_transp_values`
* :c:data:`elec_alpha_num` * :c:data:`psi_bilinear_matrix_values`
* :c:data:`n_det_selectors` * :c:data:`n_det_selectors`
* :c:data:`psi_bilinear_matrix_transp_values` * :c:data:`psi_bilinear_matrix_transp_values`
* :c:data:`psi_bilinear_matrix_values` * :c:data:`psi_bilinear_matrix_values`
* :c:data:`n_int` * :c:data:`n_int`
* :c:data:`psi_det_generators` * :c:data:`psi_det_generators`
* :c:data:`psi_bilinear_matrix_values`
* :c:data:`psi_det_alpha_unique` * :c:data:`psi_det_alpha_unique`
* :c:data:`psi_det_sorted` * :c:data:`psi_det_sorted`
* :c:data:`psi_det_sorted` * :c:data:`psi_det_sorted`
@ -1859,7 +1867,6 @@ Subroutines / functions
* :c:func:`apply_hole` * :c:func:`apply_hole`
* :c:func:`bitstring_to_list_ab` * :c:func:`bitstring_to_list_ab`
* :c:func:`check_mem`
* :c:func:`fill_buffer_double` * :c:func:`fill_buffer_double`
* :c:func:`get_excitation_degree_spin` * :c:func:`get_excitation_degree_spin`
* :c:func:`isort` * :c:func:`isort`
@ -2103,14 +2110,15 @@ Subroutines / functions
* :c:data:`pt2_stoch_istate` * :c:data:`pt2_stoch_istate`
* :c:data:`psi_selectors` * :c:data:`psi_selectors`
* :c:data:`psi_bilinear_matrix_values` * :c:data:`psi_bilinear_matrix_values`
* :c:data:`psi_det_alpha_unique` * :c:data:`psi_occ_pattern_hii`
* :c:data:`pt2_e0_denominator` * :c:data:`pt2_e0_denominator`
* :c:data:`pt2_n_teeth` * :c:data:`pt2_n_teeth`
* :c:data:`psi_selectors_coef_transp` * :c:data:`psi_selectors_coef_transp`
* :c:data:`n_det` * :c:data:`n_det`
* :c:data:`mo_two_e_integrals_in_map`
* :c:data:`s2_eig` * :c:data:`s2_eig`
* :c:data:`pt2_j` * :c:data:`pt2_j`
* :c:data:`mo_two_e_integrals_in_map` * :c:data:`psi_det_alpha_unique`
* :c:data:`psi_bilinear_matrix_transp_values` * :c:data:`psi_bilinear_matrix_transp_values`
* :c:data:`state_average_weight` * :c:data:`state_average_weight`
* :c:data:`mo_num` * :c:data:`mo_num`
@ -2119,16 +2127,18 @@ Subroutines / functions
* :c:data:`mo_one_e_integrals` * :c:data:`mo_one_e_integrals`
* :c:data:`elec_alpha_num` * :c:data:`elec_alpha_num`
* :c:data:`nproc` * :c:data:`nproc`
* :c:data:`qp_max_mem`
* :c:data:`psi_bilinear_matrix_columns_loc` * :c:data:`psi_bilinear_matrix_columns_loc`
* :c:data:`threshold_generators` * :c:data:`threshold_generators`
* :c:data:`psi_det_beta_unique` * :c:data:`psi_det_beta_unique`
* :c:data:`qp_max_mem` * :c:data:`det_to_occ_pattern`
* :c:data:`psi_bilinear_matrix_transp_rows_loc` * :c:data:`psi_bilinear_matrix_transp_rows_loc`
* :c:data:`n_states` * :c:data:`n_states`
* :c:data:`pt2_f` * :c:data:`pt2_f`
* :c:data:`n_det_generators` * :c:data:`n_det_generators`
* :c:data:`psi_bilinear_matrix_transp_values` * :c:data:`psi_bilinear_matrix_transp_values`
* :c:data:`n_int` * :c:data:`n_int`
* :c:data:`psi_det_hii`
* :c:data:`pt2_j` * :c:data:`pt2_j`
* :c:data:`psi_det_sorted` * :c:data:`psi_det_sorted`
* :c:data:`pt2_w` * :c:data:`pt2_w`

View File

@ -8,34 +8,39 @@
cis cis
=== ===
This module contains a CIS program. This module contains a |CIS| program.
The user point of view The user point of view
---------------------- ----------------------
The :command:`cis` program performs the CI of the ROHF-like + all single excitations on top of it. The :ref:`cis` program performs the CI to obtain the ROHF reference + all
This program can be very useful to : single excitations on top of it. This program can be very useful to:
* **Ground state calculations**: generate a guess for the ground state wave function if one is not sure that the :c:func:`scf` program gave the lowest SCF solution. In combination with :c:func:`save_natorb` it can produce new |MOs| in order to reperform an :c:func:`scf` optimization. * **Ground state calculations**: generate a guess for the ground state wave
function if one is not sure that the :ref:`scf` program gave the lowest |SCF|
solution. In combination with :ref:`save_natorb` it can produce new |MOs| in
order to reperform an :ref:`scf` optimization.
* **Excited states calculations**: generate guess for all the :option:`determinants n_states` wave functions, that will be used by the :c:func:`fci` program. * **Excited states calculations**: generate guesses for all the
:option:`determinants n_states` wave functions, that will be used by the
:ref:`fci` program.
The main keywords/options to be used are: The main keywords/options to be used are:
* :option:`determinants n_states` : number of states to consider for the |CIS| calculation * :option:`determinants n_states`: number of states to consider for the |CIS| calculation
* :option:`determinants s2_eig` : force all states to have the desired value of :math:`S^2` * :option:`determinants s2_eig`: force all states to have the desired value of |S^2|
* :option:`determinants expected_s2` : desired value of :math:`S^2` * :option:`determinants expected_s2`: desired value of |S^2|
The programmer point of view The programmer's point of view
---------------------------- ------------------------------
This module have been built by setting the following rules: This module was built by setting the following rules:
* The only generator determinant is the Hartree-Fock (single-reference method) * The only generator determinant is the Hartree-Fock (single-reference method)
* All generated singly excited determinants are included in the wave function (no perturbative * All generated singly excited determinants are included in the wave function (no perturbative

View File

@ -9,15 +9,22 @@ davidson
======== ========
Abstract module for Davidson's diagonalization. Abstract module for Davidson's diagonalization.
It contains everything required for the Davidson algorithm, dressed or not. If It contains everything required for the Davidson algorithm, dressed or
a dressing is used, the dressing column should be defined and the not. If a dressing is used, the dressing column should be defined and
:ref:`davidson_dressed` module should be used. If no dressing is required, the :ref:`module_davidson_dressed` module should be used. If no dressing
the :ref:`davidson` module should be used, and it has a default zero dressing vector. is required, the :ref:`module_davidson` module should be used, and it
has a default zero dressing vector.
The important providers for that module are: The important providers for that module are:
# `psi_energy` which is the expectation value over the wave function (`psi_det`, `psi_coef`) of the Hamiltonian, dressed or not. It uses the general subroutine `u_0_H_u_0`. #. :c:data:`psi_energy` which is the expectation value over the wave
# `psi_energy_two_e` which is the expectation value over the wave function (`psi_det`, `psi_coef`) of the standard two-electrons coulomb operator. It uses the general routine `u_0_H_u_0_two_e`. function (:c:data:`psi_det`, :c:data:`psi_coef`) of the Hamiltonian,
dressed or not. It uses the general subroutine :c:func:`u_0_H_u_0`.
#. :c:data:`psi_energy_two_e` which is the expectation value over the
wave function (:c:data:`psi_det`, :c:data:`psi_coef`) of the standard
two-electron Coulomb operator. It uses the general routine
:c:func:`u_0_H_u_0_two_e`.
@ -40,7 +47,7 @@ EZFIO parameters
Number of micro-iterations before re-contracting Number of micro-iterations before re-contracting
Default: 8 Default: 15
.. option:: state_following .. option:: state_following
@ -585,7 +592,6 @@ Subroutines / functions
* :c:data:`psi_det_beta_unique` * :c:data:`psi_det_beta_unique`
* :c:data:`only_expected_s2` * :c:data:`only_expected_s2`
* :c:data:`distributed_davidson` * :c:data:`distributed_davidson`
* :c:data:`n_states`
* :c:data:`n_int` * :c:data:`n_int`
Called by: Called by:
@ -626,7 +632,6 @@ Subroutines / functions
.. hlist:: .. hlist::
:columns: 3 :columns: 3
* :c:data:`n_states_diag`
* :c:data:`nthreads_davidson` * :c:data:`nthreads_davidson`
@ -682,7 +687,6 @@ Subroutines / functions
.. hlist:: .. hlist::
:columns: 3 :columns: 3
* :c:data:`n_states_diag`
* :c:data:`nthreads_davidson` * :c:data:`nthreads_davidson`
@ -696,7 +700,7 @@ Subroutines / functions
subroutine davidson_pull_results(zmq_socket_pull, v_t, s_t, imin, imax, task_id) subroutine davidson_pull_results(zmq_socket_pull, v_t, s_t, imin, imax, task_id)
Pull the results of $H|U \rangle$ on the master. Pull the results of $H | U \rangle$ on the master.
Needs: Needs:
@ -724,7 +728,7 @@ Subroutines / functions
subroutine davidson_push_results(zmq_socket_push, v_t, s_t, imin, imax, task_id) subroutine davidson_push_results(zmq_socket_push, v_t, s_t, imin, imax, task_id)
Push the results of $H|U \rangle$ from a worker to the master. Push the results of $H | U \rangle$ from a worker to the master.
Needs: Needs:
@ -850,6 +854,7 @@ Subroutines / functions
:columns: 3 :columns: 3
* :c:data:`psi_det_beta_unique` * :c:data:`psi_det_beta_unique`
* :c:data:`mpi_rank`
* :c:data:`psi_bilinear_matrix_order_transp_reverse` * :c:data:`psi_bilinear_matrix_order_transp_reverse`
* :c:data:`psi_det_alpha_unique` * :c:data:`psi_det_alpha_unique`
* :c:data:`mpi_initialized` * :c:data:`mpi_initialized`
@ -858,6 +863,7 @@ Subroutines / functions
* :c:data:`psi_bilinear_matrix_values` * :c:data:`psi_bilinear_matrix_values`
* :c:data:`nproc` * :c:data:`nproc`
* :c:data:`ref_bitmask_energy` * :c:data:`ref_bitmask_energy`
* :c:data:`n_states_diag`
* :c:data:`psi_bilinear_matrix_columns_loc` * :c:data:`psi_bilinear_matrix_columns_loc`
Called by: Called by:
@ -874,7 +880,6 @@ Subroutines / functions
* :c:func:`davidson_push_results` * :c:func:`davidson_push_results`
* :c:func:`h_s2_u_0_nstates_openmp_work` * :c:func:`h_s2_u_0_nstates_openmp_work`
* :c:func:`sleep`
.. c:function:: diagonalize_ci: .. c:function:: diagonalize_ci:
@ -934,7 +939,7 @@ Subroutines / functions
subroutine H_S2_u_0_nstates_openmp(v_0,s_0,u_0,N_st,sze) subroutine H_S2_u_0_nstates_openmp(v_0,s_0,u_0,N_st,sze)
Computes $v_0 = H|u_0\rangle$ and $s_0 = S^2 |u_0\rangle$. Computes $v_0 = H | u_0\rangle$ and $s_0 = S^2 | u_0\rangle$.
Assumes that the determinants are in psi_det Assumes that the determinants are in psi_det
@ -977,7 +982,7 @@ Subroutines / functions
subroutine H_S2_u_0_nstates_openmp_work(v_t,s_t,u_t,N_st,sze,istart,iend,ishift,istep) subroutine H_S2_u_0_nstates_openmp_work(v_t,s_t,u_t,N_st,sze,istart,iend,ishift,istep)
Computes $v_t = H|u_t\rangle$ and $s_t = S^2 |u_t\rangle$ Computes $v_t = H | u_t\rangle$ and $s_t = S^2 | u_t\rangle$
Default should be 1,N_det,0,1 Default should be 1,N_det,0,1
@ -1020,7 +1025,7 @@ Subroutines / functions
subroutine H_S2_u_0_nstates_openmp_work_1(v_t,s_t,u_t,N_st,sze,istart,iend,ishift,istep) subroutine H_S2_u_0_nstates_openmp_work_1(v_t,s_t,u_t,N_st,sze,istart,iend,ishift,istep)
Computes $v_t = H|u_t angle$ and $s_t = S^2 |u_t angle$ Computes $v_t = H | u_t \rangle$ and $s_t = S^2 | u_t\rangle$
Default should be 1,N_det,0,1 Default should be 1,N_det,0,1
@ -1072,7 +1077,7 @@ Subroutines / functions
subroutine H_S2_u_0_nstates_openmp_work_2(v_t,s_t,u_t,N_st,sze,istart,iend,ishift,istep) subroutine H_S2_u_0_nstates_openmp_work_2(v_t,s_t,u_t,N_st,sze,istart,iend,ishift,istep)
Computes $v_t = H|u_t angle$ and $s_t = S^2 |u_t angle$ Computes $v_t = H | u_t \rangle$ and $s_t = S^2 | u_t\rangle$
Default should be 1,N_det,0,1 Default should be 1,N_det,0,1
@ -1124,7 +1129,7 @@ Subroutines / functions
subroutine H_S2_u_0_nstates_openmp_work_3(v_t,s_t,u_t,N_st,sze,istart,iend,ishift,istep) subroutine H_S2_u_0_nstates_openmp_work_3(v_t,s_t,u_t,N_st,sze,istart,iend,ishift,istep)
Computes $v_t = H|u_t angle$ and $s_t = S^2 |u_t angle$ Computes $v_t = H | u_t \rangle$ and $s_t = S^2 | u_t\rangle$
Default should be 1,N_det,0,1 Default should be 1,N_det,0,1
@ -1176,7 +1181,7 @@ Subroutines / functions
subroutine H_S2_u_0_nstates_openmp_work_4(v_t,s_t,u_t,N_st,sze,istart,iend,ishift,istep) subroutine H_S2_u_0_nstates_openmp_work_4(v_t,s_t,u_t,N_st,sze,istart,iend,ishift,istep)
Computes $v_t = H|u_t angle$ and $s_t = S^2 |u_t angle$ Computes $v_t = H | u_t \rangle$ and $s_t = S^2 | u_t\rangle$
Default should be 1,N_det,0,1 Default should be 1,N_det,0,1
@ -1228,7 +1233,7 @@ Subroutines / functions
subroutine H_S2_u_0_nstates_openmp_work_N_int(v_t,s_t,u_t,N_st,sze,istart,iend,ishift,istep) subroutine H_S2_u_0_nstates_openmp_work_N_int(v_t,s_t,u_t,N_st,sze,istart,iend,ishift,istep)
Computes $v_t = H|u_t angle$ and $s_t = S^2 |u_t angle$ Computes $v_t = H | u_t \rangle$ and $s_t = S^2 | u_t\rangle$
Default should be 1,N_det,0,1 Default should be 1,N_det,0,1
@ -1280,13 +1285,13 @@ Subroutines / functions
subroutine H_S2_u_0_nstates_zmq(v_0,s_0,u_0,N_st,sze) subroutine H_S2_u_0_nstates_zmq(v_0,s_0,u_0,N_st,sze)
Computes $v_0 = H|u_0\rangle$ and $s_0 = S^2 |u_0\rangle$ Computes $v_0 = H | u_0\rangle$ and $s_0 = S^2 | u_0\rangle$
n : number of determinants n : number of determinants
H_jj : array of $\langle j|H|j \rangle$ H_jj : array of $\langle j | H | j \rangle$
S2_jj : array of $\langle j|S^2|j \rangle$ S2_jj : array of $\langle j | S^2 | j \rangle$
Needs: Needs:
@ -1303,7 +1308,6 @@ Subroutines / functions
* :c:data:`psi_bilinear_matrix_values` * :c:data:`psi_bilinear_matrix_values`
* :c:data:`nproc` * :c:data:`nproc`
* :c:data:`ref_bitmask_energy` * :c:data:`ref_bitmask_energy`
* :c:data:`n_states_diag`
* :c:data:`psi_bilinear_matrix_columns_loc` * :c:data:`psi_bilinear_matrix_columns_loc`
Called by: Called by:
@ -1327,13 +1331,6 @@ Subroutines / functions
* :c:func:`new_parallel_job` * :c:func:`new_parallel_job`
* :c:func:`omp_set_nested` * :c:func:`omp_set_nested`
Touches:
.. hlist::
:columns: 3
* :c:data:`n_states_diag`
.. c:function:: h_s2_u_0_two_e_nstates_openmp: .. c:function:: h_s2_u_0_two_e_nstates_openmp:
@ -1345,7 +1342,7 @@ Subroutines / functions
subroutine H_S2_u_0_two_e_nstates_openmp(v_0,s_0,u_0,N_st,sze) subroutine H_S2_u_0_two_e_nstates_openmp(v_0,s_0,u_0,N_st,sze)
Computes $v_0 = H|u_0\rangle$ and $s_0 = S^2 |u_0\rangle$ Computes $v_0 = H | u_0\rangle$ and $s_0 = S^2 | u_0\rangle$
Assumes that the determinants are in psi_det Assumes that the determinants are in psi_det
@ -1387,7 +1384,7 @@ Subroutines / functions
subroutine H_S2_u_0_two_e_nstates_openmp_work(v_t,s_t,u_t,N_st,sze,istart,iend,ishift,istep) subroutine H_S2_u_0_two_e_nstates_openmp_work(v_t,s_t,u_t,N_st,sze,istart,iend,ishift,istep)
Computes $v_t = H|u_t\rangle$ and $s_t = S^2 |u_t\rangle$ Computes $v_t = H | u_t\rangle$ and $s_t = S^2 | u_t\rangle$
Default should be 1,N_det,0,1 Default should be 1,N_det,0,1
@ -1429,7 +1426,7 @@ Subroutines / functions
subroutine H_S2_u_0_two_e_nstates_openmp_work_1(v_t,s_t,u_t,N_st,sze,istart,iend,ishift,istep) subroutine H_S2_u_0_two_e_nstates_openmp_work_1(v_t,s_t,u_t,N_st,sze,istart,iend,ishift,istep)
Computes $v_t = H|u_t angle$ and $s_t = S^2 |u_t angle$ Computes $v_t = H | u_t \rangle$ and $s_t = S^2 | u_t \rangle$
Default should be 1,N_det,0,1 Default should be 1,N_det,0,1
@ -1479,7 +1476,7 @@ Subroutines / functions
subroutine H_S2_u_0_two_e_nstates_openmp_work_2(v_t,s_t,u_t,N_st,sze,istart,iend,ishift,istep) subroutine H_S2_u_0_two_e_nstates_openmp_work_2(v_t,s_t,u_t,N_st,sze,istart,iend,ishift,istep)
Computes $v_t = H|u_t angle$ and $s_t = S^2 |u_t angle$ Computes $v_t = H | u_t \rangle$ and $s_t = S^2 | u_t \rangle$
Default should be 1,N_det,0,1 Default should be 1,N_det,0,1
@ -1529,7 +1526,7 @@ Subroutines / functions
subroutine H_S2_u_0_two_e_nstates_openmp_work_3(v_t,s_t,u_t,N_st,sze,istart,iend,ishift,istep) subroutine H_S2_u_0_two_e_nstates_openmp_work_3(v_t,s_t,u_t,N_st,sze,istart,iend,ishift,istep)
Computes $v_t = H|u_t angle$ and $s_t = S^2 |u_t angle$ Computes $v_t = H | u_t \rangle$ and $s_t = S^2 | u_t \rangle$
Default should be 1,N_det,0,1 Default should be 1,N_det,0,1
@ -1579,7 +1576,7 @@ Subroutines / functions
subroutine H_S2_u_0_two_e_nstates_openmp_work_4(v_t,s_t,u_t,N_st,sze,istart,iend,ishift,istep) subroutine H_S2_u_0_two_e_nstates_openmp_work_4(v_t,s_t,u_t,N_st,sze,istart,iend,ishift,istep)
Computes $v_t = H|u_t angle$ and $s_t = S^2 |u_t angle$ Computes $v_t = H | u_t \rangle$ and $s_t = S^2 | u_t \rangle$
Default should be 1,N_det,0,1 Default should be 1,N_det,0,1
@ -1629,7 +1626,7 @@ Subroutines / functions
subroutine H_S2_u_0_two_e_nstates_openmp_work_N_int(v_t,s_t,u_t,N_st,sze,istart,iend,ishift,istep) subroutine H_S2_u_0_two_e_nstates_openmp_work_N_int(v_t,s_t,u_t,N_st,sze,istart,iend,ishift,istep)
Computes $v_t = H|u_t angle$ and $s_t = S^2 |u_t angle$ Computes $v_t = H | u_t \rangle$ and $s_t = S^2 | u_t \rangle$
Default should be 1,N_det,0,1 Default should be 1,N_det,0,1
@ -1679,9 +1676,9 @@ Subroutines / functions
subroutine u_0_H_u_0(e_0,s_0,u_0,n,keys_tmp,Nint,N_st,sze) subroutine u_0_H_u_0(e_0,s_0,u_0,n,keys_tmp,Nint,N_st,sze)
Computes $E_0 = \frac{\langle u_0|H|u_0 \rangle}{\langle u_0|u_0 \rangle}$ Computes $E_0 = \frac{\langle u_0 | H | u_0 \rangle}{\langle u_0 | u_0 \rangle}$
and $S_0 = \frac{\langle u_0|S^2|u_0 \rangle}{\langle u_0|u_0 \rangle}$ and $S_0 = \frac{\langle u_0 | S^2 | u_0 \rangle}{\langle u_0 | u_0 \rangle}$
n : number of determinants n : number of determinants
@ -1692,7 +1689,6 @@ Subroutines / functions
:columns: 3 :columns: 3
* :c:data:`n_states_diag` * :c:data:`n_states_diag`
* :c:data:`n_states`
* :c:data:`distributed_davidson` * :c:data:`distributed_davidson`
Called by: Called by:
@ -1710,13 +1706,6 @@ Subroutines / functions
* :c:func:`h_s2_u_0_nstates_openmp` * :c:func:`h_s2_u_0_nstates_openmp`
* :c:func:`h_s2_u_0_nstates_zmq` * :c:func:`h_s2_u_0_nstates_zmq`
Touches:
.. hlist::
:columns: 3
* :c:data:`n_states_diag`
.. c:function:: u_0_h_u_0_two_e: .. c:function:: u_0_h_u_0_two_e:
@ -1728,7 +1717,7 @@ Subroutines / functions
subroutine u_0_H_u_0_two_e(e_0,u_0,n,keys_tmp,Nint,N_st,sze) subroutine u_0_H_u_0_two_e(e_0,u_0,n,keys_tmp,Nint,N_st,sze)
Computes $E_0 = \frac{ \langle u_0|H|u_0\rangle}{\langle u_0|u_0 \rangle}$. Computes $E_0 = \frac{ \langle u_0 | H | u_0\rangle}{\langle u_0 | u_0 \rangle}$.
n : number of determinants n : number of determinants

View File

@ -9,12 +9,16 @@ density_for_dft
=============== ===============
This module defines the *provider* of the density used for the DFT related calculations. This module defines the *provider* of the density used for the |DFT| related
This definition is done through the keyword :option:`density_for_dft density_for_dft`. calculations. This definition is done through the keyword
The density can be: :option:`density_for_dft density_for_dft`. The density can be:
* WFT : the density is computed with a potentially multi determinant wave function (see variables `psi_det` and `psi_det`)# input_density : the density is set to a density previously stored in the |EZFIO| folder (see ``aux_quantities``) * `WFT`: the density is computed with a potentially multi determinant wave
* damping_rs_dft : the density is damped between the input_density and the WFT density, with a damping factor of :option:`density_for_dft damping_for_rs_dft` function (see variables `psi_det` and `psi_det`)# input_density: the density
is set to a density previously stored in the |EZFIO| directory (see
``aux_quantities``)
* `damping_rs_dft`: the density is damped between the input_density and the WFT
density, with a damping factor of :option:`density_for_dft damping_for_rs_dft`

View File

@ -13,15 +13,15 @@ Contains everything for the computation of the Hamiltonian matrix elements in th
The main providers for this module are: The main providers for this module are:
* :option:`determinants n_states`: number of states to be computed * :option:`determinants n_states`: number of states to be computed
* `psi_det`: list of determinants in the wave function used in many routines/providers of the |QP|. * :c:data:`psi_det`: list of determinants in the wave function used in many routines/providers of the |QP|.
* `psi_coef`: list of coefficients, for all :option:`determinants n_states` states, and all determinants. * :c:data:`psi_coef`: list of coefficients, for all :option:`determinants n_states` states, and all determinants.
The main routines for this module are: The main routines for this module are:
* `i_H_j`: computes the Hamiltonian matrix element between two arbitrary Slater determinants. * :c:func:`i_H_j`: computes the Hamiltonian matrix element between two arbitrary Slater determinants.
* `i_H_j_s2`: computes the Hamiltonian and (:math:`S^2`) matrix element between two arbitrary Slater determinants. * :c:func:`i_H_j_s2`: computes the Hamiltonian and (|S^2|) matrix element between two arbitrary Slater determinants.
* `i_H_j_verbose`: returns the decomposition in terms of one- and two-body components of the Hamiltonian matrix elements between two arbitrary Slater determinants. Also return the fermionic phase factor. * :c:func:`i_H_j_verbose`: returns the decomposition in terms of one- and two-body components of the Hamiltonian matrix elements between two arbitrary Slater determinants. Also return the fermionic phase factor.
* `i_H_psi`: computes the Hamiltonian matrix element between an arbitrary Slater determinant and a wave function composed of a sum of arbitrary Slater determinants. * :c:func:`i_H_psi`: computes the Hamiltonian matrix element between an arbitrary Slater determinant and a wave function composed of a sum of arbitrary Slater determinants.
For an example of how to use these routines and providers, take a look at :file:`example.irp.f`. For an example of how to use these routines and providers, take a look at :file:`example.irp.f`.
@ -81,12 +81,12 @@ EZFIO parameters
.. option:: n_int .. option:: n_int
Number of integers required to represent bitstrings (set in module :ref:`bitmask`) Number of integers required to represent bitstrings (set in module :ref:`module_bitmask`)
.. option:: bit_kind .. option:: bit_kind
(set in module :ref:`bitmask`) (set in module :ref:`module_bitmask`)
.. option:: mo_label .. option:: mo_label

View File

@ -769,13 +769,19 @@ Subroutines / functions
subroutine density_and_grad_alpha_beta_and_all_aos_and_grad_aos_at_r(r,dm_a,dm_b, grad_dm_a, grad_dm_b, aos_array, grad_aos_array) subroutine density_and_grad_alpha_beta_and_all_aos_and_grad_aos_at_r(r,dm_a,dm_b, grad_dm_a, grad_dm_b, aos_array, grad_aos_array)
input : r(1) ==> r(1) = x, r(2) = y, r(3) = z input:
output : dm_a = alpha density evaluated at r
: dm_b = beta density evaluated at r * r(1) ==> r(1) = x, r(2) = y, r(3) = z
: aos_array(i) = ao(i) evaluated at r
: grad_dm_a(1) = X gradient of the alpha density evaluated in r output:
: grad_dm_a(1) = X gradient of the beta density evaluated in r
: grad_aos_array(1) = X gradient of the aos(i) evaluated at r * dm_a = alpha density evaluated at r
* dm_b = beta density evaluated at r
* aos_array(i) = ao(i) evaluated at r
* grad_dm_a(1) = X gradient of the alpha density evaluated in r
* grad_dm_a(1) = X gradient of the beta density evaluated in r
* grad_aos_array(1) = X gradient of the aos(i) evaluated at r
Needs: Needs:

View File

@ -15,43 +15,52 @@ fci
The user point of view The user point of view
---------------------- ----------------------
* :c:func:`fci` performs |CIPSI| calculations using a stochastic scheme for both the selection and the |PT2| contribution, * :ref:`fci` performs |CIPSI| calculations using a stochastic scheme for both
* :c:func:`pt2` computes the |PT2| contribution using the wave function stored in the |EZFIO| the selection and the |PT2| contribution,
database.
* :ref:`pt2` computes the |PT2| contribution using the wave function stored in
the |EZFIO| database.
The main keywords/options for this module are: The main keywords/options for this module are:
* :option:`determinants n_det_max` : maximum number of Slater determinants in the CIPSI wave function. The :command:`fci` program will stop when the size of the CIPSI wave function will exceed :option:`determinants n_det_max`. * :option:`determinants n_det_max` : maximum number of Slater determinants in
the |CIPSI| wave function. The :ref:`fci` program will stop when the size of
the |CIPSI| wave function will exceed :option:`determinants n_det_max`.
* :option:`perturbation pt2_max` : absolute value of the |PT2| to stop the CIPSI calculation. Once the |PT2| :math:`<` :option:`perturbation pt2_max`, the CIPSI calculation stops. * :option:`perturbation pt2_max` : absolute value of the |PT2| to stop the
|CIPSI| calculation. Once the abs(|PT2|) :math:`<` :option:`perturbation pt2_max`,
the |CIPSI| calculation stops.
* :option:`determinants n_states` : number of states to consider in the CIPSI calculation. * :option:`determinants n_states` : number of states to consider in the |CIPSI|
calculation.
* :option:`determinants read_wf` : if False, starts with a ROHF-like determinant, if True, starts with the current wave function(s) stored in the |EZFIO| folder. * :option:`determinants read_wf` : if |false|, starts with a |ROHF|-like
determinant, if |true|, starts with the current wave function(s) stored in
the |EZFIO| directory.
.. note:: .. note::
For a multi-state calculation, it is recommended to start with :c:func:`cis` or :c:func:`cisd` For a multi-state calculation, it is recommended to start with :ref:`cis`
wave functions as a guess. or :ref:`cisd` wave functions as a guess.
* :option:`determinants s2_eig` : if True, systematically add all the determinants needed to have a pure value of :math:`S^2`. Also, if True, it tracks only the states having the good :option:`determinants expected_s2`. * :option:`determinants expected_s2` : expected value of |S^2| for the
desired spin multiplicity.
.. note:: * :option:`determinants s2_eig` : if |true|, systematically add all the
For a multi-state calculation, it is recommended to start with :c:func:`cis` or :c:func:`cisd` determinants needed to have a pure value of |S^2|. Also, if |true|, it
wave functions as a guess. tracks only the states having the good :option:`determinants expected_s2`.
* :option:`determinants expected_s2` : expected value of :math:`S^2` for the desired spin multiplicity.
The programmer point of view
----------------------------
This module have been created with the :ref:`cipsi` module. The programmer's point of view
------------------------------
This module was created with the :ref:`module_cipsi` module.
.. seealso:: .. seealso::
The documentation of the :ref:`cipsi` module. The documentation of the :ref:`module_cipsi` module.

View File

@ -14,9 +14,9 @@ calculations (the spatial part of the |MOs| is common for alpha and beta
spinorbitals). spinorbitals).
The Hartree-Fock algorithm is a |SCF| and therefore is based on the The Hartree-Fock algorithm is a |SCF| and therefore is based on the
:ref:`module_scf_utils`` module. :ref:`module_scf_utils` module.
The Fock matrix is defined in :file:`hartree_fock fock_matrix_hf.irp.f`. The Fock matrix is defined in :file:`fock_matrix_hf.irp.f`.

View File

@ -562,9 +562,9 @@ Subroutines / functions
Rotates the j-th |MO| with the k-th |MO| to give two new |MOs| that are Rotates the j-th |MO| with the k-th |MO| to give two new |MOs| that are
* $+ = \frac{1}{\sqrt{2}} (|j\rangle + |k\rangle)$ * $+ = \frac{1}{\sqrt{2}} ( | j\rangle + | k\rangle)$
* $- = \frac{1}{\sqrt{2}} (|j\rangle - |k\rangle)$ * $- = \frac{1}{\sqrt{2}} ( | j\rangle - | k\rangle)$
by convention, the '+' |MO| is in the lowest index (min(j,k)) by convention, the '+' |MO| is in the lowest index (min(j,k))
by convention, the '-' |MO| is in the highest index (max(j,k)) by convention, the '-' |MO| is in the highest index (max(j,k))

View File

@ -106,39 +106,6 @@ EZFIO parameters
Providers Providers
--------- ---------
.. c:function:: fill_h_apply_buffer_selection:
File : :file:`perturbation/selection.irp.f`
.. code:: fortran
subroutine fill_H_apply_buffer_selection(n_selected,det_buffer,e_2_pert_buffer,coef_pert_buffer, &
N_st,Nint,iproc,select_max_out)
Fill the H_apply buffer with determiants for the selection
Needs:
.. hlist::
:columns: 3
* :c:data:`selection_criterion`
* :c:data:`h_apply_buffer_allocated`
* :c:data:`n_det`
* :c:data:`n_int`
Calls:
.. hlist::
:columns: 3
* :c:func:`omp_set_lock`
* :c:func:`omp_unset_lock`
* :c:func:`resize_h_apply_buffer`
.. c:var:: h0_type .. c:var:: h0_type
@ -253,6 +220,38 @@ Providers
Subroutines / functions Subroutines / functions
----------------------- -----------------------
.. c:function:: fill_h_apply_buffer_selection:
File : :file:`perturbation/selection.irp.f`
.. code:: fortran
subroutine fill_H_apply_buffer_selection(n_selected,det_buffer,e_2_pert_buffer,coef_pert_buffer, N_st,Nint,iproc,select_max_out)
Fill the H_apply buffer with determiants for the selection
Needs:
.. hlist::
:columns: 3
* :c:data:`selection_criterion`
* :c:data:`h_apply_buffer_allocated`
* :c:data:`n_det`
* :c:data:`n_int`
Calls:
.. hlist::
:columns: 3
* :c:func:`omp_set_lock`
* :c:func:`omp_unset_lock`
* :c:func:`resize_h_apply_buffer`
.. c:function:: perturb_buffer_by_mono_dummy: .. c:function:: perturb_buffer_by_mono_dummy:
@ -263,7 +262,7 @@ Subroutines / functions
subroutine perturb_buffer_by_mono_dummy(i_generator,buffer,buffer_size,e_2_pert_buffer,coef_pert_buffer,sum_e_2_pert,sum_norm_pert,sum_H_pert_diag,N_st,Nint,key_mask,fock_diag_tmp,electronic_energy) subroutine perturb_buffer_by_mono_dummy(i_generator,buffer,buffer_size,e_2_pert_buffer,coef_pert_buffer,sum_e_2_pert,sum_norm_pert,sum_H_pert_diag,N_st,Nint,key_mask,fock_diag_tmp,electronic_energy)
Applly pertubration ``dummy`` to the buffer of determinants generated in the H_apply Apply pertubration ``dummy`` to the buffer of determinants generated in the H_apply
routine. routine.
Needs: Needs:
@ -298,7 +297,7 @@ Subroutines / functions
subroutine perturb_buffer_by_mono_epstein_nesbet(i_generator,buffer,buffer_size,e_2_pert_buffer,coef_pert_buffer,sum_e_2_pert,sum_norm_pert,sum_H_pert_diag,N_st,Nint,key_mask,fock_diag_tmp,electronic_energy) subroutine perturb_buffer_by_mono_epstein_nesbet(i_generator,buffer,buffer_size,e_2_pert_buffer,coef_pert_buffer,sum_e_2_pert,sum_norm_pert,sum_H_pert_diag,N_st,Nint,key_mask,fock_diag_tmp,electronic_energy)
Applly pertubration ``epstein_nesbet`` to the buffer of determinants generated in the H_apply Apply pertubration ``epstein_nesbet`` to the buffer of determinants generated in the H_apply
routine. routine.
Needs: Needs:
@ -333,7 +332,7 @@ Subroutines / functions
subroutine perturb_buffer_by_mono_epstein_nesbet_2x2(i_generator,buffer,buffer_size,e_2_pert_buffer,coef_pert_buffer,sum_e_2_pert,sum_norm_pert,sum_H_pert_diag,N_st,Nint,key_mask,fock_diag_tmp,electronic_energy) subroutine perturb_buffer_by_mono_epstein_nesbet_2x2(i_generator,buffer,buffer_size,e_2_pert_buffer,coef_pert_buffer,sum_e_2_pert,sum_norm_pert,sum_H_pert_diag,N_st,Nint,key_mask,fock_diag_tmp,electronic_energy)
Applly pertubration ``epstein_nesbet_2x2`` to the buffer of determinants generated in the H_apply Apply pertubration ``epstein_nesbet_2x2`` to the buffer of determinants generated in the H_apply
routine. routine.
Needs: Needs:
@ -368,7 +367,7 @@ Subroutines / functions
subroutine perturb_buffer_by_mono_epstein_nesbet_2x2_no_ci_diag(i_generator,buffer,buffer_size,e_2_pert_buffer,coef_pert_buffer,sum_e_2_pert,sum_norm_pert,sum_H_pert_diag,N_st,Nint,key_mask,fock_diag_tmp,electronic_energy) subroutine perturb_buffer_by_mono_epstein_nesbet_2x2_no_ci_diag(i_generator,buffer,buffer_size,e_2_pert_buffer,coef_pert_buffer,sum_e_2_pert,sum_norm_pert,sum_H_pert_diag,N_st,Nint,key_mask,fock_diag_tmp,electronic_energy)
Applly pertubration ``epstein_nesbet_2x2_no_ci_diag`` to the buffer of determinants generated in the H_apply Apply pertubration ``epstein_nesbet_2x2_no_ci_diag`` to the buffer of determinants generated in the H_apply
routine. routine.
Needs: Needs:
@ -403,7 +402,7 @@ Subroutines / functions
subroutine perturb_buffer_by_mono_moller_plesset(i_generator,buffer,buffer_size,e_2_pert_buffer,coef_pert_buffer,sum_e_2_pert,sum_norm_pert,sum_H_pert_diag,N_st,Nint,key_mask,fock_diag_tmp,electronic_energy) subroutine perturb_buffer_by_mono_moller_plesset(i_generator,buffer,buffer_size,e_2_pert_buffer,coef_pert_buffer,sum_e_2_pert,sum_norm_pert,sum_H_pert_diag,N_st,Nint,key_mask,fock_diag_tmp,electronic_energy)
Applly pertubration ``moller_plesset`` to the buffer of determinants generated in the H_apply Apply pertubration ``moller_plesset`` to the buffer of determinants generated in the H_apply
routine. routine.
Needs: Needs:
@ -438,7 +437,7 @@ Subroutines / functions
subroutine perturb_buffer_by_mono_qdpt(i_generator,buffer,buffer_size,e_2_pert_buffer,coef_pert_buffer,sum_e_2_pert,sum_norm_pert,sum_H_pert_diag,N_st,Nint,key_mask,fock_diag_tmp,electronic_energy) subroutine perturb_buffer_by_mono_qdpt(i_generator,buffer,buffer_size,e_2_pert_buffer,coef_pert_buffer,sum_e_2_pert,sum_norm_pert,sum_H_pert_diag,N_st,Nint,key_mask,fock_diag_tmp,electronic_energy)
Applly pertubration ``qdpt`` to the buffer of determinants generated in the H_apply Apply pertubration ``qdpt`` to the buffer of determinants generated in the H_apply
routine. routine.
Needs: Needs:
@ -473,7 +472,7 @@ Subroutines / functions
subroutine perturb_buffer_dummy(i_generator,buffer,buffer_size,e_2_pert_buffer,coef_pert_buffer,sum_e_2_pert,sum_norm_pert,sum_H_pert_diag,N_st,Nint,key_mask,fock_diag_tmp,electronic_energy) subroutine perturb_buffer_dummy(i_generator,buffer,buffer_size,e_2_pert_buffer,coef_pert_buffer,sum_e_2_pert,sum_norm_pert,sum_H_pert_diag,N_st,Nint,key_mask,fock_diag_tmp,electronic_energy)
Applly pertubration ``dummy`` to the buffer of determinants generated in the H_apply Apply pertubration ``dummy`` to the buffer of determinants generated in the H_apply
routine. routine.
Needs: Needs:
@ -509,7 +508,7 @@ Subroutines / functions
subroutine perturb_buffer_epstein_nesbet(i_generator,buffer,buffer_size,e_2_pert_buffer,coef_pert_buffer,sum_e_2_pert,sum_norm_pert,sum_H_pert_diag,N_st,Nint,key_mask,fock_diag_tmp,electronic_energy) subroutine perturb_buffer_epstein_nesbet(i_generator,buffer,buffer_size,e_2_pert_buffer,coef_pert_buffer,sum_e_2_pert,sum_norm_pert,sum_H_pert_diag,N_st,Nint,key_mask,fock_diag_tmp,electronic_energy)
Applly pertubration ``epstein_nesbet`` to the buffer of determinants generated in the H_apply Apply pertubration ``epstein_nesbet`` to the buffer of determinants generated in the H_apply
routine. routine.
Needs: Needs:
@ -545,7 +544,7 @@ Subroutines / functions
subroutine perturb_buffer_epstein_nesbet_2x2(i_generator,buffer,buffer_size,e_2_pert_buffer,coef_pert_buffer,sum_e_2_pert,sum_norm_pert,sum_H_pert_diag,N_st,Nint,key_mask,fock_diag_tmp,electronic_energy) subroutine perturb_buffer_epstein_nesbet_2x2(i_generator,buffer,buffer_size,e_2_pert_buffer,coef_pert_buffer,sum_e_2_pert,sum_norm_pert,sum_H_pert_diag,N_st,Nint,key_mask,fock_diag_tmp,electronic_energy)
Applly pertubration ``epstein_nesbet_2x2`` to the buffer of determinants generated in the H_apply Apply pertubration ``epstein_nesbet_2x2`` to the buffer of determinants generated in the H_apply
routine. routine.
Needs: Needs:
@ -581,7 +580,7 @@ Subroutines / functions
subroutine perturb_buffer_epstein_nesbet_2x2_no_ci_diag(i_generator,buffer,buffer_size,e_2_pert_buffer,coef_pert_buffer,sum_e_2_pert,sum_norm_pert,sum_H_pert_diag,N_st,Nint,key_mask,fock_diag_tmp,electronic_energy) subroutine perturb_buffer_epstein_nesbet_2x2_no_ci_diag(i_generator,buffer,buffer_size,e_2_pert_buffer,coef_pert_buffer,sum_e_2_pert,sum_norm_pert,sum_H_pert_diag,N_st,Nint,key_mask,fock_diag_tmp,electronic_energy)
Applly pertubration ``epstein_nesbet_2x2_no_ci_diag`` to the buffer of determinants generated in the H_apply Apply pertubration ``epstein_nesbet_2x2_no_ci_diag`` to the buffer of determinants generated in the H_apply
routine. routine.
Needs: Needs:
@ -617,7 +616,7 @@ Subroutines / functions
subroutine perturb_buffer_moller_plesset(i_generator,buffer,buffer_size,e_2_pert_buffer,coef_pert_buffer,sum_e_2_pert,sum_norm_pert,sum_H_pert_diag,N_st,Nint,key_mask,fock_diag_tmp,electronic_energy) subroutine perturb_buffer_moller_plesset(i_generator,buffer,buffer_size,e_2_pert_buffer,coef_pert_buffer,sum_e_2_pert,sum_norm_pert,sum_H_pert_diag,N_st,Nint,key_mask,fock_diag_tmp,electronic_energy)
Applly pertubration ``moller_plesset`` to the buffer of determinants generated in the H_apply Apply pertubration ``moller_plesset`` to the buffer of determinants generated in the H_apply
routine. routine.
Needs: Needs:
@ -653,7 +652,7 @@ Subroutines / functions
subroutine perturb_buffer_qdpt(i_generator,buffer,buffer_size,e_2_pert_buffer,coef_pert_buffer,sum_e_2_pert,sum_norm_pert,sum_H_pert_diag,N_st,Nint,key_mask,fock_diag_tmp,electronic_energy) subroutine perturb_buffer_qdpt(i_generator,buffer,buffer_size,e_2_pert_buffer,coef_pert_buffer,sum_e_2_pert,sum_norm_pert,sum_H_pert_diag,N_st,Nint,key_mask,fock_diag_tmp,electronic_energy)
Applly pertubration ``qdpt`` to the buffer of determinants generated in the H_apply Apply pertubration ``qdpt`` to the buffer of determinants generated in the H_apply
routine. routine.
Needs: Needs:

View File

@ -192,11 +192,11 @@ Providers
.. code:: fortran .. code:: fortran
subroutine extrapolate_Fock_matrix( & subroutine extrapolate_Fock_matrix( &
error_matrix_DIIS,Fock_matrix_DIIS, & error_matrix_DIIS,Fock_matrix_DIIS, &
Fock_matrix_AO_,size_Fock_matrix_AO, & Fock_matrix_AO_,size_Fock_matrix_AO, &
iteration_SCF,dim_DIIS & iteration_SCF,dim_DIIS &
) )
Compute the extrapolated Fock matrix using the DIIS procedure Compute the extrapolated Fock matrix using the DIIS procedure

View File

@ -9,5 +9,5 @@ selectors_cassd
=============== ===============
Selectors for |CAS-SD| calculations. The selectors are defined as first the Selectors for |CAS-SD| calculations. The selectors are defined as first the
generators from :ref:`Generators_CAS`, and then the rest of the wave function. generators from :ref:`module_generators_cas`, and then the rest of the wave function.

View File

@ -855,8 +855,8 @@ Subroutines / functions
* :c:func:`remove_duplicates_in_selection_buffer` * :c:func:`remove_duplicates_in_selection_buffer`
* :c:func:`run_cipsi` * :c:func:`run_cipsi`
* :c:func:`run_pt2_slave` * :c:func:`run_pt2_slave`
* :c:func:`run_slave_main`
* :c:func:`run_stochastic_cipsi` * :c:func:`run_stochastic_cipsi`
* :c:func:`select_singles_and_doubles`
* :c:func:`selection_collector` * :c:func:`selection_collector`
* :c:func:`sort_selection_buffer` * :c:func:`sort_selection_buffer`
* :c:func:`testteethbuilding` * :c:func:`testteethbuilding`
@ -2651,6 +2651,7 @@ Subroutines / functions
* :c:func:`check_mem` * :c:func:`check_mem`
* :c:func:`davidson_diag_hjj_sjj` * :c:func:`davidson_diag_hjj_sjj`
* :c:func:`print_memory_usage` * :c:func:`print_memory_usage`
* :c:func:`run_slave_main`
* :c:func:`zmq_pt2` * :c:func:`zmq_pt2`
Calls: Calls:

View File

@ -107,7 +107,7 @@ Only standard Fortran is allowed : Intel or GNU extensions are forbidden.
The name of a program should be the same as the name of the file. For example, The name of a program should be the same as the name of the file. For example,
for the :ref:`fci` program, we have for the :ref:`fci` program, we have
.. code-block:: fortan .. code-block:: fortran
program fci program fci

View File

@ -8,7 +8,7 @@ EZFIO.cfg
The simplest way to add control parameters in the |EZFIO| directory is to create a The simplest way to add control parameters in the |EZFIO| directory is to create a
:file:`EZFIO.cfg` file in the module. An example can be found in existing modules :file:`EZFIO.cfg` file in the module. An example can be found in existing modules
such as :ref:`hartree_fock`:: such as :ref:`module_hartree_fock`::
[max_dim_diis] [max_dim_diis]
type: integer type: integer
@ -92,7 +92,7 @@ Optional
It is possible to directly add to the current module |EZFIO| configuration It is possible to directly add to the current module |EZFIO| configuration
files, named with the ``.ezfio_config`` suffix. An example is in the files, named with the ``.ezfio_config`` suffix. An example is in the
:ref:`bitmask` module. :ref:`module_bitmask` module.
.. code:: text .. code:: text

View File

@ -226,7 +226,6 @@ Index of Providers
* :c:data:`ezfio_work_dir` * :c:data:`ezfio_work_dir`
* :c:data:`fact_inv` * :c:data:`fact_inv`
* :c:data:`file_lock` * :c:data:`file_lock`
* :c:data:`fill_h_apply_buffer_selection`
* :c:data:`final_grid_points` * :c:data:`final_grid_points`
* :c:data:`final_weight_at_r` * :c:data:`final_weight_at_r`
* :c:data:`final_weight_at_r_vector` * :c:data:`final_weight_at_r_vector`
@ -606,7 +605,6 @@ Index of Providers
* :c:data:`psi_selectors_coef_transp` * :c:data:`psi_selectors_coef_transp`
* :c:data:`psi_selectors_diag_h_mat` * :c:data:`psi_selectors_diag_h_mat`
* :c:data:`psi_selectors_size` * :c:data:`psi_selectors_size`
* :c:data:`pt2_collector`
* :c:data:`pt2_cw` * :c:data:`pt2_cw`
* :c:data:`pt2_e0_denominator` * :c:data:`pt2_e0_denominator`
* :c:data:`pt2_f` * :c:data:`pt2_f`
@ -907,6 +905,7 @@ Index of Subroutines/Functions
* :c:func:`fcidump` * :c:func:`fcidump`
* :c:func:`fill_buffer_double` * :c:func:`fill_buffer_double`
* :c:func:`fill_h_apply_buffer_no_selection` * :c:func:`fill_h_apply_buffer_no_selection`
* :c:func:`fill_h_apply_buffer_selection`
* :c:func:`filter_connected` * :c:func:`filter_connected`
* :c:func:`filter_connected_i_h_psi0` * :c:func:`filter_connected_i_h_psi0`
* :c:func:`filter_not_connected` * :c:func:`filter_not_connected`
@ -1198,6 +1197,7 @@ Index of Subroutines/Functions
* :c:func:`provide_all_mo_integrals_erf` * :c:func:`provide_all_mo_integrals_erf`
* :c:func:`provide_everything` * :c:func:`provide_everything`
* :c:func:`pt2` * :c:func:`pt2`
* :c:func:`pt2_collector`
* :c:func:`pt2_dummy` * :c:func:`pt2_dummy`
* :c:func:`pt2_epstein_nesbet` * :c:func:`pt2_epstein_nesbet`
* :c:func:`pt2_epstein_nesbet_2x2` * :c:func:`pt2_epstein_nesbet_2x2`

View File

@ -20,25 +20,22 @@ cis
This program can be useful in many cases: This program can be useful in many cases:
Ground state calculation 1. Ground state calculation
------------------------
To be sure to have the lowest |SCF| solution, perform an :ref:`scf` To be sure to have the lowest |SCF| solution, perform an :ref:`scf`
(see the :ref:`hartree_fock` module), then a :ref:`cis`, save (see the :ref:`module_hartree_fock` module), then a :ref:`cis`, save the
the natural orbitals (see :ref:`save_natorb`) and re-run an natural orbitals (see :ref:`save_natorb`) and re-run an :ref:`scf`
:ref:`scf` optimization from this |MO| guess. optimization from this |MO| guess.
Excited states calculations 2. Excited states calculations
---------------------------
The lowest excited states are much likely to be dominated by The lowest excited states are much likely to be dominated by
single-excitations. Therefore, running a :ref:`cis` will save single-excitations. Therefore, running a :ref:`cis` will save the
the `n_states` lowest states within the |CIS| space in the |EZFIO| `n_states` lowest states within the |CIS| space in the |EZFIO|
directory, which can afterwards be used as guess wave functions for directory, which can afterwards be used as guess wave functions for
a further multi-state |FCI| calculation if :option:`determinants read_wf` a further multi-state |FCI| calculation if :option:`determinants
is set to |true| before running the :ref:`fci` read_wf` is set to |true| before running the :ref:`fci` executable.
executable.
If :option:`determinants s2_eig` is set to |true|, the |CIS| If :option:`determinants s2_eig` is set to |true|, the |CIS|

View File

@ -19,7 +19,7 @@ cisd
This program can be useful in many cases: This program can be useful in many cases:
* GROUND STATE CALCULATION: if even after a :c:func:`cis` calculation, natural * **Ground state calculation**: if even after a :c:func:`cis` calculation, natural
orbitals (see :c:func:`save_natorb`) and then :c:func:`scf` optimization, you are not sure to have the lowest scf orbitals (see :c:func:`save_natorb`) and then :c:func:`scf` optimization, you are not sure to have the lowest scf
solution, solution,
do the same strategy with the :c:func:`cisd` executable instead of the :c:func:`cis` exectuable to generate the natural do the same strategy with the :c:func:`cisd` executable instead of the :c:func:`cis` exectuable to generate the natural
@ -27,11 +27,11 @@ cisd
* EXCITED STATES CALCULATIONS: the lowest excited states are much likely to * **Excited states calculations**: the lowest excited states are much likely to
be dominanted by single- or double-excitations. be dominanted by single- or double-excitations.
Therefore, running a :c:func:`cisd` will save the "n_states" lowest states within Therefore, running a :c:func:`cisd` will save the "n_states" lowest states within
the CISD space the CISD space
in the EZFIO folder, which can afterward be used as guess wave functions in the |EZFIO| directory, which can afterward be used as guess wave functions
for a further multi-state fci calculation if you specify "read_wf" = True for a further multi-state fci calculation if you specify "read_wf" = True
before running the fci executable (see :option:`determinants read_wf`). before running the fci executable (see :option:`determinants read_wf`).
Also, if you specify "s2_eig" = True, the cisd will only retain states Also, if you specify "s2_eig" = True, the cisd will only retain states
@ -51,6 +51,7 @@ cisd
* "del" orbitals which will be never occupied * "del" orbitals which will be never occupied
Needs: Needs:
.. hlist:: .. hlist::

View File

@ -9,11 +9,14 @@ diagonalize_h
Program that extracts the :option:`determinants n_states` lowest states of the Hamiltonian within the set of Slater determinants stored in the EZFIO folder. Program that extracts the :option:`determinants n_states` lowest
states of the Hamiltonian within the set of Slater determinants stored
in the |EZFIO| directory.
If :option:`determinants s2_eig` = True, it will retain only states If :option:`determinants s2_eig` = |true|, it will retain only states
which correspond to the desired value of
:option:`determinants expected_s2`.
which corresponds to the desired value of :option:`determinants expected_s2`.
Needs: Needs:

View File

@ -21,7 +21,7 @@ fci
conditions: conditions:
* number of Slater determinants > :option:`determinants n_det_max` * number of Slater determinants > :option:`determinants n_det_max`
* |PT2| < :option:`perturbation pt2_max` * abs(|PT2|) less than :option:`perturbation pt2_max`
The following other options can be of interest: The following other options can be of interest:
@ -38,7 +38,7 @@ fci
:option:`determinants expected_s2`. :option:`determinants expected_s2`.
For excited states calculations, it is recommended to start with For excited states calculations, it is recommended to start with
:ref:`.cis.` or :ref:`.cisd.` guess wave functions, eventually in :ref:`cis` or :ref:`cisd` guess wave functions, eventually in
a restricted set of |MOs|, and to set :option:`determinants s2_eig` a restricted set of |MOs|, and to set :option:`determinants s2_eig`
to |true|. to |true|.

View File

@ -9,17 +9,22 @@ fcidump
Produce a regular FCIDUMP file from the |MOs| stored in the |EZFIO| folder. Produce a regular `FCIDUMP` file from the |MOs| stored in the |EZFIO|
directory.
To specify an active space, the class of the mos have to set in the |EZFIO| folder (see :ref:`qp_set_mo_class`). To specify an active space, the class of the |MOs| have to set in the
|EZFIO| directory (see :ref:`qp_set_mo_class`).
The fcidump program supports 3 types of MO_class : The :ref:`fcidump` program supports 3 types of |MO| classes :
* the "core" orbitals which are always doubly occupied in the calculation * the *core* orbitals which are always doubly occupied in the
calculation
* the "del" orbitals that are never occupied in the calculation * the *deleted* orbitals that are never occupied in the calculation
* the *active* orbitals that are occupied with a varying number of
electrons
* the "act" orbitals that will be occupied by a varying number of electrons
Needs: Needs:

View File

@ -9,11 +9,15 @@ four_idx_transform
4-index transformation of two-electron integrals from |AO| to |MO| integrals. 4-index transformation of two-electron integrals from |AO| to |MO|
integrals.
This program will compute the two-electron integrals on the |MO| basis and store it into the |EZFIO| folder. This program will compute the two-electron integrals on the |MO| basis
and store it into the |EZFIO| directory.
This program can be useful if the AO --> MO transformation is an
expensive step by itself.
This program can be useful if the AO --> MO transformation is an expensive step by itself.
Needs: Needs:

View File

@ -9,7 +9,7 @@ molden
Produce a Molden file Produces a Molden file
Needs: Needs:

View File

@ -9,13 +9,15 @@ print_wf
Print the ground state wave function stored in the |EZFIO| folder in the intermediate normalization. Print the ground state wave function stored in the |EZFIO| directory
in the intermediate normalization.
It also prints a lot of information regarding the excitation operators from the reference determinant It also prints a lot of information regarding the excitation
operators from the reference determinant ! and a first-order
perturbative analysis of the wave function.
and a first-order perturbative analysis of the wave function. If the wave function strongly deviates from the first-order analysis,
something funny is going on :)
If the wave function strongly deviates from the first-order analysis, something funny is going on :)
Needs: Needs:

View File

@ -9,13 +9,18 @@ pt2
Second order perturbative correction to the wave function contained in the EZFIO directory. Second order perturbative correction to the wave function contained
in the |EZFIO| directory.
This programs runs the stochastic PT2 correction on all "n_states" wave function stored in the EZFIO folder (see :option:`determinant n_states`). This programs runs the stochastic |PT2| correction on all
:option:`determinants n_states` wave functions stored in the |EZFIO|
directory.
The option for the PT2 correction are the "pt2_relative_error" which is the relative stochastic The main option for the |PT2| correction is the
:option:`perturbation pt2_relative_error` which is the relative
stochastic error on the |PT2| to reach before stopping the
sampling.
error on the PT2 to reach before stopping the stochastic sampling. (see :option:`perturbation pt2_relative_error`)
Needs: Needs:

View File

@ -9,15 +9,16 @@ save_natorb
Save natural MOs into the EZFIO Save natural |MOs| into the |EZFIO|.
This program reads the wave function stored in the EZFIO folder, This program reads the wave function stored in the |EZFIO| directory,
extracts the corresponding natural orbitals and setd them as the new
|MOs|.
extracts the corresponding natural orbitals and set them as the new MOs If this is a multi-state calculation, the density matrix that produces
the natural orbitals is obtained from an average of the density
If this is a multi-state calculation, the density matrix that produces the natural orbitals matrices of each state with the corresponding
:option:`determinants state_average_weight`
is obtained from a state-averaged of the density matrices of each state with the corresponding state_average_weight (see the doc of state_average_weight).
Needs: Needs:

View File

@ -9,12 +9,16 @@ save_one_e_dm
programs that computes the one body density on the mo basis for alpha and beta electrons Program that computes the one body density on the |MO| basis
from the wave function stored in the EZFIO folder, and then save it into the EZFIO folder aux_quantities. for $\alpha$ and $\beta$ electrons from the wave function
stored in the |EZFIO| directory, and then saves it into the
:ref:`module_aux_quantities`.
Then, the global variable data_one_e_dm_alpha_mo and data_one_e_dm_beta_mo will automatically read this density in a further calculation. Then, the global variable :option:`aux_quantities data_one_e_dm_alpha_mo`
and :option:`aux_quantities data_one_e_dm_beta_mo` will automatically
This can be used to perform damping on the density in RS-DFT calculation (see the density_for_dft module). read this density in the next calculation. This can be used to perform
damping on the density in |RSDFT| calculations (see
:ref:`module_density_for_dft`).
Needs: Needs:

View File

@ -9,7 +9,8 @@ write_integrals_erf
Saves the two-electron integrals with the :math:`erf(\mu r_{12})/r_{12}` oprerator into the EZFIO folder Saves the two-electron integrals with the $erf(\mu r_{12})/r_{12}$
oprerator into the EZFIO directory.
Needs: Needs:

View File

@ -15,7 +15,7 @@ A few interfaces to external codes are available.
|qp| -> \* |qp| -> \*
---------- ----------
`Molden`_ `Molden <http://cheminf.cmbi.ru.nl/molden>`_
3D plots of Molecular Orbitals 3D plots of Molecular Orbitals
FCIDUMP FCIDUMP

View File

@ -31,7 +31,7 @@ interactively in :ref:`qp_edit` mode. An alternative is to use the
This program will, by default, print out the first :math:`10^4` This program will, by default, print out the first :math:`10^4`
determinants whatever the size of the wave function stored in the determinants whatever the size of the wave function stored in the
|EZFIO| folder. If you want to change the number of printed Slater |EZFIO| directory. If you want to change the number of printed Slater
determinants, just change the :option:`determinants n_det_print_wf` determinants, just change the :option:`determinants n_det_print_wf`
keyword using the :ref:`qp_edit` tool. keyword using the :ref:`qp_edit` tool.

View File

@ -0,0 +1,32 @@
.. _qp_reset:
========
qp_reset
========
.. program:: qp_reset
This command resets parts of the |EZFIO| directory.
Usage
-----
.. code:: bash
qp_reset [-adhm] EZFIO_DIR
.. option:: -a, --all
Reset to the state in which the directory is after after running :ref:`qp_create_ezfio`.
.. option:: -d, --dets
Deletes the determinants and CI coefficients.
.. option:: -m, --mos
Deletes the |MOs|, and consequently the determinants and CI coefficients.

View File

@ -95,7 +95,7 @@ Running programs
qp (run|srun|mpirun) [options] <program> qp (run|srun|mpirun) [options] <program>
Runs :ref:`qp_run`, :ref:`qp_srun`, or :ref:`qp_mpirun` using the current Runs :ref:`qp_run`, :command:`qp_srun`, or :command:`qp_mpirun` using the current
|EZFIO| directory. |EZFIO| directory.
.. option:: stop .. option:: stop

View File

@ -74,7 +74,8 @@ The expected energy is ``-92.827856698`` au.
.. seealso:: .. seealso::
The documentation of the :ref:`hartree_fock` module and that of the :c:func:`scf` program. The documentation of the :ref:`module_hartree_fock` module and that of the
:ref:`scf` program.
This creates the |MOs| in the |EZFIO| database that will be used to This creates the |MOs| in the |EZFIO| database that will be used to
perform any other post-SCF method. The |qp| does not handle symmetry and perform any other post-SCF method. The |qp| does not handle symmetry and
@ -138,7 +139,7 @@ The estimated |FCI| energy of HCN is ``-93.0501`` au.
.. seealso:: .. seealso::
The documentation of the :ref:`fci` module and that of the :c:func:`fci` program. The documentation of the :ref:`module_fci` module and that of the :ref:`fci` program.
--------------------------- ---------------------------

View File

@ -1,6 +1,6 @@
.\" Man page generated from reStructuredText. .\" Man page generated from reStructuredText.
. .
.TH "CIS" "1" "Jan 25, 2019" "2.0" "Quantum Package" .TH "CIS" "1" "Jan 29, 2019" "2.0" "Quantum Package"
.SH NAME .SH NAME
cis \- | Quantum Package > cis \- | Quantum Package >
. .
@ -40,19 +40,24 @@ Disregarding spatial symmetry, it computes the \fIn_states\fP lowest
eigenstates of that CI matrix. (see \fBdeterminants n_states\fP) eigenstates of that CI matrix. (see \fBdeterminants n_states\fP)
.sp .sp
This program can be useful in many cases: This program can be useful in many cases:
.INDENT 0.0
.IP 1. 3
Ground state calculation
.sp .sp
To be sure to have the lowest SCF solution, perform an scf To be sure to have the lowest SCF solution, perform an scf
(see the hartree_fock module), then a \fI\%cis\fP, save (see the module_hartree_fock module), then a \fI\%cis\fP, save the
the natural orbitals (see save_natorb) and re\-run an natural orbitals (see save_natorb) and re\-run an scf
scf optimization from this MO guess. optimization from this MO guess.
.IP 2. 3
Excited states calculations
.sp .sp
The lowest excited states are much likely to be dominated by The lowest excited states are much likely to be dominated by
single\-excitations. Therefore, running a \fI\%cis\fP will save single\-excitations. Therefore, running a \fI\%cis\fP will save the
the \fIn_states\fP lowest states within the CIS space in the \fI\%EZFIO\fP \fIn_states\fP lowest states within the CIS space in the \fI\%EZFIO\fP
directory, which can afterwards be used as guess wave functions for directory, which can afterwards be used as guess wave functions for
a further multi\-state FCI calculation if \fBdeterminants read_wf\fP a further multi\-state FCI calculation if \fBdeterminants
is set to \fBtrue\fP before running the fci read_wf\fP is set to \fBtrue\fP before running the fci executable.
executable. .UNINDENT
.sp .sp
If \fBdeterminants s2_eig\fP is set to \fBtrue\fP, the CIS If \fBdeterminants s2_eig\fP is set to \fBtrue\fP, the CIS
will only retain states having the expected \ewidehat{S^2} value (see will only retain states having the expected \ewidehat{S^2} value (see

View File

@ -1,6 +1,6 @@
.\" Man page generated from reStructuredText. .\" Man page generated from reStructuredText.
. .
.TH "CISD" "1" "Jan 25, 2019" "2.0" "Quantum Package" .TH "CISD" "1" "Jan 29, 2019" "2.0" "Quantum Package"
.SH NAME .SH NAME
cisd \- | Quantum Package > cisd \- | Quantum Package >
. .
@ -43,17 +43,17 @@ matrix (see \fBdeterminants n_states\fP).
This program can be useful in many cases: This program can be useful in many cases:
.INDENT 0.0 .INDENT 0.0
.IP \(bu 2 .IP \(bu 2
GROUND STATE CALCULATION: if even after a \fBcis()\fP calculation, natural \fBGround state calculation\fP: if even after a \fBcis()\fP calculation, natural
orbitals (see \fBsave_natorb()\fP) and then \fBscf()\fP optimization, you are not sure to have the lowest scf orbitals (see \fBsave_natorb()\fP) and then \fBscf()\fP optimization, you are not sure to have the lowest scf
solution, solution,
do the same strategy with the \fBcisd()\fP executable instead of the \fBcis()\fP\ exectuable to generate the natural do the same strategy with the \fBcisd()\fP executable instead of the \fBcis()\fP\ exectuable to generate the natural
orbitals as a guess for the \fBscf()\fP\&. orbitals as a guess for the \fBscf()\fP\&.
.IP \(bu 2 .IP \(bu 2
EXCITED STATES CALCULATIONS: the lowest excited states are much likely to \fBExcited states calculations\fP: the lowest excited states are much likely to
be dominanted by single\- or double\-excitations. be dominanted by single\- or double\-excitations.
Therefore, running a \fBcisd()\fP will save the “n_states” lowest states within Therefore, running a \fBcisd()\fP will save the “n_states” lowest states within
the CISD space the CISD space
in the EZFIO folder, which can afterward be used as guess wave functions in the \fI\%EZFIO\fP directory, which can afterward be used as guess wave functions
for a further multi\-state fci calculation if you specify “read_wf” = True for a further multi\-state fci calculation if you specify “read_wf” = True
before running the fci executable (see \fBdeterminants read_wf\fP). before running the fci executable (see \fBdeterminants read_wf\fP).
Also, if you specify “s2_eig” = True, the cisd will only retain states Also, if you specify “s2_eig” = True, the cisd will only retain states

View File

@ -1,6 +1,6 @@
.\" Man page generated from reStructuredText. .\" Man page generated from reStructuredText.
. .
.TH "CONFIGURE" "1" "Jan 25, 2019" "2.0" "Quantum Package" .TH "CONFIGURE" "1" "Jan 29, 2019" "2.0" "Quantum Package"
.SH NAME .SH NAME
configure \- | Quantum Package > configure \- | Quantum Package >
. .

View File

@ -1,6 +1,6 @@
.\" Man page generated from reStructuredText. .\" Man page generated from reStructuredText.
. .
.TH "DIAGONALIZE_H" "1" "Jan 25, 2019" "2.0" "Quantum Package" .TH "DIAGONALIZE_H" "1" "Jan 29, 2019" "2.0" "Quantum Package"
.SH NAME .SH NAME
diagonalize_h \- | Quantum Package > diagonalize_h \- | Quantum Package >
. .
@ -32,11 +32,13 @@ level margin: \\n[rst2man-indent\\n[rst2man-indent-level]]
.. ..
.INDENT 0.0 .INDENT 0.0
.INDENT 3.5 .INDENT 3.5
Program that extracts the \fBdeterminants n_states\fP lowest states of the Hamiltonian within the set of Slater determinants stored in the EZFIO folder. Program that extracts the \fBdeterminants n_states\fP lowest
states of the Hamiltonian within the set of Slater determinants stored
in the \fI\%EZFIO\fP directory.
.sp .sp
If \fBdeterminants s2_eig\fP = True, it will retain only states If \fBdeterminants s2_eig\fP = \fBtrue\fP, it will retain only states
.sp which correspond to the desired value of
which corresponds to the desired value of \fBdeterminants expected_s2\fP\&. \fBdeterminants expected_s2\fP\&.
.sp .sp
Needs: Needs:
.INDENT 0.0 .INDENT 0.0

View File

@ -1,6 +1,6 @@
.\" Man page generated from reStructuredText. .\" Man page generated from reStructuredText.
. .
.TH "EXCITED_STATES" "1" "Jan 25, 2019" "2.0" "Quantum Package" .TH "EXCITED_STATES" "1" "Jan 29, 2019" "2.0" "Quantum Package"
.SH NAME .SH NAME
excited_states \- | Quantum Package > excited_states \- | Quantum Package >
. .

View File

@ -1,6 +1,6 @@
.\" Man page generated from reStructuredText. .\" Man page generated from reStructuredText.
. .
.TH "FCI" "1" "Jan 25, 2019" "2.0" "Quantum Package" .TH "FCI" "1" "Jan 29, 2019" "2.0" "Quantum Package"
.SH NAME .SH NAME
fci \- | Quantum Package > fci \- | Quantum Package >
. .
@ -46,7 +46,7 @@ conditions:
.IP \(bu 2 .IP \(bu 2
number of Slater determinants > \fBdeterminants n_det_max\fP number of Slater determinants > \fBdeterminants n_det_max\fP
.IP \(bu 2 .IP \(bu 2
PT2 < \fBperturbation pt2_max\fP abs(PT2) less than \fBperturbation pt2_max\fP
.UNINDENT .UNINDENT
.sp .sp
The following other options can be of interest: The following other options can be of interest:
@ -66,7 +66,7 @@ function with an \ewidehat{S^2} value corresponding to
.UNINDENT .UNINDENT
.sp .sp
For excited states calculations, it is recommended to start with For excited states calculations, it is recommended to start with
\&.cis. or \&.cisd. guess wave functions, eventually in cis or cisd guess wave functions, eventually in
a restricted set of MOs, and to set \fBdeterminants s2_eig\fP a restricted set of MOs, and to set \fBdeterminants s2_eig\fP
to \fBtrue\fP\&. to \fBtrue\fP\&.
.sp .sp

View File

@ -1,6 +1,6 @@
.\" Man page generated from reStructuredText. .\" Man page generated from reStructuredText.
. .
.TH "FCIDUMP" "1" "Jan 25, 2019" "2.0" "Quantum Package" .TH "FCIDUMP" "1" "Jan 29, 2019" "2.0" "Quantum Package"
.SH NAME .SH NAME
fcidump \- | Quantum Package > fcidump \- | Quantum Package >
. .
@ -32,18 +32,22 @@ level margin: \\n[rst2man-indent\\n[rst2man-indent-level]]
.. ..
.INDENT 0.0 .INDENT 0.0
.INDENT 3.5 .INDENT 3.5
Produce a regular FCIDUMP file from the MOs stored in the \fI\%EZFIO\fP folder. Produce a regular \fIFCIDUMP\fP file from the MOs stored in the \fI\%EZFIO\fP
directory.
.sp .sp
To specify an active space, the class of the mos have to set in the \fI\%EZFIO\fP folder (see qp_set_mo_class). To specify an active space, the class of the MOs have to set in the
\fI\%EZFIO\fP directory (see qp_set_mo_class).
.sp .sp
The fcidump program supports 3 types of MO_class : The \fI\%fcidump\fP program supports 3 types of MO classes :
.INDENT 0.0 .INDENT 0.0
.IP \(bu 2 .IP \(bu 2
the “core” orbitals which are always doubly occupied in the calculation the \fIcore\fP orbitals which are always doubly occupied in the
calculation
.IP \(bu 2 .IP \(bu 2
the “del” orbitals that are never occupied in the calculation the \fIdeleted\fP orbitals that are never occupied in the calculation
.IP \(bu 2 .IP \(bu 2
the “act” orbitals that will be occupied by a varying number of electrons the \fIactive\fP orbitals that are occupied with a varying number of
electrons
.UNINDENT .UNINDENT
.sp .sp
Needs: Needs:

View File

@ -1,6 +1,6 @@
.\" Man page generated from reStructuredText. .\" Man page generated from reStructuredText.
. .
.TH "FOUR_IDX_TRANSFORM" "1" "Jan 25, 2019" "2.0" "Quantum Package" .TH "FOUR_IDX_TRANSFORM" "1" "Jan 29, 2019" "2.0" "Quantum Package"
.SH NAME .SH NAME
four_idx_transform \- | Quantum Package > four_idx_transform \- | Quantum Package >
. .
@ -32,11 +32,14 @@ level margin: \\n[rst2man-indent\\n[rst2man-indent-level]]
.. ..
.INDENT 0.0 .INDENT 0.0
.INDENT 3.5 .INDENT 3.5
4\-index transformation of two\-electron integrals from AO to MO integrals. 4\-index transformation of two\-electron integrals from AO to MO
integrals.
.sp .sp
This program will compute the two\-electron integrals on the MO basis and store it into the \fI\%EZFIO\fP folder. This program will compute the two\-electron integrals on the MO basis
and store it into the \fI\%EZFIO\fP directory.
.sp .sp
This program can be useful if the AO > MO transformation is an expensive step by itself. This program can be useful if the AO > MO transformation is an
expensive step by itself.
.sp .sp
Needs: Needs:
.INDENT 0.0 .INDENT 0.0

View File

@ -1,6 +1,6 @@
.\" Man page generated from reStructuredText. .\" Man page generated from reStructuredText.
. .
.TH "INTERFACES" "1" "Jan 25, 2019" "2.0" "Quantum Package" .TH "INTERFACES" "1" "Jan 29, 2019" "2.0" "Quantum Package"
.SH NAME .SH NAME
interfaces \- | Quantum Package > interfaces \- | Quantum Package >
. .

View File

@ -1,6 +1,6 @@
.\" Man page generated from reStructuredText. .\" Man page generated from reStructuredText.
. .
.TH "KS_SCF" "1" "Jan 25, 2019" "2.0" "Quantum Package" .TH "KS_SCF" "1" "Jan 29, 2019" "2.0" "Quantum Package"
.SH NAME .SH NAME
ks_scf \- | Quantum Package > ks_scf \- | Quantum Package >
. .

View File

@ -1,6 +1,6 @@
.\" Man page generated from reStructuredText. .\" Man page generated from reStructuredText.
. .
.TH "MOLDEN" "1" "Jan 25, 2019" "2.0" "Quantum Package" .TH "MOLDEN" "1" "Jan 29, 2019" "2.0" "Quantum Package"
.SH NAME .SH NAME
molden \- | Quantum Package > molden \- | Quantum Package >
. .
@ -32,7 +32,7 @@ level margin: \\n[rst2man-indent\\n[rst2man-indent-level]]
.. ..
.INDENT 0.0 .INDENT 0.0
.INDENT 3.5 .INDENT 3.5
Produce a Molden file Produces a Molden file
.sp .sp
Needs: Needs:
.INDENT 0.0 .INDENT 0.0

View File

@ -1,6 +1,6 @@
.\" Man page generated from reStructuredText. .\" Man page generated from reStructuredText.
. .
.TH "NATURAL_ORBITALS" "1" "Jan 25, 2019" "2.0" "Quantum Package" .TH "NATURAL_ORBITALS" "1" "Jan 29, 2019" "2.0" "Quantum Package"
.SH NAME .SH NAME
natural_orbitals \- | Quantum Package > natural_orbitals \- | Quantum Package >
. .

View File

@ -1,6 +1,6 @@
.\" Man page generated from reStructuredText. .\" Man page generated from reStructuredText.
. .
.TH "PLUGINS" "1" "Jan 25, 2019" "2.0" "Quantum Package" .TH "PLUGINS" "1" "Jan 29, 2019" "2.0" "Quantum Package"
.SH NAME .SH NAME
plugins \- | Quantum Package > plugins \- | Quantum Package >
. .

View File

@ -1,6 +1,6 @@
.\" Man page generated from reStructuredText. .\" Man page generated from reStructuredText.
. .
.TH "PRINT_E_CONV" "1" "Jan 25, 2019" "2.0" "Quantum Package" .TH "PRINT_E_CONV" "1" "Jan 29, 2019" "2.0" "Quantum Package"
.SH NAME .SH NAME
print_e_conv \- | Quantum Package > print_e_conv \- | Quantum Package >
. .

View File

@ -1,6 +1,6 @@
.\" Man page generated from reStructuredText. .\" Man page generated from reStructuredText.
. .
.TH "PRINT_WF" "1" "Jan 25, 2019" "2.0" "Quantum Package" .TH "PRINT_WF" "1" "Jan 29, 2019" "2.0" "Quantum Package"
.SH NAME .SH NAME
print_wf \- | Quantum Package > print_wf \- | Quantum Package >
. .
@ -32,13 +32,15 @@ level margin: \\n[rst2man-indent\\n[rst2man-indent-level]]
.. ..
.INDENT 0.0 .INDENT 0.0
.INDENT 3.5 .INDENT 3.5
Print the ground state wave function stored in the \fI\%EZFIO\fP folder in the intermediate normalization. Print the ground state wave function stored in the \fI\%EZFIO\fP directory
in the intermediate normalization.
.sp .sp
It also prints a lot of information regarding the excitation operators from the reference determinant It also prints a lot of information regarding the excitation
operators from the reference determinant ! and a first\-order
perturbative analysis of the wave function.
.sp .sp
and a first\-order perturbative analysis of the wave function. If the wave function strongly deviates from the first\-order analysis,
.sp something funny is going on :)
If the wave function strongly deviates from the first\-order analysis, something funny is going on :)
.sp .sp
Needs: Needs:
.INDENT 0.0 .INDENT 0.0

View File

@ -1,6 +1,6 @@
.\" Man page generated from reStructuredText. .\" Man page generated from reStructuredText.
. .
.TH "PRINTING" "1" "Jan 25, 2019" "2.0" "Quantum Package" .TH "PRINTING" "1" "Jan 29, 2019" "2.0" "Quantum Package"
.SH NAME .SH NAME
printing \- | Quantum Package > printing \- | Quantum Package >
. .
@ -74,7 +74,7 @@ qp_run print_wf file.ezfio | tee file.ezfio.fci_natorb.wf
.sp .sp
This program will, by default, print out the first 10^4 This program will, by default, print out the first 10^4
determinants whatever the size of the wave function stored in the determinants whatever the size of the wave function stored in the
\fI\%EZFIO\fP folder. If you want to change the number of printed Slater \fI\%EZFIO\fP directory. If you want to change the number of printed Slater
determinants, just change the \fBdeterminants n_det_print_wf\fP determinants, just change the \fBdeterminants n_det_print_wf\fP
keyword using the qp_edit tool. keyword using the qp_edit tool.
.sp .sp

View File

@ -1,6 +1,6 @@
.\" Man page generated from reStructuredText. .\" Man page generated from reStructuredText.
. .
.TH "PT2" "1" "Jan 25, 2019" "2.0" "Quantum Package" .TH "PT2" "1" "Jan 29, 2019" "2.0" "Quantum Package"
.SH NAME .SH NAME
pt2 \- | Quantum Package > pt2 \- | Quantum Package >
. .
@ -32,13 +32,17 @@ level margin: \\n[rst2man-indent\\n[rst2man-indent-level]]
.. ..
.INDENT 0.0 .INDENT 0.0
.INDENT 3.5 .INDENT 3.5
Second order perturbative correction to the wave function contained in the EZFIO directory. Second order perturbative correction to the wave function contained
in the \fI\%EZFIO\fP directory.
.sp .sp
This programs runs the stochastic PT2 correction on all “n_states” wave function stored in the EZFIO folder (see \fBdeterminant n_states\fP). This programs runs the stochastic PT2 correction on all
\fBdeterminants n_states\fP wave functions stored in the \fI\%EZFIO\fP
directory.
.sp .sp
The option for the PT2 correction are the “pt2_relative_error” which is the relative stochastic The main option for the PT2 correction is the
.sp \fBperturbation pt2_relative_error\fP which is the relative
error on the PT2 to reach before stopping the stochastic sampling. (see \fBperturbation pt2_relative_error\fP) stochastic error on the PT2 to reach before stopping the
sampling.
.sp .sp
Needs: Needs:
.INDENT 0.0 .INDENT 0.0

View File

@ -1,6 +1,6 @@
.\" Man page generated from reStructuredText. .\" Man page generated from reStructuredText.
. .
.TH "QP_CONVERT_OUTPUT_TO_EZFIO" "1" "Jan 25, 2019" "2.0" "Quantum Package" .TH "QP_CONVERT_OUTPUT_TO_EZFIO" "1" "Jan 29, 2019" "2.0" "Quantum Package"
.SH NAME .SH NAME
qp_convert_output_to_ezfio \- | Quantum Package > qp_convert_output_to_ezfio \- | Quantum Package >
. .

View File

@ -1,6 +1,6 @@
.\" Man page generated from reStructuredText. .\" Man page generated from reStructuredText.
. .
.TH "QP_CREATE_EZFIO_FROM_XYZ" "1" "Jan 25, 2019" "2.0" "Quantum Package" .TH "QP_CREATE_EZFIO_FROM_XYZ" "1" "Jan 29, 2019" "2.0" "Quantum Package"
.SH NAME .SH NAME
qp_create_ezfio_from_xyz \- | Quantum Package > qp_create_ezfio_from_xyz \- | Quantum Package >
. .

View File

@ -1,6 +1,6 @@
.\" Man page generated from reStructuredText. .\" Man page generated from reStructuredText.
. .
.TH "QP_EDIT" "1" "Jan 25, 2019" "2.0" "Quantum Package" .TH "QP_EDIT" "1" "Jan 29, 2019" "2.0" "Quantum Package"
.SH NAME .SH NAME
qp_edit \- | Quantum Package > qp_edit \- | Quantum Package >
. .

View File

@ -1,6 +1,6 @@
.\" Man page generated from reStructuredText. .\" Man page generated from reStructuredText.
. .
.TH "QP_EXPORT_AS_TGZ" "1" "Jan 25, 2019" "2.0" "Quantum Package" .TH "QP_EXPORT_AS_TGZ" "1" "Jan 29, 2019" "2.0" "Quantum Package"
.SH NAME .SH NAME
qp_export_as_tgz \- | Quantum Package > qp_export_as_tgz \- | Quantum Package >
. .

View File

@ -1,6 +1,6 @@
.\" Man page generated from reStructuredText. .\" Man page generated from reStructuredText.
. .
.TH "QP_PLUGINS" "1" "Jan 25, 2019" "2.0" "Quantum Package" .TH "QP_PLUGINS" "1" "Jan 29, 2019" "2.0" "Quantum Package"
.SH NAME .SH NAME
qp_plugins \- | Quantum Package > qp_plugins \- | Quantum Package >
. .

66
man/qp_reset.1 Normal file
View File

@ -0,0 +1,66 @@
.\" Man page generated from reStructuredText.
.
.TH "QP_RESET" "1" "Jan 29, 2019" "2.0" "Quantum Package"
.SH NAME
qp_reset \- | Quantum Package >
.
.nr rst2man-indent-level 0
.
.de1 rstReportMargin
\\$1 \\n[an-margin]
level \\n[rst2man-indent-level]
level margin: \\n[rst2man-indent\\n[rst2man-indent-level]]
-
\\n[rst2man-indent0]
\\n[rst2man-indent1]
\\n[rst2man-indent2]
..
.de1 INDENT
.\" .rstReportMargin pre:
. RS \\$1
. nr rst2man-indent\\n[rst2man-indent-level] \\n[an-margin]
. nr rst2man-indent-level +1
.\" .rstReportMargin post:
..
.de UNINDENT
. RE
.\" indent \\n[an-margin]
.\" old: \\n[rst2man-indent\\n[rst2man-indent-level]]
.nr rst2man-indent-level -1
.\" new: \\n[rst2man-indent\\n[rst2man-indent-level]]
.in \\n[rst2man-indent\\n[rst2man-indent-level]]u
..
.sp
This command resets parts of the \fI\%EZFIO\fP directory.
.SH USAGE
.INDENT 0.0
.INDENT 3.5
.sp
.nf
.ft C
qp_reset [\-adhm] EZFIO_DIR
.ft P
.fi
.UNINDENT
.UNINDENT
.INDENT 0.0
.TP
.B \-a, \-\-all
Reset to the state in which the directory is after after running qp_create_ezfio\&.
.UNINDENT
.INDENT 0.0
.TP
.B \-d, \-\-dets
Deletes the determinants and CI coefficients.
.UNINDENT
.INDENT 0.0
.TP
.B \-m, \-\-mos
Deletes the MOs, and consequently the determinants and CI coefficients.
.UNINDENT
.SH AUTHOR
A. Scemama, E. Giner
.SH COPYRIGHT
2019, A. Scemama, E. Giner
.\" Generated by docutils manpage writer.
.

View File

@ -1,6 +1,6 @@
.\" Man page generated from reStructuredText. .\" Man page generated from reStructuredText.
. .
.TH "QP_RUN" "1" "Jan 25, 2019" "2.0" "Quantum Package" .TH "QP_RUN" "1" "Jan 29, 2019" "2.0" "Quantum Package"
.SH NAME .SH NAME
qp_run \- | Quantum Package > qp_run \- | Quantum Package >
. .

View File

@ -1,6 +1,6 @@
.\" Man page generated from reStructuredText. .\" Man page generated from reStructuredText.
. .
.TH "QP_SET_FROZEN_CORE" "1" "Jan 25, 2019" "2.0" "Quantum Package" .TH "QP_SET_FROZEN_CORE" "1" "Jan 29, 2019" "2.0" "Quantum Package"
.SH NAME .SH NAME
qp_set_frozen_core \- | Quantum Package > qp_set_frozen_core \- | Quantum Package >
. .

View File

@ -1,6 +1,6 @@
.\" Man page generated from reStructuredText. .\" Man page generated from reStructuredText.
. .
.TH "QP_SET_MO_CLASS" "1" "Jan 25, 2019" "2.0" "Quantum Package" .TH "QP_SET_MO_CLASS" "1" "Jan 29, 2019" "2.0" "Quantum Package"
.SH NAME .SH NAME
qp_set_mo_class \- | Quantum Package > qp_set_mo_class \- | Quantum Package >
. .

View File

@ -1,6 +1,6 @@
.\" Man page generated from reStructuredText. .\" Man page generated from reStructuredText.
. .
.TH "QP_STOP" "1" "Jan 25, 2019" "2.0" "Quantum Package" .TH "QP_STOP" "1" "Jan 29, 2019" "2.0" "Quantum Package"
.SH NAME .SH NAME
qp_stop \- | Quantum Package > qp_stop \- | Quantum Package >
. .

View File

@ -1,6 +1,6 @@
.\" Man page generated from reStructuredText. .\" Man page generated from reStructuredText.
. .
.TH "QP_UPDATE" "1" "Jan 25, 2019" "2.0" "Quantum Package" .TH "QP_UPDATE" "1" "Jan 29, 2019" "2.0" "Quantum Package"
.SH NAME .SH NAME
qp_update \- | Quantum Package > qp_update \- | Quantum Package >
. .

View File

@ -1,6 +1,6 @@
.\" Man page generated from reStructuredText. .\" Man page generated from reStructuredText.
. .
.TH "QPSH" "1" "Jan 25, 2019" "2.0" "Quantum Package" .TH "QPSH" "1" "Jan 29, 2019" "2.0" "Quantum Package"
.SH NAME .SH NAME
qpsh \- | Quantum Package > qpsh \- | Quantum Package >
. .
@ -153,7 +153,7 @@ qp (run|srun|mpirun) [options] <program>
.UNINDENT .UNINDENT
.UNINDENT .UNINDENT
.sp .sp
Runs qp_run, qp_srun, or qp_mpirun using the current Runs qp_run, \fBqp_srun\fP, or \fBqp_mpirun\fP using the current
\fI\%EZFIO\fP directory. \fI\%EZFIO\fP directory.
.UNINDENT .UNINDENT
.INDENT 0.0 .INDENT 0.0

View File

@ -1,6 +1,6 @@
.\" Man page generated from reStructuredText. .\" Man page generated from reStructuredText.
. .
.TH "RS_KS_SCF" "1" "Jan 25, 2019" "2.0" "Quantum Package" .TH "RS_KS_SCF" "1" "Jan 29, 2019" "2.0" "Quantum Package"
.SH NAME .SH NAME
rs_ks_scf \- | Quantum Package > rs_ks_scf \- | Quantum Package >
. .

View File

@ -1,6 +1,6 @@
.\" Man page generated from reStructuredText. .\" Man page generated from reStructuredText.
. .
.TH "SAVE_NATORB" "1" "Jan 25, 2019" "2.0" "Quantum Package" .TH "SAVE_NATORB" "1" "Jan 29, 2019" "2.0" "Quantum Package"
.SH NAME .SH NAME
save_natorb \- | Quantum Package > save_natorb \- | Quantum Package >
. .
@ -32,15 +32,16 @@ level margin: \\n[rst2man-indent\\n[rst2man-indent-level]]
.. ..
.INDENT 0.0 .INDENT 0.0
.INDENT 3.5 .INDENT 3.5
Save natural MOs into the EZFIO Save natural MOs into the \fI\%EZFIO\fP\&.
.sp .sp
This program reads the wave function stored in the EZFIO folder, This program reads the wave function stored in the \fI\%EZFIO\fP directory,
extracts the corresponding natural orbitals and setd them as the new
MOs\&.
.sp .sp
extracts the corresponding natural orbitals and set them as the new MOs If this is a multi\-state calculation, the density matrix that produces
.sp the natural orbitals is obtained from an average of the density
If this is a multi\-state calculation, the density matrix that produces the natural orbitals matrices of each state with the corresponding
.sp \fBdeterminants state_average_weight\fP
is obtained from a state\-averaged of the density matrices of each state with the corresponding state_average_weight (see the doc of state_average_weight).
.sp .sp
Needs: Needs:
.INDENT 0.0 .INDENT 0.0

View File

@ -1,6 +1,6 @@
.\" Man page generated from reStructuredText. .\" Man page generated from reStructuredText.
. .
.TH "SAVE_ONE_E_DM" "1" "Jan 25, 2019" "2.0" "Quantum Package" .TH "SAVE_ONE_E_DM" "1" "Jan 29, 2019" "2.0" "Quantum Package"
.SH NAME .SH NAME
save_one_e_dm \- | Quantum Package > save_one_e_dm \- | Quantum Package >
. .
@ -32,12 +32,16 @@ level margin: \\n[rst2man-indent\\n[rst2man-indent-level]]
.. ..
.INDENT 0.0 .INDENT 0.0
.INDENT 3.5 .INDENT 3.5
programs that computes the one body density on the mo basis for alpha and beta electrons Program that computes the one body density on the MO basis
from the wave function stored in the EZFIO folder, and then save it into the EZFIO folder aux_quantities. for $alpha$ and $beta$ electrons from the wave function
stored in the \fI\%EZFIO\fP directory, and then saves it into the
module_aux_quantities\&.
.sp .sp
Then, the global variable data_one_e_dm_alpha_mo and data_one_e_dm_beta_mo will automatically read this density in a further calculation. Then, the global variable \fBaux_quantities data_one_e_dm_alpha_mo\fP
.sp and \fBaux_quantities data_one_e_dm_beta_mo\fP will automatically
This can be used to perform damping on the density in RS\-DFT calculation (see the density_for_dft module). read this density in the next calculation. This can be used to perform
damping on the density in RSDFT calculations (see
module_density_for_dft).
.sp .sp
Needs: Needs:
.INDENT 0.0 .INDENT 0.0

View File

@ -1,6 +1,6 @@
.\" Man page generated from reStructuredText. .\" Man page generated from reStructuredText.
. .
.TH "SAVE_ORTHO_MOS" "1" "Jan 25, 2019" "2.0" "Quantum Package" .TH "SAVE_ORTHO_MOS" "1" "Jan 29, 2019" "2.0" "Quantum Package"
.SH NAME .SH NAME
save_ortho_mos \- | Quantum Package > save_ortho_mos \- | Quantum Package >
. .

View File

@ -1,6 +1,6 @@
.\" Man page generated from reStructuredText. .\" Man page generated from reStructuredText.
. .
.TH "SCF" "1" "Jan 25, 2019" "2.0" "Quantum Package" .TH "SCF" "1" "Jan 29, 2019" "2.0" "Quantum Package"
.SH NAME .SH NAME
scf \- | Quantum Package > scf \- | Quantum Package >
. .

View File

@ -1,6 +1,6 @@
.\" Man page generated from reStructuredText. .\" Man page generated from reStructuredText.
. .
.TH "WRITE_INTEGRALS_ERF" "1" "Jan 25, 2019" "2.0" "Quantum Package" .TH "WRITE_INTEGRALS_ERF" "1" "Jan 29, 2019" "2.0" "Quantum Package"
.SH NAME .SH NAME
write_integrals_erf \- | Quantum Package > write_integrals_erf \- | Quantum Package >
. .
@ -32,7 +32,8 @@ level margin: \\n[rst2man-indent\\n[rst2man-indent-level]]
.. ..
.INDENT 0.0 .INDENT 0.0
.INDENT 3.5 .INDENT 3.5
Saves the two\-electron integrals with the erf(\emu r_{12})/r_{12} oprerator into the EZFIO folder Saves the two\-electron integrals with the $erf(mu r_{12})/r_{12}$
oprerator into the EZFIO directory.
.sp .sp
Needs: Needs:
.INDENT 0.0 .INDENT 0.0

View File

@ -17,9 +17,13 @@ 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` provider includes .. warning::
this normalization factor.
`ao_coef` contains the |AO| coefficients given in input. These do not
include the normalization constant of the |AO|. The `ao_coef_normalized`
provider includes this normalization factor.
The |AOs| are also sorted by increasing exponent to accelerate the calculation of The |AOs| are also sorted by increasing exponent to accelerate the calculation of
the two electron integrals. the two electron integrals.

View File

@ -1,7 +1,7 @@
double precision function ao_value(i,r) double precision function ao_value(i,r)
implicit none implicit none
BEGIN_DOC BEGIN_DOC
! return the value of the ith ao at point r ! Returns the value of the i-th ao at point $\textbf{r}$
END_DOC END_DOC
double precision, intent(in) :: r(3) double precision, intent(in) :: r(3)
integer, intent(in) :: i integer, intent(in) :: i
@ -35,7 +35,8 @@ end
double precision function primitive_value(i,j,r) double precision function primitive_value(i,j,r)
implicit none implicit none
BEGIN_DOC BEGIN_DOC
! return the value of the jth primitive of ith ao at point r WITHOUT THE COEF ! Returns the value of the j-th primitive of the i-th |AO| at point $\textbf{r}
! **without the coefficient**
END_DOC END_DOC
double precision, intent(in) :: r(3) double precision, intent(in) :: r(3)
integer, intent(in) :: i,j integer, intent(in) :: i,j
@ -68,7 +69,7 @@ end
subroutine give_all_aos_at_r_old(r,aos_array) subroutine give_all_aos_at_r_old(r,aos_array)
implicit none implicit none
BEGIN_dOC BEGIN_dOC
! gives the values of aos at a given point r ! Gives the values of |AOs| at a given point $\textbf{r}$
END_DOC END_DOC
double precision, intent(in) :: r(3) double precision, intent(in) :: r(3)
double precision, intent(out) :: aos_array(ao_num) double precision, intent(out) :: aos_array(ao_num)
@ -83,8 +84,9 @@ end
subroutine give_all_aos_at_r(r,aos_array) subroutine give_all_aos_at_r(r,aos_array)
implicit none implicit none
BEGIN_dOC BEGIN_dOC
! input : r == r(1) = x and so on ! input : r == r(1) = x and so on
! aos_array(i) = aos(i) evaluated in r !
! output : aos_array(i) = aos(i) evaluated in $\textbf{r}$
END_DOC END_DOC
double precision, intent(in) :: r(3) double precision, intent(in) :: r(3)
double precision, intent(out) :: aos_array(ao_num) double precision, intent(out) :: aos_array(ao_num)
@ -121,9 +123,13 @@ end
subroutine give_all_aos_and_grad_at_r(r,aos_array,aos_grad_array) subroutine give_all_aos_and_grad_at_r(r,aos_array,aos_grad_array)
implicit none implicit none
BEGIN_DOC BEGIN_DOC
! input : r(1) ==> r(1) = x, r(2) = y, r(3) = z ! input : r(1) ==> r(1) = x, r(2) = y, r(3) = z
! output : aos_array(i) = ao(i) evaluated at r !
! : aos_grad_array(1,i) = gradient X of the ao(i) evaluated at r ! output :
!
! * aos_array(i) = ao(i) evaluated at ro
! * aos_grad_array(1,i) = gradient X of the ao(i) evaluated at $\textbf{r}$
!
END_DOC END_DOC
double precision, intent(in) :: r(3) double precision, intent(in) :: r(3)
double precision, intent(out) :: aos_array(ao_num) double precision, intent(out) :: aos_array(ao_num)
@ -187,9 +193,12 @@ end
subroutine give_all_aos_and_grad_and_lapl_at_r(r,aos_array,aos_grad_array,aos_lapl_array) subroutine give_all_aos_and_grad_and_lapl_at_r(r,aos_array,aos_grad_array,aos_lapl_array)
implicit none implicit none
BEGIN_DOC BEGIN_DOC
! input : r(1) ==> r(1) = x, r(2) = y, r(3) = z ! input : r(1) ==> r(1) = x, r(2) = y, r(3) = z
! output : aos_array(i) = ao(i) evaluated at r !
! : aos_grad_array(1,i) = gradient X of the ao(i) evaluated at r ! output :
!
! * aos_array(i) = ao(i) evaluated at $\textbf{r}$
! * aos_grad_array(1,i) = $\nabla_x$ of the ao(i) evaluated at $\textbf{r}$
END_DOC END_DOC
double precision, intent(in) :: r(3) double precision, intent(in) :: r(3)
double precision, intent(out) :: aos_array(ao_num) double precision, intent(out) :: aos_array(ao_num)

View File

@ -5,8 +5,10 @@
BEGIN_DOC BEGIN_DOC
! Second derivative matrix elements in the |AO| basis. ! Second derivative matrix elements in the |AO| basis.
! !
! :math:`{\tt ao\_deriv2\_x} = ! .. math::
! \langle \chi_i(x,y,z) | \frac{\partial^2}{\partial x^2} |\chi_j (x,y,z) \rangle` !
! {\tt ao\_deriv2\_x} =
! \langle \chi_i(x,y,z) | \frac{\partial^2}{\partial x^2} |\chi_j (x,y,z) \rangle
! !
END_DOC END_DOC
integer :: i,j,n,l integer :: i,j,n,l
@ -122,7 +124,8 @@ BEGIN_PROVIDER [double precision, ao_kinetic_integrals, (ao_num,ao_num)]
BEGIN_DOC BEGIN_DOC
! Kinetic energy integrals in the |AO| basis. ! Kinetic energy integrals in the |AO| basis.
! !
! :math:`\langle \chi_i |\hat{T}| \chi_j \rangle` ! $\langle \chi_i |\hat{T}| \chi_j \rangle$
!
END_DOC END_DOC
integer :: i,j,k,l integer :: i,j,k,l

View File

@ -2,7 +2,7 @@ subroutine give_all_erf_kl_ao(integrals_ao,mu_in,C_center)
implicit none implicit none
BEGIN_DOC BEGIN_DOC
! Subroutine that returns all integrals over $r$ of type ! Subroutine that returns all integrals over $r$ of type
! $\frac{ \erf(\mu * |r-R_C|) }{ |r-R_C| }$ ! $\frac{ \erf(\mu * | r - R_C | ) }{ | r - R_C | }$
END_DOC END_DOC
double precision, intent(in) :: mu_in,C_center(3) double precision, intent(in) :: mu_in,C_center(3)
double precision, intent(out) :: integrals_ao(ao_num,ao_num) double precision, intent(out) :: integrals_ao(ao_num,ao_num)
@ -20,7 +20,7 @@ double precision function NAI_pol_mult_erf_ao(i_ao,j_ao,mu_in,C_center)
implicit none implicit none
BEGIN_DOC BEGIN_DOC
! Computes the following integral : ! Computes the following integral :
! $\int_{-\infty}^{infty} dr \chi_i(r) \chi_j(r) \frac{\erf(\mu |r-R_C|)}{|r-R_C|}$. ! $\int_{-\infty}^{infty} dr \chi_i(r) \chi_j(r) \frac{\erf(\mu | r - R_C | )}{ | r - R_C | }$.
END_DOC END_DOC
integer, intent(in) :: i_ao,j_ao integer, intent(in) :: i_ao,j_ao
double precision, intent(in) :: mu_in, C_center(3) double precision, intent(in) :: mu_in, C_center(3)
@ -51,8 +51,12 @@ end
double precision function NAI_pol_mult_erf(A_center,B_center,power_A,power_B,alpha,beta,C_center,n_pt_in,mu_in) double precision function NAI_pol_mult_erf(A_center,B_center,power_A,power_B,alpha,beta,C_center,n_pt_in,mu_in)
BEGIN_DOC BEGIN_DOC
! Computes the following integral : ! Computes the following integral :
! $\int dr (x-A_x)^a (x-B_x)^b \exp(-\alpha (x-A_x)^2 - \beta (x-B_x)^2 ) !
! \frac{\erf(\mu |r-R_C|)}{|r-R_c|}$. ! .. math::
!
! \int dr (x-A_x)^a (x-B_x)^b \exp(-\alpha (x-A_x)^2 - \beta (x-B_x)^2 )
! \frac{\erf(\mu | r - R_C | )}{ | r - R_C | }$.
!
END_DOC END_DOC
implicit none implicit none
@ -126,7 +130,8 @@ end
subroutine give_polynomial_mult_center_one_e_erf_opt(A_center,B_center,alpha,beta,& subroutine give_polynomial_mult_center_one_e_erf_opt(A_center,B_center,alpha,beta,&
power_A,power_B,C_center,n_pt_in,d,n_pt_out,mu_in,p,p_inv,p_inv_2,p_new,P_center) power_A,power_B,C_center,n_pt_in,d,n_pt_out,mu_in,p,p_inv,p_inv_2,p_new,P_center)
BEGIN_DOC BEGIN_DOC
! Returns the explicit polynomial in terms of the $t$ variable of the following polynomial: ! Returns the explicit polynomial in terms of the $t$ variable of the
! following polynomial:
! !
! $I_{x1}(a_x, d_x,p,q) \times I_{x1}(a_y, d_y,p,q) \times I_{x1}(a_z, d_z,p,q)$. ! $I_{x1}(a_x, d_x,p,q) \times I_{x1}(a_y, d_y,p,q) \times I_{x1}(a_z, d_z,p,q)$.
END_DOC END_DOC
@ -244,7 +249,8 @@ end
subroutine give_polynomial_mult_center_one_e_erf(A_center,B_center,alpha,beta,& subroutine give_polynomial_mult_center_one_e_erf(A_center,B_center,alpha,beta,&
power_A,power_B,C_center,n_pt_in,d,n_pt_out,mu_in) power_A,power_B,C_center,n_pt_in,d,n_pt_out,mu_in)
BEGIN_DOC BEGIN_DOC
! Returns the explicit polynomial in terms of the $t$ variable of the following polynomial: ! Returns the explicit polynomial in terms of the $t$ variable of the
! following polynomial:
! !
! $I_{x1}(a_x, d_x,p,q) \times I_{x1}(a_y, d_y,p,q) \times I_{x1}(a_z, d_z,p,q)$. ! $I_{x1}(a_x, d_x,p,q) \times I_{x1}(a_y, d_y,p,q) \times I_{x1}(a_z, d_z,p,q)$.
END_DOC END_DOC
@ -262,7 +268,6 @@ subroutine give_polynomial_mult_center_one_e_erf(A_center,B_center,alpha,beta,&
double precision :: accu, pq_inv, p10_1, p10_2, p01_1, p01_2 double precision :: accu, pq_inv, p10_1, p10_2, p01_1, p01_2
double precision :: p,P_center(3),rho,p_inv,p_inv_2 double precision :: p,P_center(3),rho,p_inv,p_inv_2
accu = 0.d0 accu = 0.d0
!COMPTEUR irp_rdtsc1 = irp_rdtsc()
ASSERT (n_pt_in > 1) ASSERT (n_pt_in > 1)
p = alpha+beta p = alpha+beta
p_inv = 1.d0/p p_inv = 1.d0/p

View File

@ -458,11 +458,13 @@ end
double precision function ERI_erf(alpha,beta,delta,gama,a_x,b_x,c_x,d_x,a_y,b_y,c_y,d_y,a_z,b_z,c_z,d_z) double precision function ERI_erf(alpha,beta,delta,gama,a_x,b_x,c_x,d_x,a_y,b_y,c_y,d_y,a_z,b_z,c_z,d_z)
implicit none implicit none
BEGIN_DOC BEGIN_DOC
! ATOMIC PRIMTIVE two-electron integral between the 4 primitives :: ! Atomic primtive two-electron integral between the 4 primitives :
! primitive_1 = x1**(a_x) y1**(a_y) z1**(a_z) exp(-alpha * r1**2) !
! primitive_2 = x1**(b_x) y1**(b_y) z1**(b_z) exp(- beta * r1**2) ! * primitive 1 : $x_1^{a_x} y_1^{a_y} z_1^{a_z} \exp(-\alpha * r1^2)$
! primitive_3 = x2**(c_x) y2**(c_y) z2**(c_z) exp(-delta * r2**2) ! * primitive 2 : $x_1^{b_x} y_1^{b_y} z_1^{b_z} \exp(- \beta * r1^2)$
! primitive_4 = x2**(d_x) y2**(d_y) z2**(d_z) exp(- gama * r2**2) ! * primitive 3 : $x_2^{c_x} y_2^{c_y} z_2^{c_z} \exp(-\delta * r2^2)$
! * primitive 4 : $x_2^{d_x} y_2^{d_y} z_2^{d_z} \exp(-\gamma * r2^2)$
!
END_DOC END_DOC
double precision, intent(in) :: delta,gama,alpha,beta double precision, intent(in) :: delta,gama,alpha,beta
integer, intent(in) :: a_x,b_x,c_x,d_x,a_y,b_y,c_y,d_y,a_z,b_z,c_z,d_z integer, intent(in) :: a_x,b_x,c_x,d_x,a_y,b_y,c_y,d_y,a_z,b_z,c_z,d_z
@ -517,9 +519,11 @@ end
subroutine integrale_new_erf(I_f,a_x,b_x,c_x,d_x,a_y,b_y,c_y,d_y,a_z,b_z,c_z,d_z,p,q,n_pt) subroutine integrale_new_erf(I_f,a_x,b_x,c_x,d_x,a_y,b_y,c_y,d_y,a_z,b_z,c_z,d_z,p,q,n_pt)
BEGIN_DOC BEGIN_DOC
! calculate the integral of the polynom :: ! Calculate the integral of the polynomial :
! I_x1(a_x+b_x, c_x+d_x,p,q) * I_x1(a_y+b_y, c_y+d_y,p,q) * I_x1(a_z+b_z, c_z+d_z,p,q) !
! between ( 0 ; 1) ! $I_x1(a_x+b_x, c_x+d_x,p,q) \, I_x1(a_y+b_y, c_y+d_y,p,q) \, I_x1(a_z+b_z, c_z+d_z,p,q)$
!
! between $( 0 ; 1)$
END_DOC END_DOC

View File

@ -641,9 +641,10 @@ end
subroutine integrale_new(I_f,a_x,b_x,c_x,d_x,a_y,b_y,c_y,d_y,a_z,b_z,c_z,d_z,p,q,n_pt) subroutine integrale_new(I_f,a_x,b_x,c_x,d_x,a_y,b_y,c_y,d_y,a_z,b_z,c_z,d_z,p,q,n_pt)
BEGIN_DOC BEGIN_DOC
! calculate the integral of the polynom :: ! Calculates the integral of the polynomial :
! I_x1(a_x+b_x, c_x+d_x,p,q) * I_x1(a_y+b_y, c_y+d_y,p,q) * I_x1(a_z+b_z, c_z+d_z,p,q) !
! between ( 0 ; 1) ! $I_{x_1}(a_x+b_x,c_x+d_x,p,q) \, I_{x_1}(a_y+b_y,c_y+d_y,p,q) \, I_{x_1}(a_z+b_z,c_z+d_z,p,q)$
! in $( 0 ; 1)$
END_DOC END_DOC
@ -775,8 +776,9 @@ integer function n_pt_sup(a_x,b_x,c_x,d_x,a_y,b_y,c_y,d_y,a_z,b_z,c_z,d_z)
implicit none implicit none
BEGIN_DOC BEGIN_DOC
! Returns the upper boundary of the degree of the polynomial involved in the ! Returns the upper boundary of the degree of the polynomial involved in the
! bielctronic integral : ! two-electron integral :
! Ix(a_x,b_x,c_x,d_x) * Iy(a_y,b_y,c_y,d_y) * Iz(a_z,b_z,c_z,d_z) !
! $I_x(a_x,b_x,c_x,d_x) \, I_y(a_y,b_y,c_y,d_y) \, I_z(a_z,b_z,c_z,d_z)$
END_DOC END_DOC
integer :: a_x,b_x,c_x,d_x,a_y,b_y,c_y,d_y,a_z,b_z,c_z,d_z integer :: a_x,b_x,c_x,d_x,a_y,b_y,c_y,d_y,a_z,b_z,c_z,d_z
n_pt_sup = shiftl( a_x+b_x+c_x+d_x + a_y+b_y+c_y+d_y + a_z+b_z+c_z+d_z,1 ) n_pt_sup = shiftl( a_x+b_x+c_x+d_x + a_y+b_y+c_y+d_y + a_z+b_z+c_z+d_z,1 )
@ -790,7 +792,8 @@ subroutine give_polynom_mult_center_x(P_center,Q_center,a_x,d_x,p,q,n_pt_in,pq_i
BEGIN_DOC BEGIN_DOC
! subroutine that returns the explicit polynom in term of the "t" ! subroutine that returns the explicit polynom in term of the "t"
! variable of the following polynomw : ! variable of the following polynomw :
! I_x1(a_x, d_x,p,q) * I_x1(a_y, d_y,p,q) * I_x1(a_z, d_z,p,q) !
! $I_{x_1}(a_x,d_x,p,q) \, I_{x_1}(a_y,d_y,p,q) \ I_{x_1}(a_z,d_z,p,q)$
END_DOC END_DOC
integer, intent(in) :: n_pt_in integer, intent(in) :: n_pt_in
integer,intent(out) :: n_pt_out integer,intent(out) :: n_pt_out
@ -851,7 +854,7 @@ end
subroutine I_x1_pol_mult(a,c,B_10,B_01,B_00,C_00,D_00,d,nd,n_pt_in) subroutine I_x1_pol_mult(a,c,B_10,B_01,B_00,C_00,D_00,d,nd,n_pt_in)
implicit none implicit none
BEGIN_DOC BEGIN_DOC
! recursive function involved in the two-electron integral ! Recursive function involved in the two-electron integral
END_DOC END_DOC
integer , intent(in) :: n_pt_in integer , intent(in) :: n_pt_in
include 'utils/constants.include.F' include 'utils/constants.include.F'
@ -885,7 +888,7 @@ end
recursive subroutine I_x1_pol_mult_recurs(a,c,B_10,B_01,B_00,C_00,D_00,d,nd,n_pt_in) recursive subroutine I_x1_pol_mult_recurs(a,c,B_10,B_01,B_00,C_00,D_00,d,nd,n_pt_in)
implicit none implicit none
BEGIN_DOC BEGIN_DOC
! recursive function involved in the two-electron integral ! Recursive function involved in the two-electron integral
END_DOC END_DOC
integer , intent(in) :: n_pt_in integer , intent(in) :: n_pt_in
include 'utils/constants.include.F' include 'utils/constants.include.F'
@ -966,7 +969,7 @@ end
recursive subroutine I_x1_pol_mult_a1(c,B_10,B_01,B_00,C_00,D_00,d,nd,n_pt_in) recursive subroutine I_x1_pol_mult_a1(c,B_10,B_01,B_00,C_00,D_00,d,nd,n_pt_in)
implicit none implicit none
BEGIN_DOC BEGIN_DOC
! recursive function involved in the two-electron integral ! Recursive function involved in the two-electron integral
END_DOC END_DOC
integer , intent(in) :: n_pt_in integer , intent(in) :: n_pt_in
include 'utils/constants.include.F' include 'utils/constants.include.F'
@ -1017,7 +1020,7 @@ end
recursive subroutine I_x1_pol_mult_a2(c,B_10,B_01,B_00,C_00,D_00,d,nd,n_pt_in) recursive subroutine I_x1_pol_mult_a2(c,B_10,B_01,B_00,C_00,D_00,d,nd,n_pt_in)
implicit none implicit none
BEGIN_DOC BEGIN_DOC
! recursive function involved in the two-electron integral ! Recursive function involved in the two-electron integral
END_DOC END_DOC
integer , intent(in) :: n_pt_in integer , intent(in) :: n_pt_in
include 'utils/constants.include.F' include 'utils/constants.include.F'
@ -1075,7 +1078,7 @@ end
recursive subroutine I_x2_pol_mult(c,B_10,B_01,B_00,C_00,D_00,d,nd,dim) recursive subroutine I_x2_pol_mult(c,B_10,B_01,B_00,C_00,D_00,d,nd,dim)
implicit none implicit none
BEGIN_DOC BEGIN_DOC
! recursive function involved in the two-electron integral ! Recursive function involved in the two-electron integral
END_DOC END_DOC
integer , intent(in) :: dim integer , intent(in) :: dim
include 'utils/constants.include.F' include 'utils/constants.include.F'

View File

@ -4,18 +4,19 @@ aux_quantities
This module contains some global variables (such as densities and energies) This module contains some global variables (such as densities and energies)
which are stored in the EZFIO folder in a different place than determinants. which are stored in the |EZFIO| directory in a different place than determinants.
This is used in practice to store density matrices which can be obtained from This is used in practice to store density matrices which can be obtained from
any methods, as long as they are stored in the same MO basis which is used for any method, as long as they are stored in the same |MO| basis which is used for
the calculations. In |RSDFT| calculations, this can be done to perform damping the calculations. In |RSDFT| calculations, this can be done to perform damping
on the density in order to speed up convergence. on the density in order to speed up the convergence.
The main providers of that module are: The main providers of that module are:
* `data_one_e_dm_alpha_mo` and `data_one_e_dm_beta_mo` which are the * :c:data:`data_one_e_dm_alpha_mo` and :c:data:`data_one_e_dm_beta_mo` which
one-body alpha and beta densities which are necessary read from the EZFIO are the one-body alpha and beta densities which are necessary read from the
folder. |EZFIO| directory.
Thanks to these providers you can use any density matrix that does not Thanks to these providers you can use any density matrix that does not
necessary corresponds to that of the current wave function. necessarily corresponds to that of the current wave function.

View File

@ -43,7 +43,7 @@ By default, the program will stop when more than one million determinants have
been selected, or when the |PT2| energy is below :math:`10^{-4}`. been selected, or when the |PT2| energy is below :math:`10^{-4}`.
The variational and |PT2| energies of the iterations are stored in the The variational and |PT2| energies of the iterations are stored in the
|EZFIO| database, in the :ref:`iterations` module. |EZFIO| database, in the :ref:`module_iterations` module.

View File

@ -330,8 +330,7 @@ subroutine pt2_slave_inproc(i)
end end
subroutine pt2_collector(zmq_socket_pull, E, relative_error, pt2, error, & subroutine pt2_collector(zmq_socket_pull, E, relative_error, pt2, error, variance, norm, b, N_)
variance, norm, b, N_)
use f77_zmq use f77_zmq
use selection_types use selection_types
use bitmasks use bitmasks

View File

@ -2,34 +2,39 @@
cis cis
=== ===
This module contains a CIS program. This module contains a |CIS| program.
The user point of view The user point of view
---------------------- ----------------------
The :command:`cis` program performs the CI of the ROHF-like + all single excitations on top of it. The :ref:`cis` program performs the CI to obtain the ROHF reference + all
This program can be very useful to : single excitations on top of it. This program can be very useful to:
* **Ground state calculations**: generate a guess for the ground state wave function if one is not sure that the :c:func:`scf` program gave the lowest SCF solution. In combination with :c:func:`save_natorb` it can produce new |MOs| in order to reperform an :c:func:`scf` optimization. * **Ground state calculations**: generate a guess for the ground state wave
function if one is not sure that the :ref:`scf` program gave the lowest |SCF|
solution. In combination with :ref:`save_natorb` it can produce new |MOs| in
order to reperform an :ref:`scf` optimization.
* **Excited states calculations**: generate guess for all the :option:`determinants n_states` wave functions, that will be used by the :c:func:`fci` program. * **Excited states calculations**: generate guesses for all the
:option:`determinants n_states` wave functions, that will be used by the
:ref:`fci` program.
The main keywords/options to be used are: The main keywords/options to be used are:
* :option:`determinants n_states` : number of states to consider for the |CIS| calculation * :option:`determinants n_states`: number of states to consider for the |CIS| calculation
* :option:`determinants s2_eig` : force all states to have the desired value of :math:`S^2` * :option:`determinants s2_eig`: force all states to have the desired value of |S^2|
* :option:`determinants expected_s2` : desired value of :math:`S^2` * :option:`determinants expected_s2`: desired value of |S^2|
The programmer point of view The programmer's point of view
---------------------------- ------------------------------
This module have been built by setting the following rules: This module was built by setting the following rules:
* The only generator determinant is the Hartree-Fock (single-reference method) * The only generator determinant is the Hartree-Fock (single-reference method)
* All generated singly excited determinants are included in the wave function (no perturbative * All generated singly excited determinants are included in the wave function (no perturbative

View File

@ -1,55 +1,52 @@
program cis program cis
implicit none implicit none
BEGIN_DOC BEGIN_DOC
! !
! Configuration Interaction with Single excitations. ! Configuration Interaction with Single excitations.
! !
! This program takes a reference Slater determinant of ROHF-like ! This program takes a reference Slater determinant of ROHF-like
! occupancy, and performs all single excitations on top of it. ! occupancy, and performs all single excitations on top of it.
! Disregarding spatial symmetry, it computes the `n_states` lowest ! Disregarding spatial symmetry, it computes the `n_states` lowest
! eigenstates of that CI matrix. (see :option:`determinants n_states`) ! eigenstates of that CI matrix. (see :option:`determinants n_states`)
! !
! This program can be useful in many cases: ! This program can be useful in many cases:
! !
! !
! Ground state calculation ! 1. Ground state calculation
! ------------------------ !
! ! To be sure to have the lowest |SCF| solution, perform an :ref:`scf`
! To be sure to have the lowest |SCF| solution, perform an :ref:`scf` ! (see the :ref:`module_hartree_fock` module), then a :ref:`cis`, save the
! (see the :ref:`hartree_fock` module), then a :ref:`cis`, save ! natural orbitals (see :ref:`save_natorb`) and re-run an :ref:`scf`
! the natural orbitals (see :ref:`save_natorb`) and re-run an ! optimization from this |MO| guess.
! :ref:`scf` optimization from this |MO| guess. !
! !
! ! 2. Excited states calculations
! Excited states calculations !
! --------------------------- ! The lowest excited states are much likely to be dominated by
! ! single-excitations. Therefore, running a :ref:`cis` will save the
! The lowest excited states are much likely to be dominated by ! `n_states` lowest states within the |CIS| space in the |EZFIO|
! single-excitations. Therefore, running a :ref:`cis` will save ! directory, which can afterwards be used as guess wave functions for
! the `n_states` lowest states within the |CIS| space in the |EZFIO| ! a further multi-state |FCI| calculation if :option:`determinants
! directory, which can afterwards be used as guess wave functions for ! read_wf` is set to |true| before running the :ref:`fci` executable.
! a further multi-state |FCI| calculation if :option:`determinants read_wf` !
! is set to |true| before running the :ref:`fci` !
! executable. ! If :option:`determinants s2_eig` is set to |true|, the |CIS|
! ! will only retain states having the expected |S^2| value (see
! ! :option:`determinants expected_s2`). Otherwise, the |CIS| will take
! If :option:`determinants s2_eig` is set to |true|, the |CIS| ! the lowest :option:`determinants n_states`, whatever multiplicity
! will only retain states having the expected |S^2| value (see ! they are.
! :option:`determinants expected_s2`). Otherwise, the |CIS| will take !
! the lowest :option:`determinants n_states`, whatever multiplicity ! .. note::
! they are. !
! ! To discard some orbitals, use the :ref:`qp_set_mo_class`
! .. note:: ! command to specify:
! !
! To discard some orbitals, use the :ref:`qp_set_mo_class` ! * *core* orbitals which will be always doubly occupied
! command to specify: !
! ! * *act* orbitals where an electron can be either excited from or to
! * *core* orbitals which will be always doubly occupied !
! ! * *del* orbitals which will be never occupied
! * *act* orbitals where an electron can be either excited from or to !
!
! * *del* orbitals which will be never occupied
!
END_DOC END_DOC
read_wf = .False. read_wf = .False.
SOFT_TOUCH read_wf SOFT_TOUCH read_wf

View File

@ -11,7 +11,7 @@ program cisd
! !
! This program can be useful in many cases: ! This program can be useful in many cases:
! !
! * GROUND STATE CALCULATION: if even after a :c:func:`cis` calculation, natural ! * **Ground state calculation**: if even after a :c:func:`cis` calculation, natural
! orbitals (see :c:func:`save_natorb`) and then :c:func:`scf` optimization, you are not sure to have the lowest scf ! orbitals (see :c:func:`save_natorb`) and then :c:func:`scf` optimization, you are not sure to have the lowest scf
! solution, ! solution,
! do the same strategy with the :c:func:`cisd` executable instead of the :c:func:`cis` exectuable to generate the natural ! do the same strategy with the :c:func:`cisd` executable instead of the :c:func:`cis` exectuable to generate the natural
@ -19,11 +19,11 @@ program cisd
! !
! !
! !
! * EXCITED STATES CALCULATIONS: the lowest excited states are much likely to ! * **Excited states calculations**: the lowest excited states are much likely to
! be dominanted by single- or double-excitations. ! be dominanted by single- or double-excitations.
! Therefore, running a :c:func:`cisd` will save the "n_states" lowest states within ! Therefore, running a :c:func:`cisd` will save the "n_states" lowest states within
! the CISD space ! the CISD space
! in the EZFIO folder, which can afterward be used as guess wave functions ! in the |EZFIO| directory, which can afterward be used as guess wave functions
! for a further multi-state fci calculation if you specify "read_wf" = True ! for a further multi-state fci calculation if you specify "read_wf" = True
! before running the fci executable (see :option:`determinants read_wf`). ! before running the fci executable (see :option:`determinants read_wf`).
! Also, if you specify "s2_eig" = True, the cisd will only retain states ! Also, if you specify "s2_eig" = True, the cisd will only retain states

View File

@ -3,12 +3,19 @@ davidson
======== ========
Abstract module for Davidson's diagonalization. Abstract module for Davidson's diagonalization.
It contains everything required for the Davidson algorithm, dressed or not. If It contains everything required for the Davidson algorithm, dressed or
a dressing is used, the dressing column should be defined and the not. If a dressing is used, the dressing column should be defined and
:ref:`davidson_dressed` module should be used. If no dressing is required, the :ref:`module_davidson_dressed` module should be used. If no dressing
the :ref:`davidson` module should be used, and it has a default zero dressing vector. is required, the :ref:`module_davidson` module should be used, and it
has a default zero dressing vector.
The important providers for that module are: The important providers for that module are:
# `psi_energy` which is the expectation value over the wave function (`psi_det`, `psi_coef`) of the Hamiltonian, dressed or not. It uses the general subroutine `u_0_H_u_0`. #. :c:data:`psi_energy` which is the expectation value over the wave
# `psi_energy_two_e` which is the expectation value over the wave function (`psi_det`, `psi_coef`) of the standard two-electrons coulomb operator. It uses the general routine `u_0_H_u_0_two_e`. function (:c:data:`psi_det`, :c:data:`psi_coef`) of the Hamiltonian,
dressed or not. It uses the general subroutine :c:func:`u_0_H_u_0`.
#. :c:data:`psi_energy_two_e` which is the expectation value over the
wave function (:c:data:`psi_det`, :c:data:`psi_coef`) of the standard
two-electron Coulomb operator. It uses the general routine
:c:func:`u_0_H_u_0_two_e`.

View File

@ -51,6 +51,12 @@ subroutine davidson_run_slave(thread,iproc)
doexit=1 doexit=1
endif endif
endif endif
doexit = receive
IRP_ENDIF
if (doexit>0) then
call end_zmq_to_qp_run_socket(zmq_to_qp_run_socket)
return
endif
IRP_IF MPI IRP_IF MPI
include 'mpif.h' include 'mpif.h'
@ -187,7 +193,7 @@ subroutine davidson_push_results(zmq_socket_push, v_t, s_t, imin, imax, task_id)
use f77_zmq use f77_zmq
implicit none implicit none
BEGIN_DOC BEGIN_DOC
! Push the results of $H|U \rangle$ from a worker to the master. ! Push the results of $H | U \rangle$ from a worker to the master.
END_DOC END_DOC
integer(ZMQ_PTR) ,intent(in) :: zmq_socket_push integer(ZMQ_PTR) ,intent(in) :: zmq_socket_push
@ -233,7 +239,7 @@ subroutine davidson_pull_results(zmq_socket_pull, v_t, s_t, imin, imax, task_id)
use f77_zmq use f77_zmq
implicit none implicit none
BEGIN_DOC BEGIN_DOC
! Pull the results of $H|U \rangle$ on the master. ! Pull the results of $H | U \rangle$ on the master.
END_DOC END_DOC
integer(ZMQ_PTR) ,intent(in) :: zmq_socket_pull integer(ZMQ_PTR) ,intent(in) :: zmq_socket_pull
@ -324,13 +330,13 @@ subroutine H_S2_u_0_nstates_zmq(v_0,s_0,u_0,N_st,sze)
use f77_zmq use f77_zmq
implicit none implicit none
BEGIN_DOC BEGIN_DOC
! Computes $v_0 = H|u_0\rangle$ and $s_0 = S^2 |u_0\rangle$ ! Computes $v_0 = H | u_0\rangle$ and $s_0 = S^2 | u_0\rangle$
! !
! n : number of determinants ! n : number of determinants
! !
! H_jj : array of $\langle j|H|j \rangle$ ! H_jj : array of $\langle j | H | j \rangle$
! !
! S2_jj : array of $\langle j|S^2|j \rangle$ ! S2_jj : array of $\langle j | S^2 | j \rangle$
END_DOC END_DOC
integer, intent(in) :: N_st, sze integer, intent(in) :: N_st, sze
double precision, intent(out) :: v_0(sze,N_st), s_0(sze,N_st) double precision, intent(out) :: v_0(sze,N_st), s_0(sze,N_st)

View File

@ -27,9 +27,9 @@ subroutine u_0_H_u_0(e_0,s_0,u_0,n,keys_tmp,Nint,N_st,sze)
use bitmasks use bitmasks
implicit none implicit none
BEGIN_DOC BEGIN_DOC
! Computes $E_0 = \frac{\langle u_0|H|u_0 \rangle}{\langle u_0|u_0 \rangle}$ ! Computes $E_0 = \frac{\langle u_0 | H | u_0 \rangle}{\langle u_0 | u_0 \rangle}$
! !
! and $S_0 = \frac{\langle u_0|S^2|u_0 \rangle}{\langle u_0|u_0 \rangle}$ ! and $S_0 = \frac{\langle u_0 | S^2 | u_0 \rangle}{\langle u_0 | u_0 \rangle}$
! !
! n : number of determinants ! n : number of determinants
! !
@ -80,7 +80,7 @@ subroutine H_S2_u_0_nstates_openmp(v_0,s_0,u_0,N_st,sze)
use bitmasks use bitmasks
implicit none implicit none
BEGIN_DOC BEGIN_DOC
! Computes $v_0 = H|u_0\rangle$ and $s_0 = S^2 |u_0\rangle$. ! Computes $v_0 = H | u_0\rangle$ and $s_0 = S^2 | u_0\rangle$.
! !
! Assumes that the determinants are in psi_det ! Assumes that the determinants are in psi_det
! !
@ -135,7 +135,7 @@ subroutine H_S2_u_0_nstates_openmp_work(v_t,s_t,u_t,N_st,sze,istart,iend,ishift,
use bitmasks use bitmasks
implicit none implicit none
BEGIN_DOC BEGIN_DOC
! Computes $v_t = H|u_t\rangle$ and $s_t = S^2 |u_t\rangle$ ! Computes $v_t = H | u_t\rangle$ and $s_t = S^2 | u_t\rangle$
! !
! Default should be 1,N_det,0,1 ! Default should be 1,N_det,0,1
END_DOC END_DOC
@ -165,7 +165,7 @@ subroutine H_S2_u_0_nstates_openmp_work_$N_int(v_t,s_t,u_t,N_st,sze,istart,iend,
use bitmasks use bitmasks
implicit none implicit none
BEGIN_DOC BEGIN_DOC
! Computes $v_t = H|u_t\rangle$ and $s_t = S^2 |u_t\rangle$ ! Computes $v_t = H | u_t \\rangle$ and $s_t = S^2 | u_t\\rangle$
! !
! Default should be 1,N_det,0,1 ! Default should be 1,N_det,0,1
END_DOC END_DOC

View File

@ -15,7 +15,7 @@ subroutine H_S2_u_0_two_e_nstates_openmp(v_0,s_0,u_0,N_st,sze)
use bitmasks use bitmasks
implicit none implicit none
BEGIN_DOC BEGIN_DOC
! Computes $v_0 = H|u_0\rangle$ and $s_0 = S^2 |u_0\rangle$ ! Computes $v_0 = H | u_0\rangle$ and $s_0 = S^2 | u_0\rangle$
! !
! Assumes that the determinants are in psi_det ! Assumes that the determinants are in psi_det
! !
@ -69,7 +69,7 @@ subroutine H_S2_u_0_two_e_nstates_openmp_work(v_t,s_t,u_t,N_st,sze,istart,iend,i
use bitmasks use bitmasks
implicit none implicit none
BEGIN_DOC BEGIN_DOC
! Computes $v_t = H|u_t\rangle$ and $s_t = S^2 |u_t\rangle$ ! Computes $v_t = H | u_t\rangle$ and $s_t = S^2 | u_t\rangle$
! !
! Default should be 1,N_det,0,1 ! Default should be 1,N_det,0,1
END_DOC END_DOC
@ -99,7 +99,7 @@ subroutine H_S2_u_0_two_e_nstates_openmp_work_$N_int(v_t,s_t,u_t,N_st,sze,istart
use bitmasks use bitmasks
implicit none implicit none
BEGIN_DOC BEGIN_DOC
! Computes $v_t = H|u_t\rangle$ and $s_t = S^2 |u_t\rangle$ ! Computes $v_t = H | u_t \\rangle$ and $s_t = S^2 | u_t \\rangle$
! !
! Default should be 1,N_det,0,1 ! Default should be 1,N_det,0,1
END_DOC END_DOC
@ -461,7 +461,7 @@ subroutine u_0_H_u_0_two_e(e_0,u_0,n,keys_tmp,Nint,N_st,sze)
use bitmasks use bitmasks
implicit none implicit none
BEGIN_DOC BEGIN_DOC
! Computes $E_0 = \frac{ \langle u_0|H|u_0\rangle}{\langle u_0|u_0 \rangle}$. ! Computes $E_0 = \frac{ \langle u_0 | H | u_0\rangle}{\langle u_0 | u_0 \rangle}$.
! !
! n : number of determinants ! n : number of determinants
! !

View File

@ -3,10 +3,14 @@ density_for_dft
=============== ===============
This module defines the *provider* of the density used for the DFT related calculations. This module defines the *provider* of the density used for the |DFT| related
This definition is done through the keyword :option:`density_for_dft density_for_dft`. calculations. This definition is done through the keyword
The density can be: :option:`density_for_dft density_for_dft`. The density can be:
* WFT : the density is computed with a potentially multi determinant wave function (see variables `psi_det` and `psi_det`)# input_density : the density is set to a density previously stored in the |EZFIO| folder (see ``aux_quantities``) * `WFT`: the density is computed with a potentially multi determinant wave
* damping_rs_dft : the density is damped between the input_density and the WFT density, with a damping factor of :option:`density_for_dft damping_for_rs_dft` function (see variables `psi_det` and `psi_det`)# input_density: the density
is set to a density previously stored in the |EZFIO| directory (see
``aux_quantities``)
* `damping_rs_dft`: the density is damped between the input_density and the WFT
density, with a damping factor of :option:`density_for_dft damping_for_rs_dft`

View File

@ -48,12 +48,12 @@ default: 0.99
[n_int] [n_int]
interface: ezfio interface: ezfio
doc: Number of integers required to represent bitstrings (set in module :ref:`bitmask`) doc: Number of integers required to represent bitstrings (set in module :ref:`module_bitmask`)
type: N_int_number type: N_int_number
[bit_kind] [bit_kind]
interface: ezfio interface: ezfio
doc: (set in module :ref:`bitmask`) doc: (set in module :ref:`module_bitmask`)
type: Bit_kind type: Bit_kind
[mo_label] [mo_label]

View File

@ -7,15 +7,15 @@ Contains everything for the computation of the Hamiltonian matrix elements in th
The main providers for this module are: The main providers for this module are:
* :option:`determinants n_states`: number of states to be computed * :option:`determinants n_states`: number of states to be computed
* `psi_det`: list of determinants in the wave function used in many routines/providers of the |QP|. * :c:data:`psi_det`: list of determinants in the wave function used in many routines/providers of the |QP|.
* `psi_coef`: list of coefficients, for all :option:`determinants n_states` states, and all determinants. * :c:data:`psi_coef`: list of coefficients, for all :option:`determinants n_states` states, and all determinants.
The main routines for this module are: The main routines for this module are:
* `i_H_j`: computes the Hamiltonian matrix element between two arbitrary Slater determinants. * :c:func:`i_H_j`: computes the Hamiltonian matrix element between two arbitrary Slater determinants.
* `i_H_j_s2`: computes the Hamiltonian and (:math:`S^2`) matrix element between two arbitrary Slater determinants. * :c:func:`i_H_j_s2`: computes the Hamiltonian and (|S^2|) matrix element between two arbitrary Slater determinants.
* `i_H_j_verbose`: returns the decomposition in terms of one- and two-body components of the Hamiltonian matrix elements between two arbitrary Slater determinants. Also return the fermionic phase factor. * :c:func:`i_H_j_verbose`: returns the decomposition in terms of one- and two-body components of the Hamiltonian matrix elements between two arbitrary Slater determinants. Also return the fermionic phase factor.
* `i_H_psi`: computes the Hamiltonian matrix element between an arbitrary Slater determinant and a wave function composed of a sum of arbitrary Slater determinants. * :c:func:`i_H_psi`: computes the Hamiltonian matrix element between an arbitrary Slater determinant and a wave function composed of a sum of arbitrary Slater determinants.
For an example of how to use these routines and providers, take a look at :file:`example.irp.f`. For an example of how to use these routines and providers, take a look at :file:`example.irp.f`.

View File

@ -105,7 +105,7 @@ subroutine example_determinants_psi_det
END_DOC END_DOC
read_wf = .True. read_wf = .True.
touch read_wf touch read_wf
! you force the wave function to be set to the one in the EZFIO folder ! you force the wave function to be set to the one in the EZFIO directory
call routine_example_psi_det call routine_example_psi_det
end end

View File

@ -54,13 +54,19 @@ end
subroutine density_and_grad_alpha_beta_and_all_aos_and_grad_aos_at_r(r,dm_a,dm_b, grad_dm_a, grad_dm_b, aos_array, grad_aos_array) subroutine density_and_grad_alpha_beta_and_all_aos_and_grad_aos_at_r(r,dm_a,dm_b, grad_dm_a, grad_dm_b, aos_array, grad_aos_array)
implicit none implicit none
BEGIN_DOC BEGIN_DOC
! input : r(1) ==> r(1) = x, r(2) = y, r(3) = z ! input:
! output : dm_a = alpha density evaluated at r !
! : dm_b = beta density evaluated at r ! * r(1) ==> r(1) = x, r(2) = y, r(3) = z
! : aos_array(i) = ao(i) evaluated at r !
! : grad_dm_a(1) = X gradient of the alpha density evaluated in r ! output:
! : grad_dm_a(1) = X gradient of the beta density evaluated in r !
! : grad_aos_array(1) = X gradient of the aos(i) evaluated at r ! * dm_a = alpha density evaluated at r
! * dm_b = beta density evaluated at r
! * aos_array(i) = ao(i) evaluated at r
! * grad_dm_a(1) = X gradient of the alpha density evaluated in r
! * grad_dm_a(1) = X gradient of the beta density evaluated in r
! * grad_aos_array(1) = X gradient of the aos(i) evaluated at r
!
END_DOC END_DOC
double precision, intent(in) :: r(3) double precision, intent(in) :: r(3)
double precision, intent(out) :: dm_a(N_states),dm_b(N_states) double precision, intent(out) :: dm_a(N_states),dm_b(N_states)

View File

@ -9,42 +9,51 @@ fci
The user point of view The user point of view
---------------------- ----------------------
* :c:func:`fci` performs |CIPSI| calculations using a stochastic scheme for both the selection and the |PT2| contribution, * :ref:`fci` performs |CIPSI| calculations using a stochastic scheme for both
* :c:func:`pt2` computes the |PT2| contribution using the wave function stored in the |EZFIO| the selection and the |PT2| contribution,
database.
* :ref:`pt2` computes the |PT2| contribution using the wave function stored in
the |EZFIO| database.
The main keywords/options for this module are: The main keywords/options for this module are:
* :option:`determinants n_det_max` : maximum number of Slater determinants in the CIPSI wave function. The :command:`fci` program will stop when the size of the CIPSI wave function will exceed :option:`determinants n_det_max`. * :option:`determinants n_det_max` : maximum number of Slater determinants in
the |CIPSI| wave function. The :ref:`fci` program will stop when the size of
the |CIPSI| wave function will exceed :option:`determinants n_det_max`.
* :option:`perturbation pt2_max` : absolute value of the |PT2| to stop the CIPSI calculation. Once the |PT2| :math:`<` :option:`perturbation pt2_max`, the CIPSI calculation stops. * :option:`perturbation pt2_max` : absolute value of the |PT2| to stop the
|CIPSI| calculation. Once the abs(|PT2|) :math:`<` :option:`perturbation pt2_max`,
the |CIPSI| calculation stops.
* :option:`determinants n_states` : number of states to consider in the CIPSI calculation. * :option:`determinants n_states` : number of states to consider in the |CIPSI|
calculation.
* :option:`determinants read_wf` : if False, starts with a ROHF-like determinant, if True, starts with the current wave function(s) stored in the |EZFIO| folder. * :option:`determinants read_wf` : if |false|, starts with a |ROHF|-like
determinant, if |true|, starts with the current wave function(s) stored in
the |EZFIO| directory.
.. note:: .. note::
For a multi-state calculation, it is recommended to start with :c:func:`cis` or :c:func:`cisd` For a multi-state calculation, it is recommended to start with :ref:`cis`
wave functions as a guess. or :ref:`cisd` wave functions as a guess.
* :option:`determinants s2_eig` : if True, systematically add all the determinants needed to have a pure value of :math:`S^2`. Also, if True, it tracks only the states having the good :option:`determinants expected_s2`. * :option:`determinants expected_s2` : expected value of |S^2| for the
desired spin multiplicity.
.. note:: * :option:`determinants s2_eig` : if |true|, systematically add all the
For a multi-state calculation, it is recommended to start with :c:func:`cis` or :c:func:`cisd` determinants needed to have a pure value of |S^2|. Also, if |true|, it
wave functions as a guess. tracks only the states having the good :option:`determinants expected_s2`.
* :option:`determinants expected_s2` : expected value of :math:`S^2` for the desired spin multiplicity.
The programmer point of view
----------------------------
This module have been created with the :ref:`cipsi` module. The programmer's point of view
------------------------------
This module was created with the :ref:`module_cipsi` module.
.. seealso:: .. seealso::
The documentation of the :ref:`cipsi` module. The documentation of the :ref:`module_cipsi` module.

View File

@ -13,7 +13,7 @@ program fci
! conditions: ! conditions:
! !
! * number of Slater determinants > :option:`determinants n_det_max` ! * number of Slater determinants > :option:`determinants n_det_max`
! * |PT2| < :option:`perturbation pt2_max` ! * abs(|PT2|) less than :option:`perturbation pt2_max`
! !
! The following other options can be of interest: ! The following other options can be of interest:
! !
@ -30,7 +30,7 @@ program fci
! :option:`determinants expected_s2`. ! :option:`determinants expected_s2`.
! !
! For excited states calculations, it is recommended to start with ! For excited states calculations, it is recommended to start with
! :ref:`.cis.` or :ref:`.cisd.` guess wave functions, eventually in ! :ref:`cis` or :ref:`cisd` guess wave functions, eventually in
! a restricted set of |MOs|, and to set :option:`determinants s2_eig` ! a restricted set of |MOs|, and to set :option:`determinants s2_eig`
! to |true|. ! to |true|.
! !

View File

@ -1,13 +1,18 @@
program pt2 program pt2
implicit none implicit none
BEGIN_DOC BEGIN_DOC
! Second order perturbative correction to the wave function contained in the EZFIO directory. ! Second order perturbative correction to the wave function contained
! in the |EZFIO| directory.
! !
! This programs runs the stochastic PT2 correction on all "n_states" wave function stored in the EZFIO folder (see :option:`determinant n_states`). ! This programs runs the stochastic |PT2| correction on all
! :option:`determinants n_states` wave functions stored in the |EZFIO|
! directory.
! !
! The option for the PT2 correction are the "pt2_relative_error" which is the relative stochastic ! The main option for the |PT2| correction is the
! :option:`perturbation pt2_relative_error` which is the relative
! stochastic error on the |PT2| to reach before stopping the
! sampling.
! !
! error on the PT2 to reach before stopping the stochastic sampling. (see :option:`perturbation pt2_relative_error`)
END_DOC END_DOC
if (.not. is_zmq_slave) then if (.not. is_zmq_slave) then
read_wf = .True. read_wf = .True.

Some files were not shown because too many files have changed in this diff Show More