IBAMR  IBAMR version 0.19.
Public Member Functions | Public Attributes | Private Attributes | Static Private Attributes | List of all members
IBTK::LEInteractor::IndicesAndShifts Struct Reference

Helper class containing local indices and periodic shifts. More...

Public Member Functions

 IndicesAndShifts (const SAMRAI::hier::Box< NDIM > &ib_box, const SAMRAI::hier::Patch< NDIM > &patch, const double *const X_data, const int X_size, const bool setup_extra_buffer=false)
 
 IndicesAndShifts (const IndicesAndShifts &)=delete
 
IndicesAndShiftsoperator= (const IndicesAndShifts &)=delete
 
 IndicesAndShifts (IndicesAndShifts &&)=delete
 
IndicesAndShiftsoperator= (IndicesAndShifts &&)=delete
 

Public Attributes

Eigen::Map< Eigen::VectorXi > d_local_indices
 
Eigen::Map< Eigen::VectorXd > d_periodic_shifts
 
Eigen::Map< Eigen::VectorXd > d_buffer
 

Private Attributes

bool d_use_stack
 
SAMRAI::tbox::Array< intd_dynamic_local_indices
 
SAMRAI::tbox::Array< doubled_dynamic_periodic_shifts
 
SAMRAI::tbox::Array< doubled_dynamic_buffer
 
std::array< int, s_stack_sized_stack_local_indices
 
std::array< double, s_stack_size *NDIM > d_stack_periodic_shifts
 
std::array< double, s_stack_sized_stack_buffer
 

Static Private Attributes

static constexpr std::size_t s_stack_size = 64u
 

Detailed Description

To avoid reading points not owned by the present patch, the IB kernels take, as a function argument, the indices of points which should be interpolated at or spread from. Some applications call these functions for small numbers of points at a time (e.g. one finite element), whereas others batch things per-patch. To support both cases and avoid unnecessary allocations, this class computes the indices of points which intersect the Patch and stores their indices in an Eigen::Map, which, for small numbers of input points, uses std::array instead of std::vector.

Constructor & Destructor Documentation

◆ IndicesAndShifts() [1/3]

IBTK::LEInteractor::IndicesAndShifts::IndicesAndShifts ( const SAMRAI::hier::Box< NDIM > &  ib_box,
const SAMRAI::hier::Patch< NDIM > &  patch,
const double *const  X_data,
const int  X_size,
const bool  setup_extra_buffer = false 
)

Constructor.

◆ IndicesAndShifts() [2/3]

IBTK::LEInteractor::IndicesAndShifts::IndicesAndShifts ( const IndicesAndShifts )
delete

Copying is not implemented.

◆ IndicesAndShifts() [3/3]

IBTK::LEInteractor::IndicesAndShifts::IndicesAndShifts ( IndicesAndShifts &&  )
delete

Moving is not implemented.

Member Function Documentation

◆ operator=() [1/2]

IndicesAndShifts& IBTK::LEInteractor::IndicesAndShifts::operator= ( const IndicesAndShifts )
delete

Copying is not implemented.

◆ operator=() [2/2]

IndicesAndShifts& IBTK::LEInteractor::IndicesAndShifts::operator= ( IndicesAndShifts &&  )
delete

Moving is not implemented.

Member Data Documentation

◆ s_stack_size

constexpr std::size_t IBTK::LEInteractor::IndicesAndShifts::s_stack_size = 64u
staticconstexprprivate

◆ d_use_stack

bool IBTK::LEInteractor::IndicesAndShifts::d_use_stack
private

◆ d_dynamic_local_indices

SAMRAI::tbox::Array<int> IBTK::LEInteractor::IndicesAndShifts::d_dynamic_local_indices
private

◆ d_dynamic_periodic_shifts

SAMRAI::tbox::Array<double> IBTK::LEInteractor::IndicesAndShifts::d_dynamic_periodic_shifts
private

◆ d_dynamic_buffer

SAMRAI::tbox::Array<double> IBTK::LEInteractor::IndicesAndShifts::d_dynamic_buffer
private

◆ d_stack_local_indices

std::array<int, s_stack_size> IBTK::LEInteractor::IndicesAndShifts::d_stack_local_indices
private

◆ d_stack_periodic_shifts

std::array<double, s_stack_size * NDIM> IBTK::LEInteractor::IndicesAndShifts::d_stack_periodic_shifts
private

◆ d_stack_buffer

std::array<double, s_stack_size> IBTK::LEInteractor::IndicesAndShifts::d_stack_buffer
private

◆ d_local_indices

Eigen::Map<Eigen::VectorXi> IBTK::LEInteractor::IndicesAndShifts::d_local_indices

Array containing the indices of the points which are within the Patch provided to the constructor.

◆ d_periodic_shifts

Eigen::Map<Eigen::VectorXd> IBTK::LEInteractor::IndicesAndShifts::d_periodic_shifts

Array containing periodic shifts. Presently this is all zeros.

◆ d_buffer

Eigen::Map<Eigen::VectorXd> IBTK::LEInteractor::IndicesAndShifts::d_buffer

Array containing an extra buffer (if requested in the constructor by setting setup_extra_buffer = true) which has the same length as d_local_indices.


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