
Public Types | |
| typedef SparseMatrix< number > | MatrixType |
| typedef Vector< vector_number > | VectorType |
Public Member Functions | |
| ProductSparseMatrix (const MatrixType &m1, const MatrixType &m2, VectorMemory< VectorType > &mem) | |
| ProductSparseMatrix () | |
| void | initialize (const MatrixType &m1, const MatrixType &m2, VectorMemory< VectorType > &mem) |
| void | clear () |
| virtual void | vmult (VectorType &w, const VectorType &v) const |
| virtual void | Tvmult (VectorType &w, const VectorType &v) const |
| virtual void | vmult_add (VectorType &w, const VectorType &v) const |
| virtual void | Tvmult_add (VectorType &w, const VectorType &v) const |
Private Member Functions | |
| virtual const void * | get () const |
Private Attributes | |
| SmartPointer< const MatrixType, ProductSparseMatrix< number, vector_number > > | m1 |
| SmartPointer< const MatrixType, ProductSparseMatrix< number, vector_number > > | m2 |
| SmartPointer< VectorMemory < VectorType > , ProductSparseMatrix< number, vector_number > > | mem |
Poor man's matrix product of two sparse matrices. Stores two matrices m1 and m2 of arbitrary type SparseMatrix and implements matrix-vector multiplications for the product M1M2 by performing multiplication with both factors consecutively.
The documentation of ProductMatrix applies with exception that these matrices here may be rectangular.
Definition at line 224 of file matrix_lib.h.
| typedef SparseMatrix<number> ProductSparseMatrix< number, vector_number >::MatrixType |
Define the type of matrices used.
Definition at line 230 of file matrix_lib.h.
| typedef Vector<vector_number> ProductSparseMatrix< number, vector_number >::VectorType |
Define the type of vectors we plly this matrix to.
Definition at line 236 of file matrix_lib.h.
| ProductSparseMatrix< number, vector_number >::ProductSparseMatrix | ( | const MatrixType & | m1, |
| const MatrixType & | m2, | ||
| VectorMemory< VectorType > & | mem | ||
| ) |
Constructor. Additionally to the two constituting matrices, a memory pool for the auxiliary vector must be provided.
| ProductSparseMatrix< number, vector_number >::ProductSparseMatrix | ( | ) |
Constructor leaving an unitialized matrix. initialize() must be called, before the matrix can be used.
| void ProductSparseMatrix< number, vector_number >::initialize | ( | const MatrixType & | m1, |
| const MatrixType & | m2, | ||
| VectorMemory< VectorType > & | mem | ||
| ) |
| void ProductSparseMatrix< number, vector_number >::clear | ( | ) | [virtual] |
Reset pointer and release the matrix pointed to.
Implements PointerMatrixBase< Vector< vector_number > >.
| virtual void ProductSparseMatrix< number, vector_number >::vmult | ( | VectorType & | w, |
| const VectorType & | v | ||
| ) | const [virtual] |
Matrix-vector product w = m1 * m2 * v.
| virtual void ProductSparseMatrix< number, vector_number >::Tvmult | ( | VectorType & | w, |
| const VectorType & | v | ||
| ) | const [virtual] |
Tranposed matrix-vector product w = m2T * m1T * v.
| virtual void ProductSparseMatrix< number, vector_number >::vmult_add | ( | VectorType & | w, |
| const VectorType & | v | ||
| ) | const [virtual] |
Adding matrix-vector product w += m1 * m2 * v
| virtual void ProductSparseMatrix< number, vector_number >::Tvmult_add | ( | VectorType & | w, |
| const VectorType & | v | ||
| ) | const [virtual] |
Adding, tranposed matrix-vector product w += m2T * m1T * v.
| virtual const void* ProductSparseMatrix< number, vector_number >::get | ( | ) | const [private, virtual] |
Return some kind of identifier.
Implements PointerMatrixBase< Vector< vector_number > >.
SmartPointer<const MatrixType,ProductSparseMatrix<number,vector_number> > ProductSparseMatrix< number, vector_number >::m1 [private] |
The left matrix of the product.
Definition at line 299 of file matrix_lib.h.
SmartPointer<const MatrixType,ProductSparseMatrix<number,vector_number> > ProductSparseMatrix< number, vector_number >::m2 [private] |
The right matrix of the product.
Definition at line 304 of file matrix_lib.h.
SmartPointer<VectorMemory<VectorType>,ProductSparseMatrix<number,vector_number> > ProductSparseMatrix< number, vector_number >::mem [private] |
Memory for auxiliary vector.
Definition at line 309 of file matrix_lib.h.
documentation generated on Fri Feb 3 2012 06:04:10 by
doxygen
1.7.2