1#ifndef DUNE_FEM_SPACE_PADAPTIVE_GENERIC_HH
2#define DUNE_FEM_SPACE_PADAPTIVE_GENERIC_HH
8#include <dune/common/math.hh>
40 template<
class Traits >
110 const InterfaceType commInterface,
111 const CommunicationDirection commDirection )
147 inline bool continuous ()
const {
return Traits::continuousSpace; }
207 template<
class EntityType >
265 return blockMapper().suggestPolynomOrder( entity );
285 template<
class DiscreteFunctionSpace,
class Implementation >
298 typedef std::vector< typename BaseType::RangeFieldType > TmpDofVectorType;
299 TmpDofVectorType tmpVector( oldSpace.size() );
305 IntermediateStorageFunctionType tmp(
"padapt-temp", oldSpace, tmpVector );
326 const std::vector< GeometryType > &geometryTypes
329 for(
unsigned int i = 0; i < geometryTypes.size(); ++i )
366 template<
class Traits >
382 static void apply (
const int maxOrder,
383 std::vector< ScalarShapeFunctionSetStorageType > &scalarShapeFunctionSets,
384 std::vector< LocalKeyStorageType > &compiledLocalKeys,
385 const GeometryType &
type )
388 if( pOrd > maxOrder ) return ;
392 scalarShapeFunctionSets[ pOrd ].template insert< SingletonProviderType >(
type );
395 compiledLocalKeys[ pOrd ].template insert< CompiledLocalKeySingletonProviderType >(
type );
Provides a proxy class for pointers to a shape function set.
DFSpaceIdentifier
enumerator for identification of spaces
Definition: discretefunctionspace.hh:94
@ GenericSpace_id
id for Generic Space
Definition: discretefunctionspace.hh:100
void enlargeMemory()
resize the MemObject if necessary
Definition: dofmanager.hh:1015
void resize()
Resize index sets and memory due to what the mapper has as new size.
Definition: dofmanager.hh:983
void compress()
Compress all data that is hold by this dofmanager.
Definition: dofmanager.hh:1038
Definition: bindguard.hh:11
static DUNE_PRIVATE void apply(Args &&... args)
Definition: forloop.hh:23
Definition: vectorfunction/vectorfunction.hh:42
default implementation uses method geomTypes of given index set. Used in DiscreteFunctionSpaces.
Definition: allgeomtypes.hh:99
const std ::vector< GeometryType > & geomTypes(unsigned int codim) const
returns vector with geometry tpyes this index set has indices for
Definition: allgeomtypes.hh:171
Abstract definition of the local restriction and prolongation of discrete functions.
Definition: dataprojection/dataprojection.hh:29
const DiscreteFunctionSpaceType & asImp() const
Definition: discretefunctionspace.hh:576
Traits::FunctionSpaceType FunctionSpaceType
type of function space
Definition: discretefunctionspace.hh:193
Traits::BasisFunctionSetType BasisFunctionSetType
type of basis function set of this space
Definition: discretefunctionspace.hh:200
GridPartType::IntersectionType IntersectionType
type of the intersections
Definition: discretefunctionspace.hh:225
This is the class with default implementations for discrete function. The methods not marked with hav...
Definition: discretefunctionspace.hh:628
const InterfaceType commInterface_
Definition: discretefunctionspace.hh:698
BaseType::EntityType EntityType
Definition: discretefunctionspace.hh:644
BaseType::BlockMapperType BlockMapperType
Definition: discretefunctionspace.hh:660
BaseType::GridPartType GridPartType
Definition: discretefunctionspace.hh:640
BaseType::IndexSetType IndexSetType
Definition: discretefunctionspace.hh:642
Traits::DiscreteFunctionSpaceType DiscreteFunctionSpaceType
Definition: discretefunctionspace.hh:638
GridPartType & gridPart_
Definition: discretefunctionspace.hh:679
const IndexSetType & indexSet() const
Get a reference to the associated index set.
Definition: discretefunctionspace.hh:751
DofManagerType & dofManager_
Definition: discretefunctionspace.hh:695
BaseType::IteratorType IteratorType
Definition: discretefunctionspace.hh:643
GridPartType & gridPart() const
Definition: discretefunctionspace.hh:745
BaseType::GridType GridType
Definition: discretefunctionspace.hh:641
const CommunicationDirection commDirection_
Definition: discretefunctionspace.hh:699
Traits Traits
Definition: discretefunctionspace.hh:630
Definition: space/mapper/capabilities.hh:22
Please doc me.
Definition: padaptivespace/generic.hh:43
KeyType getMark(const EntityType &entity) const
get key to be assigned to an entity after next call to adapt()
Definition: padaptivespace/generic.hh:263
BlockMapperType & blockMapper() const
get a reference to the block mapper
Definition: padaptivespace/generic.hh:162
static const int polynomialOrder
maximal available polynomial order
Definition: padaptivespace/generic.hh:66
std::vector< LocalKeyStorageType > compiledLocalKeys_
Definition: padaptivespace/generic.hh:355
const int order_
Definition: padaptivespace/generic.hh:350
BasisFunctionSetType basisFunctionSet(const EntityType &entity) const
get basis function set for given entity
Definition: padaptivespace/generic.hh:141
ShapeFunctionSetType shapeFunctionSet(const GeometryType &type, const int order=polynomialOrder) const
return shape unique function set for geometry type
Definition: padaptivespace/generic.hh:193
BaseType::IndexSetType IndexSetType
Definition: padaptivespace/generic.hh:55
void adapt(DataProjection< DiscreteFunctionSpace, Implementation > &projection)
Definition: padaptivespace/generic.hh:286
bool continuous() const
returns true if the space contains only globally continuous functions
Definition: padaptivespace/generic.hh:147
std::vector< ScalarShapeFunctionSetStorageType > scalarShapeFunctionSets_
Definition: padaptivespace/generic.hh:353
const CompiledLocalKeyType & compiledLocalKey(const GeometryType type, const int order=polynomialOrder) const
provide access to the compiled local keys for a geometry type and polynomial order
Definition: padaptivespace/generic.hh:223
Traits::ShapeFunctionSetType ShapeFunctionSetType
Definition: padaptivespace/generic.hh:60
BaseType::GridPartType GridPartType
Definition: padaptivespace/generic.hh:53
BaseType::GridType GridType
Definition: padaptivespace/generic.hh:54
GenericDiscreteFunctionSpace(const GenericDiscreteFunctionSpace &other)
Definition: padaptivespace/generic.hh:123
BaseType::FunctionSpaceType FunctionSpaceType
Definition: padaptivespace/generic.hh:51
ShapeFunctionSetType shapeFunctionSet(const EntityType &entity) const
return shape function set for given entity
Definition: padaptivespace/generic.hh:180
BaseType::IntersectionType IntersectionType
Definition: padaptivespace/generic.hh:58
int KeyType
Definition: padaptivespace/generic.hh:92
KeyType key(const EntityType &entity) const
get identifiying basis function set key assigned to given entity
Definition: padaptivespace/generic.hh:242
bool multipleBaseFunctionSets() const
this space has more than one base function set
Definition: padaptivespace/generic.hh:159
BaseType::BasisFunctionSetType BasisFunctionSetType
Definition: padaptivespace/generic.hh:61
BaseType::DiscreteFunctionSpaceType DiscreteFunctionSpaceType
Definition: padaptivespace/generic.hh:49
void adapt()
p adaptation
Definition: padaptivespace/generic.hh:274
void mark(const KeyType &key, const EntityType &entity)
assign new key to given entity
Definition: padaptivespace/generic.hh:252
BaseType::IteratorType IteratorType
Definition: padaptivespace/generic.hh:56
std::unique_ptr< BlockMapperType > blockMapper_
Definition: padaptivespace/generic.hh:358
GenericDiscreteFunctionSpace(GridPartType &gridPart, const int order, const InterfaceType commInterface, const CommunicationDirection commDirection)
constructor
Definition: padaptivespace/generic.hh:108
BaseType::BlockMapperType BlockMapperType
Definition: padaptivespace/generic.hh:63
DFSpaceIdentifier type() const
return type identifier of discrete function space
Definition: padaptivespace/generic.hh:138
int IdentifierType
type of identifier for this discrete function space
Definition: padaptivespace/generic.hh:95
int order(const typename BaseType::EntityType &entity) const
get global order of space
Definition: padaptivespace/generic.hh:153
Traits::CompiledLocalKeyType CompiledLocalKeyType
Definition: padaptivespace/generic.hh:88
const CompiledLocalKeyType & compiledLocalKey(const EntityType &entity) const
provide access to the compiled local keys for an entity
Definition: padaptivespace/generic.hh:208
BlockMapperType * initialize(const BlockMapperType *otherMapper=0)
Definition: padaptivespace/generic.hh:321
Traits::ScalarShapeFunctionSetType ScalarShapeFunctionSetType
Definition: padaptivespace/generic.hh:70
ThisType GenericDiscreteFunctionSpaceType
Definition: padaptivespace/generic.hh:48
BaseSetLocalKeyStorage< ScalarShapeFunctionSetType > ScalarShapeFunctionSetStorageType
Definition: padaptivespace/generic.hh:72
BaseSetLocalKeyStorage< CompiledLocalKeyType > LocalKeyStorageType
Definition: padaptivespace/generic.hh:89
IteratorType::Entity EntityType
Definition: padaptivespace/generic.hh:57
int order() const
get global order of space
Definition: padaptivespace/generic.hh:150
Definition: padaptivespace/generic.hh:76
Traits::template ScalarShapeFunctionSetFactory< pOrd >::Type Type
Definition: padaptivespace/generic.hh:77
Definition: padaptivespace/generic.hh:369
static void apply(const int maxOrder, std::vector< ScalarShapeFunctionSetStorageType > &scalarShapeFunctionSets, std::vector< LocalKeyStorageType > &compiledLocalKeys, const GeometryType &type)
Definition: padaptivespace/generic.hh:382
Definition: padaptivespace/generic.hh:371
static CompiledLocalKeyType * createObject(const GeometryType &type)
Definition: padaptivespace/generic.hh:372
static void deleteObject(CompiledLocalKeyType *obj)
Definition: padaptivespace/generic.hh:376
Singleton list for key/object pairs.
Definition: singletonlist.hh:53