Dune::SubYGrid< d, ct > Class Template Reference
#include <grids.hh>
Inheritance diagram for Dune::SubYGrid< d, ct >:

Detailed Description
template<int d, typename ct>
class Dune::SubYGrid< d, ct >
A SubYGrid is a grid that is embedded in a larger grid It is characterized by an offset and an enclosing grid as shown in the following picture:

The SubYGrid is shown in red, blue is the enclosing grid.
SubYGrid has additional iterators that provide a mapping to the consecutive index in the enclosing grid.
Public Types | |
typedef YGrid< d, ct >::iTupel | iTupel |
define types used for arguments | |
Public Member Functions | |
virtual | ~SubYGrid () |
Destructor. | |
SubYGrid () | |
make uninitialized subgrid | |
SubYGrid (iTupel origin, iTupel size, iTupel offset, iTupel supersize, fTupel h, fTupel r) | |
Make SubYGrid from origin, size, offset and supersize. | |
SubYGrid (YGrid< d, ct > base) | |
Make SubYGrid from YGrid. | |
int | offset (int i) const |
Return offset to origin of enclosing grid. | |
const iTupel & | offset () const |
Return offset to origin of enclosing grid. | |
int | supersize (int i) const |
return size of enclosing grid | |
const iTupel & | supersize () const |
return size of enclosing grid | |
virtual SubYGrid< d, ct > | intersection (const YGrid< d, ct > &r) const |
Return SubYGrid of supergrid of self which is the intersection of self and another YGrid. | |
SubIterator | subbegin () const |
return subiterator to first element of index set | |
SubIterator | subend () const |
return subiterator to last element of index set | |
TransformingSubIterator | tsubbegin () const |
return iterator to first element of index set | |
TransformingSubIterator | tsubbegin (iTupel &co) const |
return iterator to given element of index set | |
TransformingSubIterator | tsubend () const |
return subiterator to last element of index set | |
int | origin (int i) const |
Return origin in direction i. | |
void | origin (int i, int oi) const |
Set origin in direction i. | |
const iTupel & | origin () const |
return reference to origin | |
int | size (int i) const |
Return size in direction i. | |
void | size (int i, int si) const |
Set size in direction i. | |
const iTupel & | size () const |
Return reference to size tupel. | |
int | totalsize () const |
Return total size of index set which is the product of all size per direction. | |
int | min (int i) const |
Return minimum index in direction i. | |
void | min (int i, int mi) const |
Set minimum index in direction i. | |
int | max (int i) const |
Return maximum index in direction i. | |
void | max (int i, int mi) const |
Set maximum index in direction i. | |
const fTupel & | meshsize () const |
Return reference to mesh size tupel for read write access. | |
ct | meshsize (int i) const |
Return mesh size in direction i. | |
void | meshsize (int i, int hi) const |
Set mesh size in direction i. | |
const fTupel & | shift () const |
Return shift tupel. | |
ct | shift (int i) const |
Return shift in direction i. | |
void | shift (int i, int ri) const |
Set shift in direction i. | |
bool | empty () const |
Return true if YGrid is empty, i.e. has size 0 in all directions. | |
int | index (const iTupel &coord) const |
given a tupel compute its index in the lexicographic numbering | |
bool | inside (const iTupel &coord) const |
given a coordinate, return true if it is in the grid | |
virtual SubYGrid< d, ct > | intersection (YGrid< d, ct > &r) const |
Return new SubYGrid of self which is the intersection of self and another YGrid. | |
YGrid< d, ct > | move (iTupel v) const |
return grid moved by the vector v | |
Iterator | begin () const |
return iterator to first element of index set | |
Iterator | end () const |
return iterator to one past the last element of index set | |
TransformingIterator | tbegin () const |
return iterator to first element of index set | |
TransformingIterator | tend () const |
return iterator to one past the last element of the grid | |
Protected Attributes | |
iTupel | _origin |
internal representation uses origin/size | |
fTupel | _h |
mesh size per direction | |
fTupel | _r |
shift per direction | |
Classes | |
class | SubIterator |
class | TransformingSubIterator |
The documentation for this class was generated from the following file: