dune-grid-glue  2.5-git
Public Types | Public Member Functions | Static Public Attributes | Protected Types | Protected Attributes | List of all members
Dune::GridGlue::Codim1Extractor< GV > Class Template Reference

#include <dune/grid-glue/extractors/codim1extractor.hh>

Inheritance diagram for Dune::GridGlue::Codim1Extractor< GV >:
Inheritance graph

Public Types

enum  { simplex_corners = dim }
 compile time number of corners of surface simplices More...
 
typedef Extractor< GV, 1 >::IndexType IndexType
 
typedef GV GridView
 
typedef GV::Grid::ctype ctype
 
typedef Dune::FieldVector< ctype, dimworldCoords
 
typedef GV::Traits::template Codim< dim >::Entity Vertex
 
typedef GV::Traits::template Codim< 0 >::Entity Element
 
typedef std::function< bool(const Element &, unsigned int subentity)> Predicate
 
typedef GV::Traits::template Codim< 0 >::template Partition< PType >::Iterator ElementIter
 
typedef GV::IntersectionIterator IsIter
 
typedef Extractor< GV, 1 >::SubEntityInfo SubEntityInfo
 
typedef Extractor< GV, 1 >::ElementInfo ElementInfo
 
typedef Extractor< GV, 1 >::VertexInfo VertexInfo
 
typedef Extractor< GV, 1 >::CoordinateInfo CoordinateInfo
 
typedef Extractor< GV, 1 >::VertexInfoMap VertexInfoMap
 
enum  
 
enum  
 
enum  
 
enum  
 
typedef GridView::Grid Grid
 
typedef Dune::FieldVector< ctype, dimLocalCoords
 
typedef Vertex::EntitySeed VertexSeed
 
typedef Element::EntitySeed ElementSeed
 
typedef std::vector< unsigned int > VertexVector
 
typedef Dune::MultipleCodimMultipleGeomTypeMapper< GridView, MCMGElementLayout > CellMapper
 
typedef Dune::MultiLinearGeometry< ctype, dim-codim, dimworldGeometry
 
typedef Dune::MultiLinearGeometry< ctype, dim-codim, dimLocalGeometry
 

Public Member Functions

 Codim1Extractor (const GV &gv, const ExtractorPredicate< GV, 1 > &descr)
 Constructor. More...
 
 Codim1Extractor (const GV &gv, const Predicate &predicate)
 Constructor. More...
 
void clear ()
 delete everything build up so far and free the memory More...
 
void getCoords (std::vector< Dune::FieldVector< ctype, dimworld > > &coords) const
 getter for the coordinates array More...
 
unsigned int nCoords () const
 getter for the count of coordinates More...
 
void getGeometryTypes (std::vector< Dune::GeometryType > &geometryTypes) const
 Get the list of geometry types. More...
 
void getFaces (std::vector< VertexVector > &faces) const
 Get the corners of the extracted subentities. More...
 
bool faceIndices (const Element &e, int &first, int &count) const
 gets index of first subentity as well as the total number of subentities that were extracted from this element More...
 
int indexInInside (unsigned int index) const
 gets the number face in the parent element More...
 
const GridViewgridView () const
 tests that a given entry in the extraction set does have local couplings More...
 
const Gridgrid () const
 
Element element (unsigned int index) const
 gets the parent element for a given face index, throws an exception if index not valid More...
 
Vertex vertex (unsigned int index) const
 gets the vertex for a given coordinate index throws an exception if index not valid More...
 
Geometry geometry (unsigned int index) const
 Get world geometry of the extracted face. More...
 
LocalGeometry geometryLocal (unsigned int index) const
 Get geometry of the extracted face in element coordinates. More...
 

Static Public Attributes

static const Dune::PartitionIteratorType PType = Dune::Interior_Partition
 

Protected Types

typedef std::map< IndexType, ElementInfo * > ElementInfoMap
 

Protected Attributes

const GridView gv_
 the grid object to extract the surface from More...
 
std::vector< CoordinateInfocoords_
 all information about the corner vertices of the extracted More...
 
std::vector< SubEntityInfosubEntities_
 all information about the extracted subEntities More...
 
VertexInfoMap vtxInfo_
 a map enabling faster access to vertices and coordinates More...
 
ElementInfoMap elmtInfo_
 a map enabling faster access to elements and faces More...
 
CellMapper cellMapper_
 

Member Typedef Documentation

◆ CellMapper

typedef Dune::MultipleCodimMultipleGeomTypeMapper<GridView, MCMGElementLayout> Dune::GridGlue::Extractor< GV, cd >::CellMapper
inherited

◆ CoordinateInfo

template<typename GV >
typedef Extractor<GV,1>::CoordinateInfo Dune::GridGlue::Codim1Extractor< GV >::CoordinateInfo

◆ Coords

template<typename GV >
typedef Dune::FieldVector<ctype, dimworld> Dune::GridGlue::Codim1Extractor< GV >::Coords

◆ ctype

template<typename GV >
typedef GV::Grid::ctype Dune::GridGlue::Codim1Extractor< GV >::ctype

◆ Element

template<typename GV >
typedef GV::Traits::template Codim<0>::Entity Dune::GridGlue::Codim1Extractor< GV >::Element

◆ ElementInfo

template<typename GV >
typedef Extractor<GV,1>::ElementInfo Dune::GridGlue::Codim1Extractor< GV >::ElementInfo

◆ ElementInfoMap

typedef std::map<IndexType, ElementInfo* > Dune::GridGlue::Extractor< GV, cd >::ElementInfoMap
protectedinherited

◆ ElementIter

template<typename GV >
typedef GV::Traits::template Codim<0>::template Partition<PType>::Iterator Dune::GridGlue::Codim1Extractor< GV >::ElementIter

◆ ElementSeed

typedef Element::EntitySeed Dune::GridGlue::Extractor< GV, cd >::ElementSeed
inherited

◆ Geometry

typedef Dune::MultiLinearGeometry<ctype, dim-codim, dimworld> Dune::GridGlue::Extractor< GV, cd >::Geometry
inherited

◆ Grid

typedef GridView::Grid Dune::GridGlue::Extractor< GV, cd >::Grid
inherited

◆ GridView

template<typename GV >
typedef GV Dune::GridGlue::Codim1Extractor< GV >::GridView

◆ IndexType

template<typename GV >
typedef Extractor<GV,1>::IndexType Dune::GridGlue::Codim1Extractor< GV >::IndexType

◆ IsIter

template<typename GV >
typedef GV::IntersectionIterator Dune::GridGlue::Codim1Extractor< GV >::IsIter

◆ LocalCoords

typedef Dune::FieldVector<ctype, dim> Dune::GridGlue::Extractor< GV, cd >::LocalCoords
inherited

◆ LocalGeometry

typedef Dune::MultiLinearGeometry<ctype, dim-codim, dim> Dune::GridGlue::Extractor< GV, cd >::LocalGeometry
inherited

◆ Predicate

template<typename GV >
typedef std::function<bool(const Element&, unsigned int subentity)> Dune::GridGlue::Codim1Extractor< GV >::Predicate

◆ SubEntityInfo

template<typename GV >
typedef Extractor<GV,1>::SubEntityInfo Dune::GridGlue::Codim1Extractor< GV >::SubEntityInfo

◆ Vertex

template<typename GV >
typedef GV::Traits::template Codim<dim>::Entity Dune::GridGlue::Codim1Extractor< GV >::Vertex

◆ VertexInfo

template<typename GV >
typedef Extractor<GV,1>::VertexInfo Dune::GridGlue::Codim1Extractor< GV >::VertexInfo

◆ VertexInfoMap

template<typename GV >
typedef Extractor<GV,1>::VertexInfoMap Dune::GridGlue::Codim1Extractor< GV >::VertexInfoMap

◆ VertexSeed

typedef Vertex::EntitySeed Dune::GridGlue::Extractor< GV, cd >::VertexSeed
inherited

◆ VertexVector

typedef std::vector<unsigned int> Dune::GridGlue::Extractor< GV, cd >::VertexVector
inherited

Member Enumeration Documentation

◆ anonymous enum

anonymous enum
inherited

◆ anonymous enum

anonymous enum
inherited

◆ anonymous enum

anonymous enum
inherited

◆ anonymous enum

template<typename GV >
anonymous enum

compile time number of corners of surface simplices

Enumerator
simplex_corners 

◆ anonymous enum

anonymous enum
inherited

Constructor & Destructor Documentation

◆ Codim1Extractor() [1/2]

template<typename GV >
Dune::GridGlue::Codim1Extractor< GV >::Codim1Extractor ( const GV &  gv,
const ExtractorPredicate< GV, 1 > &  descr 
)
inline

Constructor.

Parameters
gvthe grid view object to work with
descra predicate to mark entities for extraction (unary functor returning bool)
Deprecated:
"Please use a std::function<bool(const Element&, unsigned int)> in favor of the ExtractorPredicate."

◆ Codim1Extractor() [2/2]

template<typename GV >
Dune::GridGlue::Codim1Extractor< GV >::Codim1Extractor ( const GV &  gv,
const Predicate predicate 
)
inline

Constructor.

Parameters
gvthe grid view object to work with
predicatea predicate to mark entities for extraction (unary functor returning bool)

Member Function Documentation

◆ clear()

void Dune::GridGlue::Extractor< GV, cd >::clear ( )
inlineinherited

delete everything build up so far and free the memory

◆ element()

Element Dune::GridGlue::Extractor< GV, cd >::element ( unsigned int  index) const
inlineinherited

gets the parent element for a given face index, throws an exception if index not valid

Parameters
indexthe index of the face
Returns
a reference to the element's stored pointer

◆ faceIndices()

bool Dune::GridGlue::Extractor< GV, cd >::faceIndices ( const Element e,
int &  first,
int &  count 
) const
inlineinherited

gets index of first subentity as well as the total number of subentities that were extracted from this element

Parameters
[in]ethe element
[out]firstwill contain the index of the first subentity if it exists, else -1
[out]countwill contain the number of subentities extracted from this element
Returns
true if at least one subentity was extracted from this element

◆ geometry()

Extractor< GV, cd >::Geometry Dune::GridGlue::Extractor< GV, cd >::geometry ( unsigned int  index) const
inherited

Get world geometry of the extracted face.

Get World geometry of the extracted face.

◆ geometryLocal()

Extractor< GV, cd >::LocalGeometry Dune::GridGlue::Extractor< GV, cd >::geometryLocal ( unsigned int  index) const
inherited

Get geometry of the extracted face in element coordinates.

Get Geometry of the extracted face in element coordinates.

◆ getCoords()

void Dune::GridGlue::Extractor< GV, cd >::getCoords ( std::vector< Dune::FieldVector< ctype, dimworld > > &  coords) const
inlineinherited

getter for the coordinates array

Parameters
coordsa vector that will be resized (!) and filled with the coordinates, note that the single components are written consecutively

◆ getFaces()

void Dune::GridGlue::Extractor< GV, cd >::getFaces ( std::vector< VertexVector > &  faces) const
inlineinherited

Get the corners of the extracted subentities.

◆ getGeometryTypes()

void Dune::GridGlue::Extractor< GV, cd >::getGeometryTypes ( std::vector< Dune::GeometryType > &  geometryTypes) const
inlineinherited

Get the list of geometry types.

◆ grid()

const Grid& Dune::GridGlue::Extractor< GV, cd >::grid ( ) const
inlineinherited

◆ gridView()

const GridView& Dune::GridGlue::Extractor< GV, cd >::gridView ( ) const
inlineinherited

tests that a given entry in the extraction set does have local couplings

Todo:
parallel interface

give access to the Dune::GridView where this Patch belongs to

◆ indexInInside()

int Dune::GridGlue::Extractor< GV, cd >::indexInInside ( unsigned int  index) const
inlineinherited

gets the number face in the parent element

Parameters
indexthe index of the face
Returns
if failed -1, else the index

◆ nCoords()

unsigned int Dune::GridGlue::Extractor< GV, cd >::nCoords ( ) const
inlineinherited

getter for the count of coordinates

Returns
the count

◆ vertex()

Vertex Dune::GridGlue::Extractor< GV, cd >::vertex ( unsigned int  index) const
inlineinherited

gets the vertex for a given coordinate index throws an exception if index not valid

Parameters
indexthe index of the coordinate
Returns
a reference to the vertex' stored pointer

Member Data Documentation

◆ cellMapper_

CellMapper Dune::GridGlue::Extractor< GV, cd >::cellMapper_
protectedinherited

◆ coords_

std::vector<CoordinateInfo> Dune::GridGlue::Extractor< GV, cd >::coords_
protectedinherited

all information about the corner vertices of the extracted

◆ elmtInfo_

ElementInfoMap Dune::GridGlue::Extractor< GV, cd >::elmtInfo_
protectedinherited

a map enabling faster access to elements and faces

Maps an element's index (from index set) to an object holding the locally associated index of its first face in _indices (if there are more they are positioned consecutively) and an entity pointer to the codim<0> entity.

◆ gv_

const GridView Dune::GridGlue::Extractor< GV, cd >::gv_
protectedinherited

the grid object to extract the surface from

◆ PType

template<typename GV >
const Dune::PartitionIteratorType Dune::GridGlue::Codim1Extractor< GV >::PType = Dune::Interior_Partition
static

◆ subEntities_

std::vector<SubEntityInfo> Dune::GridGlue::Extractor< GV, cd >::subEntities_
protectedinherited

all information about the extracted subEntities

◆ vtxInfo_

VertexInfoMap Dune::GridGlue::Extractor< GV, cd >::vtxInfo_
protectedinherited

a map enabling faster access to vertices and coordinates

Maps a vertex' index (from index set) to an object holding the locally associated index of the vertex' coordinate in coords_ and an entity pointer to the codim<dim> entity.


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