diff options
author | Gael Guennebaud <g.gael@free.fr> | 2015-12-07 12:33:38 +0100 |
---|---|---|
committer | Gael Guennebaud <g.gael@free.fr> | 2015-12-07 12:33:38 +0100 |
commit | ad3d68400e361e53bd13ddc0e8ea187883a04f12 (patch) | |
tree | ecce37fa8749550e0eafb3aeea5306e3bfaf5e6a /doc/MatrixfreeSolverExample.dox | |
parent | b37036afce20e902cd5191a2a985f39b1f7e22e3 (diff) |
Add matrix-free solver example
Diffstat (limited to 'doc/MatrixfreeSolverExample.dox')
-rw-r--r-- | doc/MatrixfreeSolverExample.dox | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/doc/MatrixfreeSolverExample.dox b/doc/MatrixfreeSolverExample.dox new file mode 100644 index 000000000..000cb0bbe --- /dev/null +++ b/doc/MatrixfreeSolverExample.dox @@ -0,0 +1,20 @@ + +namespace Eigen { + +/** + +\eigenManualPage MatrixfreeSolverExample Matrix-free solvers + +Iterative solvers such as ConjugateGradient and BiCGSTAB can be used in a matrix free context. To this end, user must provide a wrapper class inheriting EigenBase<> and implementing the following methods: + - Index rows() and Index cols(): returns number of rows and columns respectively + - operator* with and %Eigen dense column vector (its actual implementation goes in a specialization of the internal::generic_product_impl class) + +Eigen::internal::traits<> must also be specialized for the wrapper type. + +Here is a complete example wrapping a Eigen::SparseMatrix: +\include matrixfree_cg.cpp +Output: \verbinclude matrixfree_cg.out + +*/ + +}
\ No newline at end of file |