7 #ifndef NUMCXX_TSPARSEMATRIX_H 8 #define NUMCXX_TSPARSEMATRIX_H 17 template<
typename T>
class TSolverUMFPACK;
18 template<
typename T>
class TPreconJacobi;
19 template<
typename T>
class TPreconILU;
40 static std::shared_ptr<TSparseMatrix <T> >
create(
index n1,
index n2) {
return std::make_shared<TSparseMatrix<T>>(n1,n2);}
44 TSparseMatrix(
const std::initializer_list<std::initializer_list<T>> &il);
47 static std::shared_ptr<TSparseMatrix <T> >
create(
const std::initializer_list<std::initializer_list<T>> &il);
87 std::shared_ptr<TArray1<int>>
pIA;
90 std::shared_ptr<TArray1<int>>
pJA;
93 std::shared_ptr<TArray1 <T> >
pA;
122 std::shared_ptr<Extension>
pExt=
nullptr;
std::shared_ptr< TArray1< int > > pJA
Column indices.
Jacobi preconditioner class.
std::shared_ptr< TMatrix< T > > calculate_inverse()
Calculate inverse of sparse matrix whuch is dense.
Sparse matrix class using CRS storage scheme.
std::shared_ptr< TMatrix< T > > copy_as_dense()
Create a dense matrix from the sparse matrix.
Header for numcxx::TMatrix.
Header for numcxx::TArray1.
std::shared_ptr< Extension > pExt
void flush()
Re-create the internal data structure in order to accomodated all newly created elements.
TArray is the common template base class for arrays and dense matrices of the numcxx project...
bool pattern_changed() const
Check if pattern has changed after last solver update.
ILU preconditioner class.
void pattern_changed(bool chg)
std::shared_ptr< TArray1< T > > pA
Entries.
Inline method definitions for class numcxx::TSparseMatrix.
index shape(int idim) const
Return the shape od the matrix.
void apply(const TArray< T > &U, TArray< T > &V) const
Apply sparse matrix to vector.
T & operator()(int i, int j)
Access operator.
Bridge class for using umfpack as solver for vmatrix.
static std::shared_ptr< TSparseMatrix< T > > create(index n1, index n2)
Static wrapper around corresponding constructor.
Base class for linear operators (matrices, sparse matrices)
std::shared_ptr< TArray1< int > > pIA
Row pointers.