52 #ifndef AMESOS2_MUMPS_DECL_HPP
53 #define AMESOS2_MUMPS_DECL_HPP
56 #include "Amesos2_SolverCore.hpp"
83 template <
class Matrix,
class Vector>
98 typedef typename super_type::scalar_type scalar_type;
99 typedef typename super_type::local_ordinal_type local_ordinal_type;
100 typedef typename super_type::global_ordinal_type global_ordinal_type;
101 typedef typename super_type::global_size_type global_size_type;
105 typedef typename type_map::type slu_type;
106 typedef typename type_map::magnitude_type magnitude_type;
107 typedef typename type_map::MUMPS_STRUC_C MUMPS_STRUC_C;
111 MUMPS(Teuchos::RCP<const Matrix> A,
112 Teuchos::RCP<Vector> X,
113 Teuchos::RCP<const Vector> B);
127 int symbolicFactorization_impl();
149 int
solve_impl(const Teuchos::Ptr<MultiVecAdapter<Vector> > X,
150 const Teuchos::Ptr<const MultiVecAdapter<Vector> > B) const;
174 const Teuchos::RCP<Teuchos::ParameterList> & parameterList );
197 int ConvertToTriplet();
199 void MUMPS_ERROR() const;
206 bool MUMPS_MATRIX_LOAD;
218 mutable Teuchos::Array<slu_type>
xvals_; local_ordinal_type ldx_;
220 mutable Teuchos::Array<slu_type>
bvals_; local_ordinal_type ldb_;
222 mutable MUMPS_STRUC_C mumps_par;
229 template <class Matrix,class Vector>
230 class MUMPSNS :
public SolverCore<Amesos2::MUMPS, Matrix, Vector>
238 MUMPSNS(Teuchos::RCP<const Matrix> A,
239 Teuchos::RCP<Vector> X,
240 Teuchos::RCP<const Vector> B);
258 TEUCHOS_TEST_FOR_EXCEPTION(
true, std::logic_error,
259 "This solver is not support for these types.");
263 int symbolicFactorization_impl()
266 TEUCHOS_TEST_FOR_EXCEPTION(
true, std::logic_error,
267 "This solver is not support for these types.");
274 TEUCHOS_TEST_FOR_EXCEPTION(
true, std::logic_error,
275 "This solver is not support for these types.");
283 TEUCHOS_TEST_FOR_EXCEPTION(
true, std::logic_error,
284 "This solver is not support for these types.");
291 TEUCHOS_TEST_FOR_EXCEPTION(
true, std::logic_error,
292 "This solver is not support for these types.");
297 const Teuchos::RCP<Teuchos::ParameterList> & parameterList )
300 TEUCHOS_TEST_FOR_EXCEPTION(
true, std::logic_error,
301 "This solver is not support for these types.");
308 TEUCHOS_TEST_FOR_EXCEPTION(
true, std::logic_error,
309 "This solver is not support for these types.");
317 TEUCHOS_TEST_FOR_EXCEPTION(
true, std::logic_error,
318 "This solver is not support for these types.");
323 int ConvertToTriplet()
326 TEUCHOS_TEST_FOR_EXCEPTION(
true, std::logic_error,
327 "This solver is not support for these types.");
332 void MUMPS_ERROR()
const
335 TEUCHOS_TEST_FOR_EXCEPTION(
true, std::logic_error,
336 "This solver is not support for these types.");
355 #ifdef HAVE_TEUCHOS_COMPLEX
356 typedef Meta::make_list4<float,
359 std::complex<double> > supported_scalars;
361 typedef Meta::make_list2<float, double> supported_scalars;
367 #endif // AMESOS2_MUMPS_DECL_HPP