mirror of
https://github.com/LCPQ/quantum_package
synced 2024-11-08 07:03:57 +01:00
commit
b2f3982486
@ -91,7 +91,10 @@ let run ?o b c d m p xyz_file =
|
|||||||
in
|
in
|
||||||
|
|
||||||
|
|
||||||
let basis_table = Hashtbl.Poly.create () in
|
let basis_table =
|
||||||
|
Hashtbl.Poly.create ()
|
||||||
|
in
|
||||||
|
|
||||||
(* Open basis set channels *)
|
(* Open basis set channels *)
|
||||||
let basis_channel element =
|
let basis_channel element =
|
||||||
let key =
|
let key =
|
||||||
@ -115,13 +118,7 @@ let run ?o b c d m p xyz_file =
|
|||||||
Sys.remove temp_filename
|
Sys.remove temp_filename
|
||||||
in
|
in
|
||||||
|
|
||||||
let rec build_basis = function
|
let fetch_channel basis =
|
||||||
| [] -> ()
|
|
||||||
| elem_and_basis_name :: rest ->
|
|
||||||
begin
|
|
||||||
match (String.lsplit2 ~on:':' elem_and_basis_name) with
|
|
||||||
| None -> (* Principal basis *)
|
|
||||||
let basis = elem_and_basis_name in
|
|
||||||
let command =
|
let command =
|
||||||
if (p) then
|
if (p) then
|
||||||
Qpackage.root ^ "/scripts/get_basis.sh \"" ^ temp_filename
|
Qpackage.root ^ "/scripts/get_basis.sh \"" ^ temp_filename
|
||||||
@ -130,6 +127,10 @@ let run ?o b c d m p xyz_file =
|
|||||||
Qpackage.root ^ "/scripts/get_basis.sh \"" ^ temp_filename
|
Qpackage.root ^ "/scripts/get_basis.sh \"" ^ temp_filename
|
||||||
^ "." ^ basis ^ "\" \"" ^ basis ^"\""
|
^ "." ^ basis ^ "\" \"" ^ basis ^"\""
|
||||||
in
|
in
|
||||||
|
match Sys.is_file basis with
|
||||||
|
| `Yes ->
|
||||||
|
In_channel.create basis
|
||||||
|
| _ ->
|
||||||
begin
|
begin
|
||||||
let filename =
|
let filename =
|
||||||
Unix.open_process_in command
|
Unix.open_process_in command
|
||||||
@ -140,6 +141,23 @@ let run ?o b c d m p xyz_file =
|
|||||||
In_channel.create filename
|
In_channel.create filename
|
||||||
in
|
in
|
||||||
Unix.unlink filename;
|
Unix.unlink filename;
|
||||||
|
new_channel
|
||||||
|
end
|
||||||
|
in
|
||||||
|
|
||||||
|
let rec build_basis = function
|
||||||
|
| [] -> ()
|
||||||
|
| elem_and_basis_name :: rest ->
|
||||||
|
begin
|
||||||
|
match (String.lsplit2 ~on:':' elem_and_basis_name) with
|
||||||
|
| None -> (* Principal basis *)
|
||||||
|
begin
|
||||||
|
let basis =
|
||||||
|
elem_and_basis_name
|
||||||
|
in
|
||||||
|
let new_channel =
|
||||||
|
fetch_channel basis
|
||||||
|
in
|
||||||
List.iter nuclei ~f:(fun elem->
|
List.iter nuclei ~f:(fun elem->
|
||||||
let key =
|
let key =
|
||||||
Element.to_string elem.Atom.element
|
Element.to_string elem.Atom.element
|
||||||
@ -151,26 +169,18 @@ let run ?o b c d m p xyz_file =
|
|||||||
end
|
end
|
||||||
| Some (key, basis) -> (*Aux basis *)
|
| Some (key, basis) -> (*Aux basis *)
|
||||||
begin
|
begin
|
||||||
let elem = Element.of_string key
|
let elem =
|
||||||
and basis = String.lowercase basis
|
Element.of_string key
|
||||||
|
and basis =
|
||||||
|
String.lowercase basis
|
||||||
in
|
in
|
||||||
let key =
|
let key =
|
||||||
Element.to_string elem
|
Element.to_string elem
|
||||||
in
|
in
|
||||||
let command =
|
let new_channel =
|
||||||
Qpackage.root ^ "/scripts/get_basis.sh \"" ^ temp_filename
|
fetch_channel basis
|
||||||
^ "." ^ basis ^ "\" \"" ^ basis ^ "\" "
|
|
||||||
in
|
in
|
||||||
begin
|
begin
|
||||||
let filename =
|
|
||||||
Unix.open_process_in command
|
|
||||||
|> In_channel.input_all
|
|
||||||
|> String.strip
|
|
||||||
in
|
|
||||||
let new_channel =
|
|
||||||
In_channel.create filename
|
|
||||||
in
|
|
||||||
Unix.unlink filename;
|
|
||||||
match Hashtbl.add basis_table ~key:key ~data:new_channel with
|
match Hashtbl.add basis_table ~key:key ~data:new_channel with
|
||||||
| `Ok -> ()
|
| `Ok -> ()
|
||||||
| `Duplicate -> failwith ("Duplicate definition of basis for "^(Element.to_long_string elem))
|
| `Duplicate -> failwith ("Duplicate definition of basis for "^(Element.to_long_string elem))
|
||||||
@ -335,13 +345,15 @@ let command =
|
|||||||
Command.basic
|
Command.basic
|
||||||
~summary: "Quantum Package command"
|
~summary: "Quantum Package command"
|
||||||
~readme:(fun () -> "
|
~readme:(fun () -> "
|
||||||
Creates an EZFIO directory from a standard xyz file.
|
Creates an EZFIO directory from a standard xyz file. The basis set is defined
|
||||||
The basis set is defined as a single string if all the
|
as a single string if all the atoms are taken from the same basis set,
|
||||||
atoms are taken from the same basis set, otherwise specific
|
otherwise specific elements can be defined as follows:
|
||||||
elements can be defined as follows:
|
|
||||||
|
|
||||||
-b \"cc-pcvdz | H:cc-pvdz | C:6-31g\"
|
-b \"cc-pcvdz | H:cc-pvdz | C:6-31g\"
|
||||||
|
|
||||||
|
If a file with the same name as the basis set exists, this file will be read.
|
||||||
|
Otherwise, the basis set is obtained from the database.
|
||||||
|
|
||||||
")
|
")
|
||||||
spec
|
spec
|
||||||
(fun o b c d m p xyz_file () ->
|
(fun o b c d m p xyz_file () ->
|
||||||
|
@ -32,11 +32,11 @@ Documentation
|
|||||||
.. by the `update_README.py` script.
|
.. by the `update_README.py` script.
|
||||||
|
|
||||||
|
|
||||||
`ao_bi_elec_integral_alpha <http://github.com/LCPQ/quantum_package/tree/master/plugins/Hartree_Fock/Fock_matrix.irp.f#L102>`_
|
`ao_bi_elec_integral_alpha <http://github.com/LCPQ/quantum_package/tree/master/plugins/Hartree_Fock/Fock_matrix.irp.f#L107>`_
|
||||||
Alpha Fock matrix in AO basis set
|
Alpha Fock matrix in AO basis set
|
||||||
|
|
||||||
|
|
||||||
`ao_bi_elec_integral_beta <http://github.com/LCPQ/quantum_package/tree/master/plugins/Hartree_Fock/Fock_matrix.irp.f#L103>`_
|
`ao_bi_elec_integral_beta <http://github.com/LCPQ/quantum_package/tree/master/plugins/Hartree_Fock/Fock_matrix.irp.f#L108>`_
|
||||||
Alpha Fock matrix in AO basis set
|
Alpha Fock matrix in AO basis set
|
||||||
|
|
||||||
|
|
||||||
@ -62,23 +62,23 @@ Documentation
|
|||||||
Diagonal Fock matrix in the MO basis
|
Diagonal Fock matrix in the MO basis
|
||||||
|
|
||||||
|
|
||||||
`fock_matrix_alpha_ao <http://github.com/LCPQ/quantum_package/tree/master/plugins/Hartree_Fock/Fock_matrix.irp.f#L83>`_
|
`fock_matrix_alpha_ao <http://github.com/LCPQ/quantum_package/tree/master/plugins/Hartree_Fock/Fock_matrix.irp.f#L88>`_
|
||||||
Alpha Fock matrix in AO basis set
|
Alpha Fock matrix in AO basis set
|
||||||
|
|
||||||
|
|
||||||
`fock_matrix_alpha_mo <http://github.com/LCPQ/quantum_package/tree/master/plugins/Hartree_Fock/Fock_matrix.irp.f#L254>`_
|
`fock_matrix_alpha_mo <http://github.com/LCPQ/quantum_package/tree/master/plugins/Hartree_Fock/Fock_matrix.irp.f#L272>`_
|
||||||
Fock matrix on the MO basis
|
Fock matrix on the MO basis
|
||||||
|
|
||||||
|
|
||||||
`fock_matrix_ao <http://github.com/LCPQ/quantum_package/tree/master/plugins/Hartree_Fock/Fock_matrix.irp.f#L312>`_
|
`fock_matrix_ao <http://github.com/LCPQ/quantum_package/tree/master/plugins/Hartree_Fock/Fock_matrix.irp.f#L330>`_
|
||||||
Fock matrix in AO basis set
|
Fock matrix in AO basis set
|
||||||
|
|
||||||
|
|
||||||
`fock_matrix_beta_ao <http://github.com/LCPQ/quantum_package/tree/master/plugins/Hartree_Fock/Fock_matrix.irp.f#L84>`_
|
`fock_matrix_beta_ao <http://github.com/LCPQ/quantum_package/tree/master/plugins/Hartree_Fock/Fock_matrix.irp.f#L89>`_
|
||||||
Alpha Fock matrix in AO basis set
|
Alpha Fock matrix in AO basis set
|
||||||
|
|
||||||
|
|
||||||
`fock_matrix_beta_mo <http://github.com/LCPQ/quantum_package/tree/master/plugins/Hartree_Fock/Fock_matrix.irp.f#L274>`_
|
`fock_matrix_beta_mo <http://github.com/LCPQ/quantum_package/tree/master/plugins/Hartree_Fock/Fock_matrix.irp.f#L292>`_
|
||||||
Fock matrix on the MO basis
|
Fock matrix on the MO basis
|
||||||
|
|
||||||
|
|
||||||
@ -114,7 +114,7 @@ Documentation
|
|||||||
.br
|
.br
|
||||||
|
|
||||||
|
|
||||||
`fock_mo_to_ao <http://github.com/LCPQ/quantum_package/tree/master/plugins/Hartree_Fock/Fock_matrix.irp.f#L355>`_
|
`fock_mo_to_ao <http://github.com/LCPQ/quantum_package/tree/master/plugins/Hartree_Fock/Fock_matrix.irp.f#L375>`_
|
||||||
Undocumented
|
Undocumented
|
||||||
|
|
||||||
|
|
||||||
@ -134,7 +134,7 @@ Documentation
|
|||||||
S^-1 Beta density matrix in the AO basis x S^-1
|
S^-1 Beta density matrix in the AO basis x S^-1
|
||||||
|
|
||||||
|
|
||||||
`hf_energy <http://github.com/LCPQ/quantum_package/tree/master/plugins/Hartree_Fock/Fock_matrix.irp.f#L293>`_
|
`hf_energy <http://github.com/LCPQ/quantum_package/tree/master/plugins/Hartree_Fock/Fock_matrix.irp.f#L311>`_
|
||||||
Hartree-Fock energy
|
Hartree-Fock energy
|
||||||
|
|
||||||
|
|
||||||
@ -142,7 +142,11 @@ Documentation
|
|||||||
Build the MOs using the extended Huckel model
|
Build the MOs using the extended Huckel model
|
||||||
|
|
||||||
|
|
||||||
`mo_guess_type <http://github.com/LCPQ/quantum_package/tree/master/plugins/Hartree_Fock/ezfio_interface.irp.f#L28>`_
|
`level_shift <http://github.com/LCPQ/quantum_package/tree/master/plugins/Hartree_Fock/ezfio_interface.irp.f#L28>`_
|
||||||
|
Energy shift on the virtual MOs to improve SCF convergence
|
||||||
|
|
||||||
|
|
||||||
|
`mo_guess_type <http://github.com/LCPQ/quantum_package/tree/master/plugins/Hartree_Fock/ezfio_interface.irp.f#L50>`_
|
||||||
Initial MO guess. Can be [ Huckel | HCore ]
|
Initial MO guess. Can be [ Huckel | HCore ]
|
||||||
|
|
||||||
|
|
||||||
@ -161,6 +165,6 @@ Documentation
|
|||||||
optional: mo_basis.mo_coef
|
optional: mo_basis.mo_coef
|
||||||
|
|
||||||
|
|
||||||
`thresh_scf <http://github.com/LCPQ/quantum_package/tree/master/plugins/Hartree_Fock/ezfio_interface.irp.f#L46>`_
|
`thresh_scf <http://github.com/LCPQ/quantum_package/tree/master/plugins/Hartree_Fock/ezfio_interface.irp.f#L68>`_
|
||||||
Threshold on the convergence of the Hartree Fock energy
|
Threshold on the convergence of the Hartree Fock energy
|
||||||
|
|
||||||
|
@ -90,10 +90,6 @@ Documentation
|
|||||||
N_states lowest eigenvalues of the dressed CI matrix
|
N_states lowest eigenvalues of the dressed CI matrix
|
||||||
|
|
||||||
|
|
||||||
`create_minilist <http://github.com/LCPQ/quantum_package/tree/master/plugins/MRCC_Utils/mrcc_dress.irp.f#L17>`_
|
|
||||||
Undocumented
|
|
||||||
|
|
||||||
|
|
||||||
`davidson_diag_hjj_mrcc <http://github.com/LCPQ/quantum_package/tree/master/plugins/MRCC_Utils/davidson.irp.f#L59>`_
|
`davidson_diag_hjj_mrcc <http://github.com/LCPQ/quantum_package/tree/master/plugins/MRCC_Utils/davidson.irp.f#L59>`_
|
||||||
Davidson diagonalization with specific diagonal elements of the H matrix
|
Davidson diagonalization with specific diagonal elements of the H matrix
|
||||||
.br
|
.br
|
||||||
@ -206,7 +202,7 @@ Documentation
|
|||||||
Find A.C = B
|
Find A.C = B
|
||||||
|
|
||||||
|
|
||||||
`find_triples_and_quadruples <http://github.com/LCPQ/quantum_package/tree/master/plugins/MRCC_Utils/mrcc_dress.irp.f#L266>`_
|
`find_triples_and_quadruples <http://github.com/LCPQ/quantum_package/tree/master/plugins/MRCC_Utils/mrcc_dress.irp.f#L245>`_
|
||||||
Undocumented
|
Undocumented
|
||||||
|
|
||||||
|
|
||||||
@ -232,19 +228,19 @@ Documentation
|
|||||||
Undocumented
|
Undocumented
|
||||||
|
|
||||||
|
|
||||||
`gen_det_idx <http://github.com/LCPQ/quantum_package/tree/master/plugins/MRCC_Utils/mrcc_dress.irp.f#L258>`_
|
`gen_det_idx <http://github.com/LCPQ/quantum_package/tree/master/plugins/MRCC_Utils/mrcc_dress.irp.f#L237>`_
|
||||||
Undocumented
|
Undocumented
|
||||||
|
|
||||||
|
|
||||||
`gen_det_shortcut <http://github.com/LCPQ/quantum_package/tree/master/plugins/MRCC_Utils/mrcc_dress.irp.f#L256>`_
|
`gen_det_shortcut <http://github.com/LCPQ/quantum_package/tree/master/plugins/MRCC_Utils/mrcc_dress.irp.f#L235>`_
|
||||||
Undocumented
|
Undocumented
|
||||||
|
|
||||||
|
|
||||||
`gen_det_sorted <http://github.com/LCPQ/quantum_package/tree/master/plugins/MRCC_Utils/mrcc_dress.irp.f#L255>`_
|
`gen_det_sorted <http://github.com/LCPQ/quantum_package/tree/master/plugins/MRCC_Utils/mrcc_dress.irp.f#L234>`_
|
||||||
Undocumented
|
Undocumented
|
||||||
|
|
||||||
|
|
||||||
`gen_det_version <http://github.com/LCPQ/quantum_package/tree/master/plugins/MRCC_Utils/mrcc_dress.irp.f#L257>`_
|
`gen_det_version <http://github.com/LCPQ/quantum_package/tree/master/plugins/MRCC_Utils/mrcc_dress.irp.f#L236>`_
|
||||||
Undocumented
|
Undocumented
|
||||||
|
|
||||||
|
|
||||||
@ -312,7 +308,7 @@ h_apply_mrcc_monoexc
|
|||||||
Dressed H with Delta_ij
|
Dressed H with Delta_ij
|
||||||
|
|
||||||
|
|
||||||
`h_u_0_mrcc <http://github.com/LCPQ/quantum_package/tree/master/plugins/MRCC_Utils/davidson.irp.f#L374>`_
|
`h_u_0_mrcc <http://github.com/LCPQ/quantum_package/tree/master/plugins/MRCC_Utils/davidson.irp.f#L367>`_
|
||||||
Computes v_0 = H|u_0>
|
Computes v_0 = H|u_0>
|
||||||
.br
|
.br
|
||||||
n : number of determinants
|
n : number of determinants
|
||||||
|
@ -1,50 +0,0 @@
|
|||||||
subroutine pt2_moller_plesset(det_pert,c_pert,e_2_pert,H_pert_diag,Nint,ndet,n_st)
|
|
||||||
use bitmasks
|
|
||||||
implicit none
|
|
||||||
integer, intent(in) :: Nint,ndet,n_st
|
|
||||||
integer(bit_kind), intent(in) :: det_pert(Nint,2)
|
|
||||||
double precision , intent(out) :: c_pert(n_st),e_2_pert(n_st),H_pert_diag(N_st)
|
|
||||||
double precision :: i_H_psi_array(N_st)
|
|
||||||
|
|
||||||
BEGIN_DOC
|
|
||||||
! compute the standard Moller-Plesset perturbative first order coefficient and second order energetic contribution
|
|
||||||
!
|
|
||||||
! for the various n_st states.
|
|
||||||
!
|
|
||||||
! c_pert(i) = <psi(i)|H|det_pert>/(difference of orbital energies)
|
|
||||||
!
|
|
||||||
! e_2_pert(i) = <psi(i)|H|det_pert>^2/(difference of orbital energies)
|
|
||||||
!
|
|
||||||
END_DOC
|
|
||||||
|
|
||||||
integer :: i,j
|
|
||||||
double precision :: diag_H_mat_elem
|
|
||||||
integer :: exc(0:2,2,2)
|
|
||||||
integer :: degree
|
|
||||||
double precision :: phase,delta_e,h
|
|
||||||
integer :: h1,h2,p1,p2,s1,s2
|
|
||||||
ASSERT (Nint == N_int)
|
|
||||||
ASSERT (Nint > 0)
|
|
||||||
call get_excitation(ref_bitmask,det_pert,exc,degree,phase,Nint)
|
|
||||||
if (degree == 2) then
|
|
||||||
call decode_exc(exc,degree,h1,p1,h2,p2,s1,s2)
|
|
||||||
delta_e = Fock_matrix_diag_mo(h1) + Fock_matrix_diag_mo(h2) - &
|
|
||||||
(Fock_matrix_diag_mo(p1) + Fock_matrix_diag_mo(p2))
|
|
||||||
delta_e = 1.d0/delta_e
|
|
||||||
else if (degree == 1) then
|
|
||||||
call decode_exc(exc,degree,h1,p1,h2,p2,s1,s2)
|
|
||||||
delta_e = Fock_matrix_diag_mo(h1) - Fock_matrix_diag_mo(p1)
|
|
||||||
delta_e = 1.d0/delta_e
|
|
||||||
else
|
|
||||||
delta_e = 0.d0
|
|
||||||
endif
|
|
||||||
|
|
||||||
call i_H_psi(det_pert,psi_selectors,psi_selectors_coef,Nint,N_det,psi_selectors_size,n_st,i_H_psi_array)
|
|
||||||
h = diag_H_mat_elem(det_pert,Nint)
|
|
||||||
do i =1,n_st
|
|
||||||
H_pert_diag(i) = h
|
|
||||||
c_pert(i) = i_H_psi_array(i) *delta_e
|
|
||||||
e_2_pert(i) = c_pert(i) * i_H_psi_array(i)
|
|
||||||
enddo
|
|
||||||
|
|
||||||
end
|
|
@ -239,7 +239,7 @@ perturb_buffer_moller_plesset
|
|||||||
.br
|
.br
|
||||||
|
|
||||||
|
|
||||||
`pt2_epstein_nesbet <http://github.com/LCPQ/quantum_package/tree/master/plugins/Perturbation/epstein_nesbet.irp.f#L1>`_
|
`pt2_epstein_nesbet <http://github.com/LCPQ/quantum_package/tree/master/plugins/Perturbation/pt2_equations.irp.f_template_363#L3>`_
|
||||||
compute the standard Epstein-Nesbet perturbative first order coefficient and second order energetic contribution
|
compute the standard Epstein-Nesbet perturbative first order coefficient and second order energetic contribution
|
||||||
.br
|
.br
|
||||||
for the various N_st states.
|
for the various N_st states.
|
||||||
@ -250,7 +250,7 @@ perturb_buffer_moller_plesset
|
|||||||
.br
|
.br
|
||||||
|
|
||||||
|
|
||||||
`pt2_epstein_nesbet_2x2 <http://github.com/LCPQ/quantum_package/tree/master/plugins/Perturbation/epstein_nesbet.irp.f#L45>`_
|
`pt2_epstein_nesbet_2x2 <http://github.com/LCPQ/quantum_package/tree/master/plugins/Perturbation/pt2_equations.irp.f_template_363#L59>`_
|
||||||
compute the Epstein-Nesbet 2x2 diagonalization coefficient and energetic contribution
|
compute the Epstein-Nesbet 2x2 diagonalization coefficient and energetic contribution
|
||||||
.br
|
.br
|
||||||
for the various N_st states.
|
for the various N_st states.
|
||||||
@ -261,7 +261,7 @@ perturb_buffer_moller_plesset
|
|||||||
.br
|
.br
|
||||||
|
|
||||||
|
|
||||||
`pt2_epstein_nesbet_sc2 <http://github.com/LCPQ/quantum_package/tree/master/plugins/Perturbation/pert_sc2.irp.f#L186>`_
|
`pt2_epstein_nesbet_sc2 <http://github.com/LCPQ/quantum_package/tree/master/plugins/Perturbation/pt2_equations.irp.f_template_363#L353>`_
|
||||||
compute the standard Epstein-Nesbet perturbative first order coefficient and second order energetic contribution
|
compute the standard Epstein-Nesbet perturbative first order coefficient and second order energetic contribution
|
||||||
.br
|
.br
|
||||||
for the various N_st states, but with the CISD_SC2 energies and coefficients
|
for the various N_st states, but with the CISD_SC2 energies and coefficients
|
||||||
@ -272,7 +272,7 @@ perturb_buffer_moller_plesset
|
|||||||
.br
|
.br
|
||||||
|
|
||||||
|
|
||||||
`pt2_epstein_nesbet_sc2_no_projected <http://github.com/LCPQ/quantum_package/tree/master/plugins/Perturbation/pert_sc2.irp.f#L87>`_
|
`pt2_epstein_nesbet_sc2_no_projected <http://github.com/LCPQ/quantum_package/tree/master/plugins/Perturbation/pt2_equations.irp.f_template_363#L275>`_
|
||||||
compute the Epstein-Nesbet perturbative first order coefficient and second order energetic contribution
|
compute the Epstein-Nesbet perturbative first order coefficient and second order energetic contribution
|
||||||
.br
|
.br
|
||||||
for the various N_st states,
|
for the various N_st states,
|
||||||
@ -296,7 +296,7 @@ perturb_buffer_moller_plesset
|
|||||||
H_pert_diag = <HF|H|det_pert> c_pert
|
H_pert_diag = <HF|H|det_pert> c_pert
|
||||||
|
|
||||||
|
|
||||||
`pt2_epstein_nesbet_sc2_projected <http://github.com/LCPQ/quantum_package/tree/master/plugins/Perturbation/pert_sc2.irp.f#L2>`_
|
`pt2_epstein_nesbet_sc2_projected <http://github.com/LCPQ/quantum_package/tree/master/plugins/Perturbation/pt2_equations.irp.f_template_363#L181>`_
|
||||||
compute the Epstein-Nesbet perturbative first order coefficient and second order energetic contribution
|
compute the Epstein-Nesbet perturbative first order coefficient and second order energetic contribution
|
||||||
.br
|
.br
|
||||||
for the various N_st states,
|
for the various N_st states,
|
||||||
@ -336,7 +336,7 @@ perturb_buffer_moller_plesset
|
|||||||
than pt2_max in absolute value
|
than pt2_max in absolute value
|
||||||
|
|
||||||
|
|
||||||
`pt2_moller_plesset <http://github.com/LCPQ/quantum_package/tree/master/plugins/Perturbation/Moller_plesset.irp.f#L1>`_
|
`pt2_moller_plesset <http://github.com/LCPQ/quantum_package/tree/master/plugins/Perturbation/pt2_equations.irp.f_template_363#L120>`_
|
||||||
compute the standard Moller-Plesset perturbative first order coefficient and second order energetic contribution
|
compute the standard Moller-Plesset perturbative first order coefficient and second order energetic contribution
|
||||||
.br
|
.br
|
||||||
for the various n_st states.
|
for the various n_st states.
|
||||||
@ -352,7 +352,7 @@ perturb_buffer_moller_plesset
|
|||||||
provided.
|
provided.
|
||||||
|
|
||||||
|
|
||||||
`repeat_all_e_corr <http://github.com/LCPQ/quantum_package/tree/master/plugins/Perturbation/pert_sc2.irp.f#L156>`_
|
`repeat_all_e_corr <http://github.com/LCPQ/quantum_package/tree/master/plugins/Perturbation/pert_sc2.irp.f#L1>`_
|
||||||
Undocumented
|
Undocumented
|
||||||
|
|
||||||
|
|
||||||
|
@ -1,106 +0,0 @@
|
|||||||
subroutine pt2_epstein_nesbet(det_pert,c_pert,e_2_pert,H_pert_diag,Nint,ndet,N_st,minilist,idx_minilist,N_minilist)
|
|
||||||
use bitmasks
|
|
||||||
implicit none
|
|
||||||
integer, intent(in) :: Nint,ndet,N_st
|
|
||||||
integer(bit_kind), intent(in) :: det_pert(Nint,2)
|
|
||||||
double precision , intent(out) :: c_pert(N_st),e_2_pert(N_st),H_pert_diag(N_st)
|
|
||||||
double precision :: i_H_psi_array(N_st)
|
|
||||||
|
|
||||||
integer, intent(in) :: N_minilist
|
|
||||||
integer, intent(in) :: idx_minilist(0:N_det_selectors)
|
|
||||||
integer(bit_kind), intent(in) :: minilist(Nint,2,N_det_selectors)
|
|
||||||
|
|
||||||
BEGIN_DOC
|
|
||||||
! compute the standard Epstein-Nesbet perturbative first order coefficient and second order energetic contribution
|
|
||||||
!
|
|
||||||
! for the various N_st states.
|
|
||||||
!
|
|
||||||
! c_pert(i) = <psi(i)|H|det_pert>/( E(i) - <det_pert|H|det_pert> )
|
|
||||||
!
|
|
||||||
! e_2_pert(i) = <psi(i)|H|det_pert>^2/( E(i) - <det_pert|H|det_pert> )
|
|
||||||
!
|
|
||||||
END_DOC
|
|
||||||
|
|
||||||
integer :: i,j
|
|
||||||
double precision :: diag_H_mat_elem, h
|
|
||||||
PROVIDE selection_criterion
|
|
||||||
|
|
||||||
ASSERT (Nint == N_int)
|
|
||||||
ASSERT (Nint > 0)
|
|
||||||
!call i_H_psi(det_pert,psi_selectors,psi_selectors_coef,Nint,N_det_selectors,psi_selectors_size,N_st,i_H_psi_array)
|
|
||||||
call i_H_psi_minilist(det_pert,minilist,idx_minilist,N_minilist,psi_selectors_coef,Nint,N_minilist,psi_selectors_size,N_st,i_H_psi_array)
|
|
||||||
|
|
||||||
|
|
||||||
h = diag_H_mat_elem(det_pert,Nint)
|
|
||||||
do i =1,N_st
|
|
||||||
if(CI_electronic_energy(i)>h.and.CI_electronic_energy(i).ne.0.d0)then
|
|
||||||
c_pert(i) = -1.d0
|
|
||||||
e_2_pert(i) = selection_criterion*selection_criterion_factor*2.d0
|
|
||||||
else if (dabs(CI_electronic_energy(i) - h) > 1.d-6) then
|
|
||||||
c_pert(i) = i_H_psi_array(i) / (CI_electronic_energy(i) - h)
|
|
||||||
H_pert_diag(i) = h*c_pert(i)*c_pert(i)
|
|
||||||
e_2_pert(i) = c_pert(i) * i_H_psi_array(i)
|
|
||||||
else
|
|
||||||
c_pert(i) = -1.d0
|
|
||||||
e_2_pert(i) = -dabs(i_H_psi_array(i))
|
|
||||||
H_pert_diag(i) = h
|
|
||||||
endif
|
|
||||||
enddo
|
|
||||||
|
|
||||||
end
|
|
||||||
|
|
||||||
subroutine pt2_epstein_nesbet_2x2(det_pert,c_pert,e_2_pert,H_pert_diag,Nint,ndet,N_st,minilist,idx_minilist,N_minilist)
|
|
||||||
use bitmasks
|
|
||||||
implicit none
|
|
||||||
integer, intent(in) :: Nint,ndet,N_st
|
|
||||||
integer(bit_kind), intent(in) :: det_pert(Nint,2)
|
|
||||||
double precision , intent(out) :: c_pert(N_st),e_2_pert(N_st),H_pert_diag(N_st)
|
|
||||||
double precision :: i_H_psi_array(N_st)
|
|
||||||
|
|
||||||
integer, intent(in) :: N_minilist
|
|
||||||
integer, intent(in) :: idx_minilist(0:N_det_selectors)
|
|
||||||
integer(bit_kind), intent(in) :: minilist(Nint,2,N_det_selectors)
|
|
||||||
|
|
||||||
BEGIN_DOC
|
|
||||||
! compute the Epstein-Nesbet 2x2 diagonalization coefficient and energetic contribution
|
|
||||||
!
|
|
||||||
! for the various N_st states.
|
|
||||||
!
|
|
||||||
! e_2_pert(i) = 0.5 * (( <det_pert|H|det_pert> - E(i) ) - sqrt( ( <det_pert|H|det_pert> - E(i)) ^2 + 4 <psi(i)|H|det_pert>^2 )
|
|
||||||
!
|
|
||||||
! c_pert(i) = e_2_pert(i)/ <psi(i)|H|det_pert>
|
|
||||||
!
|
|
||||||
END_DOC
|
|
||||||
|
|
||||||
integer :: i,j
|
|
||||||
double precision :: diag_H_mat_elem,delta_e, h
|
|
||||||
ASSERT (Nint == N_int)
|
|
||||||
ASSERT (Nint > 0)
|
|
||||||
PROVIDE CI_electronic_energy
|
|
||||||
|
|
||||||
!call i_H_psi(det_pert,psi_selectors,psi_selectors_coef,Nint,N_det_selectors,psi_selectors_size,N_st,i_H_psi_array)
|
|
||||||
call i_H_psi_minilist(det_pert,minilist,idx_minilist,N_minilist,psi_selectors_coef,Nint,N_minilist,psi_selectors_size,N_st,i_H_psi_array)
|
|
||||||
|
|
||||||
h = diag_H_mat_elem(det_pert,Nint)
|
|
||||||
do i =1,N_st
|
|
||||||
if (i_H_psi_array(i) /= 0.d0) then
|
|
||||||
delta_e = h - CI_electronic_energy(i)
|
|
||||||
if (delta_e > 0.d0) then
|
|
||||||
e_2_pert(i) = 0.5d0 * (delta_e - dsqrt(delta_e * delta_e + 4.d0 * i_H_psi_array(i) * i_H_psi_array(i)))
|
|
||||||
else
|
|
||||||
e_2_pert(i) = 0.5d0 * (delta_e + dsqrt(delta_e * delta_e + 4.d0 * i_H_psi_array(i) * i_H_psi_array(i)))
|
|
||||||
endif
|
|
||||||
if (dabs(i_H_psi_array(i)) > 1.d-6) then
|
|
||||||
c_pert(i) = e_2_pert(i)/i_H_psi_array(i)
|
|
||||||
else
|
|
||||||
c_pert(i) = 0.d0
|
|
||||||
endif
|
|
||||||
H_pert_diag(i) = h*c_pert(i)*c_pert(i)
|
|
||||||
else
|
|
||||||
e_2_pert(i) = 0.d0
|
|
||||||
c_pert(i) = 0.d0
|
|
||||||
H_pert_diag(i) = 0.d0
|
|
||||||
endif
|
|
||||||
enddo
|
|
||||||
|
|
||||||
end
|
|
@ -1,166 +1,3 @@
|
|||||||
|
|
||||||
subroutine pt2_epstein_nesbet_SC2_projected(det_pert,c_pert,e_2_pert,H_pert_diag,Nint,ndet,N_st,minilist,idx_minilist,N_minilist)
|
|
||||||
use bitmasks
|
|
||||||
implicit none
|
|
||||||
integer, intent(in) :: Nint,ndet,N_st
|
|
||||||
integer(bit_kind), intent(in) :: det_pert(Nint,2)
|
|
||||||
double precision , intent(out) :: c_pert(N_st),e_2_pert(N_st),H_pert_diag(N_st)
|
|
||||||
double precision :: i_H_psi_array(N_st)
|
|
||||||
integer :: idx_repeat(0:ndet)
|
|
||||||
|
|
||||||
integer, intent(in) :: N_minilist
|
|
||||||
integer, intent(in) :: idx_minilist(0:N_det_selectors)
|
|
||||||
integer(bit_kind), intent(in) :: minilist(Nint,2,N_det_selectors)
|
|
||||||
|
|
||||||
BEGIN_DOC
|
|
||||||
! compute the Epstein-Nesbet perturbative first order coefficient and second order energetic contribution
|
|
||||||
!
|
|
||||||
! for the various N_st states,
|
|
||||||
!
|
|
||||||
! but with the correction in the denominator
|
|
||||||
!
|
|
||||||
! comming from the interaction of that determinant with all the others determinants
|
|
||||||
!
|
|
||||||
! that can be repeated by repeating all the double excitations
|
|
||||||
!
|
|
||||||
! : you repeat all the correlation energy already taken into account in CI_electronic_energy(1)
|
|
||||||
!
|
|
||||||
! that could be repeated to this determinant.
|
|
||||||
!
|
|
||||||
! In addition, for the perturbative energetic contribution you have the standard second order
|
|
||||||
!
|
|
||||||
! e_2_pert = <psi_i|H|det_pert>^2/(Delta_E)
|
|
||||||
!
|
|
||||||
! and also the purely projected contribution
|
|
||||||
!
|
|
||||||
! H_pert_diag = <HF|H|det_pert> c_pert
|
|
||||||
END_DOC
|
|
||||||
|
|
||||||
integer :: i,j,degree,l
|
|
||||||
double precision :: diag_H_mat_elem,accu_e_corr,hij,h0j,h,delta_E
|
|
||||||
double precision :: repeat_all_e_corr,accu_e_corr_tmp,e_2_pert_fonda
|
|
||||||
|
|
||||||
ASSERT (Nint == N_int)
|
|
||||||
ASSERT (Nint > 0)
|
|
||||||
|
|
||||||
call i_H_psi_SC2(det_pert,psi_selectors,psi_selectors_coef,Nint,N_det_selectors,psi_selectors_size,N_st,i_H_psi_array,idx_repeat)
|
|
||||||
accu_e_corr = 0.d0
|
|
||||||
!$IVDEP
|
|
||||||
do i = 1, idx_repeat(0)
|
|
||||||
accu_e_corr = accu_e_corr + E_corr_per_selectors(idx_repeat(i))
|
|
||||||
enddo
|
|
||||||
h = diag_H_mat_elem(det_pert,Nint) + accu_e_corr
|
|
||||||
delta_E = 1.d0/(CI_SC2_electronic_energy(1) - h)
|
|
||||||
|
|
||||||
|
|
||||||
c_pert(1) = i_H_psi_array(1) /(CI_SC2_electronic_energy(1) - h)
|
|
||||||
e_2_pert(1) = i_H_psi_array(1) * c_pert(1)
|
|
||||||
|
|
||||||
do i =2,N_st
|
|
||||||
H_pert_diag(i) = h
|
|
||||||
if (dabs(CI_SC2_electronic_energy(i) - h) > 1.d-6) then
|
|
||||||
c_pert(i) = i_H_psi_array(i) / (-dabs(CI_SC2_electronic_energy(i) - h))
|
|
||||||
e_2_pert(i) = (c_pert(i) * i_H_psi_array(i))
|
|
||||||
else
|
|
||||||
c_pert(i) = i_H_psi_array(i)
|
|
||||||
e_2_pert(i) = -dabs(i_H_psi_array(i))
|
|
||||||
endif
|
|
||||||
enddo
|
|
||||||
|
|
||||||
degree = popcnt(xor( ref_bitmask(1,1), det_pert(1,1))) + &
|
|
||||||
popcnt(xor( ref_bitmask(1,2), det_pert(1,2)))
|
|
||||||
!DEC$ NOUNROLL
|
|
||||||
do l=2,Nint
|
|
||||||
degree = degree+ popcnt(xor( ref_bitmask(l,1), det_pert(l,1))) + &
|
|
||||||
popcnt(xor( ref_bitmask(l,2), det_pert(l,2)))
|
|
||||||
enddo
|
|
||||||
if(degree==4)then
|
|
||||||
! <psi|delta_H|psi>
|
|
||||||
e_2_pert_fonda = e_2_pert(1)
|
|
||||||
H_pert_diag(1) = e_2_pert(1) * c_pert(1) * c_pert(1)
|
|
||||||
do i = 1, N_st
|
|
||||||
do j = 1, idx_repeat(0)
|
|
||||||
e_2_pert(i) += e_2_pert_fonda * psi_selectors_coef(idx_repeat(j),i) * psi_selectors_coef(idx_repeat(j),i)
|
|
||||||
enddo
|
|
||||||
enddo
|
|
||||||
endif
|
|
||||||
|
|
||||||
end
|
|
||||||
|
|
||||||
|
|
||||||
subroutine pt2_epstein_nesbet_SC2_no_projected(det_pert,c_pert,e_2_pert,H_pert_diag,Nint,ndet,N_st,minilist,idx_minilist,N_minilist)
|
|
||||||
use bitmasks
|
|
||||||
implicit none
|
|
||||||
integer, intent(in) :: Nint,ndet,N_st
|
|
||||||
integer(bit_kind), intent(in) :: det_pert(Nint,2)
|
|
||||||
double precision , intent(out) :: c_pert(N_st),e_2_pert(N_st),H_pert_diag(N_st)
|
|
||||||
double precision :: i_H_psi_array(N_st)
|
|
||||||
integer :: idx_repeat(0:ndet)
|
|
||||||
|
|
||||||
integer, intent(in) :: N_minilist
|
|
||||||
integer, intent(in) :: idx_minilist(0:N_det_selectors)
|
|
||||||
integer(bit_kind), intent(in) :: minilist(Nint,2,N_det_selectors)
|
|
||||||
|
|
||||||
BEGIN_DOC
|
|
||||||
! compute the Epstein-Nesbet perturbative first order coefficient and second order energetic contribution
|
|
||||||
!
|
|
||||||
! for the various N_st states,
|
|
||||||
!
|
|
||||||
! but with the correction in the denominator
|
|
||||||
!
|
|
||||||
! comming from the interaction of that determinant with all the others determinants
|
|
||||||
!
|
|
||||||
! that can be repeated by repeating all the double excitations
|
|
||||||
!
|
|
||||||
! : you repeat all the correlation energy already taken into account in CI_electronic_energy(1)
|
|
||||||
!
|
|
||||||
! that could be repeated to this determinant.
|
|
||||||
!
|
|
||||||
! In addition, for the perturbative energetic contribution you have the standard second order
|
|
||||||
!
|
|
||||||
! e_2_pert = <psi_i|H|det_pert>^2/(Delta_E)
|
|
||||||
!
|
|
||||||
! and also the purely projected contribution
|
|
||||||
!
|
|
||||||
! H_pert_diag = <HF|H|det_pert> c_pert
|
|
||||||
END_DOC
|
|
||||||
|
|
||||||
integer :: i,j,degree,l
|
|
||||||
double precision :: diag_H_mat_elem,accu_e_corr,hij,h0j,h,delta_E
|
|
||||||
double precision :: repeat_all_e_corr,accu_e_corr_tmp,e_2_pert_fonda
|
|
||||||
|
|
||||||
ASSERT (Nint == N_int)
|
|
||||||
ASSERT (Nint > 0)
|
|
||||||
|
|
||||||
call i_H_psi_SC2(det_pert,psi_selectors,psi_selectors_coef,Nint,N_det_selectors,psi_selectors_size,N_st,i_H_psi_array,idx_repeat)
|
|
||||||
accu_e_corr = 0.d0
|
|
||||||
!$IVDEP
|
|
||||||
do i = 1, idx_repeat(0)
|
|
||||||
accu_e_corr = accu_e_corr + E_corr_per_selectors(idx_repeat(i))
|
|
||||||
enddo
|
|
||||||
h = diag_H_mat_elem(det_pert,Nint) + accu_e_corr
|
|
||||||
delta_E = 1.d0/(CI_SC2_electronic_energy(1) - h)
|
|
||||||
|
|
||||||
|
|
||||||
c_pert(1) = i_H_psi_array(1) /(CI_SC2_electronic_energy(1) - h)
|
|
||||||
e_2_pert(1) = i_H_psi_array(1) * c_pert(1)
|
|
||||||
|
|
||||||
do i =2,N_st
|
|
||||||
H_pert_diag(i) = h
|
|
||||||
if (dabs(CI_SC2_electronic_energy(i) - h) > 1.d-6) then
|
|
||||||
c_pert(i) = i_H_psi_array(i) / (-dabs(CI_SC2_electronic_energy(i) - h))
|
|
||||||
e_2_pert(i) = (c_pert(i) * i_H_psi_array(i))
|
|
||||||
else
|
|
||||||
c_pert(i) = i_H_psi_array(i)
|
|
||||||
e_2_pert(i) = -dabs(i_H_psi_array(i))
|
|
||||||
endif
|
|
||||||
enddo
|
|
||||||
end
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
double precision function repeat_all_e_corr(key_in)
|
double precision function repeat_all_e_corr(key_in)
|
||||||
implicit none
|
implicit none
|
||||||
integer(bit_kind), intent(in) :: key_in(N_int,2)
|
integer(bit_kind), intent(in) :: key_in(N_int,2)
|
||||||
@ -190,54 +27,3 @@ double precision function repeat_all_e_corr(key_in)
|
|||||||
|
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
||||||
subroutine pt2_epstein_nesbet_sc2(det_pert,c_pert,e_2_pert,H_pert_diag,Nint,ndet,N_st,minilist,idx_minilist,N_minilist)
|
|
||||||
use bitmasks
|
|
||||||
implicit none
|
|
||||||
integer, intent(in) :: Nint,ndet,N_st
|
|
||||||
integer(bit_kind), intent(in) :: det_pert(Nint,2)
|
|
||||||
double precision , intent(out) :: c_pert(N_st),e_2_pert(N_st),H_pert_diag(N_st)
|
|
||||||
double precision :: i_H_psi_array(N_st)
|
|
||||||
|
|
||||||
integer, intent(in) :: N_minilist
|
|
||||||
integer, intent(in) :: idx_minilist(0:N_det_selectors)
|
|
||||||
integer(bit_kind), intent(in) :: minilist(Nint,2,N_det_selectors)
|
|
||||||
|
|
||||||
BEGIN_DOC
|
|
||||||
! compute the standard Epstein-Nesbet perturbative first order coefficient and second order energetic contribution
|
|
||||||
!
|
|
||||||
! for the various N_st states, but with the CISD_SC2 energies and coefficients
|
|
||||||
!
|
|
||||||
! c_pert(i) = <psi(i)|H|det_pert>/( E(i) - <det_pert|H|det_pert> )
|
|
||||||
!
|
|
||||||
! e_2_pert(i) = <psi(i)|H|det_pert>^2/( E(i) - <det_pert|H|det_pert> )
|
|
||||||
!
|
|
||||||
END_DOC
|
|
||||||
|
|
||||||
integer :: i,j
|
|
||||||
double precision :: diag_H_mat_elem, h
|
|
||||||
PROVIDE selection_criterion
|
|
||||||
|
|
||||||
ASSERT (Nint == N_int)
|
|
||||||
ASSERT (Nint > 0)
|
|
||||||
!call i_H_psi(det_pert,psi_selectors,psi_selectors_coef,Nint,N_det_selectors,psi_selectors_size,N_st,i_H_psi_array)
|
|
||||||
call i_H_psi_minilist(det_pert,minilist,idx_minilist,N_minilist,psi_selectors_coef,Nint,N_minilist,psi_selectors_size,N_st,i_H_psi_array)
|
|
||||||
|
|
||||||
|
|
||||||
h = diag_H_mat_elem(det_pert,Nint)
|
|
||||||
do i =1,N_st
|
|
||||||
if(CI_SC2_electronic_energy(i)>h.and.CI_SC2_electronic_energy(i).ne.0.d0)then
|
|
||||||
c_pert(i) = -1.d0
|
|
||||||
e_2_pert(i) = selection_criterion*selection_criterion_factor*2.d0
|
|
||||||
else if (dabs(CI_SC2_electronic_energy(i) - h) > 1.d-6) then
|
|
||||||
c_pert(i) = i_H_psi_array(i) / (CI_SC2_electronic_energy(i) - h)
|
|
||||||
H_pert_diag(i) = h*c_pert(i)*c_pert(i)
|
|
||||||
e_2_pert(i) = c_pert(i) * i_H_psi_array(i)
|
|
||||||
else
|
|
||||||
c_pert(i) = -1.d0
|
|
||||||
e_2_pert(i) = -dabs(i_H_psi_array(i))
|
|
||||||
H_pert_diag(i) = h
|
|
||||||
endif
|
|
||||||
enddo
|
|
||||||
|
|
||||||
end
|
|
||||||
|
@ -2,7 +2,7 @@ BEGIN_SHELL [ /usr/bin/env python ]
|
|||||||
import perturbation
|
import perturbation
|
||||||
END_SHELL
|
END_SHELL
|
||||||
|
|
||||||
subroutine perturb_buffer_$PERT(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)
|
subroutine perturb_buffer_$PERT(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)
|
||||||
implicit none
|
implicit none
|
||||||
BEGIN_DOC
|
BEGIN_DOC
|
||||||
! Applly pertubration ``$PERT`` to the buffer of determinants generated in the H_apply
|
! Applly pertubration ``$PERT`` to the buffer of determinants generated in the H_apply
|
||||||
@ -12,6 +12,7 @@ subroutine perturb_buffer_$PERT(i_generator,buffer,buffer_size,e_2_pert_buffer,c
|
|||||||
integer, intent(in) :: Nint, N_st, buffer_size, i_generator
|
integer, intent(in) :: Nint, N_st, buffer_size, i_generator
|
||||||
integer(bit_kind), intent(in) :: buffer(Nint,2,buffer_size)
|
integer(bit_kind), intent(in) :: buffer(Nint,2,buffer_size)
|
||||||
integer(bit_kind),intent(in) :: key_mask(Nint,2)
|
integer(bit_kind),intent(in) :: key_mask(Nint,2)
|
||||||
|
double precision, intent(in) :: fock_diag_tmp(2,0:mo_tot_num)
|
||||||
double precision, intent(inout) :: sum_norm_pert(N_st),sum_e_2_pert(N_st)
|
double precision, intent(inout) :: sum_norm_pert(N_st),sum_e_2_pert(N_st)
|
||||||
double precision, intent(inout) :: coef_pert_buffer(N_st,buffer_size),e_2_pert_buffer(N_st,buffer_size),sum_H_pert_diag(N_st)
|
double precision, intent(inout) :: coef_pert_buffer(N_st,buffer_size),e_2_pert_buffer(N_st,buffer_size),sum_H_pert_diag(N_st)
|
||||||
double precision :: c_pert(N_st), e_2_pert(N_st), H_pert_diag(N_st)
|
double precision :: c_pert(N_st), e_2_pert(N_st), H_pert_diag(N_st)
|
||||||
@ -43,23 +44,7 @@ subroutine perturb_buffer_$PERT(i_generator,buffer,buffer_size,e_2_pert_buffer,c
|
|||||||
end if
|
end if
|
||||||
|
|
||||||
|
|
||||||
buffer_loop : do i = 1,buffer_size
|
do i=1,buffer_size
|
||||||
|
|
||||||
! do k=1,N_minilist_gen
|
|
||||||
! ex = 0
|
|
||||||
! do ni=1,Nint
|
|
||||||
! ex += popcnt(xor(minilist_gen(ni,1,k), buffer(ni,1,i))) + popcnt(xor(minilist_gen(ni,2,k), buffer(ni,2,i)))
|
|
||||||
! end do
|
|
||||||
! if(ex <= 4) then
|
|
||||||
! cycle buffer_loop
|
|
||||||
! end if
|
|
||||||
! end do
|
|
||||||
|
|
||||||
! c_ref = connected_to_ref(buffer(1,1,i),miniList_gen,Nint,N_minilist_gen+1,N_minilist_gen)
|
|
||||||
!
|
|
||||||
! if (c_ref /= 0) then
|
|
||||||
! cycle
|
|
||||||
! endif
|
|
||||||
|
|
||||||
if(is_connected_to(buffer(1,1,i), miniList_gen, Nint, N_minilist_gen)) then
|
if(is_connected_to(buffer(1,1,i), miniList_gen, Nint, N_minilist_gen)) then
|
||||||
cycle
|
cycle
|
||||||
@ -71,20 +56,18 @@ subroutine perturb_buffer_$PERT(i_generator,buffer,buffer_size,e_2_pert_buffer,c
|
|||||||
|
|
||||||
integer :: degree
|
integer :: degree
|
||||||
call get_excitation_degree(HF_bitmask,buffer(1,1,i),degree,N_int)
|
call get_excitation_degree(HF_bitmask,buffer(1,1,i),degree,N_int)
|
||||||
! call pt2_$PERT(buffer(1,1,i), &
|
call pt2_$PERT(psi_det_generators(1,1,i_generator),buffer(1,1,i), fock_diag_tmp, &
|
||||||
! c_pert,e_2_pert,H_pert_diag,Nint,N_det_selectors,n_st,minilist,idx_minilist)
|
c_pert,e_2_pert,H_pert_diag,Nint,N_minilist,n_st,minilist,idx_minilist,N_minilist)
|
||||||
call pt2_$PERT(buffer(1,1,i), &
|
|
||||||
c_pert,e_2_pert,H_pert_diag,Nint,N_minilist,n_st,minilist,idx_minilist,N_minilist) !!!!!!!!!!!!!!!!! MAUVAISE SIGNATURE PR LES AUTRES PT2_* !!!!!
|
|
||||||
|
|
||||||
do k = 1,N_st
|
do k = 1,N_st
|
||||||
e_2_pert_buffer(k,i) = e_2_pert(k)
|
e_2_pert_buffer(k,i) = e_2_pert(k)
|
||||||
coef_pert_buffer(k,i) = c_pert(k)
|
coef_pert_buffer(k,i) = c_pert(k)
|
||||||
sum_norm_pert(k) += c_pert(k) * c_pert(k)
|
sum_norm_pert(k) = sum_norm_pert(k) + c_pert(k) * c_pert(k)
|
||||||
sum_e_2_pert(k) += e_2_pert(k)
|
sum_e_2_pert(k) = sum_e_2_pert(k) + e_2_pert(k)
|
||||||
sum_H_pert_diag(k) += H_pert_diag(k)
|
sum_H_pert_diag(k) = sum_H_pert_diag(k) + H_pert_diag(k)
|
||||||
enddo
|
enddo
|
||||||
|
|
||||||
enddo buffer_loop
|
enddo
|
||||||
|
|
||||||
end
|
end
|
||||||
|
|
||||||
|
367
plugins/Perturbation/pt2_equations.irp.f
Normal file
367
plugins/Perturbation/pt2_equations.irp.f
Normal file
@ -0,0 +1,367 @@
|
|||||||
|
BEGIN_TEMPLATE
|
||||||
|
|
||||||
|
subroutine pt2_epstein_nesbet ($arguments)
|
||||||
|
use bitmasks
|
||||||
|
implicit none
|
||||||
|
$declarations
|
||||||
|
|
||||||
|
BEGIN_DOC
|
||||||
|
! compute the standard Epstein-Nesbet perturbative first order coefficient and second order energetic contribution
|
||||||
|
!
|
||||||
|
! for the various N_st states.
|
||||||
|
!
|
||||||
|
! c_pert(i) = <psi(i)|H|det_pert>/( E(i) - <det_pert|H|det_pert> )
|
||||||
|
!
|
||||||
|
! e_2_pert(i) = <psi(i)|H|det_pert>^2/( E(i) - <det_pert|H|det_pert> )
|
||||||
|
!
|
||||||
|
END_DOC
|
||||||
|
|
||||||
|
integer :: i,j
|
||||||
|
double precision :: diag_H_mat_elem_fock, h
|
||||||
|
double precision :: i_H_psi_array(N_st)
|
||||||
|
PROVIDE selection_criterion
|
||||||
|
|
||||||
|
ASSERT (Nint == N_int)
|
||||||
|
ASSERT (Nint > 0)
|
||||||
|
!call i_H_psi(det_pert,psi_selectors,psi_selectors_coef,Nint,N_det_selectors,psi_selectors_size,N_st,i_H_psi_array)
|
||||||
|
call i_H_psi_minilist(det_pert,minilist,idx_minilist,N_minilist,psi_selectors_coef,Nint,N_minilist,psi_selectors_size,N_st,i_H_psi_array)
|
||||||
|
|
||||||
|
|
||||||
|
h = diag_H_mat_elem_fock(det_ref,det_pert,fock_diag_tmp,Nint)
|
||||||
|
do i =1,N_st
|
||||||
|
if(CI_electronic_energy(i)>h.and.CI_electronic_energy(i).ne.0.d0)then
|
||||||
|
c_pert(i) = -1.d0
|
||||||
|
e_2_pert(i) = selection_criterion*selection_criterion_factor*2.d0
|
||||||
|
else if (dabs(CI_electronic_energy(i) - h) > 1.d-6) then
|
||||||
|
c_pert(i) = i_H_psi_array(i) / (CI_electronic_energy(i) - h)
|
||||||
|
H_pert_diag(i) = h*c_pert(i)*c_pert(i)
|
||||||
|
e_2_pert(i) = c_pert(i) * i_H_psi_array(i)
|
||||||
|
else
|
||||||
|
c_pert(i) = -1.d0
|
||||||
|
e_2_pert(i) = -dabs(i_H_psi_array(i))
|
||||||
|
H_pert_diag(i) = h
|
||||||
|
endif
|
||||||
|
enddo
|
||||||
|
|
||||||
|
end
|
||||||
|
|
||||||
|
subroutine pt2_epstein_nesbet_2x2 ($arguments)
|
||||||
|
use bitmasks
|
||||||
|
implicit none
|
||||||
|
$declarations
|
||||||
|
|
||||||
|
BEGIN_DOC
|
||||||
|
! compute the Epstein-Nesbet 2x2 diagonalization coefficient and energetic contribution
|
||||||
|
!
|
||||||
|
! for the various N_st states.
|
||||||
|
!
|
||||||
|
! e_2_pert(i) = 0.5 * (( <det_pert|H|det_pert> - E(i) ) - sqrt( ( <det_pert|H|det_pert> - E(i)) ^2 + 4 <psi(i)|H|det_pert>^2 )
|
||||||
|
!
|
||||||
|
! c_pert(i) = e_2_pert(i)/ <psi(i)|H|det_pert>
|
||||||
|
!
|
||||||
|
END_DOC
|
||||||
|
|
||||||
|
integer :: i,j
|
||||||
|
double precision :: diag_H_mat_elem_fock,delta_e, h
|
||||||
|
double precision :: i_H_psi_array(N_st)
|
||||||
|
ASSERT (Nint == N_int)
|
||||||
|
ASSERT (Nint > 0)
|
||||||
|
PROVIDE CI_electronic_energy
|
||||||
|
|
||||||
|
!call i_H_psi(det_pert,psi_selectors,psi_selectors_coef,Nint,N_det_selectors,psi_selectors_size,N_st,i_H_psi_array)
|
||||||
|
call i_H_psi_minilist(det_pert,minilist,idx_minilist,N_minilist,psi_selectors_coef,Nint,N_minilist,psi_selectors_size,N_st,i_H_psi_array)
|
||||||
|
|
||||||
|
h = diag_H_mat_elem_fock(det_ref,det_pert,fock_diag_tmp,Nint)
|
||||||
|
do i =1,N_st
|
||||||
|
if (i_H_psi_array(i) /= 0.d0) then
|
||||||
|
delta_e = h - CI_electronic_energy(i)
|
||||||
|
if (delta_e > 0.d0) then
|
||||||
|
e_2_pert(i) = 0.5d0 * (delta_e - dsqrt(delta_e * delta_e + 4.d0 * i_H_psi_array(i) * i_H_psi_array(i)))
|
||||||
|
else
|
||||||
|
e_2_pert(i) = 0.5d0 * (delta_e + dsqrt(delta_e * delta_e + 4.d0 * i_H_psi_array(i) * i_H_psi_array(i)))
|
||||||
|
endif
|
||||||
|
if (dabs(i_H_psi_array(i)) > 1.d-6) then
|
||||||
|
c_pert(i) = e_2_pert(i)/i_H_psi_array(i)
|
||||||
|
else
|
||||||
|
c_pert(i) = 0.d0
|
||||||
|
endif
|
||||||
|
H_pert_diag(i) = h*c_pert(i)*c_pert(i)
|
||||||
|
else
|
||||||
|
e_2_pert(i) = 0.d0
|
||||||
|
c_pert(i) = 0.d0
|
||||||
|
H_pert_diag(i) = 0.d0
|
||||||
|
endif
|
||||||
|
enddo
|
||||||
|
|
||||||
|
end
|
||||||
|
|
||||||
|
subroutine pt2_moller_plesset ($arguments)
|
||||||
|
use bitmasks
|
||||||
|
implicit none
|
||||||
|
$declarations
|
||||||
|
|
||||||
|
BEGIN_DOC
|
||||||
|
! compute the standard Moller-Plesset perturbative first order coefficient and second order energetic contribution
|
||||||
|
!
|
||||||
|
! for the various n_st states.
|
||||||
|
!
|
||||||
|
! c_pert(i) = <psi(i)|H|det_pert>/(difference of orbital energies)
|
||||||
|
!
|
||||||
|
! e_2_pert(i) = <psi(i)|H|det_pert>^2/(difference of orbital energies)
|
||||||
|
!
|
||||||
|
END_DOC
|
||||||
|
|
||||||
|
integer :: i,j
|
||||||
|
double precision :: diag_H_mat_elem_fock
|
||||||
|
integer :: exc(0:2,2,2)
|
||||||
|
integer :: degree
|
||||||
|
double precision :: phase,delta_e,h
|
||||||
|
double precision :: i_H_psi_array(N_st)
|
||||||
|
integer :: h1,h2,p1,p2,s1,s2
|
||||||
|
ASSERT (Nint == N_int)
|
||||||
|
ASSERT (Nint > 0)
|
||||||
|
call get_excitation(ref_bitmask,det_pert,exc,degree,phase,Nint)
|
||||||
|
if (degree == 2) then
|
||||||
|
call decode_exc(exc,degree,h1,p1,h2,p2,s1,s2)
|
||||||
|
delta_e = Fock_matrix_diag_mo(h1) + Fock_matrix_diag_mo(h2) - &
|
||||||
|
(Fock_matrix_diag_mo(p1) + Fock_matrix_diag_mo(p2))
|
||||||
|
delta_e = 1.d0/delta_e
|
||||||
|
else if (degree == 1) then
|
||||||
|
call decode_exc(exc,degree,h1,p1,h2,p2,s1,s2)
|
||||||
|
delta_e = Fock_matrix_diag_mo(h1) - Fock_matrix_diag_mo(p1)
|
||||||
|
delta_e = 1.d0/delta_e
|
||||||
|
else
|
||||||
|
delta_e = 0.d0
|
||||||
|
endif
|
||||||
|
|
||||||
|
call i_H_psi(det_pert,psi_selectors,psi_selectors_coef,Nint,N_det,psi_selectors_size,n_st,i_H_psi_array)
|
||||||
|
h = diag_H_mat_elem_fock(det_ref,det_pert,fock_diag_tmp,Nint)
|
||||||
|
do i =1,n_st
|
||||||
|
H_pert_diag(i) = h
|
||||||
|
c_pert(i) = i_H_psi_array(i) *delta_e
|
||||||
|
e_2_pert(i) = c_pert(i) * i_H_psi_array(i)
|
||||||
|
enddo
|
||||||
|
|
||||||
|
end
|
||||||
|
|
||||||
|
|
||||||
|
subroutine pt2_epstein_nesbet_SC2_projected ($arguments)
|
||||||
|
use bitmasks
|
||||||
|
implicit none
|
||||||
|
$declarations
|
||||||
|
BEGIN_DOC
|
||||||
|
! compute the Epstein-Nesbet perturbative first order coefficient and second order energetic contribution
|
||||||
|
!
|
||||||
|
! for the various N_st states,
|
||||||
|
!
|
||||||
|
! but with the correction in the denominator
|
||||||
|
!
|
||||||
|
! comming from the interaction of that determinant with all the others determinants
|
||||||
|
!
|
||||||
|
! that can be repeated by repeating all the double excitations
|
||||||
|
!
|
||||||
|
! : you repeat all the correlation energy already taken into account in CI_electronic_energy(1)
|
||||||
|
!
|
||||||
|
! that could be repeated to this determinant.
|
||||||
|
!
|
||||||
|
! In addition, for the perturbative energetic contribution you have the standard second order
|
||||||
|
!
|
||||||
|
! e_2_pert = <psi_i|H|det_pert>^2/(Delta_E)
|
||||||
|
!
|
||||||
|
! and also the purely projected contribution
|
||||||
|
!
|
||||||
|
! H_pert_diag = <HF|H|det_pert> c_pert
|
||||||
|
END_DOC
|
||||||
|
|
||||||
|
double precision :: i_H_psi_array(N_st)
|
||||||
|
integer :: idx_repeat(0:ndet)
|
||||||
|
integer :: i,j,degree,l
|
||||||
|
double precision :: diag_H_mat_elem_fock,accu_e_corr,hij,h0j,h,delta_E
|
||||||
|
double precision :: repeat_all_e_corr,accu_e_corr_tmp,e_2_pert_fonda
|
||||||
|
|
||||||
|
ASSERT (Nint == N_int)
|
||||||
|
ASSERT (Nint > 0)
|
||||||
|
|
||||||
|
call i_H_psi_SC2(det_pert,psi_selectors,psi_selectors_coef,Nint,N_det_selectors,psi_selectors_size,N_st,i_H_psi_array,idx_repeat)
|
||||||
|
accu_e_corr = 0.d0
|
||||||
|
!$IVDEP
|
||||||
|
do i = 1, idx_repeat(0)
|
||||||
|
accu_e_corr = accu_e_corr + E_corr_per_selectors(idx_repeat(i))
|
||||||
|
enddo
|
||||||
|
h = diag_H_mat_elem_fock(det_ref,det_pert,fock_diag_tmp,Nint)
|
||||||
|
h = h + accu_e_corr
|
||||||
|
delta_E = 1.d0/(CI_SC2_electronic_energy(1) - h)
|
||||||
|
|
||||||
|
|
||||||
|
c_pert(1) = i_H_psi_array(1) /(CI_SC2_electronic_energy(1) - h)
|
||||||
|
e_2_pert(1) = i_H_psi_array(1) * c_pert(1)
|
||||||
|
|
||||||
|
do i =2,N_st
|
||||||
|
H_pert_diag(i) = h
|
||||||
|
if (dabs(CI_SC2_electronic_energy(i) - h) > 1.d-6) then
|
||||||
|
c_pert(i) = i_H_psi_array(i) / (-dabs(CI_SC2_electronic_energy(i) - h))
|
||||||
|
e_2_pert(i) = (c_pert(i) * i_H_psi_array(i))
|
||||||
|
else
|
||||||
|
c_pert(i) = i_H_psi_array(i)
|
||||||
|
e_2_pert(i) = -dabs(i_H_psi_array(i))
|
||||||
|
endif
|
||||||
|
enddo
|
||||||
|
|
||||||
|
degree = popcnt(xor( ref_bitmask(1,1), det_pert(1,1))) + &
|
||||||
|
popcnt(xor( ref_bitmask(1,2), det_pert(1,2)))
|
||||||
|
!DEC$ NOUNROLL
|
||||||
|
do l=2,Nint
|
||||||
|
degree = degree+ popcnt(xor( ref_bitmask(l,1), det_pert(l,1))) + &
|
||||||
|
popcnt(xor( ref_bitmask(l,2), det_pert(l,2)))
|
||||||
|
enddo
|
||||||
|
if(degree==4)then
|
||||||
|
! <psi|delta_H|psi>
|
||||||
|
e_2_pert_fonda = e_2_pert(1)
|
||||||
|
H_pert_diag(1) = e_2_pert(1) * c_pert(1) * c_pert(1)
|
||||||
|
do i = 1, N_st
|
||||||
|
do j = 1, idx_repeat(0)
|
||||||
|
e_2_pert(i) += e_2_pert_fonda * psi_selectors_coef(idx_repeat(j),i) * psi_selectors_coef(idx_repeat(j),i)
|
||||||
|
enddo
|
||||||
|
enddo
|
||||||
|
endif
|
||||||
|
|
||||||
|
end
|
||||||
|
|
||||||
|
|
||||||
|
subroutine pt2_epstein_nesbet_SC2_no_projected ($arguments)
|
||||||
|
use bitmasks
|
||||||
|
implicit none
|
||||||
|
$declarations
|
||||||
|
BEGIN_DOC
|
||||||
|
! compute the Epstein-Nesbet perturbative first order coefficient and second order energetic contribution
|
||||||
|
!
|
||||||
|
! for the various N_st states,
|
||||||
|
!
|
||||||
|
! but with the correction in the denominator
|
||||||
|
!
|
||||||
|
! comming from the interaction of that determinant with all the others determinants
|
||||||
|
!
|
||||||
|
! that can be repeated by repeating all the double excitations
|
||||||
|
!
|
||||||
|
! : you repeat all the correlation energy already taken into account in CI_electronic_energy(1)
|
||||||
|
!
|
||||||
|
! that could be repeated to this determinant.
|
||||||
|
!
|
||||||
|
! In addition, for the perturbative energetic contribution you have the standard second order
|
||||||
|
!
|
||||||
|
! e_2_pert = <psi_i|H|det_pert>^2/(Delta_E)
|
||||||
|
!
|
||||||
|
! and also the purely projected contribution
|
||||||
|
!
|
||||||
|
! H_pert_diag = <HF|H|det_pert> c_pert
|
||||||
|
END_DOC
|
||||||
|
|
||||||
|
double precision :: i_H_psi_array(N_st)
|
||||||
|
integer :: idx_repeat(0:ndet)
|
||||||
|
integer :: i,j,degree,l
|
||||||
|
double precision :: diag_H_mat_elem_fock,accu_e_corr,hij,h0j,h,delta_E
|
||||||
|
double precision :: repeat_all_e_corr,accu_e_corr_tmp,e_2_pert_fonda
|
||||||
|
|
||||||
|
ASSERT (Nint == N_int)
|
||||||
|
ASSERT (Nint > 0)
|
||||||
|
|
||||||
|
call i_H_psi_SC2(det_pert,psi_selectors,psi_selectors_coef,Nint,N_det_selectors,psi_selectors_size,N_st,i_H_psi_array,idx_repeat)
|
||||||
|
accu_e_corr = 0.d0
|
||||||
|
!$IVDEP
|
||||||
|
do i = 1, idx_repeat(0)
|
||||||
|
accu_e_corr = accu_e_corr + E_corr_per_selectors(idx_repeat(i))
|
||||||
|
enddo
|
||||||
|
h = diag_H_mat_elem_fock(det_ref,det_pert,fock_diag_tmp,Nint)
|
||||||
|
h = h + accu_e_corr
|
||||||
|
delta_E = 1.d0/(CI_SC2_electronic_energy(1) - h)
|
||||||
|
|
||||||
|
|
||||||
|
c_pert(1) = i_H_psi_array(1) /(CI_SC2_electronic_energy(1) - h)
|
||||||
|
e_2_pert(1) = i_H_psi_array(1) * c_pert(1)
|
||||||
|
|
||||||
|
do i =2,N_st
|
||||||
|
H_pert_diag(i) = h
|
||||||
|
if (dabs(CI_SC2_electronic_energy(i) - h) > 1.d-6) then
|
||||||
|
c_pert(i) = i_H_psi_array(i) / (-dabs(CI_SC2_electronic_energy(i) - h))
|
||||||
|
e_2_pert(i) = (c_pert(i) * i_H_psi_array(i))
|
||||||
|
else
|
||||||
|
c_pert(i) = i_H_psi_array(i)
|
||||||
|
e_2_pert(i) = -dabs(i_H_psi_array(i))
|
||||||
|
endif
|
||||||
|
enddo
|
||||||
|
end
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
subroutine pt2_epstein_nesbet_sc2 ($arguments)
|
||||||
|
use bitmasks
|
||||||
|
implicit none
|
||||||
|
$declarations
|
||||||
|
BEGIN_DOC
|
||||||
|
! compute the standard Epstein-Nesbet perturbative first order coefficient and second order energetic contribution
|
||||||
|
!
|
||||||
|
! for the various N_st states, but with the CISD_SC2 energies and coefficients
|
||||||
|
!
|
||||||
|
! c_pert(i) = <psi(i)|H|det_pert>/( E(i) - <det_pert|H|det_pert> )
|
||||||
|
!
|
||||||
|
! e_2_pert(i) = <psi(i)|H|det_pert>^2/( E(i) - <det_pert|H|det_pert> )
|
||||||
|
!
|
||||||
|
END_DOC
|
||||||
|
|
||||||
|
integer :: i,j
|
||||||
|
double precision :: i_H_psi_array(N_st)
|
||||||
|
double precision :: diag_H_mat_elem_fock, h
|
||||||
|
PROVIDE selection_criterion
|
||||||
|
|
||||||
|
ASSERT (Nint == N_int)
|
||||||
|
ASSERT (Nint > 0)
|
||||||
|
!call i_H_psi(det_pert,psi_selectors,psi_selectors_coef,Nint,N_det_selectors,psi_selectors_size,N_st,i_H_psi_array)
|
||||||
|
call i_H_psi_minilist(det_pert,minilist,idx_minilist,N_minilist,psi_selectors_coef,Nint,N_minilist,psi_selectors_size,N_st,i_H_psi_array)
|
||||||
|
|
||||||
|
|
||||||
|
h = diag_H_mat_elem_fock(det_ref,det_pert,fock_diag_tmp,Nint)
|
||||||
|
do i =1,N_st
|
||||||
|
if(CI_SC2_electronic_energy(i)>h.and.CI_SC2_electronic_energy(i).ne.0.d0)then
|
||||||
|
c_pert(i) = -1.d0
|
||||||
|
e_2_pert(i) = selection_criterion*selection_criterion_factor*2.d0
|
||||||
|
else if (dabs(CI_SC2_electronic_energy(i) - h) > 1.d-6) then
|
||||||
|
c_pert(i) = i_H_psi_array(i) / (CI_SC2_electronic_energy(i) - h)
|
||||||
|
H_pert_diag(i) = h*c_pert(i)*c_pert(i)
|
||||||
|
e_2_pert(i) = c_pert(i) * i_H_psi_array(i)
|
||||||
|
else
|
||||||
|
c_pert(i) = -1.d0
|
||||||
|
e_2_pert(i) = -dabs(i_H_psi_array(i))
|
||||||
|
H_pert_diag(i) = h
|
||||||
|
endif
|
||||||
|
enddo
|
||||||
|
|
||||||
|
end
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
SUBST [ arguments, declarations ]
|
||||||
|
|
||||||
|
det_ref,det_pert,fock_diag_tmp,c_pert,e_2_pert,H_pert_diag,Nint,ndet,N_st,minilist,idx_minilist,N_minilist ;
|
||||||
|
|
||||||
|
integer, intent(in) :: Nint
|
||||||
|
integer, intent(in) :: ndet
|
||||||
|
integer, intent(in) :: N_st
|
||||||
|
integer, intent(in) :: N_minilist
|
||||||
|
integer(bit_kind), intent(in) :: det_ref (Nint,2)
|
||||||
|
integer(bit_kind), intent(in) :: det_pert(Nint,2)
|
||||||
|
double precision , intent(in) :: fock_diag_tmp(2,mo_tot_num+1)
|
||||||
|
double precision , intent(out) :: c_pert(N_st)
|
||||||
|
double precision , intent(out) :: e_2_pert(N_st)
|
||||||
|
double precision, intent(out) :: H_pert_diag(N_st)
|
||||||
|
integer, intent(in) :: idx_minilist(0:N_det_selectors)
|
||||||
|
integer(bit_kind), intent(in) :: minilist(Nint,2,N_det_selectors)
|
||||||
|
;;
|
||||||
|
|
||||||
|
|
||||||
|
END_TEMPLATE
|
||||||
|
|
||||||
|
! Note : If the arguments are changed here, they should also be changed accordingly in
|
||||||
|
! the perturbation.template.f file.
|
||||||
|
|
@ -131,10 +131,10 @@ class H_apply(object):
|
|||||||
def filter_vvvv_excitation(self):
|
def filter_vvvv_excitation(self):
|
||||||
self["filter_vvvv_excitation"] = """
|
self["filter_vvvv_excitation"] = """
|
||||||
key_union_hole_part = 0_bit_kind
|
key_union_hole_part = 0_bit_kind
|
||||||
call set_bite_to_integer(i_a,key_union_hole_part,N_int)
|
call set_bit_to_integer(i_a,key_union_hole_part,N_int)
|
||||||
call set_bite_to_integer(j_a,key_union_hole_part,N_int)
|
call set_bit_to_integer(j_a,key_union_hole_part,N_int)
|
||||||
call set_bite_to_integer(i_b,key_union_hole_part,N_int)
|
call set_bit_to_integer(i_b,key_union_hole_part,N_int)
|
||||||
call set_bite_to_integer(j_b,key_union_hole_part,N_int)
|
call set_bit_to_integer(j_b,key_union_hole_part,N_int)
|
||||||
do jtest_vvvv = 1, N_int
|
do jtest_vvvv = 1, N_int
|
||||||
if(iand(key_union_hole_part(jtest_vvvv),virt_bitmask(jtest_vvvv,1).ne.key_union_hole_part(jtest_vvvv)))then
|
if(iand(key_union_hole_part(jtest_vvvv),virt_bitmask(jtest_vvvv,1).ne.key_union_hole_part(jtest_vvvv)))then
|
||||||
b_cycle = .False.
|
b_cycle = .False.
|
||||||
@ -157,7 +157,6 @@ class H_apply(object):
|
|||||||
|
|
||||||
def set_filter_2h_2p(self):
|
def set_filter_2h_2p(self):
|
||||||
self["filter2h2p"] = """
|
self["filter2h2p"] = """
|
||||||
! ! DIR$ FORCEINLINE
|
|
||||||
if (is_a_two_holes_two_particles(key)) cycle
|
if (is_a_two_holes_two_particles(key)) cycle
|
||||||
"""
|
"""
|
||||||
|
|
||||||
@ -205,7 +204,7 @@ class H_apply(object):
|
|||||||
"""
|
"""
|
||||||
self.data["keys_work"] = """
|
self.data["keys_work"] = """
|
||||||
call perturb_buffer_%s(i_generator,keys_out,key_idx,e_2_pert_buffer,coef_pert_buffer,sum_e_2_pert, &
|
call perturb_buffer_%s(i_generator,keys_out,key_idx,e_2_pert_buffer,coef_pert_buffer,sum_e_2_pert, &
|
||||||
sum_norm_pert,sum_H_pert_diag,N_st,N_int,key_mask)
|
sum_norm_pert,sum_H_pert_diag,N_st,N_int,key_mask,fock_diag_tmp)
|
||||||
"""%(pert,)
|
"""%(pert,)
|
||||||
self.data["finalization"] = """
|
self.data["finalization"] = """
|
||||||
"""
|
"""
|
||||||
|
84
src/Determinants/Fock_diag.irp.f
Normal file
84
src/Determinants/Fock_diag.irp.f
Normal file
@ -0,0 +1,84 @@
|
|||||||
|
subroutine build_fock_tmp(fock_diag_tmp,det_ref,Nint)
|
||||||
|
use bitmasks
|
||||||
|
implicit none
|
||||||
|
BEGIN_DOC
|
||||||
|
! Build the diagonal of the Fock matrix corresponding to a generator
|
||||||
|
! determinant. F_00 is <i|H|i> = E0.
|
||||||
|
END_DOC
|
||||||
|
integer, intent(in) :: Nint
|
||||||
|
integer(bit_kind), intent(in) :: det_ref(Nint,2)
|
||||||
|
double precision, intent(out) :: fock_diag_tmp(2,mo_tot_num+1)
|
||||||
|
|
||||||
|
integer :: occ(Nint*bit_kind_size,2)
|
||||||
|
integer :: ne(2), i, j, ii, jj
|
||||||
|
double precision :: E0
|
||||||
|
|
||||||
|
! Compute Fock matrix diagonal elements
|
||||||
|
call bitstring_to_list_ab(det_ref,occ,Ne,Nint)
|
||||||
|
|
||||||
|
fock_diag_tmp = 0.d0
|
||||||
|
E0 = 0.d0
|
||||||
|
|
||||||
|
! Occupied MOs
|
||||||
|
do ii=1,elec_alpha_num
|
||||||
|
i = occ(ii,1)
|
||||||
|
fock_diag_tmp(1,i) = fock_diag_tmp(1,i) + mo_mono_elec_integral(i,i)
|
||||||
|
E0 = E0 + mo_mono_elec_integral(i,i)
|
||||||
|
do jj=1,elec_alpha_num
|
||||||
|
j = occ(jj,1)
|
||||||
|
if (i==j) cycle
|
||||||
|
fock_diag_tmp(1,i) = fock_diag_tmp(1,i) + mo_bielec_integral_jj_anti(i,j)
|
||||||
|
E0 = E0 + 0.5d0*mo_bielec_integral_jj_anti(i,j)
|
||||||
|
enddo
|
||||||
|
do jj=1,elec_beta_num
|
||||||
|
j = occ(jj,2)
|
||||||
|
fock_diag_tmp(1,i) = fock_diag_tmp(1,i) + mo_bielec_integral_jj(i,j)
|
||||||
|
E0 = E0 + mo_bielec_integral_jj(i,j)
|
||||||
|
enddo
|
||||||
|
enddo
|
||||||
|
do ii=1,elec_beta_num
|
||||||
|
i = occ(ii,2)
|
||||||
|
fock_diag_tmp(2,i) = fock_diag_tmp(2,i) + mo_mono_elec_integral(i,i)
|
||||||
|
E0 = E0 + mo_mono_elec_integral(i,i)
|
||||||
|
do jj=1,elec_beta_num
|
||||||
|
j = occ(jj,2)
|
||||||
|
if (i==j) cycle
|
||||||
|
fock_diag_tmp(2,i) = fock_diag_tmp(2,i) + mo_bielec_integral_jj_anti(i,j)
|
||||||
|
E0 = E0 + 0.5d0*mo_bielec_integral_jj_anti(i,j)
|
||||||
|
enddo
|
||||||
|
do jj=1,elec_alpha_num
|
||||||
|
j = occ(jj,1)
|
||||||
|
fock_diag_tmp(2,i) = fock_diag_tmp(2,i) + mo_bielec_integral_jj(i,j)
|
||||||
|
enddo
|
||||||
|
enddo
|
||||||
|
|
||||||
|
! Virtual MOs
|
||||||
|
do i=1,mo_tot_num
|
||||||
|
if (fock_diag_tmp(1,i) /= 0.d0) cycle
|
||||||
|
fock_diag_tmp(1,i) = fock_diag_tmp(1,i) + mo_mono_elec_integral(i,i)
|
||||||
|
do jj=1,elec_alpha_num
|
||||||
|
j = occ(jj,1)
|
||||||
|
fock_diag_tmp(1,i) = fock_diag_tmp(1,i) + mo_bielec_integral_jj_anti(i,j)
|
||||||
|
enddo
|
||||||
|
do jj=1,elec_beta_num
|
||||||
|
j = occ(jj,2)
|
||||||
|
fock_diag_tmp(1,i) = fock_diag_tmp(1,i) + mo_bielec_integral_jj(i,j)
|
||||||
|
enddo
|
||||||
|
enddo
|
||||||
|
do i=1,mo_tot_num
|
||||||
|
if (fock_diag_tmp(2,i) /= 0.d0) cycle
|
||||||
|
fock_diag_tmp(2,i) = fock_diag_tmp(2,i) + mo_mono_elec_integral(i,i)
|
||||||
|
do jj=1,elec_beta_num
|
||||||
|
j = occ(jj,2)
|
||||||
|
fock_diag_tmp(2,i) = fock_diag_tmp(2,i) + mo_bielec_integral_jj_anti(i,j)
|
||||||
|
enddo
|
||||||
|
do jj=1,elec_alpha_num
|
||||||
|
j = occ(jj,1)
|
||||||
|
fock_diag_tmp(2,i) = fock_diag_tmp(2,i) + mo_bielec_integral_jj(i,j)
|
||||||
|
enddo
|
||||||
|
enddo
|
||||||
|
|
||||||
|
fock_diag_tmp(1,mo_tot_num+1) = E0
|
||||||
|
fock_diag_tmp(2,mo_tot_num+1) = E0
|
||||||
|
|
||||||
|
end
|
@ -1,6 +1,6 @@
|
|||||||
|
|
||||||
|
|
||||||
subroutine $subroutine_diexc(key_in, key_prev, hole_1,particl_1, hole_2, particl_2, i_generator, iproc_in $parameters )
|
subroutine $subroutine_diexc(key_in, key_prev, hole_1,particl_1, hole_2, particl_2, fock_diag_tmp, i_generator, iproc_in $parameters )
|
||||||
|
|
||||||
integer(bit_kind), intent(in) :: key_in(N_int, 2), hole_1(N_int, 2), hole_2(N_int, 2)
|
integer(bit_kind), intent(in) :: key_in(N_int, 2), hole_1(N_int, 2), hole_2(N_int, 2)
|
||||||
integer(bit_kind), intent(in) :: particl_1(N_int, 2), particl_2(N_int, 2)
|
integer(bit_kind), intent(in) :: particl_1(N_int, 2), particl_2(N_int, 2)
|
||||||
@ -8,7 +8,7 @@ subroutine $subroutine_diexc(key_in, key_prev, hole_1,particl_1, hole_2, particl
|
|||||||
integer,intent(in) :: i_generator,iproc_in
|
integer,intent(in) :: i_generator,iproc_in
|
||||||
integer(bit_kind) :: status(N_int*bit_kind_size, 2)
|
integer(bit_kind) :: status(N_int*bit_kind_size, 2)
|
||||||
integer :: highest, p1,p2,sp,ni,i,mi,nt,ns
|
integer :: highest, p1,p2,sp,ni,i,mi,nt,ns
|
||||||
|
double precision, intent(in) :: fock_diag_tmp(2,mo_tot_num+1)
|
||||||
integer(bit_kind), intent(in) :: key_prev(N_int, 2, *)
|
integer(bit_kind), intent(in) :: key_prev(N_int, 2, *)
|
||||||
PROVIDE N_int
|
PROVIDE N_int
|
||||||
PROVIDE N_det
|
PROVIDE N_det
|
||||||
@ -72,7 +72,7 @@ subroutine $subroutine_diexc(key_in, key_prev, hole_1,particl_1, hole_2, particl
|
|||||||
if((status(p1, sp) == 1 .and. status(p2, sp) > 1) .or. &
|
if((status(p1, sp) == 1 .and. status(p2, sp) > 1) .or. &
|
||||||
(status(p1, sp) == 2 .and. status(p2, sp) == 3) .or. &
|
(status(p1, sp) == 2 .and. status(p2, sp) == 3) .or. &
|
||||||
(status(p1, sp) == 3 .and. status(p2, sp) == 3 .and. p2 > p1)) then
|
(status(p1, sp) == 3 .and. status(p2, sp) == 3 .and. p2 > p1)) then
|
||||||
call $subroutine_diexcP(key_in, sp, p1, particl_1, sp, p2, particl_2, i_generator, iproc_in $parameters )
|
call $subroutine_diexcP(key_in, sp, p1, particl_1, sp, p2, particl_2, fock_diag_tmp, i_generator, iproc_in $parameters )
|
||||||
end if
|
end if
|
||||||
end do
|
end do
|
||||||
end do
|
end do
|
||||||
@ -89,16 +89,17 @@ subroutine $subroutine_diexc(key_in, key_prev, hole_1,particl_1, hole_2, particl
|
|||||||
(status(p1, 1) == 1 .and. status(p2, 2) >= 2) .or. &
|
(status(p1, 1) == 1 .and. status(p2, 2) >= 2) .or. &
|
||||||
(status(p1, 1) == 2 .and. status(p2, 2) /= 2)) then
|
(status(p1, 1) == 2 .and. status(p2, 2) /= 2)) then
|
||||||
|
|
||||||
call $subroutine_diexcP(key_in, 1, p1, particl_1, 2, p2, particl_2, i_generator, iproc_in $parameters )
|
call $subroutine_diexcP(key_in, 1, p1, particl_1, 2, p2, particl_2, fock_diag_tmp, i_generator, iproc_in $parameters )
|
||||||
end if
|
end if
|
||||||
end do
|
end do
|
||||||
end do
|
end do
|
||||||
end subroutine
|
end subroutine
|
||||||
|
|
||||||
|
|
||||||
subroutine $subroutine_diexcP(key_in, fs1, fh1, particl_1, fs2, fh2, particl_2, i_generator, iproc_in $parameters )
|
subroutine $subroutine_diexcP(key_in, fs1, fh1, particl_1, fs2, fh2, particl_2, fock_diag_tmp, i_generator, iproc_in $parameters )
|
||||||
|
|
||||||
integer(bit_kind), intent(in) :: key_in(N_int, 2), particl_1(N_int, 2), particl_2(N_int, 2)
|
integer(bit_kind), intent(in) :: key_in(N_int, 2), particl_1(N_int, 2), particl_2(N_int, 2)
|
||||||
|
double precision, intent(in) :: fock_diag_tmp(2,mo_tot_num+1)
|
||||||
integer(bit_kind) :: p1_mask(N_int, 2), p2_mask(N_int, 2), key_mask(N_int, 2)
|
integer(bit_kind) :: p1_mask(N_int, 2), p2_mask(N_int, 2), key_mask(N_int, 2)
|
||||||
integer,intent(in) :: fh1,fh2,fs1,fs2,i_generator,iproc_in
|
integer,intent(in) :: fh1,fh2,fs1,fs2,i_generator,iproc_in
|
||||||
integer(bit_kind) :: miniList(N_int, 2, N_det)
|
integer(bit_kind) :: miniList(N_int, 2, N_det)
|
||||||
@ -115,11 +116,11 @@ subroutine $subroutine_diexcP(key_in, fs1, fh1, particl_1, fs2, fh2, particl_2,
|
|||||||
key_mask(ishft(fh1,-bit_kind_shift) + 1, fs1) -= ishft(1,iand(fh1-1,bit_kind_size-1))
|
key_mask(ishft(fh1,-bit_kind_shift) + 1, fs1) -= ishft(1,iand(fh1-1,bit_kind_size-1))
|
||||||
key_mask(ishft(fh2,-bit_kind_shift) + 1, fs2) -= ishft(1,iand(fh2-1,bit_kind_size-1))
|
key_mask(ishft(fh2,-bit_kind_shift) + 1, fs2) -= ishft(1,iand(fh2-1,bit_kind_size-1))
|
||||||
|
|
||||||
call $subroutine_diexcOrg(key_in, key_mask, p1_mask, particl_1, p2_mask, particl_2, i_generator, iproc_in $parameters )
|
call $subroutine_diexcOrg(key_in, key_mask, p1_mask, particl_1, p2_mask, particl_2, fock_diag_tmp, i_generator, iproc_in $parameters )
|
||||||
end subroutine
|
end subroutine
|
||||||
|
|
||||||
|
|
||||||
subroutine $subroutine_diexcOrg(key_in,key_mask,hole_1,particl_1,hole_2, particl_2, i_generator, iproc_in $parameters )
|
subroutine $subroutine_diexcOrg(key_in,key_mask,hole_1,particl_1,hole_2, particl_2, fock_diag_tmp, i_generator, iproc_in $parameters )
|
||||||
use omp_lib
|
use omp_lib
|
||||||
use bitmasks
|
use bitmasks
|
||||||
implicit none
|
implicit none
|
||||||
@ -136,6 +137,7 @@ subroutine $subroutine_diexcOrg(key_in,key_mask,hole_1,particl_1,hole_2, particl
|
|||||||
integer(bit_kind), intent(in) :: hole_1(N_int,2), particl_1(N_int,2)
|
integer(bit_kind), intent(in) :: hole_1(N_int,2), particl_1(N_int,2)
|
||||||
integer(bit_kind), intent(in) :: hole_2(N_int,2), particl_2(N_int,2)
|
integer(bit_kind), intent(in) :: hole_2(N_int,2), particl_2(N_int,2)
|
||||||
integer, intent(in) :: iproc_in
|
integer, intent(in) :: iproc_in
|
||||||
|
double precision, intent(in) :: fock_diag_tmp(2,mo_tot_num+1)
|
||||||
integer(bit_kind), allocatable :: hole_save(:,:)
|
integer(bit_kind), allocatable :: hole_save(:,:)
|
||||||
integer(bit_kind), allocatable :: key(:,:),hole(:,:), particle(:,:)
|
integer(bit_kind), allocatable :: key(:,:),hole(:,:), particle(:,:)
|
||||||
integer(bit_kind), allocatable :: hole_tmp(:,:), particle_tmp(:,:)
|
integer(bit_kind), allocatable :: hole_tmp(:,:), particle_tmp(:,:)
|
||||||
@ -175,6 +177,7 @@ subroutine $subroutine_diexcOrg(key_in,key_mask,hole_1,particl_1,hole_2, particl
|
|||||||
particle_tmp(N_int,2), occ_particle(N_int*bit_kind_size,2), &
|
particle_tmp(N_int,2), occ_particle(N_int*bit_kind_size,2), &
|
||||||
occ_hole(N_int*bit_kind_size,2), occ_particle_tmp(N_int*bit_kind_size,2),&
|
occ_hole(N_int*bit_kind_size,2), occ_particle_tmp(N_int*bit_kind_size,2),&
|
||||||
occ_hole_tmp(N_int*bit_kind_size,2),key_union_hole_part(N_int))
|
occ_hole_tmp(N_int*bit_kind_size,2),key_union_hole_part(N_int))
|
||||||
|
|
||||||
$init_thread
|
$init_thread
|
||||||
|
|
||||||
|
|
||||||
@ -372,7 +375,7 @@ subroutine $subroutine_diexcOrg(key_in,key_mask,hole_1,particl_1,hole_2, particl
|
|||||||
$finalization
|
$finalization
|
||||||
end
|
end
|
||||||
|
|
||||||
subroutine $subroutine_monoexc(key_in, hole_1,particl_1,i_generator,iproc_in $parameters )
|
subroutine $subroutine_monoexc(key_in, hole_1,particl_1,fock_diag_tmp,i_generator,iproc_in $parameters )
|
||||||
use omp_lib
|
use omp_lib
|
||||||
use bitmasks
|
use bitmasks
|
||||||
implicit none
|
implicit none
|
||||||
@ -387,6 +390,7 @@ subroutine $subroutine_monoexc(key_in, hole_1,particl_1,i_generator,iproc_in $pa
|
|||||||
integer(bit_kind),intent(in) :: key_in(N_int,2)
|
integer(bit_kind),intent(in) :: key_in(N_int,2)
|
||||||
integer(bit_kind),intent(in) :: hole_1(N_int,2), particl_1(N_int,2)
|
integer(bit_kind),intent(in) :: hole_1(N_int,2), particl_1(N_int,2)
|
||||||
integer, intent(in) :: iproc_in
|
integer, intent(in) :: iproc_in
|
||||||
|
double precision, intent(in) :: fock_diag_tmp(2,mo_tot_num+1)
|
||||||
integer(bit_kind),allocatable :: keys_out(:,:,:)
|
integer(bit_kind),allocatable :: keys_out(:,:,:)
|
||||||
integer(bit_kind),allocatable :: hole_save(:,:)
|
integer(bit_kind),allocatable :: hole_save(:,:)
|
||||||
integer(bit_kind),allocatable :: key(:,:),hole(:,:), particle(:,:)
|
integer(bit_kind),allocatable :: key(:,:),hole(:,:), particle(:,:)
|
||||||
@ -526,6 +530,7 @@ subroutine $subroutine($params_main)
|
|||||||
integer(bit_kind), allocatable :: mask(:,:,:)
|
integer(bit_kind), allocatable :: mask(:,:,:)
|
||||||
integer :: ispin, k
|
integer :: ispin, k
|
||||||
integer :: iproc
|
integer :: iproc
|
||||||
|
double precision, allocatable :: fock_diag_tmp(:,:)
|
||||||
|
|
||||||
$initialization
|
$initialization
|
||||||
PROVIDE H_apply_buffer_allocated mo_bielec_integrals_in_map psi_det_generators psi_coef_generators
|
PROVIDE H_apply_buffer_allocated mo_bielec_integrals_in_map psi_det_generators psi_coef_generators
|
||||||
@ -539,7 +544,7 @@ subroutine $subroutine($params_main)
|
|||||||
call wall_time(wall_0)
|
call wall_time(wall_0)
|
||||||
|
|
||||||
iproc = 0
|
iproc = 0
|
||||||
allocate( mask(N_int,2,6) )
|
allocate( mask(N_int,2,6), fock_diag_tmp(2,mo_tot_num+1) )
|
||||||
do i_generator=1,nmax
|
do i_generator=1,nmax
|
||||||
|
|
||||||
progress_bar(1) = i_generator
|
progress_bar(1) = i_generator
|
||||||
@ -549,6 +554,9 @@ subroutine $subroutine($params_main)
|
|||||||
endif
|
endif
|
||||||
$skip
|
$skip
|
||||||
|
|
||||||
|
! Compute diagonal of the Fock matrix
|
||||||
|
call build_fock_tmp(fock_diag_tmp,psi_det_generators(1,1,i_generator),N_int)
|
||||||
|
|
||||||
! Create bit masks for holes and particles
|
! Create bit masks for holes and particles
|
||||||
do ispin=1,2
|
do ispin=1,2
|
||||||
do k=1,N_int
|
do k=1,N_int
|
||||||
@ -577,12 +585,12 @@ subroutine $subroutine($params_main)
|
|||||||
psi_det_generators(1,1,1), &
|
psi_det_generators(1,1,1), &
|
||||||
mask(1,1,d_hole1), mask(1,1,d_part1), &
|
mask(1,1,d_hole1), mask(1,1,d_part1), &
|
||||||
mask(1,1,d_hole2), mask(1,1,d_part2), &
|
mask(1,1,d_hole2), mask(1,1,d_part2), &
|
||||||
i_generator, iproc $params_post)
|
fock_diag_tmp, i_generator, iproc $params_post)
|
||||||
endif
|
endif
|
||||||
if($do_mono_excitations)then
|
if($do_mono_excitations)then
|
||||||
call $subroutine_monoexc(psi_det_generators(1,1,i_generator), &
|
call $subroutine_monoexc(psi_det_generators(1,1,i_generator), &
|
||||||
mask(1,1,s_hole ), mask(1,1,s_part ), &
|
mask(1,1,s_hole ), mask(1,1,s_part ), &
|
||||||
i_generator, iproc $params_post)
|
fock_diag_tmp, i_generator, iproc $params_post)
|
||||||
endif
|
endif
|
||||||
call wall_time(wall_1)
|
call wall_time(wall_1)
|
||||||
$printout_always
|
$printout_always
|
||||||
@ -592,13 +600,13 @@ subroutine $subroutine($params_main)
|
|||||||
endif
|
endif
|
||||||
enddo
|
enddo
|
||||||
|
|
||||||
deallocate( mask )
|
deallocate( mask, fock_diag_tmp )
|
||||||
|
|
||||||
!$OMP PARALLEL DEFAULT(SHARED) &
|
!$OMP PARALLEL DEFAULT(SHARED) &
|
||||||
!$OMP PRIVATE(i_generator,wall_1,wall_0,ispin,k,mask,iproc)
|
!$OMP PRIVATE(i_generator,wall_1,wall_0,ispin,k,mask,iproc,fock_diag_tmp)
|
||||||
call wall_time(wall_0)
|
call wall_time(wall_0)
|
||||||
!$ iproc = omp_get_thread_num()
|
!$ iproc = omp_get_thread_num()
|
||||||
allocate( mask(N_int,2,6) )
|
allocate( mask(N_int,2,6), fock_diag_tmp(2,mo_tot_num+1) )
|
||||||
!$OMP DO SCHEDULE(dynamic,1)
|
!$OMP DO SCHEDULE(dynamic,1)
|
||||||
do i_generator=nmax+1,N_det_generators
|
do i_generator=nmax+1,N_det_generators
|
||||||
if (iproc == 0) then
|
if (iproc == 0) then
|
||||||
@ -609,6 +617,9 @@ subroutine $subroutine($params_main)
|
|||||||
endif
|
endif
|
||||||
$skip
|
$skip
|
||||||
|
|
||||||
|
! Compute diagonal of the Fock matrix
|
||||||
|
call build_fock_tmp(fock_diag_tmp,psi_det_generators(1,1,i_generator),N_int)
|
||||||
|
|
||||||
! Create bit masks for holes and particles
|
! Create bit masks for holes and particles
|
||||||
do ispin=1,2
|
do ispin=1,2
|
||||||
do k=1,N_int
|
do k=1,N_int
|
||||||
@ -638,12 +649,12 @@ subroutine $subroutine($params_main)
|
|||||||
psi_det_generators(1,1,1), &
|
psi_det_generators(1,1,1), &
|
||||||
mask(1,1,d_hole1), mask(1,1,d_part1), &
|
mask(1,1,d_hole1), mask(1,1,d_part1), &
|
||||||
mask(1,1,d_hole2), mask(1,1,d_part2), &
|
mask(1,1,d_hole2), mask(1,1,d_part2), &
|
||||||
i_generator, iproc $params_post)
|
fock_diag_tmp, i_generator, iproc $params_post)
|
||||||
endif
|
endif
|
||||||
if($do_mono_excitations)then
|
if($do_mono_excitations)then
|
||||||
call $subroutine_monoexc(psi_det_generators(1,1,i_generator), &
|
call $subroutine_monoexc(psi_det_generators(1,1,i_generator), &
|
||||||
mask(1,1,s_hole ), mask(1,1,s_part ), &
|
mask(1,1,s_hole ), mask(1,1,s_part ), &
|
||||||
i_generator, iproc $params_post)
|
fock_diag_tmp, i_generator, iproc $params_post)
|
||||||
endif
|
endif
|
||||||
!$ call omp_set_lock(lck)
|
!$ call omp_set_lock(lck)
|
||||||
call wall_time(wall_1)
|
call wall_time(wall_1)
|
||||||
@ -655,7 +666,7 @@ subroutine $subroutine($params_main)
|
|||||||
!$ call omp_unset_lock(lck)
|
!$ call omp_unset_lock(lck)
|
||||||
enddo
|
enddo
|
||||||
!$OMP END DO
|
!$OMP END DO
|
||||||
deallocate( mask )
|
deallocate( mask, fock_diag_tmp )
|
||||||
!$OMP END PARALLEL
|
!$OMP END PARALLEL
|
||||||
!$ call omp_destroy_lock(lck)
|
!$ call omp_destroy_lock(lck)
|
||||||
|
|
||||||
|
@ -15,19 +15,19 @@ Documentation
|
|||||||
.. by the `update_README.py` script.
|
.. by the `update_README.py` script.
|
||||||
|
|
||||||
|
|
||||||
`a_operator <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/slater_rules.irp.f#L1110>`_
|
`a_operator <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/slater_rules.irp.f#L1398>`_
|
||||||
Needed for diag_H_mat_elem
|
Needed for diag_H_mat_elem
|
||||||
|
|
||||||
|
|
||||||
`abs_psi_coef_max <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/determinants.irp.f#L451>`_
|
`abs_psi_coef_max <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/determinants.irp.f#L452>`_
|
||||||
Max and min values of the coefficients
|
Max and min values of the coefficients
|
||||||
|
|
||||||
|
|
||||||
`abs_psi_coef_min <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/determinants.irp.f#L452>`_
|
`abs_psi_coef_min <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/determinants.irp.f#L453>`_
|
||||||
Max and min values of the coefficients
|
Max and min values of the coefficients
|
||||||
|
|
||||||
|
|
||||||
`ac_operator <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/slater_rules.irp.f#L1155>`_
|
`ac_operator <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/slater_rules.irp.f#L1444>`_
|
||||||
Needed for diag_H_mat_elem
|
Needed for diag_H_mat_elem
|
||||||
|
|
||||||
|
|
||||||
@ -39,6 +39,21 @@ Documentation
|
|||||||
Energy of the reference bitmask used in Slater rules
|
Energy of the reference bitmask used in Slater rules
|
||||||
|
|
||||||
|
|
||||||
|
`bitstring_to_list_ab <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/slater_rules.irp.f#L352>`_
|
||||||
|
Gives the inidices(+1) of the bits set to 1 in the bit string
|
||||||
|
For alpha/beta determinants
|
||||||
|
|
||||||
|
|
||||||
|
`bitstring_to_list_ab_old <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/slater_rules.irp.f#L390>`_
|
||||||
|
Gives the inidices(+1) of the bits set to 1 in the bit string
|
||||||
|
For alpha/beta determinants
|
||||||
|
|
||||||
|
|
||||||
|
`build_fock_tmp <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/Fock_diag.irp.f#L1>`_
|
||||||
|
Build the diagonal of the Fock matrix corresponding to a generator
|
||||||
|
determinant. F_00 is <i|H|i> = E0.
|
||||||
|
|
||||||
|
|
||||||
`ci_eigenvectors <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/diagonalize_CI.irp.f#L37>`_
|
`ci_eigenvectors <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/diagonalize_CI.irp.f#L37>`_
|
||||||
Eigenvectors/values of the CI matrix
|
Eigenvectors/values of the CI matrix
|
||||||
|
|
||||||
@ -100,29 +115,37 @@ Documentation
|
|||||||
Initial guess vectors are not necessarily orthonormal
|
Initial guess vectors are not necessarily orthonormal
|
||||||
|
|
||||||
|
|
||||||
`connected_to_ref <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/connected_to_ref.irp.f#L157>`_
|
`connected_to_ref <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/connected_to_ref.irp.f#L192>`_
|
||||||
Undocumented
|
Undocumented
|
||||||
|
|
||||||
|
|
||||||
`connected_to_ref_by_mono <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/connected_to_ref.irp.f#L255>`_
|
`connected_to_ref_by_mono <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/connected_to_ref.irp.f#L290>`_
|
||||||
Undocumented
|
Undocumented
|
||||||
|
|
||||||
|
|
||||||
`copy_h_apply_buffer_to_wf <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/H_apply.irp.f#L103>`_
|
`copy_h_apply_buffer_to_wf <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/H_apply.irp.f#L112>`_
|
||||||
Copies the H_apply buffer to psi_coef.
|
Copies the H_apply buffer to psi_coef.
|
||||||
After calling this subroutine, N_det, psi_det and psi_coef need to be touched
|
After calling this subroutine, N_det, psi_det and psi_coef need to be touched
|
||||||
|
|
||||||
|
|
||||||
|
`create_minilist <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/slater_rules.irp.f#L840>`_
|
||||||
|
Undocumented
|
||||||
|
|
||||||
|
|
||||||
|
`create_minilist_find_previous <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/slater_rules.irp.f#L887>`_
|
||||||
|
Undocumented
|
||||||
|
|
||||||
|
|
||||||
`create_wf_of_psi_bilinear_matrix <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/spindeterminants.irp.f#L445>`_
|
`create_wf_of_psi_bilinear_matrix <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/spindeterminants.irp.f#L445>`_
|
||||||
Generate a wave function containing all possible products
|
Generate a wave function containing all possible products
|
||||||
of alpha and beta determinants
|
of alpha and beta determinants
|
||||||
|
|
||||||
|
|
||||||
`davidson_converged <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/davidson.irp.f#L565>`_
|
`davidson_converged <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/davidson.irp.f#L604>`_
|
||||||
True if the Davidson algorithm is converged
|
True if the Davidson algorithm is converged
|
||||||
|
|
||||||
|
|
||||||
`davidson_criterion <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/davidson.irp.f#L555>`_
|
`davidson_criterion <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/davidson.irp.f#L596>`_
|
||||||
Can be : [ energy | residual | both | wall_time | cpu_time | iterations ]
|
Can be : [ energy | residual | both | wall_time | cpu_time | iterations ]
|
||||||
|
|
||||||
|
|
||||||
@ -145,7 +168,7 @@ Documentation
|
|||||||
Initial guess vectors are not necessarily orthonormal
|
Initial guess vectors are not necessarily orthonormal
|
||||||
|
|
||||||
|
|
||||||
`davidson_diag_hjj <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/davidson.irp.f#L241>`_
|
`davidson_diag_hjj <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/davidson.irp.f#L288>`_
|
||||||
Davidson diagonalization with specific diagonal elements of the H matrix
|
Davidson diagonalization with specific diagonal elements of the H matrix
|
||||||
.br
|
.br
|
||||||
H_jj : specific diagonal H matrix elements to diagonalize de Davidson
|
H_jj : specific diagonal H matrix elements to diagonalize de Davidson
|
||||||
@ -174,10 +197,6 @@ Documentation
|
|||||||
Max number of Davidson sizes
|
Max number of Davidson sizes
|
||||||
|
|
||||||
|
|
||||||
`davidson_threshold <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/davidson.irp.f#L556>`_
|
|
||||||
Can be : [ energy | residual | both | wall_time | cpu_time | iterations ]
|
|
||||||
|
|
||||||
|
|
||||||
`decode_exc <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/slater_rules.irp.f#L76>`_
|
`decode_exc <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/slater_rules.irp.f#L76>`_
|
||||||
Decodes the exc arrays returned by get_excitation.
|
Decodes the exc arrays returned by get_excitation.
|
||||||
h1,h2 : Holes
|
h1,h2 : Holes
|
||||||
@ -206,7 +225,7 @@ Documentation
|
|||||||
Undocumented
|
Undocumented
|
||||||
|
|
||||||
|
|
||||||
`det_occ <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/ezfio_interface.irp.f#L226>`_
|
`det_occ <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/ezfio_interface.irp.f#L248>`_
|
||||||
det_occ
|
det_occ
|
||||||
|
|
||||||
|
|
||||||
@ -222,10 +241,15 @@ Documentation
|
|||||||
Diagonalization algorithm (Davidson or Lapack)
|
Diagonalization algorithm (Davidson or Lapack)
|
||||||
|
|
||||||
|
|
||||||
`diag_h_mat_elem <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/slater_rules.irp.f#L1048>`_
|
`diag_h_mat_elem <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/slater_rules.irp.f#L1336>`_
|
||||||
Computes <i|H|i>
|
Computes <i|H|i>
|
||||||
|
|
||||||
|
|
||||||
|
`diag_h_mat_elem_fock <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/slater_rules.irp.f#L1267>`_
|
||||||
|
Computes <i|H|i> when i is at most a double excitation from
|
||||||
|
a reference.
|
||||||
|
|
||||||
|
|
||||||
`diagonalize_ci <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/diagonalize_CI.irp.f#L105>`_
|
`diagonalize_ci <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/diagonalize_CI.irp.f#L105>`_
|
||||||
Replace the coefficients of the CI states by the coefficients of the
|
Replace the coefficients of the CI states by the coefficients of the
|
||||||
eigenstates of the CI matrix
|
eigenstates of the CI matrix
|
||||||
@ -262,11 +286,11 @@ Documentation
|
|||||||
Expected value of S2 : S*(S+1)
|
Expected value of S2 : S*(S+1)
|
||||||
|
|
||||||
|
|
||||||
`fill_h_apply_buffer_no_selection <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/H_apply.irp.f#L258>`_
|
`fill_h_apply_buffer_no_selection <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/H_apply.irp.f#L266>`_
|
||||||
Fill the H_apply buffer with determiants for CISD
|
Fill the H_apply buffer with determiants for CISD
|
||||||
|
|
||||||
|
|
||||||
`filter_3_highest_electrons <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/determinants.irp.f#L423>`_
|
`filter_3_highest_electrons <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/determinants.irp.f#L424>`_
|
||||||
Returns a determinant with only the 3 highest electrons
|
Returns a determinant with only the 3 highest electrons
|
||||||
|
|
||||||
|
|
||||||
@ -282,17 +306,7 @@ Documentation
|
|||||||
idx(0) is the number of determinants that interact with key1
|
idx(0) is the number of determinants that interact with key1
|
||||||
|
|
||||||
|
|
||||||
`filter_connected_davidson_warp <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/filter_connected.irp.f#L102>`_
|
`filter_connected_i_h_psi0 <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/filter_connected.irp.f#L101>`_
|
||||||
Filters out the determinants that are not connected by H
|
|
||||||
returns the array idx which contains the index of the
|
|
||||||
determinants in the array key1 that interact
|
|
||||||
via the H operator with key2.
|
|
||||||
.br
|
|
||||||
idx(0) is the number of determinants that interact with key1
|
|
||||||
key1 should come from psi_det_sorted_ab.
|
|
||||||
|
|
||||||
|
|
||||||
`filter_connected_i_h_psi0 <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/filter_connected.irp.f#L390>`_
|
|
||||||
returns the array idx which contains the index of the
|
returns the array idx which contains the index of the
|
||||||
.br
|
.br
|
||||||
determinants in the array key1 that interact
|
determinants in the array key1 that interact
|
||||||
@ -302,7 +316,7 @@ Documentation
|
|||||||
idx(0) is the number of determinants that interact with key1
|
idx(0) is the number of determinants that interact with key1
|
||||||
|
|
||||||
|
|
||||||
`filter_connected_i_h_psi0_sc2 <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/filter_connected.irp.f#L489>`_
|
`filter_connected_i_h_psi0_sc2 <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/filter_connected.irp.f#L205>`_
|
||||||
standard filter_connected_i_H_psi but returns in addition
|
standard filter_connected_i_H_psi but returns in addition
|
||||||
.br
|
.br
|
||||||
the array of the index of the non connected determinants to key1
|
the array of the index of the non connected determinants to key1
|
||||||
@ -314,7 +328,11 @@ Documentation
|
|||||||
to repeat the excitations
|
to repeat the excitations
|
||||||
|
|
||||||
|
|
||||||
`generate_all_alpha_beta_det_products <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/spindeterminants.irp.f#L500>`_
|
`first_guess <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/guess_lowest_state.irp.f#L1>`_
|
||||||
|
Select all the determinants with the lowest energy as a starting point.
|
||||||
|
|
||||||
|
|
||||||
|
`generate_all_alpha_beta_det_products <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/spindeterminants.irp.f#L503>`_
|
||||||
Create a wave function from all possible alpha x beta determinants
|
Create a wave function from all possible alpha x beta determinants
|
||||||
|
|
||||||
|
|
||||||
@ -330,7 +348,7 @@ Documentation
|
|||||||
Returns the excitation degree between two determinants
|
Returns the excitation degree between two determinants
|
||||||
|
|
||||||
|
|
||||||
`get_excitation_degree_vector <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/slater_rules.irp.f#L953>`_
|
`get_excitation_degree_vector <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/slater_rules.irp.f#L1172>`_
|
||||||
Applies get_excitation_degree to an array of determinants
|
Applies get_excitation_degree to an array of determinants
|
||||||
|
|
||||||
|
|
||||||
@ -350,7 +368,7 @@ Documentation
|
|||||||
Returns the excitation operator between two singly excited determinants and the phase
|
Returns the excitation operator between two singly excited determinants and the phase
|
||||||
|
|
||||||
|
|
||||||
`get_occ_from_key <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/slater_rules.irp.f#L1203>`_
|
`get_occ_from_key <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/slater_rules.irp.f#L1490>`_
|
||||||
Returns a list of occupation numbers from a bitstring
|
Returns a list of occupation numbers from a bitstring
|
||||||
|
|
||||||
|
|
||||||
@ -384,7 +402,7 @@ Documentation
|
|||||||
Undocumented
|
Undocumented
|
||||||
|
|
||||||
|
|
||||||
`h_u_0 <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/slater_rules.irp.f#L1219>`_
|
`h_u_0 <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/slater_rules.irp.f#L1506>`_
|
||||||
Computes v_0 = H|u_0>
|
Computes v_0 = H|u_0>
|
||||||
.br
|
.br
|
||||||
n : number of determinants
|
n : number of determinants
|
||||||
@ -392,23 +410,35 @@ Documentation
|
|||||||
H_jj : array of <j|H|j>
|
H_jj : array of <j|H|j>
|
||||||
|
|
||||||
|
|
||||||
`i_h_j <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/slater_rules.irp.f#L356>`_
|
`i_h_j <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/slater_rules.irp.f#L430>`_
|
||||||
Returns <i|H|j> where i and j are determinants
|
Returns <i|H|j> where i and j are determinants
|
||||||
|
|
||||||
|
|
||||||
`i_h_j_phase_out <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/slater_rules.irp.f#L492>`_
|
`i_h_j_phase_out <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/slater_rules.irp.f#L566>`_
|
||||||
Returns <i|H|j> where i and j are determinants
|
Returns <i|H|j> where i and j are determinants
|
||||||
|
|
||||||
|
|
||||||
`i_h_j_verbose <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/slater_rules.irp.f#L628>`_
|
`i_h_j_verbose <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/slater_rules.irp.f#L702>`_
|
||||||
Returns <i|H|j> where i and j are determinants
|
Returns <i|H|j> where i and j are determinants
|
||||||
|
|
||||||
|
|
||||||
`i_h_psi <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/slater_rules.irp.f#L767>`_
|
`i_h_psi <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/slater_rules.irp.f#L940>`_
|
||||||
<key|H|psi> for the various Nstates
|
Computes <i|H|Psi> = \sum_J c_J <i|H|J>.
|
||||||
|
.br
|
||||||
|
Uses filter_connected_i_H_psi0 to get all the |J> to which |i>
|
||||||
|
is connected.
|
||||||
|
The i_H_psi_minilist is much faster but requires to build the
|
||||||
|
minilists
|
||||||
|
|
||||||
|
|
||||||
`i_h_psi_sc2 <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/slater_rules.irp.f#L850>`_
|
`i_h_psi_minilist <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/slater_rules.irp.f#L982>`_
|
||||||
|
Computes <i|H|Psi> = \sum_J c_J <i|H|J>.
|
||||||
|
.br
|
||||||
|
Uses filter_connected_i_H_psi0 to get all the |J> to which |i>
|
||||||
|
is connected. The |J> are searched in short pre-computed lists.
|
||||||
|
|
||||||
|
|
||||||
|
`i_h_psi_sc2 <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/slater_rules.irp.f#L1069>`_
|
||||||
<key|H|psi> for the various Nstate
|
<key|H|psi> for the various Nstate
|
||||||
.br
|
.br
|
||||||
returns in addition
|
returns in addition
|
||||||
@ -422,7 +452,7 @@ Documentation
|
|||||||
to repeat the excitations
|
to repeat the excitations
|
||||||
|
|
||||||
|
|
||||||
`i_h_psi_sc2_verbose <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/slater_rules.irp.f#L897>`_
|
`i_h_psi_sc2_verbose <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/slater_rules.irp.f#L1116>`_
|
||||||
<key|H|psi> for the various Nstate
|
<key|H|psi> for the various Nstate
|
||||||
.br
|
.br
|
||||||
returns in addition
|
returns in addition
|
||||||
@ -436,7 +466,7 @@ Documentation
|
|||||||
to repeat the excitations
|
to repeat the excitations
|
||||||
|
|
||||||
|
|
||||||
`i_h_psi_sec_ord <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/slater_rules.irp.f#L803>`_
|
`i_h_psi_sec_ord <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/slater_rules.irp.f#L1022>`_
|
||||||
<key|H|psi> for the various Nstates
|
<key|H|psi> for the various Nstates
|
||||||
|
|
||||||
|
|
||||||
@ -451,7 +481,7 @@ Documentation
|
|||||||
idx_non_cas gives the indice of the determinant in psi_det.
|
idx_non_cas gives the indice of the determinant in psi_det.
|
||||||
|
|
||||||
|
|
||||||
`int_of_3_highest_electrons <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/determinants.irp.f#L388>`_
|
`int_of_3_highest_electrons <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/determinants.irp.f#L389>`_
|
||||||
Returns an integer*8 as :
|
Returns an integer*8 as :
|
||||||
.br
|
.br
|
||||||
|_<--- 21 bits ---><--- 21 bits ---><--- 21 bits --->|
|
|_<--- 21 bits ---><--- 21 bits ---><--- 21 bits --->|
|
||||||
@ -463,6 +493,10 @@ Documentation
|
|||||||
.br
|
.br
|
||||||
|
|
||||||
|
|
||||||
|
`is_connected_to <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/connected_to_ref.irp.f#L158>`_
|
||||||
|
Undocumented
|
||||||
|
|
||||||
|
|
||||||
`is_in_wavefunction <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/connected_to_ref.irp.f#L36>`_
|
`is_in_wavefunction <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/connected_to_ref.irp.f#L36>`_
|
||||||
True if the determinant ``det`` is in the wave function
|
True if the determinant ``det`` is in the wave function
|
||||||
|
|
||||||
@ -475,7 +509,7 @@ Documentation
|
|||||||
Undocumented
|
Undocumented
|
||||||
|
|
||||||
|
|
||||||
`max_degree_exc <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/determinants.irp.f#L32>`_
|
`max_degree_exc <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/determinants.irp.f#L33>`_
|
||||||
Maximum degree of excitation in the wf
|
Maximum degree of excitation in the wf
|
||||||
|
|
||||||
|
|
||||||
@ -508,7 +542,7 @@ Documentation
|
|||||||
Maximum number of determinants diagonalized by Jacobi
|
Maximum number of determinants diagonalized by Jacobi
|
||||||
|
|
||||||
|
|
||||||
`n_det_max_property <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/ezfio_interface.irp.f#L292>`_
|
`n_det_max_property <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/ezfio_interface.irp.f#L314>`_
|
||||||
Max number of determinants in the wave function when you select for a given property
|
Max number of determinants in the wave function when you select for a given property
|
||||||
|
|
||||||
|
|
||||||
@ -556,7 +590,7 @@ Documentation
|
|||||||
Number of possible determinants for a given occ_pattern
|
Number of possible determinants for a given occ_pattern
|
||||||
|
|
||||||
|
|
||||||
`one_body_dm_mo <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/density_matrix.irp.f#L164>`_
|
`one_body_dm_mo <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/density_matrix.irp.f#L162>`_
|
||||||
One-body density matrix
|
One-body density matrix
|
||||||
|
|
||||||
|
|
||||||
@ -568,15 +602,15 @@ Documentation
|
|||||||
Alpha and beta one-body density matrix for each state
|
Alpha and beta one-body density matrix for each state
|
||||||
|
|
||||||
|
|
||||||
`one_body_single_double_dm_mo_alpha <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/density_matrix.irp.f#L80>`_
|
`one_body_single_double_dm_mo_alpha <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/density_matrix.irp.f#L79>`_
|
||||||
Alpha and beta one-body density matrix for each state
|
Alpha and beta one-body density matrix for each state
|
||||||
|
|
||||||
|
|
||||||
`one_body_single_double_dm_mo_beta <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/density_matrix.irp.f#L81>`_
|
`one_body_single_double_dm_mo_beta <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/density_matrix.irp.f#L80>`_
|
||||||
Alpha and beta one-body density matrix for each state
|
Alpha and beta one-body density matrix for each state
|
||||||
|
|
||||||
|
|
||||||
`one_body_spin_density_mo <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/density_matrix.irp.f#L172>`_
|
`one_body_spin_density_mo <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/density_matrix.irp.f#L170>`_
|
||||||
rho(alpha) - rho(beta)
|
rho(alpha) - rho(beta)
|
||||||
|
|
||||||
|
|
||||||
@ -584,15 +618,11 @@ Documentation
|
|||||||
If true, The One body DM is calculated with ignoring the Double<->Doubles extra diag elements
|
If true, The One body DM is calculated with ignoring the Double<->Doubles extra diag elements
|
||||||
|
|
||||||
|
|
||||||
`pouet <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/program_initial_determinants.irp.f#L1>`_
|
`psi_average_norm_contrib <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/determinants.irp.f#L274>`_
|
||||||
Undocumented
|
|
||||||
|
|
||||||
|
|
||||||
`psi_average_norm_contrib <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/determinants.irp.f#L273>`_
|
|
||||||
Contribution of determinants to the state-averaged density
|
Contribution of determinants to the state-averaged density
|
||||||
|
|
||||||
|
|
||||||
`psi_average_norm_contrib_sorted <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/determinants.irp.f#L303>`_
|
`psi_average_norm_contrib_sorted <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/determinants.irp.f#L304>`_
|
||||||
Wave function sorted by determinants contribution to the norm (state-averaged)
|
Wave function sorted by determinants contribution to the norm (state-averaged)
|
||||||
|
|
||||||
|
|
||||||
@ -644,7 +674,7 @@ Documentation
|
|||||||
function.
|
function.
|
||||||
|
|
||||||
|
|
||||||
`psi_coef <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/determinants.irp.f#L227>`_
|
`psi_coef <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/determinants.irp.f#L228>`_
|
||||||
The wave function coefficients. Initialized with Hartree-Fock if the EZFIO file
|
The wave function coefficients. Initialized with Hartree-Fock if the EZFIO file
|
||||||
is empty
|
is empty
|
||||||
|
|
||||||
@ -653,33 +683,33 @@ Documentation
|
|||||||
Undocumented
|
Undocumented
|
||||||
|
|
||||||
|
|
||||||
`psi_coef_max <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/determinants.irp.f#L449>`_
|
`psi_coef_max <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/determinants.irp.f#L450>`_
|
||||||
Max and min values of the coefficients
|
Max and min values of the coefficients
|
||||||
|
|
||||||
|
|
||||||
`psi_coef_min <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/determinants.irp.f#L450>`_
|
`psi_coef_min <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/determinants.irp.f#L451>`_
|
||||||
Max and min values of the coefficients
|
Max and min values of the coefficients
|
||||||
|
|
||||||
|
|
||||||
`psi_coef_sorted <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/determinants.irp.f#L302>`_
|
`psi_coef_sorted <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/determinants.irp.f#L303>`_
|
||||||
Wave function sorted by determinants contribution to the norm (state-averaged)
|
Wave function sorted by determinants contribution to the norm (state-averaged)
|
||||||
|
|
||||||
|
|
||||||
`psi_coef_sorted_ab <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/determinants.irp.f#L468>`_
|
`psi_coef_sorted_ab <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/determinants.irp.f#L469>`_
|
||||||
Determinants on which we apply <i|H|j>.
|
Determinants on which we apply <i|H|j>.
|
||||||
They are sorted by the 3 highest electrons in the alpha part,
|
They are sorted by the 3 highest electrons in the alpha part,
|
||||||
then by the 3 highest electrons in the beta part to accelerate
|
then by the 3 highest electrons in the beta part to accelerate
|
||||||
the research of connected determinants.
|
the research of connected determinants.
|
||||||
|
|
||||||
|
|
||||||
`psi_coef_sorted_bit <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/determinants.irp.f#L333>`_
|
`psi_coef_sorted_bit <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/determinants.irp.f#L334>`_
|
||||||
Determinants on which we apply <i|H|psi> for perturbation.
|
Determinants on which we apply <i|H|psi> for perturbation.
|
||||||
They are sorted by determinants interpreted as integers. Useful
|
They are sorted by determinants interpreted as integers. Useful
|
||||||
to accelerate the search of a random determinant in the wave
|
to accelerate the search of a random determinant in the wave
|
||||||
function.
|
function.
|
||||||
|
|
||||||
|
|
||||||
`psi_det <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/determinants.irp.f#L65>`_
|
`psi_det <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/determinants.irp.f#L66>`_
|
||||||
The wave function determinants. Initialized with Hartree-Fock if the EZFIO file
|
The wave function determinants. Initialized with Hartree-Fock if the EZFIO file
|
||||||
is empty
|
is empty
|
||||||
|
|
||||||
@ -700,29 +730,29 @@ Documentation
|
|||||||
Unique beta determinants
|
Unique beta determinants
|
||||||
|
|
||||||
|
|
||||||
`psi_det_size <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/determinants.irp.f#L47>`_
|
`psi_det_size <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/determinants.irp.f#L48>`_
|
||||||
Size of the psi_det/psi_coef arrays
|
Size of the psi_det/psi_coef arrays
|
||||||
|
|
||||||
|
|
||||||
`psi_det_sorted <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/determinants.irp.f#L301>`_
|
`psi_det_sorted <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/determinants.irp.f#L302>`_
|
||||||
Wave function sorted by determinants contribution to the norm (state-averaged)
|
Wave function sorted by determinants contribution to the norm (state-averaged)
|
||||||
|
|
||||||
|
|
||||||
`psi_det_sorted_ab <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/determinants.irp.f#L467>`_
|
`psi_det_sorted_ab <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/determinants.irp.f#L468>`_
|
||||||
Determinants on which we apply <i|H|j>.
|
Determinants on which we apply <i|H|j>.
|
||||||
They are sorted by the 3 highest electrons in the alpha part,
|
They are sorted by the 3 highest electrons in the alpha part,
|
||||||
then by the 3 highest electrons in the beta part to accelerate
|
then by the 3 highest electrons in the beta part to accelerate
|
||||||
the research of connected determinants.
|
the research of connected determinants.
|
||||||
|
|
||||||
|
|
||||||
`psi_det_sorted_bit <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/determinants.irp.f#L332>`_
|
`psi_det_sorted_bit <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/determinants.irp.f#L333>`_
|
||||||
Determinants on which we apply <i|H|psi> for perturbation.
|
Determinants on which we apply <i|H|psi> for perturbation.
|
||||||
They are sorted by determinants interpreted as integers. Useful
|
They are sorted by determinants interpreted as integers. Useful
|
||||||
to accelerate the search of a random determinant in the wave
|
to accelerate the search of a random determinant in the wave
|
||||||
function.
|
function.
|
||||||
|
|
||||||
|
|
||||||
`psi_det_sorted_next_ab <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/determinants.irp.f#L469>`_
|
`psi_det_sorted_next_ab <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/determinants.irp.f#L470>`_
|
||||||
Determinants on which we apply <i|H|j>.
|
Determinants on which we apply <i|H|j>.
|
||||||
They are sorted by the 3 highest electrons in the alpha part,
|
They are sorted by the 3 highest electrons in the alpha part,
|
||||||
then by the 3 highest electrons in the beta part to accelerate
|
then by the 3 highest electrons in the beta part to accelerate
|
||||||
@ -761,7 +791,7 @@ Documentation
|
|||||||
Undocumented
|
Undocumented
|
||||||
|
|
||||||
|
|
||||||
`read_dets <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/determinants.irp.f#L598>`_
|
`read_dets <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/determinants.irp.f#L599>`_
|
||||||
Reads the determinants from the EZFIO file
|
Reads the determinants from the EZFIO file
|
||||||
|
|
||||||
|
|
||||||
@ -777,20 +807,16 @@ Documentation
|
|||||||
Energy of the reference bitmask used in Slater rules
|
Energy of the reference bitmask used in Slater rules
|
||||||
|
|
||||||
|
|
||||||
`remove_duplicates_in_psi_det <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/H_apply.irp.f#L190>`_
|
`remove_duplicates_in_psi_det <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/H_apply.irp.f#L198>`_
|
||||||
Removes duplicate determinants in the wave function.
|
Removes duplicate determinants in the wave function.
|
||||||
|
|
||||||
|
|
||||||
`resize_h_apply_buffer <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/H_apply.irp.f#L48>`_
|
`resize_h_apply_buffer <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/H_apply.irp.f#L57>`_
|
||||||
Resizes the H_apply buffer of proc iproc. The buffer lock should
|
Resizes the H_apply buffer of proc iproc. The buffer lock should
|
||||||
be set before calling this function.
|
be set before calling this function.
|
||||||
|
|
||||||
|
|
||||||
`routine <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/program_initial_determinants.irp.f#L7>`_
|
`s2_eig <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/ezfio_interface.irp.f#L270>`_
|
||||||
Undocumented
|
|
||||||
|
|
||||||
|
|
||||||
`s2_eig <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/ezfio_interface.irp.f#L248>`_
|
|
||||||
Force the wave function to be an eigenfunction of S^2
|
Force the wave function to be an eigenfunction of S^2
|
||||||
|
|
||||||
|
|
||||||
@ -810,31 +836,31 @@ Documentation
|
|||||||
Undocumented
|
Undocumented
|
||||||
|
|
||||||
|
|
||||||
`save_natural_mos <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/density_matrix.irp.f#L196>`_
|
`save_natural_mos <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/density_matrix.irp.f#L194>`_
|
||||||
Save natural orbitals, obtained by diagonalization of the one-body density matrix in the MO basis
|
Save natural orbitals, obtained by diagonalization of the one-body density matrix in the MO basis
|
||||||
|
|
||||||
|
|
||||||
`save_wavefunction <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/determinants.irp.f#L645>`_
|
`save_wavefunction <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/determinants.irp.f#L646>`_
|
||||||
Save the wave function into the EZFIO file
|
Save the wave function into the EZFIO file
|
||||||
|
|
||||||
|
|
||||||
`save_wavefunction_general <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/determinants.irp.f#L664>`_
|
`save_wavefunction_general <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/determinants.irp.f#L665>`_
|
||||||
Save the wave function into the EZFIO file
|
Save the wave function into the EZFIO file
|
||||||
|
|
||||||
|
|
||||||
`save_wavefunction_specified <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/determinants.irp.f#L752>`_
|
`save_wavefunction_specified <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/determinants.irp.f#L753>`_
|
||||||
Save the wave function into the EZFIO file
|
Save the wave function into the EZFIO file
|
||||||
|
|
||||||
|
|
||||||
`save_wavefunction_unsorted <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/determinants.irp.f#L655>`_
|
`save_wavefunction_unsorted <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/determinants.irp.f#L656>`_
|
||||||
Save the wave function into the EZFIO file
|
Save the wave function into the EZFIO file
|
||||||
|
|
||||||
|
|
||||||
`set_bite_to_integer <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/create_excitations.irp.f#L38>`_
|
`set_bit_to_integer <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/create_excitations.irp.f#L38>`_
|
||||||
Undocumented
|
Undocumented
|
||||||
|
|
||||||
|
|
||||||
`set_natural_mos <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/density_matrix.irp.f#L180>`_
|
`set_natural_mos <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/density_matrix.irp.f#L178>`_
|
||||||
Set natural orbitals, obtained by diagonalization of the one-body density matrix in the MO basis
|
Set natural orbitals, obtained by diagonalization of the one-body density matrix in the MO basis
|
||||||
|
|
||||||
|
|
||||||
@ -844,26 +870,26 @@ Documentation
|
|||||||
for a given couple of hole/particle excitations i.
|
for a given couple of hole/particle excitations i.
|
||||||
|
|
||||||
|
|
||||||
`sort_dets_ab <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/davidson.irp.f#L197>`_
|
`sort_dets_ab <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/davidson.irp.f#L234>`_
|
||||||
Undocumented
|
Uncodumented : TODO
|
||||||
|
|
||||||
|
|
||||||
`sort_dets_ab_v <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/davidson.irp.f#L145>`_
|
`sort_dets_ab_v <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/davidson.irp.f#L164>`_
|
||||||
Undocumented
|
Uncodumented : TODO
|
||||||
|
|
||||||
|
|
||||||
`sort_dets_ba_v <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/davidson.irp.f#L124>`_
|
`sort_dets_ba_v <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/davidson.irp.f#L135>`_
|
||||||
Undocumented
|
Uncodumented : TODO
|
||||||
|
|
||||||
|
|
||||||
`sort_dets_by_3_highest_electrons <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/determinants.irp.f#L489>`_
|
`sort_dets_by_3_highest_electrons <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/determinants.irp.f#L490>`_
|
||||||
Determinants on which we apply <i|H|j>.
|
Determinants on which we apply <i|H|j>.
|
||||||
They are sorted by the 3 highest electrons in the alpha part,
|
They are sorted by the 3 highest electrons in the alpha part,
|
||||||
then by the 3 highest electrons in the beta part to accelerate
|
then by the 3 highest electrons in the beta part to accelerate
|
||||||
the research of connected determinants.
|
the research of connected determinants.
|
||||||
|
|
||||||
|
|
||||||
`sort_dets_by_det_search_key <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/determinants.irp.f#L346>`_
|
`sort_dets_by_det_search_key <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/determinants.irp.f#L347>`_
|
||||||
Determinants are sorted are sorted according to their det_search_key.
|
Determinants are sorted are sorted according to their det_search_key.
|
||||||
Useful to accelerate the search of a random determinant in the wave
|
Useful to accelerate the search of a random determinant in the wave
|
||||||
function.
|
function.
|
||||||
@ -873,12 +899,12 @@ Documentation
|
|||||||
Return an integer*8 corresponding to a determinant index for searching
|
Return an integer*8 corresponding to a determinant index for searching
|
||||||
|
|
||||||
|
|
||||||
`state_average_weight <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/density_matrix.irp.f#L207>`_
|
`state_average_weight <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/density_matrix.irp.f#L205>`_
|
||||||
Weights in the state-average calculation of the density matrix
|
Weights in the state-average calculation of the density matrix
|
||||||
|
|
||||||
|
|
||||||
`tamiser <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/davidson.irp.f#L91>`_
|
`tamiser <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/davidson.irp.f#L91>`_
|
||||||
Undocumented
|
Uncodumented : TODO
|
||||||
|
|
||||||
|
|
||||||
`target_energy <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/ezfio_interface.irp.f#L160>`_
|
`target_energy <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/ezfio_interface.irp.f#L160>`_
|
||||||
@ -889,7 +915,11 @@ Documentation
|
|||||||
convergence of the correlation energy of SC2 iterations
|
convergence of the correlation energy of SC2 iterations
|
||||||
|
|
||||||
|
|
||||||
`threshold_generators <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/ezfio_interface.irp.f#L270>`_
|
`threshold_davidson <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/ezfio_interface.irp.f#L204>`_
|
||||||
|
Thresholds of Davidson's algorithm
|
||||||
|
|
||||||
|
|
||||||
|
`threshold_generators <http://github.com/LCPQ/quantum_package/tree/master/src/Determinants/ezfio_interface.irp.f#L292>`_
|
||||||
Thresholds on generators (fraction of the norm)
|
Thresholds on generators (fraction of the norm)
|
||||||
|
|
||||||
|
|
||||||
|
@ -35,7 +35,7 @@ subroutine do_mono_excitation(key_in,i_hole,i_particle,ispin,i_ok)
|
|||||||
endif
|
endif
|
||||||
end
|
end
|
||||||
|
|
||||||
subroutine set_bite_to_integer(i_physical,key,Nint)
|
subroutine set_bit_to_integer(i_physical,key,Nint)
|
||||||
use bitmasks
|
use bitmasks
|
||||||
implicit none
|
implicit none
|
||||||
integer, intent(in) :: i_physical,Nint
|
integer, intent(in) :: i_physical,Nint
|
||||||
|
@ -1264,6 +1264,75 @@ end
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
double precision function diag_H_mat_elem_fock(det_ref,det_pert,fock_diag_tmp,Nint)
|
||||||
|
use bitmasks
|
||||||
|
implicit none
|
||||||
|
BEGIN_DOC
|
||||||
|
! Computes <i|H|i> when i is at most a double excitation from
|
||||||
|
! a reference.
|
||||||
|
END_DOC
|
||||||
|
integer,intent(in) :: Nint
|
||||||
|
integer(bit_kind),intent(in) :: det_ref(Nint,2), det_pert(Nint,2)
|
||||||
|
double precision, intent(in) :: fock_diag_tmp(2,mo_tot_num+1)
|
||||||
|
|
||||||
|
integer :: degree
|
||||||
|
double precision :: phase, E0
|
||||||
|
integer :: exc(0:2,2,2)
|
||||||
|
integer :: h1, p1, h2, p2, s1, s2
|
||||||
|
|
||||||
|
call get_excitation_degree(det_ref,det_pert,degree,Nint)
|
||||||
|
E0 = fock_diag_tmp(1,mo_tot_num+1)
|
||||||
|
if (degree == 2) then
|
||||||
|
call get_double_excitation(det_ref,det_pert,exc,phase,Nint)
|
||||||
|
call decode_exc(exc,2,h1,p1,h2,p2,s1,s2)
|
||||||
|
|
||||||
|
if ( (s1 == 1).and.(s2 == 1) ) then ! alpha/alpha
|
||||||
|
diag_H_mat_elem_fock = E0 &
|
||||||
|
- fock_diag_tmp(1,h1) &
|
||||||
|
+ ( fock_diag_tmp(1,p1) - mo_bielec_integral_jj_anti(h1,p1) ) &
|
||||||
|
- ( fock_diag_tmp(1,h2) - mo_bielec_integral_jj_anti(h1,h2) &
|
||||||
|
+ mo_bielec_integral_jj_anti(p1,h2) ) &
|
||||||
|
+ ( fock_diag_tmp(1,p2) - mo_bielec_integral_jj_anti(h1,p2) &
|
||||||
|
+ mo_bielec_integral_jj_anti(p1,p2) - mo_bielec_integral_jj_anti(h2,p2) )
|
||||||
|
|
||||||
|
else if ( (s1 == 2).and.(s2 == 2) ) then ! beta/beta
|
||||||
|
diag_H_mat_elem_fock = E0 &
|
||||||
|
- fock_diag_tmp(2,h1) &
|
||||||
|
+ ( fock_diag_tmp(2,p1) - mo_bielec_integral_jj_anti(h1,p1) ) &
|
||||||
|
- ( fock_diag_tmp(2,h2) - mo_bielec_integral_jj_anti(h1,h2) &
|
||||||
|
+ mo_bielec_integral_jj_anti(p1,h2) ) &
|
||||||
|
+ ( fock_diag_tmp(2,p2) - mo_bielec_integral_jj_anti(h1,p2) &
|
||||||
|
+ mo_bielec_integral_jj_anti(p1,p2) - mo_bielec_integral_jj_anti(h2,p2) )
|
||||||
|
|
||||||
|
else ! alpha/beta
|
||||||
|
diag_H_mat_elem_fock = E0 &
|
||||||
|
- fock_diag_tmp(1,h1) &
|
||||||
|
+ ( fock_diag_tmp(1,p1) - mo_bielec_integral_jj_anti(h1,p1) ) &
|
||||||
|
- ( fock_diag_tmp(2,h2) - mo_bielec_integral_jj(h1,h2) &
|
||||||
|
+ mo_bielec_integral_jj(p1,h2) ) &
|
||||||
|
+ ( fock_diag_tmp(2,p2) - mo_bielec_integral_jj(h1,p2) &
|
||||||
|
+ mo_bielec_integral_jj(p1,p2) - mo_bielec_integral_jj_anti(h2,p2) )
|
||||||
|
|
||||||
|
endif
|
||||||
|
|
||||||
|
else if (degree == 1) then
|
||||||
|
call get_mono_excitation(det_ref,det_pert,exc,phase,Nint)
|
||||||
|
call decode_exc(exc,1,h1,p1,h2,p2,s1,s2)
|
||||||
|
if (s1 == 1) then
|
||||||
|
diag_H_mat_elem_fock = E0 - fock_diag_tmp(1,h1) &
|
||||||
|
+ ( fock_diag_tmp(1,p1) - mo_bielec_integral_jj_anti(h1,p1) )
|
||||||
|
else
|
||||||
|
diag_H_mat_elem_fock = E0 - fock_diag_tmp(2,h1) &
|
||||||
|
+ ( fock_diag_tmp(2,p1) - mo_bielec_integral_jj_anti(h1,p1) )
|
||||||
|
endif
|
||||||
|
|
||||||
|
else if (degree == 0) then
|
||||||
|
diag_H_mat_elem_fock = E0
|
||||||
|
else
|
||||||
|
STOP 'Bug in diag_H_mat_elem_fock'
|
||||||
|
endif
|
||||||
|
end
|
||||||
|
|
||||||
double precision function diag_H_mat_elem(det_in,Nint)
|
double precision function diag_H_mat_elem(det_in,Nint)
|
||||||
implicit none
|
implicit none
|
||||||
BEGIN_DOC
|
BEGIN_DOC
|
||||||
|
@ -203,34 +203,10 @@ output_bitmask
|
|||||||
Output file for Bitmask
|
Output file for Bitmask
|
||||||
|
|
||||||
|
|
||||||
output_cas_sd
|
|
||||||
Output file for CAS_SD
|
|
||||||
|
|
||||||
|
|
||||||
output_cid
|
|
||||||
Output file for CID
|
|
||||||
|
|
||||||
|
|
||||||
output_cisd
|
|
||||||
Output file for CISD
|
|
||||||
|
|
||||||
|
|
||||||
output_cisd_sc2_selected
|
|
||||||
Output file for CISD_SC2_selected
|
|
||||||
|
|
||||||
|
|
||||||
output_cisd_selected
|
|
||||||
Output file for CISD_selected
|
|
||||||
|
|
||||||
|
|
||||||
`output_cpu_time_0 <http://github.com/LCPQ/quantum_package/tree/master/src/Ezfio_files/output.irp.f#L2>`_
|
`output_cpu_time_0 <http://github.com/LCPQ/quantum_package/tree/master/src/Ezfio_files/output.irp.f#L2>`_
|
||||||
Initial CPU and wall times when printing in the output files
|
Initial CPU and wall times when printing in the output files
|
||||||
|
|
||||||
|
|
||||||
output_ddci_selected
|
|
||||||
Output file for DDCI_selected
|
|
||||||
|
|
||||||
|
|
||||||
output_determinants
|
output_determinants
|
||||||
Output file for Determinants
|
Output file for Determinants
|
||||||
|
|
||||||
@ -243,18 +219,10 @@ output_ezfio_files
|
|||||||
Output file for Ezfio_files
|
Output file for Ezfio_files
|
||||||
|
|
||||||
|
|
||||||
output_fcidump
|
|
||||||
Output file for FCIdump
|
|
||||||
|
|
||||||
|
|
||||||
output_full_ci
|
output_full_ci
|
||||||
Output file for Full_CI
|
Output file for Full_CI
|
||||||
|
|
||||||
|
|
||||||
output_generators_cas
|
|
||||||
Output file for Generators_CAS
|
|
||||||
|
|
||||||
|
|
||||||
output_generators_full
|
output_generators_full
|
||||||
Output file for Generators_full
|
Output file for Generators_full
|
||||||
|
|
||||||
@ -271,10 +239,6 @@ output_integrals_monoelec
|
|||||||
Output file for Integrals_Monoelec
|
Output file for Integrals_Monoelec
|
||||||
|
|
||||||
|
|
||||||
output_loc_cele
|
|
||||||
Output file for loc_cele
|
|
||||||
|
|
||||||
|
|
||||||
output_mo_basis
|
output_mo_basis
|
||||||
Output file for MO_Basis
|
Output file for MO_Basis
|
||||||
|
|
||||||
@ -283,14 +247,6 @@ output_moguess
|
|||||||
Output file for MOGuess
|
Output file for MOGuess
|
||||||
|
|
||||||
|
|
||||||
output_molden
|
|
||||||
Output file for Molden
|
|
||||||
|
|
||||||
|
|
||||||
output_mp2
|
|
||||||
Output file for MP2
|
|
||||||
|
|
||||||
|
|
||||||
output_mrcc_cassd
|
output_mrcc_cassd
|
||||||
Output file for MRCC_CASSD
|
Output file for MRCC_CASSD
|
||||||
|
|
||||||
@ -323,18 +279,10 @@ output_psiref_utils
|
|||||||
Output file for Psiref_Utils
|
Output file for Psiref_Utils
|
||||||
|
|
||||||
|
|
||||||
output_qmcchem
|
|
||||||
Output file for QmcChem
|
|
||||||
|
|
||||||
|
|
||||||
output_selectors_full
|
output_selectors_full
|
||||||
Output file for Selectors_full
|
Output file for Selectors_full
|
||||||
|
|
||||||
|
|
||||||
output_singlerefmethod
|
|
||||||
Output file for SingleRefMethod
|
|
||||||
|
|
||||||
|
|
||||||
output_utils
|
output_utils
|
||||||
Output file for Utils
|
Output file for Utils
|
||||||
|
|
||||||
|
32
src/Integrals_Bielec/.gitignore
vendored
32
src/Integrals_Bielec/.gitignore
vendored
@ -1,20 +1,20 @@
|
|||||||
# Automatically created by /home/razoa/quantum_package/scripts/module/module_handler.py
|
# Automatically created by $QP_ROOT/scripts/module/module_handler.py
|
||||||
IRPF90_temp
|
.ninja_deps
|
||||||
|
.ninja_log
|
||||||
|
AO_Basis
|
||||||
|
Bitmask
|
||||||
|
Electrons
|
||||||
|
Ezfio_files
|
||||||
IRPF90_man
|
IRPF90_man
|
||||||
irpf90_entities
|
IRPF90_temp
|
||||||
tags
|
MO_Basis
|
||||||
irpf90.make
|
|
||||||
Makefile
|
Makefile
|
||||||
Makefile.depend
|
Makefile.depend
|
||||||
build.ninja
|
|
||||||
.ninja_log
|
|
||||||
.ninja_deps
|
|
||||||
ezfio_interface.irp.f
|
|
||||||
Ezfio_files
|
|
||||||
MO_Basis
|
|
||||||
Utils
|
|
||||||
Pseudo
|
|
||||||
Bitmask
|
|
||||||
AO_Basis
|
|
||||||
Electrons
|
|
||||||
Nuclei
|
Nuclei
|
||||||
|
Pseudo
|
||||||
|
Utils
|
||||||
|
ezfio_interface.irp.f
|
||||||
|
irpf90.make
|
||||||
|
irpf90_entities
|
||||||
|
tags
|
||||||
|
test_integrals
|
@ -47,7 +47,7 @@ Documentation
|
|||||||
i(r1) j(r1) 1/r12 k(r2) l(r2)
|
i(r1) j(r1) 1/r12 k(r2) l(r2)
|
||||||
|
|
||||||
|
|
||||||
`ao_bielec_integral_schwartz <http://github.com/LCPQ/quantum_package/tree/master/src/Integrals_Bielec/ao_bi_integrals.irp.f#L489>`_
|
`ao_bielec_integral_schwartz <http://github.com/LCPQ/quantum_package/tree/master/src/Integrals_Bielec/ao_bi_integrals.irp.f#L501>`_
|
||||||
Needed to compute Schwartz inequalities
|
Needed to compute Schwartz inequalities
|
||||||
|
|
||||||
|
|
||||||
@ -56,7 +56,7 @@ Documentation
|
|||||||
i(r1) j(r1) 1/r12 k(r2) l(r2)
|
i(r1) j(r1) 1/r12 k(r2) l(r2)
|
||||||
|
|
||||||
|
|
||||||
`ao_bielec_integrals_in_map <http://github.com/LCPQ/quantum_package/tree/master/src/Integrals_Bielec/ao_bi_integrals.irp.f#L322>`_
|
`ao_bielec_integrals_in_map <http://github.com/LCPQ/quantum_package/tree/master/src/Integrals_Bielec/ao_bi_integrals.irp.f#L330>`_
|
||||||
Map of Atomic integrals
|
Map of Atomic integrals
|
||||||
i(r1) j(r2) 1/r12 k(r1) l(r2)
|
i(r1) j(r2) 1/r12 k(r1) l(r2)
|
||||||
|
|
||||||
@ -73,6 +73,10 @@ Documentation
|
|||||||
Computes the product of l values of i,j,k,and l
|
Computes the product of l values of i,j,k,and l
|
||||||
|
|
||||||
|
|
||||||
|
`bench_maps <http://github.com/LCPQ/quantum_package/tree/master/src/Integrals_Bielec/test_integrals.irp.f#L1>`_
|
||||||
|
Performs timing benchmarks on integral access
|
||||||
|
|
||||||
|
|
||||||
`bielec_integrals_index <http://github.com/LCPQ/quantum_package/tree/master/src/Integrals_Bielec/map_integrals.irp.f#L19>`_
|
`bielec_integrals_index <http://github.com/LCPQ/quantum_package/tree/master/src/Integrals_Bielec/map_integrals.irp.f#L19>`_
|
||||||
Undocumented
|
Undocumented
|
||||||
|
|
||||||
@ -85,7 +89,7 @@ Documentation
|
|||||||
Frees the memory of the AO map
|
Frees the memory of the AO map
|
||||||
|
|
||||||
|
|
||||||
`clear_mo_map <http://github.com/LCPQ/quantum_package/tree/master/src/Integrals_Bielec/map_integrals.irp.f#L399>`_
|
`clear_mo_map <http://github.com/LCPQ/quantum_package/tree/master/src/Integrals_Bielec/map_integrals.irp.f#L422>`_
|
||||||
Frees the memory of the MO map
|
Frees the memory of the MO map
|
||||||
|
|
||||||
|
|
||||||
@ -105,15 +109,15 @@ Documentation
|
|||||||
Compute integrals on the fly
|
Compute integrals on the fly
|
||||||
|
|
||||||
|
|
||||||
`dump_ao_integrals <http://github.com/LCPQ/quantum_package/tree/master/src/Integrals_Bielec/map_integrals.irp.f_template_547#L3>`_
|
`dump_ao_integrals <http://github.com/LCPQ/quantum_package/tree/master/src/Integrals_Bielec/map_integrals.irp.f_template_567#L3>`_
|
||||||
Save to disk the $ao integrals
|
Save to disk the $ao integrals
|
||||||
|
|
||||||
|
|
||||||
`dump_mo_integrals <http://github.com/LCPQ/quantum_package/tree/master/src/Integrals_Bielec/map_integrals.irp.f_template_547#L140>`_
|
`dump_mo_integrals <http://github.com/LCPQ/quantum_package/tree/master/src/Integrals_Bielec/map_integrals.irp.f_template_567#L137>`_
|
||||||
Save to disk the $ao integrals
|
Save to disk the $ao integrals
|
||||||
|
|
||||||
|
|
||||||
`eri <http://github.com/LCPQ/quantum_package/tree/master/src/Integrals_Bielec/ao_bi_integrals.irp.f#L652>`_
|
`eri <http://github.com/LCPQ/quantum_package/tree/master/src/Integrals_Bielec/ao_bi_integrals.irp.f#L664>`_
|
||||||
ATOMIC PRIMTIVE bielectronic integral between the 4 primitives ::
|
ATOMIC PRIMTIVE bielectronic integral between the 4 primitives ::
|
||||||
primitive_1 = x1**(a_x) y1**(a_y) z1**(a_z) exp(-alpha * r1**2)
|
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_2 = x1**(b_x) y1**(b_y) z1**(b_z) exp(- beta * r1**2)
|
||||||
@ -135,7 +139,7 @@ Documentation
|
|||||||
t_w(i,2,k) = t(i)
|
t_w(i,2,k) = t(i)
|
||||||
|
|
||||||
|
|
||||||
`general_primitive_integral <http://github.com/LCPQ/quantum_package/tree/master/src/Integrals_Bielec/ao_bi_integrals.irp.f#L514>`_
|
`general_primitive_integral <http://github.com/LCPQ/quantum_package/tree/master/src/Integrals_Bielec/ao_bi_integrals.irp.f#L526>`_
|
||||||
Computes the integral <pq|rs> where p,q,r,s are Gaussian primitives
|
Computes the integral <pq|rs> where p,q,r,s are Gaussian primitives
|
||||||
|
|
||||||
|
|
||||||
@ -161,52 +165,56 @@ Documentation
|
|||||||
Returns one integral <ij|kl> in the MO basis
|
Returns one integral <ij|kl> in the MO basis
|
||||||
|
|
||||||
|
|
||||||
`get_mo_bielec_integrals <http://github.com/LCPQ/quantum_package/tree/master/src/Integrals_Bielec/map_integrals.irp.f#L310>`_
|
`get_mo_bielec_integral_schwartz <http://github.com/LCPQ/quantum_package/tree/master/src/Integrals_Bielec/map_integrals.irp.f#L299>`_
|
||||||
|
Returns one integral <ij|kl> in the MO basis
|
||||||
|
|
||||||
|
|
||||||
|
`get_mo_bielec_integrals <http://github.com/LCPQ/quantum_package/tree/master/src/Integrals_Bielec/map_integrals.irp.f#L333>`_
|
||||||
Returns multiple integrals <ij|kl> in the MO basis, all
|
Returns multiple integrals <ij|kl> in the MO basis, all
|
||||||
i for j,k,l fixed.
|
i for j,k,l fixed.
|
||||||
|
|
||||||
|
|
||||||
`get_mo_bielec_integrals_existing_ik <http://github.com/LCPQ/quantum_package/tree/master/src/Integrals_Bielec/map_integrals.irp.f#L341>`_
|
`get_mo_bielec_integrals_existing_ik <http://github.com/LCPQ/quantum_package/tree/master/src/Integrals_Bielec/map_integrals.irp.f#L364>`_
|
||||||
Returns multiple integrals <ij|kl> in the MO basis, all
|
Returns multiple integrals <ij|kl> in the MO basis, all
|
||||||
i(1)j(1) 1/r12 k(2)l(2)
|
i(1)j(1) 1/r12 k(2)l(2)
|
||||||
i for j,k,l fixed.
|
i for j,k,l fixed.
|
||||||
|
|
||||||
|
|
||||||
`get_mo_map_size <http://github.com/LCPQ/quantum_package/tree/master/src/Integrals_Bielec/map_integrals.irp.f#L391>`_
|
`get_mo_map_size <http://github.com/LCPQ/quantum_package/tree/master/src/Integrals_Bielec/map_integrals.irp.f#L414>`_
|
||||||
Return the number of elements in the MO map
|
Return the number of elements in the MO map
|
||||||
|
|
||||||
|
|
||||||
`give_polynom_mult_center_x <http://github.com/LCPQ/quantum_package/tree/master/src/Integrals_Bielec/ao_bi_integrals.irp.f#L850>`_
|
`give_polynom_mult_center_x <http://github.com/LCPQ/quantum_package/tree/master/src/Integrals_Bielec/ao_bi_integrals.irp.f#L874>`_
|
||||||
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_x1(a_x, d_x,p,q) * I_x1(a_y, d_y,p,q) * I_x1(a_z, d_z,p,q)
|
||||||
|
|
||||||
|
|
||||||
`i_x1_new <http://github.com/LCPQ/quantum_package/tree/master/src/Integrals_Bielec/ao_bi_integrals.irp.f#L771>`_
|
`i_x1_new <http://github.com/LCPQ/quantum_package/tree/master/src/Integrals_Bielec/ao_bi_integrals.irp.f#L795>`_
|
||||||
recursive function involved in the bielectronic integral
|
recursive function involved in the bielectronic integral
|
||||||
|
|
||||||
|
|
||||||
`i_x1_pol_mult <http://github.com/LCPQ/quantum_package/tree/master/src/Integrals_Bielec/ao_bi_integrals.irp.f#L913>`_
|
`i_x1_pol_mult <http://github.com/LCPQ/quantum_package/tree/master/src/Integrals_Bielec/ao_bi_integrals.irp.f#L937>`_
|
||||||
recursive function involved in the bielectronic integral
|
recursive function involved in the bielectronic integral
|
||||||
|
|
||||||
|
|
||||||
`i_x1_pol_mult_a1 <http://github.com/LCPQ/quantum_package/tree/master/src/Integrals_Bielec/ao_bi_integrals.irp.f#L1033>`_
|
`i_x1_pol_mult_a1 <http://github.com/LCPQ/quantum_package/tree/master/src/Integrals_Bielec/ao_bi_integrals.irp.f#L1057>`_
|
||||||
recursive function involved in the bielectronic integral
|
recursive function involved in the bielectronic integral
|
||||||
|
|
||||||
|
|
||||||
`i_x1_pol_mult_a2 <http://github.com/LCPQ/quantum_package/tree/master/src/Integrals_Bielec/ao_bi_integrals.irp.f#L1087>`_
|
`i_x1_pol_mult_a2 <http://github.com/LCPQ/quantum_package/tree/master/src/Integrals_Bielec/ao_bi_integrals.irp.f#L1111>`_
|
||||||
recursive function involved in the bielectronic integral
|
recursive function involved in the bielectronic integral
|
||||||
|
|
||||||
|
|
||||||
`i_x1_pol_mult_recurs <http://github.com/LCPQ/quantum_package/tree/master/src/Integrals_Bielec/ao_bi_integrals.irp.f#L947>`_
|
`i_x1_pol_mult_recurs <http://github.com/LCPQ/quantum_package/tree/master/src/Integrals_Bielec/ao_bi_integrals.irp.f#L971>`_
|
||||||
recursive function involved in the bielectronic integral
|
recursive function involved in the bielectronic integral
|
||||||
|
|
||||||
|
|
||||||
`i_x2_new <http://github.com/LCPQ/quantum_package/tree/master/src/Integrals_Bielec/ao_bi_integrals.irp.f#L806>`_
|
`i_x2_new <http://github.com/LCPQ/quantum_package/tree/master/src/Integrals_Bielec/ao_bi_integrals.irp.f#L830>`_
|
||||||
recursive function involved in the bielectronic integral
|
recursive function involved in the bielectronic integral
|
||||||
|
|
||||||
|
|
||||||
`i_x2_pol_mult <http://github.com/LCPQ/quantum_package/tree/master/src/Integrals_Bielec/ao_bi_integrals.irp.f#L1149>`_
|
`i_x2_pol_mult <http://github.com/LCPQ/quantum_package/tree/master/src/Integrals_Bielec/ao_bi_integrals.irp.f#L1173>`_
|
||||||
recursive function involved in the bielectronic integral
|
recursive function involved in the bielectronic integral
|
||||||
|
|
||||||
|
|
||||||
@ -218,21 +226,21 @@ Documentation
|
|||||||
Create new entry into MO map, or accumulate in an existing entry
|
Create new entry into MO map, or accumulate in an existing entry
|
||||||
|
|
||||||
|
|
||||||
`integrale_new <http://github.com/LCPQ/quantum_package/tree/master/src/Integrals_Bielec/ao_bi_integrals.irp.f#L697>`_
|
`integrale_new <http://github.com/LCPQ/quantum_package/tree/master/src/Integrals_Bielec/ao_bi_integrals.irp.f#L721>`_
|
||||||
calculate the integral of the polynom ::
|
calculate the integral of the polynom ::
|
||||||
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)
|
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)
|
between ( 0 ; 1)
|
||||||
|
|
||||||
|
|
||||||
`load_ao_integrals <http://github.com/LCPQ/quantum_package/tree/master/src/Integrals_Bielec/map_integrals.irp.f_template_547#L89>`_
|
`load_ao_integrals <http://github.com/LCPQ/quantum_package/tree/master/src/Integrals_Bielec/map_integrals.irp.f_template_567#L89>`_
|
||||||
Read from disk the $ao integrals
|
Read from disk the $ao integrals
|
||||||
|
|
||||||
|
|
||||||
`load_mo_integrals <http://github.com/LCPQ/quantum_package/tree/master/src/Integrals_Bielec/map_integrals.irp.f_template_547#L226>`_
|
`load_mo_integrals <http://github.com/LCPQ/quantum_package/tree/master/src/Integrals_Bielec/map_integrals.irp.f_template_567#L223>`_
|
||||||
Read from disk the $ao integrals
|
Read from disk the $ao integrals
|
||||||
|
|
||||||
|
|
||||||
`mo_bielec_integral <http://github.com/LCPQ/quantum_package/tree/master/src/Integrals_Bielec/map_integrals.irp.f#L298>`_
|
`mo_bielec_integral <http://github.com/LCPQ/quantum_package/tree/master/src/Integrals_Bielec/map_integrals.irp.f#L321>`_
|
||||||
Returns one integral <ij|kl> in the MO basis
|
Returns one integral <ij|kl> in the MO basis
|
||||||
|
|
||||||
|
|
||||||
@ -272,6 +280,10 @@ Documentation
|
|||||||
mo_bielec_integral_jj_anti_from_ao(i,j) = J_ij - K_ij
|
mo_bielec_integral_jj_anti_from_ao(i,j) = J_ij - K_ij
|
||||||
|
|
||||||
|
|
||||||
|
`mo_bielec_integral_schwartz <http://github.com/LCPQ/quantum_package/tree/master/src/Integrals_Bielec/mo_bi_integrals.irp.f#L492>`_
|
||||||
|
Needed to compute Schwartz inequalities
|
||||||
|
|
||||||
|
|
||||||
`mo_bielec_integrals_in_map <http://github.com/LCPQ/quantum_package/tree/master/src/Integrals_Bielec/mo_bi_integrals.irp.f#L22>`_
|
`mo_bielec_integrals_in_map <http://github.com/LCPQ/quantum_package/tree/master/src/Integrals_Bielec/mo_bi_integrals.irp.f#L22>`_
|
||||||
If True, the map of MO bielectronic integrals is provided
|
If True, the map of MO bielectronic integrals is provided
|
||||||
|
|
||||||
@ -292,7 +304,7 @@ Documentation
|
|||||||
Aligned n_pt_max_integrals
|
Aligned n_pt_max_integrals
|
||||||
|
|
||||||
|
|
||||||
`n_pt_sup <http://github.com/LCPQ/quantum_package/tree/master/src/Integrals_Bielec/ao_bi_integrals.irp.f#L836>`_
|
`n_pt_sup <http://github.com/LCPQ/quantum_package/tree/master/src/Integrals_Bielec/ao_bi_integrals.irp.f#L860>`_
|
||||||
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 :
|
bielctronic 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)
|
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)
|
||||||
|
@ -111,11 +111,11 @@ Documentation
|
|||||||
Pseudo-potential
|
Pseudo-potential
|
||||||
|
|
||||||
|
|
||||||
`ao_pseudo_integral_local <http://github.com/LCPQ/quantum_package/tree/master/src/Integrals_Monoelec/pot_ao_pseudo_ints.irp.f#L15>`_
|
`ao_pseudo_integral_local <http://github.com/LCPQ/quantum_package/tree/master/src/Integrals_Monoelec/pot_ao_pseudo_ints.irp.f#L13>`_
|
||||||
Local pseudo-potential
|
Local pseudo-potential
|
||||||
|
|
||||||
|
|
||||||
`ao_pseudo_integral_non_local <http://github.com/LCPQ/quantum_package/tree/master/src/Integrals_Monoelec/pot_ao_pseudo_ints.irp.f#L121>`_
|
`ao_pseudo_integral_non_local <http://github.com/LCPQ/quantum_package/tree/master/src/Integrals_Monoelec/pot_ao_pseudo_ints.irp.f#L120>`_
|
||||||
Local pseudo-potential
|
Local pseudo-potential
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user