Representation of two synchronized elements within the sparse Hermitian matrix.The HermitianElement class represents two synchronized elements (i.e. two value/index pairs) within a sparse Hermitian matrix. It guarantees that a modification of element
via iterator is also applied to element
. The following example illustrates this by means of a
dense Hermitian matrix:
More...
#include <HermitianElement.h>
Inherits blaze::SparseElement.
|
typedef MT::ElementType | ElementType |
| Type of the represented matrix element.
|
|
typedef MT::Iterator | IteratorType |
| Type of the underlying sparse matrix iterators.
|
|
|
IteratorType | pos_ |
| Iterator to the current sparse Hermitian matrix element.
|
|
MT * | matrix_ |
| The sparse matrix containing the iterator.
|
|
size_t | index_ |
| The row/column index of the iterator.
|
|
|
Reference | value () const |
| Access to the current value of the Hermitian element. More...
|
|
IndexType | index () const |
| Access to the current index of the Hermitian element. More...
|
|
void | sync () |
| Synchronization of the current sparse element to the according paired element. More...
|
|
bool | isSynced () const |
| Checking if the current sparse element is in sync. More...
|
|
template<typename MT>
class blaze::HermitianElement< MT >
Representation of two synchronized elements within the sparse Hermitian matrix.
The HermitianElement class represents two synchronized elements (i.e. two value/index pairs) within a sparse Hermitian matrix. It guarantees that a modification of element
via iterator is also applied to element
. The following example illustrates this by means of a
dense Hermitian matrix:
typedef std::complex<double> cplx;
Hermitian A( 3UL );
A(0,2) = cplx(-2,1);
A(1,1) = cplx( 3,0);
A(1,2) = cplx( 5,2);
*it = cplx(4,3);
Constructor for the HermitianElement class.
- Parameters
-
pos | The initial position of the iterator. |
matrix | The sparse matrix containing the iterator. |
idx | The row/column index of the iterator. |
Access to the current index of the Hermitian element.
- Returns
- The current index of the Hermitian element.
Checking if the current sparse element is in sync.
- Returns
- true if the current sparse element is in sync, false if not.
template<typename MT >
template<typename T >
Multiplication assignment to the Hermitian element.
- Parameters
-
v | The right-hand side value for the multiplication. |
- Returns
- Reference to the assigned Hermitian element.
- Exceptions
-
std::invalid_argument | Invalid assignment to diagonal matrix element. |
template<typename MT >
template<typename T >
Addition assignment to the Hermitian element.
- Parameters
-
v | The right-hand side value for the addition. |
- Returns
- Reference to the assigned Hermitian element.
- Exceptions
-
std::invalid_argument | Invalid assignment to diagonal matrix element. |
template<typename MT >
template<typename T >
Subtraction assignment to the Hermitian element.
- Parameters
-
v | The right-hand side value for the subtraction. |
- Returns
- Reference to the assigned Hermitian element.
- Exceptions
-
std::invalid_argument | Invalid assignment to diagonal matrix element. |
Direct access to the Hermitian element.
- Returns
- Reference to the value of the Hermitian element.
template<typename MT >
template<typename T >
Division assignment to the Hermitian element.
- Parameters
-
v | The right-hand side value for the division. |
- Returns
- Reference to the assigned Hermitian element.
- Exceptions
-
std::invalid_argument | Invalid assignment to diagonal matrix element. |
template<typename MT >
template<typename T >
Assignment to the Hermitian element.
- Parameters
-
v | The new value of the Hermitian element. |
- Returns
- Reference to the assigned Hermitian element.
- Exceptions
-
std::invalid_argument | Invalid assignment to diagonal matrix element. |
Synchronization of the current sparse element to the according paired element.
- Returns
- void
Access to the current value of the Hermitian element.
- Returns
- The current value of the Hermitian element.
The documentation for this class was generated from the following file: