rebl-AMR
Voxel< N, value > Class Template Reference

This Class Generates an unbalancerd Voxel to improve search by geometry partitioning. More...

#include <tree.h>

Inheritance diagram for Voxel< N, value >:
Tree< N, value >

Public Member Functions

 Voxel (real *length, real *coords)
 
void setLevel (uint *l)
 
void generateSearchTree (real *geom_xyz, uint n)
 
void distributeGeomToLeaves (real *geom_xyz, uint n)
 
uint checkSiblingStatus (morton< N > key, morton< N > *sibkey)
 
void derefineGeomTree ()
 
bool IsInsideSegment (morton< N > key, real *xyz)
 
 ~Voxel ()
 
- Public Member Functions inherited from Tree< N, value >
 Tree (real *length, real *coords, uint nx, uint ny, uint nz)
 
 Tree (real *length, real *coords)
 
 Tree ()
 
void construct (real *length, real *coords, uint nx, uint ny, uint nz)
 
virtual void level (morton< N > key, uint *level)
 
void centroid (morton< N > key, real *xyz)
 
void enclosingBox (morton< N > key, real *X)
 
virtual bitmap< N, value >::iterator begin ()
 
virtual bitmap< N, value >::iterator end ()
 
virtual uint size ()
 
void reserve (uint *reservedsize)
 
void siblings (morton< N > key, uint mylevel, morton< N > *sibkey)
 
void refine (morton< N > key)
 
void derefine (morton< N > key)
 
void refineRefineList ()
 
void refineRefineList (bitvector< N > &V)
 
void fourToOneP (uint istart, uint iend)
 
void refineRefineList (uint istart, uint iend)
 
void fourToOne ()
 
void findFlipLevel (morton< N > key, uint *mylevel, uint *changedirectionlevel, uint *direction)
 
void flipForNbr (morton< N > *key, uint *mylevel, uint *changedirectionlevel, uint *direction)
 
uint IsInVectorList (morton< N > key)
 
void addToList (morton< N > key)
 
uint count (morton< N > key)
 
void addToDerefineList (morton< N > key)
 If any of the siblings are listed in the dereffinement do not add to the list as derefining one child means removing all the siblings. More...
 
void derefineDerefineList (uint nlevel)
 
uint isInsideSolid (const morton< N > key, const real *geom_xyz, uint n)
 
virtual bitmap< N, value >::iterator find (morton< N > key)
 
void insertKey (morton< N > key)
 
void convertStl2Morton (uint geom_size, real *geom_xyz)
 
void pushToRefinelist (uint level)
 
bool isBoundary (morton< N > &key)
 
void extractBoundary ()
 
void getDirections (morton< N > &key, vector< uint > &directions)
 
uint refineListSize ()
 
void clearRefineList ()
 
void extractBoundaryP (uint istart, uint iend)
 
bool isInMeshList (const morton< N > &key)
 
bool isInRefineList (const morton< N > &key)
 
void constructHigherLevelNbrs (const morton< N > &key, const uint &keylevel, const uint &direction, morton< N > *nbr)
 
void printMesh ()
 
bool isBoundary (const morton< N > &key, uint direction)
 
std::pair< morton< N >, int > readRefineList (typename std::unordered_map< morton< N >, int >::iterator it)
 
morton< N > readDerefineList (typename std::unordered_map< morton< N >, int >::iterator it)
 
void getKey (uint i, morton< N > &key)
 
void clearMortonSTL ()
 
void retainFourToOne ()
 
void removeFromDerefineList (typename std::unordered_map< morton< N >, int >::iterator it)
 
unordered_map< morton< N >, int >::iterator Dbegin ()
 
unordered_map< morton< N >, int >::iterator Dend ()
 
void derefineDerefineList ()
 
void clearMesh ()
 
void pushToDerefinelist (uint nlevel)
 
unordered_map< morton< N >, int >::iterator Rbegin ()
 
unordered_map< morton< N >, int >::iterator Rend ()
 
std::unordered_map< morton< N >, int >::iterator findInDerefine (morton< N > key)
 
void mortonSTLclear ()
 
void flipRefineElemTag (typename std::unordered_map< morton< N >, int >::iterator it)
 
void refinelistReset ()
 
void constructNonlocalHigherLevelNbrs (const morton< N > &key, const uint &keylevel, const uint &direction, morton< N > *nbr)
 
void insertSeed (morton< N > &key)
 
void insertNbrs (vector< int > &Nbrs)
 
void enclosingBoxFixedLevel (morton< N > key, uint mylevel, real *X)
 
void centroidFixedLevel (morton< N > key, const uint mylevel, real *xyz)
 
virtual void convertCoordToMorton (real *xyz, morton< N > &key)
 
std::unordered_map< morton< N >, int >::iterator findInList (morton< N > key)
 
 ~Tree ()
 

Private Attributes

uint maxlevel
 
uint numMax
 
bitmap< N, value > mesh
 
bitvector< N > lookup
 

Friends

template<size_t N1, typename value1 >
class Hdf5XmfV
 

Additional Inherited Members

- Public Attributes inherited from Tree< N, value >
bitvector< N > boundarylist
 
- Protected Attributes inherited from Tree< N, value >
real ancestorlength [3]
 
real ancestorcoords [3]
 
morton< N > ancestorkey = 0
 
uint npx
 
uint npy
 
uint npz
 

Detailed Description

template<size_t N, typename value>
class Voxel< N, value >

This Class Generates an unbalancerd Voxel to improve search by geometry partitioning.

Constructor & Destructor Documentation

◆ Voxel()

template<size_t N, typename value>
Voxel< N, value >::Voxel ( real length,
real coords 
)
inline

◆ ~Voxel()

template<size_t N, typename value >
Voxel< N, value >::~Voxel ( )

Destructor of this class

Member Function Documentation

◆ checkSiblingStatus()

template<size_t N, typename value >
uint Voxel< N, value >::checkSiblingStatus ( morton< N >  key,
morton< N > *  sibkey 
)
Parameters
sibkeychecks to see if siblings include any points and whether they have the same level

◆ derefineGeomTree()

template<size_t N, typename value >
void Voxel< N, value >::derefineGeomTree ( )

checks to see if siblings include any points and whether they have the same level derefines the tree based on geometry

◆ distributeGeomToLeaves()

template<size_t N, typename value >
void Voxel< N, value >::distributeGeomToLeaves ( real geom_xyz,
uint  n 
)

distributes geometry to different cells (leaves)

◆ generateSearchTree()

template<size_t N, typename value >
void Voxel< N, value >::generateSearchTree ( real geom_xyz,
uint  n 
)

generates an initial tree

◆ IsInsideSegment()

template<size_t N, typename value >
bool Voxel< N, value >::IsInsideSegment ( morton< N >  key,
real xyz 
)

◆ setLevel()

template<size_t N, typename value >
void Voxel< N, value >::setLevel ( uint l)

constructor sets the maximum level for refinement

Friends And Related Function Documentation

◆ Hdf5XmfV

template<size_t N, typename value>
template<size_t N1, typename value1 >
friend class Hdf5XmfV
friend

this is a friend class to write out in hdf5 format

Member Data Documentation

◆ lookup

template<size_t N, typename value>
bitvector<N> Voxel< N, value >::lookup
private

◆ maxlevel

template<size_t N, typename value>
uint Voxel< N, value >::maxlevel
private

maximum level of refinement

◆ mesh

template<size_t N, typename value>
bitmap<N, value> Voxel< N, value >::mesh
private

◆ numMax

template<size_t N, typename value>
uint Voxel< N, value >::numMax
private

number of elements having the highest level


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