Reference documentation for deal.II version 8.5.1
fe_q_hierarchical.h
1 // ---------------------------------------------------------------------
2 //
3 // Copyright (C) 2002 - 2017 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 #ifndef dealii__fe_q_hierarchical_h
17 #define dealii__fe_q_hierarchical_h
18 
19 #include <deal.II/base/config.h>
20 #include <deal.II/base/tensor_product_polynomials.h>
21 #include <deal.II/fe/fe_poly.h>
22 
23 DEAL_II_NAMESPACE_OPEN
24 
27 
540 template <int dim>
541 class FE_Q_Hierarchical : public FE_Poly<TensorProductPolynomials<dim>,dim>
542 {
543 public:
547  FE_Q_Hierarchical (const unsigned int p);
548 
554  virtual std::string get_name () const;
555 
560  virtual bool has_support_on_face (const unsigned int shape_index,
561  const unsigned int face_index) const;
562 
576  virtual bool hp_constraints_are_implemented () const;
577 
582  virtual void get_interpolation_matrix(const FiniteElement< dim> &source,
583  FullMatrix< double > &matrix) const;
584 
588  virtual const
589  FullMatrix<double> &get_prolongation_matrix (const unsigned int child,
591 
607  virtual
608  std::vector<std::pair<unsigned int, unsigned int> >
609  hp_vertex_dof_identities (const FiniteElement<dim> &fe_other) const;
610 
614  virtual
615  std::vector<std::pair<unsigned int, unsigned int> >
616  hp_line_dof_identities (const FiniteElement<dim> &fe_other) const;
617 
621  virtual
622  std::vector<std::pair<unsigned int, unsigned int> >
623  hp_quad_dof_identities (const FiniteElement<dim> &fe_other) const;
624 
638  virtual void get_face_interpolation_matrix (const FiniteElement<dim> &source, FullMatrix<double> &matrix) const;
639 
651  virtual void get_subface_interpolation_matrix (const FiniteElement<dim> &source, const unsigned int subface, FullMatrix<double> &matrix) const;
652 
662  virtual
664  compare_for_face_domination (const FiniteElement<dim> &fe_other) const;
665 
674  virtual std::size_t memory_consumption () const;
675 
681  std::vector<unsigned int> get_embedding_dofs (const unsigned int sub_degree) const;
682 
688  virtual std::pair<Table<2,bool>, std::vector<unsigned int> >
689  get_constant_modes () const;
690 
694  virtual
695  void interpolate(std::vector<double> &local_dofs,
696  const std::vector<double> &values) const DEAL_II_DEPRECATED;
697 
701  virtual
702  void
703  interpolate(std::vector<double> &local_dofs,
704  const std::vector<Vector<double> > &values,
705  const unsigned int offset = 0) const DEAL_II_DEPRECATED;
706 
710  virtual
711  void
712  interpolate(std::vector<double> &local_dofs,
713  const VectorSlice<const std::vector<std::vector<double> > > &values) const DEAL_II_DEPRECATED;
714 
715 
716 protected:
722  virtual FiniteElement<dim> *clone() const;
723 
724 private:
725 
732  static std::vector<unsigned int> get_dpo_vector(const unsigned int degree);
733 
761  static
762  std::vector<unsigned int> hierarchic_to_fe_q_hierarchical_numbering (
763  const FiniteElementData<dim> &fe);
764 
768  static
769  std::vector<unsigned int>
771 
776  void build_dofs_cell (std::vector<FullMatrix<double> > &dofs_cell,
777  std::vector<FullMatrix<double> > &dofs_subcell) const;
778 
783  void initialize_constraints (const std::vector<FullMatrix<double> > &dofs_subcell);
784 
788  void initialize_embedding_and_restriction (const std::vector<FullMatrix<double> > &dofs_cell,
789  const std::vector<FullMatrix<double> > &dofs_subcell);
790 
796 
802 
806  const std::vector<unsigned int> face_renumber;
807 
814  template <int dim1> friend class FE_Q_Hierarchical;
815 };
816 
819 /* -------------- declaration of explicit specializations ------------- */
820 
821 template <>
823 
824 template <>
825 bool
827  const unsigned int) const;
828 
829 template <>
830 std::vector<unsigned int>
832 
833 DEAL_II_NAMESPACE_CLOSE
834 
835 #endif
virtual std::vector< std::pair< unsigned int, unsigned int > > hp_line_dof_identities(const FiniteElement< dim > &fe_other) const
virtual bool hp_constraints_are_implemented() const
void initialize_generalized_support_points()
void initialize_embedding_and_restriction(const std::vector< FullMatrix< double > > &dofs_cell, const std::vector< FullMatrix< double > > &dofs_subcell)
const unsigned int degree
Definition: fe_base.h:311
virtual FiniteElement< dim > * clone() const
const std::vector< unsigned int > face_renumber
virtual void get_interpolation_matrix(const FiniteElement< dim > &source, FullMatrix< double > &matrix) const
virtual const FullMatrix< double > & get_prolongation_matrix(const unsigned int child, const RefinementCase< dim > &refinement_case=RefinementCase< dim >::isotropic_refinement) const
std::vector< unsigned int > get_embedding_dofs(const unsigned int sub_degree) const
virtual std::string get_name() const
virtual bool has_support_on_face(const unsigned int shape_index, const unsigned int face_index) const
virtual void interpolate(std::vector< double > &local_dofs, const std::vector< double > &values) const 1
static std::vector< unsigned int > face_fe_q_hierarchical_to_hierarchic_numbering(const unsigned int degree)
virtual std::pair< Table< 2, bool >, std::vector< unsigned int > > get_constant_modes() const
void initialize_constraints(const std::vector< FullMatrix< double > > &dofs_subcell)
virtual void get_subface_interpolation_matrix(const FiniteElement< dim > &source, const unsigned int subface, FullMatrix< double > &matrix) const
friend class FE_Q_Hierarchical
static std::vector< unsigned int > hierarchic_to_fe_q_hierarchical_numbering(const FiniteElementData< dim > &fe)
virtual std::vector< std::pair< unsigned int, unsigned int > > hp_vertex_dof_identities(const FiniteElement< dim > &fe_other) const
virtual std::vector< std::pair< unsigned int, unsigned int > > hp_quad_dof_identities(const FiniteElement< dim > &fe_other) const
virtual void get_face_interpolation_matrix(const FiniteElement< dim > &source, FullMatrix< double > &matrix) const
virtual std::size_t memory_consumption() const
static std::vector< unsigned int > get_dpo_vector(const unsigned int degree)
virtual FiniteElementDomination::Domination compare_for_face_domination(const FiniteElement< dim > &fe_other) const
void build_dofs_cell(std::vector< FullMatrix< double > > &dofs_cell, std::vector< FullMatrix< double > > &dofs_subcell) const
void initialize_generalized_face_support_points()