galerkin()

galerkin()#

AffineConstantOperator.galerkin(Vr, Wr=None)#

Project this operator to a low-dimensional linear space.

Consider an affine operator

\[\Op_{\ell}(\q,\u;\bfmu) = \sum_{a=0}^{A_{\ell}-1}\theta_{\ell}^{(a)}\!(\bfmu)\, \Op_{\ell}^{(a)}\!(\q, \u)\]

where

  • \(\q\in\RR^n\) is the full-order state,

  • \(\u\in\RR^m\) is the input,

  • \(\bfmu\in\RR^p\) is the parameter vector, and

  • each \(\Op_{\ell}^{(a)}\!(\q,\u)\) is a nonparametric operator.

Given a trial basis \(\Vr\in\RR^{n\times r}\) and a test basis \(\Wr\in\RR^{n\times r}\), the corresponding intrusive projection of \(\f\) is the affine operator

\[\fhat_{\ell}(\qhat,\u;\bfmu) = \sum_{a=0}^{A_{\ell}-1}\theta_{\ell}^{(a)}\!(\bfmu)\, (\Wr\trp\Vr)^{-1}\Wr\trp\Op_{\ell}^{(a)}\!(\V\qhat, \u) = \sum_{a=0}^{A_{\ell}-1}\theta_{\ell}^{(a)}\!(\bfmu)\, \Ophat_{\ell}^{(a)}\!(\qhat, \u),\]

where \(\Ophat_{\ell}^{(a)}\!(\qhat, \u) = (\Wr\trp\Vr)^{-1}\Wr\trp\Op_{\ell}^{(a)}\!(\V\qhat, \u)\) is the intrusive projection of \(\Op_{\ell}^{(a)}.\) Here, \(\qhat\in\RR^r\) is the reduced-order state, which enables the low-dimensional state approximation \(\q = \Vr\qhat.\) If \(\Wr = \Vr\), the result is called a Galerkin projection. If \(\Wr \neq \Vr\), it is called a Petrov-Galerkin projection.

Parameters:
Vr(n, r) ndarray

Basis for the trial space.

Wr(n, r) ndarray or None

Basis for the test space. If None, defaults to Vr.

Returns:
opoperator

New object of the same class as self.