16 #ifndef dealii_trilinos_solver_h 17 #define dealii_trilinos_solver_h 20 #include <deal.II/base/config.h> 22 #ifdef DEAL_II_WITH_TRILINOS 24 # include <deal.II/lac/exceptions.h> 25 # include <deal.II/lac/solver_control.h> 26 # include <deal.II/lac/vector.h> 27 # include <deal.II/lac/la_parallel_vector.h> 31 # include <Epetra_LinearProblem.h> 33 # include <Epetra_Operator.h> 37 DEAL_II_NAMESPACE_OPEN
43 class PreconditionBase;
168 solve (
const Epetra_Operator &A,
183 solve (
const Epetra_Operator &A,
186 const Epetra_Operator &preconditioner);
198 solve (
const Epetra_Operator &A,
199 Epetra_MultiVector &x,
200 const Epetra_MultiVector &b,
214 solve (
const Epetra_Operator &A,
215 Epetra_MultiVector &x,
216 const Epetra_MultiVector &b,
217 const Epetra_Operator &preconditioner);
234 const ::Vector<double> &b,
249 solve (Epetra_Operator &A,
251 const ::Vector<double> &b,
263 const ::LinearAlgebra::distributed::Vector<double> &b,
274 solve (Epetra_Operator &A,
276 const ::LinearAlgebra::distributed::Vector<double> &b,
290 <<
"An error with error number " << arg1
291 <<
" occurred while calling a Trilinos function");
309 template <
typename Preconditioner>
310 void do_solve(
const Preconditioner &preconditioner);
315 template <
typename Preconditioner>
317 const Preconditioner &preconditioner);
354 const Epetra_Operator &preconditioner);
459 const unsigned int restart_parameter = 30);
653 const ::LinearAlgebra::distributed::Vector<double> &b);
676 const ::Vector<double> &b);
687 const ::LinearAlgebra::distributed::Vector<double> &b);
699 <<
"An error with error number " << arg1
700 <<
" occurred while calling a Trilinos function");
728 std::unique_ptr<Amesos_BaseSolver>
solver;
738 DEAL_II_NAMESPACE_CLOSE
740 #endif // DEAL_II_WITH_TRILINOS void set_preconditioner(AztecOO &solver, const Preconditioner &preconditioner)
SolverCG(SolverControl &cn, const AdditionalData &data=AdditionalData())
virtual ~SolverDirect()=default
const bool output_solver_details
std::unique_ptr< Amesos_BaseSolver > solver
const AdditionalData additional_data
std::unique_ptr< AztecOO_StatusTest > status_test
const AdditionalData additional_data
AdditionalData(const bool output_solver_details=false, const unsigned int restart_parameter=30)
const AdditionalData additional_data
void initialize(const SparseMatrix &A)
static ::ExceptionBase & ExcTrilinosError(int arg1)
void solve(MPI::Vector &x, const MPI::Vector &b)
const AdditionalData additional_data
void do_solve(const Preconditioner &preconditioner)
virtual ~SolverBase()=default
SolverControl & solver_control
#define DeclException1(Exception1, type1, outsequence)
SolverCGS(SolverControl &cn, const AdditionalData &data=AdditionalData())
AdditionalData(const bool output_solver_details=false)
SolverBicgstab(SolverControl &cn, const AdditionalData &data=AdditionalData())
SolverControl & solver_control
std::unique_ptr< Epetra_LinearProblem > linear_problem
SolverControl & control() const
void solve(const SparseMatrix &A, MPI::Vector &x, const MPI::Vector &b, const PreconditionBase &preconditioner)
std::unique_ptr< Epetra_LinearProblem > linear_problem
SolverTFQMR(SolverControl &cn, const AdditionalData &data=AdditionalData())
AdditionalData(const bool output_solver_details=false)
SolverBase(SolverControl &cn, const AdditionalData &data=AdditionalData())
const AdditionalData additional_data
AdditionalData(const bool output_solver_details=false, const std::string &solver_type="Amesos_Klu")
SolverDirect(SolverControl &cn, const AdditionalData &data=AdditionalData())
const AdditionalData additional_data
bool output_solver_details
AdditionalData(const bool output_solver_details=false)
SolverControl & control() const
AdditionalData(const bool output_solver_details=false, const unsigned int gmres_restart_parameter=30)
SolverGMRES(SolverControl &cn, const AdditionalData &data=AdditionalData())
const AdditionalData additional_data
static ::ExceptionBase & ExcTrilinosError(int arg1)
AdditionalData(const bool output_solver_details=false)
const unsigned int gmres_restart_parameter