ug4
|
matrix operator based on the assembling of a problem More...
#include <assembled_linear_operator.h>
Public Types | |
typedef TAlgebra | algebra_type |
Type of Algebra. | |
typedef MatrixOperator< matrix_type, vector_type > | base_type |
Type of base class. | |
typedef TAlgebra::matrix_type | matrix_type |
Type of Matrix. | |
typedef TAlgebra::vector_type | vector_type |
Type of Vector. | |
![]() | |
typedef TAlgebra::vector_type | codomain_function_type |
typedef TAlgebra::vector_type | domain_function_type |
typedef TAlgebra::matrix_type | matrix_type |
![]() | |
typedef Y | codomain_function_type |
Range space. | |
typedef X | domain_function_type |
Domain space. | |
![]() | |
typedef Y | codomain_function_type |
Range space. | |
typedef X | domain_function_type |
Domain space. | |
Public Member Functions | |
virtual void | apply (vector_type &d, const vector_type &c) |
compute d = J(u)*c (here, J(u) is a Matrix) | |
virtual void | apply_sub (vector_type &d, const vector_type &c) |
Compute d := d - J(u)*c. | |
AssembledLinearOperator () | |
Default Constructor. | |
AssembledLinearOperator (SmartPtr< IAssemble< TAlgebra > > ass) | |
Constructor. | |
AssembledLinearOperator (SmartPtr< IAssemble< TAlgebra > > ass, const GridLevel &gl) | |
Constructor. | |
SmartPtr< IAssemble< TAlgebra > > | discretization () |
returns the discretization to be used | |
virtual void | init () |
initialize the operator | |
virtual void | init (const vector_type &u) |
initializes the operator that may depend on the current solution | |
void | init_op_and_rhs (vector_type &b) |
initializes the operator and assembles the passed rhs vector | |
const GridLevel & | level () const |
returns the level | |
void | set_dirichlet_values (vector_type &u) |
Set Dirichlet values. | |
void | set_discretization (SmartPtr< IAssemble< TAlgebra > > ass) |
sets the discretization to be used | |
void | set_level (const GridLevel &gl) |
sets the level used for assembling | |
virtual | ~AssembledLinearOperator () |
Destructor. | |
![]() | |
virtual TAlgebra::matrix_type & | get_matrix () |
![]() | |
virtual void | apply (Y &f, const X &u)=0 |
virtual void | apply_sub (Y &f, const X &u)=0 |
virtual void | init (const X &u)=0 |
init operator depending on a function u | |
virtual void | prepare (X &u) |
default implementation for IOperator interface | |
virtual | ~ILinearOperator () |
virtual destructor | |
![]() | |
virtual | ~IOperator () |
virtual destructor | |
Protected Attributes | |
GridLevel | m_gridLevel |
SmartPtr< IAssemble< TAlgebra > > | m_spAss |
matrix operator based on the assembling of a problem
This operator implements the MatrixOperator interface, thus is basically a matrix that can be applied to vectors. In addition the class allows to set an IAssemble object and an the GridLevel. Invoking the init method the matrix is created using the IAssemble routine on the given GridLevel.
TAlgebra | algebra type |
typedef TAlgebra ug::AssembledLinearOperator< TAlgebra >::algebra_type |
Type of Algebra.
typedef MatrixOperator<matrix_type,vector_type> ug::AssembledLinearOperator< TAlgebra >::base_type |
Type of base class.
typedef TAlgebra::matrix_type ug::AssembledLinearOperator< TAlgebra >::matrix_type |
Type of Matrix.
typedef TAlgebra::vector_type ug::AssembledLinearOperator< TAlgebra >::vector_type |
Type of Vector.
|
inline |
Default Constructor.
|
inline |
Constructor.
|
inline |
Constructor.
|
inlinevirtual |
Destructor.
|
virtual |
compute d = J(u)*c (here, J(u) is a Matrix)
Reimplemented from ug::MatrixOperator< TAlgebra::matrix_type, TAlgebra::vector_type >.
|
virtual |
Compute d := d - J(u)*c.
Reimplemented from ug::MatrixOperator< TAlgebra::matrix_type, TAlgebra::vector_type >.
References num_cols(), num_rows(), ug::PST_ADDITIVE, ug::PST_CONSISTENT, and UG_THROW.
|
inline |
returns the discretization to be used
References ug::AssembledLinearOperator< TAlgebra >::m_spAss.
|
virtual |
initialize the operator
Reimplemented from ug::MatrixOperator< TAlgebra::matrix_type, TAlgebra::vector_type >.
References UG_CATCH_THROW, and UG_THROW.
|
virtual |
initializes the operator that may depend on the current solution
Reimplemented from ug::MatrixOperator< TAlgebra::matrix_type, TAlgebra::vector_type >.
References UG_CATCH_THROW, and UG_THROW.
void ug::AssembledLinearOperator< TAlgebra >::init_op_and_rhs | ( | vector_type & | b | ) |
initializes the operator and assembles the passed rhs vector
References UG_THROW.
Referenced by ug::AssembleLinearOperatorRhsAndSolution().
|
inline |
returns the level
References ug::AssembledLinearOperator< TAlgebra >::m_gridLevel.
void ug::AssembledLinearOperator< TAlgebra >::set_dirichlet_values | ( | vector_type & | u | ) |
Set Dirichlet values.
References UG_CATCH_THROW, and UG_THROW.
Referenced by ug::AssembleLinearOperatorRhsAndSolution().
|
inline |
sets the discretization to be used
References ug::AssembledLinearOperator< TAlgebra >::m_spAss.
|
inline |
sets the level used for assembling
References ug::AssembledLinearOperator< TAlgebra >::m_gridLevel.
|
protected |
|
protected |