Reference documentation for deal.II version 9.0.0
shape_info.h
1 // ---------------------------------------------------------------------
2 //
3 // Copyright (C) 2011 - 2018 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 at
12 // the top level of the deal.II distribution.
13 //
14 // ---------------------------------------------------------------------
15 
16 
17 #ifndef dealii_matrix_free_shape_info_h
18 #define dealii_matrix_free_shape_info_h
19 
20 
21 #include <deal.II/base/exceptions.h>
22 #include <deal.II/base/quadrature_lib.h>
23 #include <deal.II/base/aligned_vector.h>
24 #include <deal.II/fe/fe.h>
25 
26 
27 DEAL_II_NAMESPACE_OPEN
28 
29 namespace internal
30 {
31  namespace MatrixFreeFunctions
32  {
38  enum ElementType
39  {
48  tensor_symmetric_collocation = 0,
54  tensor_symmetric_hermite = 1,
60  tensor_symmetric = 2,
64  tensor_general = 3,
69  truncated_tensor = 4,
75  tensor_symmetric_plus_dg0 = 5
76  };
77 
88  template <typename Number>
89  struct ShapeInfo
90  {
94  ShapeInfo ();
95 
99  template <int dim>
100  ShapeInfo (const Quadrature<1> &quad,
101  const FiniteElement<dim> &fe,
102  const unsigned int base_element = 0);
103 
112  template <int dim>
113  void reinit (const Quadrature<1> &quad,
114  const FiniteElement<dim> &fe_dim,
115  const unsigned int base_element = 0);
116 
120  std::size_t memory_consumption () const;
121 
127  ElementType element_type;
128 
137 
146 
155 
162 
169 
176 
183 
190 
197 
203 
209 
215 
223  std::vector<unsigned int> lexicographic_numbering;
224 
228  unsigned int fe_degree;
229 
233  unsigned int n_q_points_1d;
234 
239  unsigned int n_q_points;
240 
246 
250  unsigned int n_q_points_face;
251 
256 
262 
299 
339 
344  bool check_1d_shapes_symmetric(const unsigned int n_q_points_1d);
345 
353  };
354 
355 
356 
357  // ------------------------------------------ inline functions
358 
359  template <typename Number>
360  template <int dim>
361  inline
363  const FiniteElement<dim> &fe_in,
364  const unsigned int base_element_number)
365  :
366  element_type(tensor_general),
367  fe_degree (0),
368  n_q_points_1d (0),
369  n_q_points (0),
370  dofs_per_component_on_cell (0),
371  n_q_points_face (0),
372  dofs_per_component_on_face (0),
373  nodal_at_cell_boundaries (false)
374  {
375  reinit (quad, fe_in, base_element_number);
376  }
377 
378  } // end of namespace MatrixFreeFunctions
379 
380 } // end of namespace internal
381 
382 DEAL_II_NAMESPACE_CLOSE
383 
384 #endif
void reinit(const Quadrature< 1 > &quad, const FiniteElement< dim > &fe_dim, const unsigned int base_element=0)
AlignedVector< Number > shape_values_eo
Definition: shape_info.h:161
::Table< 2, unsigned int > face_to_cell_index_nodal
Definition: shape_info.h:298
AlignedVector< Number > shape_hessians
Definition: shape_info.h:154
AlignedVector< Number > shape_values
Definition: shape_info.h:136
AlignedVector< Number > hessians_within_subface[2]
Definition: shape_info.h:214
bool check_1d_shapes_symmetric(const unsigned int n_q_points_1d)
AlignedVector< Number > shape_gradients_collocation_eo
Definition: shape_info.h:182
AlignedVector< Number > shape_data_on_face[2]
Definition: shape_info.h:196
AlignedVector< Number > shape_hessians_eo
Definition: shape_info.h:175
AlignedVector< Number > gradients_within_subface[2]
Definition: shape_info.h:208
AlignedVector< Number > shape_gradients_eo
Definition: shape_info.h:168
::Table< 2, unsigned int > face_to_cell_index_hermite
Definition: shape_info.h:338
AlignedVector< Number > shape_gradients
Definition: shape_info.h:145
AlignedVector< Number > values_within_subface[2]
Definition: shape_info.h:202
std::vector< unsigned int > lexicographic_numbering
Definition: shape_info.h:223
AlignedVector< Number > shape_hessians_collocation_eo
Definition: shape_info.h:189