![]() |
(git:b77b4be)
|
RI-methods for HFX. More...
Functions/Subroutines | |
subroutine, public | check_inverse (matrix_1, matrix_2, name, unit_nr) |
... | |
subroutine, public | hfx_ri_pre_scf_calc_tensors (qs_env, ri_data, t_2c_int_ri, t_2c_int_pot, t_3c_int, do_kpoints) |
Calculate 2-center and 3-center integrals. | |
subroutine, public | hfx_ri_update_ks (qs_env, ri_data, ks_matrix, ehfx, mos, rho_ao, geometry_did_change, nspins, hf_fraction) |
... | |
subroutine, public | hfx_ri_update_forces (qs_env, ri_data, nspins, hf_fraction, rho_ao, rho_ao_resp, mos, use_virial, resp_only, rescale_factor) |
the general routine that calls the relevant force code | |
subroutine, public | get_force_from_3c_trace (force, t_3c_contr, t_3c_der, atom_of_kind, kind_of, idx_to_at, pref, do_mp2, deriv_dim) |
This routines calculates the force contribution from a trace over 3D tensors, i.e. force = sum_ijk A_ijk B_ijk. An iteration over the blocks is made, which index determin the atom on which the force acts. | |
subroutine, public | get_2c_der_force (force, t_2c_contr, t_2c_der, atom_of_kind, kind_of, idx_to_at, pref, do_mp2, do_ovlp) |
Update the forces due to the derivative of the a 2-center product d/dR (Q|R) | |
subroutine, public | print_ri_hfx (ri_data, qs_env) |
Print RI-HFX quantities, as required by the PRINT subsection. | |
subroutine, public | get_idx_to_atom (idx_to_at, bsizes_split, bsizes_orig) |
a small utility function that returns the atom corresponding to a block of a split tensor | |
RI-methods for HFX.
subroutine, public hfx_ri::check_inverse | ( | type(dbcsr_type), intent(inout) | matrix_1, |
type(dbcsr_type), intent(inout) | matrix_2, | ||
character(len=*), intent(in), optional | name, | ||
integer, intent(in) | unit_nr | ||
) |
subroutine, public hfx_ri::hfx_ri_pre_scf_calc_tensors | ( | type(qs_environment_type), pointer | qs_env, |
type(hfx_ri_type), intent(inout) | ri_data, | ||
type(dbcsr_type), dimension(:), intent(out) | t_2c_int_ri, | ||
type(dbcsr_type), dimension(:), intent(out) | t_2c_int_pot, | ||
type(dbt_type), dimension(:, :) | t_3c_int, | ||
logical, intent(in), optional | do_kpoints | ||
) |
Calculate 2-center and 3-center integrals.
2c: K_1(P, R) = (P|v1|R) and K_2(P, R) = (P|v2|R) 3c: int_3c(mu, lambda, P) = (mu lambda |v2| P) v_1 is HF operator, v_2 is RI metric
qs_env | ... |
ri_data | ... |
t_2c_int_RI | K_2(P, R) note: even with k-point, only need on central cell |
t_2c_int_pot | K_1(P, R) |
t_3c_int | int_3c(mu, lambda, P) |
do_kpoints | ... \notes the integral tensor arrays are already allocated on entry |
Definition at line 443 of file hfx_ri.F.
subroutine, public hfx_ri::hfx_ri_update_ks | ( | type(qs_environment_type), pointer | qs_env, |
type(hfx_ri_type), intent(inout) | ri_data, | ||
type(dbcsr_p_type), dimension(:, :), pointer | ks_matrix, | ||
real(kind=dp), intent(out) | ehfx, | ||
type(mo_set_type), dimension(:), intent(in), optional | mos, | ||
type(dbcsr_p_type), dimension(:, :), pointer | rho_ao, | ||
logical, intent(in) | geometry_did_change, | ||
integer, intent(in) | nspins, | ||
real(kind=dp), intent(in) | hf_fraction | ||
) |
subroutine, public hfx_ri::hfx_ri_update_forces | ( | type(qs_environment_type), pointer | qs_env, |
type(hfx_ri_type), intent(inout) | ri_data, | ||
integer, intent(in) | nspins, | ||
real(kind=dp), intent(in) | hf_fraction, | ||
type(dbcsr_p_type), dimension(:, :), optional | rho_ao, | ||
type(dbcsr_p_type), dimension(:), optional | rho_ao_resp, | ||
type(mo_set_type), dimension(:), intent(in), optional | mos, | ||
logical, intent(in), optional | use_virial, | ||
logical, intent(in), optional | resp_only, | ||
real(dp), intent(in), optional | rescale_factor | ||
) |
subroutine, public hfx_ri::get_force_from_3c_trace | ( | type(qs_force_type), dimension(:), pointer | force, |
type(dbt_type), intent(inout) | t_3c_contr, | ||
type(dbt_type), dimension(3), intent(inout) | t_3c_der, | ||
integer, dimension(:), intent(in) | atom_of_kind, | ||
integer, dimension(:), intent(in) | kind_of, | ||
integer, dimension(:), intent(in) | idx_to_at, | ||
real(dp), intent(in) | pref, | ||
logical, intent(in), optional | do_mp2, | ||
integer, intent(in), optional | deriv_dim | ||
) |
This routines calculates the force contribution from a trace over 3D tensors, i.e. force = sum_ijk A_ijk B_ijk. An iteration over the blocks is made, which index determin the atom on which the force acts.
force | ... |
t_3c_contr | ... |
t_3c_der | ... |
atom_of_kind | ... |
kind_of | ... |
idx_to_at | ... |
pref | ... |
do_mp2 | ... |
deriv_dim | the dimension of the tensor corresponding to the derivative (by default 1) |
Definition at line 3361 of file hfx_ri.F.
subroutine, public hfx_ri::get_2c_der_force | ( | type(qs_force_type), dimension(:), pointer | force, |
type(dbt_type), intent(inout) | t_2c_contr, | ||
type(dbt_type), dimension(3), intent(inout) | t_2c_der, | ||
integer, dimension(:), intent(in) | atom_of_kind, | ||
integer, dimension(:), intent(in) | kind_of, | ||
integer, dimension(:), intent(in) | idx_to_at, | ||
real(dp), intent(in) | pref, | ||
logical, intent(in), optional | do_mp2, | ||
logical, intent(in), optional | do_ovlp | ||
) |
Update the forces due to the derivative of the a 2-center product d/dR (Q|R)
force | ... |
t_2c_contr | A precontracted tensor containing sum_abcdPS (ab|P)(P|Q)^-1 (R|S)^-1 (S|cd) P_ac P_bd |
t_2c_der | the d/dR (Q|R) tensor, in all 3 cartesian directions |
atom_of_kind | ... |
kind_of | ... |
idx_to_at | ... |
pref | ... |
do_mp2 | ... |
do_ovlp | ... |
Definition at line 3447 of file hfx_ri.F.
subroutine, public hfx_ri::print_ri_hfx | ( | type(hfx_ri_type), intent(inout) | ri_data, |
type(qs_environment_type), pointer | qs_env | ||
) |
subroutine, public hfx_ri::get_idx_to_atom | ( | integer, dimension(:), intent(inout) | idx_to_at, |
integer, dimension(:), intent(in) | bsizes_split, | ||
integer, dimension(:), intent(in) | bsizes_orig | ||
) |