OperatorTemplate#

class OperatorTemplate[source]#

Template for general operators \(\Ophat_{\ell}(\qhat,\u).\)

In this package, an “operator” is a function \(\Ophat_{\ell}: \RR^r \times \RR^m \to \RR^r\) that acts on a state vector \(\qhat\in\RR^r\) and (optionally) an input vector \(\u\in\RR^m\).

Models are defined as the sum of several operators, for example, an opinf.models.ContinuousModel object represents a system of ordinary differential equations:

\[\ddt\qhat(t) = \sum_{\ell=1}^{n_\textrm{terms}}\Ophat_{\ell}(\qhat(t),\u(t)).\]

Notes

This class can be used for custom nonparametric model terms that are not learnable with Operator Inference. For parametric model terms, see ParametricOperatorTemplate. For model terms that can be learned with Operator Inference, see OpInfOperator or ParametricOpInfOperator.

Properties:
state_dimension#

Dimension \(r\) of the state \(\qhat\) that the operator acts on.

Methods:

apply

Apply the operator mapping to the given state / input.

copy

Return a copy of the operator using copy.deepcopy().

galerkin

Get the (Petrov-)Galerkin projection of this operator.

jacobian

Construct the state Jacobian of the operator.

load

Load an operator from an HDF5 file.

save

Save the operator to an HDF5 file.

verify

Verify consistency between dimension properties and required methods.