Reference documentation for deal.II version 9.0.0
vector_tools.h
1 // ---------------------------------------------------------------------
2 //
3 // Copyright (C) 1998 - 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 #ifndef dealii_vector_tools_h
17 #define dealii_vector_tools_h
18 
19 
20 #include <deal.II/base/config.h>
21 #include <deal.II/base/exceptions.h>
22 #include <deal.II/base/quadrature_lib.h>
23 #include <deal.II/base/point.h>
24 #include <deal.II/dofs/function_map.h>
25 #include <deal.II/dofs/dof_handler.h>
26 #include <deal.II/hp/dof_handler.h>
27 #include <deal.II/hp/mapping_collection.h>
28 
29 #include <map>
30 #include <vector>
31 #include <set>
32 #include <functional>
33 
34 DEAL_II_NAMESPACE_OPEN
35 
36 template <int dim, typename RangeNumberType> class Function;
37 template <int dim> class Quadrature;
38 template <int dim> class QGauss;
39 template <int dim, typename number> class MatrixFree;
40 
41 template <typename number> class Vector;
42 template <typename number> class FullMatrix;
43 template <int dim, int spacedim> class Mapping;
44 template <typename gridtype> class InterGridMap;
45 namespace hp
46 {
47  template <int dim> class QCollection;
48 }
49 class ConstraintMatrix;
50 
51 
52 //TODO: Move documentation of functions to the functions!
53 
320 namespace VectorTools
321 {
347  enum NormType
348  {
374 
390 
408 
426 
443 
459 
478 
495 
512 
529 
547 
563 
564  };
569 
570 
571 
591  template <int dim, int spacedim, typename VectorType,
592  template <int, int> class DoFHandlerType>
593  void interpolate (const Mapping<dim,spacedim> &mapping,
594  const DoFHandlerType<dim,spacedim> &dof,
596  VectorType &vec,
597  const ComponentMask &component_mask = ComponentMask());
598 
603  template <int dim, int spacedim, typename VectorType,
604  template <int, int> class DoFHandlerType>
605  void interpolate
606  (const DoFHandlerType<dim,spacedim> &dof,
608  VectorType &vec,
609  const ComponentMask &component_mask = ComponentMask());
610 
627  template <int dim, class InVector, class OutVector, int spacedim>
628  void interpolate (const DoFHandler<dim,spacedim> &dof_1,
629  const DoFHandler<dim,spacedim> &dof_2,
630  const FullMatrix<double> &transfer,
631  const InVector &data_1,
632  OutVector &data_2);
633 
680  template <int dim, int spacedim, typename VectorType,
681  template <int,int> class DoFHandlerType>
682  void
684  (const Mapping<dim,spacedim> &mapping,
685  const DoFHandlerType<dim,spacedim> &dof_handler,
686  const std::map<types::material_id,
688  VectorType &dst,
689  const ComponentMask &component_mask = ComponentMask());
690 
715  template <int dim, int spacedim, typename VectorType,
716  template <int, int> class DoFHandlerType>
717  void
718  interpolate_to_different_mesh (const DoFHandlerType<dim, spacedim> &dof1,
719  const VectorType &u1,
720  const DoFHandlerType<dim, spacedim> &dof2,
721  VectorType &u2);
722 
736  template <int dim, int spacedim, typename VectorType,
737  template <int, int> class DoFHandlerType>
738  void
739  interpolate_to_different_mesh (const DoFHandlerType<dim, spacedim> &dof1,
740  const VectorType &u1,
741  const DoFHandlerType<dim, spacedim> &dof2,
742  const ConstraintMatrix &constraints,
743  VectorType &u2);
744 
752  template <int dim, int spacedim, typename VectorType,
753  template <int, int> class DoFHandlerType>
754  void
756  (const InterGridMap<DoFHandlerType<dim, spacedim> > &intergridmap,
757  const VectorType &u1,
758  const ConstraintMatrix &constraints,
759  VectorType &u2);
760 
812  template <int dim, typename VectorType, int spacedim>
813  void project (const Mapping<dim, spacedim> &mapping,
814  const DoFHandler<dim,spacedim> &dof,
815  const ConstraintMatrix &constraints,
816  const Quadrature<dim> &quadrature,
818  VectorType &vec,
819  const bool enforce_zero_boundary = false,
820  const Quadrature<dim-1> &q_boundary = (dim > 1 ?
821  QGauss<dim-1>(2) :
822  Quadrature<dim-1>(0)),
823  const bool project_to_boundary_first = false);
824 
829  template <int dim, typename VectorType, int spacedim>
830  void project (const DoFHandler<dim,spacedim> &dof,
831  const ConstraintMatrix &constraints,
832  const Quadrature<dim> &quadrature,
834  VectorType &vec,
835  const bool enforce_zero_boundary = false,
836  const Quadrature<dim-1> &q_boundary = (dim > 1 ?
837  QGauss<dim-1>(2) :
838  Quadrature<dim-1>(0)),
839  const bool project_to_boundary_first = false);
840 
845  template <int dim, typename VectorType, int spacedim>
846  void project (const hp::MappingCollection<dim, spacedim> &mapping,
847  const hp::DoFHandler<dim,spacedim> &dof,
848  const ConstraintMatrix &constraints,
849  const hp::QCollection<dim> &quadrature,
851  VectorType &vec,
852  const bool enforce_zero_boundary = false,
853  const hp::QCollection<dim-1> &q_boundary = hp::QCollection<dim-1>(dim > 1 ?
854  QGauss<dim-1>(2) :
855  Quadrature<dim-1>(0)),
856  const bool project_to_boundary_first = false);
857 
862  template <int dim, typename VectorType, int spacedim>
863  void project (const hp::DoFHandler<dim,spacedim> &dof,
864  const ConstraintMatrix &constraints,
865  const hp::QCollection<dim> &quadrature,
867  VectorType &vec,
868  const bool enforce_zero_boundary = false,
869  const hp::QCollection<dim-1> &q_boundary = hp::QCollection<dim-1>(dim > 1 ?
870  QGauss<dim-1>(2) :
871  Quadrature<dim-1>(0)),
872  const bool project_to_boundary_first = false);
873 
895  template <int dim, typename VectorType, int spacedim>
896  void project (const Mapping<dim, spacedim> &mapping,
897  const DoFHandler<dim,spacedim> &dof,
898  const ConstraintMatrix &constraints,
899  const Quadrature<dim> &quadrature,
900  const std::function< typename VectorType::value_type (const typename DoFHandler<dim, spacedim>::active_cell_iterator &, const unsigned int)> &func,
901  VectorType &vec_result);
902 
927  template <int dim, typename VectorType>
928  void project (std::shared_ptr<const MatrixFree<dim,typename VectorType::value_type> > data,
929  const ConstraintMatrix &constraints,
930  const unsigned int n_q_points_1d,
931  const std::function< VectorizedArray<typename VectorType::value_type> (const unsigned int, const unsigned int)> &func,
932  VectorType &vec_result,
933  const unsigned int fe_component = 0);
934 
938  template <int dim, typename VectorType>
939  void project (std::shared_ptr<const MatrixFree<dim,typename VectorType::value_type> > data,
940  const ConstraintMatrix &constraints,
941  const std::function< VectorizedArray<typename VectorType::value_type> (const unsigned int, const unsigned int)> &func,
942  VectorType &vec_result,
943  const unsigned int fe_component = 0);
944 
996  template <int dim, int spacedim, template <int,int> class DoFHandlerType,
997  typename number>
998  void
1000  (const Mapping<dim,spacedim> &mapping,
1001  const DoFHandlerType<dim,spacedim> &dof,
1002  const std::map<types::boundary_id, const Function<spacedim,number>*> &function_map,
1003  std::map<types::global_dof_index,number> &boundary_values,
1004  const ComponentMask &component_mask = ComponentMask());
1005 
1010  template <int dim, int spacedim, typename number>
1011  void
1013  (const hp::MappingCollection<dim,spacedim> &mapping,
1014  const hp::DoFHandler<dim,spacedim> &dof,
1015  const std::map<types::boundary_id, const Function<spacedim,number>*> &function_map,
1016  std::map<types::global_dof_index,number> &boundary_values,
1017  const ComponentMask &component_mask = ComponentMask());
1018 
1028  template <int dim, int spacedim, template <int,int> class DoFHandlerType,
1029  typename number>
1030  void
1032  (const Mapping<dim,spacedim> &mapping,
1033  const DoFHandlerType<dim,spacedim> &dof,
1034  const types::boundary_id boundary_component,
1035  const Function<spacedim,number> &boundary_function,
1036  std::map<types::global_dof_index,number> &boundary_values,
1037  const ComponentMask &component_mask = ComponentMask());
1038 
1048  template <int dim, int spacedim, template <int,int> class DoFHandlerType,
1049  typename number>
1050  void
1052  (const DoFHandlerType<dim,spacedim> &dof,
1053  const types::boundary_id boundary_component,
1054  const Function<spacedim,number> &boundary_function,
1055  std::map<types::global_dof_index,number> &boundary_values,
1056  const ComponentMask &component_mask = ComponentMask());
1057 
1058 
1065  template <int dim, int spacedim, template <int,int> class DoFHandlerType,
1066  typename number>
1067  void
1069  (const DoFHandlerType<dim,spacedim> &dof,
1070  const std::map<types::boundary_id, const Function<spacedim,number>*> &function_map,
1071  std::map<types::global_dof_index,number> &boundary_values,
1072  const ComponentMask &component_mask = ComponentMask());
1073 
1074 
1136  template <int dim, int spacedim, template <int,int> class DoFHandlerType,
1137  typename number>
1138  void
1140  (const Mapping<dim,spacedim> &mapping,
1141  const DoFHandlerType<dim,spacedim> &dof,
1142  const std::map<types::boundary_id, const Function<spacedim,number>*> &function_map,
1143  ConstraintMatrix &constraints,
1144  const ComponentMask &component_mask = ComponentMask());
1145 
1157  template <int dim, int spacedim, template <int,int> class DoFHandlerType,
1158  typename number>
1159  void
1161  (const Mapping<dim,spacedim> &mapping,
1162  const DoFHandlerType<dim,spacedim> &dof,
1163  const types::boundary_id boundary_component,
1164  const Function<spacedim,number> &boundary_function,
1165  ConstraintMatrix &constraints,
1166  const ComponentMask &component_mask = ComponentMask());
1167 
1179  template <int dim, int spacedim, template <int,int> class DoFHandlerType,
1180  typename number>
1181  void
1183  (const DoFHandlerType<dim,spacedim> &dof,
1184  const types::boundary_id boundary_component,
1185  const Function<spacedim,number> &boundary_function,
1186  ConstraintMatrix &constraints,
1187  const ComponentMask &component_mask = ComponentMask());
1188 
1189 
1198  template <int dim, int spacedim, template <int,int> class DoFHandlerType,
1199  typename number>
1200  void
1202  (const DoFHandlerType<dim,spacedim> &dof,
1203  const std::map<types::boundary_id, const Function<spacedim,number>*> &function_map,
1204  ConstraintMatrix &constraints,
1205  const ComponentMask &component_mask = ComponentMask());
1206 
1207 
1272  template <int dim, int spacedim, typename number>
1274  (const Mapping<dim, spacedim> &mapping,
1275  const DoFHandler<dim,spacedim> &dof,
1276  const std::map<types::boundary_id, const Function<spacedim,number>*> &boundary_functions,
1277  const Quadrature<dim-1> &q,
1278  std::map<types::global_dof_index,number> &boundary_values,
1279  std::vector<unsigned int> component_mapping = std::vector<unsigned int>());
1280 
1285  template <int dim, int spacedim, typename number>
1287  (const DoFHandler<dim,spacedim> &dof,
1288  const std::map<types::boundary_id, const Function<spacedim,number>*> &boundary_function,
1289  const Quadrature<dim-1> &q,
1290  std::map<types::global_dof_index,number> &boundary_values,
1291  std::vector<unsigned int> component_mapping = std::vector<unsigned int>());
1292 
1296  template <int dim, int spacedim, typename number>
1298  (const hp::MappingCollection<dim, spacedim> &mapping,
1299  const hp::DoFHandler<dim,spacedim> &dof,
1300  const std::map<types::boundary_id, const Function<spacedim,number>*> &boundary_functions,
1301  const hp::QCollection<dim-1> &q,
1302  std::map<types::global_dof_index,number> &boundary_values,
1303  std::vector<unsigned int> component_mapping = std::vector<unsigned int>());
1304 
1309  template <int dim, int spacedim, typename number>
1311  (const hp::DoFHandler<dim,spacedim> &dof,
1312  const std::map<types::boundary_id, const Function<spacedim,number>*> &boundary_function,
1313  const hp::QCollection<dim-1> &q,
1314  std::map<types::global_dof_index,number> &boundary_values,
1315  std::vector<unsigned int> component_mapping = std::vector<unsigned int>());
1316 
1355  template <int dim, int spacedim, typename number>
1357  (const Mapping<dim, spacedim> &mapping,
1358  const DoFHandler<dim,spacedim> &dof,
1359  const std::map<types::boundary_id, const Function<spacedim,number>*> &boundary_functions,
1360  const Quadrature<dim-1> &q,
1361  ConstraintMatrix &constraints,
1362  std::vector<unsigned int> component_mapping = std::vector<unsigned int>());
1363 
1370  template <int dim, int spacedim, typename number>
1372  (const DoFHandler<dim,spacedim> &dof,
1373  const std::map<types::boundary_id, const Function<spacedim,number>*> &boundary_function,
1374  const Quadrature<dim-1> &q,
1375  ConstraintMatrix &constraints,
1376  std::vector<unsigned int> component_mapping = std::vector<unsigned int>());
1377 
1378 
1433  template <int dim>
1435  (const DoFHandler<dim> &dof_handler,
1436  const unsigned int first_vector_component,
1437  const Function<dim,double> &boundary_function,
1438  const types::boundary_id boundary_component,
1439  ConstraintMatrix &constraints,
1440  const Mapping<dim> &mapping = StaticMappingQ1<dim>::mapping);
1441 
1450  template <int dim>
1452  (const hp::DoFHandler<dim> &dof_handler,
1453  const unsigned int first_vector_component,
1454  const Function<dim,double> &boundary_function,
1455  const types::boundary_id boundary_component,
1456  ConstraintMatrix &constraints,
1458 
1554  template <int dim>
1556  (const DoFHandler<dim> &dof_handler,
1557  const unsigned int first_vector_component,
1558  const Function<dim,double> &boundary_function,
1559  const types::boundary_id boundary_component,
1560  ConstraintMatrix &constraints,
1561  const Mapping<dim> &mapping = StaticMappingQ1<dim>::mapping);
1562 
1563 
1570  template <int dim>
1572  (const hp::DoFHandler<dim> &dof_handler,
1573  const unsigned int first_vector_component,
1574  const Function<dim,double> &boundary_function,
1575  const types::boundary_id boundary_component,
1576  ConstraintMatrix &constraints,
1578 
1579 
1626  template <int dim>
1628  (const DoFHandler<dim> &dof_handler,
1629  const unsigned int first_vector_component,
1630  const Function<dim,double> &boundary_function,
1631  const types::boundary_id boundary_component,
1632  ConstraintMatrix &constraints,
1633  const Mapping<dim> &mapping = StaticMappingQ1<dim>::mapping);
1634 
1643  template <int dim>
1645  (const hp::DoFHandler<dim> &dof_handler,
1646  const unsigned int first_vector_component,
1647  const Function<dim,double> &boundary_function,
1648  const types::boundary_id boundary_component,
1649  ConstraintMatrix &constraints,
1650  const hp::MappingCollection<dim, dim> &mapping_collection
1652 
1653 
1880  template <int dim, int spacedim, template <int, int> class DoFHandlerType>
1881  void
1883  (const DoFHandlerType<dim,spacedim> &dof_handler,
1884  const unsigned int first_vector_component,
1885  const std::set<types::boundary_id> &boundary_ids,
1886  typename FunctionMap<spacedim>::type &function_map,
1887  ConstraintMatrix &constraints,
1889 
1901  template <int dim, int spacedim, template <int, int> class DoFHandlerType>
1902  void
1904  (const DoFHandlerType<dim,spacedim> &dof_handler,
1905  const unsigned int first_vector_component,
1906  const std::set<types::boundary_id> &boundary_ids,
1907  ConstraintMatrix &constraints,
1909 
1926  template <int dim, int spacedim, template <int, int> class DoFHandlerType>
1927  void
1929  (const DoFHandlerType<dim,spacedim> &dof_handler,
1930  const unsigned int first_vector_component,
1931  const std::set<types::boundary_id> &boundary_ids,
1932  typename FunctionMap<spacedim>::type &function_map,
1933  ConstraintMatrix &constraints,
1935 
1944  template <int dim, int spacedim, template <int, int> class DoFHandlerType>
1945  void
1947  (const DoFHandlerType<dim,spacedim> &dof_handler,
1948  const unsigned int first_vector_component,
1949  const std::set<types::boundary_id> &boundary_ids,
1950  ConstraintMatrix &constraints,
1952 
1953 
1955 
1959 
1966  template <int dim, int spacedim, typename VectorType>
1967  void create_right_hand_side (const Mapping<dim, spacedim> &mapping,
1968  const DoFHandler<dim,spacedim> &dof,
1969  const Quadrature<dim> &q,
1971  VectorType &rhs_vector,
1972  const ConstraintMatrix &constraints=ConstraintMatrix());
1973 
1978  template <int dim, int spacedim, typename VectorType>
1980  const Quadrature<dim> &q,
1982  VectorType &rhs_vector,
1983  const ConstraintMatrix &constraints=ConstraintMatrix());
1984 
1988  template <int dim, int spacedim, typename VectorType>
1990  const hp::DoFHandler<dim,spacedim> &dof,
1991  const hp::QCollection<dim> &q,
1993  VectorType &rhs_vector,
1994  const ConstraintMatrix &constraints=ConstraintMatrix());
1995 
1999  template <int dim, int spacedim, typename VectorType>
2001  const hp::QCollection<dim> &q,
2003  VectorType &rhs_vector,
2004  const ConstraintMatrix &constraints=ConstraintMatrix());
2005 
2057  template <int dim, int spacedim>
2059  const DoFHandler<dim,spacedim> &dof_handler,
2060  const Point<spacedim> &p,
2061  Vector<double> &rhs_vector);
2062 
2067  template <int dim, int spacedim>
2068  void create_point_source_vector(const DoFHandler<dim,spacedim> &dof_handler,
2069  const Point<spacedim> &p,
2070  Vector<double> &rhs_vector);
2071 
2075  template <int dim, int spacedim>
2077  const hp::DoFHandler<dim,spacedim> &dof_handler,
2078  const Point<spacedim> &p,
2079  Vector<double> &rhs_vector);
2080 
2087  template <int dim, int spacedim>
2089  const Point<spacedim> &p,
2090  Vector<double> &rhs_vector);
2091 
2110  template <int dim, int spacedim>
2112  const DoFHandler<dim,spacedim> &dof_handler,
2113  const Point<spacedim> &p,
2114  const Point<dim> &direction,
2115  Vector<double> &rhs_vector);
2116 
2121  template <int dim, int spacedim>
2122  void create_point_source_vector(const DoFHandler<dim,spacedim> &dof_handler,
2123  const Point<spacedim> &p,
2124  const Point<dim> &direction,
2125  Vector<double> &rhs_vector);
2126 
2130  template <int dim, int spacedim>
2132  const hp::DoFHandler<dim,spacedim> &dof_handler,
2133  const Point<spacedim> &p,
2134  const Point<dim> &direction,
2135  Vector<double> &rhs_vector);
2136 
2143  template <int dim, int spacedim>
2145  const Point<spacedim> &p,
2146  const Point<dim> &direction,
2147  Vector<double> &rhs_vector);
2148 
2158  template <int dim, int spacedim, typename VectorType>
2160  const DoFHandler<dim,spacedim> &dof,
2161  const Quadrature<dim-1> &q,
2163  VectorType &rhs_vector,
2164  const std::set<types::boundary_id> &boundary_ids = std::set<types::boundary_id>());
2165 
2173  template <int dim, int spacedim, typename VectorType>
2175  (const DoFHandler<dim,spacedim> &dof,
2176  const Quadrature<dim-1> &q,
2178  VectorType &rhs_vector,
2179  const std::set<types::boundary_id> &boundary_ids = std::set<types::boundary_id>());
2180 
2187  template <int dim, int spacedim, typename VectorType>
2189  (const hp::MappingCollection<dim,spacedim> &mapping,
2190  const hp::DoFHandler<dim,spacedim> &dof,
2191  const hp::QCollection<dim-1> &q,
2193  VectorType &rhs_vector,
2194  const std::set<types::boundary_id> &boundary_ids = std::set<types::boundary_id>());
2195 
2204  template <int dim, int spacedim, typename VectorType>
2206  (const hp::DoFHandler<dim,spacedim> &dof,
2207  const hp::QCollection<dim-1> &q,
2209  VectorType &rhs_vector,
2210  const std::set<types::boundary_id> &boundary_ids = std::set<types::boundary_id>());
2211 
2213 
2217 
2305  template <int dim, class InVector, class OutVector, int spacedim>
2306  void integrate_difference (const Mapping<dim,spacedim> &mapping,
2307  const DoFHandler<dim,spacedim> &dof,
2308  const InVector &fe_function,
2309  const Function<spacedim,double> &exact_solution,
2310  OutVector &difference,
2311  const Quadrature<dim> &q,
2312  const NormType &norm,
2313  const Function<spacedim,double> *weight = nullptr,
2314  const double exponent = 2.);
2315 
2320  template <int dim, class InVector, class OutVector, int spacedim>
2322  const InVector &fe_function,
2323  const Function<spacedim,double> &exact_solution,
2324  OutVector &difference,
2325  const Quadrature<dim> &q,
2326  const NormType &norm,
2327  const Function<spacedim,double> *weight = nullptr,
2328  const double exponent = 2.);
2329 
2333  template <int dim, class InVector, class OutVector, int spacedim>
2335  const hp::DoFHandler<dim,spacedim> &dof,
2336  const InVector &fe_function,
2337  const Function<spacedim,double> &exact_solution,
2338  OutVector &difference,
2339  const hp::QCollection<dim> &q,
2340  const NormType &norm,
2341  const Function<spacedim,double> *weight = nullptr,
2342  const double exponent = 2.);
2343 
2348  template <int dim, class InVector, class OutVector, int spacedim>
2350  const InVector &fe_function,
2351  const Function<spacedim,double> &exact_solution,
2352  OutVector &difference,
2353  const hp::QCollection<dim> &q,
2354  const NormType &norm,
2355  const Function<spacedim,double> *weight = nullptr,
2356  const double exponent = 2.);
2357 
2383  template <int dim, int spacedim, class InVector>
2385  const InVector &cellwise_error,
2386  const NormType &norm,
2387  const double exponent = 2.);
2388 
2401  template <int dim, typename VectorType, int spacedim>
2402  void point_difference
2403  (const DoFHandler<dim,spacedim> &dof,
2404  const VectorType &fe_function,
2407  const Point<spacedim> &point);
2408 
2421  template <int dim, typename VectorType, int spacedim>
2422  void point_difference
2423  (const Mapping<dim, spacedim> &mapping,
2424  const DoFHandler<dim,spacedim> &dof,
2425  const VectorType &fe_function,
2428  const Point<spacedim> &point);
2429 
2452  template <int dim, typename VectorType, int spacedim>
2453  void
2455  const VectorType &fe_function,
2456  const Point<spacedim> &point,
2458 
2476  template <int dim, typename VectorType, int spacedim>
2477  void
2479  const VectorType &fe_function,
2480  const Point<spacedim> &point,
2482 
2509  template <int dim, typename VectorType, int spacedim>
2510  typename VectorType::value_type
2512  const VectorType &fe_function,
2513  const Point<spacedim> &point);
2514 
2532  template <int dim, typename VectorType, int spacedim>
2533  typename VectorType::value_type
2535  const VectorType &fe_function,
2536  const Point<spacedim> &point);
2537 
2560  template <int dim, typename VectorType, int spacedim>
2561  void
2562  point_value (const Mapping<dim, spacedim> &mapping,
2563  const DoFHandler<dim,spacedim> &dof,
2564  const VectorType &fe_function,
2565  const Point<spacedim> &point,
2567 
2585  template <int dim, typename VectorType, int spacedim>
2586  void
2588  const hp::DoFHandler<dim,spacedim> &dof,
2589  const VectorType &fe_function,
2590  const Point<spacedim> &point,
2592 
2615  template <int dim, typename VectorType, int spacedim>
2616  typename VectorType::value_type
2617  point_value (const Mapping<dim,spacedim> &mapping,
2618  const DoFHandler<dim,spacedim> &dof,
2619  const VectorType &fe_function,
2620  const Point<spacedim> &point);
2621 
2639  template <int dim, typename VectorType, int spacedim>
2640  typename VectorType::value_type
2642  const hp::DoFHandler<dim,spacedim> &dof,
2643  const VectorType &fe_function,
2644  const Point<spacedim> &point);
2645 
2667  template <int dim, typename VectorType, int spacedim>
2668  void
2670  const VectorType &fe_function,
2671  const Point<spacedim> &point,
2673 
2690  template <int dim, typename VectorType, int spacedim>
2691  void
2693  const VectorType &fe_function,
2694  const Point<spacedim> &point,
2696 
2718  template <int dim, typename VectorType, int spacedim>
2721  const VectorType &fe_function,
2722  const Point<spacedim> &point);
2723 
2740  template <int dim, typename VectorType, int spacedim>
2743  const VectorType &fe_function,
2744  const Point<spacedim> &point);
2745 
2767  template <int dim, typename VectorType, int spacedim>
2768  void
2769  point_gradient (const Mapping<dim, spacedim> &mapping,
2770  const DoFHandler<dim,spacedim> &dof,
2771  const VectorType &fe_function,
2772  const Point<spacedim> &point,
2774 
2791  template <int dim, typename VectorType, int spacedim>
2792  void
2794  const hp::DoFHandler<dim,spacedim> &dof,
2795  const VectorType &fe_function,
2796  const Point<spacedim> &point,
2798 
2820  template <int dim, typename VectorType, int spacedim>
2822  point_gradient (const Mapping<dim,spacedim> &mapping,
2823  const DoFHandler<dim,spacedim> &dof,
2824  const VectorType &fe_function,
2825  const Point<spacedim> &point);
2826 
2843  template <int dim, typename VectorType, int spacedim>
2846  const hp::DoFHandler<dim,spacedim> &dof,
2847  const VectorType &fe_function,
2848  const Point<spacedim> &point);
2849 
2851 
2855 
2905  template <typename VectorType>
2906  void subtract_mean_value(VectorType &v,
2907  const std::vector<bool> &p_select = std::vector<bool>());
2908 
2909 
2933  template <int dim, typename VectorType, int spacedim>
2934  typename VectorType::value_type
2936  const DoFHandler<dim,spacedim> &dof,
2937  const Quadrature<dim> &quadrature,
2938  const VectorType &v,
2939  const unsigned int component);
2940 
2945  template <int dim, typename VectorType, int spacedim>
2946  typename VectorType::value_type
2948  const Quadrature<dim> &quadrature,
2949  const VectorType &v,
2950  const unsigned int component);
2952 
2982  template <int dim, int spacedim, template <int,int> class DoFHandlerType,
2983  typename VectorType>
2984  void get_position_vector(const DoFHandlerType<dim,spacedim> &dh,
2985  VectorType &vector,
2986  const ComponentMask &mask = ComponentMask());
2987 
2989 
2994  "The given point is inside a cell of a "
2995  "parallel::distributed::Triangulation that is not "
2996  "locally owned by this processor.");
2997 }
2998 
2999 
3000 DEAL_II_NAMESPACE_CLOSE
3001 
3002 #endif
void integrate_difference(const Mapping< dim, spacedim > &mapping, const DoFHandler< dim, spacedim > &dof, const InVector &fe_function, const Function< spacedim, double > &exact_solution, OutVector &difference, const Quadrature< dim > &q, const NormType &norm, const Function< spacedim, double > *weight=nullptr, const double exponent=2.)
void point_value(const DoFHandler< dim, spacedim > &dof, const VectorType &fe_function, const Point< spacedim > &point, Vector< typename VectorType::value_type > &value)
void compute_nonzero_tangential_flux_constraints(const DoFHandlerType< dim, spacedim > &dof_handler, const unsigned int first_vector_component, const std::set< types::boundary_id > &boundary_ids, typename FunctionMap< spacedim >::type &function_map, ConstraintMatrix &constraints, const Mapping< dim, spacedim > &mapping=StaticMappingQ1< dim >::mapping)
void project_boundary_values_curl_conforming(const DoFHandler< dim > &dof_handler, const unsigned int first_vector_component, const Function< dim, double > &boundary_function, const types::boundary_id boundary_component, ConstraintMatrix &constraints, const Mapping< dim > &mapping=StaticMappingQ1< dim >::mapping)
void point_difference(const DoFHandler< dim, spacedim > &dof, const VectorType &fe_function, const Function< spacedim, typename VectorType::value_type > &exact_solution, Vector< typename VectorType::value_type > &difference, const Point< spacedim > &point)
unsigned int boundary_id
Definition: types.h:110
void interpolate_based_on_material_id(const Mapping< dim, spacedim > &mapping, const DoFHandlerType< dim, spacedim > &dof_handler, const std::map< types::material_id, const Function< spacedim, typename VectorType::value_type > *> &function_map, VectorType &dst, const ComponentMask &component_mask=ComponentMask())
void compute_no_normal_flux_constraints(const DoFHandlerType< dim, spacedim > &dof_handler, const unsigned int first_vector_component, const std::set< types::boundary_id > &boundary_ids, ConstraintMatrix &constraints, const Mapping< dim, spacedim > &mapping=StaticMappingQ1< dim >::mapping)
ActiveSelector::active_cell_iterator active_cell_iterator
Definition: dof_handler.h:229
void compute_nonzero_normal_flux_constraints(const DoFHandlerType< dim, spacedim > &dof_handler, const unsigned int first_vector_component, const std::set< types::boundary_id > &boundary_ids, typename FunctionMap< spacedim >::type &function_map, ConstraintMatrix &constraints, const Mapping< dim, spacedim > &mapping=StaticMappingQ1< dim >::mapping)
void create_right_hand_side(const Mapping< dim, spacedim > &mapping, const DoFHandler< dim, spacedim > &dof, const Quadrature< dim > &q, const Function< spacedim, typename VectorType::value_type > &rhs, VectorType &rhs_vector, const ConstraintMatrix &constraints=ConstraintMatrix())
unsigned int material_id
Definition: types.h:133
void project(const Mapping< dim, spacedim > &mapping, const DoFHandler< dim, spacedim > &dof, const ConstraintMatrix &constraints, const Quadrature< dim > &quadrature, const Function< spacedim, typename VectorType::value_type > &function, VectorType &vec, const bool enforce_zero_boundary=false, const Quadrature< dim-1 > &q_boundary=(dim > 1 ? QGauss< dim-1 >(2) :Quadrature< dim-1 >(0)), const bool project_to_boundary_first=false)
void create_boundary_right_hand_side(const Mapping< dim, spacedim > &mapping, const DoFHandler< dim, spacedim > &dof, const Quadrature< dim-1 > &q, const Function< spacedim, typename VectorType::value_type > &rhs, VectorType &rhs_vector, const std::set< types::boundary_id > &boundary_ids=std::set< types::boundary_id >())
void compute_normal_flux_constraints(const DoFHandlerType< dim, spacedim > &dof_handler, const unsigned int first_vector_component, const std::set< types::boundary_id > &boundary_ids, ConstraintMatrix &constraints, const Mapping< dim, spacedim > &mapping=StaticMappingQ1< dim >::mapping)
void get_position_vector(const DoFHandlerType< dim, spacedim > &dh, VectorType &vector, const ComponentMask &mask=ComponentMask())
void point_gradient(const DoFHandler< dim, spacedim > &dof, const VectorType &fe_function, const Point< spacedim > &point, std::vector< Tensor< 1, spacedim, typename VectorType::value_type > > &value)
Abstract base class for mapping classes.
Definition: dof_tools.h:46
#define DeclExceptionMsg(Exception, defaulttext)
Definition: exceptions.h:335
static ::ExceptionBase & ExcPointNotAvailableHere()
void subtract_mean_value(VectorType &v, const std::vector< bool > &p_select=std::vector< bool >())
void interpolate(const Mapping< dim, spacedim > &mapping, const DoFHandlerType< dim, spacedim > &dof, const Function< spacedim, typename VectorType::value_type > &function, VectorType &vec, const ComponentMask &component_mask=ComponentMask())
std::map< types::boundary_id, const Function< dim, Number > * > type
Definition: function_map.h:81
void create_point_source_vector(const Mapping< dim, spacedim > &mapping, const DoFHandler< dim, spacedim > &dof_handler, const Point< spacedim > &p, Vector< double > &rhs_vector)
VectorType::value_type compute_mean_value(const Mapping< dim, spacedim > &mapping, const DoFHandler< dim, spacedim > &dof, const Quadrature< dim > &quadrature, const VectorType &v, const unsigned int component)
Definition: hp.h:102
void project_boundary_values(const Mapping< dim, spacedim > &mapping, const DoFHandler< dim, spacedim > &dof, const std::map< types::boundary_id, const Function< spacedim, number > *> &boundary_functions, const Quadrature< dim-1 > &q, std::map< types::global_dof_index, number > &boundary_values, std::vector< unsigned int > component_mapping=std::vector< unsigned int >())
void interpolate_boundary_values(const Mapping< dim, spacedim > &mapping, const DoFHandlerType< dim, spacedim > &dof, const std::map< types::boundary_id, const Function< spacedim, number > *> &function_map, std::map< types::global_dof_index, number > &boundary_values, const ComponentMask &component_mask=ComponentMask())
Definition: mpi.h:53
void project_boundary_values_curl_conforming_l2(const DoFHandler< dim > &dof_handler, const unsigned int first_vector_component, const Function< dim, double > &boundary_function, const types::boundary_id boundary_component, ConstraintMatrix &constraints, const Mapping< dim > &mapping=StaticMappingQ1< dim >::mapping)
double compute_global_error(const Triangulation< dim, spacedim > &tria, const InVector &cellwise_error, const NormType &norm, const double exponent=2.)
void project_boundary_values_div_conforming(const DoFHandler< dim > &dof_handler, const unsigned int first_vector_component, const Function< dim, double > &boundary_function, const types::boundary_id boundary_component, ConstraintMatrix &constraints, const Mapping< dim > &mapping=StaticMappingQ1< dim >::mapping)
void interpolate_to_different_mesh(const DoFHandlerType< dim, spacedim > &dof1, const VectorType &u1, const DoFHandlerType< dim, spacedim > &dof2, VectorType &u2)