dune-grid  2.3.1
Public Types | Public Member Functions | List of all members
Dune::SGeometry< mydim, cdim, GridImp > Class Template Reference

#include <dune/grid/sgrid.hh>

Public Types

typedef GridImp::ctype ctype
 define type used for coordinates in grid module

Public Member Functions

void make (const FieldVector< ctype, cdim > &lower, const FieldMatrix< ctype, mydim, cdim > &A)
 Set up the geometry.
 SGeometry ()
 constructor

Detailed Description

template<int mydim, int cdim, class GridImp>
class Dune::SGeometry< mydim, cdim, GridImp >

SGeometry realizes the concept of the geometric part of a mesh entity.

The geometric part of a mesh entity is a $d$-dimensional object in $\mathbf{R}^w$ where $d$ corresponds the template parameter dim and $w$ corresponds to the template parameter dimworld.

The $d$-dimensional object is a polyhedron given by a certain number of corners, which are vectors in $\mathbf{R}^w$.

The member function global provides a map from a topologically equivalent polyhedron ("reference element") in $\mathbf{R}^d$ to the given polyhedron. This map can be inverted by the member function local, where an appropriate projection is applied first, when $d\neq w$.

In the case of a structured mesh discretizing a generalized cube this map is linear and can be described as

\[ g(l) = s + \sum\limits_{i=0}^{d-1} l_ir^i\]

where $s\in\mathbf{R}^w$ is a given position vector, the $r^i\in\mathbf{R}^w$ are given direction vectors and $l\in\mathbf{R}^d$ is a local coordinate within the reference polyhedron. The direction vectors are assumed to be orthogonal with respect to the standard Eucliden inner product.

The $d$-dimensional reference polyhedron is given by the points $\{ (x_0,\ldots,x_{d-1}) \ | \ x_i\in\{0,1\}\ \}$.

In order to invert the map for a point $p$, we have to find a local coordinate $l$ such that $g(l)=p$. Of course this is only possible if $d=w$. In the general case $d\leq w$ we determine $l$ such that

\[(s,r^k) + \sum\limits_{i=0}^{d-1} l_i (r^i,r^k) = (p,r^k) \ \ \ \forall k=0,\ldots,d-1. \]

The resulting system is diagonal since the direction vectors are required to be orthogonal.

Member Typedef Documentation

template<int mydim, int cdim, class GridImp >
typedef GridImp::ctype Dune::SGeometry< mydim, cdim, GridImp >::ctype

define type used for coordinates in grid module

Constructor & Destructor Documentation

template<int mydim, int cdim, class GridImp >
Dune::SGeometry< mydim, cdim, GridImp >::SGeometry ( )
inline

constructor

Member Function Documentation

template<int mydim, int cdim, class GridImp >
void Dune::SGeometry< mydim, cdim, GridImp >::make ( const FieldVector< ctype, cdim > &  lower,
const FieldMatrix< ctype, mydim, cdim > &  A 
)
inline

Set up the geometry.

Parameters
lowerThe lower left corner
AThe direction vectors

Allows a consistent treatment of all dimensions, including 0 (the vertex).


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