16 #ifndef dealii_error_estimator_h 17 #define dealii_error_estimator_h 20 #include <deal.II/base/config.h> 22 #include <deal.II/base/exceptions.h> 23 #include <deal.II/base/function.h> 25 #include <deal.II/dofs/deprecated_function_map.h> 27 #include <deal.II/fe/component_mask.h> 31 DEAL_II_NAMESPACE_OPEN
260 template <
int dim,
int spacedim = dim>
339 template <
typename InputVector,
typename DoFHandlerType>
343 const DoFHandlerType & dof,
348 const InputVector & solution,
349 Vector<float> & error,
361 template <
typename InputVector,
typename DoFHandlerType>
364 const DoFHandlerType & dof,
369 const InputVector & solution,
370 Vector<float> & error,
391 template <
typename InputVector,
typename DoFHandlerType>
395 const DoFHandlerType & dof,
400 const std::vector<const InputVector *> &solutions,
401 std::vector<Vector<float> *> & errors,
413 template <
typename InputVector,
typename DoFHandlerType>
416 const DoFHandlerType & dof,
421 const std::vector<const InputVector *> &solutions,
422 std::vector<Vector<float> *> & errors,
435 template <
typename InputVector,
typename DoFHandlerType>
439 const DoFHandlerType & dof,
444 const InputVector & solution,
445 Vector<float> & error,
458 template <
typename InputVector,
typename DoFHandlerType>
461 const DoFHandlerType & dof,
466 const InputVector & solution,
467 Vector<float> & error,
480 template <
typename InputVector,
typename DoFHandlerType>
484 const DoFHandlerType & dof,
489 const std::vector<const InputVector *> &solutions,
490 std::vector<Vector<float> *> & errors,
503 template <
typename InputVector,
typename DoFHandlerType>
506 const DoFHandlerType & dof,
511 const std::vector<const InputVector *> &solutions,
512 std::vector<Vector<float> *> & errors,
524 "You provided a ComponentMask argument that is invalid. " 525 "Component masks need to be either default constructed " 526 "(in which case they indicate that every component is " 527 "selected) or need to have a length equal to the number " 528 "of vector components of the finite element in use " 529 "by the DoFHandler object. In the latter case, at " 530 "least one component needs to be selected.");
536 "If you do specify the argument for a (possibly " 537 "spatially variable) coefficient function for this function, " 538 "then it needs to refer to a coefficient that is either " 539 "scalar (has one vector component) or has as many vector " 540 "components as there are in the finite element used by " 541 "the DoFHandler argument.");
549 <<
"You provided a function map that for boundary indicator " 550 << arg1 <<
" specifies a function with " << arg2
551 <<
" vector components. However, the finite " 552 "element in use has " 554 <<
" components, and these two numbers need to match.");
561 <<
"The number of input vectors, " << arg1
562 <<
" needs to be equal to the number of output vectors, " 564 <<
". This is not the case in your call of this function.");
569 "You need to specify at least one solution vector as " 586 template <
int spacedim>
627 template <
typename InputVector,
typename DoFHandlerType>
631 const DoFHandlerType & dof,
636 const InputVector & solution,
637 Vector<float> & error,
649 template <
typename InputVector,
typename DoFHandlerType>
652 const DoFHandlerType &dof,
657 const InputVector & solution,
658 Vector<float> & error,
679 template <
typename InputVector,
typename DoFHandlerType>
683 const DoFHandlerType & dof,
688 const std::vector<const InputVector *> &solutions,
689 std::vector<Vector<float> *> & errors,
701 template <
typename InputVector,
typename DoFHandlerType>
704 const DoFHandlerType &dof,
709 const std::vector<const InputVector *> &solutions,
710 std::vector<Vector<float> *> & errors,
723 template <
typename InputVector,
typename DoFHandlerType>
727 const DoFHandlerType & dof,
732 const InputVector & solution,
733 Vector<float> & error,
746 template <
typename InputVector,
typename DoFHandlerType>
749 const DoFHandlerType & dof,
754 const InputVector & solution,
755 Vector<float> & error,
768 template <
typename InputVector,
typename DoFHandlerType>
772 const DoFHandlerType & dof,
777 const std::vector<const InputVector *> &solutions,
778 std::vector<Vector<float> *> & errors,
791 template <
typename InputVector,
typename DoFHandlerType>
794 const DoFHandlerType & dof,
799 const std::vector<const InputVector *> &solutions,
800 std::vector<Vector<float> *> & errors,
812 "You provided a ComponentMask argument that is invalid. " 813 "Component masks need to be either default constructed " 814 "(in which case they indicate that every component is " 815 "selected) or need to have a length equal to the number " 816 "of vector components of the finite element in use " 817 "by the DoFHandler object. In the latter case, at " 818 "least one component needs to be selected.");
824 "If you do specify the argument for a (possibly " 825 "spatially variable) coefficient function for this function, " 826 "then it needs to refer to a coefficient that is either " 827 "scalar (has one vector component) or has as many vector " 828 "components as there are in the finite element used by " 829 "the DoFHandler argument.");
837 <<
"You provided a function map that for boundary indicator " 838 << arg1 <<
" specifies a function with " << arg2
839 <<
" vector components. However, the finite " 840 "element in use has " 842 <<
" components, and these two numbers need to match.");
849 <<
"The number of input vectors, " << arg1
850 <<
" needs to be equal to the number of output vectors, " 852 <<
". This is not the case in your call of this function.");
857 "You need to specify at least one solution vector as " 863 DEAL_II_NAMESPACE_CLOSE
static ::ExceptionBase & ExcInvalidBoundaryFunction(types::boundary_id arg1, int arg2, int arg3)
static const unsigned int invalid_unsigned_int
#define DeclException2(Exception2, type1, type2, outsequence)
static ::ExceptionBase & ExcInvalidCoefficient()
static void estimate(const Mapping< dim, spacedim > &mapping, const DoFHandlerType &dof, const Quadrature< dim - 1 > &quadrature, const std::map< types::boundary_id, const Function< spacedim, typename InputVector::value_type > *> &neumann_bc, const InputVector &solution, Vector< float > &error, const ComponentMask &component_mask=ComponentMask(), const Function< spacedim > *coefficients=nullptr, const unsigned int n_threads=numbers::invalid_unsigned_int, const types::subdomain_id subdomain_id=numbers::invalid_subdomain_id, const types::material_id material_id=numbers::invalid_material_id, const Strategy strategy=cell_diameter_over_24)
const types::subdomain_id invalid_subdomain_id
static ::ExceptionBase & ExcInvalidComponentMask()
unsigned int subdomain_id
Abstract base class for mapping classes.
#define DeclExceptionMsg(Exception, defaulttext)
static ::ExceptionBase & ExcIncompatibleNumberOfElements(int arg1, int arg2)
Kelly error estimator with the factor .
#define DeclException3(Exception3, type1, type2, type3, outsequence)
Kelly error estimator with the factor .
const types::material_id invalid_material_id
static ::ExceptionBase & ExcNoSolutions()