dune-geometry
2.2.0
|
default settings for BasicGeometry More...
#include <dune/geometry/genericgeometry/geometrytraits.hh>
Classes | |
struct | Caching |
specifies how constant values are to be cached More... | |
struct | Mapping |
specifies the reference mapping to be used More... | |
struct | UserData |
type of additional user data to be stored in each mapping More... | |
Public Types | |
typedef DuneCoordTraits< ctype > | CoordTraits |
types needed in matrix-vector operations | |
Static Public Attributes | |
static const int | dimGrid = dimG |
dimension of the grid | |
static const int | dimWorld = dimW |
dimension of the world | |
static const bool | hybrid = true |
may the grid contain elements of different type? |
default settings for BasicGeometry
The class BasicGeometry requires a template argument Traits. These traits specify which reference mapping shall be used by the geometry and tweaks some performance settings.
This default implementation serves two purposed. Firstly, it documents the expected parameters. Secondly, the user of BasicGeometry can derive his traits class from DefaultGeometryTraits. Then, only the non-default settings have to be specified. Moreover, deriving from DefaultGeometryTraits makes the user code more robust to changes in the generic geometries.
typedef DuneCoordTraits< ctype > Dune::GenericGeometry::DefaultGeometryTraits< ctype, dimG, dimW, alwaysAffine >::CoordTraits |
types needed in matrix-vector operations
const int Dune::GenericGeometry::DefaultGeometryTraits< ctype, dimG, dimW, alwaysAffine >::dimGrid = dimG [static] |
dimension of the grid
const int Dune::GenericGeometry::DefaultGeometryTraits< ctype, dimG, dimW, alwaysAffine >::dimWorld = dimW [static] |
dimension of the world
const bool Dune::GenericGeometry::DefaultGeometryTraits< ctype, dimG, dimW, alwaysAffine >::hybrid = true [static] |
may the grid contain elements of different type?
If the elements (entities of codimension 0) may differ in topology type, the grid is called hybrid (and this parameter must be set to true). In this case, all methods of the geometry implementation are virtual (but no other branching for topology type is used).
If the grid is non-hybrid, hybrid can be set to false. In this case, virtual methods are not necessary and, hence, the geometries are a little faster.
If hybrid is set to false, an additional parameter topologyId is required. It specifies the topological type of all elements in the grid. Here's an example:
static const unsigned int topologyId = SimplexTopology< dimGrid >::type::id;