DUNE-FEM (unstable)
Dune::Fem::hpDG::DiscontinuousGalerkinBlockMapper< GridPart, LocalKeys > Struct Template Reference
An \(hp\)-adaptive Dune::Fem::DofMapper. More...
#include <dune/fem/space/hpdg/blockmapper.hh>
Public Types | |
using | SizeType = typename BaseType::SizeType |
size type | |
using | GlobalKeyType = typename BaseType::GlobalKeyType |
global key type | |
using | GridPartType = GridPart |
grid part type | |
using | ElementType = typename BaseType::ElementType |
element type | |
using | LocalKeysType = LocalKeys |
basis function sets type | |
using | KeyType = typename LocalKeysType::KeyType |
key type | |
using | DofManagerType = DofManager< GridType > |
dof manager type | |
typedef Traits::DofMapperType | DofMapperType |
type of the DofMapper implementation | |
Public Member Functions | |
bool | consecutive () const |
return true if compress will affect data | |
SizeType | oldOffSet (const int block) const |
return old offsets for given block | |
SizeType | offSet (const int block) const |
return current offsets for given block | |
SizeType | numBlocks () const |
return number of supported blocks | |
void | update () |
update DoF mapping after grid modification More... | |
bool | contains (const int codim) const |
returns true if DoFs for given codimension exist More... | |
bool | fixedDataSize (const int codim) const |
Check, whether the data in a codimension has fixed size. | |
void | mapEach (const ElementType &element, Functor f) const |
map each local DoF number to a global key More... | |
void | mapEachEntityDof (const Entity &entity, Functor f) const |
map each local DoF number to a global key More... | |
Construction | |
template<class Function > | |
DiscontinuousGalerkinBlockMapper (const GridPartType &gridPart, const LocalKeysType &localKeys, const KeyType &value, Function function) | |
DiscontinuousGalerkinBlockMapper (const GridPartType &gridPart, const LocalKeysType &localKeys, const KeyType &value) | |
Copying and assignment | |
DiscontinuousGalerkinBlockMapper (const ThisType &)=delete | |
copy constructor | |
DiscontinuousGalerkinBlockMapper (ThisType &&)=default | |
move constructor | |
ThisType & | operator= (const ThisType &)=delete |
assignment operator | |
ThisType & | operator= (ThisType &&)=default |
move assignment operator | |
Adaptation interface | |
template<class Element > | |
std::enable_if<(std::is_same< Element, ElementType >::value||std::is_same< Element, GridElementType >::value), constKeyType & >::type | key (const Element &element) const |
get key currently assigned to an entity | |
void | mark (const KeyType &key, const ElementType &element) |
set key to be assigned to an entity after next call to adapt() | |
KeyType | getMark (const ElementType &element) const |
get key to be assigned to an entity after next call to adapt() | |
template<class Function > | |
bool | adapt (Function function) |
please doc me | |
bool | adapt () |
please doc me | |
Public interface for adaptation managers | |
const DofManagerType & | dofManager () const |
return DOF manager | |
void | insertEntity (const GridElementType &gridElement) |
add DOFs for element | |
void | removeEntity (const GridElementType &gridElement) |
mark DOFs for removal | |
void | insertNewEntity (const GridElementType &gridElement) |
add DOFs for new element | |
void | resize () |
bool | compress () |
compress DOF mapping | |
template<class Traits > | |
void | write (OutStreamInterface< Traits > &) |
this mapper has no I/O capabilities | |
template<class Traits > | |
void | read (InStreamInterface< Traits > &) |
this mapper has no I/O capabilities | |
void | backup () const |
this mapper has no I/O capabilities | |
void | restore () |
this mapper has no I/O capabilities | |
Interface methods | |
SizeType | size () const |
return number of dofs | |
int | maxNumDofs () const |
return upper bound for number of dofs | |
SizeType | numDofs (const ElementType &element) const |
return number of dofs for given element | |
template<class Entity > | |
SizeType | numEntityDofs (const Entity &entity) const |
return number of dofs for given element | |
void | onSubEntity (const ElementType &element, int i, int c, std::vector< bool > &indices) const |
void | onSubEntity (const ElementType &element, int i, int c, std::vector< char > &indices) const |
template<class Function > | |
void | mapEach (const ElementType &element, Function function) const |
map local dof to global key | |
template<class Entity , class Function > | |
void | mapEachEntityDof (const Entity &entity, Function function) const |
map local dof to global key | |
SizeType | numberOfHoles (const int block) const |
return number of holes during compression | |
GlobalKeyType | oldIndex (const int hole, const int block) const |
return old index of given hole during compression | |
GlobalKeyType | newIndex (const int hole, const int block) const |
return new index of given hole during compression | |
static constexpr bool | contains (const int codim) |
return true if dofs are associated to codimension | |
static constexpr bool | fixedDataSize (int codim) |
return true if number of dofs is fixed for given codimension | |
static constexpr bool | consecutive () |
return true (this mapper yields a consecutive DOF numbering) | |
static constexpr SizeType | oldOffSet (const int block) |
return 0 (this mapper has no offset) | |
static constexpr SizeType | offSet (const int block) |
return 0 (this mapper has no offset) | |
static constexpr SizeType | numBlocks () |
return 1 (this mapper has one block) | |
Detailed Description
template<class GridPart, class LocalKeys>
struct Dune::Fem::hpDG::DiscontinuousGalerkinBlockMapper< GridPart, LocalKeys >
struct Dune::Fem::hpDG::DiscontinuousGalerkinBlockMapper< GridPart, LocalKeys >
An \(hp\)-adaptive Dune::Fem::DofMapper.
- Template Parameters
-
GridPart a Dune::Fem::GridPart type LocalKeys see documentation below
- Note
- The second template parameter is required to provide the following member methods: struct LocalKeys{// type of key// type of datausing DataType = ImplementationDefined;// return maximum number of dofs associated with an entitystd::size_t maxBlocks () const;// return maximum number of dofs for given type and key// map key to data type// map data to key type};Unique label for each type of entities that can occur in DUNE grids.Definition: type.hh:114std::enable_if<(std::is_same< Element, ElementType >::value||std::is_same< Element, GridElementType >::value), constKeyType & >::type key(const Element &element) constget key currently assigned to an entityDefinition: blockmapper.hh:319typename LocalKeysType::KeyType KeyTypekey typeDefinition: blockmapper.hh:120Dummy struct used for documentation purposes.Definition: documentation.hh:42
Member Function Documentation
◆ contains()
|
inlineinherited |
returns true if DoFs for given codimension exist
- Parameters
-
[in] codim codimension to check
- Returns
- true if DoFs for codimension exist
◆ mapEach()
|
inlineinherited |
map each local DoF number to a global key
- Parameters
-
[in] element element, the DoFs belong to [in] f functor to call for each DoF
The functor has to be a copyable object satisfying the following interface:
struct Functor
{
// application operator
template< class GlobalKey >
void operator() ( const int localDoF, const GlobalKey &globalDoF );
};
For each DoF to be mapped, this method will call the application operator once.
- Note
- There is no guarantee on the order, in which the functor is applied.
- The global key has to be compatible with the Dof storage.
◆ mapEachEntityDof()
|
inlineinherited |
map each local DoF number to a global key
- Parameters
-
[in] entity entity, the DoFs belong to [in] f functor to call for each DoF
The functor has to be a copyable object satisfying the following interface:
struct Functor
{
// application operator
template< class GlobalKey >
void operator() ( const int localDoF, const GlobalKey &globalKey );
};
For each DoF to be mapped, this method will call the application operator once.
- Note
- There is no guarantee on the order, in which the functor is applied.
- The global key has to be compatible with the Dof storage.
◆ update()
|
inlineinherited |
update DoF mapping after grid modification
Adaptive DoF mappers are considered to be always up to date and this method does nothing.
The documentation for this struct was generated from the following file:
- dune/fem/space/hpdg/blockmapper.hh
|
Legal Statements / Impressum |
Hosted by TU Dresden |
generated with Hugo v0.111.3
(Nov 12, 23:30, 2024)