ergo
|
Code for various utilities used by 2-electron integral computation (i.e. More...
#include <string.h>
#include <stdexcept>
#include "integrals_2el_utils.h"
#include "integrals_hermite.h"
#include "template_blas_common.h"
#include "basis_func_extent.h"
#include "integrals_2el_repeating.h"
#include "integrals_general.h"
Functions | |
ergo_real | get_max_abs_vector_element (int n, const ergo_real *vector) |
void | allocate_buffers_needed_by_integral_code (const IntegralInfo &integralInfo, int maxNoOfMonomials, int basisFuncListCount_max, JK_contribs_buffer_struct *bufferStruct) |
void | free_buffers_needed_by_integral_code (JK_contribs_buffer_struct *bufferStruct) |
int | get_related_integrals_h (const IntegralInfo &integralInfo, const JK::ExchWeights &CAM_params, int n1max, int noOfMonomials_1, int n2max, int noOfMonomials_2, ergo_real dx0, ergo_real dx1, ergo_real dx2, ergo_real alpha1, ergo_real alpha2, ergo_real alpha0, ergo_real *primitiveIntegralList, ergo_real *primitiveIntegralList_work, ergo_real resultPreFactor) |
static ergo_real | erfc_inverse (ergo_real x, ergo_real requested_accuracy) |
void | compute_extent_for_list_of_distributions (int n, DistributionSpecStructLabeled *distrList, ergo_real threshold, ergo_real maxLimitingFactor, ergo_real maxabsDmatelement) |
int | get_list_of_labeled_distrs_maxLimitingFactor (const BasisInfoStruct &basisInfo, const IntegralInfo &integralInfo, ergo_real threshold, ergo_real *resultMaxLimitingFactor, ergo_real maxDensityMatrixElement) |
int | get_list_of_labeled_distrs (const BasisInfoStruct &basisInfo, const IntegralInfo &integralInfo, ergo_real threshold, DistributionSpecStructLabeled *resultList, int maxCountDistrs, ergo_real maxLimitingFactor, const ergo_real *dens, ergo_real maxDensityMatrixElement) |
static void | create_item_list_from_list_of_distributions (int n, const DistributionSpecStructLabeled *distrList, box_item_struct *itemList) |
int | create_box_system_and_reorder_distrs (int distrCount, DistributionSpecStructLabeled *distrList, ergo_real toplevelBoxSize, BoxSystem &boxSystem) |
Code for various utilities used by 2-electron integral computation (i.e.
computation of J and K matrices).
void allocate_buffers_needed_by_integral_code | ( | const IntegralInfo & | integralInfo, |
int | maxNoOfMonomials, | ||
int | basisFuncListCount_max, | ||
JK_contribs_buffer_struct * | bufferStruct | ||
) |
References MAX_NO_OF_BASIS_FUNC_PAIRS_PER_BATCH, JK_contribs_buffer_struct::partial_dmat_1, JK_contribs_buffer_struct::partial_dmat_2, JK_contribs_buffer_struct::partial_K_1, JK_contribs_buffer_struct::partial_K_2, JK_contribs_buffer_struct::primitiveIntegralList, JK_contribs_buffer_struct::primitiveIntegralList_work, and JK_contribs_buffer_struct::summedIntegralList.
Referenced by compute_JK_single_box(), execute_joblist_J_std_serial(), execute_joblist_J_std_thread_func(), execute_joblist_K_serial(), and execute_joblist_K_thread_func().
void compute_extent_for_list_of_distributions | ( | int | n, |
DistributionSpecStructLabeled * | distrList, | ||
ergo_real | threshold, | ||
ergo_real | maxLimitingFactor, | ||
ergo_real | maxabsDmatelement | ||
) |
References DistributionSpecStructLabeled::distr, erfc_inverse(), DistributionSpecStruct::extent, and template_blas_sqrt().
Referenced by compute_J_by_boxes_linear(), compute_JK_single_box(), and compute_K_by_boxes().
int create_box_system_and_reorder_distrs | ( | int | distrCount, |
DistributionSpecStructLabeled * | distrList, | ||
ergo_real | toplevelBoxSize, | ||
BoxSystem & | boxSystem | ||
) |
References BoxSystem::create_box_system(), create_item_list_from_list_of_distributions(), do_output(), LOG_AREA_INTEGRALS, and LOG_CAT_ERROR.
Referenced by compute_J_by_boxes_linear(), and compute_K_by_boxes().
|
static |
References box_item_struct::originalIndex.
Referenced by create_box_system_and_reorder_distrs().
References do_output(), LOG_AREA_INTEGRALS, LOG_CAT_ERROR, and template_blas_erfc().
Referenced by compute_extent_for_list_of_distributions().
void free_buffers_needed_by_integral_code | ( | JK_contribs_buffer_struct * | bufferStruct | ) |
References JK_contribs_buffer_struct::partial_dmat_1, JK_contribs_buffer_struct::partial_dmat_2, JK_contribs_buffer_struct::partial_K_1, JK_contribs_buffer_struct::partial_K_2, JK_contribs_buffer_struct::primitiveIntegralList, JK_contribs_buffer_struct::primitiveIntegralList_work, and JK_contribs_buffer_struct::summedIntegralList.
Referenced by compute_JK_single_box(), execute_joblist_J_std_serial(), execute_joblist_J_std_thread_func(), execute_joblist_K_serial(), and execute_joblist_K_thread_func().
int get_list_of_labeled_distrs | ( | const BasisInfoStruct & | basisInfo, |
const IntegralInfo & | integralInfo, | ||
ergo_real | threshold, | ||
DistributionSpecStructLabeled * | resultList, | ||
int | maxCountDistrs, | ||
ergo_real | maxLimitingFactor, | ||
const ergo_real * | dens, | ||
ergo_real | maxDensityMatrixElement | ||
) |
References DistributionSpecStructLabeled::basisFuncIndex_1, DistributionSpecStructLabeled::basisFuncIndex_2, BasisInfoStruct::basisFuncList, BasisFuncStruct::centerCoords, compute_extent_for_all_basis_funcs_2el(), BoxSystem::create_box_system(), distance(), DistributionSpecStructLabeled::distr, DistributionSpecStructLabeled::dmatElement, IntegratorWithMemory::do_2e_integral(), do_output(), BoxSystem::get_items_near_point(), get_product_simple_primitives(), DistributionSpecStructLabeled::limitingFactor, LOG_AREA_INTEGRALS, LOG_CAT_ERROR, BasisInfoStruct::noOfBasisFuncs, DistributionSpecStructLabeled::pairIndex, and template_blas_sqrt().
Referenced by compute_JK_single_box(), compute_K_by_boxes(), and create_CSR_for_K().
int get_list_of_labeled_distrs_maxLimitingFactor | ( | const BasisInfoStruct & | basisInfo, |
const IntegralInfo & | integralInfo, | ||
ergo_real | threshold, | ||
ergo_real * | resultMaxLimitingFactor, | ||
ergo_real | maxDensityMatrixElement | ||
) |
References BasisInfoStruct::basisFuncList, BasisFuncStruct::centerCoords, compute_extent_for_all_basis_funcs_2el(), BoxSystem::create_box_system(), distance(), IntegratorWithMemory::do_2e_integral(), do_output(), BoxSystem::get_items_near_point(), get_product_simple_primitives(), LOG_AREA_INTEGRALS, LOG_CAT_ERROR, BasisInfoStruct::noOfBasisFuncs, and template_blas_sqrt().
Referenced by compute_JK_single_box(), compute_K_by_boxes(), and create_CSR_for_K().
References template_blas_fabs().
Referenced by compute_J_by_boxes(), compute_J_by_boxes_linear(), compute_JK_single_box(), and get_list_of_labeled_distrs_linear().
int get_related_integrals_h | ( | const IntegralInfo & | integralInfo, |
const JK::ExchWeights & | CAM_params, | ||
int | n1max, | ||
int | noOfMonomials_1, | ||
int | n2max, | ||
int | noOfMonomials_2, | ||
ergo_real | dx0, | ||
ergo_real | dx1, | ||
ergo_real | dx2, | ||
ergo_real | alpha1, | ||
ergo_real | alpha2, | ||
ergo_real | alpha0, | ||
ergo_real * | primitiveIntegralList, | ||
ergo_real * | primitiveIntegralList_work, | ||
ergo_real | resultPreFactor | ||
) |