DUNE LocalFunctions (2.9)

edges0.5.hh
1// -*- tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*-
2// vi: set et ts=4 sw=2 sts=2:
3// SPDX-FileCopyrightInfo: Copyright (C) DUNE Project contributors, see file LICENSE.md in module root
4// SPDX-License-Identifier: LicenseRef-GPL-2.0-only-with-DUNE-exception
5
6#ifndef DUNE_LOCALFUNCTIONS_WHITNEY_EDGES0_5_HH
7#define DUNE_LOCALFUNCTIONS_WHITNEY_EDGES0_5_HH
8
9#include <dune/geometry/type.hh>
10
11#include <dune/localfunctions/whitney/edges0.5/basis.hh>
12#include <dune/localfunctions/whitney/edges0.5/coefficients.hh>
13#include <dune/localfunctions/whitney/edges0.5/interpolation.hh>
14
15namespace Dune {
16
18 //
19 // FiniteElement
20 //
21
23
41 template<class Geometry, class RF>
43 public:
47 struct Traits {
48 typedef EdgeS0_5Basis<Geometry, RF> Basis;
49 typedef EdgeS0_5Interpolation<Geometry,
50 typename Basis::Traits> Interpolation;
52 };
53
54 private:
55 typename Traits::Basis basis_;
56 typename Traits::Interpolation interpolation_;
57 static const typename Traits::Coefficients& coefficients_;
58
59 public:
61
64 template<class VertexOrder>
65 EdgeS0_5FiniteElement(const Geometry& geo,
66 const VertexOrder& vertexOrder) :
67 basis_(geo, vertexOrder), interpolation_(geo, vertexOrder)
68 { }
69
71 const typename Traits::Basis& basis() const { return basis_; }
73 const typename Traits::Interpolation& interpolation() const
74 { return interpolation_; }
76 const typename Traits::Coefficients& coefficients() const
77 { return coefficients_; }
79 static constexpr GeometryType type() { return GeometryTypes::simplex(Geometry::mydimension); }
80 };
81
82 template<class Geometry, class RF>
83 const typename EdgeS0_5FiniteElement<Geometry, RF>::Traits::Coefficients&
84 EdgeS0_5FiniteElement<Geometry, RF>::coefficients_ =
85 typename Traits::Coefficients();
86
88 //
89 // Factory
90 //
91
93
102 template<class Geometry, class RF>
105
107
121 template<class VertexOrder>
122 const FiniteElement make(const Geometry& geometry,
123 const VertexOrder& vertexOrder)
124 { return FiniteElement(geometry, vertexOrder); }
125 };
126
127} // namespace Dune
128
129#endif // DUNE_LOCALFUNCTIONS_WHITNEY_EDGES0_5_HH
Basis for order 0.5 (lowest order) edge elements on simplices.
Definition: basis.hh:38
Coefficients for lowest order edge elements on simplices.
Definition: coefficients.hh:30
FiniteElement for lowest order edge elements on simplices.
Definition: edges0.5.hh:42
EdgeS0_5FiniteElement(const Geometry &geo, const VertexOrder &vertexOrder)
Constructor.
Definition: edges0.5.hh:65
static constexpr GeometryType type()
return geometry type of this element
Definition: edges0.5.hh:79
const Traits::Basis & basis() const
return reference to the basis object
Definition: edges0.5.hh:71
const Traits::Interpolation & interpolation() const
return reference to the interpolation object
Definition: edges0.5.hh:73
const Traits::Coefficients & coefficients() const
return reference to the coefficients object
Definition: edges0.5.hh:76
Interpolation for lowest order edge elements on simplices.
Definition: interpolation.hh:33
ImplementationDefined FiniteElement
Type of the finite element.
Definition: interface.hh:126
Factory for EdgeS0_5FiniteElement objects.
Definition: edges0.5.hh:103
const FiniteElement make(const Geometry &geometry, const VertexOrder &vertexOrder)
construct the factory
Definition: edges0.5.hh:122
Creative Commons License   |  Legal Statements / Impressum  |  Hosted by TU Dresden & Uni Heidelberg  |  generated with Hugo v0.111.3 (May 27, 22:36, 2026)