Space for linear FEM in 1D. More...

#include <space1D.hh>

Inheritance diagram for linearFEM::Linear1d:
concepts::Space< Real >

Public Types

typedef concepts::Scan< LineScan
 
typedef Scan< Element< Real > > Scanner
 
typedef void(* SMap) (const concepts::TColumn< Real > &, concepts::TColumn< Real > &)
 
typedef Element< Real > type
 

Public Member Functions

virtual uint dim () const
 
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...
 
 Linear1d (concepts::Mesh1 &msh, uint level, concepts::BoundaryConditions *bc=0)
 Constructor. More...
 
virtual uint nelm () const
 
virtual uint nelm () const=0
 Returns the number of elements in the space. More...
 
virtual Scanscan () const
 
virtual Scannerscan () const=0
 Returns a scanner to iterate over the elements of the space. More...
 
virtual ~Linear1d ()
 

Protected Member Functions

virtual std::ostream & info (std::ostream &os) const
 

Private Member Functions

void constructor_ (concepts::Cell1 &cell, uint level, concepts::DynArray< uint > &dofMap, const concepts::DynArray< uint > &bcMap)
 Assigns the degrees of freedom and creates elements. More...
 
void enforceBC_ (concepts::Cell1 &cell, uint level, concepts::DynArray< uint > &bcMap)
 Notes where Dirichlet boundary conditions have to be enforced. More...
 

Private Attributes

concepts::BoundaryConditionsbc_
 Boundary conditions. More...
 
uint dim_
 Number of degrees of freedom. More...
 
concepts::Joiner< Line *, 1 > * elm_
 List of elements. More...
 
concepts::Mesh1msh_
 Mesh which this space is based on. More...
 
uint nelm_
 Number of elements. More...
 

Detailed Description

Space for linear FEM in 1D.

Author
Philipp Frauenfelder, 2002
Examples
linearFEM1d-simple.cc, and linearFEM1d.cc.

Definition at line 39 of file space1D.hh.

Member Typedef Documentation

◆ Scan

Definition at line 41 of file space1D.hh.

◆ Scanner

typedef Scan<Element<Real > > concepts::Space< Real >::Scanner
inherited

Definition at line 47 of file space.hh.

◆ SMap

typedef void(* linearFEM::Linear1d::SMap) (const concepts::TColumn< Real > &, concepts::TColumn< Real > &)

Definition at line 42 of file space1D.hh.

◆ type

typedef Element<Real > concepts::Space< Real >::type
inherited

Definition at line 46 of file space.hh.

Constructor & Destructor Documentation

◆ Linear1d()

linearFEM::Linear1d::Linear1d ( concepts::Mesh1 msh,
uint  level,
concepts::BoundaryConditions bc = 0 
)

Constructor.

Recursively calls enforceBC_ and constructor_

Parameters
mshMesh
levelNumber levels for initial refinement
bcBoundary conditions

◆ ~Linear1d()

virtual linearFEM::Linear1d::~Linear1d ( )
virtual

Member Function Documentation

◆ constructor_()

void linearFEM::Linear1d::constructor_ ( concepts::Cell1 cell,
uint  level,
concepts::DynArray< uint > &  dofMap,
const concepts::DynArray< uint > &  bcMap 
)
private

Assigns the degrees of freedom and creates elements.

The numbers of the degrees of freedom is stored in dofMap.

constructor_ is called recursively until level is 0. On this level, the degrees of freedom are assigned and the elements are created and stored in elm_.

Parameters
cellCurrent cell
levelNumber of levels left to desired level
dofMapStores assigned dof for the vertices
bcMapStores boundary condition flag for each vertex

◆ dim() [1/2]

virtual uint linearFEM::Linear1d::dim ( ) const
inlinevirtual

Definition at line 52 of file space1D.hh.

◆ dim() [2/2]

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

◆ enforceBC_()

void linearFEM::Linear1d::enforceBC_ ( concepts::Cell1 cell,
uint  level,
concepts::DynArray< uint > &  bcMap 
)
private

Notes where Dirichlet boundary conditions have to be enforced.

This information is stored in bcMap.

enforceBC_ is called recursively until level is 0. On this level, the boundary conditions are checked.

Parameters
cellCurrent cell
levelNumber of levels left to desired level
bcMapStores boundary condition flag for each vertex

◆ 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& linearFEM::Linear1d::info ( std::ostream &  os) const
protectedvirtual

Reimplemented from concepts::Space< Real >.

◆ nelm() [1/2]

virtual uint linearFEM::Linear1d::nelm ( ) const
inlinevirtual

Definition at line 53 of file space1D.hh.

◆ nelm() [2/2]

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

◆ scan() [1/2]

virtual Scan* linearFEM::Linear1d::scan ( ) const
inlinevirtual

Definition at line 54 of file space1D.hh.

◆ scan() [2/2]

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

Member Data Documentation

◆ bc_

concepts::BoundaryConditions* linearFEM::Linear1d::bc_
private

Boundary conditions.

Definition at line 65 of file space1D.hh.

◆ dim_

uint linearFEM::Linear1d::dim_
private

Number of degrees of freedom.

Definition at line 59 of file space1D.hh.

◆ elm_

concepts::Joiner<Line*, 1>* linearFEM::Linear1d::elm_
private

List of elements.

Definition at line 67 of file space1D.hh.

◆ msh_

concepts::Mesh1& linearFEM::Linear1d::msh_
private

Mesh which this space is based on.

Definition at line 63 of file space1D.hh.

◆ nelm_

uint linearFEM::Linear1d::nelm_
private

Number of elements.

Definition at line 61 of file space1D.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