GEOSX
|
This class creates and provides basic support for PETSc solvers. More...
#include <PetscSolver.hpp>
Public Member Functions | |
PetscSolver (LinearSolverParameters parameters) | |
Solver constructor, with parameter list reference. More... | |
virtual | ~PetscSolver ()=default |
Virtual destructor. | |
void | solve (PetscMatrix &mat, PetscVector &sol, PetscVector &rhs, DofManager const *const dofManager=nullptr) |
Solve system with an iterative solver. More... | |
LinearSolverResult const & | result () |
Get the result of previous solve. More... | |
This class creates and provides basic support for PETSc solvers.
Definition at line 35 of file PetscSolver.hpp.
geosx::PetscSolver::PetscSolver | ( | LinearSolverParameters | parameters | ) |
Solver constructor, with parameter list reference.
[in] | parameters | structure containing linear solver parameters |
|
inline |
Get the result of previous solve.
Definition at line 69 of file PetscSolver.hpp.
void geosx::PetscSolver::solve | ( | PetscMatrix & | mat, |
PetscVector & | sol, | ||
PetscVector & | rhs, | ||
DofManager const *const | dofManager = nullptr |
||
) |
Solve system with an iterative solver.
[in,out] | mat | the matrix |
[in,out] | sol | the solution |
[in,out] | rhs | the right-hand side |
dofManager | the Degree-of-Freedom manager associated with matrix |
Solve Ax=b with A an PetscMatrix, x and b PetscVector.