35 #ifndef _BLAZE_MATH_ADAPTORS_SYMMETRICMATRIX_NONNUMERICPROXY_H_
36 #define _BLAZE_MATH_ADAPTORS_SYMMETRICMATRIX_NONNUMERICPROXY_H_
97 template<
typename MT >
138 template<
typename T >
inline NonNumericProxy& operator+=(
const T& value );
139 template<
typename T >
inline NonNumericProxy& operator-=(
const T& value );
140 template<
typename T >
inline NonNumericProxy& operator*=(
const T& value );
141 template<
typename T >
inline NonNumericProxy& operator/=(
const T& value );
148 inline RawReference
get()
const;
209 template<
typename MT >
216 const size_t index( rmm ?
i_ :
j_ );
218 if( pos ==
matrix_.end(index) )
236 template<
typename MT >
238 : matrix_( nnp.matrix_ )
259 template<
typename MT >
262 const typename MT::Iterator pos( matrix_.find( i_, j_ ) );
263 const size_t index( rmm ? i_ : j_ );
265 if( pos != matrix_.end( index ) &&
isDefault( *pos->value() ) )
267 matrix_.erase( index, pos );
269 matrix_.erase( ( rmm ? j_ : i_ ), matrix_.find( j_, i_ ) );
289 template<
typename MT >
304 template<
typename MT >
305 template<
typename T >
320 template<
typename MT >
321 template<
typename T >
336 template<
typename MT >
337 template<
typename T >
352 template<
typename MT >
353 template<
typename T >
368 template<
typename MT >
369 template<
typename T >
391 template<
typename MT >
394 const typename MT::Iterator pos( matrix_.find( i_, j_ ) );
396 return *pos->value();
414 template<
typename MT >
433 template<
typename MT1,
typename MT2 >
436 template<
typename MT,
typename T >
439 template<
typename T,
typename MT >
442 template<
typename MT1,
typename MT2 >
445 template<
typename MT,
typename T >
448 template<
typename T,
typename MT >
451 template<
typename MT1,
typename MT2 >
454 template<
typename MT,
typename T >
455 inline bool operator<( const NonNumericProxy<MT>& lhs,
const T& rhs );
457 template<
typename T,
typename MT >
458 inline bool operator<( const T& lhs, const NonNumericProxy<MT>& rhs );
460 template<
typename MT1,
typename MT2 >
463 template<
typename MT,
typename T >
466 template<
typename T,
typename MT >
469 template<
typename MT1,
typename MT2 >
472 template<
typename MT,
typename T >
473 inline bool operator<=( const NonNumericProxy<MT>& lhs,
const T& rhs );
475 template<
typename T,
typename MT >
476 inline bool operator<=( const T& lhs, const NonNumericProxy<MT>& rhs );
478 template<
typename MT1,
typename MT2 >
481 template<
typename MT,
typename T >
484 template<
typename T,
typename MT >
487 template<
typename MT >
488 inline std::ostream& operator<<( std::ostream& os, const NonNumericProxy<MT>& proxy );
501 template<
typename MT1,
typename MT2 >
504 return ( lhs.
get() == rhs.
get() );
517 template<
typename MT,
typename T >
520 return ( lhs.
get() == rhs );
533 template<
typename T,
typename MT >
536 return ( lhs == rhs.
get() );
549 template<
typename MT1,
typename MT2 >
552 return ( lhs.
get() != rhs.
get() );
565 template<
typename MT,
typename T >
568 return ( lhs.
get() != rhs );
581 template<
typename T,
typename MT >
584 return ( lhs != rhs.
get() );
597 template<
typename MT1,
typename MT2 >
600 return ( lhs.get() < rhs.get() );
613 template<
typename MT,
typename T >
614 inline bool operator<( const NonNumericProxy<MT>& lhs,
const T& rhs )
616 return ( lhs.get() < rhs );
629 template<
typename T,
typename MT >
630 inline bool operator<( const T& lhs, const NonNumericProxy<MT>& rhs )
632 return ( lhs < rhs.get() );
645 template<
typename MT1,
typename MT2 >
648 return ( lhs.
get() > rhs.
get() );
661 template<
typename MT,
typename T >
664 return ( lhs.
get() > rhs );
677 template<
typename T,
typename MT >
680 return ( lhs > rhs.
get() );
693 template<
typename MT1,
typename MT2 >
696 return ( lhs.get() <= rhs.get() );
709 template<
typename MT,
typename T >
710 inline bool operator<=( const NonNumericProxy<MT>& lhs,
const T& rhs )
712 return ( lhs.get() <= rhs );
725 template<
typename T,
typename MT >
726 inline bool operator<=( const T& lhs, const NonNumericProxy<MT>& rhs )
728 return ( lhs <= rhs.get() );
741 template<
typename MT1,
typename MT2 >
744 return ( lhs.
get() >= rhs.
get() );
757 template<
typename MT,
typename T >
760 return ( lhs.
get() >= rhs );
773 template<
typename T,
typename MT >
776 return ( lhs >= rhs.
get() );
789 template<
typename MT >
790 inline std::ostream& operator<<( std::ostream& os, const NonNumericProxy<MT>& proxy )
792 return os << proxy.get();
808 template<
typename MT >
811 template<
typename MT >
814 template<
typename MT >
832 template<
typename MT >
853 template<
typename MT >
873 template<
typename MT >
#define BLAZE_CONSTRAINT_MUST_NOT_BE_CONST(T)
Constraint on the data type.In case the given data type is a const-qualified type, a compilation error is created.
Definition: Const.h:116
Constraint on the data type.
Header file for basic type definitions.
NonNumericProxy & operator=(const NonNumericProxy &nnp)
Copy assignment operator for NonNumericProxy.
Definition: NonNumericProxy.h:290
Proxy base class.The Proxy class is a base class for all proxy classes within the Blaze library that ...
Definition: Proxy.h:99
Access proxy for symmetric, square matrices with non-numeric element types.The NonNumericProxy provid...
Definition: NonNumericProxy.h:98
Constraint on the data type.
void reset(const DiagonalProxy< MT > &proxy)
Resetting the represented element to the default initial values.
Definition: DiagonalProxy.h:821
bool operator>(const NegativeAccuracy< A > &lhs, const T &rhs)
Greater-than comparison between a NegativeAccuracy object and a floating point value.
Definition: Accuracy.h:366
bool operator>=(const NegativeAccuracy< A > &, const T &rhs)
Greater-or-equal-than comparison between a NegativeAccuracy object and a floating point value...
Definition: Accuracy.h:442
void * operator&() const
Address operator (private & undefined)
#define BLAZE_CONSTRAINT_MUST_NOT_BE_VOLATILE(T)
Constraint on the data type.In case the given data type is a volatile-qualified type, a compilation error is created.
Definition: Volatile.h:116
Constraint on the data type.
size_t i_
Row-index of the accessed matrix element.
Definition: NonNumericProxy.h:164
bool isDefault(const DiagonalProxy< MT > &proxy)
Returns whether the represented element is in default state.
Definition: DiagonalProxy.h:861
Constraint on the data type.
Constraint on the data type.
ET::ValueType RepresentedType
Type of the represented matrix element.
Definition: NonNumericProxy.h:114
size_t j_
Column-index of the accessed matrix element.
Definition: NonNumericProxy.h:165
Header file for the clear shim.
Namespace of the Blaze C++ math library.
Definition: Blaze.h:57
#define BLAZE_ALWAYS_INLINE
Platform dependent setup of an enforced inline keyword.
Definition: Inline.h:85
Compile time check for row-major matrix types.This type trait tests whether or not the given template...
Definition: IsRowMajorMatrix.h:104
#define BLAZE_CONSTRAINT_MUST_NOT_BE_POINTER_TYPE(T)
Constraint on the data type.In case the given data type T is not a pointer type, a compilation error ...
Definition: Pointer.h:116
Constraint on the data type.
#define BLAZE_CONSTRAINT_MUST_NOT_BE_UPPER_MATRIX_TYPE(T)
Constraint on the data type.In case the given data type T is a upper triangular matrix type...
Definition: Upper.h:118
#define BLAZE_CONSTRAINT_MUST_NOT_BE_NUMERIC_TYPE(T)
Constraint on the data type.In case the given data type T is a numeric (integral or floating point) d...
Definition: Numeric.h:118
Type ElementType
Type of the sparse matrix elements.
Definition: CompressedMatrix.h:2505
void clear(const DiagonalProxy< MT > &proxy)
Clearing the represented element.
Definition: DiagonalProxy.h:841
RawReference get() const
Returning a reference to the accessed matrix element.
Definition: NonNumericProxy.h:392
#define BLAZE_CONSTRAINT_MUST_NOT_BE_SYMMETRIC_MATRIX_TYPE(T)
Constraint on the data type.In case the given data type T is a symmetric matrix type, a compilation error is created.
Definition: Symmetric.h:116
Header file for run time assertion macros.
Header file for the Proxy class.
Constraint on the data type.
Constraint on the data type.
ET::Reference RawReference
Raw reference to the represented element.
Definition: NonNumericProxy.h:115
Header file for the reset shim.
#define BLAZE_CONSTRAINT_MUST_NOT_BE_LOWER_MATRIX_TYPE(T)
Constraint on the data type.In case the given data type T is a lower triangular matrix type...
Definition: Lower.h:118
#define BLAZE_CONSTRAINT_MUST_NOT_BE_REFERENCE_TYPE(T)
Constraint on the data type.In case the given data type T is not a reference type, a compilation error is created.
Definition: Reference.h:116
Element * Iterator
Iterator over non-constant elements.
Definition: CompressedMatrix.h:2510
Header file for the isDefault shim.
Constraint on the data type.
Constraint on the data type.
MT & matrix_
Reference to the adapted matrix.
Definition: NonNumericProxy.h:163
Header file for the IsRowMajorMatrix type trait.
NonNumericProxy(MT &sm, size_t i, size_t j)
Initialization constructor for a NonNumericProxy.
Definition: NonNumericProxy.h:210
#define BLAZE_CONSTRAINT_MUST_NOT_BE_EXPRESSION_TYPE(T)
Constraint on the data type.In case the given data type T is an expression (i.e. a type derived from ...
Definition: Expression.h:118
bool operator==(const NegativeAccuracy< A > &lhs, const T &rhs)
Equality comparison between a NegativeAccuracy object and a floating point value. ...
Definition: Accuracy.h:249
bool operator!=(const NegativeAccuracy< A > &lhs, const T &rhs)
Inequality comparison between a NegativeAccuracy object and a floating point value.
Definition: Accuracy.h:289
MatrixAccessProxy< This > Reference
Reference to a non-constant matrix value.
Definition: CompressedMatrix.h:2508
~NonNumericProxy()
The destructor for NonNumericProxy.
Definition: NonNumericProxy.h:260
System settings for the inline keywords.
#define BLAZE_INTERNAL_ASSERT(expr, msg)
Run time assertion macro for internal checks.In case of an invalid run time expression, the program execution is terminated. The BLAZE_INTERNAL_ASSERT macro can be disabled by setting the BLAZE_USER_ASSERTION flag to zero or by defining NDEBUG during the compilation.
Definition: Assert.h:101
#define BLAZE_CONSTRAINT_MUST_BE_SPARSE_MATRIX_TYPE(T)
Constraint on the data type.In case the given data type T is not a sparse, N-dimensional matrix type...
Definition: SparseMatrix.h:79