Representation of two synchronized values within a sparse Hermitian matrix.The HermitianValue class represents two synchronized values within a sparse Hermitian matrix. It guarantees that a modification of value
via iterator is also applied to the value
. The following example illustrates this by means of a
sparse Hermitian matrix:
More...
#include <HermitianValue.h>
Inherits blaze::Proxy< HermitianValue< MT > >.
|
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.
|
|
|
void | reset () const |
| Reset the Hermitian value to its default initial value. More...
|
|
void | clear () const |
| Clearing the Hermitian value. More...
|
|
void | invert () const |
| In-place inversion of the Hermitian value. More...
|
|
RepresentedType | get () const noexcept |
| Access to the represented value. More...
|
|
void | sync () const |
| Synchronization of the current sparse element to the according paired element. More...
|
|
template<typename MT>
class blaze::HermitianValue< MT >
Representation of two synchronized values within a sparse Hermitian matrix.
The HermitianValue class represents two synchronized values within a sparse Hermitian matrix. It guarantees that a modification of value
via iterator is also applied to the value
. The following example illustrates this by means of a
sparse 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->value() = cplx(4,3);
Constructor for the HermitianValue class.
- Parameters
-
pos | The initial position of the iterator. |
matrix | The sparse matrix containing the iterator. |
index | The row/column index of the iterator. |
Clearing the Hermitian value.
- Returns
- void
This function clears the Hermitian value to its default initial state.
Access to the represented value.
- Returns
- Copy of the represented value.
Returns the imaginary part of the represented complex number.
- Returns
- The current imaginary part of the represented complex number.
In case the value represents a complex number, this function returns the current value of its imaginary part.
Setting the imaginary part of the represented complex number.
- Parameters
-
value | The new value for the imaginary part. |
- Returns
- void
In case the proxy represents a complex number, this function sets a new value to its imaginary part.
In-place inversion of the Hermitian value.
- Returns
- void
Conversion to the represented value.
- Returns
- Copy of the represented value.
template<typename MT>
template<typename T >
Multiplication assignment to the Hermitian value.
- Parameters
-
value | The right-hand side value for the multiplication. |
- Returns
- Reference to the assigned Hermitian value.
- Exceptions
-
std::invalid_argument | Invalid assignment to diagonal matrix element. |
template<typename MT>
template<typename T >
Addition assignment to the Hermitian value.
- Parameters
-
value | The right-hand side value to be added to the Hermitian value. |
- Returns
- Reference to the assigned Hermitian value.
- Exceptions
-
std::invalid_argument | Invalid assignment to diagonal matrix element. |
template<typename MT>
template<typename T >
Subtraction assignment to the Hermitian value.
- Parameters
-
value | The right-hand side value to be subtracted from the Hermitian value. |
- Returns
- Reference to the assigned Hermitian value.
- Exceptions
-
std::invalid_argument | Invalid assignment to diagonal matrix element. |
template<typename MT>
template<typename T >
Division assignment to the Hermitian value.
- Parameters
-
value | The right-hand side value for the division. |
- Returns
- Reference to the assigned Hermitian value.
- Exceptions
-
std::invalid_argument | Invalid assignment to diagonal matrix element. |
Copy assignment operator for HermitianValue.
- Parameters
-
hv | The Hermitian value to be copied. |
- Returns
- Reference to the assigned Hermitian value.
- Exceptions
-
std::invalid_argument | Invalid assignment to diagonal matrix element. |
template<typename MT>
template<typename T >
Assignment to the Hermitian value.
- Parameters
-
value | The new value of the Hermitian value. |
- Returns
- Reference to the assigned Hermitian value.
- Exceptions
-
std::invalid_argument | Invalid assignment to diagonal matrix element. |
Returns the real part of the represented complex number.
- Returns
- The current real part of the represented complex number.
In case the value represents a complex number, this function returns the current value of its real part.
Setting the real part of the represented complex number.
- Parameters
-
value | The new value for the real part. |
- Returns
- void
In case the value represents a complex number, this function sets a new value to its real part.
Reset the Hermitian value to its default initial value.
- Returns
- void
This function resets the Hermitian value to its default initial value.
Synchronization of the current sparse element to the according paired element.
- Returns
- void
The documentation for this class was generated from the following file: