GenericAdaptiveVariationalSolver

class dolfin.cpp.fem.GenericAdaptiveVariationalSolver(*args, **kwargs)

Bases: dolfin.cpp.common.Variable

An abstract class for goal-oriented adaptive solution of variational problems.

adapt_problem()

Adapt the problem to other mesh. Must be overloaded in subclass.

Arguments
mesh (Mesh)
The other mesh
adaptive_data()

Return stored adaptive data

Returns
list of Parameters
The data stored in the adaptive loop
static default_parameters()

Default parameter values:

“max_iterations” (int) “max_dimension” (int) “plot_mesh” (bool) “save_data” (bool) “data_label” (std::string) “reference” (double) “marking_strategy” (std::string) “marking_fraction” (double)
evaluate_goal()

Evaluate the goal functional. Must be overloaded in subclass.

Arguments
M (Form)
The functional to be evaluated
u (Function)
The function of which to evaluate the functional
Returns
float
The value of M evaluated at u
extract_bcs()

Extract the boundary conditions for the primal problem. Must be overloaded in subclass.

Returns
list of DirichletBC
The primal boundary conditions
solve()

Solve such that the functional error is less than the given tolerance. Note that each call to solve is based on the leaf-node of the variational problem

Arguments
tol (float)
The error tolerance
solve_primal()

Solve the primal problem. Must be overloaded in subclass.

Returns
Function
The solution to the primal problem
summary()

Present summary of all adaptive data and parameters

thisown

The membership flag