h1_error.push_back (h1_error_per_cell.l2_norm());
cout << " Estimating H1 error... ";
- KellyErrorEstimator<dim> ee;
+
QSimpson<dim-1> eq;
- ee.estimate_error (*dof, eq,
- KellyErrorEstimator<dim>::FunctionMap(),
- solution,
- estimated_error_per_cell,
- ((prm.get("Test case")=="Kink") ?
- &kink_coefficient : 0 ));
+ KellyErrorEstimator<dim>::estimate (*dof, eq,
+ KellyErrorEstimator<dim>::FunctionMap(),
+ solution,
+ estimated_error_per_cell,
+ ((prm.get("Test case")=="Kink") ?
+ &kink_coefficient : 0 ));
cout << estimated_error_per_cell.l2_norm() << endl;
estimated_error.push_back (estimated_error_per_cell.l2_norm());
* value which denotes the constant
* coefficient with value one.
*/
- static void estimate_error (const DoFHandler<dim> &dof,
- const Quadrature<dim-1> &quadrature,
- const FunctionMap &neumann_bc,
- const Vector<double> &solution,
- Vector<float> &error,
- const Function<dim> *coefficient = 0);
+ static void estimate (const DoFHandler<dim> &dof,
+ const Quadrature<dim-1> &quadrature,
+ const FunctionMap &neumann_bc,
+ const Vector<double> &solution,
+ Vector<float> &error,
+ const Function<dim> *coefficient = 0);
/**
* Exception
+
/*---------------------------- error_estimator.h ---------------------------*/
/* end of #ifndef __error_estimator_H */
#endif
#if deal_II_dimension == 1
template <>
-void KellyErrorEstimator<1>::estimate_error (const DoFHandler<1> &,
- const Quadrature<0> &,
- const FunctionMap &,
- const Vector<double> &,
- Vector<float> &,
- const Function<1> *) {
+void KellyErrorEstimator<1>::estimate (const DoFHandler<1> &,
+ const Quadrature<0> &,
+ const FunctionMap &,
+ const Vector<double> &,
+ Vector<float> &,
+ const Function<1> *) {
Assert(false, ExcNotImplemented());
};
template <int dim>
-void KellyErrorEstimator<dim>::estimate_error (const DoFHandler<dim> &dof,
- const Quadrature<dim-1> &quadrature,
- const FunctionMap &neumann_bc,
- const Vector<double> &solution,
- Vector<float> &error,
- const Function<dim> *coefficient) {
+void KellyErrorEstimator<dim>::estimate (const DoFHandler<dim> &dof,
+ const Quadrature<dim-1> &quadrature,
+ const FunctionMap &neumann_bc,
+ const Vector<double> &solution,
+ Vector<float> &error,
+ const Function<dim> *coefficient)
+{
Assert (neumann_bc.find(255) == neumann_bc.end(),
ExcInvalidBoundaryIndicator());
h1_error.push_back (h1_error_per_cell.l2_norm());
cout << " Estimating H1 error... ";
- KellyErrorEstimator<dim> ee;
+
QSimpson<dim-1> eq;
- ee.estimate_error (*dof, eq,
- KellyErrorEstimator<dim>::FunctionMap(),
- solution,
- estimated_error_per_cell,
- ((prm.get("Test case")=="Kink") ?
- &kink_coefficient : 0 ));
+ KellyErrorEstimator<dim>::estimate (*dof, eq,
+ KellyErrorEstimator<dim>::FunctionMap(),
+ solution,
+ estimated_error_per_cell,
+ ((prm.get("Test case")=="Kink") ?
+ &kink_coefficient : 0 ));
cout << estimated_error_per_cell.l2_norm() << endl;
estimated_error.push_back (estimated_error_per_cell.l2_norm());