IBAMR
An adaptive and distributed-memory parallel implementation of the immersed boundary (IB) method
Public Member Functions | List of all members
IBAMR::CIBMobilitySolver Class Reference

Class CIBMobilitySolver solves for the constraint forces $ \vec{\lambda}$ and rigid body velocity $ \vec{U}$ of the structure(s). Specifically, the class solves two types of matrix-equations. More...

#include </home/runner/work/IBAMR/IBAMR/include/ibamr/CIBMobilitySolver.h>

Inheritance diagram for IBAMR::CIBMobilitySolver:
Inheritance graph
[legend]

Public Member Functions

 CIBMobilitySolver (std::string object_name, SAMRAI::tbox::Pointer< SAMRAI::tbox::Database > input_db, SAMRAI::tbox::Pointer< IBAMR::INSStaggeredHierarchyIntegrator > navier_stokes_integrator, SAMRAI::tbox::Pointer< IBAMR::CIBStrategy > cib_strategy)
 The only constructor of this class.
 
virtual ~CIBMobilitySolver ()
 Destructor for this class.
 
void setSolutionTime (const double solution_time)
 Set the time at which the solution is to be evaluated.
 
void setTimeInterval (const double current_time, const double new_time)
 Set the time interval of integration.
 
void setInterpScale (const double interp_scale)
 Set scale for interp operator.
 
void setSpreadScale (const double spread_scale)
 Set scale for spread operator.
 
void setRegularizeMobilityScale (const double reg_mob_scale)
 Set scale for regularizing mobility matrix.
 
void setNormalizeSpreadForce (const bool normalize_force)
 Set if the mean of the Lagrangian force is to be subtracted from the Eulerian force variable. More...
 
void setVelocityPoissonSpecifications (const SAMRAI::solv::PoissonSpecifications &u_problem_coefs)
 Set the PoissonSpecifications object used to specify the coefficients for the momentum equation in the incompressible Stokes operator.
 
void setPhysicalBcCoefs (const std::vector< SAMRAI::solv::RobinBcCoefStrategy< NDIM > * > &u_bc_coefs, SAMRAI::solv::RobinBcCoefStrategy< NDIM > *p_bc_coef)
 Set the SAMRAI::solv::RobinBcCoefStrategy objects used to specify physical boundary conditions. More...
 
void setPhysicalBoundaryHelper (SAMRAI::tbox::Pointer< IBAMR::StaggeredStokesPhysicalBoundaryHelper > bc_helper)
 Set the StokesSpecifications object and timestep size used to specify the coefficients for the time-dependent incompressible Stokes operator.
 
bool solveMobilitySystem (Vec x, Vec b)
 Solves the mobility problem. More...
 
bool solveBodyMobilitySystem (Vec x, Vec b)
 Solves the mobility problem. More...
 
void initializeSolverState (Vec x, Vec b)
 Initialize the mobility solver. More...
 
void deallocateSolverState ()
 Deallocate the mobility solver.
 
void getMobilitySolvers (IBAMR::KrylovMobilitySolver **km_solver=nullptr, IBAMR::DirectMobilitySolver **dm_solver=nullptr, IBAMR::KrylovFreeBodyMobilitySolver **fbm_solver=nullptr)
 Get access to mobility solvers. More...
 

Detailed Description

Class CIBMobilitySolver solves for the constraint forces $ \vec{\lambda}$ and rigid body velocity $ \vec{U}$ of the structure(s). Specifically, the class solves two types of matrix-equations.

\begin{eqnarray*} \beta J L^{-1} S \gamma \vec{\lambda} &=& M \vec{\lambda} = \vec{w} \\ T M T^* \vec{U} &=& \vec{F}. \end{eqnarray*}

Here, $ J $ is the interpolation operator, $ S $ is the spreading operator, $ L $ is the incompressible Stokes operator, $ T $ is the rigid body operator, $ \vec{w} $ is the desired velocity at the nodes of the structure(s), and $ \vec{F} $ is the net external force and torque on the body.

This class employs direct solver for the approximate mobility and body-mobility sub-problems. The approximate mobility matrix is intended to be used in the preconditioning step of the overall constraint solver. The overall preconditioner is implemented in

See also
IBAMR::CIBSaddlePointSolver class. The class also supports Krylov body mobility solver for bodies moving under external force and torque.

Member Function Documentation

◆ getMobilitySolvers()

void IBAMR::CIBMobilitySolver::getMobilitySolvers ( IBAMR::KrylovMobilitySolver **  km_solver = nullptr,
IBAMR::DirectMobilitySolver **  dm_solver = nullptr,
IBAMR::KrylovFreeBodyMobilitySolver **  fbm_solver = nullptr 
)

Get access to mobility solvers.

Note
A null argument is simply skipped with no corresponding solver return.

◆ initializeSolverState()

void IBAMR::CIBMobilitySolver::initializeSolverState ( Vec  x,
Vec  b 
)

Initialize the mobility solver.

Parameters
xVec storing the Lagrange multiplier
bVec storing the desired velocity

◆ setNormalizeSpreadForce()

void IBAMR::CIBMobilitySolver::setNormalizeSpreadForce ( const bool  normalize_force)

Set if the mean of the Lagrangian force is to be subtracted from the Eulerian force variable.

Note
This operation is needed for certain situations like Stokes flow with periodic BCs.

◆ setPhysicalBcCoefs()

void IBAMR::CIBMobilitySolver::setPhysicalBcCoefs ( const std::vector< SAMRAI::solv::RobinBcCoefStrategy< NDIM > * > &  u_bc_coefs,
SAMRAI::solv::RobinBcCoefStrategy< NDIM > *  p_bc_coef 
)

Set the SAMRAI::solv::RobinBcCoefStrategy objects used to specify physical boundary conditions.

Note
Any of the elements of u_bc_coefs may be NULL. In this case, homogeneous Dirichlet boundary conditions are employed for that data depth. p_bc_coef may also be NULL; in that case, homogeneous Neumann boundary conditions are employed for the pressure.
Parameters
u_bc_coefsIBTK::Vector of pointers to objects that can set the Robin boundary condition coefficients for the velocity.
p_bc_coefPointer to object that can set the Robin boundary condition coefficients for the pressure.

◆ solveBodyMobilitySystem()

bool IBAMR::CIBMobilitySolver::solveBodyMobilitySystem ( Vec  x,
Vec  b 
)

Solves the mobility problem.

Parameters
xVec storing the rigid body velocity
bVec storing the net external generalized force
Returns
true if the solver converged to the specified tolerances, false otherwise

◆ solveMobilitySystem()

bool IBAMR::CIBMobilitySolver::solveMobilitySystem ( Vec  x,
Vec  b 
)

Solves the mobility problem.

Parameters
xVec storing the Lagrange multiplier.
bVec storing the desired velocity.
Returns
true if the solver converged to the specified tolerances, false otherwise

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