SOFA API  014b24ea
Open source framework for multi-physics simuation
sofa::component::linearsolver::MinResLinearSolver< TMatrix, TVector > Class Template Reference

#include <MinResLinearSolver.h>

Inheritance diagram for sofa::component::linearsolver::MinResLinearSolver< TMatrix, TVector >:

Detailed Description

template<class TMatrix, class TVector>
class sofa::component::linearsolver::MinResLinearSolver< TMatrix, TVector >

Linear system solver using the MINRES iterative algorithm

Author
Matthieu Nesme
Date
2013

Public Attributes

Data< unsigned > f_maxIter
 maximum number of iterations of the Conjugate Gradient solution More...
 
Data< doublef_tolerance
 desired precision of the Conjugate Gradient Solution (ratio of current residual norm over initial residual norm) More...
 
Data< boolf_verbose
 Dump system state at each iteration. More...
 
Data< std::map< std::string, sofa::helper::vector< SReal > > > f_graph
 Graph of residuals at each iteration. More...
 

Public Member Functions

 SOFA_CLASS (SOFA_TEMPLATE2(MinResLinearSolver, TMatrix, TVector), SOFA_TEMPLATE2(sofa::component::linearsolver::MatrixLinearSolver, TMatrix, TVector))
 
void resetSystem () override
 
void setSystemMBKMatrix (const sofa::core::MechanicalParams *mparams) override
 
void solve (Matrix &M, Vector &x, Vector &b) override
 Solve Mx=b. More...
 

Protected Member Functions

 MinResLinearSolver ()
 Linear system solver using the conjugate gradient iterative algorithm. More...
 

Attribute details

template<class TMatrix , class TVector >
Data<std::map < std::string, sofa::helper::vector<SReal> > > sofa::component::linearsolver::MinResLinearSolver< TMatrix, TVector >::f_graph

Graph of residuals at each iteration.

template<class TMatrix , class TVector >
Data<unsigned> sofa::component::linearsolver::MinResLinearSolver< TMatrix, TVector >::f_maxIter

maximum number of iterations of the Conjugate Gradient solution

template<class TMatrix , class TVector >
Data<double> sofa::component::linearsolver::MinResLinearSolver< TMatrix, TVector >::f_tolerance

desired precision of the Conjugate Gradient Solution (ratio of current residual norm over initial residual norm)

template<class TMatrix , class TVector >
Data<bool> sofa::component::linearsolver::MinResLinearSolver< TMatrix, TVector >::f_verbose

Dump system state at each iteration.

Constructor details

template<class TMatrix , class TVector >
sofa::component::linearsolver::MinResLinearSolver< TMatrix, TVector >::MinResLinearSolver ( )
protected

Linear system solver using the conjugate gradient iterative algorithm.

Function details

template<class TMatrix , class TVector >
void sofa::component::linearsolver::MinResLinearSolver< TMatrix, TVector >::resetSystem ( )
override
template<class TMatrix , class TVector >
void sofa::component::linearsolver::MinResLinearSolver< TMatrix, TVector >::setSystemMBKMatrix ( const sofa::core::MechanicalParams mparams)
override
template<class TMatrix , class TVector >
sofa::component::linearsolver::MinResLinearSolver< TMatrix, TVector >::SOFA_CLASS ( SOFA_TEMPLATE2(MinResLinearSolver< TMatrix, TVector >, TMatrix, TVector)  ,
SOFA_TEMPLATE2(sofa::component::linearsolver::MatrixLinearSolver, TMatrix, TVector)   
)
template<class TMatrix , class TVector >
void sofa::component::linearsolver::MinResLinearSolver< TMatrix, TVector >::solve ( Matrix A,
Vector x,
Vector b 
)
override

Solve Mx=b.

Solve Ax=b code issued (and modified) from tminres (https://code.google.com/p/tminres/)