dune-grid  2.2.1
Classes | Public Member Functions | Protected Member Functions | Static Protected Member Functions | Friends | List of all members
Dune::GeometryGrid< HostGrid, CoordFunction, Allocator > Class Template Reference

grid wrapper replacing the geometriesGeometryGrid wraps another DUNE grid and replaces its geometry by the generic geometries from dune-grid. These are linear (respectively n-linear) DUNE geometries interpolating some given corners. These corners are obtained by mapping the corners of the host grid's geometry (also called host geometry) by a coordinate function. More...

#include <dune/grid/geometrygrid/grid.hh>

Classes

struct  Codim

Public Member Functions

template<int codim>
Codim< codim >::LevelIterator lbegin (int level) const
template<int codim>
Codim< codim >::LevelIterator lend (int level) const
template<int codim, PartitionIteratorType pitype>
Codim< codim >::template
Partition< pitype >
::LevelIterator 
lbegin (int level) const
template<int codim, PartitionIteratorType pitype>
Codim< codim >::template
Partition< pitype >
::LevelIterator 
lend (int level) const
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
const GlobalIdSetglobalIdSet () const
const LocalIdSetlocalIdSet () const
const LevelIndexSetlevelIndexSet (int level) const
const LeafIndexSetleafIndexSet () const
void globalRefine (int refCount)
bool mark (int refCount, const typename Codim< 0 >::Entity &entity)
int getMark (const typename Codim< 0 >::Entity &entity) const
bool preAdapt ()
bool adapt ()
void postAdapt ()

Protected Member Functions

const CoordFunction & coordFunction () const
template<int codim>
char * allocateMappingStorage (const GeometryType &gt) const
template<int codim>
void deallocateMappingStorage (const GeometryType &gt, char *p) const

Static Protected Member Functions

template<int codim>
static const
HostGrid::template Codim
< codim >::Entity
getHostEntity (const typename Codim< codim >::Entity &entity)

Friends

class GeoGrid::HierarchicIterator< const Grid >
class GeoGrid::EntityBase
class GeoGrid::EntityPointer
class GeoGrid::EntityProxy
class GeoGrid::Geometry
class GeoGrid::Intersection
class GeoGrid::IntersectionIterator
class GeoGrid::IdSet
class GeoGrid::IndexSet
struct HostGridAccess
class GeoGrid::CommDataHandle
struct GeoGrid::LevelIteratorTraits
struct GeoGrid::LeafIteratorTraits
class PersistentContainer

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

Index and Id Set Types

typedef Traits::LeafIndexSet LeafIndexSet
 type of leaf index set
typedef Traits::LevelIndexSet LevelIndexSet
 type of level index set
typedef Traits::GlobalIdSet GlobalIdSet
 type of global id set
typedef Traits::LocalIdSet LocalIdSet
 type of local id set

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

Construction and Destruction

 GeometryGrid (HostGrid &hostGrid, CoordFunction &coordFunction, const Allocator &allocator=Allocator())
 constructor
 GeometryGrid (HostGrid *hostGrid, CoordFunction *coordFunction, const Allocator &allocator=Allocator())
 constructor
 ~GeometryGrid ()
 destructor

Size Methods

int maxLevel () const
 obtain maximal grid level
int size (int level, int codim) const
 obtain number of entites on a level
int size (int codim) const
 obtain number of leaf entities
int size (int level, GeometryType type) const
 obtain number of entites on a level
int size (GeometryType type) const
 returns the number of boundary segments within the macro grid
size_t numBoundarySegments () const
 obtain number of leaf entities

Parallel Data Distribution and Communication Methods

int overlapSize (int codim) const
 obtain size of overlap region for the leaf grid
int ghostSize (int codim) const
 obtain size of ghost region for the leaf grid
int overlapSize (int level, int codim) const
 obtain size of overlap region for a grid level
int ghostSize (int level, int codim) const
 obtain size of ghost region for a grid level
template<class DataHandle , class Data >
void communicate (CommDataHandleIF< DataHandle, Data > &datahandle, InterfaceType interface, CommunicationDirection direction, int level) const
 communicate information on a grid level
template<class DataHandle , class Data >
void communicate (CommDataHandleIF< DataHandle, Data > &datahandle, InterfaceType interface, CommunicationDirection direction) const
 communicate information on leaf entities
const CollectiveCommunicationcomm () const
 obtain CollectiveCommunication object
template<class EntitySeed >
Traits::template Codim
< EntitySeed::codimension >
::EntityPointer 
entityPointer (const EntitySeed &seed) const
 obtain EntityPointer from EntitySeed.

Miscellaneous Methods

const HostGrid & hostGrid () const
HostGrid & hostGrid ()
void update ()
 update grid caches

Detailed Description

template<class HostGrid, class CoordFunction = DefaultCoordFunction< HostGrid >, class Allocator = std::allocator< void >>
class Dune::GeometryGrid< HostGrid, CoordFunction, Allocator >

grid wrapper replacing the geometries

GeometryGrid wraps another DUNE grid and replaces its geometry by the generic geometries from dune-grid. These are linear (respectively n-linear) DUNE geometries interpolating some given corners. These corners are obtained by mapping the corners of the host grid's geometry (also called host geometry) by a coordinate function.

An example of a coordinate function is given by the following code:

class ExampleFunction
: public Dune :: AnalyticalCoordFunction< double, 2, 3, ExampleFunction >
{
typedef ExampleFunction This;
public:
typedef Base :: DomainVector DomainVector;
typedef Base :: RangeVector RangeVector;
void evaluate ( const DomainVector &x, RangeVector &y ) const
{
y[ 0 ] = x[ 0 ];
y[ 1 ] = x[ 1 ];
y[ 2 ] = x[ 0 ] + x[ 1 ];
}
};
Note
A dune-fem Function can be used as a coordinate function. The evaluation of discrete functions would be very expensive, though.
Template Parameters
HostGridDUNE grid to be wrapped (called host grid)
CoordFunctioncoordinate function

Member Typedef Documentation

template<class HostGrid , class CoordFunction = DefaultCoordFunction< HostGrid >, class Allocator = std::allocator< void >>
typedef Traits::CollectiveCommunication Dune::GeometryGrid< HostGrid, CoordFunction, Allocator >::CollectiveCommunication

communicator with all other processes having some part of the grid

template<class HostGrid , class CoordFunction = DefaultCoordFunction< HostGrid >, class Allocator = std::allocator< void >>
typedef Traits::ctype Dune::GeometryGrid< HostGrid, CoordFunction, Allocator >::ctype

type of vector coordinates (e.g., double)

template<class HostGrid , class CoordFunction = DefaultCoordFunction< HostGrid >, class Allocator = std::allocator< void >>
typedef Traits::GlobalIdSet Dune::GeometryGrid< HostGrid, CoordFunction, Allocator >::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.

Note
Id's are neither consecutive nor necessarily of an integral type.

The global id set is a model of Dune::IdSet.

template<class HostGrid , class CoordFunction = DefaultCoordFunction< HostGrid >, class Allocator = std::allocator< void >>
typedef Traits::HierarchicIterator Dune::GeometryGrid< HostGrid, CoordFunction, Allocator >::HierarchicIterator

iterator over the grid hierarchy

template<class HostGrid , class CoordFunction = DefaultCoordFunction< HostGrid >, class Allocator = std::allocator< void >>
typedef Traits::LeafIndexSet Dune::GeometryGrid< HostGrid, CoordFunction, Allocator >::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.

template<class HostGrid , class CoordFunction = DefaultCoordFunction< HostGrid >, class Allocator = std::allocator< void >>
typedef Traits::LeafIntersectionIterator Dune::GeometryGrid< HostGrid, CoordFunction, Allocator >::LeafIntersectionIterator

iterator over intersections with other entities on the leaf level

template<class HostGrid , class CoordFunction = DefaultCoordFunction< HostGrid >, class Allocator = std::allocator< void >>
typedef Traits::LevelIndexSet Dune::GeometryGrid< HostGrid, CoordFunction, Allocator >::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.

template<class HostGrid , class CoordFunction = DefaultCoordFunction< HostGrid >, class Allocator = std::allocator< void >>
typedef Traits::LevelIntersectionIterator Dune::GeometryGrid< HostGrid, CoordFunction, Allocator >::LevelIntersectionIterator

iterator over intersections with other entities on the same level

template<class HostGrid , class CoordFunction = DefaultCoordFunction< HostGrid >, class Allocator = std::allocator< void >>
typedef Traits::LocalIdSet Dune::GeometryGrid< HostGrid, CoordFunction, Allocator >::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.

Note
Ids are neither consecutive nor necessarily of an integral type.
Local ids need not be compatible with global ids. Also, no mapping from local ids to global ones needs to exist.

The global id set is a model of Dune::IdSet.

template<class HostGrid , class CoordFunction = DefaultCoordFunction< HostGrid >, class Allocator = std::allocator< void >>
typedef GridFamily::Traits Dune::GeometryGrid< HostGrid, CoordFunction, Allocator >::Traits

type of the grid traits

Constructor & Destructor Documentation

template<class HostGrid , class CoordFunction = DefaultCoordFunction< HostGrid >, class Allocator = std::allocator< void >>
Dune::GeometryGrid< HostGrid, CoordFunction, Allocator >::GeometryGrid ( HostGrid &  hostGrid,
CoordFunction &  coordFunction,
const Allocator &  allocator = Allocator() 
)
inline

constructor

The references to host grid and coordinate function are stored in the grid. Therefore, they must remain valid until the grid is destroyed.

Parameters
[in]hostGridreference to the grid to wrap
[in]coordFunctionreference to the coordinate function
[in]allocatorstorage allocator
template<class HostGrid , class CoordFunction = DefaultCoordFunction< HostGrid >, class Allocator = std::allocator< void >>
Dune::GeometryGrid< HostGrid, CoordFunction, Allocator >::GeometryGrid ( HostGrid *  hostGrid,
CoordFunction *  coordFunction,
const Allocator &  allocator = Allocator() 
)
inline

constructor

The grid takes ownership of the pointers to host grid and coordinate function. They will be deleted when the grid is destroyed.

Parameters
[in]hostGridpointer to the grid to wrap
[in]coordFunctionpointer to the coordinate function
[in]allocatorstorage allocator
template<class HostGrid , class CoordFunction = DefaultCoordFunction< HostGrid >, class Allocator = std::allocator< void >>
Dune::GeometryGrid< HostGrid, CoordFunction, Allocator >::~GeometryGrid ( )
inline

destructor

Member Function Documentation

template<class HostGrid , class CoordFunction = DefaultCoordFunction< HostGrid >, class Allocator = std::allocator< void >>
bool Dune::GeometryGrid< HostGrid, CoordFunction, Allocator >::adapt ( )
inline
template<class HostGrid , class CoordFunction = DefaultCoordFunction< HostGrid >, class Allocator = std::allocator< void >>
template<int codim>
char* Dune::GeometryGrid< HostGrid, CoordFunction, Allocator >::allocateMappingStorage ( const GeometryType &  gt) const
inlineprotected
template<class HostGrid , class CoordFunction = DefaultCoordFunction< HostGrid >, class Allocator = std::allocator< void >>
const CollectiveCommunication& Dune::GeometryGrid< HostGrid, CoordFunction, Allocator >::comm ( ) const
inline

obtain CollectiveCommunication object

The CollectiveCommunication object should be used to globally communicate information between all processes sharing this grid.

Note
The CollectiveCommunication object returned is identical to the one returned by the host grid.

References Dune::GeometryGrid< HostGrid, CoordFunction, Allocator >::hostGrid().

template<class HostGrid , class CoordFunction = DefaultCoordFunction< HostGrid >, class Allocator = std::allocator< void >>
template<class DataHandle , class Data >
void Dune::GeometryGrid< HostGrid, CoordFunction, Allocator >::communicate ( CommDataHandleIF< DataHandle, Data > &  datahandle,
InterfaceType  interface,
CommunicationDirection  direction,
int  level 
) const
inline

communicate information on a grid level

Parameters
datahandlecommunication data handle (user defined)
[in]interfacecommunication interface (one of InteriorBorder_InteriorBorder_Interface, InteriorBorder_All_Interface, Overlap_OverlapFront_Interface, Overlap_All_Interface, All_All_Interface)
[in]directioncommunication direction (one of ForwardCommunication or BackwardCommunication)
[in]levelgrid level to communicate

References Dune::GeometryGrid< HostGrid, CoordFunction, Allocator >::hostGrid().

template<class HostGrid , class CoordFunction = DefaultCoordFunction< HostGrid >, class Allocator = std::allocator< void >>
template<class DataHandle , class Data >
void Dune::GeometryGrid< HostGrid, CoordFunction, Allocator >::communicate ( CommDataHandleIF< DataHandle, Data > &  datahandle,
InterfaceType  interface,
CommunicationDirection  direction 
) const
inline

communicate information on leaf entities

Parameters
datahandlecommunication data handle (user defined)
[in]interfacecommunication interface (one of InteriorBorder_InteriorBorder_Interface, InteriorBorder_All_Interface, Overlap_OverlapFront_Interface, Overlap_All_Interface, All_All_Interface)
[in]directioncommunication direction (one of ForwardCommunication, BackwardCommunication)

References Dune::GeometryGrid< HostGrid, CoordFunction, Allocator >::hostGrid().

template<class HostGrid , class CoordFunction = DefaultCoordFunction< HostGrid >, class Allocator = std::allocator< void >>
const CoordFunction& Dune::GeometryGrid< HostGrid, CoordFunction, Allocator >::coordFunction ( ) const
inlineprotected
template<class HostGrid , class CoordFunction = DefaultCoordFunction< HostGrid >, class Allocator = std::allocator< void >>
template<int codim>
void Dune::GeometryGrid< HostGrid, CoordFunction, Allocator >::deallocateMappingStorage ( const GeometryType &  gt,
char *  p 
) const
inlineprotected
template<class HostGrid , class CoordFunction = DefaultCoordFunction< HostGrid >, class Allocator = std::allocator< void >>
template<class EntitySeed >
Traits::template Codim< EntitySeed::codimension >::EntityPointer Dune::GeometryGrid< HostGrid, CoordFunction, Allocator >::entityPointer ( const EntitySeed &  seed) const
inline

obtain EntityPointer from EntitySeed.

template<class HostGrid , class CoordFunction = DefaultCoordFunction< HostGrid >, class Allocator = std::allocator< void >>
template<int codim>
static const HostGrid::template Codim< codim >::Entity& Dune::GeometryGrid< HostGrid, CoordFunction, Allocator >::getHostEntity ( const typename Codim< codim >::Entity entity)
inlinestaticprotected
template<class HostGrid , class CoordFunction = DefaultCoordFunction< HostGrid >, class Allocator = std::allocator< void >>
int Dune::GeometryGrid< HostGrid, CoordFunction, Allocator >::getMark ( const typename Codim< 0 >::Entity entity) const
inline
template<class HostGrid , class CoordFunction = DefaultCoordFunction< HostGrid >, class Allocator = std::allocator< void >>
int Dune::GeometryGrid< HostGrid, CoordFunction, Allocator >::ghostSize ( int  codim) const
inline

obtain size of ghost region for the leaf grid

Parameters
[in]codimcodimension for with the information is desired

References Dune::GeometryGrid< HostGrid, CoordFunction, Allocator >::hostGrid().

template<class HostGrid , class CoordFunction = DefaultCoordFunction< HostGrid >, class Allocator = std::allocator< void >>
int Dune::GeometryGrid< HostGrid, CoordFunction, Allocator >::ghostSize ( int  level,
int  codim 
) const
inline

obtain size of ghost region for a grid level

Parameters
[in]levelgrid level (0, ..., maxLevel())
[in]codimcodimension (0, ..., dimension)

References Dune::GeometryGrid< HostGrid, CoordFunction, Allocator >::hostGrid().

template<class HostGrid , class CoordFunction = DefaultCoordFunction< HostGrid >, class Allocator = std::allocator< void >>
const GlobalIdSet& Dune::GeometryGrid< HostGrid, CoordFunction, Allocator >::globalIdSet ( ) const
inline
template<class HostGrid , class CoordFunction = DefaultCoordFunction< HostGrid >, class Allocator = std::allocator< void >>
void Dune::GeometryGrid< HostGrid, CoordFunction, Allocator >::globalRefine ( int  refCount)
inline
template<class HostGrid , class CoordFunction = DefaultCoordFunction< HostGrid >, class Allocator = std::allocator< void >>
const HostGrid& Dune::GeometryGrid< HostGrid, CoordFunction, Allocator >::hostGrid ( ) const
inline
template<class HostGrid , class CoordFunction = DefaultCoordFunction< HostGrid >, class Allocator = std::allocator< void >>
HostGrid& Dune::GeometryGrid< HostGrid, CoordFunction, Allocator >::hostGrid ( )
inline
template<class HostGrid , class CoordFunction = DefaultCoordFunction< HostGrid >, class Allocator = std::allocator< void >>
template<int codim>
Codim< codim >::LevelIterator Dune::GeometryGrid< HostGrid, CoordFunction, Allocator >::lbegin ( int  level) const
inline
template<class HostGrid , class CoordFunction = DefaultCoordFunction< HostGrid >, class Allocator = std::allocator< void >>
template<int codim, PartitionIteratorType pitype>
Codim< codim >::template Partition< pitype >::LevelIterator Dune::GeometryGrid< HostGrid, CoordFunction, Allocator >::lbegin ( int  level) const
inline
template<class HostGrid , class CoordFunction = DefaultCoordFunction< HostGrid >, class Allocator = std::allocator< void >>
template<int codim>
Codim< codim >::LeafIterator Dune::GeometryGrid< HostGrid, CoordFunction, Allocator >::leafbegin ( ) const
inline
template<class HostGrid , class CoordFunction = DefaultCoordFunction< HostGrid >, class Allocator = std::allocator< void >>
template<int codim, PartitionIteratorType pitype>
Codim< codim >::template Partition< pitype >::LeafIterator Dune::GeometryGrid< HostGrid, CoordFunction, Allocator >::leafbegin ( ) const
inline
template<class HostGrid , class CoordFunction = DefaultCoordFunction< HostGrid >, class Allocator = std::allocator< void >>
template<int codim>
Codim< codim >::LeafIterator Dune::GeometryGrid< HostGrid, CoordFunction, Allocator >::leafend ( ) const
inline
template<class HostGrid , class CoordFunction = DefaultCoordFunction< HostGrid >, class Allocator = std::allocator< void >>
template<int codim, PartitionIteratorType pitype>
Codim< codim >::template Partition< pitype >::LeafIterator Dune::GeometryGrid< HostGrid, CoordFunction, Allocator >::leafend ( ) const
inline
template<class HostGrid , class CoordFunction = DefaultCoordFunction< HostGrid >, class Allocator = std::allocator< void >>
const LeafIndexSet& Dune::GeometryGrid< HostGrid, CoordFunction, Allocator >::leafIndexSet ( ) const
inline
template<class HostGrid , class CoordFunction = DefaultCoordFunction< HostGrid >, class Allocator = std::allocator< void >>
template<int codim>
Codim< codim >::LevelIterator Dune::GeometryGrid< HostGrid, CoordFunction, Allocator >::lend ( int  level) const
inline
template<class HostGrid , class CoordFunction = DefaultCoordFunction< HostGrid >, class Allocator = std::allocator< void >>
template<int codim, PartitionIteratorType pitype>
Codim< codim >::template Partition< pitype >::LevelIterator Dune::GeometryGrid< HostGrid, CoordFunction, Allocator >::lend ( int  level) const
inline
template<class HostGrid , class CoordFunction = DefaultCoordFunction< HostGrid >, class Allocator = std::allocator< void >>
const LevelIndexSet& Dune::GeometryGrid< HostGrid, CoordFunction, Allocator >::levelIndexSet ( int  level) const
inline
template<class HostGrid , class CoordFunction = DefaultCoordFunction< HostGrid >, class Allocator = std::allocator< void >>
const LocalIdSet& Dune::GeometryGrid< HostGrid, CoordFunction, Allocator >::localIdSet ( ) const
inline
template<class HostGrid , class CoordFunction = DefaultCoordFunction< HostGrid >, class Allocator = std::allocator< void >>
bool Dune::GeometryGrid< HostGrid, CoordFunction, Allocator >::mark ( int  refCount,
const typename Codim< 0 >::Entity entity 
)
inline
template<class HostGrid , class CoordFunction = DefaultCoordFunction< HostGrid >, class Allocator = std::allocator< void >>
int Dune::GeometryGrid< HostGrid, CoordFunction, Allocator >::maxLevel ( ) const
inline

obtain maximal grid level

Grid levels are numbered 0, ..., L, where L is the value returned by this method.

Returns
maximal grid level

References Dune::GeometryGrid< HostGrid, CoordFunction, Allocator >::hostGrid().

Referenced by Dune::GeometryGrid< HostGrid, CoordFunction, Allocator >::levelIndexSet(), and Dune::GeometryGrid< HostGrid, CoordFunction, Allocator >::update().

template<class HostGrid , class CoordFunction = DefaultCoordFunction< HostGrid >, class Allocator = std::allocator< void >>
size_t Dune::GeometryGrid< HostGrid, CoordFunction, Allocator >::numBoundarySegments ( ) const
inline

obtain number of leaf entities

Returns
number of leaf entities with a geometry of type type

References Dune::GeometryGrid< HostGrid, CoordFunction, Allocator >::hostGrid().

template<class HostGrid , class CoordFunction = DefaultCoordFunction< HostGrid >, class Allocator = std::allocator< void >>
int Dune::GeometryGrid< HostGrid, CoordFunction, Allocator >::overlapSize ( int  codim) const
inline

obtain size of overlap region for the leaf grid

Parameters
[in]codimcodimension for with the information is desired

References Dune::GeometryGrid< HostGrid, CoordFunction, Allocator >::hostGrid().

template<class HostGrid , class CoordFunction = DefaultCoordFunction< HostGrid >, class Allocator = std::allocator< void >>
int Dune::GeometryGrid< HostGrid, CoordFunction, Allocator >::overlapSize ( int  level,
int  codim 
) const
inline

obtain size of overlap region for a grid level

Parameters
[in]levelgrid level (0, ..., maxLevel())
[in]codimcodimension (0, ..., dimension)

References Dune::GeometryGrid< HostGrid, CoordFunction, Allocator >::hostGrid().

template<class HostGrid , class CoordFunction = DefaultCoordFunction< HostGrid >, class Allocator = std::allocator< void >>
void Dune::GeometryGrid< HostGrid, CoordFunction, Allocator >::postAdapt ( )
inline
template<class HostGrid , class CoordFunction = DefaultCoordFunction< HostGrid >, class Allocator = std::allocator< void >>
bool Dune::GeometryGrid< HostGrid, CoordFunction, Allocator >::preAdapt ( )
inline
template<class HostGrid , class CoordFunction = DefaultCoordFunction< HostGrid >, class Allocator = std::allocator< void >>
int Dune::GeometryGrid< HostGrid, CoordFunction, Allocator >::size ( int  level,
int  codim 
) const
inline

obtain number of entites on a level

Parameters
[in]levellevel to consider
[in]codimcodimension to consider
Returns
number of entities of codimension codim on grid level level.

References Dune::GeometryGrid< HostGrid, CoordFunction, Allocator >::hostGrid().

template<class HostGrid , class CoordFunction = DefaultCoordFunction< HostGrid >, class Allocator = std::allocator< void >>
int Dune::GeometryGrid< HostGrid, CoordFunction, Allocator >::size ( int  codim) const
inline

obtain number of leaf entities

Parameters
[in]codimcodimension to consider
Returns
number of leaf entities of codimension codim

References Dune::GeometryGrid< HostGrid, CoordFunction, Allocator >::hostGrid().

template<class HostGrid , class CoordFunction = DefaultCoordFunction< HostGrid >, class Allocator = std::allocator< void >>
int Dune::GeometryGrid< HostGrid, CoordFunction, Allocator >::size ( int  level,
GeometryType  type 
) const
inline

obtain number of entites on a level

Parameters
[in]levellevel to consider
[in]typegeometry type to consider
Returns
number of entities with a geometry of type type on grid level level.

References Dune::GeometryGrid< HostGrid, CoordFunction, Allocator >::hostGrid().

template<class HostGrid , class CoordFunction = DefaultCoordFunction< HostGrid >, class Allocator = std::allocator< void >>
int Dune::GeometryGrid< HostGrid, CoordFunction, Allocator >::size ( GeometryType  type) const
inline

returns the number of boundary segments within the macro grid

Returns
number of boundary segments within the macro grid

References Dune::GeometryGrid< HostGrid, CoordFunction, Allocator >::hostGrid().

template<class HostGrid , class CoordFunction = DefaultCoordFunction< HostGrid >, class Allocator = std::allocator< void >>
void Dune::GeometryGrid< HostGrid, CoordFunction, Allocator >::update ( )
inline

update grid caches

This method has to be called whenever the underlying host grid changes.

Note
If you adapt the host grid through this geometry grid's adaptation or load balancing methods, update is automatically called.

References Dune::GeometryGrid< HostGrid, CoordFunction, Allocator >::adapt(), and Dune::GeometryGrid< HostGrid, CoordFunction, Allocator >::maxLevel().

Referenced by Dune::GeometryGrid< HostGrid, CoordFunction, Allocator >::adapt(), and Dune::GeometryGrid< HostGrid, CoordFunction, Allocator >::globalRefine().

Friends And Related Function Documentation

template<class HostGrid , class CoordFunction = DefaultCoordFunction< HostGrid >, class Allocator = std::allocator< void >>
friend class GeoGrid::CommDataHandle
friend
template<class HostGrid , class CoordFunction = DefaultCoordFunction< HostGrid >, class Allocator = std::allocator< void >>
friend class GeoGrid::EntityBase
friend
template<class HostGrid , class CoordFunction = DefaultCoordFunction< HostGrid >, class Allocator = std::allocator< void >>
friend class GeoGrid::EntityPointer
friend
template<class HostGrid , class CoordFunction = DefaultCoordFunction< HostGrid >, class Allocator = std::allocator< void >>
friend class GeoGrid::EntityProxy
friend
template<class HostGrid , class CoordFunction = DefaultCoordFunction< HostGrid >, class Allocator = std::allocator< void >>
friend class GeoGrid::Geometry
friend
template<class HostGrid , class CoordFunction = DefaultCoordFunction< HostGrid >, class Allocator = std::allocator< void >>
friend class GeoGrid::HierarchicIterator< const Grid >
friend
template<class HostGrid , class CoordFunction = DefaultCoordFunction< HostGrid >, class Allocator = std::allocator< void >>
friend class GeoGrid::IdSet
friend
template<class HostGrid , class CoordFunction = DefaultCoordFunction< HostGrid >, class Allocator = std::allocator< void >>
friend class GeoGrid::IndexSet
friend
template<class HostGrid , class CoordFunction = DefaultCoordFunction< HostGrid >, class Allocator = std::allocator< void >>
friend class GeoGrid::Intersection
friend
template<class HostGrid , class CoordFunction = DefaultCoordFunction< HostGrid >, class Allocator = std::allocator< void >>
friend class GeoGrid::IntersectionIterator
friend
template<class HostGrid , class CoordFunction = DefaultCoordFunction< HostGrid >, class Allocator = std::allocator< void >>
friend struct GeoGrid::LeafIteratorTraits
friend
template<class HostGrid , class CoordFunction = DefaultCoordFunction< HostGrid >, class Allocator = std::allocator< void >>
friend struct GeoGrid::LevelIteratorTraits
friend
template<class HostGrid , class CoordFunction = DefaultCoordFunction< HostGrid >, class Allocator = std::allocator< void >>
friend struct HostGridAccess
friend
template<class HostGrid , class CoordFunction = DefaultCoordFunction< HostGrid >, class Allocator = std::allocator< void >>
friend class PersistentContainer
friend

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