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

Class FastSweepingLSMethod provides a fast-sweeping algorithm implementation of the level set method. Specifically, this class produces a solution to the Eikonal equation \( |\nabla Q | = 1 \), which produces the signed distance away from an interface. More...

#include <ibamr/FastSweepingLSMethod.h>

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

Public Types

using LocateInterfaceNeighborhoodFcnPtr = void(*)(int D_idx, SAMRAI::tbox::Pointer< IBTK::HierarchyMathOps > hier_math_ops, double time, bool initial_time, void *ctx)
 Function specifying distance function near an interface. More...
 

Public Member Functions

 FastSweepingLSMethod (std::string object_name, SAMRAI::tbox::Pointer< SAMRAI::tbox::Database > db=nullptr, bool register_for_restart=true)
 Constructor. More...
 
virtual ~FastSweepingLSMethod ()=default
 Destructor. More...
 
void initializeLSData (int D_idx, SAMRAI::tbox::Pointer< IBTK::HierarchyMathOps > hierarchy_math_ops, int integrator_step, double time, bool initial_time) override
 Initialize level set data using the fast-sweeping method. More...
 
virtual void registerPhysicalBoundaryCondition (SAMRAI::solv::RobinBcCoefStrategy< NDIM > *robin_bc_coef)
 Register physical boundary condition for the level set. More...
 
virtual void registerInterfaceNeighborhoodLocatingFcn (LocateInterfaceNeighborhoodFcnPtr callback, void *ctx)
 Register interface neighborhood locating functions. More...
 
virtual void setReinitializeLSData (bool reinit_ls_data)
 Indicate that the class should reinitialize level set. More...
 
void putToDatabase (SAMRAI::tbox::Pointer< SAMRAI::tbox::Database > db) override
 

Protected Attributes

bool d_consider_phys_bdry_wall = false
 
int d_wall_location_idx [2 *NDIM]
 
std::string d_object_name
 
bool d_registered_for_restart
 
LevelSetOrder d_ls_order = FIRST_ORDER_LS
 
LevelSetTimeStepping d_ls_ts = GAUSS_SEIDEL_PSEUDO_TS
 
double d_abs_tol = 1.0e-5
 
int d_max_its = 100
 
bool d_enable_logging = false
 
bool d_reinitialize_ls = false
 
int d_reinit_interval = 0
 
SAMRAI::solv::RobinBcCoefStrategy< NDIM > * d_bc_coef
 
std::vector< LocateInterfaceNeighborhoodFcnPtrd_locate_interface_fcns
 
std::vector< void * > d_locate_interface_fcns_ctx
 

Private Member Functions

void fastSweep (SAMRAI::tbox::Pointer< IBTK::HierarchyMathOps > hier_math_ops, int dist_idx) const
 Do one fast sweep over the hierarchy. More...
 
void fastSweep (SAMRAI::tbox::Pointer< SAMRAI::pdat::CellData< NDIM, double > > dist_data, const SAMRAI::tbox::Pointer< SAMRAI::hier::Patch< NDIM > > patch, const SAMRAI::hier::Box< NDIM > &domain_box) const
 Do one fast sweep over a patch. More...
 
void getFromInput (SAMRAI::tbox::Pointer< SAMRAI::tbox::Database > db)
 
void getFromRestart ()
 
 FastSweepingLSMethod (const FastSweepingLSMethod &from)=delete
 Copy constructor. More...
 
FastSweepingLSMethodoperator= (const FastSweepingLSMethod &that)=delete
 Assignment operator. More...
 

Detailed Description

Note
The class can also compute distance function from physical domain boundary if specified through input file. In presence of a physical domain wall, the distance function at a grid point is D = min(distance from interface, distance from wall location).

References Zhao, H., A Fast Sweeping Method For Eikonal Equations

Member Typedef Documentation

◆ LocateInterfaceNeighborhoodFcnPtr

using IBAMR::LSInitStrategy::LocateInterfaceNeighborhoodFcnPtr = void (*)(int D_idx, SAMRAI::tbox::Pointer<IBTK::HierarchyMathOps> hier_math_ops, double time, bool initial_time, void* ctx)
inherited

Constructor & Destructor Documentation

◆ FastSweepingLSMethod() [1/2]

IBAMR::FastSweepingLSMethod::FastSweepingLSMethod ( std::string  object_name,
SAMRAI::tbox::Pointer< SAMRAI::tbox::Database db = nullptr,
bool  register_for_restart = true 
)

◆ ~FastSweepingLSMethod()

virtual IBAMR::FastSweepingLSMethod::~FastSweepingLSMethod ( )
virtualdefault

◆ FastSweepingLSMethod() [2/2]

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

Member Function Documentation

◆ initializeLSData()

void IBAMR::FastSweepingLSMethod::initializeLSData ( int  D_idx,
SAMRAI::tbox::Pointer< IBTK::HierarchyMathOps hierarchy_math_ops,
int  integrator_step,
double  time,
bool  initial_time 
)
overridevirtual

Implements IBAMR::LSInitStrategy.

◆ fastSweep() [1/2]

void IBAMR::FastSweepingLSMethod::fastSweep ( SAMRAI::tbox::Pointer< IBTK::HierarchyMathOps hier_math_ops,
int  dist_idx 
) const
private

◆ fastSweep() [2/2]

void IBAMR::FastSweepingLSMethod::fastSweep ( SAMRAI::tbox::Pointer< SAMRAI::pdat::CellData< NDIM, double > >  dist_data,
const SAMRAI::tbox::Pointer< SAMRAI::hier::Patch< NDIM > >  patch,
const SAMRAI::hier::Box< NDIM > &  domain_box 
) const
private

◆ getFromInput()

void IBAMR::FastSweepingLSMethod::getFromInput ( SAMRAI::tbox::Pointer< SAMRAI::tbox::Database db)
private

Read input values from a given database.

◆ getFromRestart()

void IBAMR::FastSweepingLSMethod::getFromRestart ( )
private

Read object state from the restart file and initialize class data members.

◆ operator=()

FastSweepingLSMethod& IBAMR::FastSweepingLSMethod::operator= ( const FastSweepingLSMethod 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.

◆ registerPhysicalBoundaryCondition()

virtual void IBAMR::LSInitStrategy::registerPhysicalBoundaryCondition ( SAMRAI::solv::RobinBcCoefStrategy< NDIM > *  robin_bc_coef)
virtualinherited

◆ registerInterfaceNeighborhoodLocatingFcn()

virtual void IBAMR::LSInitStrategy::registerInterfaceNeighborhoodLocatingFcn ( LocateInterfaceNeighborhoodFcnPtr  callback,
void *  ctx 
)
virtualinherited

◆ setReinitializeLSData()

virtual void IBAMR::LSInitStrategy::setReinitializeLSData ( bool  reinit_ls_data)
virtualinherited

◆ putToDatabase()

void IBAMR::LSInitStrategy::putToDatabase ( SAMRAI::tbox::Pointer< SAMRAI::tbox::Database db)
overridevirtualinherited

Write out object state to the given database.

An empty default implementation is provided.

Implements SAMRAI::tbox::Serializable.

Member Data Documentation

◆ d_consider_phys_bdry_wall

bool IBAMR::FastSweepingLSMethod::d_consider_phys_bdry_wall = false
protected

◆ d_wall_location_idx

int IBAMR::FastSweepingLSMethod::d_wall_location_idx[2 *NDIM]
protected

◆ d_object_name

std::string IBAMR::LSInitStrategy::d_object_name
protectedinherited

◆ d_registered_for_restart

bool IBAMR::LSInitStrategy::d_registered_for_restart
protectedinherited

◆ d_ls_order

LevelSetOrder IBAMR::LSInitStrategy::d_ls_order = FIRST_ORDER_LS
protectedinherited

◆ d_ls_ts

LevelSetTimeStepping IBAMR::LSInitStrategy::d_ls_ts = GAUSS_SEIDEL_PSEUDO_TS
protectedinherited

◆ d_abs_tol

double IBAMR::LSInitStrategy::d_abs_tol = 1.0e-5
protectedinherited

◆ d_max_its

int IBAMR::LSInitStrategy::d_max_its = 100
protectedinherited

◆ d_enable_logging

bool IBAMR::LSInitStrategy::d_enable_logging = false
protectedinherited

◆ d_reinitialize_ls

bool IBAMR::LSInitStrategy::d_reinitialize_ls = false
protectedinherited

◆ d_reinit_interval

int IBAMR::LSInitStrategy::d_reinit_interval = 0
protectedinherited

◆ d_bc_coef

SAMRAI::solv::RobinBcCoefStrategy<NDIM>* IBAMR::LSInitStrategy::d_bc_coef
protectedinherited

◆ d_locate_interface_fcns

std::vector<LocateInterfaceNeighborhoodFcnPtr> IBAMR::LSInitStrategy::d_locate_interface_fcns
protectedinherited

◆ d_locate_interface_fcns_ctx

std::vector<void*> IBAMR::LSInitStrategy::d_locate_interface_fcns_ctx
protectedinherited

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