NeoPZ
|
Defines a abstract class of solvers which will be used by matrix classes. Solver. More...
#include <pzmatrix.h>
Public Member Functions | |
int | ClassId () const override |
Define the class id associated with the class. More... | |
virtual void | Solve (const TPZFMatrix< TVar > &F, TPZFMatrix< TVar > &result, TPZFMatrix< TVar > *residual=0)=0 |
Solves the system of linear equations. More... | |
virtual void | Decompose () |
Decompose the system of equations if a direct solver is used. More... | |
virtual TPZSolver * | Clone () const =0 |
Clones the current object returning a pointer of type TPZSolver. More... | |
virtual | ~TPZSolver () |
Destructor. More... | |
virtual void | ResetMatrix () |
This method will reset the matrix associated with the solver. More... | |
virtual void | UpdateFrom (TPZAutoPointer< TPZMatrix< TVar > > matrix) |
Updates the values of the current matrix based on the values of the matrix. More... | |
Public Member Functions inherited from TPZSavable | |
TPZSavable () | |
virtual | ~TPZSavable () |
virtual std::list< std::map< std::string, uint64_t > > | VersionHistory () const |
virtual std::pair< std::string, uint64_t > | Version () const |
virtual void | Write (TPZStream &buf, int withclassid) const |
Writes this object to the TPZStream buffer. Include the classid if withclassid = true. More... | |
virtual void | Read (TPZStream &buf, void *context) |
read objects from the stream More... | |
virtual bool | Compare (TPZSavable *copy, bool override=false) |
Compares the object for identity with the object pointed to, eventually copy the object. More... | |
virtual bool | Compare (TPZSavable *copy, bool override=false) const |
Compares the object for identity with the object pointed to, eventually copy the object. More... | |
Public Member Functions inherited from TPZRegisterClassId | |
template<typename T > | |
TPZRegisterClassId (int(T::*)() const) | |
TPZRegisterClassId ()=default | |
Additional Inherited Members | |
Static Public Member Functions inherited from TPZSavable | |
static std::set< TPZRestoreClassBase * > & | RestoreClassSet () |
This static function guarantees that the gMap object is available when needed. More... | |
static std::map< int, TPZRestore_t > & | ClassIdMap () |
This static function guarantees that the gMap object is available when needed. More... | |
static std::pair< std::string, uint64_t > | NeoPZVersion () |
static void | Register (TPZRestoreClassBase *restore) |
static void | RegisterClassId (int classid, TPZRestore_t fun) |
static TPZSavable * | CreateInstance (const int &classId) |
Defines a abstract class of solvers which will be used by matrix classes. Solver.
Definition at line 32 of file pzmatrix.h.
Destructor.
Destructor
Definition at line 19 of file pzsolve.cpp.
Referenced by TPZSolver< STATE >::Decompose().
|
overridevirtual |
Define the class id associated with the class.
This id has to be unique for all classes A non unique id is flagged at the startup of the program
Implements TPZSavable.
Reimplemented in TPZMatrixSolver< TVar >, TPZStepSolver< TVar >, and TPZMGSolver< TVar >.
Definition at line 61 of file pzsolve.h.
Referenced by TPZMatrixSolver< STATE >::ClassId().
Clones the current object returning a pointer of type TPZSolver.
Implemented in TPZSequenceSolver< TVar >, TPZMGSolver< TVar >, TPZStepSolver< TVar >, and TPZCopySolve< TVar >.
Referenced by TPZSequenceSolver< TVar >::AppendSolver(), TPZSubMeshAnalysis::Assemble(), TPZSolver< STATE >::Decompose(), TPZStepSolver< TVar >::SetBiCGStab(), TPZStepSolver< TVar >::SetCG(), TPZStepSolver< TVar >::SetGMRES(), TPZElastoPlasticAnalysis::SetPrecond(), TPZStepSolver< TVar >::SetPreconditioner(), TPZAnalysis::SetSolver(), TPZMGAnalysis::Solve(), and TPZMGSolver< TVar >::TPZMGSolver().
|
inlinevirtual |
Decompose the system of equations if a direct solver is used.
Reimplemented in TPZStepSolver< TVar >.
|
inlinevirtual |
This method will reset the matrix associated with the solver.
This is useful when the matrix needs to be recomputed in a non linear problem
Reimplemented in TPZMatrixSolver< TVar >, TPZMatrixSolver< REAL >, TPZMatrixSolver< TTVar >, TPZMatrixSolver< STATE >, TPZStepSolver< TVar >, and TPZSequenceSolver< TVar >.
Definition at line 48 of file pzsolve.h.
Referenced by TPZMatrixSolver< STATE >::UpdateFrom().
|
pure virtual |
Solves the system of linear equations.
F | contains Force vector |
result | contains the solution |
residual | contains the residual for that linear system |
Implemented in TPZStepSolver< TVar >, TPZMGSolver< TVar >, TPZCopySolve< TVar >, and TPZSequenceSolver< TVar >.
Referenced by TPZAnalysis::AnimateRun(), TPZMGAnalysis::Solve(), TPZEulerAnalysis::Solve(), and TPZAnalysis::Solve().
|
inlinevirtual |
Updates the values of the current matrix based on the values of the matrix.
Reimplemented in TPZMatrixSolver< TVar >, TPZMatrixSolver< REAL >, TPZMatrixSolver< TTVar >, TPZMatrixSolver< STATE >, TPZStepSolver< TVar >, and TPZSequenceSolver< TVar >.