Main Page | Modules | Namespace List | Class Hierarchy | Class List | File List | Namespace Members | Class Members | File Members | Related Pages

ZeroOne Class Template Reference
[linbox/blackbox]

#include <zero-one.h>

Inheritance diagram for ZeroOne:

BlackboxInterface List of all members.

Detailed Description

template<class _Field>
class LinBox::ZeroOne< _Field >

Time and space efficient representation of sparse {0,1}-matrices.

A 0-1 matrix is a matrix with all 0's and 1's as entries. We're using a NAG-sparse format. Applies can be performed fast, using only additions. When initalizing this class, you only need to build 2 arrays of equal length: an array of the row indices for the non-zero (1's) entries, and an array of the column indices for the non-zero (1's) entries.

A {0, 1,-1} matrix can be effecively represented as the Dif of two ZeroOne's.


Public Member Functions

template<class OutVector, class InVector> OutVector & apply (OutVector &y, const InVector &x) const
template<class OutVector, class InVector> OutVector & applyTranspose (OutVector &y, const InVector &x) const
std::istream & read (std::istream &is)


Member Function Documentation

OutVector& apply OutVector &  y,
const InVector &  x
const [inline]
 

Uses one of the three private utility functions. It calls the generalized utility function _apply if there is no special ordering, _fyapply if there is C_ordering or _fxapply if there is fortran_ordering

OutVector& applyTranspose OutVector &  y,
const InVector &  x
const [inline]
 

Uses one of the three private utility functions, in the manner described above. Worthy of note is the fact that applyTranspose works by passing the column positions to the _apply functions as if they were rows, and row positions as if they were columns, as if the matrix had been transposed.

std::istream& read std::istream &  is  )  [inline]
 

Read the matrix from a stream in the JGD's SMS format

Parameters:
is Input stream from which to read the matrix
Returns:
Reference to input stream


The documentation for this class was generated from the following file:
Generated on Thu Feb 8 22:32:58 2007 for linbox by doxygen 1.3.4