ergo
|
Go to the source code of this file.
Classes | |
struct | matrix_utilities_CompareClass< RandomAccessIterator > |
Functions | |
mat::SizesAndBlocks | prepareMatrixSizesAndBlocks (int n_basis_functions, int sparse_block_size, int factor1, int factor2, int factor3) |
void | getMatrixPermutation (const BasisInfoStruct &basisInfo, int sparse_block_size, int factor1, int factor2, int factor3, std::vector< int > &permutation) |
void | getMatrixPermutation (const BasisInfoStruct &basisInfo, int sparse_block_size, int factor1, int factor2, int factor3, std::vector< int > &permutation, std::vector< int > &inversePermutation) |
void | getMatrixPermutationOnlyFactor2 (const std::vector< ergo_real > &xcoords, const std::vector< ergo_real > &ycoords, const std::vector< ergo_real > &zcoords, int sparse_block_size_lowest, int first_factor, std::vector< int > &permutation, std::vector< int > &inversePermutation) |
void | getMatrixPermutationOnlyFactor2 (const BasisInfoStruct &basisInfo, int sparse_block_size_lowest, int first_factor, std::vector< int > &permutation, std::vector< int > &inversePermutation) |
void | fill_matrix_with_random_numbers (int n, symmMatrix &M) |
void | add_random_diag_perturbation (int n, symmMatrix &M, ergo_real eps) |
bool | check_if_matrix_contains_strange_elements (const symmMatrix &M, std::vector< int > const &inversePermutationHML) |
This function is supposed to check if a matrix contains any strange numbers such as "inf" or "nan". More... | |
void | output_matrix (int n, const ergo_real *matrix, const char *matrixName) |
template<class Tmatrix > | |
ergo_real | compute_maxabs_sparse (const Tmatrix &M) |
template<typename Tmatrix > | |
void | get_all_nonzeros (Tmatrix const &A, std::vector< int > const &inversePermutation, std::vector< int > &rowind, std::vector< int > &colind, std::vector< ergo_real > &values) |
template<typename Tmatrix > | |
void | output_distance_vs_magnitude (BasisInfoStruct const &basisInfo, Tmatrix const &A, std::vector< int > const &inversePermutation, std::string name, int resolution_r, int resolution_m) |
template<typename Tmatrix > | |
void | output_magnitude_histogram (Tmatrix const &A, std::string name, int resolution_m) |
template<typename Tmatrix > | |
void | write_matrix_in_matrix_market_format (Tmatrix const &A, std::vector< int > const &inversePermutation, std::string filename, std::string identifier, std::string method_and_basis) |
void add_random_diag_perturbation | ( | int | n, |
symmMatrix & | M, | ||
ergo_real | eps | ||
) |
References mat::MatrixSymmetric< Treal, Tmatrix >::add_values(), and rand_minus1_to_1().
Referenced by getAllEigsInterval().
bool check_if_matrix_contains_strange_elements | ( | const symmMatrix & | M, |
std::vector< int > const & | inversePermutationHML | ||
) |
This function is supposed to check if a matrix contains any strange numbers such as "inf" or "nan".
The function returns true is any strange numbers are found, and false if the matrix seems ok.
References mat::MatrixSymmetric< Treal, Tmatrix >::get_all_values(), and max.
Referenced by SCF_restricted::get_2e_part_and_energy().
ergo_real compute_maxabs_sparse | ( | const Tmatrix & | M | ) |
void fill_matrix_with_random_numbers | ( | int | n, |
symmMatrix & | M | ||
) |
References mat::MatrixSymmetric< Treal, Tmatrix >::random().
void get_all_nonzeros | ( | Tmatrix const & | A, |
std::vector< int > const & | inversePermutation, | ||
std::vector< int > & | rowind, | ||
std::vector< int > & | colind, | ||
std::vector< ergo_real > & | values | ||
) |
Referenced by output_distance_vs_magnitude(), and write_matrix_in_matrix_market_format().
void getMatrixPermutation | ( | const BasisInfoStruct & | basisInfo, |
int | sparse_block_size, | ||
int | factor1, | ||
int | factor2, | ||
int | factor3, | ||
std::vector< int > & | permutation | ||
) |
References getMatrixPermutation().
void getMatrixPermutation | ( | const BasisInfoStruct & | basisInfo, |
int | sparse_block_size, | ||
int | factor1, | ||
int | factor2, | ||
int | factor3, | ||
std::vector< int > & | permutation, | ||
std::vector< int > & | inversePermutation | ||
) |
References BasisInfoStruct::basisFuncList, BasisFuncStruct_::centerCoords, do_output(), getPermutation(), LOG_AREA_SCF, LOG_CAT_INFO, and BasisInfoStruct::noOfBasisFuncs.
Referenced by calculation_shared(), getMatrixPermutation(), load_density_and_project_sparse(), main(), SCF::MatOptions::prepare(), and preparePermutations().
void getMatrixPermutationOnlyFactor2 | ( | const std::vector< ergo_real > & | xcoords, |
const std::vector< ergo_real > & | ycoords, | ||
const std::vector< ergo_real > & | zcoords, | ||
int | sparse_block_size_lowest, | ||
int | first_factor, | ||
std::vector< int > & | permutation, | ||
std::vector< int > & | inversePermutation | ||
) |
References do_output(), getPermutation(), LOG_AREA_SCF, and LOG_CAT_INFO.
Referenced by getMatrixPermutationOnlyFactor2().
void getMatrixPermutationOnlyFactor2 | ( | const BasisInfoStruct & | basisInfo, |
int | sparse_block_size_lowest, | ||
int | first_factor, | ||
std::vector< int > & | permutation, | ||
std::vector< int > & | inversePermutation | ||
) |
void output_distance_vs_magnitude | ( | BasisInfoStruct const & | basisInfo, |
Tmatrix const & | A, | ||
std::vector< int > const & | inversePermutation, | ||
std::string | name, | ||
int | resolution_r, | ||
int | resolution_m | ||
) |
basisInfo | Info about basis set. |
A | The matrix. |
inversePermutation | Permutation to be used when accessing matrix elements. |
name | File name. |
resolution_r | Resolution in r-direction, r is the distance between atoms. |
resolution_m | Resolution m-direction, m is the magnitude of matrix elements. |
References BasisInfoStruct::basisFuncList, BasisFuncStruct_::centerCoords, get_all_nonzeros(), and BasisInfoStruct::noOfBasisFuncs.
Referenced by SCF_restricted::get_2e_part_and_energy(), SCF_restricted::get_new_density_matrix(), and SCF_general::SCF_general().
void output_magnitude_histogram | ( | Tmatrix const & | A, |
std::string | name, | ||
int | resolution_m | ||
) |
A | The matrix. |
name | File name. |
resolution_m | Resolution m-direction, m is the magnitude of matrix elements. |
Referenced by get_dens_from_fock_sparse(), and SCF_general::SCF_general().
void output_matrix | ( | int | n, |
const ergo_real * | matrix, | ||
const char * | matrixName | ||
) |
Referenced by dft_get_uxc(), and dft_get_xc().
mat::SizesAndBlocks prepareMatrixSizesAndBlocks | ( | int | n_basis_functions, |
int | sparse_block_size, | ||
int | factor1, | ||
int | factor2, | ||
int | factor3 | ||
) |
References do_output(), LOG_AREA_SCF, and LOG_CAT_INFO.
Referenced by calculation_shared(), load_density_and_project_sparse(), main(), SCF::MatOptions::prepare(), and preparePermutations().
void write_matrix_in_matrix_market_format | ( | Tmatrix const & | A, |
std::vector< int > const & | inversePermutation, | ||
std::string | filename, | ||
std::string | identifier, | ||
std::string | method_and_basis | ||
) |