![]() |
MFEM v4.9.0
Finite element discretization library
|
Abstract base class for an iterative solver controller. More...
#include <solvers.hpp>
Public Member Functions | |
| IterativeSolverController () | |
| virtual | ~IterativeSolverController () |
| bool | HasConverged () |
| virtual void | Reset () |
| virtual void | MonitorResidual (int it, real_t norm, const Vector &r, bool final) |
| Monitor the solution vector r. | |
| virtual void | MonitorSolution (int it, real_t norm, const Vector &x, bool final) |
| Monitor the solution vector x. | |
| virtual bool | RequiresUpdatedSolution () const |
| Indicates if the controller requires an updated solution every iteration. | |
| void | SetIterativeSolver (const IterativeSolver &solver) |
| This method is invoked by IterativeSolver::SetController(), informing the controller which IterativeSolver is using it. | |
Protected Attributes | |
| const class IterativeSolver * | iter_solver |
| The last IterativeSolver to which this controller was attached. | |
| bool | converged = false |
Abstract base class for an iterative solver controller.
Definition at line 36 of file solvers.hpp.
|
inline |
Definition at line 47 of file solvers.hpp.
|
inlinevirtual |
Definition at line 49 of file solvers.hpp.
|
inline |
Has the solver converged?
Can be used if convergence is detected in the controller (before reaching the relative or absolute tolerance of the IterativeSolver).
Definition at line 55 of file solvers.hpp.
|
inlinevirtual |
Monitor the solution vector r.
Reimplemented in mfem::ResidualBCMonitor.
Definition at line 64 of file solvers.hpp.
|
inlinevirtual |
Monitor the solution vector x.
Definition at line 70 of file solvers.hpp.
|
inlinevirtual |
Indicates if the controller requires an updated solution every iteration.
The default behavior is to not require the updated solution to allow solvers to skip it if not needed otherwise.
Definition at line 78 of file solvers.hpp.
|
inlinevirtual |
Reset the controller to its initial state.
This function is called by the IterativeSolver::Mult() method on the first iteration.
Definition at line 61 of file solvers.hpp.
|
inline |
This method is invoked by IterativeSolver::SetController(), informing the controller which IterativeSolver is using it.
Definition at line 82 of file solvers.hpp.
|
protected |
In MonitorResidual or MonitorSolution, this member variable can be set to true to indicate early convergence.
Definition at line 44 of file solvers.hpp.
|
protected |
The last IterativeSolver to which this controller was attached.
Definition at line 40 of file solvers.hpp.