Reference documentation for deal.II version 9.4.1
\(\newcommand{\dealvcentcolon}{\mathrel{\mathop{:}}}\) \(\newcommand{\dealcoloneq}{\dealvcentcolon\mathrel{\mkern-1.2mu}=}\) \(\newcommand{\jump}[1]{\left[\!\left[ #1 \right]\!\right]}\) \(\newcommand{\average}[1]{\left\{\!\left\{ #1 \right\}\!\right\}}\)
Loading...
Searching...
No Matches
fe_nedelec_sz.h
Go to the documentation of this file.
1// ---------------------------------------------------------------------
2//
3// Copyright (C) 2015 - 2022 by the deal.II authors
4//
5// This file is part of the deal.II library.
6//
7// The deal.II library is free software; you can use it, redistribute
8// it, and/or modify it under the terms of the GNU Lesser General
9// Public License as published by the Free Software Foundation; either
10// version 2.1 of the License, or (at your option) any later version.
11// The full text of the license can be found in the file LICENSE.md at
12// the top level directory of deal.II.
13//
14// ---------------------------------------------------------------------
15
16#ifndef dealii_fe_nedelec_sz_h
17#define dealii_fe_nedelec_sz_h
18
19#include <deal.II/base/config.h>
20
24
25#include <deal.II/fe/fe.h>
27#include <deal.II/fe/mapping.h>
28
30
33
72template <int dim, int spacedim = dim>
73class FE_NedelecSZ : public FiniteElement<dim, dim>
74{
75public:
76 static_assert(dim == spacedim,
77 "FE_NedelecSZ is only implemented for dim==spacedim!");
78
93 FE_NedelecSZ(const unsigned int order);
94
95 virtual UpdateFlags
96 requires_update_flags(const UpdateFlags update_flags) const override;
97
98 virtual std::string
99 get_name() const override;
100
101 virtual std::unique_ptr<FiniteElement<dim, dim>>
102 clone() const override;
103
108 virtual double
109 shape_value(const unsigned int i, const Point<dim> &p) const override;
110
114 virtual double
115 shape_value_component(const unsigned int i,
116 const Point<dim> & p,
117 const unsigned int component) const override;
118
123 virtual Tensor<1, dim>
124 shape_grad(const unsigned int i, const Point<dim> &p) const override;
125
129 virtual Tensor<1, dim>
130 shape_grad_component(const unsigned int i,
131 const Point<dim> & p,
132 const unsigned int component) const override;
133
138 virtual Tensor<2, dim>
139 shape_grad_grad(const unsigned int i, const Point<dim> &p) const override;
140
144 virtual Tensor<2, dim>
145 shape_grad_grad_component(const unsigned int i,
146 const Point<dim> & p,
147 const unsigned int component) const override;
148
149protected:
155
156 virtual std::unique_ptr<
157 typename ::FiniteElement<dim, spacedim>::InternalDataBase>
158 get_data(
159 const UpdateFlags update_flags,
160 const Mapping<dim, spacedim> &mapping,
161 const Quadrature<dim> & quadrature,
163 spacedim>
164 &output_data) const override;
165
171 virtual void
173 const typename Triangulation<dim, dim>::cell_iterator &cell,
174 const CellSimilarity::Similarity cell_similarity,
175 const Quadrature<dim> & quadrature,
176 const Mapping<dim, dim> & mapping,
177 const typename Mapping<dim, dim>::InternalDataBase & mapping_internal,
178 const ::internal::FEValuesImplementation::MappingRelatedData<dim, dim>
179 & mapping_data,
180 const typename FiniteElement<dim, dim>::InternalDataBase &fedata,
182 &data) const override;
183
184 using FiniteElement<dim, spacedim>::fill_fe_face_values;
185
191 virtual void
193 const typename Triangulation<dim, dim>::cell_iterator &cell,
194 const unsigned int face_no,
195 const hp::QCollection<dim - 1> & quadrature,
196 const Mapping<dim, dim> & mapping,
197 const typename Mapping<dim, dim>::InternalDataBase & mapping_internal,
198 const ::internal::FEValuesImplementation::MappingRelatedData<dim, dim>
199 & mapping_data,
200 const typename FiniteElement<dim, dim>::InternalDataBase &fedata,
202 &data) const override;
203
207 virtual void
209 const typename Triangulation<dim, dim>::cell_iterator &cell,
210 const unsigned int face_no,
211 const unsigned int sub_no,
212 const Quadrature<dim - 1> & quadrature,
213 const Mapping<dim, dim> & mapping,
214 const typename Mapping<dim, dim>::InternalDataBase & mapping_internal,
215 const ::internal::FEValuesImplementation::MappingRelatedData<dim, dim>
216 & mapping_data,
217 const typename FiniteElement<dim, dim>::InternalDataBase &fedata,
219 &data) const override;
220
241 {
242 public:
249 mutable std::vector<std::vector<Tensor<1, dim>>> shape_values;
250
258 mutable std::vector<std::vector<DerivativeForm<1, dim, dim>>> shape_grads;
259
267 mutable std::vector<std::vector<DerivativeForm<2, dim, dim>>>
269
285 std::vector<std::vector<std::vector<double>>> sigma_imj_values;
286
302 std::vector<std::vector<std::vector<double>>> sigma_imj_grads;
303
315 std::vector<std::vector<double>> edge_sigma_values;
316
328 std::vector<std::vector<double>> edge_sigma_grads;
329
345 std::vector<std::vector<double>> edge_lambda_values;
346
356 std::vector<std::vector<double>> edge_lambda_grads_2d;
357
367 std::vector<std::vector<std::vector<double>>> edge_lambda_grads_3d;
368
379 std::vector<std::vector<std::vector<double>>> edge_lambda_gradgrads_3d;
380
397 std::vector<std::vector<double>> face_lambda_values;
398
407 std::vector<std::vector<double>> face_lambda_grads;
408 };
409
410private:
419 static std::vector<unsigned int>
420 get_dpo_vector(const unsigned int degree);
421
425 std::vector<Polynomials::Polynomial<double>> IntegratedLegendrePolynomials;
426
431 void
432 create_polynomials(const unsigned int degree);
433
437 unsigned int
438 compute_num_dofs(const unsigned int degree) const;
439
444 void
446 const Quadrature<dim> &quadrature,
447 const InternalData & fedata) const;
448
453 void
455 const Quadrature<dim> &quadrature,
456 const InternalData & fedata) const;
457};
458
459
460
464
465#endif
std::vector< std::vector< double > > edge_lambda_grads_2d
std::vector< std::vector< Tensor< 1, dim > > > shape_values
std::vector< std::vector< std::vector< double > > > sigma_imj_values
std::vector< std::vector< double > > edge_sigma_grads
std::vector< std::vector< double > > edge_sigma_values
std::vector< std::vector< DerivativeForm< 2, dim, dim > > > shape_hessians
std::vector< std::vector< std::vector< double > > > sigma_imj_grads
std::vector< std::vector< double > > face_lambda_values
std::vector< std::vector< DerivativeForm< 1, dim, dim > > > shape_grads
std::vector< std::vector< std::vector< double > > > edge_lambda_grads_3d
std::vector< std::vector< double > > edge_lambda_values
std::vector< std::vector< std::vector< double > > > edge_lambda_gradgrads_3d
std::vector< std::vector< double > > face_lambda_grads
virtual void fill_fe_values(const typename Triangulation< dim, dim >::cell_iterator &cell, const CellSimilarity::Similarity cell_similarity, const Quadrature< dim > &quadrature, const Mapping< dim, dim > &mapping, const typename Mapping< dim, dim >::InternalDataBase &mapping_internal, const ::internal::FEValuesImplementation::MappingRelatedData< dim, dim > &mapping_data, const typename FiniteElement< dim, dim >::InternalDataBase &fedata, ::internal::FEValuesImplementation::FiniteElementRelatedData< dim, dim > &data) const override
unsigned int compute_num_dofs(const unsigned int degree) const
virtual std::unique_ptr< FiniteElement< dim, dim > > clone() const override
virtual void fill_fe_face_values(const typename Triangulation< dim, dim >::cell_iterator &cell, const unsigned int face_no, const hp::QCollection< dim - 1 > &quadrature, const Mapping< dim, dim > &mapping, const typename Mapping< dim, dim >::InternalDataBase &mapping_internal, const ::internal::FEValuesImplementation::MappingRelatedData< dim, dim > &mapping_data, const typename FiniteElement< dim, dim >::InternalDataBase &fedata, ::internal::FEValuesImplementation::FiniteElementRelatedData< dim, dim > &data) const override
virtual UpdateFlags requires_update_flags(const UpdateFlags update_flags) const override
static std::vector< unsigned int > get_dpo_vector(const unsigned int degree)
virtual void fill_fe_subface_values(const typename Triangulation< dim, dim >::cell_iterator &cell, const unsigned int face_no, const unsigned int sub_no, const Quadrature< dim - 1 > &quadrature, const Mapping< dim, dim > &mapping, const typename Mapping< dim, dim >::InternalDataBase &mapping_internal, const ::internal::FEValuesImplementation::MappingRelatedData< dim, dim > &mapping_data, const typename FiniteElement< dim, dim >::InternalDataBase &fedata, ::internal::FEValuesImplementation::FiniteElementRelatedData< dim, dim > &data) const override
void create_polynomials(const unsigned int degree)
virtual std::unique_ptr< typename ::FiniteElement< dim, spacedim >::InternalDataBase > get_data(const UpdateFlags update_flags, const Mapping< dim, spacedim > &mapping, const Quadrature< dim > &quadrature, ::internal::FEValuesImplementation::FiniteElementRelatedData< dim, spacedim > &output_data) const override
virtual std::string get_name() const override
virtual Tensor< 2, dim > shape_grad_grad_component(const unsigned int i, const Point< dim > &p, const unsigned int component) const override
virtual Tensor< 1, dim > shape_grad_component(const unsigned int i, const Point< dim > &p, const unsigned int component) const override
virtual Tensor< 1, dim > shape_grad(const unsigned int i, const Point< dim > &p) const override
std::vector< Polynomials::Polynomial< double > > IntegratedLegendrePolynomials
virtual Tensor< 2, dim > shape_grad_grad(const unsigned int i, const Point< dim > &p) const override
virtual double shape_value_component(const unsigned int i, const Point< dim > &p, const unsigned int component) const override
void fill_face_values(const typename Triangulation< dim, dim >::cell_iterator &cell, const Quadrature< dim > &quadrature, const InternalData &fedata) const
void fill_edge_values(const typename Triangulation< dim, dim >::cell_iterator &cell, const Quadrature< dim > &quadrature, const InternalData &fedata) const
MappingKind mapping_kind
virtual double shape_value(const unsigned int i, const Point< dim > &p) const override
const unsigned int degree
Definition: fe_data.h:449
friend class InternalDataBase
Definition: fe.h:3075
Abstract base class for mapping classes.
Definition: mapping.h:311
Definition: point.h:111
Definition: tensor.h:503
#define DEAL_II_NAMESPACE_OPEN
Definition: config.h:442
#define DEAL_II_NAMESPACE_CLOSE
Definition: config.h:443
UpdateFlags
MappingKind
Definition: mapping.h:72