Namespace to perform operation on Eigen objects. More...
Functions | |
void | sortEigenvalues (Eigen::VectorXd &eigenvalues, Eigen::MatrixXd &eigenvectors) |
sort eigenvalues | |
Eigen::VectorXd | ExpSpaced (double first, double last, int n) |
Returns exponentially spaced vector. | |
template<typename T > | |
Eigen::Matrix< T, Eigen::Dynamic, Eigen::Dynamic > | vectorTensorProduct (const Eigen::Matrix< T, Eigen::Dynamic, 1 > &g, const Eigen::Tensor< T, 3 > &c, const Eigen::Matrix< T, Eigen::Dynamic, 1 > &a) |
A function that computes the product of g.T c a, where c is a third dim tensor. | |
template Eigen::Matrix< double, Eigen::Dynamic, Eigen::Dynamic > | vectorTensorProduct (const Eigen::Matrix< double, Eigen::Dynamic, 1 > &g, const Eigen::Tensor< double, 3 > &c, const Eigen::Matrix< double, Eigen::Dynamic, 1 > &a) |
template Eigen::Matrix< int, Eigen::Dynamic, Eigen::Dynamic > | vectorTensorProduct (const Eigen::Matrix< int, Eigen::Dynamic, 1 > &g, const Eigen::Tensor< int, 3 > &c, const Eigen::Matrix< int, Eigen::Dynamic, 1 > &a) |
template Eigen::Matrix< float, Eigen::Dynamic, Eigen::Dynamic > | vectorTensorProduct (const Eigen::Matrix< float, Eigen::Dynamic, 1 > &g, const Eigen::Tensor< float, 3 > &c, const Eigen::Matrix< float, Eigen::Dynamic, 1 > &a) |
template<typename T > | |
Eigen::SparseMatrix< T > | vectorize (Eigen::SparseMatrix< T > &Matrix) |
Vectorize a Sparse Matrix. | |
template<typename T > | |
T | max (Eigen::SparseMatrix< T > &mat, label &ind_row, label &ind_col) |
Find the maximum of a sparse Matrix (Useful for DEIM) | |
template<typename T > | |
T | min (Eigen::SparseMatrix< T > &mat, label &ind_row, label &ind_col) |
Find the minimum of a sparse Matrix (Useful for DEIM) | |
template<typename T > | |
Eigen::Matrix< T, Eigen::Dynamic, Eigen::Dynamic > | innerProduct (List< Eigen::SparseMatrix< T > > &A, List< Eigen::SparseMatrix< T > > &B) |
Perform Frobenius inner Product between two list of sparse matrices A and B. | |
template<typename T > | |
Eigen::Matrix< T, Eigen::Dynamic, Eigen::Dynamic > | innerProduct (List< Eigen::SparseMatrix< T > > &A, Eigen::SparseMatrix< T > &B) |
Perform Frobenius inner Product between a list of sparse matrices A and a sparse matrix B. | |
template<typename T > | |
T | innerProduct (Eigen::SparseMatrix< T > &A, Eigen::SparseMatrix< T > &B) |
Perform Frobenius inner Product between two sparse matrices A and B. | |
template<typename T > | |
Eigen::SparseMatrix< T > | MVproduct (List< Eigen::SparseMatrix< T > > &A, Eigen::DenseBase< Eigen::Matrix< T, Eigen::Dynamic, Eigen::Dynamic > > &C) |
Sparse Matrix-Vector product between a list of sparse matrices and a vector of coefficients. | |
template<typename T > | |
Eigen::Matrix< T, Eigen::Dynamic, Eigen::Dynamic > | MVproduct (const std::vector< Eigen::Matrix< T, Eigen::Dynamic, Eigen::Dynamic > > &A, Eigen::DenseBase< Eigen::Matrix< T, Eigen::Dynamic, Eigen::Dynamic > > &C) |
Dense Matrix-Vector product between a list of sparse matrices and a vector of coefficients. | |
template<typename T > | |
List< Eigen::SparseMatrix< T > > | MMproduct (List< Eigen::SparseMatrix< T > > &A, Eigen::DenseBase< Eigen::Matrix< T, Eigen::Dynamic, Eigen::Dynamic > > &C) |
Sparse Matrix - Dense Matrix product between a list of sparse matrices and a dense matrix. | |
template<typename T > | |
T | condNumber (Eigen::Matrix< T, Eigen::Dynamic, Eigen::Dynamic > &A) |
Conditioning number of a dense matrix. | |
Namespace to perform operation on Eigen objects.
T EigenFunctions::condNumber | ( | Eigen::Matrix< T, Eigen::Dynamic, Eigen::Dynamic > & | A | ) |
Conditioning number of a dense matrix.
[in] | A | input Matrix |
T | type of object, i.e. double, float, .... |
Definition at line 426 of file EigenFunctions.H.
Eigen::VectorXd EigenFunctions::ExpSpaced | ( | double | first, |
double | last, | ||
int | n ) |
Returns exponentially spaced vector.
[in] | first | First element of the vector |
[in] | last | Last element of the vector |
[in] | n | Number of elements |
T | type of object, i.e. double, float, .... |
Definition at line 72 of file EigenFunctions.C.
T EigenFunctions::innerProduct | ( | Eigen::SparseMatrix< T > & | A, |
Eigen::SparseMatrix< T > & | B ) |
Perform Frobenius inner Product between two sparse matrices A and B.
\[out = tr(\mathbf{A}^T \mathbf{B} ) \]
[in] | A | Sparse Matrix A |
[in] | B | Sparse Matrix B |
T | type of object, i.e. double, float, .... |
Definition at line 361 of file EigenFunctions.H.
Eigen::Matrix< T, Eigen::Dynamic, Eigen::Dynamic > EigenFunctions::innerProduct | ( | List< Eigen::SparseMatrix< T > > & | A, |
Eigen::SparseMatrix< T > & | B ) |
Perform Frobenius inner Product between a list of sparse matrices A and a sparse matrix B.
\[\mathbf{A} = [\mathbf{A_1}, \dots, \mathbf{A_N}] , out_i = tr(\mathbf{A_i}^T \mathbf{B} ) \]
[in] | A | List of Matrices A |
[in] | B | Sparse Matrix B |
T | type of object, i.e. double, float, .... |
Definition at line 344 of file EigenFunctions.H.
Eigen::Matrix< T, Eigen::Dynamic, Eigen::Dynamic > EigenFunctions::innerProduct | ( | List< Eigen::SparseMatrix< T > > & | A, |
List< Eigen::SparseMatrix< T > > & | B ) |
Perform Frobenius inner Product between two list of sparse matrices A and B.
\[ \mathbf{A} = [\mathbf{A_1}, \dots, \mathbf{A_N}] , \mathbf{B} = [\mathbf{B_1}, \dots, \mathbf{B_M}] , out_{ij} = tr(\mathbf{A_i}^T \mathbf{B_j} ) \]
[in] | A | List of Matrices A |
[in] | B | List of Matrices B |
T | type of object, i.e. double, float, .... |
Definition at line 324 of file EigenFunctions.H.
T EigenFunctions::max | ( | Eigen::SparseMatrix< T > & | mat, |
label & | ind_row, | ||
label & | ind_col ) |
Find the maximum of a sparse Matrix (Useful for DEIM)
[out] | mat | The matrix |
[out] | ind_row | The ind row |
[out] | ind_col | The ind col |
T | type of object, i.e. double, float, .... |
Definition at line 276 of file EigenFunctions.H.
T EigenFunctions::min | ( | Eigen::SparseMatrix< T > & | mat, |
label & | ind_row, | ||
label & | ind_col ) |
Find the minimum of a sparse Matrix (Useful for DEIM)
[out] | mat | The matrix |
[out] | ind_row | The index for the row |
[out] | ind_col | The ind col |
T | type of object, i.e. double, float, .... |
Definition at line 300 of file EigenFunctions.H.
List< Eigen::SparseMatrix< T > > EigenFunctions::MMproduct | ( | List< Eigen::SparseMatrix< T > > & | A, |
Eigen::DenseBase< Eigen::Matrix< T, Eigen::Dynamic, Eigen::Dynamic > > & | C ) |
Sparse Matrix - Dense Matrix product between a list of sparse matrices and a dense matrix.
\[ \mathbf{A} = [\mathbf{A_1}, \dots, \mathbf{A_N}] , \mathbf{C} = [\mathbf{c_{\bullet 1}}, ...., \mathbf{c_{\bullet N}}], \mathbf{out} = [\mathbf{O_1},\dots,\mathbf{O_N}] \]
\[ \mathbf{O_i} = \sum_{k=1}^N \mathbf{A_k} c_{ki} \]
[in] | A | List of sparse Matrices |
[in] | C | Dense Matrix |
T | type of object, i.e. double, float, .... |
Definition at line 408 of file EigenFunctions.H.
Eigen::Matrix< T, Eigen::Dynamic, Eigen::Dynamic > EigenFunctions::MVproduct | ( | const std::vector< Eigen::Matrix< T, Eigen::Dynamic, Eigen::Dynamic > > & | A, |
Eigen::DenseBase< Eigen::Matrix< T, Eigen::Dynamic, Eigen::Dynamic > > & | C ) |
Dense Matrix-Vector product between a list of sparse matrices and a vector of coefficients.
\[ \mathbf{A} = [\mathbf{A_1}, \dots, \mathbf{A_N}] , \mathbf{c} = [c_1, ...., c_N] \]
\[ \mathbf{out} = \sum_{k=1}^N \mathbf{A_k} c_k \]
[in] | A | Dense Matrix A |
[in] | C | Dense Vector C |
T | type of object, i.e. double, float, .... |
Definition at line 390 of file EigenFunctions.H.
Eigen::SparseMatrix< T > EigenFunctions::MVproduct | ( | List< Eigen::SparseMatrix< T > > & | A, |
Eigen::DenseBase< Eigen::Matrix< T, Eigen::Dynamic, Eigen::Dynamic > > & | C ) |
Sparse Matrix-Vector product between a list of sparse matrices and a vector of coefficients.
\[ \mathbf{A} = [\mathbf{A_1}, \dots, \mathbf{A_N}] , \mathbf{c} = [c_1, ...., c_N] \]
\[ \mathbf{out} = \sum_{k=1}^N \mathbf{A_k} c_k \]
[in] | A | Sparse Matrix A |
[in] | C | Dense Vector C |
T | type of object, i.e. double, float, .... |
Definition at line 375 of file EigenFunctions.H.
void EigenFunctions::sortEigenvalues | ( | Eigen::VectorXd & | eigenvalues, |
Eigen::MatrixXd & | eigenvectors ) |
sort eigenvalues
[in,out] | eigenvalues | The eigenvalues |
[in,out] | eigenvectors | The eigenvectors |
Definition at line 39 of file EigenFunctions.C.
Eigen::SparseMatrix< T > EigenFunctions::vectorize | ( | Eigen::SparseMatrix< T > & | Matrix | ) |
Vectorize a Sparse Matrix.
[in] | Matrix | The matrix |
T | type of object, i.e. double, float, .... |
Definition at line 255 of file EigenFunctions.H.
template Eigen::Matrix< double, Eigen::Dynamic, Eigen::Dynamic > EigenFunctions::vectorTensorProduct | ( | const Eigen::Matrix< double, Eigen::Dynamic, 1 > & | g, |
const Eigen::Tensor< double, 3 > & | c, | ||
const Eigen::Matrix< double, Eigen::Dynamic, 1 > & | a ) |
template Eigen::Matrix< float, Eigen::Dynamic, Eigen::Dynamic > EigenFunctions::vectorTensorProduct | ( | const Eigen::Matrix< float, Eigen::Dynamic, 1 > & | g, |
const Eigen::Tensor< float, 3 > & | c, | ||
const Eigen::Matrix< float, Eigen::Dynamic, 1 > & | a ) |
template Eigen::Matrix< int, Eigen::Dynamic, Eigen::Dynamic > EigenFunctions::vectorTensorProduct | ( | const Eigen::Matrix< int, Eigen::Dynamic, 1 > & | g, |
const Eigen::Tensor< int, 3 > & | c, | ||
const Eigen::Matrix< int, Eigen::Dynamic, 1 > & | a ) |
Eigen::Matrix< T, Eigen::Dynamic, Eigen::Dynamic > EigenFunctions::vectorTensorProduct | ( | const Eigen::Matrix< T, Eigen::Dynamic, 1 > & | g, |
const Eigen::Tensor< T, 3 > & | c, | ||
const Eigen::Matrix< T, Eigen::Dynamic, 1 > & | a ) |
A function that computes the product of g.T c a, where c is a third dim tensor.
[in] | g | The first vector |
[in] | c | The three dim tensor |
[in] | a | The second vector |
Definition at line 89 of file EigenFunctions.C.