An interface to allow Mumps to be used as an (exact) Preconditioner. More...
#include <mumps_solver.h>
Public Member Functions | |
MumpsPreconditioner () | |
Constructor. | |
~MumpsPreconditioner () | |
Destructor. | |
MumpsPreconditioner (const MumpsPreconditioner &)=delete | |
Broken copy constructor. | |
void | operator= (const MumpsPreconditioner &)=delete |
Broken assignment operator. | |
void | setup () |
Function to set up a preconditioner for the linear system defined by matrix_pt. This function must be called before using preconditioner_solve. Note: matrix_pt must point to an object of class CRDoubleMatrix or CCDoubleMatrix. | |
void | preconditioner_solve (const DoubleVector &r, DoubleVector &z) |
Function applies Mumps to vector r for (exact) preconditioning, this requires a call to setup(...) first. | |
void | clean_up_memory () |
Clean up memory – forward the call to the version in Mumps in its LinearSolver incarnation. | |
void | enable_doc_time () |
Enable documentation of timings. | |
void | disable_doc_time () |
Disable the documentation of timings. | |
![]() | |
Preconditioner () | |
Constructor. | |
Preconditioner (const Preconditioner &)=delete | |
Broken copy constructor. | |
void | operator= (const Preconditioner &)=delete |
Broken assignment operator. | |
virtual | ~Preconditioner () |
Destructor (empty) | |
virtual void | preconditioner_solve_transpose (const DoubleVector &r, DoubleVector &z) |
Apply the preconditioner. Pure virtual generic interface function. This method should apply the preconditioner operator to the vector r and return the vector z. (broken virtual) | |
virtual void | setup (DoubleMatrixBase *matrix_pt) |
Setup the preconditioner: store the matrix pointer and the communicator pointer then call preconditioner specific setup() function. | |
void | setup (const Problem *problem_pt, DoubleMatrixBase *matrix_pt) |
Compatability layer for old preconditioners where problem pointers were needed. The problem pointer is only used to get a communicator pointer. | |
void | enable_silent_preconditioner_setup () |
Set up the block preconditioner quietly! | |
void | disable_silent_preconditioner_setup () |
Be verbose in the block preconditioner setup. | |
virtual DoubleMatrixBase * | matrix_pt () const |
Get function for matrix pointer. | |
virtual void | set_matrix_pt (DoubleMatrixBase *matrix_pt) |
Set the matrix pointer. | |
virtual const OomphCommunicator * | comm_pt () const |
Get function for comm pointer. | |
virtual void | set_comm_pt (const OomphCommunicator *const comm_pt) |
Set the communicator pointer. | |
double | setup_time () const |
Returns the time to setup the preconditioner. | |
virtual void | turn_into_subsidiary_block_preconditioner (BlockPreconditioner< CRDoubleMatrix > *master_block_prec_pt, const Vector< unsigned > &doftype_in_master_preconditioner_coarse) |
Virtual interface function for making a preconditioner a subsidiary of a block preconditioner. By default nothing is needed, but if this preconditioner is also a block preconditioner then things need to happen. There's an assumption here that the block preconditioner will be in CR form but since that assumption is hard coded all over BlockPreconditioner we're safe. | |
virtual void | turn_into_subsidiary_block_preconditioner (BlockPreconditioner< CRDoubleMatrix > *master_block_prec_pt, const Vector< unsigned > &doftype_in_master_preconditioner_coarse, const Vector< Vector< unsigned > > &doftype_coarsen_map_coarse) |
Virtual interface function for making a preconditioner a subsidiary of a block preconditioner. By default nothing is needed, but if this preconditioner is also a block preconditioner then things need to happen. Version for coarsening dof-types. | |
![]() | |
DistributableLinearAlgebraObject () | |
Default constructor - create a distribution. | |
DistributableLinearAlgebraObject (const DistributableLinearAlgebraObject &matrix)=delete | |
Broken copy constructor. | |
void | operator= (const DistributableLinearAlgebraObject &)=delete |
Broken assignment operator. | |
virtual | ~DistributableLinearAlgebraObject () |
Destructor. | |
LinearAlgebraDistribution * | distribution_pt () const |
access to the LinearAlgebraDistribution | |
unsigned | nrow () const |
access function to the number of global rows. | |
unsigned | nrow_local () const |
access function for the num of local rows on this processor. | |
unsigned | nrow_local (const unsigned &p) const |
access function for the num of local rows on this processor. | |
unsigned | first_row () const |
access function for the first row on this processor | |
unsigned | first_row (const unsigned &p) const |
access function for the first row on this processor | |
bool | distributed () const |
distribution is serial or distributed | |
bool | distribution_built () const |
if the communicator_pt is null then the distribution is not setup then false is returned, otherwise return true | |
void | build_distribution (const LinearAlgebraDistribution *const dist_pt) |
setup the distribution of this distributable linear algebra object | |
void | build_distribution (const LinearAlgebraDistribution &dist) |
setup the distribution of this distributable linear algebra object | |
Private Attributes | |
MumpsSolver | Solver |
the Mumps solver emplyed by this preconditioner | |
Additional Inherited Members | |
![]() | |
void | clear_distribution () |
clear the distribution of this distributable linear algebra object | |
![]() | |
bool | Silent_preconditioner_setup |
Boolean to indicate whether or not the build should be done silently. | |
std::ostream * | Stream_pt |
Pointer to the output stream – defaults to std::cout. | |
An interface to allow Mumps to be used as an (exact) Preconditioner.
Definition at line 358 of file mumps_solver.h.
|
inline |
Constructor.
Definition at line 362 of file mumps_solver.h.
References oomph::MumpsSolver::disable_doc_stats(), oomph::LinearSolver::disable_doc_time(), and Solver.
|
inline |
Destructor.
Definition at line 369 of file mumps_solver.h.
|
delete |
Broken copy constructor.
|
inlinevirtual |
Clean up memory – forward the call to the version in Mumps in its LinearSolver incarnation.
Reimplemented from oomph::Preconditioner.
Definition at line 416 of file mumps_solver.h.
References oomph::MumpsSolver::clean_up_memory(), and Solver.
|
inline |
Disable the documentation of timings.
Definition at line 429 of file mumps_solver.h.
References oomph::LinearSolver::disable_doc_time(), and Solver.
|
inline |
Enable documentation of timings.
Definition at line 423 of file mumps_solver.h.
References oomph::LinearSolver::enable_doc_time(), and Solver.
|
delete |
Broken assignment operator.
|
inlinevirtual |
Function applies Mumps to vector r for (exact) preconditioning, this requires a call to setup(...) first.
Implements oomph::Preconditioner.
Definition at line 408 of file mumps_solver.h.
References oomph::MumpsSolver::resolve(), and Solver.
|
inlinevirtual |
Function to set up a preconditioner for the linear system defined by matrix_pt. This function must be called before using preconditioner_solve. Note: matrix_pt must point to an object of class CRDoubleMatrix or CCDoubleMatrix.
Implements oomph::Preconditioner.
Definition at line 382 of file mumps_solver.h.
References oomph::DistributableLinearAlgebraObject::build_distribution(), oomph::MumpsSolver::factorise(), oomph::Preconditioner::matrix_pt(), oomph::oomph_info, and Solver.
|
private |
the Mumps solver emplyed by this preconditioner
Definition at line 436 of file mumps_solver.h.
Referenced by clean_up_memory(), disable_doc_time(), enable_doc_time(), MumpsPreconditioner(), preconditioner_solve(), and setup().