18 template<
typename Matrix>
22 #define SPECIALIZE_MATRIX_VECTOR_TRAITS(MATVEC, IDX) \
24 struct MatrixVectorTraits<MATVEC> \
27 static std::unique_ptr<MATVEC> newInstance(); \
28 static std::unique_ptr<MATVEC> newInstance(MATVEC const& A); \
29 static std::unique_ptr<MATVEC> newInstance( \
30 MatrixSpecifications const& spec); \
31 static std::unique_ptr<MATVEC> newInstance(Index const length); \
59 #undef SPECIALIZE_MATRIX_VECTOR_TRAITS
Declaration of class PETScMatrix, which provides an interface to PETSc matrix routines.
Declaration of class PETScVector, which provides an interface to PETSc vector routines.
RawMatrixType::Index IndexType
Eigen::SparseMatrix< double >::Index IndexType
Wrapper class for PETSc matrix routines for matrix.
Wrapper class for PETSc vector.
SPECIALIZE_MATRIX_VECTOR_TRAITS(PETScMatrix, PETScMatrix::IndexType)