19 #ifndef GEOS_LINEARALGEBRA_MULTISCALE_LEVELBUILDERBASE_HPP_
20 #define GEOS_LINEARALGEBRA_MULTISCALE_LEVELBUILDERBASE_HPP_
25 #include "linearAlgebra/common/PreconditionerBase.hpp"
27 #include "mesh/MeshLevel.hpp"
40 template<
typename LAI >
60 static std::unique_ptr< LevelBuilderBase< LAI > >
108 MPI_Comm
const & comm ) = 0;
116 Matrix const & fineMatrix ) = 0;
The DoFManager is responsible for allocating global dofs, constructing sparsity patterns,...
Partition of the decomposed physical domain. It also manages the connexion information to its neighbo...
Base class for level builder implementations.
typename LAI::ParallelVector Vector
Alias for vector type.
string m_name
Level name (label)
typename LAI::ParallelMatrix Matrix
Alias for matrix type.
virtual Operator const & restriction() const =0
virtual void initializeFineLevel(DomainPartition &domain, geos::DofManager const &dofManager, MPI_Comm const &comm)=0
Initialize the finest level (level 0).
LevelBuilderBase(string name, LinearSolverParameters params)
Constructor.
static std::unique_ptr< LevelBuilderBase< LAI > > create(string name, LinearSolverParameters params)
Factory interface to create level instances.
virtual void compute(Matrix const &fineMatrix)=0
Compute the current level.
virtual Matrix const & matrix() const =0
virtual std::unique_ptr< PreconditionerBase< LAI > > makeCoarseSolver() const =0
Instantiate coarsest level solver.
LinearSolverParameters m_params
Linear solver top-level parameters.
virtual Operator const * presmoother() const =0
virtual void initializeCoarseLevel(LevelBuilderBase< LAI > &fineLevel, Matrix const &fineMatrix)=0
Initialize a coarse level (levels 1 and above).
virtual Operator const * postsmoother() const =0
virtual ~LevelBuilderBase()=default
Destructor.
virtual Operator const & prolongation() const =0
LAInterface::ParallelMatrix ParallelMatrix
Alias for ParallelMatrix.
LAInterface::ParallelVector ParallelVector
Alias for ParallelVector.
Set of parameters for a linear solver or preconditioner.