47 #ifdef HAVE_STOKHOS_ML
48 #include "ml_include.h"
49 #include "ml_MultiLevelPreconditioner.h"
56 #ifdef HAVE_STOKHOS_ML
60 ML_Epetra::SetDefaults(
precParams->
get<std::string>(
"default values"),
70 #ifdef HAVE_STOKHOS_ML
74 Teuchos::rcp(
new ML_Epetra::MultiLevelPreconditioner(*mat, *precParams,
80 "Stokhos::MLPreconditionerFactory is available " <<
81 "only with configured with ML support!");
83 #endif // HAVE_STOKHOS_ML
90 #ifdef HAVE_STOKHOS_ML
95 Teuchos::rcp_dynamic_cast<ML_Epetra::MultiLevelPreconditioner>(prec_op);
101 non_const_prec_crs_mat = *mat;
104 ml_prec->ComputePreconditioner();
107 "Stokhos::MLPreconditionerFactory is available " <<
108 "only with configured with ML support!");
109 #endif // HAVE_STOKHOS_ML
virtual Teuchos::RCP< Epetra_Operator > compute(const Teuchos::RCP< Epetra_Operator > &op, bool compute_prec=true)
Compute preconditioner.
MLPreconditionerFactory(const Teuchos::RCP< Teuchos::ParameterList > &p)
Constructor.
Teuchos::RCP< Teuchos::ParameterList > precParams
Preconditioner parameters.
T & get(ParameterList &l, const std::string &name)
#define TEUCHOS_TEST_FOR_EXCEPTION(throw_exception_test, Exception, msg)
TEUCHOS_DEPRECATED RCP< T > rcp(T *p, Dealloc_T dealloc, bool owns_mem)
virtual void recompute(const Teuchos::RCP< Epetra_Operator > &op, const Teuchos::RCP< Epetra_Operator > &prec)
Recompute preconditioner operator for a new matrix.
ParameterList & setParametersNotAlreadySet(const ParameterList &source)
bool isType(const std::string &name) const