# ErrorControl¶

class dolfin.cpp.fem.ErrorControl

(Goal-oriented) Error Control class. The notation used here follows the notation in “Automated goal-oriented error control I: stationary variational problems”, ME Rognes and A Logg, 2010-2011.

Create error control object

Parameters: Form > a_star (std::shared_ptr<) – (Form ) the bilinear form for the dual problem Form > L_star (std::shared_ptr<) – (Form ) the linear form for the dual problem Form > residual (std::shared_ptr<) – (Form ) a functional for the residual (error estimate) Form > a_R_T (std::shared_ptr<) – (Form ) the bilinear form for the strong cell residual problem Form > L_R_T (std::shared_ptr<) – (Form ) the linear form for the strong cell residual problem Form > a_R_dT (std::shared_ptr<) – (Form ) the bilinear form for the strong facet residual problem Form > L_R_dT (std::shared_ptr<) – (Form ) the linear form for the strong facet residual problem Form > eta_T (std::shared_ptr<) – (Form ) a linear form over DG_0 for error indicators is_linear (bool) – (bool) true iff primal problem is linear
compute_cell_residual()

Compute representation for the strong cell residual from the weak residual

Parameters: & R_T (Function) – (Function ) the strong cell residual (to be computed) Function & u (const) – (Function ) the primal approximation void
compute_dual()

Compute dual approximation defined by dual variational problem and dual boundary conditions given by homogenized primal boundary conditions.

Parameters: & z (Function) – (Function ) the dual approximation (to be computed) std::vector< std::shared_ptr< const DirichletBC > > bcs (const) – (std::vector) the primal boundary conditions void
compute_extrapolation()

Compute extrapolation with boundary conditions

Parameters: Function & z (const) – (Function ) the extrapolated function (to be computed) std::vector< std::shared_ptr< const DirichletBC > > bcs (const) – (std::vector) the dual boundary conditions void
compute_facet_residual()

Compute representation for the strong facet residual from the weak residual and the strong cell residual

Parameters: & R_dT (SpecialFacetFunction) – (SpecialFacetFunction ) the strong facet residual (to be computed) Function & u (const) – (Function ) the primal approximation Function & R_T (const) – (Function ) the strong cell residual void
compute_indicators()

Compute error indicators

Parameters: double > & indicators (MeshFunction<) – (MeshFunction) the error indicators (to be computed) Function & u (const) – (Function ) the primal approximation void
static default_parameters()
estimate_error()

Estimate the error relative to the goal M of the discrete approximation ‘u’ relative to the variational formulation by evaluating the weak residual at an approximation to the dual solution.

Parameters: Function & u (const) – (Function ) the primal approximation std::vector< std::shared_ptr< const DirichletBC > > bcs (const) – (std::vector) the primal boundary conditions double double error estimate
residual_representation()

Compute strong representation (strong cell and facet residuals) of the weak residual.

Parameters: & R_T (Function) – (Function ) the strong cell residual (to be computed) & R_dT (SpecialFacetFunction) – (SpecialFacetFunction ) the strong facet residual (to be computed) Function & u (const) – (Function ) the primal approximation void
thisown

The membership flag