1 #ifndef EXERCISE_3_ERRORESTIMATOR_H_ 2 #define EXERCISE_3_ERRORESTIMATOR_H_ 12 #include <Eigen/Dense> 17 template<
typename ConfiguratorType>
28 typedef typename Eigen::Matrix<RealType, 3, 1>
VecType;
37 const VectorType &numericalSolution,
45 _mesh.refineMarkedTriangles();
58 return errEstimates.norm();
Helper class to evaluate a discrete nodal function on a given mesh.
const shellFE::DiscreteFunctionDefaultShellFE< ConfiguratorType > _numericalSolution
const TriangleType & getTriang(const int num) const
ErrorEstimator(MeshType &mesh, const ConfiguratorType &config, const VectorType &numericalSolution, RealType gamma=0.4)
Constructor.
Class for local error estimation.
DataTypeContainer::DomVecType DomVecType
DataTypeContainer::RealType RealType
ConfiguratorType::InitType MeshType
int getNumTriangs() const
Eigen::VectorXd VectorType
void computeH(VectorType &h) const
Compute length on longest edge for each element.
RealType markAndRefineTriangles()
ConfiguratorType::DomVecType DomVecType
DataTypeContainer::TangentVecType TangentVecType
ConfiguratorType::RealType RealType
ConfiguratorType::TangentVecType TangentVecType
MeshType & getMesh()
Returns reference to the mesh that was used for initialization of this object.
Eigen::Matrix< RealType, 3, 1 > VecType
Configurator for Finite Elements.
const TangentVecType & getEdge(int i) const
Access edge i.
void computeLocalErrorEstimates(VectorType &errEstimates) const