Proto  3.2
Public Member Functions | Protected Member Functions | Protected Attributes | Friends | List of all members
Proto::LevelFluxRegister< T, C, MEM > Class Template Reference

Flux Register. More...

#include <Proto_LevelFluxRegister.H>

Public Member Functions

 LevelFluxRegister ()
 Default constructor. More...
 
 LevelFluxRegister (const DisjointBoxLayout &a_dblCoarse, const DisjointBoxLayout &a_dblFine, const Point &a_refRatio, Array< T, DIM > a_dxCoarse)
 Constructor. More...
 
void define (const DisjointBoxLayout &a_dblCoarse, const DisjointBoxLayout &a_dblFine, const Point &a_refRatio, Array< T, DIM > a_dxCoarse)
 Define function. More...
 
void incrementCoarse (const BoxData< T, C, MEM > &a_flux, const DataIndex< BoxPartition > &a_di, const T &a_weight, unsigned int a_dir)
 Increment Coarse. More...
 
void incrementFine (const BoxData< T, C, MEM > &a_flux, const DataIndex< BoxPartition > &a_di, const T &a_weight, unsigned int a_dir)
 Increment Fine. More...
 
void reflux (LevelBoxData< T, C, MEM > &a_coarseData, const T &a_weight)
 Reflux. More...
 
void reset (T a_val=0)
 Reset. More...
 
int key (const Box &a_bx, const DataIndex< BoxPartition > &a_di)
 compute the hash key for a coarse register. More...
 
void print () const
 
DisjointBoxLayout crseLayout () const
 Access to layouts. More...
 
DisjointBoxLayout fineLayout () const
 

Protected Member Functions

BoxData< T, C, MEM > & sourceData (const Box &a_bx, const DataIndex< BoxPartition > &di)
 
BoxData< T, C, MEM > & destData (const Box &a_bx, const DataIndex< BoxPartition > &di)
 

Protected Attributes

DisjointBoxLayout m_crseLayout
 
DisjointBoxLayout m_fineLayout
 
Array< T, DIM > m_dxCrse
 
FluxRegisterCopier< T, C, MEM > m_copier
 
Point m_refRatio
 
std::vector< std::vector< Register< T, C, MEM > > > m_crseRegisters
 
std::vector< std::vector< shared_ptr< BoxData< T, C, MEM > > > > m_crseIncrement
 
std::vector< std::vector< Register< T, C, MEM > > > m_fineRegisters
 
std::vector< unordered_map< unsigned int, unsigned int > > m_crseIndices
 
std::vector< Array< Array< int, 2 >, DIM > > m_fineIndices
 
Array< Array< Stencil< T >, 2 >, DIM > m_avgFlux
 

Friends

class FluxRegisterCopierOp< T, C, MEM >
 
class FluxRegisterCopier< T, C, MEM >
 

Detailed Description

template<typename T, unsigned int C, MemType MEM>
class Proto::LevelFluxRegister< T, C, MEM >

Flux Register.

Constructor & Destructor Documentation

◆ LevelFluxRegister() [1/2]

template<typename T, unsigned int C, MemType MEM>
Proto::LevelFluxRegister< T, C, MEM >::LevelFluxRegister ( )
inline

Default constructor.

◆ LevelFluxRegister() [2/2]

template<typename T , unsigned int C, MemType MEM>
Proto::LevelFluxRegister< T, C, MEM >::LevelFluxRegister ( const DisjointBoxLayout a_dblCoarse,
const DisjointBoxLayout a_dblFine,
const Point a_refRatio,
Array< T, DIM >  a_dxCoarse 
)

Constructor.

Member Function Documentation

◆ define()

template<typename T , unsigned int C, MemType MEM>
void Proto::LevelFluxRegister< T, C, MEM >::define ( const DisjointBoxLayout a_dblCoarse,
const DisjointBoxLayout a_dblFine,
const Point a_refRatio,
Array< T, DIM >  a_dxCoarse 
)

Define function.

◆ incrementCoarse()

template<typename T , unsigned int C, MemType MEM>
void Proto::LevelFluxRegister< T, C, MEM >::incrementCoarse ( const BoxData< T, C, MEM > &  a_flux,
const DataIndex< BoxPartition > &  a_di,
const T &  a_weight,
unsigned int  a_dir 
)

Increment Coarse.

Increments all the registers contained in the coarse patch a_di, direction a_dir. Assumes that a_flux is defined on all the a_dir faces in the patch.

◆ incrementFine()

template<typename T , unsigned int C, MemType MEM>
void Proto::LevelFluxRegister< T, C, MEM >::incrementFine ( const BoxData< T, C, MEM > &  a_flux,
const DataIndex< BoxPartition > &  a_di,
const T &  a_weight,
unsigned int  a_dir 
)

Increment Fine.

Increments all the registers contained in the fine patch a_di, direction a_dir. Assumes that a_flux is defined on all the a_dir faces in the patch.

◆ reflux()

template<typename T , unsigned int C, MemType MEM>
void Proto::LevelFluxRegister< T, C, MEM >::reflux ( LevelBoxData< T, C, MEM > &  a_coarseData,
const T &  a_weight 
)

Reflux.

Performs the reflux correction on input coarse data.

◆ reset()

template<typename T , unsigned int C, MemType MEM>
void Proto::LevelFluxRegister< T, C, MEM >::reset ( a_val = 0)

Reset.

◆ key()

template<typename T , unsigned int C, MemType MEM>
int Proto::LevelFluxRegister< T, C, MEM >::key ( const Box a_bx,
const DataIndex< BoxPartition > &  a_di 
)

compute the hash key for a coarse register.

◆ print()

template<typename T , unsigned int C, MemType MEM>
void Proto::LevelFluxRegister< T, C, MEM >::print ( ) const

◆ crseLayout()

template<typename T, unsigned int C, MemType MEM>
DisjointBoxLayout Proto::LevelFluxRegister< T, C, MEM >::crseLayout ( ) const
inline

Access to layouts.

◆ fineLayout()

template<typename T, unsigned int C, MemType MEM>
DisjointBoxLayout Proto::LevelFluxRegister< T, C, MEM >::fineLayout ( ) const
inline

◆ sourceData()

template<typename T , unsigned int C, MemType MEM>
BoxData< T, C, MEM > & Proto::LevelFluxRegister< T, C, MEM >::sourceData ( const Box a_bx,
const DataIndex< BoxPartition > &  di 
)
protected

◆ destData()

template<typename T , unsigned int C, MemType MEM>
BoxData< T, C, MEM > & Proto::LevelFluxRegister< T, C, MEM >::destData ( const Box a_bx,
const DataIndex< BoxPartition > &  di 
)
protected

Friends And Related Function Documentation

◆ FluxRegisterCopierOp< T, C, MEM >

template<typename T, unsigned int C, MemType MEM>
friend class FluxRegisterCopierOp< T, C, MEM >
friend

◆ FluxRegisterCopier< T, C, MEM >

template<typename T, unsigned int C, MemType MEM>
friend class FluxRegisterCopier< T, C, MEM >
friend

Member Data Documentation

◆ m_crseLayout

template<typename T, unsigned int C, MemType MEM>
DisjointBoxLayout Proto::LevelFluxRegister< T, C, MEM >::m_crseLayout
protected

◆ m_fineLayout

template<typename T, unsigned int C, MemType MEM>
DisjointBoxLayout Proto::LevelFluxRegister< T, C, MEM >::m_fineLayout
protected

◆ m_dxCrse

template<typename T, unsigned int C, MemType MEM>
Array<T, DIM> Proto::LevelFluxRegister< T, C, MEM >::m_dxCrse
protected

◆ m_copier

template<typename T, unsigned int C, MemType MEM>
FluxRegisterCopier<T,C,MEM> Proto::LevelFluxRegister< T, C, MEM >::m_copier
protected

◆ m_refRatio

template<typename T, unsigned int C, MemType MEM>
Point Proto::LevelFluxRegister< T, C, MEM >::m_refRatio
protected

◆ m_crseRegisters

template<typename T, unsigned int C, MemType MEM>
std::vector<std::vector<Register<T,C,MEM> > > Proto::LevelFluxRegister< T, C, MEM >::m_crseRegisters
protected

◆ m_crseIncrement

template<typename T, unsigned int C, MemType MEM>
std::vector<std::vector<shared_ptr<BoxData<T,C,MEM> > > > Proto::LevelFluxRegister< T, C, MEM >::m_crseIncrement
protected

◆ m_fineRegisters

template<typename T, unsigned int C, MemType MEM>
std::vector<std::vector<Register<T,C,MEM> > > Proto::LevelFluxRegister< T, C, MEM >::m_fineRegisters
protected

◆ m_crseIndices

template<typename T, unsigned int C, MemType MEM>
std::vector<unordered_map<unsigned int,unsigned int> > Proto::LevelFluxRegister< T, C, MEM >::m_crseIndices
protected

◆ m_fineIndices

template<typename T, unsigned int C, MemType MEM>
std::vector<Array<Array<int,2>, DIM> > Proto::LevelFluxRegister< T, C, MEM >::m_fineIndices
protected

◆ m_avgFlux

template<typename T, unsigned int C, MemType MEM>
Array<Array<Stencil<T>,2>,DIM> Proto::LevelFluxRegister< T, C, MEM >::m_avgFlux
protected

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