Reference documentation for deal.II version Git ede8f93e86 2020-12-03 14:59:20 -0700
\(\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\}}\)
fe_q_base.h
Go to the documentation of this file.
1 // ---------------------------------------------------------------------
2 //
3 // Copyright (C) 2000 - 2019 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_q_base_h
17 #define dealii_fe_q_base_h
18 
19 #include <deal.II/base/config.h>
20 
22 
23 #include <deal.II/fe/fe_poly.h>
24 
26 
27 
30 
37 template <class PolynomialType,
38  int dim = PolynomialType::dimension,
39  int spacedim = dim>
40 class FE_Q_Base : public FE_Poly<dim, spacedim>
41 {
42 public:
46  FE_Q_Base(const PolynomialType & poly_space,
47  const FiniteElementData<dim> &fe_data,
48  const std::vector<bool> & restriction_is_additive_flags);
49 
59  virtual void
61  FullMatrix<double> &matrix) const override;
62 
63 
73  virtual void
75  FullMatrix<double> & matrix,
76  const unsigned int face_no = 0) const override;
77 
87  virtual void
89  const FiniteElement<dim, spacedim> &source,
90  const unsigned int subface,
91  FullMatrix<double> & matrix,
92  const unsigned int face_no = 0) const override;
93 
98  virtual bool
99  has_support_on_face(const unsigned int shape_index,
100  const unsigned int face_index) const override;
101 
124  virtual const FullMatrix<double> &
126  const unsigned int child,
127  const RefinementCase<dim> &refinement_case =
129 
156  virtual const FullMatrix<double> &
158  const unsigned int child,
159  const RefinementCase<dim> &refinement_case =
161 
200  virtual unsigned int
201  face_to_cell_index(const unsigned int face_dof_index,
202  const unsigned int face,
203  const bool face_orientation = true,
204  const bool face_flip = false,
205  const bool face_rotation = false) const override;
206 
211  virtual std::pair<Table<2, bool>, std::vector<unsigned int>>
212  get_constant_modes() const override;
213 
227  virtual bool
228  hp_constraints_are_implemented() const override;
229 
245  virtual std::vector<std::pair<unsigned int, unsigned int>>
247  const FiniteElement<dim, spacedim> &fe_other) const override;
248 
253  virtual std::vector<std::pair<unsigned int, unsigned int>>
255  const FiniteElement<dim, spacedim> &fe_other) const override;
256 
261  virtual std::vector<std::pair<unsigned int, unsigned int>>
263  const unsigned int face_no = 0) const override;
264 
266 
273  "FE_Q can only be used for polynomial degrees "
274  "greater than zero. If you want an element of polynomial "
275  "degree zero, then it cannot be continuous and you "
276  "will want to use FE_DGQ<dim>(0).");
277 
278 protected:
285  static std::vector<unsigned int>
286  get_dpo_vector(const unsigned int degree);
287 
293  void
294  initialize(const std::vector<Point<1>> &support_points_1d);
295 
300  void
301  initialize_constraints(const std::vector<Point<1>> &points);
302 
307  void
308  initialize_unit_support_points(const std::vector<Point<1>> &points);
309 
314  void
315  initialize_unit_face_support_points(const std::vector<Point<1>> &points);
316 
321  void
323 
330  struct Implementation;
331 
332  // Declare implementation friend.
333  friend struct FE_Q_Base<PolynomialType, dim, spacedim>::Implementation;
334 
335 private:
340 
346  const unsigned int q_degree;
347 };
348 
349 
353 
354 #endif
virtual std::vector< std::pair< unsigned int, unsigned int > > hp_line_dof_identities(const FiniteElement< dim, spacedim > &fe_other) const override
Definition: fe_q_base.cc:775
virtual void get_subface_interpolation_matrix(const FiniteElement< dim, spacedim > &source, const unsigned int subface, FullMatrix< double > &matrix, const unsigned int face_no=0) const override
Definition: fe_q_base.cc:623
FE_Q_Base(const PolynomialType &poly_space, const FiniteElementData< dim > &fe_data, const std::vector< bool > &restriction_is_additive_flags)
Definition: fe_q_base.cc:412
virtual void get_face_interpolation_matrix(const FiniteElement< dim, spacedim > &source, FullMatrix< double > &matrix, const unsigned int face_no=0) const override
Definition: fe_q_base.cc:607
Threads::Mutex mutex
Definition: fe_q_base.h:339
static std::vector< unsigned int > get_dpo_vector(const unsigned int degree)
Definition: fe_q_base.cc:1182
Contents is actually a matrix.
const unsigned int degree
Definition: fe_base.h:431
virtual bool has_support_on_face(const unsigned int shape_index, const unsigned int face_index) const override
Definition: fe_q_base.cc:1550
static ::ExceptionBase & ExcFEQCannotHaveDegree0()
virtual const FullMatrix< double > & get_prolongation_matrix(const unsigned int child, const RefinementCase< dim > &refinement_case=RefinementCase< dim >::isotropic_refinement) const override
Definition: fe_q_base.cc:1207
virtual std::vector< std::pair< unsigned int, unsigned int > > hp_quad_dof_identities(const FiniteElement< dim, spacedim > &fe_other, const unsigned int face_no=0) const override
Definition: fe_q_base.cc:840
const unsigned int q_degree
Definition: fe_q_base.h:346
void initialize_unit_face_support_points(const std::vector< Point< 1 >> &points)
Definition: fe_q_base.cc:942
void initialize_unit_support_points(const std::vector< Point< 1 >> &points)
Definition: fe_q_base.cc:917
#define DeclExceptionMsg(Exception, defaulttext)
Definition: exceptions.h:493
#define DEAL_II_NAMESPACE_CLOSE
Definition: config.h:372
virtual void get_interpolation_matrix(const FiniteElement< dim, spacedim > &source, FullMatrix< double > &matrix) const override
Definition: fe_q_base.cc:508
virtual const FullMatrix< double > & get_restriction_matrix(const unsigned int child, const RefinementCase< dim > &refinement_case=RefinementCase< dim >::isotropic_refinement) const override
Definition: fe_q_base.cc:1406
virtual unsigned int face_to_cell_index(const unsigned int face_dof_index, const unsigned int face, const bool face_orientation=true, const bool face_flip=false, const bool face_rotation=false) const override
Definition: fe_q_base.cc:1066
void initialize_constraints(const std::vector< Point< 1 >> &points)
Definition: fe_q_base.cc:1197
virtual bool hp_constraints_are_implemented() const override
Definition: fe_q_base.cc:725
void initialize(const std::vector< Point< 1 >> &support_points_1d)
Definition: fe_q_base.cc:431
void initialize_quad_dof_index_permutation()
Definition: fe_q_base.cc:981
#define DEAL_II_NAMESPACE_OPEN
Definition: config.h:371
const std::unique_ptr< ScalarPolynomialsBase< dim > > poly_space
Definition: fe_poly.h:526
virtual std::vector< std::pair< unsigned int, unsigned int > > hp_vertex_dof_identities(const FiniteElement< dim, spacedim > &fe_other) const override
Definition: fe_q_base.cc:734
virtual std::pair< Table< 2, bool >, std::vector< unsigned int > > get_constant_modes() const override
Definition: fe_q_base.cc:1652
const std::vector< bool > restriction_is_additive_flags
Definition: fe.h:2572