This module contains some experimental features extending the sparse module:
#include <unsupported/Eigen/SparseExtra>
|
| bool | Eigen::getMarketHeader (const std::string &filename, int &sym, bool &iscomplex, bool &isdense) |
| | Reads the header of a matrixmarket file and determines the properties of a matrix. More...
|
| |
| template<typename SparseMatrixType > |
| bool | Eigen::loadMarket (SparseMatrixType &mat, const std::string &filename) |
| | Loads a sparse matrix from a matrixmarket format file. More...
|
| |
| template<typename DenseType > |
| bool | Eigen::loadMarketDense (DenseType &mat, const std::string &filename) |
| | Loads a dense Matrix or Vector from a matrixmarket file. If a statically sized matrix has to be parsed and the file contains the wrong dimensions it is undefined behaviour. More...
|
| |
|
template<typename VectorType > |
| bool | Eigen::loadMarketVector (VectorType &vec, const std::string &filename) |
| | Same functionality as loadMarketDense, deprecated.
|
| |
| template<typename SparseMatrixType > |
| bool | Eigen::saveMarket (const SparseMatrixType &mat, const std::string &filename, int sym=0) |
| | writes a sparse Matrix to a marketmarket format file More...
|
| |
| template<typename DenseType > |
| bool | Eigen::saveMarketDense (const DenseType &mat, const std::string &filename) |
| | writes a dense Matrix or vector to a marketmarket format file More...
|
| |
|
template<typename VectorType > |
| bool | Eigen::saveMarketVector (const VectorType &vec, const std::string &filename) |
| | Same functionality as saveMarketDense, deprecated.
|
| |
◆ getMarketHeader()
| bool Eigen::getMarketHeader |
( |
const std::string & |
filename, |
|
|
int & |
sym, |
|
|
bool & |
iscomplex, |
|
|
bool & |
isdense |
|
) |
| |
|
inline |
Reads the header of a matrixmarket file and determines the properties of a matrix.
- Parameters
-
| filename | of the file |
| sym | if the matrix is hermitian,symmetric or none of the latter (sym=0) |
| iscomplex | if the matrix has complex or real coefficients |
| isdense | if the matrix is dense or sparse |
- Returns
- true if the file was found
◆ loadMarket()
template<typename SparseMatrixType >
| bool Eigen::loadMarket |
( |
SparseMatrixType & |
mat, |
|
|
const std::string & |
filename |
|
) |
| |
Loads a sparse matrix from a matrixmarket format file.
- Template Parameters
-
| SparseMatrixType | to read into, symmetries are not supported |
- Parameters
-
| mat | SparseMatrix to read into, current values are overwritten |
| filename | to parse matrix from |
- Returns
- returns true if file exists. Returns false if the parsing did not succeed.
◆ loadMarketDense()
template<typename DenseType >
| bool Eigen::loadMarketDense |
( |
DenseType & |
mat, |
|
|
const std::string & |
filename |
|
) |
| |
Loads a dense Matrix or Vector from a matrixmarket file. If a statically sized matrix has to be parsed and the file contains the wrong dimensions it is undefined behaviour.
- Template Parameters
-
| DenseMatrixType | to read into |
- Parameters
-
| mat | DenseMatrix to read into, current values are overwritten, symmetries are not supported |
| filename | to parse matrix from |
- Returns
- true if parsing was successful. Returns false if the parsing did not succeed.
◆ saveMarket()
template<typename SparseMatrixType >
| bool Eigen::saveMarket |
( |
const SparseMatrixType & |
mat, |
|
|
const std::string & |
filename, |
|
|
int |
sym = 0 |
|
) |
| |
writes a sparse Matrix to a marketmarket format file
- Template Parameters
-
| SparseMatrixType | to write to file |
- Parameters
-
| mat | matrix to write to file |
| filename | filename to write to |
| sym | at the moment no symmetry operations are supported |
- Returns
- true if writing succeeded
◆ saveMarketDense()
template<typename DenseType >
| bool Eigen::saveMarketDense |
( |
const DenseType & |
mat, |
|
|
const std::string & |
filename |
|
) |
| |
writes a dense Matrix or vector to a marketmarket format file
- Template Parameters
-
| DenseMatrixType | to write to file |
- Parameters
-
| mat | matrix to write to file |
| filename | filename to write to |
- Returns
- true if writing succeeded