bempp_cl.api.assembly.boundary_operator

Implementation of boundary operators.

Classes

BoundaryOperator

A base class for boundary operators.

BoundaryOperatorWithAssembler

Implements a boundary operator together with an assembler.

_SumBoundaryOperator

Return the sum of two boundary operators.

_ScaledBoundaryOperator

Scale a boundary operator.

_ProductBoundaryOperator

Multiply two boundary operators.

ZeroBoundaryOperator

A boundary operator that represents a zero operator.

MultiplicationOperator

Returns a weak multiplication operator with a grid function.

Module Contents

class bempp_cl.api.assembly.boundary_operator.BoundaryOperator(domain, range_, dual_to_range, parameters)

Bases: object

A base class for boundary operators.

_domain
_range
_dual_to_range
_parameters
_cached = None
_range_map = None
property domain

Return the domain space of the operator.

property range

Return the range space of the operator.

property dual_to_range

Return the dual to range space of the operator.

property parameters

Return the parameters associated with the operator.

weak_form()

Return the weak form (assemble if necessary).

strong_form()

Return a discrete operator that maps into the range space.

__mul__(other)

Return product with a scalar, grid function or other operator.

__matmul__(other)

Multiply by another operator.

__rmul__(other)

Multiply by another operator.

__add__(other)

Return sum of two boundary operators.

__neg__()

Negate an operator.

__sub__(other)

Subtract two operators.

class bempp_cl.api.assembly.boundary_operator.BoundaryOperatorWithAssembler(domain, range_, dual_to_range, assembler, operator_descriptor, transpose=False)

Bases: BoundaryOperator

Implements a boundary operator together with an assembler.

_assembler
_operator_descriptor
transpose_ = False
property assembler

Return the assembler associated with this operator.

property descriptor

Operator descriptor.

_assemble()

Assemble the operator.

_transpose(_range)
class bempp_cl.api.assembly.boundary_operator._SumBoundaryOperator(op1, op2)

Bases: BoundaryOperator

Return the sum of two boundary operators.

_op1
_op2
_assemble()

Implement the weak form.

class bempp_cl.api.assembly.boundary_operator._ScaledBoundaryOperator(op, alpha)

Bases: BoundaryOperator

Scale a boundary operator.

_op
_alpha
_assemble()

Implement the weak form.

class bempp_cl.api.assembly.boundary_operator._ProductBoundaryOperator(op1, op2)

Bases: BoundaryOperator

Multiply two boundary operators.

_op1
_op2
_assemble()

Implement the weak form.

class bempp_cl.api.assembly.boundary_operator.ZeroBoundaryOperator(domain, range_, dual_to_range)

Bases: BoundaryOperator

A boundary operator that represents a zero operator.

Parameters

domainbempp_cl.api.space.Space

Domain space of the operator.

range_bempp_cl.api.space.Space

Range space of the operator.

dual_to_rangebempp_cl.api.space.Space

Dual space to the range space.

_assemble()
__iadd__(other)

Add.

__isub__(other)

Subtract.

class bempp_cl.api.assembly.boundary_operator.MultiplicationOperator(grid_function, domain, range_, dual_to_range, parameters=None, mode='component')

Bases: BoundaryOperator

Returns a weak multiplication operator with a grid function.

Given a grid function g, this operator assembles a sparse matrix that implements weak multiplication with g in a given basis.

_mode = 'component'
_grid_fun
_assemble()

Assemble the operator.