linbox
Public Member Functions | Protected Attributes
SparseMatrix< Field_, SparseMatrixFormat::TPL > Class Template Reference

Sparse Matrix in Triples storage. More...

#include <sparse-tpl-matrix.h>

Inherits BlackboxInterface.

+ Collaboration diagram for SparseMatrix< Field_, SparseMatrixFormat::TPL >:

Public Member Functions

std::ostream & write (std::ostream &out) const
 
void finalize (sortPolicy s=cacheOpt)
 Establish triples order. Use after setEntry's, before any applies.
 
template<class Mat1 , class Mat2 >
Mat1 & applyLeft (Mat1 &Y, const Mat2 &X) const
 Mul with this on left: Y <- AX. Requires conformal shapes.
 
template<class Mat1 , class Mat2 >
Mat1 & applyRight (Mat1 &Y, const Mat2 &X) const
 Mul with this on right: Y <- XA. Requires conformal shapes.
 
template<class OutVector , class InVector >
OutVector & apply (OutVector &y, const InVector &x) const
 y <- A x. More...
 
template<class OutVector , class InVector >
OutVector & applyTranspose (OutVector &, const InVector &) const
 y <- A^T x. More...
 
size_t size () const
 Returns number of non-zero entries. More...
 

Protected Attributes

Index rows_
 The number of rows, columns.
 

Detailed Description

template<class Field_>
class LinBox::SparseMatrix< Field_, SparseMatrixFormat::TPL >

Sparse Matrix in Triples storage.

Sparse matrix representation which stores nonzero entries by i,j,value triples.

Member Function Documentation

◆ write()

std::ostream & write ( std::ostream &  out) const
Bug:
we should not support too many formats

◆ apply()

OutVector & apply ( OutVector &  y,
const InVector &  x 
) const

y <- A x.

Performance will generally be best if A is in cacheOpt order, and rowMajor, colMajor orders are generally better than random.

◆ applyTranspose()

OutVector & applyTranspose ( OutVector &  y,
const InVector &  x 
) const

y <- A^T x.

Performance will generally be best if A is in cacheOpt order, and rowMajor, colMajor orders are generally better than random.

◆ size()

size_t size ( ) const

Returns number of non-zero entries.

Warning
(some could be zero, for instance after a rebind...

The documentation for this class was generated from the following files: