pymor.discretizers.fenics.cg
¶
Module Contents¶
- pymor.discretizers.fenics.cg.discretize_stationary_cg(analytical_problem, diameter=None, degree=1, preassemble=True)[source]¶
Discretizes a
StationaryProblem
with finite elements using FEniCS.- Parameters:
analytical_problem – The
StationaryProblem
to discretize.diameter – If not
None
,diameter
is passed as an argument to thedomain_discretizer
.degree – polynomial degree of the finite element.
preassemble – If
True
, preassemble all operators in the resultingModel
.
- Returns:
m – The
Model
that has been generated.data – Dictionary with the following entries:
- mesh:
The generated dolfin mesh object.
- boundary_mask:
Codim-1
MeshFunctionSizet
indicating which boundary type a boundary facet belongs to.- boundary_ids:
Dict mapping boundary types to ids used in
boundary_mask
.- unassembled_m:
In case
preassemble
isTrue
, the generatedModel
before preassembling operators.