20#ifndef LIBMESH_ERROR_ESTIMATOR_H
21#define LIBMESH_ERROR_ESTIMATOR_H
24#include "libmesh/libmesh_common.h"
25#include "libmesh/system_norm.h"
41template <
typename T>
class NumericVector;
98 bool estimate_parent_error =
false) = 0;
113 const std::map<const System *, SystemNorm> & error_norms,
115 bool estimate_parent_error =
false);
121 typedef std::map<std::pair<const System *, unsigned int>, std::unique_ptr<ErrorVector>>
ErrorMap;
138 bool estimate_parent_error =
false);
167 void reduce_error (std::vector<ErrorVectorReal> & error_per_cell,
void ErrorVector unsigned int
This is the EquationSystems class.
This class holds functions that will estimate the error in a finite element solution on a given mesh.
ErrorEstimator & operator=(const ErrorEstimator &)=default
virtual ~ErrorEstimator()=default
void reduce_error(std::vector< ErrorVectorReal > &error_per_cell, const Parallel::Communicator &comm) const
This method takes the local error contributions in error_per_cell from each processor and combines th...
ErrorEstimator(const ErrorEstimator &)=default
Copy/move ctor, copy/move assignment operator, and destructor are all explicitly defaulted for this s...
virtual ErrorEstimatorType type() const =0
SystemNorm error_norm
When estimating the error in a single system, the error_norm is used to control the scaling and norm ...
virtual void estimate_errors(const EquationSystems &equation_systems, ErrorVector &error_per_cell, const std::map< const System *, SystemNorm > &error_norms, const std::map< const System *, const NumericVector< Number > * > *solution_vectors=nullptr, bool estimate_parent_error=false)
This virtual function can be redefined in derived classes, but by default computes the sum of the err...
std::map< std::pair< const System *, unsigned int >, std::unique_ptr< ErrorVector > > ErrorMap
When calculating many error vectors at once, we need a data structure to hold them all.
virtual void estimate_error(const System &system, ErrorVector &error_per_cell, const NumericVector< Number > *solution_vector=nullptr, bool estimate_parent_error=false)=0
This pure virtual function must be redefined in derived classes to compute the error for each active ...
ErrorEstimator()=default
Constructor.
ErrorEstimator(ErrorEstimator &&)=default
The ErrorVector is a specialization of the StatisticsVector for error data computed on a finite eleme...
Provides a uniform interface to vector storage schemes for different linear algebra libraries.
This class defines a norm/seminorm to be applied to a NumericVector which contains coefficients in a ...
Manages consistently variables, degrees of freedom, and coefficient vectors.
The libMesh namespace provides an interface to certain functionality in the library.
ErrorEstimatorType
Defines an enum for the different types of error estimators which are available.