MFEM v2.0
|
PCG solver in hypre. More...
#include <hypre.hpp>
Public Member Functions | |
HyprePCG (HypreParMatrix &_A) | |
void | SetTol (double tol) |
void | SetMaxIter (int max_iter) |
void | SetLogging (int logging) |
void | SetPrintLevel (int print_lvl) |
void | SetPreconditioner (HypreSolver &precond) |
Set the hypre solver to be used as a preconditioner. | |
void | SetResidualConvergenceOptions (int res_frequency=-1, double rtol=0.0) |
void | SetZeroInintialIterate () |
non-hypre setting | |
void | GetNumIterations (int &num_iterations) |
virtual | operator HYPRE_Solver () const |
The typecast to HYPRE_Solver returns the internal pcg_solver. | |
virtual HYPRE_PtrToParSolverFcn | SetupFcn () const |
PCG Setup function. | |
virtual HYPRE_PtrToParSolverFcn | SolveFcn () const |
PCG Solve function. | |
virtual void | Mult (const HypreParVector &b, HypreParVector &x) const |
Solve Ax=b with hypre's PCG. | |
virtual | ~HyprePCG () |
Private Attributes | |
int | print_level |
int | use_zero_initial_iterate |
HYPRE_Solver | pcg_solver |
HyprePCG::HyprePCG | ( | HypreParMatrix & | _A | ) |
virtual HyprePCG::~HyprePCG | ( | ) | [virtual] |
void HyprePCG::GetNumIterations | ( | int & | num_iterations | ) | [inline] |
Definition at line 259 of file hypre.hpp.
References pcg_solver.
virtual void HyprePCG::Mult | ( | const HypreParVector & | b, |
HypreParVector & | x | ||
) | const [virtual] |
virtual HyprePCG::operator HYPRE_Solver | ( | ) | const [inline, virtual] |
The typecast to HYPRE_Solver returns the internal pcg_solver.
Implements HypreSolver.
Definition at line 263 of file hypre.hpp.
References pcg_solver.
void HyprePCG::SetLogging | ( | int | logging | ) |
void HyprePCG::SetMaxIter | ( | int | max_iter | ) |
Referenced by main().
void HyprePCG::SetPreconditioner | ( | HypreSolver & | precond | ) |
Set the hypre solver to be used as a preconditioner.
Referenced by main().
void HyprePCG::SetPrintLevel | ( | int | print_lvl | ) |
Referenced by main().
void HyprePCG::SetResidualConvergenceOptions | ( | int | res_frequency = -1 , |
double | rtol = 0.0 |
||
) |
Use the L2 norm of the residual for measuring PCG convergence, plus (optionally) 1) periodically recompute true residuals from scratch; and 2) enable residual-based stopping criteria.
void HyprePCG::SetTol | ( | double | tol | ) |
Referenced by main().
virtual HYPRE_PtrToParSolverFcn HyprePCG::SetupFcn | ( | ) | const [inline, virtual] |
void HyprePCG::SetZeroInintialIterate | ( | ) | [inline] |
virtual HYPRE_PtrToParSolverFcn HyprePCG::SolveFcn | ( | ) | const [inline, virtual] |
HYPRE_Solver HyprePCG::pcg_solver [private] |
Definition at line 238 of file hypre.hpp.
Referenced by GetNumIterations(), and operator HYPRE_Solver().
int HyprePCG::print_level [private] |
int HyprePCG::use_zero_initial_iterate [private] |
Definition at line 237 of file hypre.hpp.
Referenced by SetZeroInintialIterate().