16 #ifndef dealii_fe_poly_h 17 #define dealii_fe_poly_h 20 #include <deal.II/base/quadrature.h> 21 #include <deal.II/base/std_cxx14/memory.h> 23 #include <deal.II/fe/fe.h> 25 DEAL_II_NAMESPACE_OPEN
69 template <
class PolynomialType,
70 int dim = PolynomialType::dimension,
99 std::vector<unsigned int>
106 std::vector<unsigned int>
130 const unsigned int component)
const override;
153 const unsigned int component)
const override;
176 const unsigned int component)
const override;
200 const unsigned int component)
const override;
224 const unsigned int component)
const override;
234 virtual std::unique_ptr<
242 &output_data)
const override 246 std::unique_ptr<typename FiniteElement<dim, spacedim>::InternalDataBase>
247 data_ptr = std_cxx14::make_unique<InternalData>();
248 auto &data =
dynamic_cast<InternalData &
>(*data_ptr);
251 const unsigned int n_q_points = quadrature.
size();
256 std::vector<double> values(
258 std::vector<Tensor<1, dim>> grads(
260 std::vector<Tensor<2, dim>> grad_grads(
262 std::vector<Tensor<3, dim>> third_derivatives(
264 std::vector<Tensor<4, dim>>
284 !((output_data.shape_values.n_rows() > 0) &&
285 (output_data.shape_values.n_cols() == n_q_points)))
286 data.shape_values.reinit(this->dofs_per_cell, n_q_points);
289 data.shape_gradients.reinit(this->dofs_per_cell, n_q_points);
292 data.shape_hessians.reinit(this->dofs_per_cell, n_q_points);
295 data.shape_3rd_derivatives.reinit(this->dofs_per_cell, n_q_points);
302 for (
unsigned int i = 0; i < n_q_points; ++i)
319 if (output_data.shape_values.n_rows() > 0)
321 if (output_data.shape_values.n_cols() == n_q_points)
323 output_data.shape_values[k][i] = values[k];
326 data.shape_values[k][i] = values[k];
334 data.shape_gradients[k][i] = grads[k];
338 data.shape_hessians[k][i] = grad_grads[k];
342 data.shape_3rd_derivatives[k][i] = third_derivatives[k];
354 const ::internal::FEValuesImplementation::MappingRelatedData<dim,
360 &output_data)
const override;
365 const unsigned int face_no,
369 const ::internal::FEValuesImplementation::MappingRelatedData<dim,
375 &output_data)
const override;
378 fill_fe_subface_values(
380 const unsigned int face_no,
381 const unsigned int sub_no,
385 const ::internal::FEValuesImplementation::MappingRelatedData<dim,
391 &output_data)
const override;
475 const unsigned int n_q_points,
476 const unsigned int dof)
const;
487 DEAL_II_NAMESPACE_CLOSE
virtual double shape_value(const unsigned int i, const Point< dim > &p) const override
Table< 2, Tensor< 2, dim > > shape_hessians
virtual Tensor< 4, dim > shape_4th_derivative(const unsigned int i, const Point< dim > &p) const override
const Point< dim > & point(const unsigned int i) const
virtual Tensor< 1, dim > shape_grad(const unsigned int i, const Point< dim > &p) const override
virtual Tensor< 2, dim > shape_grad_grad(const unsigned int i, const Point< dim > &p) const override
virtual Tensor< 2, dim > shape_grad_grad_component(const unsigned int i, const Point< dim > &p, const unsigned int component) const override
Table< 2, Tensor< 1, dim > > shape_gradients
FE_Poly(const PolynomialType &poly_space, const FiniteElementData< dim > &fe_data, const std::vector< bool > &restriction_is_additive_flags, const std::vector< ComponentMask > &nonzero_components)
virtual std::unique_ptr< typename FiniteElement< dim, spacedim >::InternalDataBase > get_data(const UpdateFlags update_flags, const Mapping< dim, spacedim > &, const Quadrature< dim > &quadrature, ::internal::FEValuesImplementation::FiniteElementRelatedData< dim, spacedim > &output_data) const override
Third derivatives of shape functions.
Abstract base class for mapping classes.
Table< 2, Tensor< 3, dim > > shape_3rd_derivatives
Second derivatives of shape functions.
unsigned int size() const
const unsigned int dofs_per_cell
virtual Tensor< 3, dim > shape_3rd_derivative_component(const unsigned int i, const Point< dim > &p, const unsigned int component) const override
Table< 2, double > shape_values
unsigned int get_degree() const
void correct_third_derivatives(internal::FEValuesImplementation::FiniteElementRelatedData< dim, spacedim > &output_data, const internal::FEValuesImplementation::MappingRelatedData< dim, spacedim > &mapping_data, const unsigned int n_q_points, const unsigned int dof) const
virtual UpdateFlags requires_update_flags(const UpdateFlags update_flags) const override
virtual Tensor< 4, dim > shape_4th_derivative_component(const unsigned int i, const Point< dim > &p, const unsigned int component) const override
Shape function gradients.
virtual Tensor< 3, dim > shape_3rd_derivative(const unsigned int i, const Point< dim > &p) const override
const std::vector< ComponentMask > nonzero_components
virtual double shape_value_component(const unsigned int i, const Point< dim > &p, const unsigned int component) const override
PolynomialType poly_space
std::vector< unsigned int > get_poly_space_numbering_inverse() const
std::vector< unsigned int > get_poly_space_numbering() const
const std::vector< bool > restriction_is_additive_flags
virtual Tensor< 1, dim > shape_grad_component(const unsigned int i, const Point< dim > &p, const unsigned int component) const override