ug4
|
describes a linear mapping X->Y More...
#include <linear_operator.h>
Public Types | |
typedef Y | codomain_function_type |
Range space. More... | |
typedef X | domain_function_type |
Domain space. More... | |
Public Types inherited from ug::IOperator< X, X > | |
typedef X | codomain_function_type |
Range space. More... | |
typedef X | domain_function_type |
Domain space. More... | |
Public Member Functions | |
virtual void | apply (Y &f, const X &u)=0 |
virtual void | apply_sub (Y &f, const X &u)=0 |
virtual void | init ()=0 |
init operator More... | |
virtual void | init (const X &u)=0 |
init operator depending on a function u More... | |
virtual void | prepare (X &u) |
default implementation for IOperator interface More... | |
virtual | ~ILinearOperator () |
virtual destructor More... | |
Public Member Functions inherited from ug::IOperator< X, X > | |
virtual void | apply (X &d, const X &u)=0 |
computes the nonlinear mapping d := N(u) More... | |
virtual | ~IOperator () |
virtual destructor More... | |
describes a linear mapping X->Y
This class is the base class for all linear mappings between two spaces. The domain space and the codomain space are passed as template parameters. The mapping must be linear. For nonlinear mappings see IOperator. The basic usage of this class is to provide the computation of:
f := L*u, (resp. d := J(u) * c in iterative schemes),
where f (resp. d) is from the codomain space, u (resp. c) a function of the domain space and L is a linear mapping (resp. J(u) a linearized mapping)
This application is splitted into two steps, that have to be called in the correct order:
This splitting has been made, since initialization may be computationally expansive. Thus, the user of this class has the choice when to call this initialization. E.g. when the operator is applied several times, the init of the operator is only needed once.
X | Domain space function |
Y | Range space function |
typedef Y ug::ILinearOperator< X, Y >::codomain_function_type |
Range space.
typedef X ug::ILinearOperator< X, Y >::domain_function_type |
Domain space.
|
inlinevirtual |
virtual destructor
|
pure virtual |
This method applies the operator, i.e. f = L*u (or d = J(u)*c in iterative schemes). Note, that the operator must have been initialized once before this method can be used.
[in] | u | domain function |
[out] | f | codomain function |
Implemented in ug::MatrixOperator< M, X, X >, ug::SchurComplementOperator< TAlgebra >, ug::LocalSchurComplement< TAlgebra >, ug::LocalSchurComplement< algebra_type >, ug::AssembledLinearOperator< TAlgebra >, and ug::MatrixOperator< TAlgebra::matrix_type, TAlgebra::vector_type >.
|
pure virtual |
This method applies the operator and subracts the result from the input codomain function, i.e. f -= L*u (or d -= J(u)*c in iterative schemes). Note, that the operator must have been initialized once before this method can be used.
[in] | u | domain function |
[in,out] | f | codomain function |
Implemented in ug::MatrixOperator< M, X, X >, ug::SchurComplementOperator< TAlgebra >, ug::LocalSchurComplement< TAlgebra >, ug::LocalSchurComplement< algebra_type >, ug::AssembledLinearOperator< TAlgebra >, and ug::MatrixOperator< TAlgebra::matrix_type, TAlgebra::vector_type >.
|
pure virtual |
init operator
This method initializes the operator. Once initialized the 'apply'-method can be called. If the operator is a linearization this function returns false.
Implements ug::IOperator< X, X >.
Implemented in ug::AssembledLinearOperator< TAlgebra >, ug::SchurComplementOperator< TAlgebra >, ug::SchurComplementMatrixOperator< TAlgebra, M, X, Y >, ug::LocalSchurComplement< TAlgebra >, ug::LocalSchurComplement< algebra_type >, ug::MatrixOperator< M, X, Y >, ug::MatrixOperator< M, X, X >, ug::MatrixOperator< TAlgebra::matrix_type, TAlgebra::vector_type >, ug::MatrixDiagonalInverse< M, X, Y >, and ug::MatrixDiagonal< M, X, Y >.
|
pure virtual |
init operator depending on a function u
This method initializes the operator. Once initialized the 'apply'-method can be called. The function u is passed here, since the linear operator may be the linearization of some non-linear operator. Thus, the operator depends on the linearization point. If the operator is not a linearization, this method can be implemented by simply calling init() and forgetting about the linearization point.
[in] | u | function (linearization point) |
Implemented in ug::SchurComplementMatrixOperator< TAlgebra, M, X, Y >, ug::MatrixOperator< M, X, Y >, ug::MatrixOperator< M, X, X >, ug::MatrixDiagonalInverse< M, X, Y >, ug::MatrixDiagonal< M, X, Y >, ug::AssembledLinearOperator< TAlgebra >, ug::SchurComplementOperator< TAlgebra >, ug::LocalSchurComplement< TAlgebra >, ug::LocalSchurComplement< algebra_type >, and ug::MatrixOperator< TAlgebra::matrix_type, TAlgebra::vector_type >.
|
inlinevirtual |
default implementation for IOperator interface
Implements ug::IOperator< X, X >.