16#ifndef dealii_dof_tools_h
17#define dealii_dof_tools_h
45template <
int dim,
typename RangeNumberType>
47template <
int dim,
int spacedim>
51 template <
int dim,
int spacedim>
52 class MappingCollection;
53 template <
int dim,
int spacedim>
56template <
class MeshType>
58template <
int dim,
int spacedim>
61template <
int dim,
class T>
63template <
typename Number>
68 template <
typename CellIterator>
69 struct PeriodicFacePair;
82 template <
int dim,
int spacedim>
84 always_couple_on_faces(
258 template <
int dim,
int spacedim>
269 template <
int dim,
int spacedim>
282 template <
int dim,
int spacedim>
283 std::vector<Table<2, Coupling>>
414 typename SparsityPatternType,
415 typename number =
double>
419 SparsityPatternType & sparsity_pattern,
421 const bool keep_constrained_dofs =
true,
491 typename SparsityPatternType,
492 typename number =
double>
497 SparsityPatternType & sparsity_pattern,
499 const bool keep_constrained_dofs =
true,
522 template <
int dim,
int spacedim,
typename SparsityPatternType>
526 SparsityPatternType & sparsity);
573 template <
int dim,
int spacedim,
typename SparsityPatternType>
576 SparsityPatternType & sparsity_pattern);
588 typename SparsityPatternType,
593 SparsityPatternType & sparsity_pattern,
595 const bool keep_constrained_dofs =
true,
618 template <
int dim,
int spacedim,
typename SparsityPatternType>
622 SparsityPatternType & sparsity,
656 typename SparsityPatternType,
661 SparsityPatternType & sparsity,
663 const bool keep_constrained_dofs,
669 const unsigned int)> &face_has_flux_coupling =
670 &internal::always_couple_on_faces<dim, spacedim>);
681 template <
int dim,
int spacedim,
typename SparsityPatternType>
685 const std::vector<types::global_dof_index> &dof_to_boundary_mapping,
686 SparsityPatternType & sparsity_pattern);
707 typename SparsityPatternType,
714 const std::vector<types::global_dof_index> &dof_to_boundary_mapping,
715 SparsityPatternType & sparsity);
764 template <
int dim,
int spacedim,
typename number>
836 template <
int dim,
int spacedim>
840 const unsigned int coarse_component,
842 const unsigned int fine_component,
863 template <
int dim,
int spacedim>
867 const unsigned int coarse_component,
869 const unsigned int fine_component,
871 std::vector<std::map<types::global_dof_index, float>>
872 &transfer_representation);
1048 template <
typename FaceIterator,
typename number>
1051 const FaceIterator & face_1,
1055 const bool face_orientation =
true,
1056 const bool face_flip =
false,
1057 const bool face_rotation =
false,
1059 const std::vector<unsigned int> &first_vector_components =
1060 std::vector<unsigned int>(),
1061 const number periodicity_factor = 1.);
1084 template <
int dim,
int spacedim,
typename number>
1091 const std::vector<unsigned int> &first_vector_components =
1092 std::vector<unsigned int>(),
1093 const number periodicity_factor = 1.);
1101 template <
typename DoFHandlerType,
typename number>
1109 const std::vector<unsigned int> &first_vector_components =
1110 std::vector<unsigned int>(),
1111 const number periodicity_factor = 1.);
1144 template <
int dim,
int spacedim,
typename number>
1150 const unsigned int direction,
1153 const number periodicity_factor = 1.);
1182 template <
int dim,
int spacedim,
typename number>
1187 const unsigned int direction,
1190 const number periodicity_factor = 1.);
1219 template <
int dim,
int spacedim>
1222 std::vector<bool> & selected_dofs);
1228 template <
int dim,
int spacedim>
1274 template <
int dim,
int spacedim>
1278 std::vector<bool> & selected_dofs);
1312 template <
int dim,
int spacedim>
1347 template <
int dim,
int spacedim>
1351 std::vector<bool> & selected_dofs);
1376 template <
int dim,
int spacedim>
1385 template <
int dim,
int spacedim>
1390 std::vector<bool> & selected_dofs);
1396 template <
int dim,
int spacedim>
1401 std::vector<bool> & selected_dofs);
1457 template <
int dim,
int spacedim>
1461 std::vector<bool> & selected_dofs,
1462 const std::set<types::boundary_id> &boundary_ids = {});
1506 template <
int dim,
int spacedim>
1510 const std::set<types::boundary_id> &boundary_ids = {});
1518 template <
int dim,
int spacedim>
1523 const std::set<types::boundary_id> &boundary_ids = {});
1541 template <
int dim,
int spacedim>
1546 std::vector<bool> & selected_dofs,
1547 const std::set<types::boundary_id> &boundary_ids =
1548 std::set<types::boundary_id>());
1577 template <
int dim,
int spacedim,
typename number =
double>
1581 const std::function<
1619 template <
int dim,
int spacedim>
1623 std::vector<std::vector<bool>> & constant_modes);
1639 template <
int dim,
int spacedim>
1643 std::vector<bool> & selected_dofs);
1659 template <
int dim,
int spacedim>
1670 template <
int dim,
int spacedim>
1675 const unsigned int level);
1686 template <
int dim,
int spacedim>
1701 template <
int dim,
int spacedim>
1702 std::vector<IndexSet>
1720 template <
int dim,
int spacedim>
1721 std::vector<IndexSet>
1739 template <
int dim,
int spacedim>
1740 std::vector<IndexSet>
1749 template <
int dim,
int spacedim>
1753 const unsigned int level,
1787 template <
int dim,
int spacedim>
1790 std::vector<types::subdomain_id> &subdomain);
1817 template <
int dim,
int spacedim>
1842 template <
int dim,
int spacedim>
1847 std::vector<unsigned int> & n_dofs_on_subdomain);
1870 template <
int dim,
int spacedim>
1930 template <
int dim,
int spacedim>
1931 std::vector<types::global_dof_index>
1942 template <
typename DoFHandlerType>
1945 const std::vector<typename DoFHandlerType::active_cell_iterator> &patch);
1967 template <
int dim,
int spacedim>
1971 const unsigned int level,
1972 const std::vector<bool> & selected_dofs = {},
2026 template <
int dim,
int spacedim>
2027 std::vector<unsigned int>
2030 const unsigned int level,
2031 const bool interior_dofs_only,
2032 const bool boundary_patches =
false,
2033 const bool level_boundary_patches =
false,
2034 const bool single_cell_patches =
false,
2035 const bool invert_vertex_mapping =
false);
2051 template <
int dim,
int spacedim>
2052 std::vector<unsigned int>
2055 const unsigned int level,
2057 const bool boundary_patches =
false,
2058 const bool level_boundary_patches =
false,
2059 const bool single_cell_patches =
false,
2060 const bool invert_vertex_mapping =
false);
2099 template <
int dim,
int spacedim>
2103 const unsigned int level,
2104 const bool interior_dofs_only,
2105 const bool boundary_dofs =
false);
2126 template <
int dim,
int spacedim>
2130 const unsigned int level,
2131 const bool interior_dofs_only =
false);
2175 template <
int dim,
int spacedim>
2176 std::vector<types::global_dof_index>
2179 const bool vector_valued_once =
false,
2180 const std::vector<unsigned int> &target_component = {});
2186 template <
int dim,
int spacedim>
2190 std::vector<types::global_dof_index> &dofs_per_component,
2191 const bool vector_valued_once =
false,
2192 const std::vector<unsigned int> & target_component = {});
2210 template <
int dim,
int spacedim>
2211 std::vector<types::global_dof_index>
2213 const std::vector<unsigned int> &target_block =
2214 std::vector<unsigned int>());
2220 template <
int dim,
int spacedim>
2223 std::vector<types::global_dof_index> &dofs_per_block,
2224 const std::vector<unsigned int> & target_block =
2225 std::vector<unsigned int>());
2236 template <
int dim,
int spacedim>
2239 std::vector<unsigned int> & active_fe_indices);
2268 template <
int dim,
int spacedim>
2280 template <
typename DoFHandlerType>
2283 const std::vector<typename DoFHandlerType::active_cell_iterator> &patch);
2307 template <
int dim,
int spacedim>
2310 std::vector<types::global_dof_index> &mapping);
2322 template <
int dim,
int spacedim>
2325 const std::set<types::boundary_id> &boundary_ids,
2326 std::vector<types::global_dof_index> &mapping);
2356 template <
int dim,
int spacedim>
2366 template <
int dim,
int spacedim>
2369 const ::hp::MappingCollection<dim, spacedim> &mapping,
2404 template <
int dim,
int spacedim>
2415 template <
int dim,
int spacedim>
2418 const ::hp::MappingCollection<dim, spacedim> &mapping,
2444 template <
int dim,
int spacedim,
class Comp>
2450 &point_to_index_map);
2488 template <
int dim,
int spacedim,
typename Number>
2493 const unsigned int component = 0);
2572 template <
int spacedim>
2619 template <
int dim,
int spacedim,
typename number>
2637 template <
int dim,
int spacedim,
typename number>
2732 template <
int dim,
int spacedim,
class Comp>
2738 &point_to_index_map)
2743 std::vector<Point<spacedim>> support_points(dof_handler.
n_dofs());
2748 point_to_index_map.clear();
2750 point_to_index_map[support_points[i]] = i;
2755 template <
typename DoFHandlerType,
typename number>
2763 const std::vector<unsigned int> &first_vector_components,
2764 const number periodicity_factor)
2767 DoFHandlerType::space_dimension>(
2771 first_vector_components,
2772 periodicity_factor);
2777 template <
typename DoFHandlerType>
2778 inline std::vector<types::global_dof_index>
2780 const std::vector<typename DoFHandlerType::active_cell_iterator> &patch)
2783 DoFHandlerType::space_dimension>(patch);
2788 template <
typename DoFHandlerType>
2791 const std::vector<typename DoFHandlerType::active_cell_iterator> &patch)
2794 DoFHandlerType::space_dimension>(patch);
types::global_dof_index n_dofs() const
Abstract base class for mapping classes.
#define DEAL_II_DEPRECATED
#define DEAL_II_NAMESPACE_OPEN
#define DEAL_II_DEPRECATED_EARLY
#define DEAL_II_NAMESPACE_CLOSE
UpdateFlags & operator|=(UpdateFlags &f1, const UpdateFlags f2)
#define DeclException0(Exception0)
static ::ExceptionBase & ExcGridNotCoarser()
static ::ExceptionBase & ExcInvalidBoundaryIndicator()
static ::ExceptionBase & ExcFiniteElementsDontMatch()
static ::ExceptionBase & ExcNoFESelected()
static ::ExceptionBase & ExcGridsDontMatch()
void compute_intergrid_transfer_representation(const DoFHandler< dim, spacedim > &coarse_grid, const unsigned int coarse_component, const DoFHandler< dim, spacedim > &fine_grid, const unsigned int fine_component, const InterGridMap< DoFHandler< dim, spacedim > > &coarse_to_fine_grid_map, std::vector< std::map< types::global_dof_index, float > > &transfer_representation)
void make_zero_boundary_constraints(const DoFHandler< dim, spacedim > &dof, const types::boundary_id boundary_id, AffineConstraints< number > &zero_boundary_constraints, const ComponentMask &component_mask=ComponentMask())
void make_hanging_node_constraints(const DoFHandler< dim, spacedim > &dof_handler, AffineConstraints< number > &constraints)
void compute_intergrid_constraints(const DoFHandler< dim, spacedim > &coarse_grid, const unsigned int coarse_component, const DoFHandler< dim, spacedim > &fine_grid, const unsigned int fine_component, const InterGridMap< DoFHandler< dim, spacedim > > &coarse_to_fine_grid_map, AffineConstraints< double > &constraints)
void make_flux_sparsity_pattern(const DoFHandler< dim, spacedim > &dof_handler, SparsityPatternType &sparsity_pattern)
void make_boundary_sparsity_pattern(const DoFHandler< dim, spacedim > &dof, const std::vector< types::global_dof_index > &dof_to_boundary_mapping, SparsityPatternType &sparsity_pattern)
void make_sparsity_pattern(const DoFHandler< dim, spacedim > &dof_handler, SparsityPatternType &sparsity_pattern, const AffineConstraints< number > &constraints=AffineConstraints< number >(), const bool keep_constrained_dofs=true, const types::subdomain_id subdomain_id=numbers::invalid_subdomain_id)
@ matrix
Contents is actually a matrix.
const types::subdomain_id invalid_subdomain_id
unsigned int global_dof_index
unsigned int subdomain_id
ParameterHandler::OutputStyle operator|(const ParameterHandler::OutputStyle f1, const ParameterHandler::OutputStyle f2)