IBAMR  IBAMR version 0.19.
Public Types | Public Member Functions | Static Public Member Functions | Static Public Attributes | Protected Member Functions | Private Member Functions | Private Attributes | Static Private Attributes | List of all members
IBAMR::StaggeredStokesSolverManager Class Reference

Class StaggeredStokesSolverManager is a singleton manager class to provide access to generic staggered-grid Stokes solver implementations.

#include <ibamr/StaggeredStokesSolverManager.h>

Public Types

using SolverMaker = SAMRAI::tbox::Pointer< StaggeredStokesSolver >(*)(const std::string &solver_object_name, SAMRAI::tbox::Pointer< SAMRAI::tbox::Database > solver_input_db, const std::string &solver_default_options_prefix)
 

Public Member Functions

SAMRAI::tbox::Pointer< StaggeredStokesSolverallocateSolver (const std::string &solver_type, const std::string &solver_object_name, SAMRAI::tbox::Pointer< SAMRAI::tbox::Database > solver_input_db, const std::string &solver_default_options_prefix) const
 
SAMRAI::tbox::Pointer< StaggeredStokesSolverallocateSolver (const std::string &solver_type, const std::string &solver_object_name, SAMRAI::tbox::Pointer< SAMRAI::tbox::Database > solver_input_db, const std::string &solver_default_options_prefix, const std::string &precond_type, const std::string &precond_object_name, SAMRAI::tbox::Pointer< SAMRAI::tbox::Database > precond_input_db, const std::string &precond_default_options_prefix, const std::string &sub_precond_type="", const std::string &sub_precond_object_name="", SAMRAI::tbox::Pointer< SAMRAI::tbox::Database > sub_precond_input_db=SAMRAI::tbox::Pointer< SAMRAI::tbox::Database >(), const std::string &sub_precond_default_options_prefix="") const
 
void registerSolverFactoryFunction (const std::string &solver_type, SolverMaker solver_maker)
 

Static Public Member Functions

static StaggeredStokesSolverManagergetManager ()
 
static void freeManager ()
 

Static Public Attributes

static const std::string UNDEFINED
 
static const std::string DEFAULT_KRYLOV_SOLVER
 
static const std::string PETSC_KRYLOV_SOLVER
 
static const std::string DEFAULT_BLOCK_PRECONDITIONER
 
static const std::string BLOCK_FACTORIZATION_PRECONDITIONER
 
static const std::string PROJECTION_PRECONDITIONER
 
static const std::string DEFAULT_FAC_PRECONDITIONER
 
static const std::string BOX_RELAXATION_FAC_PRECONDITIONER
 
static const std::string LEVEL_RELAXATION_FAC_PRECONDITIONER
 
static const std::string DEFAULT_LEVEL_SOLVER
 
static const std::string PETSC_LEVEL_SOLVER
 

Protected Member Functions

 StaggeredStokesSolverManager ()
 Default constructor. More...
 
 ~StaggeredStokesSolverManager ()=default
 Destructor. More...
 

Private Member Functions

 StaggeredStokesSolverManager (const StaggeredStokesSolverManager &from)=delete
 Copy constructor. More...
 
StaggeredStokesSolverManageroperator= (const StaggeredStokesSolverManager &that)=delete
 Assignment operator. More...
 

Private Attributes

std::map< std::string, SolverMakerd_solver_maker_map
 

Static Private Attributes

static StaggeredStokesSolverManagers_solver_manager_instance
 
static bool s_registered_callback
 
static unsigned char s_shutdown_priority
 

Member Typedef Documentation

◆ SolverMaker

using IBAMR::StaggeredStokesSolverManager::SolverMaker = SAMRAI::tbox::Pointer<StaggeredStokesSolver> (*)(const std::string& solver_object_name, SAMRAI::tbox::Pointer<SAMRAI::tbox::Database> solver_input_db, const std::string& solver_default_options_prefix)

Typedef for functions to construct staggered-grid Stokes solvers.

Constructor & Destructor Documentation

◆ StaggeredStokesSolverManager() [1/2]

IBAMR::StaggeredStokesSolverManager::StaggeredStokesSolverManager ( )
protected

◆ ~StaggeredStokesSolverManager()

IBAMR::StaggeredStokesSolverManager::~StaggeredStokesSolverManager ( )
protecteddefault

◆ StaggeredStokesSolverManager() [2/2]

IBAMR::StaggeredStokesSolverManager::StaggeredStokesSolverManager ( const StaggeredStokesSolverManager from)
privatedelete
Note
This constructor is not implemented and should not be used.
Parameters
fromThe value to copy to this object.

Member Function Documentation

◆ getManager()

static StaggeredStokesSolverManager* IBAMR::StaggeredStokesSolverManager::getManager ( )
static

Return a pointer to the instance of the solver manager. Access to StaggeredStokesSolverManager objects is mediated by the getManager() function.

Returns
A pointer to the solver manager instance.

◆ freeManager()

static void IBAMR::StaggeredStokesSolverManager::freeManager ( )
static

Deallocate the StaggeredStokesSolverManager instance.

It is not necessary to call this function at program termination since it is automatically called by the ShutdownRegistry class.

◆ allocateSolver() [1/2]

SAMRAI::tbox::Pointer<StaggeredStokesSolver> IBAMR::StaggeredStokesSolverManager::allocateSolver ( const std::string &  solver_type,
const std::string &  solver_object_name,
SAMRAI::tbox::Pointer< SAMRAI::tbox::Database solver_input_db,
const std::string &  solver_default_options_prefix 
) const

Allocate a new StaggeredStokesSolver object of the specified type.

◆ allocateSolver() [2/2]

SAMRAI::tbox::Pointer<StaggeredStokesSolver> IBAMR::StaggeredStokesSolverManager::allocateSolver ( const std::string &  solver_type,
const std::string &  solver_object_name,
SAMRAI::tbox::Pointer< SAMRAI::tbox::Database solver_input_db,
const std::string &  solver_default_options_prefix,
const std::string &  precond_type,
const std::string &  precond_object_name,
SAMRAI::tbox::Pointer< SAMRAI::tbox::Database precond_input_db,
const std::string &  precond_default_options_prefix,
const std::string &  sub_precond_type = "",
const std::string &  sub_precond_object_name = "",
SAMRAI::tbox::Pointer< SAMRAI::tbox::Database sub_precond_input_db = SAMRAI::tbox::PointerSAMRAI::tbox::Database >(),
const std::string &  sub_precond_default_options_prefix = "" 
) const

Allocate a new StaggeredStokesSolver object of the specified type with a preconditioner of a specified type.

Note
The preconditioner settings are used only when the parent solver is a KrylovLinearSolver.

◆ registerSolverFactoryFunction()

void IBAMR::StaggeredStokesSolverManager::registerSolverFactoryFunction ( const std::string &  solver_type,
SolverMaker  solver_maker 
)

Register a solver factory function with the solver manager class.

◆ operator=()

StaggeredStokesSolverManager& IBAMR::StaggeredStokesSolverManager::operator= ( const StaggeredStokesSolverManager that)
privatedelete
Note
This operator is not implemented and should not be used.
Parameters
thatThe value to assign to this object.
Returns
A reference to this object.

Member Data Documentation

◆ UNDEFINED

const std::string IBAMR::StaggeredStokesSolverManager::UNDEFINED
static

Key to use for "undefined" solver types.

◆ DEFAULT_KRYLOV_SOLVER

const std::string IBAMR::StaggeredStokesSolverManager::DEFAULT_KRYLOV_SOLVER
static

Default Krylov solver types automatically provided by the manager class.

◆ PETSC_KRYLOV_SOLVER

const std::string IBAMR::StaggeredStokesSolverManager::PETSC_KRYLOV_SOLVER
static

◆ DEFAULT_BLOCK_PRECONDITIONER

const std::string IBAMR::StaggeredStokesSolverManager::DEFAULT_BLOCK_PRECONDITIONER
static

Default block preconditioner types automatically provided by the manager class.

◆ BLOCK_FACTORIZATION_PRECONDITIONER

const std::string IBAMR::StaggeredStokesSolverManager::BLOCK_FACTORIZATION_PRECONDITIONER
static

◆ PROJECTION_PRECONDITIONER

const std::string IBAMR::StaggeredStokesSolverManager::PROJECTION_PRECONDITIONER
static

◆ DEFAULT_FAC_PRECONDITIONER

const std::string IBAMR::StaggeredStokesSolverManager::DEFAULT_FAC_PRECONDITIONER
static

Default FAC preconditioner types automatically provided by the manager class.

◆ BOX_RELAXATION_FAC_PRECONDITIONER

const std::string IBAMR::StaggeredStokesSolverManager::BOX_RELAXATION_FAC_PRECONDITIONER
static

◆ LEVEL_RELAXATION_FAC_PRECONDITIONER

const std::string IBAMR::StaggeredStokesSolverManager::LEVEL_RELAXATION_FAC_PRECONDITIONER
static

◆ DEFAULT_LEVEL_SOLVER

const std::string IBAMR::StaggeredStokesSolverManager::DEFAULT_LEVEL_SOLVER
static

Default level solver types automatically provided by the manager class.

◆ PETSC_LEVEL_SOLVER

const std::string IBAMR::StaggeredStokesSolverManager::PETSC_LEVEL_SOLVER
static

◆ s_solver_manager_instance

StaggeredStokesSolverManager* IBAMR::StaggeredStokesSolverManager::s_solver_manager_instance
staticprivate

Static data members used to control access to and destruction of singleton data manager instance.

◆ s_registered_callback

bool IBAMR::StaggeredStokesSolverManager::s_registered_callback
staticprivate

◆ s_shutdown_priority

unsigned char IBAMR::StaggeredStokesSolverManager::s_shutdown_priority
staticprivate

◆ d_solver_maker_map

std::map<std::string, SolverMaker> IBAMR::StaggeredStokesSolverManager::d_solver_maker_map
private

Mapping from solver type names to solver maker functions.


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