16 #include <deal.II/lac/vector.h> 17 #include <deal.II/lac/block_vector.h> 18 #include <deal.II/lac/la_vector.h> 19 #include <deal.II/lac/la_parallel_vector.h> 20 #include <deal.II/lac/la_parallel_block_vector.h> 21 #include <deal.II/lac/petsc_parallel_vector.h> 22 #include <deal.II/lac/petsc_parallel_block_vector.h> 23 #include <deal.II/lac/trilinos_vector.h> 24 #include <deal.II/lac/trilinos_parallel_block_vector.h> 25 #include <deal.II/lac/sparse_matrix.h> 27 #include <deal.II/dofs/dof_accessor.h> 28 #include <deal.II/dofs/dof_handler.h> 29 #include <deal.II/dofs/dof_levels.h> 30 #include <deal.II/hp/dof_handler.h> 31 #include <deal.II/grid/tria_boundary.h> 32 #include <deal.II/grid/tria_iterator.h> 33 #include <deal.II/grid/tria_iterator.templates.h> 34 #include <deal.II/fe/fe.h> 38 DEAL_II_NAMESPACE_OPEN
41 template <
typename DoFHandlerType,
bool lda>
42 template <
class InputVector,
typename number>
47 const unsigned int fe_index)
const 49 if (!this->has_children())
61 (fe_index == this->active_fe_index())
63 (fe_index == DoFHandlerType::default_fe_index))
64 this->get_dof_values (values, interpolated_values);
71 this->get_dof_values (values, tmp);
74 this->get_fe().dofs_per_cell);
75 this->dof_handler->get_fe(fe_index).get_interpolation_matrix (this->get_fe(),
77 interpolation.
vmult (interpolated_values, tmp);
94 (fe_index != DoFHandlerType::default_fe_index),
95 ExcMessage (
"You cannot call this function on non-active cells " 96 "of hp::DoFHandler objects unless you provide an explicit " 97 "finite element index because they do not have naturally " 98 "associated finite element spaces associated: degrees " 99 "of freedom are only distributed on active cells for which " 100 "the active_fe_index has been set."));
105 Assert (this->dof_handler !=
nullptr,
106 typename BaseClass::ExcInvalidObject());
107 Assert (interpolated_values.
size() == dofs_per_cell,
108 typename BaseClass::ExcVectorDoesNotMatch());
109 Assert (values.size() == this->dof_handler->n_dofs(),
110 typename BaseClass::ExcVectorDoesNotMatch());
123 interpolated_values = 0;
149 for (
unsigned int child=0; child<this->n_children(); ++child)
155 this->child(child)->get_interpolated_dof_values (values,
162 for (
unsigned int i=0; i<dofs_per_cell; ++i)
164 interpolated_values(i) += tmp2(i);
165 else if (tmp2(i) != number())
166 interpolated_values(i) = tmp2(i);
175 #include "dof_accessor_get.inst" 177 DEAL_II_NAMESPACE_CLOSE
bool restriction_is_additive(const unsigned int index) const
void vmult(Vector< number2 > &w, const Vector< number2 > &v, const bool adding=false) const
void get_interpolated_dof_values(const InputVector &values, Vector< number > &interpolated_values, const unsigned int fe_index=DoFHandlerType::default_fe_index) const
static ::ExceptionBase & ExcMessage(std::string arg1)
#define Assert(cond, exc)
virtual const FullMatrix< double > & get_restriction_matrix(const unsigned int child, const RefinementCase< dim > &refinement_case=RefinementCase< dim >::isotropic_refinement) const
const unsigned int dofs_per_cell