Go to the documentation of this file.
38 #ifndef INTEGRALS_2EL_UTILS_HEADER
39 #define INTEGRALS_2EL_UTILS_HEADER
47 #define MAX_NO_OF_BRANCHES 10
100 int maxNoOfMonomials,
101 int basisFuncListCount_max,
110 int n1max,
int noOfMonomials_1,
111 int n2max,
int noOfMonomials_2,
Treal template_blas_sqrt(Treal x)
Definition: integrals_2el_repeating.h:59
Definition: integrals_2el_utils.h:71
ergo_real * summedIntegralList
Definition: integrals_2el_utils.h:86
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)
Definition: integrals_2el_utils.cc:369
int noOfBasisFuncs
Definition: basisinfo.h:120
int get_list_of_labeled_distrs_maxLimitingFactor(const BasisInfoStruct &basisInfo, const IntegralInfo &integralInfo, ergo_real threshold, ergo_real *resultMaxLimitingFactor, ergo_real maxDensityMatrixElement)
Definition: integrals_2el_utils.cc:269
Definition: basisinfo.h:50
Code for determining extent of basis functions, for 2-electron integral evaluation.
int originalIndex
Definition: box_system.h:48
int row
Definition: integrals_2el_utils.h:54
int basisFuncIndex_1
Definition: basisinfo.h:59
int create_box_system_and_reorder_distrs(int distrCount, DistributionSpecStructLabeled *distrList, ergo_real toplevelBoxSize, BoxSystem &boxSystem)
Definition: integrals_2el_utils.cc:508
int pairIndex
Definition: basisinfo.h:61
#define LOG_CAT_ERROR
Definition: output.h:47
box_struct_basic basicBox
Definition: integrals_2el_utils.h:73
double ergo_real
Definition: realtype.h:69
static void create_item_list_from_list_of_distributions(int n, const DistributionSpecStructLabeled *distrList, box_item_struct *itemList)
Definition: integrals_2el_utils.cc:494
void compute_extent_for_list_of_distributions(int n, DistributionSpecStructLabeled *distrList, ergo_real threshold, ergo_real maxLimitingFactor, ergo_real maxabsDmatelement)
Definition: integrals_2el_utils.cc:252
int multiply_by_hermite_conversion_matrix_from_left(int n1max, int n2max, ergo_real a, ergo_real *A, ergo_real *result) const
Definition: integral_info.cc:261
BoxSystem class representing a hierarchical data structure of boxes in 3D space (an oct-tree).
Treal template_blas_erfc(Treal x)
General functionality related to computation of integrals involving Gaussian basis functions.
Definition: basisinfo.h:112
void addContrib(int row, int col, ergo_real value)
Definition: integrals_2el_utils.cc:67
int indexInCurrVec
Definition: integrals_2el_utils.h:61
int get_product_simple_primitives(const BasisInfoStruct &basisInfoA, int iA, const BasisInfoStruct &basisInfoB, int iB, DistributionSpecStruct resultList[], int maxCount, ergo_real threshold)
Definition: integrals_general.cc:268
ergo_real * partial_dmat_2
Definition: integrals_2el_utils.h:90
Treal template_blas_fabs(Treal x)
int basisFuncIndex_2
Definition: basisinfo.h:60
void compute_extent_for_list_of_distributions(int n, DistributionSpecStructLabeled *distrList, ergo_real threshold, ergo_real maxLimitingFactor, ergo_real maxabsDmatelement)
Definition: integrals_2el_utils.cc:252
void allocate_buffers_needed_by_integral_code(const IntegralInfo &integralInfo, int maxNoOfMonomials, int basisFuncListCount_max, JK_contribs_buffer_struct *bufferStruct)
Definition: integrals_2el_utils.cc:126
void allocate_buffers_needed_by_integral_code(const IntegralInfo &integralInfo, int maxNoOfMonomials, int basisFuncListCount_max, JK_contribs_buffer_struct *bufferStruct)
Definition: integrals_2el_utils.cc:126
const RowColVal & fetchNextContrib(int &currVecIndexForFetch, int &indexInCurrVecForFetch) const
Definition: integrals_2el_utils.cc:86
int col
Definition: integrals_2el_utils.h:55
int currContribCount
Definition: integrals_2el_utils.h:60
static const int nVectorsMax
Definition: integrals_2el_utils.h:58
std::vector< RowColVal > * vList[nVectorsMax]
Definition: integrals_2el_utils.h:63
int branchCountListForJ[MAX_NO_OF_BRANCHES]
Definition: integrals_2el_utils.h:77
ergo_real * partial_K_2
Definition: integrals_2el_utils.h:92
int create_box_system_and_reorder_distrs(int distrCount, DistributionSpecStructLabeled *distrList, ergo_real toplevelBoxSize, BoxSystem &boxSystem)
Definition: integrals_2el_utils.cc:508
int get_related_integrals_hermite(const IntegralInfo &integralInfo, const JK::ExchWeights ¶msCAM, int n1max, int noOfMonomials_1, int n2max, int noOfMonomials_2, ergo_real dx0, ergo_real dx1, ergo_real dx2, ergo_real alpha0, ergo_real resultPreFactor, ergo_real *primitiveIntegralList)
Definition: integrals_hermite.cc:53
Contains coefficients needed for quick integral evaluation.
Definition: integral_info.h:94
Definition: basisinfo.h:58
Definition: box_system.h:46
Code for various utilities used by 2-electron integral computation (i.e. computation of J and K matri...
ergo_real get_max_abs_vector_element(int n, const ergo_real *vector)
Definition: integrals_2el_utils.cc:103
#define MAX_NO_OF_BRANCHES
Definition: integrals_2el_utils.h:47
#define MAX_NO_OF_BASIS_FUNC_PAIRS_PER_BATCH
Definition: organize_distrs.h:97
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)
Definition: integrals_2el_utils.cc:176
int compute_extent_for_all_basis_funcs_2el(const IntegralInfo &integralInfo, const BasisInfoStruct &basisInfo, ergo_real *basisFuncExtentList, ergo_real threshold, ergo_real maxAbsDensMatElement)
Definition: basis_func_extent.cc:125
ergo_real do_2e_integral(const DistributionSpecStruct *psi)
Definition: integrals_2el_repeating.cc:90
Definition: integrals_2el_utils.h:53
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)
Definition: integrals_2el_utils.cc:369
distr_list_description_struct distrListForK
Definition: integrals_2el_utils.h:79
void free_buffers_needed_by_integral_code(JK_contribs_buffer_struct *bufferStruct)
Definition: integrals_2el_utils.cc:152
int get_list_of_labeled_distrs_maxLimitingFactor(const BasisInfoStruct &basisInfo, const IntegralInfo &integralInfo, ergo_real threshold, ergo_real *resultMaxLimitingFactor, ergo_real maxDensityMatrixElement)
Definition: integrals_2el_utils.cc:269
ergo_real value
Definition: integrals_2el_utils.h:56
BasisFuncStruct * basisFuncList
Definition: basisinfo.h:121
Definition: integrals_2el_utils.h:52
Vector3D centerCoords
Definition: basisinfo.h:90
Code for computation of Coulomb integrals of Hermite Gaussians, using the the McMurchie-Davidson sche...
#define LOG_AREA_INTEGRALS
Definition: output.h:60
Definition: integral_info.h:148
box_struct()
Definition: integrals_2el_utils.cc:118
ergo_real * primitiveIntegralList_work
Definition: integrals_2el_utils.h:88
Definition: organize_distrs_mm.h:63
Functionality for keeping track of certain kinds of integrals that are computed repeatedly,...
int currVecIndex
Definition: integrals_2el_utils.h:59
Definition: integrals_2el_utils.h:85
Definition: box_system.h:53
~ResultMatContrib()
Definition: integrals_2el_utils.cc:62
Definition: box_system.h:71
Code for organizing a given set of primitive Gaussian distributions (typically coming from basis func...
int get_items_near_point(const box_item_struct *itemList, const ergo_real *coords, ergo_real distance, int *resultOrgIndexList) const
Goes through existning box system to find all items within specified distance from given reference po...
Definition: box_system.cc:430
static ergo_real erfc_inverse(ergo_real x, ergo_real requested_accuracy)
Definition: integrals_2el_utils.cc:220
ergo_real * partial_dmat_1
Definition: integrals_2el_utils.h:89
ResultMatContrib()
Definition: integrals_2el_utils.cc:51
static ergo_real distance(const ergo_real *a, const ergo_real *b)
Coomputes distance between two points, they do not need to be of the Vector3D type.
Definition: dft_common.cc:526
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)
Definition: integrals_2el_utils.cc:176
DistributionSpecStruct distr
Definition: basisinfo.h:65
int multiply_by_hermite_conversion_matrix_from_right(int n1max, int n2max, ergo_real a, ergo_real *A, ergo_real *result) const
Definition: integral_info.cc:253
void do_output(int logCategory, int logArea, const char *format,...)
Definition: output.cc:53
ergo_real * partial_K_1
Definition: integrals_2el_utils.h:91
ergo_real get_max_abs_vector_element(int n, const ergo_real *vector)
Definition: integrals_2el_utils.cc:103
int currVecReservedSize
Definition: integrals_2el_utils.h:62
ergo_real extent
Definition: basisinfo.h:53
distr_list_description_struct branchListForJ[MAX_NO_OF_BRANCHES]
Definition: integrals_2el_utils.h:75
ergo_real * primitiveIntegralList
Definition: integrals_2el_utils.h:87
ergo_real limitingFactor
Definition: basisinfo.h:63
ergo_real dmatElement
Definition: basisinfo.h:64
Code for organizing a given set of primitive Gaussian distributions (typically coming from basis func...
int create_box_system(box_item_struct *itemList, int noOfItems, ergo_real toplevelBoxSize)
Creates the box system.
Definition: box_system.cc:74
int branchIndexListForJ[MAX_NO_OF_BRANCHES]
Definition: integrals_2el_utils.h:76
void free_buffers_needed_by_integral_code(JK_contribs_buffer_struct *bufferStruct)
Definition: integrals_2el_utils.cc:152