identical grid wrapper More...
#include <grid.hh>
Classes | |
struct | Codim |
traits structure containing types for a codimension More... | |
struct | Partition |
Types for GridView. More... | |
Public Types | |
typedef Traits::ExtraData | ExtraData |
Public Member Functions | |
template<int codim> | |
Codim< codim >::LeafIterator | leafbegin () const |
template<int codim> | |
Codim< codim >::LeafIterator | leafend () const |
template<int codim, PartitionIteratorType pitype> | |
Codim< codim >::template Partition< pitype > ::LeafIterator | leafbegin () const |
template<int codim, PartitionIteratorType pitype> | |
Codim< codim >::template Partition< pitype > ::LeafIterator | leafend () const |
template<int codim> | |
Codim< codim >::LevelIterator | lbegin (const int) const |
template<int codim> | |
Codim< codim >::LevelIterator | lend (const int) const |
template<int codim, PartitionIteratorType pitype> | |
Codim< codim >::template Partition< pitype > ::LevelIterator | lbegin (const int) const |
template<int codim, PartitionIteratorType pitype> | |
Codim< codim >::template Partition< pitype > ::LevelIterator | lend (const int) const |
const GlobalIdSet & | globalIdSet () const |
const LocalIdSet & | localIdSet () const |
const LevelIndexSet & | levelIndexSet (int) const |
const LeafIndexSet & | leafIndexSet () const |
void | globalRefine (int) |
bool | mark (int, const typename Codim< 0 >::Entity &) |
int | getMark (const typename Codim< 0 >::Entity &) const |
bool | preAdapt () |
bool | adapt () |
template<class DataHandle > | |
bool | adapt (DataHandle &) |
void | postAdapt () |
const std::array< int, 3 > & | logicalCartesianSize () const |
const int * | globalCell () const |
void | getIJK (const int c, std::array< int, 3 > &ijk) const |
ExtraData | extraData () const |
template<class EntitySeed > | |
int | corners (const EntitySeed &seed) const |
template<class EntitySeed > | |
GlobalCoordinate | corner (const EntitySeed &seed, const int i) const |
template<class EntitySeed > | |
int | subEntities (const EntitySeed &seed, const int codim) const |
template<int codim, class EntitySeedArg > | |
Codim< codim >::EntitySeed | subEntitySeed (const EntitySeedArg &baseSeed, const int i) const |
const std::vector< GeometryType > & | geomTypes (const unsigned int codim) const |
int | indexInInside (const typename Codim< 0 >::EntitySeed &seed, const int i) const |
int | cartesianIndexInInside (const typename Codim< 0 >::EntitySeed &seed, const int i) const |
Codim< 0 >::EntitySeed | neighbor (const typename Codim< 0 >::EntitySeed &seed, const int i) const |
int | indexInOutside (const typename Codim< 0 >::EntitySeed &seed, const int i) const |
template<class EntitySeed > | |
GlobalCoordinate | outerNormal (const EntitySeed &seed, const int i) const |
template<class EntitySeed > | |
GlobalCoordinate | unitOuterNormal (const EntitySeed &seed, const int i) const |
template<class EntitySeed > | |
GlobalCoordinate | centroids (const EntitySeed &seed) const |
GlobalCoordinate | copyToGlobalCoordinate (const double *coords) const |
template<class EntitySeed > | |
double | volumes (const EntitySeed &seed) const |
void | init () |
Protected Attributes | |
std::unique_ptr < UnstructuredGridType, UnstructuredGridDeleter > | gridPtr_ |
const UnstructuredGridType & | grid_ |
CollectiveCommunication | comm_ |
std::array< int, 3 > | cartDims_ |
std::vector< std::vector < GeometryType > > | geomTypes_ |
std::vector< std::vector< int > > | cellVertices_ |
std::vector< GlobalCoordinate > | unitOuterNormals_ |
LeafIndexSet | leafIndexSet_ |
GlobalIdSet | globalIdSet_ |
LocalIdSet | localIdSet_ |
Traits | |
typedef GridFamily::Traits | Traits |
type of the grid traits | |
Iterator Types | |
typedef Traits::HierarchicIterator | HierarchicIterator |
iterator over the grid hierarchy | |
typedef Traits::LeafIntersectionIterator | LeafIntersectionIterator |
iterator over intersections with other entities on the leaf level | |
typedef Traits::LevelIntersectionIterator | LevelIntersectionIterator |
iterator over intersections with other entities on the same level | |
Grid View Types | |
typedef Partition < All_Partition > ::LevelGridView | LevelGridView |
View types for All_Partition. | |
typedef Partition < All_Partition > ::LeafGridView | LeafGridView |
Index and Id Set Types | |
typedef Traits::LeafIndexSet | LeafIndexSet |
type of leaf index set More... | |
typedef Traits::LevelIndexSet | LevelIndexSet |
type of level index set More... | |
typedef Traits::GlobalIdSet | GlobalIdSet |
type of global id set More... | |
typedef Traits::LocalIdSet | LocalIdSet |
type of local id set More... | |
Miscellaneous Types | |
typedef Traits::ctype | ctype |
type of vector coordinates (e.g., double) | |
typedef Traits::CollectiveCommunication | CollectiveCommunication |
communicator with all other processes having some part of the grid | |
typedef Traits::GlobalCoordinate | GlobalCoordinate |
Construction and Destruction | |
PolyhedralGrid (const UnstructuredGridType &grid) | |
constructor More... | |
Casting operators | |
operator const UnstructuredGridType & () const | |
Size Methods | |
int | maxLevel () const |
obtain maximal grid level More... | |
int | size (int, int codim) const |
obtain number of entites on a level More... | |
int | size (int codim) const |
obtain number of leaf entities More... | |
int | size (int, GeometryType type) const |
obtain number of entites on a level More... | |
int | size (GeometryType type) const |
returns the number of boundary segments within the macro grid More... | |
size_t | numBoundarySegments () const |
obtain number of leaf entities More... | |
Parallel Data Distribution and Communication Methods | |
int | overlapSize (int) const |
obtain size of overlap region for the leaf grid More... | |
int | ghostSize (int codim) const |
obtain size of ghost region for the leaf grid More... | |
int | overlapSize (int, int) const |
obtain size of overlap region for a grid level More... | |
int | ghostSize (int, int codim) const |
obtain size of ghost region for a grid level More... | |
template<class DataHandle , class Data > | |
void | communicate (CommDataHandleIF< DataHandle, Data > &, InterfaceType, CommunicationDirection, int) const |
communicate information on a grid level More... | |
template<class DataHandle , class Data > | |
void | communicate (CommDataHandleIF< DataHandle, Data > &, InterfaceType, CommunicationDirection) const |
communicate information on leaf entities More... | |
const CollectiveCommunication & | comm () const |
obtain CollectiveCommunication object More... | |
bool | loadBalance () |
rebalance the load each process has to handle More... | |
template<class DataHandle , class Data > | |
bool | loadBalance (CommDataHandleIF< DataHandle, Data > &) |
rebalance the load each process has to handle More... | |
template<class DofManager > | |
bool | loadBalance (DofManager &) |
rebalance the load each process has to handle More... | |
template<PartitionIteratorType pitype> | |
Partition< pitype >::LevelGridView | levelGridView (int) const |
View for a grid level. | |
template<PartitionIteratorType pitype> | |
Partition< pitype >::LeafGridView | leafGridView () const |
View for the leaf grid. | |
LevelGridView | levelGridView (int) const |
View for a grid level for All_Partition. | |
LeafGridView | leafGridView () const |
View for the leaf grid for All_Partition. | |
template<class EntitySeed > | |
Traits::template Codim < EntitySeed::codimension > ::EntityPointer | entityPointer (const EntitySeed &seed) const |
obtain EntityPointer from EntitySeed. More... | |
template<class EntitySeed > | |
Traits::template Codim < EntitySeed::codimension > ::Entity | entity (const EntitySeed &seed) const |
obtain EntityPointer from EntitySeed. More... | |
Miscellaneous Methods | |
void | update () |
update grid caches More... | |
identical grid wrapper
HostGrid | DUNE grid to be wrapped (called host grid) |
typedef Traits::GlobalIdSet Dune::PolyhedralGrid< dim, dimworld >::GlobalIdSet |
type of global id set
The id set assigns a unique identifier to each entity within the grid. This identifier is unique over all processes sharing this grid.
The global id set is a model of Dune::IdSet.
typedef Traits::LeafIndexSet Dune::PolyhedralGrid< dim, dimworld >::LeafIndexSet |
type of leaf index set
The index set assigns consecutive indices to the entities of the leaf grid. The indices are of integral type and can be used to access arrays.
The leaf index set is a model of Dune::IndexSet.
typedef Traits::LevelIndexSet Dune::PolyhedralGrid< dim, dimworld >::LevelIndexSet |
type of level index set
The index set assigns consecutive indices to the entities of a grid level. The indices are of integral type and can be used to access arrays.
The level index set is a model of Dune::IndexSet.
typedef Traits::LocalIdSet Dune::PolyhedralGrid< dim, dimworld >::LocalIdSet |
type of local id set
The id set assigns a unique identifier to each entity within the grid. This identifier needs only to be unique over this process.
Though the local id set may be identical to the global id set, it is often implemented more efficiently.
The global id set is a model of Dune::IdSet.
|
inlineexplicit |
constructor
The references to ug are stored in the grid. Therefore, they must remain valid until the grid is destroyed.
[in] | ug | UnstructuredGrid reference |
|
inline |
|
inline |
handle | handler for restriction and prolongation operations which is a Model of the AdaptDataHandleInterface class. |
|
inline |
obtain CollectiveCommunication object
The CollectiveCommunication object should be used to globally communicate information between all processes sharing this grid.
|
inline |
communicate information on a grid level
dataHandle | communication data handle (user defined) | |
[in] | interface | communication interface (one of InteriorBorder_InteriorBorder_Interface, InteriorBorder_All_Interface, Overlap_OverlapFront_Interface, Overlap_All_Interface, All_All_Interface) |
[in] | direction | communication direction (one of ForwardCommunication or BackwardCommunication) |
[in] | level | grid level to communicate |
|
inline |
communicate information on leaf entities
dataHandle | communication data handle (user defined) | |
[in] | interface | communication interface (one of InteriorBorder_InteriorBorder_Interface, InteriorBorder_All_Interface, Overlap_OverlapFront_Interface, Overlap_All_Interface, All_All_Interface) |
[in] | direction | communication direction (one of ForwardCommunication, BackwardCommunication) |
|
inline |
obtain EntityPointer from EntitySeed.
|
inline |
obtain EntityPointer from EntitySeed.
|
inline |
obtain size of ghost region for the leaf grid
[in] | codim | codimension for with the information is desired |
|
inline |
obtain size of ghost region for a grid level
[in] | level | grid level (0, ..., maxLevel()) |
[in] | codim | codimension (0, ..., dimension) |
|
inline |
rebalance the load each process has to handle
A parallel grid is redistributed such that each process has about the same load (e.g., the same number of leaf entites).
|
inline |
rebalance the load each process has to handle
A parallel grid is redistributed such that each process has about the same load (e.g., the same number of leaf entites).
The data handle is used to communicate the data associated with entities that move from one process to another.
datahandle | communication data handle (user defined) |
|
inline |
rebalance the load each process has to handle
A parallel grid is redistributed such that each process has about the same load (e.g., the same number of leaf entites).
The data handle is used to communicate the data associated with entities that move from one process to another.
dataHandle | data handle following the ALUGrid interface |
|
inline |
obtain maximal grid level
Grid levels are numbered 0, ..., L, where L is the value returned by this method.
|
inline |
obtain number of leaf entities
[in] | type | geometry type to consider |
|
inline |
obtain size of overlap region for the leaf grid
[in] | codim | codimension for with the information is desired |
|
inline |
obtain size of overlap region for a grid level
[in] | level | grid level (0, ..., maxLevel()) |
[in] | codim | codimension (0, ..., dimension) |
|
inline |
|
inline |
|
inline |
obtain number of entites on a level
[in] | level | level to consider |
[in] | codim | codimension to consider |
|
inline |
obtain number of leaf entities
[in] | codim | codimension to consider |
|
inline |
obtain number of entites on a level
[in] | level | level to consider |
[in] | type | geometry type to consider |
|
inline |
returns the number of boundary segments within the macro grid
|
inline |
update grid caches
This method has to be called whenever the underlying host grid changes.