https://mooseframework.inl.gov
Public Member Functions | Static Public Member Functions | Protected Types | Protected Member Functions | Protected Attributes | Static Protected Attributes | List of all members
LumpedPreconditioner Class Referenceabstract

Class to that applies the lumped mass matrix preconditioner in the ExplicitTimeIntegrator. More...

#include <LumpedPreconditioner.h>

Inheritance diagram for LumpedPreconditioner:
[legend]

Public Member Functions

 LumpedPreconditioner (const NumericVector< Real > &diag_inverse)
 
virtual void init () override
 
virtual void apply (const NumericVector< Real > &x, NumericVector< Real > &y) override
 
virtual bool initialized () const
 
virtual void apply (const NumericVector< Real > &x, NumericVector< Real > &y)=0
 
virtual void clear ()
 
virtual void setup ()
 
virtual void zero ()
 
void set_matrix (SparseMatrix< Number > &mat)
 
PreconditionerType type () const
 
void set_type (const PreconditionerType pct)
 
const Parallel::Communicatorcomm () const
 
processor_id_type n_processors () const
 
processor_id_type processor_id () const
 

Static Public Member Functions

static std::unique_ptr< Preconditioner< Real > > build_preconditioner (const libMesh::Parallel::Communicator &comm, const SolverPackage solver_package=libMesh::default_solver_package())
 
static std::string get_info ()
 
static void print_info (std::ostream &out_stream=libMesh::out)
 
static unsigned int n_objects ()
 
static void enable_print_counter_info ()
 
static void disable_print_counter_info ()
 

Protected Types

typedef std::map< std::string, std::pair< unsigned int, unsigned int > > Counts
 

Protected Member Functions

void increment_constructor_count (const std::string &name) noexcept
 
void increment_destructor_count (const std::string &name) noexcept
 

Protected Attributes

const NumericVector< Real > & _diag_inverse
 The inverse of the diagonal of the lumped matrix. More...
 
SparseMatrix< Real > * _matrix
 
PreconditionerType _preconditioner_type
 
bool _is_initialized
 
const Parallel::Communicator_communicator
 

Static Protected Attributes

static Counts _counts
 
static Threads::atomic< unsigned int_n_objects
 
static Threads::spin_mutex _mutex
 
static bool _enable_print_counter
 

Detailed Description

Class to that applies the lumped mass matrix preconditioner in the ExplicitTimeIntegrator.

Definition at line 29 of file LumpedPreconditioner.h.

Constructor & Destructor Documentation

◆ LumpedPreconditioner()

LumpedPreconditioner::LumpedPreconditioner ( const NumericVector< Real > &  diag_inverse)
inline

Definition at line 32 of file LumpedPreconditioner.h.

33  : Preconditioner(diag_inverse.comm()), _diag_inverse(diag_inverse)
34  {
35  }
Preconditioner(const libMesh::Parallel::Communicator &comm)
const NumericVector< Real > & _diag_inverse
The inverse of the diagonal of the lumped matrix.

Member Function Documentation

◆ apply()

virtual void LumpedPreconditioner::apply ( const NumericVector< Real > &  x,
NumericVector< Real > &  y 
)
inlineoverridevirtual

Definition at line 43 of file LumpedPreconditioner.h.

44  {
45  y.pointwise_mult(_diag_inverse, x);
46  }
const NumericVector< Real > & _diag_inverse
The inverse of the diagonal of the lumped matrix.

◆ init()

virtual void LumpedPreconditioner::init ( )
inlineoverridevirtual

Reimplemented from libMesh::Preconditioner< Real >.

Definition at line 37 of file LumpedPreconditioner.h.

38  {
39  // No more initialization needed here
40  _is_initialized = true;
41  }

Member Data Documentation

◆ _diag_inverse

const NumericVector<Real>& LumpedPreconditioner::_diag_inverse
protected

The inverse of the diagonal of the lumped matrix.

Definition at line 50 of file LumpedPreconditioner.h.

Referenced by apply().


The documentation for this class was generated from the following file: