Common base class for many merger implementations: produce pairs of entities that may intersect.
More...
|
typedef T | ctype |
| the numeric type used in this interface
|
|
typedef Merger< T, grid1Dim, grid2Dim, dimworld >::Grid1Coords | Grid1Coords |
| Type used for local coordinates on the grid1 side.
|
|
typedef Merger< T, grid1Dim, grid2Dim, dimworld >::Grid2Coords | Grid2Coords |
| Type used for local coordinates on the grid2 side.
|
|
typedef Dune::FieldVector< T, dimworld > | WorldCoords |
| the coordinate type used in this interface
|
|
|
virtual void | build (const std::vector< Dune::FieldVector< T, dimworld > > &grid1_Coords, const std::vector< unsigned int > &grid1_elements, const std::vector< Dune::GeometryType > &grid1_element_types, const std::vector< Dune::FieldVector< T, dimworld > > &grid2_coords, const std::vector< unsigned int > &grid2_elements, const std::vector< Dune::GeometryType > &grid2_element_types) |
|
unsigned int | nSimplices () const |
| get the number of simplices in the merged grid The indices are then in 0..nSimplices()-1
|
|
void | clear () |
|
void | enableFallback (bool fallback) |
|
void | enableBruteForce (bool bruteForce) |
|
unsigned int | parents (unsigned int idx) const |
|
unsigned int | parent (unsigned int idx, unsigned int parId=0) const |
| get index of grid-n's parent simplex for given merged grid simplex
|
|
bool | simplexRefined (unsigned int idx, std::vector< unsigned int > &indices) const |
| get the merged grid simplices refining a given grid-n simplex
|
|
GridTraits< n >::Coords | parentLocal (unsigned int idx, unsigned int corner, unsigned int parId=0) const |
| get the grid-n parent's simplex local coordinates for a particular merged grid simplex corner (parent's index can be obtained via "parent<n>")
|
|
|
| StandardMerge () |
|
virtual void | computeIntersections (const Dune::GeometryType &grid1ElementType, const std::vector< Dune::FieldVector< T, dimworld > > &grid1ElementCorners, std::bitset<(1<< grid1Dim)> &neighborIntersects1, unsigned int grid1Index, const Dune::GeometryType &grid2ElementType, const std::vector< Dune::FieldVector< T, dimworld > > &grid2ElementCorners, std::bitset<(1<< grid2Dim)> &neighborIntersects2, unsigned int grid2Index, std::vector< RemoteSimplicialIntersection > &intersections)=0 |
| Compute the intersection between two overlapping elements.
|
|
bool | computeIntersection (unsigned int candidate0, unsigned int candidate1, const std::vector< Dune::FieldVector< T, dimworld > > &grid1Coords, const std::vector< Dune::GeometryType > &grid1_element_types, std::bitset<(1<< grid1Dim)> &neighborIntersects1, const std::vector< Dune::FieldVector< T, dimworld > > &grid2Coords, const std::vector< Dune::GeometryType > &grid2_element_types, std::bitset<(1<< grid2Dim)> &neighborIntersects2, bool insert=true) |
| Compute the intersection between two overlapping elements.
|
|
template<class T, int grid1Dim, int grid2Dim, int dimworld>
class Dune::GridGlue::StandardMerge< T, grid1Dim, grid2Dim, dimworld >
Common base class for many merger implementations: produce pairs of entities that may intersect.
Many merger algorithms consist of two parts: on the one hand there is a mechanism that produces pairs of elements that may intersect. On the other hand there is an algorithm that computes the intersection of two given elements. For the pairs-producing algorithm there appears to be a canonical choice, namely the algorithm by Gander and Japhet described in 'An Algorithm for Non-Matching Grid Projections with Linear Complexity, M.J. Gander and C. Japhet, Domain Decomposition Methods in Science and Engineering XVIII, pp. 185–192, Springer-Verlag, 2009.' This class implements this algorithm, calling a pure virtual function computeIntersection() to compute the intersection between two elements. Actual merger implementations can derive from this class and only implement computeIntersection().
- Template Parameters
-
T | The type used for coordinates (assumed to be the same for both grids) |
grid1Dim | Dimension of the grid1 grid |
grid2Dim | Dimension of the grid2 grid |
dimworld | Dimension of the world space where the coupling takes place |