pymor.bindings.dunegdt¶
Module Contents¶
Classes¶
Wraps a vector from dune-xt to make it usable with ListVectorArray. |
|
Required for DuneXTVectorSpace, Usually not to be used directly. |
|
A |
|
Wraps a dune-xt matrix as an |
- class pymor.bindings.dunegdt.DuneXTVector(impl)[source]¶
Bases:
pymor.vectorarrays.list.CopyOnWriteVectorWraps a vector from dune-xt to make it usable with ListVectorArray.
Parameters
- impl
The actual vector from dune.xt.la, usually IstlVector.
- class pymor.bindings.dunegdt.ComplexifiedDuneXTVector(real_part, imag_part)[source]¶
Bases:
pymor.vectorarrays.list.ComplexifiedVectorRequired for DuneXTVectorSpace, Usually not to be used directly.
- class pymor.bindings.dunegdt.DuneXTVectorSpace(dim, dune_vector_type=IstlVector, id='STATE')[source]¶
Bases:
pymor.vectorarrays.list.ComplexifiedListVectorSpaceA
VectorSpaceyielding DuneXTVectorParameters
- dim
Dimension of the
VectorSpace, i.e., length of the resulting vectors.- vector_type
Type of the actual vector from dune.xt.la, usually IstlVector.
- id
Identifier of the
VectorSpace.
- class pymor.bindings.dunegdt.DuneXTMatrixOperator(matrix, source_id='STATE', range_id='STATE', solver_options=None, name=None)[source]¶
Bases:
pymor.operators.list.LinearComplexifiedListVectorArrayOperatorBaseWraps a dune-xt matrix as an
Operator.Parameters
- matrix
The actual matrix from dune.xt.la, usually IstlMatrix.
- source_id
Identifier of the source
VectorSpace.- range_id
Identifier of the source
VectorSpace.- solver_options
If specified, either a string or a dict specifying the solver used in apply_inverse. See https://zivgitlab.uni-muenster.de/ag-ohlberger/dune-community/dune-xt/-/tree/master/dune/xt/la/solver for available options, depending on the type of
matrix. E.g., for dune.xt.la.IstlSparseMatrix, (as can be queried from dune.xt.la.IstlSparseMatrixSolver viatypes()andoptions(type)): - ‘bicgstab.ssor’ - ‘bicgstab.amg.ssor’ - ‘bicgstab.amg.ilu0’ - ‘bicgstab.ilut’ - ‘bicgstab’ - ‘cg’- name
Optional name of the resulting
Operator.
- _real_apply_inverse_one_vector(self, v, mu=None, initial_guess=None, least_squares=False, prepare_data=None)[source]¶
- _assemble_lincomb(self, operators, coefficients, identity_shift=0.0, solver_options=None, name=None)[source]¶
Try to assemble a linear combination of the given operators.
Returns a new
Operatorwhich represents the sumc_1*O_1 + ... + c_N*O_N + s*I
where
O_iareOperators,c_i,sscalar coefficients andIthe identity.This method is called in the
assemblemethod ofLincombOperatoron the first of its operators. If an assembly of the given linear combination is possible, e.g. the linear combination of the system matrices of the operators can be formed, then the assembled operator is returned. Otherwise, the method returnsNoneto indicate that assembly is not possible.Parameters
- operators
List of
OperatorsO_iwhose linear combination is formed.- coefficients
List of the corresponding linear coefficients
c_i.- identity_shift
The coefficient
s.- solver_options
solver_optionsfor the assembled operator.- name
Name of the assembled operator.
Returns
The assembled
Operatorif assembly is possible, otherwiseNone.