53 if (prec_name ==
"Ifpack")
56 else if (prec_name ==
"ML")
61 "Error! Unknown preconditioner type " << prec_name
62 <<
". Valid choices are \"Ifpack\" and \"ML\".");
69 return factory->compute(mat, compute_prec);
77 factory->recompute(mat, prec);
#define TEUCHOS_TEST_FOR_EXCEPTION(throw_exception_test, Exception, msg)
A factory for building ML preconditioners.
virtual Teuchos::RCP< Epetra_Operator > compute(const Teuchos::RCP< Epetra_Operator > &mat, bool compute_prec=true)
Compute preconditioner operator.
TEUCHOS_DEPRECATED RCP< T > rcp(T *p, Dealloc_T dealloc, bool owns_mem)
virtual void recompute(const Teuchos::RCP< Epetra_Operator > &mat, const Teuchos::RCP< Epetra_Operator > &prec)
Recompute preconditioner operator for a new matrix.
A factory for building Ifpack preconditioners.
PreconditionerFactory(const std::string &prec_name, const Teuchos::RCP< Teuchos::ParameterList > ¶ms)
Constructor.
Teuchos::RCP< Stokhos::AbstractPreconditionerFactory > factory
Preconditioner factory.