davidson
Abstract module for Davidson’s diagonalization. It contains everything required for the Davidson algorithm, dressed or not. If a dressing is used, the dressing column should be defined and the davidson_dressed module should be used. If no dressing is required, the davidson module should be used, and it has a default zero dressing vector.
The important providers for that module are:
psi_energy
which is the expectation value over the wave function (psi_det
,psi_coef
) of the Hamiltonian, dressed or not. It uses the general subroutineu_0_H_u_0()
.psi_energy_two_e
which is the expectation value over the wave function (psi_det
,psi_coef
) of the standard two-electron Coulomb operator. It uses the general routineu_0_H_u_0_two_e()
.
EZFIO parameters
- threshold_davidson
Thresholds of Davidson’s algorithm
Default: 1.e-10
- n_states_diag
Number of states to consider during the Davdison diagonalization
Default: 4
- davidson_sze_max
Number of micro-iterations before re-contracting
Default: 15
- state_following
If
true
, the states are re-ordered to match the input statesDefault: False
- disk_based_davidson
If
true
, a memory-mapped file may be used to store the W and S2 vectors if not enough RAM is availableDefault: True
- distributed_davidson
If
true
, use the distributed algorithmDefault: True
- only_expected_s2
If
true
, use filter out all vectors with bad \(\widehat{S^2}\) valuesDefault: True
- n_det_max_full
Maximum number of determinants where \(\hat H\) is fully diagonalized
Default: 1000
Providers
- ci_eigenvectors
File :
davidson/diagonalize_ci.irp.f
double precision, allocatable :: ci_electronic_energy (N_states_diag) double precision, allocatable :: ci_eigenvectors (N_det,N_states_diag) double precision, allocatable :: ci_s2 (N_states_diag)
Eigenvectors/values of the CI matrix
Needs:
diag_algorithm
dressing_column_h
expected_s2
h_matrix_all_dets
mo_two_e_integrals_in_map
n_det
n_int
n_states
n_states_diag
nthreads_davidson
only_expected_s2
psi_coef
psi_det
s2_eig
s2_matrix_all_dets
threshold_davidson
Needed by:
ci_energy
- ci_electronic_energy
File :
davidson/diagonalize_ci.irp.f
double precision, allocatable :: ci_electronic_energy (N_states_diag) double precision, allocatable :: ci_eigenvectors (N_det,N_states_diag) double precision, allocatable :: ci_s2 (N_states_diag)
Eigenvectors/values of the CI matrix
Needs:
diag_algorithm
dressing_column_h
expected_s2
h_matrix_all_dets
mo_two_e_integrals_in_map
n_det
n_int
n_states
n_states_diag
nthreads_davidson
only_expected_s2
psi_coef
psi_det
s2_eig
s2_matrix_all_dets
threshold_davidson
Needed by:
ci_energy
- ci_energy
File :
davidson/diagonalize_ci.irp.f
double precision, allocatable :: ci_energy (N_states_diag)
n_states
lowest eigenvalues of the CI matrixNeeds:
ci_electronic_energy
mpi_master
n_det
n_states
n_states_diag
nuclear_repulsion
output_wall_time_0
- ci_s2
File :
davidson/diagonalize_ci.irp.f
double precision, allocatable :: ci_electronic_energy (N_states_diag) double precision, allocatable :: ci_eigenvectors (N_det,N_states_diag) double precision, allocatable :: ci_s2 (N_states_diag)
Eigenvectors/values of the CI matrix
Needs:
diag_algorithm
dressing_column_h
expected_s2
h_matrix_all_dets
mo_two_e_integrals_in_map
n_det
n_int
n_states
n_states_diag
nthreads_davidson
only_expected_s2
psi_coef
psi_det
s2_eig
s2_matrix_all_dets
threshold_davidson
Needed by:
ci_energy
- diag_algorithm
File :
davidson/diagonalization_hs2_dressed.irp.f
character*(64) :: diag_algorithm
Diagonalization algorithm (Davidson or Lapack)
Needs:
n_det
n_det_max_full
n_states
Needed by:
ci_electronic_energy
- dressed_column_idx
File :
davidson/diagonalization_hs2_dressed.irp.f
integer, allocatable :: dressed_column_idx (N_states)
Index of the dressed columns
Needs:
n_det
n_states
psi_coef
- n_states_diag
File :
davidson/input.irp.f
integer :: n_states_diag
Number of states to consider during the Davdison diagonalization
Needs:
ezfio_filename
mpi_master
n_states
output_wall_time_0
Needed by:
ci_electronic_energy
ci_energy
psi_energy
- nthreads_davidson
File :
davidson/davidson_parallel.irp.f
integer :: nthreads_davidson
Number of threads for Davidson
Needs:
mpi_master
nproc
Needed by:
ci_electronic_energy
- psi_energy
File :
davidson/u0_h_u0.irp.f
double precision, allocatable :: psi_energy (N_states) double precision, allocatable :: psi_s2 (N_states)
psi_energy(i) = \(\langle \Psi_i | H | \Psi_i \rangle\)
psi_s2(i) = \(\langle \Psi_i | S^2 | \Psi_i \rangle\)
Needs:
distributed_davidson
h_matrix_all_dets
n_det
n_det_max_full
n_int
n_states
n_states_diag
psi_coef
psi_det
psi_det_size
s2_matrix_all_dets
Needed by:
psi_energy_with_nucl_rep
- psi_energy_two_e
File :
davidson/u0_wee_u0.irp.f
double precision, allocatable :: psi_energy_two_e (N_states)
Energy of the current wave function
Needs:
n_det
n_int
n_states
psi_coef
psi_det
psi_det_size
- psi_energy_with_nucl_rep
File :
davidson/u0_h_u0.irp.f
double precision, allocatable :: psi_energy_with_nucl_rep (N_states)
Energy of the wave function with the nuclear repulsion energy.
Needs:
n_states
nuclear_repulsion
psi_energy
- psi_s2
File :
davidson/u0_h_u0.irp.f
double precision, allocatable :: psi_energy (N_states) double precision, allocatable :: psi_s2 (N_states)
psi_energy(i) = \(\langle \Psi_i | H | \Psi_i \rangle\)
psi_s2(i) = \(\langle \Psi_i | S^2 | \Psi_i \rangle\)
Needs:
distributed_davidson
h_matrix_all_dets
n_det
n_det_max_full
n_int
n_states
n_states_diag
psi_coef
psi_det
psi_det_size
s2_matrix_all_dets
Needed by:
psi_energy_with_nucl_rep
- threshold_davidson_pt2
File :
davidson/diagonalization_hs2_dressed.irp.f
double precision :: threshold_davidson_pt2
Threshold of Davidson’s algorithm, using PT2 as a guide
Needs:
threshold_davidson
Subroutines / functions
- davidson_collector:
File :
davidson/davidson_parallel.irp.f
subroutine davidson_collector(zmq_to_qp_run_socket, zmq_socket_pull, v0, s0, sze, N_st)
Routine collecting the results of the workers in Davidson’s algorithm.
Needs:
n_det
Called by:
h_s2_u_0_nstates_zmq()
Calls:
davidson_pull_results()
- davidson_diag_hjj_sjj:
File :
davidson/diagonalization_hs2_dressed.irp.f
subroutine davidson_diag_hjj_sjj(dets_in,u_in,H_jj,s2_out,energies,dim_in,sze,N_st,N_st_diag_in,Nint,dressing_state,converged)
Davidson diagonalization with specific diagonal elements of the H matrix
H_jj : specific diagonal H matrix elements to diagonalize de Davidson
S2_out : Output : s^2
dets_in : bitmasks corresponding to determinants
- u_inguess coefficients on the various states. Overwritten
on exit
dim_in : leftmost dimension of u_in
sze : Number of determinants
N_st : Number of eigenstates
N_st_diag_in : Number of states in which H is diagonalized. Assumed > sze
Initial guess vectors are not necessarily orthonormal
Needs:
davidson_sze_max
disk_based_davidson
distributed_davidson
dressed_column_idx
dressing_column_h
expected_s2
ezfio_work_dir
n_det
n_int
nproc
nthreads_davidson
nuclear_repulsion
only_expected_s2
psi_bilinear_matrix_values
psi_bilinear_matrix_order_reverse
psi_coef
psi_det_alpha_unique
psi_det_beta_unique
qp_max_mem
s2_eig
state_following
threshold_davidson
threshold_davidson_from_pt2
threshold_davidson_pt2
Called by:
davidson_diag_hs2()
Calls:
c_f_pointer()
check_mem()
dgemm()
dswap()
h_s2_u_0_nstates_openmp()
h_s2_u_0_nstates_zmq()
lapack_diag()
mmap()
munmap()
normalize()
nullify_small_elements()
ortho_qr()
ortho_qr_unblocked()
random_number()
resident_memory()
sgemm()
write_double()
write_int()
write_time()
Touches:
nthreads_davidson
- davidson_diag_hs2:
File :
davidson/diagonalization_hs2_dressed.irp.f
subroutine davidson_diag_hs2(dets_in,u_in,s2_out,dim_in,energies,sze,N_st,N_st_diag,Nint,dressing_state,converged)
Davidson diagonalization.
dets_in : bitmasks corresponding to determinants
- u_inguess coefficients on the various states. Overwritten
on exit
dim_in : leftmost dimension of u_in
sze : Number of determinants
N_st : Number of eigenstates
Initial guess vectors are not necessarily orthonormal
Needs:
dressing_column_h
mo_two_e_integrals_in_map
n_int
Called by:
ci_electronic_energy
Calls:
davidson_diag_hjj_sjj()
Touches:
nthreads_davidson
- davidson_pull_results:
File :
davidson/davidson_parallel.irp.f
subroutine davidson_pull_results(zmq_socket_pull, v_t, s_t, imin, imax, task_id)
Pull the results of $H | U rangle$ on the master.
Needs:
n_det
n_states_diag
Called by:
davidson_collector()
- davidson_push_results:
File :
davidson/davidson_parallel.irp.f
subroutine davidson_push_results(zmq_socket_push, v_t, s_t, imin, imax, task_id)
Push the results of $H | U rangle$ from a worker to the master.
Needs:
n_det
n_states_diag
- davidson_push_results_async_recv:
File :
davidson/davidson_parallel.irp.f
subroutine davidson_push_results_async_recv(zmq_socket_push,sending)
Push the results of $H | U rangle$ from a worker to the master.
Called by:
davidson_slave_work()
- davidson_push_results_async_send:
File :
davidson/davidson_parallel.irp.f
subroutine davidson_push_results_async_send(zmq_socket_push, v_t, s_t, imin, imax, task_id,sending)
Push the results of $H | U rangle$ from a worker to the master.
Needs:
n_det
n_states_diag
Called by:
davidson_slave_work()
- davidson_run_slave:
File :
davidson/davidson_parallel.irp.f
subroutine davidson_run_slave(thread,iproc)
Slave routine for Davidson’s diagonalization.
Needs:
n_det
n_states_diag
Called by:
davidson_slave_inproc()
davidson_slave_tcp()
Calls:
davidson_slave_work()
end_zmq_push_socket()
end_zmq_to_qp_run_socket()
sleep()
- davidson_slave_inproc:
File :
davidson/davidson_parallel.irp.f
subroutine davidson_slave_inproc(i)
Called by:
h_s2_u_0_nstates_zmq()
Calls:
davidson_run_slave()
- davidson_slave_tcp:
File :
davidson/davidson_parallel.irp.f
subroutine davidson_slave_tcp(i)
Calls:
davidson_run_slave()
- davidson_slave_work:
File :
davidson/davidson_parallel.irp.f
subroutine davidson_slave_work(zmq_to_qp_run_socket, zmq_socket_push, N_st, sze, worker_id)
Needs:
mpi_initialized
mpi_rank
n_det
n_states_diag
nproc
psi_bilinear_matrix_columns_loc
psi_bilinear_matrix_order_transp_reverse
psi_bilinear_matrix_transp_values
psi_bilinear_matrix_values
psi_det_alpha_unique
psi_det_beta_unique
ref_bitmask_energy
Called by:
davidson_run_slave()
Calls:
davidson_push_results_async_recv()
davidson_push_results_async_send()
h_s2_u_0_nstates_openmp_work()
- diagonalize_ci:
File :
davidson/diagonalize_ci.irp.f
subroutine diagonalize_CI
Replace the coefficients of the CI states by the coefficients of the eigenstates of the CI matrix.
Needs:
ci_electronic_energy
ci_electronic_energy
ci_energy
ci_electronic_energy
n_det
n_states
psi_coef
psi_energy
psi_energy
Touches:
ci_electronic_energy
ci_electronic_energy
ci_energy
ci_electronic_energy
psi_coef
psi_energy
psi_energy
- h_s2_u_0_nstates_openmp:
File :
davidson/u0_h_u0.irp.f
subroutine H_S2_u_0_nstates_openmp(v_0,s_0,u_0,N_st,sze)
Computes $v_0 = H | u_0rangle$ and $s_0 = S^2 | u_0rangle$.
Assumes that the determinants are in psi_det
istart, iend, ishift, istep are used in ZMQ parallelization.
Needs:
n_det
psi_bilinear_matrix_order_reverse
psi_bilinear_matrix_values
Called by:
davidson_diag_hjj_sjj()
u_0_h_u_0()
Calls:
dset_order()
dtranspose()
h_s2_u_0_nstates_openmp_work()
- h_s2_u_0_nstates_openmp_work:
File :
davidson/u0_h_u0.irp.f
subroutine H_S2_u_0_nstates_openmp_work(v_t,s_t,u_t,N_st,sze,istart,iend,ishift,istep)
Computes $v_t = H | u_trangle$ and $s_t = S^2 | u_trangle$
Default should be 1,N_det,0,1
Needs:
n_det
n_int
ref_bitmask_energy
Called by:
davidson_slave_work()
h_s2_u_0_nstates_openmp()
Calls:
h_s2_u_0_nstates_openmp_work_1()
h_s2_u_0_nstates_openmp_work_2()
h_s2_u_0_nstates_openmp_work_3()
h_s2_u_0_nstates_openmp_work_4()
h_s2_u_0_nstates_openmp_work_n_int()
- h_s2_u_0_nstates_openmp_work_1:
File :
davidson/u0_h_u0.irp.f_template_708
subroutine H_S2_u_0_nstates_openmp_work_1(v_t,s_t,u_t,N_st,sze,istart,iend,ishift,istep)
Computes $v_t = H | u_t rangle$ and $s_t = S^2 | u_trangle$
Default should be 1,N_det,0,1
Needs:
n_det
n_int
nthreads_davidson
psi_bilinear_matrix_columns_loc
psi_bilinear_matrix_order_transp_reverse
psi_bilinear_matrix_transp_rows_loc
psi_bilinear_matrix_transp_values
psi_bilinear_matrix_values
psi_det_alpha_unique
psi_det_beta_unique
singles_beta_csc
singles_beta_csc_idx
Called by:
h_s2_u_0_nstates_openmp_work()
Calls:
get_all_spin_singles_1()
get_all_spin_singles_and_doubles_1()
get_s2()
i_h_j_double_alpha_beta()
i_h_j_double_spin()
i_h_j_single_spin()
- h_s2_u_0_nstates_openmp_work_2:
File :
davidson/u0_h_u0.irp.f_template_708
subroutine H_S2_u_0_nstates_openmp_work_2(v_t,s_t,u_t,N_st,sze,istart,iend,ishift,istep)
Computes $v_t = H | u_t rangle$ and $s_t = S^2 | u_trangle$
Default should be 1,N_det,0,1
Needs:
n_det
n_int
nthreads_davidson
psi_bilinear_matrix_columns_loc
psi_bilinear_matrix_order_transp_reverse
psi_bilinear_matrix_transp_rows_loc
psi_bilinear_matrix_transp_values
psi_bilinear_matrix_values
psi_det_alpha_unique
psi_det_beta_unique
singles_beta_csc
singles_beta_csc_idx
Called by:
h_s2_u_0_nstates_openmp_work()
Calls:
get_all_spin_singles_2()
get_all_spin_singles_and_doubles_2()
get_s2()
i_h_j_double_alpha_beta()
i_h_j_double_spin()
i_h_j_single_spin()
- h_s2_u_0_nstates_openmp_work_3:
File :
davidson/u0_h_u0.irp.f_template_708
subroutine H_S2_u_0_nstates_openmp_work_3(v_t,s_t,u_t,N_st,sze,istart,iend,ishift,istep)
Computes $v_t = H | u_t rangle$ and $s_t = S^2 | u_trangle$
Default should be 1,N_det,0,1
Needs:
n_det
n_int
nthreads_davidson
psi_bilinear_matrix_columns_loc
psi_bilinear_matrix_order_transp_reverse
psi_bilinear_matrix_transp_rows_loc
psi_bilinear_matrix_transp_values
psi_bilinear_matrix_values
psi_det_alpha_unique
psi_det_beta_unique
singles_beta_csc
singles_beta_csc_idx
Called by:
h_s2_u_0_nstates_openmp_work()
Calls:
get_all_spin_singles_3()
get_all_spin_singles_and_doubles_3()
get_s2()
i_h_j_double_alpha_beta()
i_h_j_double_spin()
i_h_j_single_spin()
- h_s2_u_0_nstates_openmp_work_4:
File :
davidson/u0_h_u0.irp.f_template_708
subroutine H_S2_u_0_nstates_openmp_work_4(v_t,s_t,u_t,N_st,sze,istart,iend,ishift,istep)
Computes $v_t = H | u_t rangle$ and $s_t = S^2 | u_trangle$
Default should be 1,N_det,0,1
Needs:
n_det
n_int
nthreads_davidson
psi_bilinear_matrix_columns_loc
psi_bilinear_matrix_order_transp_reverse
psi_bilinear_matrix_transp_rows_loc
psi_bilinear_matrix_transp_values
psi_bilinear_matrix_values
psi_det_alpha_unique
psi_det_beta_unique
singles_beta_csc
singles_beta_csc_idx
Called by:
h_s2_u_0_nstates_openmp_work()
Calls:
get_all_spin_singles_4()
get_all_spin_singles_and_doubles_4()
get_s2()
i_h_j_double_alpha_beta()
i_h_j_double_spin()
i_h_j_single_spin()
- h_s2_u_0_nstates_openmp_work_n_int:
File :
davidson/u0_h_u0.irp.f_template_708
subroutine H_S2_u_0_nstates_openmp_work_N_int(v_t,s_t,u_t,N_st,sze,istart,iend,ishift,istep)
Computes $v_t = H | u_t rangle$ and $s_t = S^2 | u_trangle$
Default should be 1,N_det,0,1
Needs:
n_det
n_int
nthreads_davidson
psi_bilinear_matrix_columns_loc
psi_bilinear_matrix_order_transp_reverse
psi_bilinear_matrix_transp_rows_loc
psi_bilinear_matrix_transp_values
psi_bilinear_matrix_values
psi_det_alpha_unique
psi_det_beta_unique
singles_beta_csc
singles_beta_csc_idx
Called by:
h_s2_u_0_nstates_openmp_work()
Calls:
get_all_spin_singles_and_doubles_n_int()
get_all_spin_singles_n_int()
get_s2()
i_h_j_double_alpha_beta()
i_h_j_double_spin()
i_h_j_single_spin()
- h_s2_u_0_nstates_zmq:
File :
davidson/davidson_parallel.irp.f
subroutine H_S2_u_0_nstates_zmq(v_0,s_0,u_0,N_st,sze)
Computes $v_0 = H | u_0rangle$ and $s_0 = S^2 | u_0rangle$
n : number of determinants
H_jj : array of $langle j | H | j rangle$
S2_jj : array of $langle j | S^2 | j rangle$
Needs:
mpi_initialized
n_det
n_states_diag
nproc
psi_bilinear_matrix_columns_loc
psi_bilinear_matrix_order_reverse
psi_bilinear_matrix_order_transp_reverse
psi_bilinear_matrix_transp_values
psi_bilinear_matrix_values
psi_det_alpha_unique
psi_det_beta_unique
ref_bitmask_energy
Called by:
davidson_diag_hjj_sjj()
u_0_h_u_0()
Calls:
davidson_collector()
davidson_slave_inproc()
dset_order()
dtranspose()
end_parallel_job()
new_parallel_job()
omp_set_nested()
- h_s2_u_0_two_e_nstates_openmp:
File :
davidson/u0_wee_u0.irp.f
subroutine H_S2_u_0_two_e_nstates_openmp(v_0,s_0,u_0,N_st,sze)
Computes $v_0 = H | u_0rangle$ and $s_0 = S^2 | u_0rangle$
Assumes that the determinants are in psi_det
istart, iend, ishift, istep are used in ZMQ parallelization.
Needs:
n_det
psi_bilinear_matrix_order_reverse
psi_bilinear_matrix_values
Called by:
u_0_h_u_0_two_e()
Calls:
dset_order()
dtranspose()
h_s2_u_0_two_e_nstates_openmp_work()
- h_s2_u_0_two_e_nstates_openmp_work:
File :
davidson/u0_wee_u0.irp.f
subroutine H_S2_u_0_two_e_nstates_openmp_work(v_t,s_t,u_t,N_st,sze,istart,iend,ishift,istep)
Computes $v_t = H | u_trangle$ and $s_t = S^2 | u_trangle$
Default should be 1,N_det,0,1
Needs:
n_det
n_int
ref_bitmask_energy
Called by:
h_s2_u_0_two_e_nstates_openmp()
Calls:
h_s2_u_0_two_e_nstates_openmp_work_1()
h_s2_u_0_two_e_nstates_openmp_work_2()
h_s2_u_0_two_e_nstates_openmp_work_3()
h_s2_u_0_two_e_nstates_openmp_work_4()
h_s2_u_0_two_e_nstates_openmp_work_n_int()
- h_s2_u_0_two_e_nstates_openmp_work_1:
File :
davidson/u0_wee_u0.irp.f_template_457
subroutine H_S2_u_0_two_e_nstates_openmp_work_1(v_t,s_t,u_t,N_st,sze,istart,iend,ishift,istep)
Computes $v_t = H | u_t rangle$ and $s_t = S^2 | u_t rangle$
Default should be 1,N_det,0,1
Needs:
n_det
n_int
nthreads_davidson
psi_bilinear_matrix_columns_loc
psi_bilinear_matrix_order_transp_reverse
psi_bilinear_matrix_transp_rows_loc
psi_bilinear_matrix_transp_values
psi_bilinear_matrix_values
psi_det_alpha_unique
psi_det_beta_unique
Called by:
h_s2_u_0_two_e_nstates_openmp_work()
Calls:
get_all_spin_singles_1()
get_all_spin_singles_and_doubles_1()
get_s2()
i_h_j_double_alpha_beta()
i_h_j_double_spin()
i_wee_j_single()
- h_s2_u_0_two_e_nstates_openmp_work_2:
File :
davidson/u0_wee_u0.irp.f_template_457
subroutine H_S2_u_0_two_e_nstates_openmp_work_2(v_t,s_t,u_t,N_st,sze,istart,iend,ishift,istep)
Computes $v_t = H | u_t rangle$ and $s_t = S^2 | u_t rangle$
Default should be 1,N_det,0,1
Needs:
n_det
n_int
nthreads_davidson
psi_bilinear_matrix_columns_loc
psi_bilinear_matrix_order_transp_reverse
psi_bilinear_matrix_transp_rows_loc
psi_bilinear_matrix_transp_values
psi_bilinear_matrix_values
psi_det_alpha_unique
psi_det_beta_unique
Called by:
h_s2_u_0_two_e_nstates_openmp_work()
Calls:
get_all_spin_singles_2()
get_all_spin_singles_and_doubles_2()
get_s2()
i_h_j_double_alpha_beta()
i_h_j_double_spin()
i_wee_j_single()
- h_s2_u_0_two_e_nstates_openmp_work_3:
File :
davidson/u0_wee_u0.irp.f_template_457
subroutine H_S2_u_0_two_e_nstates_openmp_work_3(v_t,s_t,u_t,N_st,sze,istart,iend,ishift,istep)
Computes $v_t = H | u_t rangle$ and $s_t = S^2 | u_t rangle$
Default should be 1,N_det,0,1
Needs:
n_det
n_int
nthreads_davidson
psi_bilinear_matrix_columns_loc
psi_bilinear_matrix_order_transp_reverse
psi_bilinear_matrix_transp_rows_loc
psi_bilinear_matrix_transp_values
psi_bilinear_matrix_values
psi_det_alpha_unique
psi_det_beta_unique
Called by:
h_s2_u_0_two_e_nstates_openmp_work()
Calls:
get_all_spin_singles_3()
get_all_spin_singles_and_doubles_3()
get_s2()
i_h_j_double_alpha_beta()
i_h_j_double_spin()
i_wee_j_single()
- h_s2_u_0_two_e_nstates_openmp_work_4:
File :
davidson/u0_wee_u0.irp.f_template_457
subroutine H_S2_u_0_two_e_nstates_openmp_work_4(v_t,s_t,u_t,N_st,sze,istart,iend,ishift,istep)
Computes $v_t = H | u_t rangle$ and $s_t = S^2 | u_t rangle$
Default should be 1,N_det,0,1
Needs:
n_det
n_int
nthreads_davidson
psi_bilinear_matrix_columns_loc
psi_bilinear_matrix_order_transp_reverse
psi_bilinear_matrix_transp_rows_loc
psi_bilinear_matrix_transp_values
psi_bilinear_matrix_values
psi_det_alpha_unique
psi_det_beta_unique
Called by:
h_s2_u_0_two_e_nstates_openmp_work()
Calls:
get_all_spin_singles_4()
get_all_spin_singles_and_doubles_4()
get_s2()
i_h_j_double_alpha_beta()
i_h_j_double_spin()
i_wee_j_single()
- h_s2_u_0_two_e_nstates_openmp_work_n_int:
File :
davidson/u0_wee_u0.irp.f_template_457
subroutine H_S2_u_0_two_e_nstates_openmp_work_N_int(v_t,s_t,u_t,N_st,sze,istart,iend,ishift,istep)
Computes $v_t = H | u_t rangle$ and $s_t = S^2 | u_t rangle$
Default should be 1,N_det,0,1
Needs:
n_det
n_int
nthreads_davidson
psi_bilinear_matrix_columns_loc
psi_bilinear_matrix_order_transp_reverse
psi_bilinear_matrix_transp_rows_loc
psi_bilinear_matrix_transp_values
psi_bilinear_matrix_values
psi_det_alpha_unique
psi_det_beta_unique
Called by:
h_s2_u_0_two_e_nstates_openmp_work()
Calls:
get_all_spin_singles_and_doubles_n_int()
get_all_spin_singles_n_int()
get_s2()
i_h_j_double_alpha_beta()
i_h_j_double_spin()
i_wee_j_single()
- print_energy_components:
File :
davidson/print_e_components.irp.f
subroutine print_energy_components()
Prints the different components of the energy.
Needs:
mo_integrals_n_e
mo_kinetic_integrals
mo_num
mo_pseudo_integrals
n_states
nuclear_repulsion
one_e_dm_mo_alpha
psi_energy
- u_0_h_u_0:
File :
davidson/u0_h_u0.irp.f
subroutine u_0_H_u_0(e_0,s_0,u_0,n,keys_tmp,Nint,N_st,sze)
Computes $E_0 = frac{langle u_0 | H | u_0 rangle}{langle u_0 | u_0 rangle}$
and $S_0 = frac{langle u_0 | S^2 | u_0 rangle}{langle u_0 | u_0 rangle}$
n : number of determinants
Needs:
distributed_davidson
h_matrix_all_dets
n_det_max_full
n_states_diag
s2_matrix_all_dets
Called by:
psi_energy
Calls:
h_s2_u_0_nstates_openmp()
h_s2_u_0_nstates_zmq()
- u_0_h_u_0_two_e:
File :
davidson/u0_wee_u0.irp.f
subroutine u_0_H_u_0_two_e(e_0,u_0,n,keys_tmp,Nint,N_st,sze)
Computes $E_0 = frac{ langle u_0 | H | u_0rangle}{langle u_0 | u_0 rangle}$.
n : number of determinants
Called by:
psi_energy_two_e
Calls:
h_s2_u_0_two_e_nstates_openmp()
- zmq_get_n_states_diag:
File :
davidson/davidson_parallel.irp.f
integer function zmq_get_N_states_diag(zmq_to_qp_run_socket, worker_id)
Get N_states_diag from the qp_run scheduler
Needs:
mpi_master
n_states_diag
zmq_state
Touches:
n_states_diag
- zmq_put_n_states_diag:
File :
davidson/davidson_parallel.irp.f
integer function zmq_put_N_states_diag(zmq_to_qp_run_socket,worker_id)
Put N_states_diag on the qp_run scheduler
Needs:
n_states_diag
zmq_state