Proto  3.2
Public Member Functions | Private Member Functions | Private Attributes | List of all members
Proto::MBInterpOp Class Reference

Mapped Multiblock Block Boundary Interpolation Operator. More...

#include <Proto_MBInterpOp.H>

Public Member Functions

 MBInterpOp ()
 
 MBInterpOp (Point a_ghost, unsigned int a_order=4)
 Initialize. More...
 
template<typename MAP , MemType MEM>
 MBInterpOp (const MBLevelMap< MAP, MEM > &a_map, int a_order=4)
 
template<typename MAP , MemType MEM>
void define (const MBLevelMap< MAP, MEM > &a_map, int a_order=4)
 Define Block. More...
 
template<typename MAP , MemType MEM>
void define (const MBLevelMap< MAP, MEM > &a_map, MBInterpLayout a_interpLayout, int a_order=4)
 Define Block. More...
 
template<typename MAP , MemType MEM>
void define (const std::vector< std::shared_ptr< MBLevelMap< MAP, MEM >>> &a_maps, MBInterpLayout a_interpLayout, int a_order=4)
 
void insert (std::shared_ptr< MBPointInterpOp > a_op)
 Manual Operator Insertion. More...
 
template<typename T , unsigned int C, MemType MEM>
void apply (MBLevelBoxData< T, C, MEM > &a_dst, MBLevelBoxData< T, C, MEM > &a_src)
 Apply. More...
 
MBPointInterpOpoperator() (const MBDataPoint &a_target)
 Coefficients. More...
 
void print () const
 
void writeFootprint (std::string filename) const
 
template<typename MAP , MemType MEM>
void writeLevelFootprint (const MBLevelMap< MAP, MEM > &map, std::string filename) const
 
template<typename T , unsigned int C, MemType MEM>
void printErrorPoints (MBLevelBoxData< T, C, MEM > &a_err, T a_eps=0)
 

Private Member Functions

template<typename MAP , MemType MEM>
void addPointOps (const MBIndex &index, Point dir, const MBLevelMap< MAP, MEM > &map)
 
bool containsOp (Point dataPoint, const MBIndex &index) const
 
template<typename MAP , MemType MEM>
void addPointOp (Point dataPoint, const MBIndex &index, const MBLevelMap< MAP, MEM > &map)
 
void addShiftedOp (const MBPointInterpOp &baseOp, Point shift)
 
void copyAlongSymmetryAxes (const MBPointInterpOp &pointOp)
 

Private Attributes

MBInterpLayout m_interpLayout
 
Point m_ghost
 
int m_order
 
std::vector< std::shared_ptr< MBPointInterpOp > > m_ops
 
std::unordered_set< MBPointID, MBPointID::Hashm_points
 

Detailed Description

Mapped Multiblock Block Boundary Interpolation Operator.

MBInterpOp interpolates data to all block boundary ghost cells in a MBLevelBoxData. Ghost cells associated with domain boundaries are not affected.

Constructor & Destructor Documentation

◆ MBInterpOp() [1/3]

Proto::MBInterpOp::MBInterpOp ( )
inline

◆ MBInterpOp() [2/3]

Proto::MBInterpOp::MBInterpOp ( Point  a_ghost,
unsigned int  a_order = 4 
)
inline

Initialize.

This function does not create any operators. The user must call define separately

◆ MBInterpOp() [3/3]

template<typename MAP , MemType MEM>
Proto::MBInterpOp::MBInterpOp ( const MBLevelMap< MAP, MEM > &  a_map,
int  a_order = 4 
)
inline

Member Function Documentation

◆ define() [1/3]

template<typename MAP , MemType MEM>
void Proto::MBInterpOp::define ( const MBLevelMap< MAP, MEM > &  a_map,
int  a_order = 4 
)
inline

Define Block.

Builds the necessary MBPointInterpOp objects for each block boundary ghost cell implied by the input MBLevelMap and the number of ghost cells this was initialized with (see constructor). This function only defines the operators used to interpolate into the specified block. A user may choose to specify a different version of physical space when building the operators for each block

◆ define() [2/3]

template<typename MAP , MemType MEM>
void Proto::MBInterpOp::define ( const MBLevelMap< MAP, MEM > &  a_map,
MBInterpLayout  a_interpLayout,
int  a_order = 4 
)
inline

Define Block.

Builds the necessary MBPointInterpOp objects for each block boundary ghost cell implied by the input MBLevelMap and the number of ghost cells this was initialized with (see constructor). This function only defines the operators used to interpolate into the specified block. A user may choose to specify a different version of physical space when building the operators for each block

◆ define() [3/3]

template<typename MAP , MemType MEM>
void Proto::MBInterpOp::define ( const std::vector< std::shared_ptr< MBLevelMap< MAP, MEM >>> &  a_maps,
MBInterpLayout  a_interpLayout,
int  a_order = 4 
)
inline

◆ insert()

void Proto::MBInterpOp::insert ( std::shared_ptr< MBPointInterpOp a_op)
inline

Manual Operator Insertion.

Allows a user to build an MBInterpOp by manually constructing the point ops

◆ apply()

template<typename T , unsigned int C, MemType MEM>
void Proto::MBInterpOp::apply ( MBLevelBoxData< T, C, MEM > &  a_dst,
MBLevelBoxData< T, C, MEM > &  a_src 
)
inline

Apply.

Interpolates from source data to all block boundary ghost cells in the destination. It is assumed that MBLevelBoxData::fillBoundaries() has been called on the source data beforehand.

◆ operator()()

MBPointInterpOp& Proto::MBInterpOp::operator() ( const MBDataPoint a_target)
inline

Coefficients.

Writes the first P coefficients of the interpolating polynomial to a specified component of a specified source data array. Useful for debugging Get Point Operator Returns the MBPointInterpOp associated with a specified target cell.

◆ print()

void Proto::MBInterpOp::print ( ) const

◆ writeFootprint()

void Proto::MBInterpOp::writeFootprint ( std::string  filename) const

◆ writeLevelFootprint()

template<typename MAP , MemType MEM>
void Proto::MBInterpOp::writeLevelFootprint ( const MBLevelMap< MAP, MEM > &  map,
std::string  filename 
) const

◆ printErrorPoints()

template<typename T , unsigned int C, MemType MEM>
void Proto::MBInterpOp::printErrorPoints ( MBLevelBoxData< T, C, MEM > &  a_err,
a_eps = 0 
)

◆ addPointOps()

template<typename MAP , MemType MEM>
void Proto::MBInterpOp::addPointOps ( const MBIndex index,
Point  dir,
const MBLevelMap< MAP, MEM > &  map 
)
private

◆ containsOp()

bool Proto::MBInterpOp::containsOp ( Point  dataPoint,
const MBIndex index 
) const
private

◆ addPointOp()

template<typename MAP , MemType MEM>
void Proto::MBInterpOp::addPointOp ( Point  dataPoint,
const MBIndex index,
const MBLevelMap< MAP, MEM > &  map 
)
private

◆ addShiftedOp()

void Proto::MBInterpOp::addShiftedOp ( const MBPointInterpOp baseOp,
Point  shift 
)
private

◆ copyAlongSymmetryAxes()

void Proto::MBInterpOp::copyAlongSymmetryAxes ( const MBPointInterpOp pointOp)
private

Member Data Documentation

◆ m_interpLayout

MBInterpLayout Proto::MBInterpOp::m_interpLayout
private

◆ m_ghost

Point Proto::MBInterpOp::m_ghost
private

◆ m_order

int Proto::MBInterpOp::m_order
private

◆ m_ops

std::vector<std::shared_ptr<MBPointInterpOp> > Proto::MBInterpOp::m_ops
private

◆ m_points

std::unordered_set<MBPointID, MBPointID::Hash> Proto::MBInterpOp::m_points
private

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