Skip to content
Snippets Groups Projects
Commit 1119c141 authored by Christophe Geuzaine's avatar Christophe Geuzaine
Browse files

use MUMPS if available

parent dc820a9c
No related branches found
No related tags found
No related merge requests found
...@@ -106,12 +106,16 @@ class linearSystemGmm : public linearSystem<scalar> { ...@@ -106,12 +106,16 @@ class linearSystemGmm : public linearSystem<scalar> {
void setGmres(int n){ _gmres = n; } void setGmres(int n){ _gmres = n; }
virtual int systemSolve() virtual int systemSolve()
{ {
#if defined(HAVE_MUMPS)
gmm::MUMPS_solve(*_a, *_x, *_b);
#else
//gmm::ilutp_precond<gmm::row_matrix<gmm::wsvector<scalar> > > P(*_a, 25, 0.); //gmm::ilutp_precond<gmm::row_matrix<gmm::wsvector<scalar> > > P(*_a, 25, 0.);
gmm::ildltt_precond<gmm::row_matrix<gmm::wsvector<scalar> > > P(*_a, 30, 1.e-10); gmm::ildltt_precond<gmm::row_matrix<gmm::wsvector<scalar> > > P(*_a, 30, 1.e-10);
gmm::iteration iter(_prec); gmm::iteration iter(_prec);
iter.set_noisy(_noisy); iter.set_noisy(_noisy);
if(_gmres) gmm::gmres(*_a, *_x, *_b, P, 100, iter); if(_gmres) gmm::gmres(*_a, *_x, *_b, P, 100, iter);
else gmm::cg(*_a, *_x, *_b, P, iter); else gmm::cg(*_a, *_x, *_b, P, iter);
#endif
return 1; return 1;
} }
}; };
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment