element.hh

Go to the documentation of this file.
1 
6 #ifndef elementLin_hh
7 #define elementLin_hh
8 
9 #include <memory>
10 #include "basics/typedefs.hh"
11 #include "space/element.hh"
12 #include "space/tmatrix.hh"
14 
15 namespace concepts {
16  // forward declarations
17  class Connector;
18  class Cell;
19 }
20 
21 namespace linearFEM {
22 
23  using concepts::Real;
24 
25  // *************************************************************** Element **
26 
30  class Element : public concepts::ElementWithCell<Real> {
31  public:
36  Element(const uint i, uint idx[]);
43  virtual const concepts::Connector& support() const = 0;
45  virtual const concepts::Cell& cell() const = 0;
47  virtual const concepts::TMatrixBase<Real>& T() const { return *T_; }
48  protected:
50  std::unique_ptr<concepts::TMatrixBase<Real> > T_;
51  };
52 
53 } // namespace linearFEM
54 
55 namespace concepts {
56 
57  // ************************************************************** Scanners **
58 
59  template<>
61  public concepts::Scan<concepts::Element<Real> > {
62  public:
63  virtual linearFEM::Element& operator++(int) = 0;
64  };
65 }
66 
67 #endif // elementLin_hh
A column of a T matrix.
Definition: analytical.hh:18
An abstract class for an element of a space.
Definition: exceptions.hh:15
virtual linearFEM::Element & operator++(int)=0
Returns the next element in the scanned set.
A cell in a mesh consist of topological information (neighbours, connectivity, orientation) and geome...
Definition: cell.hh:39
virtual const concepts::Cell & cell() const =0
Returns the cell of this element.
Element with cell.
Linear FEM in 1D, 2D and 3D.
Definition: spaceTraits.hh:19
std::unique_ptr< concepts::TMatrixBase< Real > > T_
T matrix of this element.
Definition: element.hh:50
An abstract class for scanning a mesh (a set of cells) or a space (a set of elements).
virtual const concepts::TMatrixBase< Real > & T() const
Returns the T matrix of this element.
Definition: element.hh:47
virtual const concepts::Connector & support() const =0
Returns the support of this element.
Element(const uint i, uint idx[])
Constructor.
Base class for the element for linear FEM.
Definition: element.hh:30
An abstract class for elements of the topology.
Definition: connector.hh:85
double Real
Type normally used for a floating point number.
Definition: typedefs.hh:36
Element(concepts::TColumn< Real > *T0, concepts::TColumn< Real > *T1)
Constructor.
Basic namespace for Concepts-2.
Definition: pml_formula.h:16
Page URL: http://wiki.math.ethz.ch/bin/view/Concepts/WebHome
21 August 2020
© 2020 Eidgenössische Technische Hochschule Zürich