pymor.discretizers.skfem.cg

Module Contents

class pymor.discretizers.skfem.cg.AdvectionOperator(basis, advection_function, dirichlet_dofs=None, dirichlet_clear_diag=False, name=None)[source]

Bases: SKFemBilinearFormOperator

Base class for operators which assemble into a NumpyMatrixOperator.

sparse[source]

True if the operator assembles into a sparse matrix, False if the operator assembles into a dense matrix, None if unknown.

Methods

build_form

build_form(mu)[source]
class pymor.discretizers.skfem.cg.BoundaryDirichletFunctional(basis, dirichlet_data, dirichlet_dofs=None, name=None)[source]

Bases: pymor.operators.numpy.NumpyMatrixBasedOperator

Base class for operators which assemble into a NumpyMatrixOperator.

sparse[source]

True if the operator assembles into a sparse matrix, False if the operator assembles into a dense matrix, None if unknown.

source[source]
class pymor.discretizers.skfem.cg.DiffusionOperator(basis, diffusion_function, dirichlet_dofs=None, dirichlet_clear_diag=False, name=None)[source]

Bases: SKFemBilinearFormOperator

Base class for operators which assemble into a NumpyMatrixOperator.

sparse[source]

True if the operator assembles into a sparse matrix, False if the operator assembles into a dense matrix, None if unknown.

Methods

build_form

build_form(mu)[source]
class pymor.discretizers.skfem.cg.L2Functional(basis, function, dirichlet_dofs=None, dirichlet_data=None, name=None)[source]

Bases: SKFemLinearFormOperator

Base class for operators which assemble into a NumpyMatrixOperator.

sparse[source]

True if the operator assembles into a sparse matrix, False if the operator assembles into a dense matrix, None if unknown.

Methods

build_form

build_form(mu)[source]
class pymor.discretizers.skfem.cg.L2ProductOperator(basis, dirichlet_dofs=None, dirichlet_clear_diag=False, coefficient_function=None, name=None)[source]

Bases: SKFemBilinearFormOperator

Base class for operators which assemble into a NumpyMatrixOperator.

sparse[source]

True if the operator assembles into a sparse matrix, False if the operator assembles into a dense matrix, None if unknown.

Methods

build_form

build_form(mu)[source]
class pymor.discretizers.skfem.cg.SKFemBilinearFormOperator(basis, dirichlet_dofs=None, dirichlet_clear_diag=False, name=None)[source]

Bases: pymor.operators.numpy.NumpyMatrixBasedOperator

Base class for operators which assemble into a NumpyMatrixOperator.

sparse[source]

True if the operator assembles into a sparse matrix, False if the operator assembles into a dense matrix, None if unknown.

Methods

build_form

build_form(mu)[source]
class pymor.discretizers.skfem.cg.SKFemLinearFormOperator(basis, dirichlet_dofs=None, name=None)[source]

Bases: pymor.operators.numpy.NumpyMatrixBasedOperator

Base class for operators which assemble into a NumpyMatrixOperator.

sparse[source]

True if the operator assembles into a sparse matrix, False if the operator assembles into a dense matrix, None if unknown.

source[source]
class pymor.discretizers.skfem.cg.SKFemVisualizer(space, basis)[source]

Bases: pymor.core.base.ImmutableObject

Base class for immutable objects in pyMOR.

Instances of ImmutableObject are immutable in the sense that after execution of __init__, any modification of a non-private attribute will raise an exception.

Warning

For instances of ImmutableObject, the result of member function calls should be completely determined by the function’s arguments together with the object’s __init__ arguments and the current state of pyMOR’s global defaults.

While, in principle, you are allowed to modify private members after instance initialization, this should never affect the outcome of future method calls. In particular, if you update any internal state after initialization, you have to ensure that this state is not affected by possible changes of the global defaults.

Methods

visualize

visualize(U, **kwargs)[source]
pymor.discretizers.skfem.cg.discretize_stationary_cg(analytical_problem, diameter=None, mesh_type=None, element=None, preassemble=True)[source]

Discretizes a StationaryProblem with finite elements using scikit-fem.

Parameters

analytical_problem

The StationaryProblem to discretize.

diameter

If not None, diameter is passed as an argument to the domain_discretizer.

mesh_type

If not None, a skfem.Mesh to be used for discretizing the domain of analytical_problem.

element

If not None, the skfem.Element to be used for building the finite element space. If None, mesh.elem() is used.

preassemble

If True, preassemble all operators in the resulting Model.

Returns

m

The Model that has been generated.

data

Dictionary with the following entries:

mesh:

The generated skfem.Mesh.

basis:

The generated skfem.Basis.

boundary_facets:

Dict of boundary_facets of mesh per boundary type.

dirichlet_dofs:

DOFs of the skfem.Basis associated with the Dirichlet boundary.

unassembled_m:

In case preassemble is True, the generated Model before preassembling operators.