A the NeumannTrace space of a given 3D - Finite Element space. More...

#include <neumannTraceSpace3d.hh>

Inheritance diagram for hp3D::NeumannTraceSpace3d:
concepts::SpaceOnCells< Real > concepts::Space< Real >

Public Types

typedef concepts::Scan< hp2D::Element< Real > > Scan
 
typedef Scan< ElementWithCell< Real > > Scanner
 
typedef ElementWithCell< Real > type
 
typedef concepts::ElementAndFacette< hp3D::Element< Real > > UnderlyingElement
 
typedef concepts::ElementAndFacette< concepts::QuadUnderlyingQuad
 

Public Member Functions

virtual uint dim () const
 Returns the dimension of the underlying Finite Element Space. More...
 
virtual uint dim () const=0
 Returns the dimension of the space. More...
 
virtual uint getOutputDimension () const
 Returns the default output dimension, when we consider plotting a real-valued operator on this space. More...
 
virtual uint nelm () const
 Returns the number of NeumannTraceElements in the Space. More...
 
virtual uint nelm () const=0
 Returns the number of elements in the space. More...
 
 NeumannTraceSpace3d (concepts::SpaceOnCells< Real > &spc, const concepts::FacetteTraceTypes< concepts::FaceNormalVectorRule > &fttypes, bool emptyElm=true)
 Constructor. More...
 
 NeumannTraceSpace3d (const concepts::SpaceOnCells< Real > &spc, const concepts::Set< uint > faceAttr, concepts::FacetteTraceType< concepts::FaceNormalVectorRule >::traceTypes=concepts::FacetteTraceType< concepts::FaceNormalVectorRule >::FIRST, const concepts::FaceNormalVectorRule &normalVectorRule=concepts::FaceNormalVectorRule(), bool emptyElm=true)
 Constructor. More...
 
virtual Scanscan () const
 Returns a scanner to iterate over the elements of the space TODO: why is this not working. More...
 
virtual Scannerscan () const=0
 Returns a scanner to iterate over the elements of the space. More...
 
virtual ~NeumannTraceSpace3d ()
 Deconstructor. More...
 

Protected Member Functions

virtual std::ostream & info (std::ostream &os) const
 Returns the underlying 3D elements of the given edge if existing. More...
 

Private Member Functions

bool activeQuad_ (const concepts::Set< uint > &quadAttr, const concepts::Connector2 &quad)
 
bool buildElements_ (concepts::HashMap< concepts::Sequence< UnderlyingElement > > &uelm, const concepts::BoundaryConditions *bc)
 
void reconstruct_ (concepts::HashMap< concepts::Sequence< UnderlyingElement > > &irregular_uelm, concepts::HashMap< concepts::Sequence< UnderlyingQuad > > &nodeMap, concepts::HashMap< concepts::Sequence< UnderlyingQuad > >::const_iterator iterNode, concepts::Set< uint > &buildedEdges, concepts::HashMap< concepts::Sequence< UnderlyingQuad > > &coarsetochld_map)
 
template<class F >
void test_ (const concepts::ElementWithCell< Real > &elm, F condition)
 Test if not implemented elements have edges w.r.t. More...
 
Real weight_ (bool first, const concepts::Z2 dir, const uint nUelm, const concepts::Attribute attrb) const
 Consider the outwards pointing normalvector evaluations of a neumantrace basis function u. More...
 

Private Attributes

const uint dim_
 Dimension of the FE space. More...
 
concepts::Joiner< hp2D::Element< Real > *, 1 > * elm_
 Linked list of the elements. More...
 
bool emptyElements_
 
uint nelm_
 Number of elements currently active in the mesh. More...
 
concepts::HashMap< hp3D::NeumannTraceElement3d< Real > * > quads_
 Map from key of (topological) quad to the element. More...
 
concepts::FacetteTraceTypes< concepts::FaceNormalVectorRuletrTypes_
 Mapping from Attributes to a given EdgeTracetype. More...
 

Detailed Description

A the NeumannTrace space of a given 3D - Finite Element space.

The elements are from type hp3D::Face.

One can restrict the trace operation by EdgeTraceTypes or via Attributes and a EdgeNormalVectorRule.

If the FE space is rebuild, one has to construct the NeumannTraceSpace again.

Additonally a map from the topological edge to the set of the underlying elements is stored.

Author
Gruhlke, Robert, 2013, Goette, Michael 2015

Definition at line 61 of file neumannTraceSpace3d.hh.

Member Typedef Documentation

◆ Scan

◆ Scanner

typedef Scan<ElementWithCell<Real > > concepts::SpaceOnCells< Real >::Scanner
inherited

Definition at line 84 of file space.hh.

◆ type

typedef ElementWithCell<Real > concepts::SpaceOnCells< Real >::type
inherited

Definition at line 83 of file space.hh.

◆ UnderlyingElement

◆ UnderlyingQuad

Constructor & Destructor Documentation

◆ NeumannTraceSpace3d() [1/2]

hp3D::NeumannTraceSpace3d::NeumannTraceSpace3d ( const concepts::SpaceOnCells< Real > &  spc,
const concepts::Set< uint >  faceAttr,
concepts::FacetteTraceType< concepts::FaceNormalVectorRule >::traceTypes  = concepts::FacetteTraceTypeconcepts::FaceNormalVectorRule >::FIRST,
const concepts::FaceNormalVectorRule normalVectorRule = concepts::FaceNormalVectorRule(),
bool  emptyElm = true 
)

Constructor.

This builds a NeumannTraceSpace only for edges with attributes that are requested.

The EdgeTraceType can be FIRST, MEAN, JUMP or PLUS and MINUS. Since the EdgeNormalVectorRule in a sense is constant for all requested edges, you have to think about the Meaning of these Traces then, since they are also defined with the help of the first underlying Element. Alternativly one uses the second Constructor.

This Constructor may easy applicate for Boundary Elements with a FIRST neumanntrace, since these elements only have up to one underlying Element.

Additional a Flag for empty Elements is given, that controls the build up of Elements with no degrees of freedoms on it. This might be used for graphical Output.

@param spc underlying Finite Element Space
@param edgeAttr  set of requested edge attributes
@param traceTypes the type of NeumannTrace, i.e. FIRST,MEAN,JUMP,PLUS,MINUS
@param normalVectorRule Given rule for the Normalvector behaviour
@param emptyElm Flag to control build of empty Elements

◆ NeumannTraceSpace3d() [2/2]

hp3D::NeumannTraceSpace3d::NeumannTraceSpace3d ( concepts::SpaceOnCells< Real > &  spc,
const concepts::FacetteTraceTypes< concepts::FaceNormalVectorRule > &  fttypes,
bool  emptyElm = true 
)

Constructor.

This builds a NeumannTraceSpace for edgesthat are requested in the EdgeTraceTypes semantic.

The EdgeTraceType can be FIRST, MEAN, JUMP or PLUS and MINUS for different edges with different attributes. In opposite to the first constructor the EdgeNormalVectorRule is not constant, since they can vary for each Attribute. This is controlled with the EdgeTraceTypes variable.

This constructor may is the choice when building a NeumannTraceSpace on a Finite Element Space with different material attributes.

Additional a Flag for empty Elements is given, that controls the build up of Elements with no degrees of freedoms on it. This might be used for graphical Output.

@param spc underlying Finite Element Space
@param edgeAttr  set of requested edge attributes
@param traceTypes the type of NeumannTrace, i.e. FIRST,MEAN,JUMP,PLUS,MINUS
@param normalVectorRule Given rule for the Normalvector behaviour
@param emptyElm Flag to control build of empty Elements

◆ ~NeumannTraceSpace3d()

virtual hp3D::NeumannTraceSpace3d::~NeumannTraceSpace3d ( )
virtual

Deconstructor.

Member Function Documentation

◆ activeQuad_()

bool hp3D::NeumannTraceSpace3d::activeQuad_ ( const concepts::Set< uint > &  quadAttr,
const concepts::Connector2 quad 
)
inlineprivate

Definition at line 294 of file neumannTraceSpace3d.hh.

◆ buildElements_()

bool hp3D::NeumannTraceSpace3d::buildElements_ ( concepts::HashMap< concepts::Sequence< UnderlyingElement > > &  uelm,
const concepts::BoundaryConditions bc 
)
private

◆ dim() [1/2]

virtual uint hp3D::NeumannTraceSpace3d::dim ( ) const
inlinevirtual

Returns the dimension of the underlying Finite Element Space.

Definition at line 193 of file neumannTraceSpace3d.hh.

◆ dim() [2/2]

virtual uint concepts::SpaceOnCells< Real >::dim ( ) const
pure virtualinherited

◆ getOutputDimension()

virtual uint concepts::Space< Real >::getOutputDimension ( ) const
inlinevirtualinherited

Returns the default output dimension, when we consider plotting a real-valued operator on this space.

Definition at line 50 of file space.hh.

◆ info()

virtual std::ostream& hp3D::NeumannTraceSpace3d::info ( std::ostream &  os) const
protectedvirtual

Returns the underlying 3D elements of the given edge if existing.

Recompute shape functions, e.g. for other abscissas redefined through setIntegrationRule

Reimplemented from concepts::SpaceOnCells< Real >.

◆ nelm() [1/2]

virtual uint hp3D::NeumannTraceSpace3d::nelm ( ) const
inlinevirtual

Returns the number of NeumannTraceElements in the Space.

Definition at line 198 of file neumannTraceSpace3d.hh.

◆ nelm() [2/2]

virtual uint concepts::SpaceOnCells< Real >::nelm ( ) const
pure virtualinherited

Returns the number of elements in the space.

Implements concepts::Space< Real >.

Implemented in hp2D::hpAdaptiveSpace< Real >, hp3D::Space, hp2Dedge::Space, hp2D::Space, hp2D::hpAdaptiveSpace< Real >, and hp1D::Space.

◆ reconstruct_()

void hp3D::NeumannTraceSpace3d::reconstruct_ ( concepts::HashMap< concepts::Sequence< UnderlyingElement > > &  irregular_uelm,
concepts::HashMap< concepts::Sequence< UnderlyingQuad > > &  nodeMap,
concepts::HashMap< concepts::Sequence< UnderlyingQuad > >::const_iterator  iterNode,
concepts::Set< uint > &  buildedEdges,
concepts::HashMap< concepts::Sequence< UnderlyingQuad > > &  coarsetochld_map 
)
private

◆ scan() [1/2]

virtual Scan* hp3D::NeumannTraceSpace3d::scan ( ) const
inlinevirtual

Returns a scanner to iterate over the elements of the space TODO: why is this not working.

Definition at line 203 of file neumannTraceSpace3d.hh.

◆ scan() [2/2]

virtual Scanner* concepts::SpaceOnCells< Real >::scan ( ) const
pure virtualinherited

Returns a scanner to iterate over the elements of the space.

Implements concepts::Space< Real >.

Implemented in hp2D::hpAdaptiveSpace< Real >, hp3D::Space, hp2Dedge::Space, hp2D::Space, hp2D::hpAdaptiveSpace< Real >, and hp1D::Space.

◆ test_()

template<class F >
void hp3D::NeumannTraceSpace3d::test_ ( const concepts::ElementWithCell< Real > &  elm,
condition 
)
private

Test if not implemented elements have edges w.r.t.

to condition and throws an exception in that case.

◆ weight_()

Real hp3D::NeumannTraceSpace3d::weight_ ( bool  first,
const concepts::Z2  dir,
const uint  nUelm,
const concepts::Attribute  attrb 
) const
private

Consider the outwards pointing normalvector evaluations of a neumantrace basis function u.

The defintion of the normalvector n above, introduce K+ and K- and therefore normal traces: n * grad(u+) and n * grad(u-)

Parameters
pos0 if first underlying element, 1 if second
dir0 if underlying element is K-, 1 if K+
nUelm
Precondition
nUelm is either 1 or 2. number of underlying elements
Parameters
attrbAttribute of the current cell, to access EdgeTraceType information.

Member Data Documentation

◆ dim_

const uint hp3D::NeumannTraceSpace3d::dim_
private

Dimension of the FE space.

Definition at line 228 of file neumannTraceSpace3d.hh.

◆ elm_

concepts::Joiner<hp2D::Element<Real>*, 1>* hp3D::NeumannTraceSpace3d::elm_
private

Linked list of the elements.

Definition at line 239 of file neumannTraceSpace3d.hh.

◆ emptyElements_

bool hp3D::NeumannTraceSpace3d::emptyElements_
private

Definition at line 252 of file neumannTraceSpace3d.hh.

◆ nelm_

uint hp3D::NeumannTraceSpace3d::nelm_
private

Number of elements currently active in the mesh.

Definition at line 231 of file neumannTraceSpace3d.hh.

◆ quads_

concepts::HashMap<hp3D::NeumannTraceElement3d<Real>* > hp3D::NeumannTraceSpace3d::quads_
private

Map from key of (topological) quad to the element.

Definition at line 242 of file neumannTraceSpace3d.hh.

◆ trTypes_

concepts::FacetteTraceTypes<concepts::FaceNormalVectorRule> hp3D::NeumannTraceSpace3d::trTypes_
private

Mapping from Attributes to a given EdgeTracetype.

This controlls the NeumannTraces indeed.

Definition at line 249 of file neumannTraceSpace3d.hh.


The documentation for this class was generated from the following file:
Page URL: http://wiki.math.ethz.ch/bin/view/Concepts/WebHome
21 August 2020
© 2020 Eidgenössische Technische Hochschule Zürich