rom: Galerkin: projector

The projector is needed for Galerkin to perform the projection of the FOM operators onto the reduced space.

It is explicitly required from the user when doing masked or hyper-reduced Galerkin.

For a default problem, you don't need to pass it because the projector is constructed behind the scenes automatically using the decoder's jacobian.

todo: explain more, talk about pressio-tools.

API

When provided by the user, the projector must be a functor as follows:

class Projector:
  def __init__(self, ...):
    # as needed

  def __call__(self, operand, time, result):
    # project operand and store in result

Note that the operand is either a FOM velocity instance, or the decoder's Jacobian. In all cases, however, it is a numpy.array. You can define the actual projection operation however you like.

One thing to keep in mind is that, typically, the operand is either a masked operand (i.e., the result of masking a full FOM operand) if you are using a masked problem, or it is a hyper-reduced object if you are using a hyper-reduced Galerkin problem.