2
/// This file is part of Rheolef.
4
/// Copyright (C) 2000-2009 Pierre Saramito <Pierre.Saramito@imag.fr>
6
/// Rheolef is free software; you can redistribute it and/or modify
7
/// it under the terms of the GNU General Public License as published by
8
/// the Free Software Foundation; either version 2 of the License, or
9
/// (at your option) any later version.
11
/// Rheolef is distributed in the hope that it will be useful,
12
/// but WITHOUT ANY WARRANTY; without even the implied warranty of
13
/// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14
/// GNU General Public License for more details.
16
/// You should have received a copy of the GNU General Public License
17
/// along with Rheolef; if not, write to the Free Software
18
/// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
20
/// =========================================================================
21
// direct solver interface
23
#include "rheolef/solver.h"
24
#include "solver_pastix.h"
28
template<class T, class M>
29
solver_rep<T,M>::solver_rep (const csr<T,M>& a, const solver_option_type& opt)
30
: _ptr(new_macro(rep(a,opt)))
33
template<class T, class M>
34
solver_rep<T,M>::~solver_rep ()
38
template<class T, class M>
40
solver_rep<T,M>::update_values (const csr<T,M>& a)
42
_ptr->update_values (a);
44
template<class T, class M>
46
solver_rep<T,M>::solve (const vec<T,M>& b)
48
return _ptr->solve (b);
50
template<class T, class M>
52
solver_rep<T,M>::trans_solve (const vec<T,M>& b)
54
return _ptr->trans_solve (b);
56
// ----------------------------------------------------------------------------
57
// instanciation in library
58
// ----------------------------------------------------------------------------
59
template class solver_rep<Float,sequential>;
61
#ifdef _RHEOLEF_HAVE_MPI
62
template class solver_rep<Float,distributed>;
63
#endif // _RHEOLEF_HAVE_MPI
65
} // namespace rheolef