From ab41c18d601fed3d90f3266f56c6e31a48ea7a87 Mon Sep 17 00:00:00 2001 From: Gael Guennebaud Date: Wed, 18 Aug 2010 15:33:58 +0200 Subject: quickly mention how to solve a sparse problem --- doc/C09_TutorialSparse.dox | 41 ++++++++++++++++++++++++++++++++++++++++- 1 file changed, 40 insertions(+), 1 deletion(-) (limited to 'doc') diff --git a/doc/C09_TutorialSparse.dox b/doc/C09_TutorialSparse.dox index e46939e32..19fc11375 100644 --- a/doc/C09_TutorialSparse.dox +++ b/doc/C09_TutorialSparse.dox @@ -213,7 +213,46 @@ res = A.selfadjointView() * dv; // if only the lower part of A is store \section TutorialSparseDirectSolvers Using the direct solvers -TODO +To solve a sparse problem you currently have to use one or multiple of the following "unsupported" module: +- \ref SparseExtra_Module + - \b solvers: SparseLLT, SparseLDLT (\#include ) + - \b notes: built-in basic LLT and LDLT solvers +- \ref CholmodSupport_Module + - \b solver: SparseLLT (\#include ) + - \b notes: LLT solving using Cholmod, requires a SparseMatrix object. (recommended for symmetric/selfadjoint problems) +- \ref UmfPackSupport_Module + - \b solver: SparseLU (\#include ) + - \b notes: LU solving using UmfPack, requires a SparseMatrix object (recommended for squared matrices) +- \ref SuperLUSupport_Module + - \b solver: SparseLU (\#include ) + - \b notes: (LU solving using SuperLU, requires a SparseMatrix object, recommended for squared matrices) +- \ref TaucsSupport_Module + - \b solver: SparseLLT (\#include ) + - \b notes: LLT solving using Taucs, requires a SparseMatrix object (not recommended) + +\warning Those modules are currently considered to be "unsupported" because 1) they are not documented, and 2) their API is likely to change in the future. + +Here is a typical example: +\code +#include +// ... +SparseMatrix A; +// fill A +VectorXd b, x; +// fill b +// solve Ax = b using UmfPack: +SparseLU,UmfPack> lu_of_A(A); +if(!lu_of_A.succeeded()) { + // decomposiiton failed + return; +} +if(!lu_of_A.solve(b,&x)) { + // solving failed + return; +} +\endcode + +See also the class SparseLLT, class SparseLU, and class SparseLDLT. \li \b Next: TODO -- cgit v1.2.3