nifty7.operators.linear_operator module#

class LinearOperator[source]#

Bases: Operator

NIFTY base class for linear operators.

The base NIFTY operator class is an abstract class from which other specific operator subclasses are derived.

Variables:
  • TIMES (int) – Symbolic constant representing normal operator application

  • ADJOINT_TIMES (int) – Symbolic constant representing adjoint operator application

  • INVERSE_TIMES (int) – Symbolic constant representing inverse operator application

  • ADJOINT_INVERSE_TIMES (int) – Symbolic constant representing adjoint inverse operator application

  • INVERSE_ADJOINT_TIMES (int) – same as ADJOINT_INVERSE_TIMES

Notes

The symbolic constants for the operation modes can be combined by the “bitwise-or” operator “|”, for expressing the capability of the operator by means of a single integer number.

ADJOINT_BIT = 1#
ADJOINT_INVERSE_TIMES = 8#
ADJOINT_TIMES = 2#
INVERSE_ADJOINT_TIMES = 8#
INVERSE_BIT = 2#
INVERSE_TIMES = 4#
TIMES = 1#
__call__(x)[source]#

Same as times()

property adjoint#

the adjoint of self

Returns a LinearOperator object which behaves as if it were the adjoint of this operator.

Type:

LinearOperator

adjoint_inverse_times(x)[source]#

Applies the adjoint-inverse Operator to a given Field.

Parameters:

x (Field) – The input Field, defined on the Operator’s domain.

Returns:

The processed Field defined on the Operator’s target domain.

Return type:

Field

Notes

If the operator has an inverse then the inverse adjoint is identical to the adjoint inverse. We provide both names for convenience.

adjoint_times(x)[source]#

Applies the adjoint-Operator to a given Field.

Parameters:

x (Field) – The input Field, defined on the Operator’s target domain

Returns:

The processed Field defined on the Operator’s domain.

Return type:

Field

apply(x, mode)[source]#

Applies the Operator to a given x, in a specified mode.

Parameters:
Returns:

The processed Field defined on the Operator’s target or domain, depending on mode.

Return type:

Field

property capability#

the supported operation modes

Returns the supported subset of TIMES, ADJOINT_TIMES, INVERSE_TIMES, and ADJOINT_INVERSE_TIMES, joined together by the “|” operator.

Type:

int

force(x)[source]#

Extract subset of domain of x according to self.domain and apply operator.

property inverse#

the inverse of self

Returns a LinearOperator object which behaves as if it were the inverse of this operator.

Type:

LinearOperator

inverse_adjoint_times(x)[source]#

Same as adjoint_inverse_times()

inverse_times(x)[source]#

Applies the inverse Operator to a given Field.

Parameters:

x (Field) – The input Field, defined on the Operator’s target domain

Returns:

The processed Field defined on the Operator’s domain.

Return type:

Field

times(x)[source]#

Applies the Operator to a given Field.

Parameters:

x (Field) – The input Field, defined on the Operator’s domain.

Returns:

The processed Field defined on the Operator’s target domain.

Return type:

Field