![]() |
Ginkgo Generated from branch based on main. Ginkgo version 1.11.0
A numerical linear algebra library targeting many-core architectures
|
This class is a utility which efficiently implements the identity matrix (a linear operator which maps each vector to itself). More...
#include <ginkgo/core/matrix/identity.hpp>
Public Types | |
| using | value_type = ValueType |
| using | transposed_type = Identity<ValueType> |
| Public Types inherited from gko::EnablePolymorphicAssignment< Identity< default_precision > > | |
| using | result_type |
Public Member Functions | |
| std::unique_ptr< LinOp > | transpose () const override |
| Returns a LinOp representing the transpose of the Transposable object. | |
| std::unique_ptr< LinOp > | conj_transpose () const override |
| Returns a LinOp representing the conjugate transpose of the Transposable object. | |
| Public Member Functions inherited from gko::EnableLinOp< Identity< default_precision > > | |
| const Identity< default_precision > * | apply (ptr_param< const LinOp > b, ptr_param< LinOp > x) const |
| Public Member Functions inherited from gko::EnablePolymorphicAssignment< Identity< default_precision > > | |
| void | convert_to (result_type *result) const override |
| void | move_to (result_type *result) override |
Static Public Member Functions | |
| static std::unique_ptr< Identity > | create (std::shared_ptr< const Executor > exec, dim< 2 > size) |
| Creates an Identity matrix of the specified size. | |
| static std::unique_ptr< Identity > | create (std::shared_ptr< const Executor > exec, size_type size=0) |
| Creates an Identity matrix of the specified size. | |
Friends | |
| class | EnablePolymorphicObject< Identity, LinOp > |
This class is a utility which efficiently implements the identity matrix (a linear operator which maps each vector to itself).
Thus, objects of the Identity class always represent a square matrix, and don't require any storage for their values. The apply method is implemented as a simple copy (or a linear combination).
| ValueType | precision of matrix elements |
|
overridevirtual |
Returns a LinOp representing the conjugate transpose of the Transposable object.
Implements gko::Transposable.
|
static |
Creates an Identity matrix of the specified size.
| size | size of the matrix (must be square) |
|
static |
Creates an Identity matrix of the specified size.
| size | size of the matrix |
|
overridevirtual |
Returns a LinOp representing the transpose of the Transposable object.
Implements gko::Transposable.