35 #ifndef _BLAZE_MATH_ADAPTORS_DIAGONALMATRIX_DENSE_H_
36 #define _BLAZE_MATH_ADAPTORS_DIAGONALMATRIX_DENSE_H_
102 template<
typename MT
104 class DiagonalMatrix<MT,SO,true>
105 :
public DenseMatrix< DiagonalMatrix<MT,SO,true>, SO >
112 typedef IntrinsicTrait<ET> IT;
117 typedef DiagonalMatrix<MT,SO,true>
This;
122 typedef typename MT::IntrinsicType IntrinsicType;
127 typedef typename MT::Pointer Pointer;
128 typedef typename MT::ConstPointer ConstPointer;
135 template<
typename ET >
138 typedef DiagonalMatrix< typename MT::template Rebind<ET>::Other > Other;
149 typedef std::random_access_iterator_tag IteratorCategory;
151 typedef DiagonalProxy<MT> PointerType;
152 typedef DiagonalProxy<MT> ReferenceType;
153 typedef ptrdiff_t DifferenceType;
156 typedef IteratorCategory iterator_category;
157 typedef ValueType value_type;
158 typedef PointerType pointer;
159 typedef ReferenceType reference;
160 typedef DifferenceType difference_type;
193 inline Iterator& operator+=(
size_t inc ) {
194 ( SO )?( row_ += inc ):( column_ += inc );
205 inline Iterator& operator-=(
size_t dec ) {
206 ( SO )?( row_ -= dec ):( column_ -= dec );
217 ( SO )?( ++row_ ):( ++column_ );
227 inline const Iterator operator++(
int ) {
240 ( SO )?( --row_ ):( --column_ );
250 inline const Iterator operator--(
int ) {
263 return ReferenceType( *matrix_, row_, column_ );
272 inline PointerType operator->()
const {
273 return PointerType( *matrix_, row_, column_ );
284 return matrix_->begin( column_ ) + row_;
286 return matrix_->begin( row_ ) + column_;
298 return ( SO )?( lhs.row_ == rhs.row_ ):( lhs.column_ == rhs.column_ );
334 return ( SO )?( lhs.row_ != rhs.row_ ):( lhs.column_ != rhs.column_ );
370 return ( SO )?( lhs.row_ < rhs.row_ ):( lhs.column_ < rhs.column_ );
406 return ( SO )?( lhs.row_ > rhs.row_ ):( lhs.column_ > rhs.column_ );
442 return ( SO )?( lhs.row_ <= rhs.row_ ):( lhs.column_ <= rhs.column_ );
478 return ( SO )?( lhs.row_ >= rhs.row_ ):( lhs.column_ >= rhs.column_ );
513 return ( SO )?( row_ - rhs.row_ ):( column_ - rhs.column_ );
526 return Iterator( *it.matrix_, it.row_ + inc, it.column_ );
528 return Iterator( *it.matrix_, it.row_, it.column_ + inc );
541 return Iterator( *it.matrix_, it.row_ + inc, it.column_ );
543 return Iterator( *it.matrix_, it.row_, it.column_ + inc );
556 return Iterator( *it.matrix_, it.row_ - dec, it.column_ );
558 return Iterator( *it.matrix_, it.row_, it.column_ - dec );
573 enum { vectorizable = MT::vectorizable };
576 enum { smpAssignable = MT::smpAssignable };
582 explicit inline DiagonalMatrix();
583 template<
typename A1 >
explicit inline DiagonalMatrix(
const A1& a1 );
584 explicit inline DiagonalMatrix(
size_t n,
const ElementType& init );
586 explicit inline DiagonalMatrix( ElementType* ptr,
size_t n );
587 explicit inline DiagonalMatrix( ElementType* ptr,
size_t n,
size_t nn );
589 template<
typename Deleter >
590 explicit inline DiagonalMatrix( ElementType* ptr,
size_t n, Deleter d );
592 template<
typename Deleter >
593 explicit inline DiagonalMatrix( ElementType* ptr,
size_t n,
size_t nn, Deleter d );
595 inline DiagonalMatrix(
const DiagonalMatrix& m );
606 inline Reference operator()(
size_t i,
size_t j );
607 inline ConstReference operator()(
size_t i,
size_t j )
const;
608 inline Reference at(
size_t i,
size_t j );
609 inline ConstReference at(
size_t i,
size_t j )
const;
610 inline ConstPointer data ()
const;
611 inline ConstPointer data (
size_t i )
const;
613 inline ConstIterator
begin (
size_t i )
const;
614 inline ConstIterator
cbegin(
size_t i )
const;
616 inline ConstIterator
end (
size_t i )
const;
617 inline ConstIterator
cend (
size_t i )
const;
624 inline DiagonalMatrix& operator=(
const ElementType& rhs );
625 inline DiagonalMatrix& operator=(
const DiagonalMatrix& rhs );
627 template<
typename MT2,
bool SO2 >
628 inline typename DisableIf< IsComputation<MT2>, DiagonalMatrix& >::Type
629 operator=(
const Matrix<MT2,SO2>& rhs );
631 template<
typename MT2,
bool SO2 >
632 inline typename EnableIf< IsComputation<MT2>, DiagonalMatrix& >::Type
633 operator=(
const Matrix<MT2,SO2>& rhs );
635 template<
typename MT2,
bool SO2 >
636 inline typename DisableIf< IsComputation<MT2>, DiagonalMatrix& >::Type
637 operator+=(
const Matrix<MT2,SO2>& rhs );
639 template<
typename MT2,
bool SO2 >
640 inline typename EnableIf< IsComputation<MT2>, DiagonalMatrix& >::Type
641 operator+=(
const Matrix<MT2,SO2>& rhs );
643 template<
typename MT2,
bool SO2 >
644 inline typename DisableIf< IsComputation<MT2>, DiagonalMatrix& >::Type
645 operator-=(
const Matrix<MT2,SO2>& rhs );
647 template<
typename MT2,
bool SO2 >
648 inline typename EnableIf< IsComputation<MT2>, DiagonalMatrix& >::Type
649 operator-=(
const Matrix<MT2,SO2>& rhs );
651 template<
typename MT2,
bool SO2 >
652 inline DiagonalMatrix& operator*=(
const Matrix<MT2,SO2>& rhs );
654 template<
typename Other >
655 inline typename EnableIf< IsNumeric<Other>, DiagonalMatrix >::Type&
656 operator*=( Other rhs );
658 template<
typename Other >
659 inline typename EnableIf< IsNumeric<Other>, DiagonalMatrix >::Type&
660 operator/=( Other rhs );
667 inline size_t rows()
const;
671 inline size_t capacity(
size_t i )
const;
673 inline size_t nonZeros(
size_t i )
const;
675 inline void reset(
size_t i );
677 void resize (
size_t n,
bool preserve=
true );
678 inline void extend (
size_t n,
bool preserve=
true );
679 inline void reserve(
size_t elements );
680 template<
typename Other >
inline DiagonalMatrix& scale(
const Other& scalar );
681 inline void swap( DiagonalMatrix& m ) ;
695 template<
typename Other >
inline bool canAlias (
const Other* alias )
const;
696 template<
typename Other >
inline bool isAliased(
const Other* alias )
const;
698 inline bool isAligned ()
const;
699 inline bool canSMPAssign()
const;
711 inline const MT construct(
size_t n ,
TrueType );
712 inline const MT construct(
const ElementType& value,
FalseType );
714 template<
typename MT2,
bool SO2,
typename T >
715 inline const MT construct(
const Matrix<MT2,SO2>& m, T );
727 template<
typename MT2,
bool SO2,
bool DF2 >
728 friend bool isDefault(
const DiagonalMatrix<MT2,SO2,DF2>& m );
730 template<
typename MT2,
bool SO2,
bool DF2 >
731 friend MT2& derestrict( DiagonalMatrix<MT2,SO2,DF2>& m );
766 template<
typename MT
768 inline DiagonalMatrix<MT,SO,true>::DiagonalMatrix()
796 template<
typename MT
798 template<
typename A1 >
799 inline DiagonalMatrix<MT,SO,true>::DiagonalMatrix(
const A1& a1 )
800 : matrix_( construct( a1, typename IsResizable<MT>::Type() ) )
816 template<
typename MT
818 inline DiagonalMatrix<MT,SO,true>::DiagonalMatrix(
size_t n,
const ElementType& init )
819 : matrix_( n, n, ElementType() )
823 for(
size_t i=0UL; i<n; ++i )
854 template<
typename MT
856 inline DiagonalMatrix<MT,SO,true>::DiagonalMatrix( ElementType* ptr,
size_t n )
857 : matrix_( ptr, n, n )
892 template<
typename MT
894 inline DiagonalMatrix<MT,SO,true>::DiagonalMatrix( ElementType* ptr,
size_t n,
size_t nn )
895 : matrix_( ptr, n, n, nn )
928 template<
typename MT
930 template<
typename Deleter >
931 inline DiagonalMatrix<MT,SO,true>::DiagonalMatrix( ElementType* ptr,
size_t n, Deleter d )
932 : matrix_( ptr, n, n, d )
966 template<
typename MT
968 template<
typename Deleter >
969 inline DiagonalMatrix<MT,SO,true>::DiagonalMatrix( ElementType* ptr,
size_t n,
size_t nn, Deleter d )
970 : matrix_( ptr, n, n, nn, d )
988 template<
typename MT
990 inline DiagonalMatrix<MT,SO,true>::DiagonalMatrix(
const DiagonalMatrix& m )
991 : matrix_( m.matrix_ )
1024 template<
typename MT
1027 DiagonalMatrix<MT,SO,true>::operator()(
size_t i,
size_t j )
1054 template<
typename MT
1057 DiagonalMatrix<MT,SO,true>::operator()(
size_t i,
size_t j )
const
1062 return matrix_(i,j);
1085 template<
typename MT
1088 DiagonalMatrix<MT,SO,true>::at(
size_t i,
size_t j )
1096 return (*
this)(i,j);
1119 template<
typename MT
1122 DiagonalMatrix<MT,SO,true>::at(
size_t i,
size_t j )
const
1130 return (*
this)(i,j);
1149 template<
typename MT
1151 inline typename DiagonalMatrix<MT,SO,true>::ConstPointer
1152 DiagonalMatrix<MT,SO,true>::data()
const
1154 return matrix_.data();
1169 template<
typename MT
1171 inline typename DiagonalMatrix<MT,SO,true>::ConstPointer
1172 DiagonalMatrix<MT,SO,true>::data(
size_t i )
const
1174 return matrix_.data(i);
1192 template<
typename MT
1198 return Iterator( matrix_, 0UL, i );
1200 return Iterator( matrix_, i, 0UL );
1218 template<
typename MT
1223 return matrix_.begin(i);
1241 template<
typename MT
1246 return matrix_.cbegin(i);
1264 template<
typename MT
1290 template<
typename MT
1295 return matrix_.end(i);
1313 template<
typename MT
1318 return matrix_.cend(i);
1339 template<
typename MT
1341 inline DiagonalMatrix<MT,SO,true>&
1342 DiagonalMatrix<MT,SO,true>::operator=(
const ElementType& rhs )
1345 for(
size_t j=0UL; j<
columns(); ++j )
1349 for(
size_t i=0UL; i<
rows(); ++i )
1369 template<
typename MT
1371 inline DiagonalMatrix<MT,SO,true>&
1372 DiagonalMatrix<MT,SO,true>::operator=(
const DiagonalMatrix& rhs )
1374 matrix_ = rhs.matrix_;
1398 template<
typename MT
1400 template<
typename MT2
1402 inline typename DisableIf< IsComputation<MT2>, DiagonalMatrix<MT,SO,true>& >::Type
1403 DiagonalMatrix<MT,SO,true>::operator=(
const Matrix<MT2,SO2>& rhs )
1405 if( !IsDiagonal<MT2>::value && !
isDiagonal( ~rhs ) ) {
1433 template<
typename MT
1435 template<
typename MT2
1437 inline typename EnableIf< IsComputation<MT2>, DiagonalMatrix<MT,SO,true>& >::Type
1438 DiagonalMatrix<MT,SO,true>::operator=(
const Matrix<MT2,SO2>& rhs )
1440 if( !IsSquare<MT2>::value && !
isSquare( ~rhs ) ) {
1444 if( IsDiagonal<MT2>::value ) {
1454 move( matrix_, tmp );
1479 template<
typename MT
1481 template<
typename MT2
1483 inline typename DisableIf< IsComputation<MT2>, DiagonalMatrix<MT,SO,true>& >::Type
1484 DiagonalMatrix<MT,SO,true>::operator+=(
const Matrix<MT2,SO2>& rhs )
1486 if( !IsDiagonal<MT2>::value && !
isDiagonal( ~rhs ) ) {
1514 template<
typename MT
1516 template<
typename MT2
1518 inline typename EnableIf< IsComputation<MT2>, DiagonalMatrix<MT,SO,true>& >::Type
1519 DiagonalMatrix<MT,SO,true>::operator+=(
const Matrix<MT2,SO2>& rhs )
1521 if( !IsSquare<MT2>::value && !
isSquare( ~rhs ) ) {
1525 if( IsDiagonal<MT2>::value ) {
1560 template<
typename MT
1562 template<
typename MT2
1564 inline typename DisableIf< IsComputation<MT2>, DiagonalMatrix<MT,SO,true>& >::Type
1565 DiagonalMatrix<MT,SO,true>::operator-=(
const Matrix<MT2,SO2>& rhs )
1567 if( !IsDiagonal<MT2>::value && !
isDiagonal( ~rhs ) ) {
1595 template<
typename MT
1597 template<
typename MT2
1599 inline typename EnableIf< IsComputation<MT2>, DiagonalMatrix<MT,SO,true>& >::Type
1600 DiagonalMatrix<MT,SO,true>::operator-=(
const Matrix<MT2,SO2>& rhs )
1602 if( !IsSquare<MT2>::value && !
isSquare( ~rhs ) ) {
1606 if( IsDiagonal<MT2>::value ) {
1640 template<
typename MT
1642 template<
typename MT2
1644 inline DiagonalMatrix<MT,SO,true>&
1645 DiagonalMatrix<MT,SO,true>::operator*=(
const Matrix<MT2,SO2>& rhs )
1647 if( matrix_.rows() != (~rhs).
columns() ) {
1651 MT tmp( matrix_ * ~rhs );
1657 move( matrix_, tmp );
1676 template<
typename MT
1678 template<
typename Other >
1679 inline typename EnableIf< IsNumeric<Other>, DiagonalMatrix<MT,SO,true> >::Type&
1680 DiagonalMatrix<MT,SO,true>::operator*=( Other rhs )
1696 template<
typename MT
1698 template<
typename Other >
1699 inline typename EnableIf< IsNumeric<Other>, DiagonalMatrix<MT,SO,true> >::Type&
1700 DiagonalMatrix<MT,SO,true>::operator/=( Other rhs )
1725 template<
typename MT
1729 return matrix_.rows();
1741 template<
typename MT
1745 return matrix_.columns();
1762 template<
typename MT
1766 return matrix_.spacing();
1778 template<
typename MT
1782 return matrix_.capacity();
1800 template<
typename MT
1804 return matrix_.capacity(i);
1816 template<
typename MT
1820 return matrix_.nonZeros();
1838 template<
typename MT
1842 return matrix_.nonZeros(i);
1854 template<
typename MT
1877 template<
typename MT
1899 template<
typename MT
1947 template<
typename MT
1957 const size_t oldsize( matrix_.rows() );
1959 matrix_.resize( n, n,
true );
1962 const size_t increment( n - oldsize );
1963 submatrix( matrix_, 0UL, oldsize, n, increment ).reset();
1964 submatrix( matrix_, oldsize, 0UL, increment, increment ).reset();
1984 template<
typename MT
1986 inline void DiagonalMatrix<MT,SO,true>::extend(
size_t n,
bool preserve )
2007 template<
typename MT
2009 inline void DiagonalMatrix<MT,SO,true>::reserve(
size_t elements )
2011 matrix_.reserve( elements );
2024 template<
typename MT
2026 template<
typename Other >
2027 inline DiagonalMatrix<MT,SO,true>& DiagonalMatrix<MT,SO,true>::scale(
const Other& scalar )
2029 matrix_.scale( scalar );
2044 template<
typename MT
2050 swap( matrix_, m.matrix_ );
2074 template<
typename MT
2105 template<
typename MT
2107 template<
typename Other >
2108 inline bool DiagonalMatrix<MT,SO,true>::canAlias(
const Other* alias )
const
2110 return matrix_.canAlias( alias );
2127 template<
typename MT
2129 template<
typename Other >
2130 inline bool DiagonalMatrix<MT,SO,true>::isAliased(
const Other* alias )
const
2132 return matrix_.isAliased( alias );
2148 template<
typename MT
2150 inline bool DiagonalMatrix<MT,SO,true>::isAligned()
const
2152 return matrix_.isAligned();
2169 template<
typename MT
2171 inline bool DiagonalMatrix<MT,SO,true>::canSMPAssign()
const
2173 return matrix_.canSMPAssign();
2195 template<
typename MT
2198 DiagonalMatrix<MT,SO,true>::load(
size_t i,
size_t j )
const
2200 return matrix_.load( i, j );
2222 template<
typename MT
2227 return matrix_.loada( i, j );
2249 template<
typename MT
2254 return matrix_.loadu( i, j );
2275 template<
typename MT
2277 inline const MT DiagonalMatrix<MT,SO,true>::construct(
size_t n,
TrueType )
2294 template<
typename MT
2296 inline const MT DiagonalMatrix<MT,SO,true>::construct(
const ElementType& init,
FalseType )
2303 for(
size_t i=0UL; i<tmp.rows(); ++i )
2323 template<
typename MT
2325 template<
typename MT2
2328 inline const MT DiagonalMatrix<MT,SO,true>::construct(
const Matrix<MT2,SO2>& m, T )
2332 if( !IsDiagonal<MT2>::value && !
isDiagonal( tmp ) ) {
Constraint on the data type.
Header file for all restructuring submatrix functions.
#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
#define BLAZE_THROW_INVALID_ARGUMENT(MESSAGE)
Macro for the emission of a std::invalid_argument exceptionThis macro encapsulates the default way of...
Definition: Exception.h:187
#define BLAZE_USER_ASSERT(expr, msg)
Run time assertion macro for user checks.In case of an invalid run time expression, the program execution is terminated. The BLAZE_USER_ASSERT macro can be disabled by setting the BLAZE_USER_ASSERT flag to zero or by defining NDEBUG during the compilation.
Definition: Assert.h:117
bool isDiagonal(const DenseMatrix< MT, SO > &dm)
Checks if the give dense matrix is diagonal.
Definition: DenseMatrix.h:1511
Header file for the Rows type trait.
Header file for the UNUSED_PARAMETER function template.
const DMatDMatMultExpr< T1, T2 > operator*(const DenseMatrix< T1, false > &lhs, const DenseMatrix< T2, false > &rhs)
Multiplication operator for the multiplication of two row-major dense matrices ( ).
Definition: DMatDMatMultExpr.h:7820
Header file for basic type definitions.
BLAZE_ALWAYS_INLINE bool isSquare(const Matrix< MT, SO > &matrix)
Checks if the given matrix is a square matrix.
Definition: Matrix.h:603
BLAZE_ALWAYS_INLINE MT::ConstIterator cbegin(const Matrix< MT, SO > &matrix, size_t i)
Returns an iterator to the first element of row/column i.
Definition: Matrix.h:229
BLAZE_ALWAYS_INLINE MT::ConstIterator cend(const Matrix< MT, SO > &matrix, size_t i)
Returns an iterator just past the last element of row/column i.
Definition: Matrix.h:292
bool operator<=(const NegativeAccuracy< A > &, const T &rhs)
Less-or-equal-than comparison between a NegativeAccuracy object and a floating point value...
Definition: Accuracy.h:404
BLAZE_ALWAYS_INLINE MT::Iterator end(Matrix< MT, SO > &matrix, size_t i)
Returns an iterator just past the last element of row/column i.
Definition: Matrix.h:250
Header file for the FalseType type/value trait base class.
#define BLAZE_CONSTRAINT_MUST_BE_MATRIX_WITH_STORAGE_ORDER(T, SO)
Constraint on the data type.In case the given data type T is not a dense or sparse matrix type and in...
Definition: StorageOrder.h:81
Header file for the IsDiagonal type trait.
#define BLAZE_CONSTRAINT_MUST_BE_DENSE_MATRIX_TYPE(T)
Constraint on the data type.In case the given data type T is not a dense, N-dimensional matrix type...
Definition: DenseMatrix.h:79
Header file for the implementation of the base template of the DiagonalMatrix.
Constraint on the data type.
Constraint on the data type.
void reset(const DiagonalProxy< MT > &proxy)
Resetting the represented element to the default initial values.
Definition: DiagonalProxy.h:507
const This & CompositeType
Data type for composite expression templates.
Definition: CompressedMatrix.h:2588
BLAZE_ALWAYS_INLINE size_t capacity(const Matrix< MT, SO > &matrix)
Returns the maximum capacity of the matrix.
Definition: Matrix.h:340
BLAZE_ALWAYS_INLINE size_t rows(const Matrix< MT, SO > &matrix)
Returns the current number of rows of the matrix.
Definition: Matrix.h:308
void clear(CompressedMatrix< Type, SO > &m)
Clearing the given compressed matrix.
Definition: CompressedMatrix.h:4926
DisableIf< Or< IsComputation< MT >, IsTransExpr< MT > >, typename ColumnExprTrait< MT >::Type >::Type column(Matrix< MT, SO > &matrix, size_t index)
Creating a view on a specific column of the given matrix.
Definition: Column.h:107
void UNUSED_PARAMETER(const T1 &)
Suppression of unused parameter warnings.
Definition: Unused.h:81
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
CompressedMatrix< Type, true > This
Type of this CompressedMatrix instance.
Definition: CompressedMatrix.h:2582
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
#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
BLAZE_ALWAYS_INLINE size_t nonZeros(const Matrix< MT, SO > &matrix)
Returns the total number of non-zero elements in the matrix.
Definition: Matrix.h:378
#define BLAZE_CONSTRAINT_MUST_BE_SQUARE(T)
Constraint on the data type.In case the given data type T is not a square matrix type, a compilation error is created.
Definition: Square.h:78
void move(CustomMatrix< Type, AF, PF, SO > &dst, CustomMatrix< Type, AF, PF, SO > &src)
Moving the contents of one custom matrix to another.
Definition: CustomMatrix.h:6085
Constraint on the data type.
CompressedMatrix< Type, false > OppositeType
Result type with opposite storage order for expression template evaluations.
Definition: CompressedMatrix.h:2584
bool isDefault(const DiagonalProxy< MT > &proxy)
Returns whether the represented element is in default state.
Definition: DiagonalProxy.h:547
Constraint on the data type.
Constraint on the data type.
Header file for the IsSquare type trait.
Constraint on the data type.
Constraint on the data type.
Header file for the DenseSubmatrix class template.
Header file for the DisableIf class template.
BLAZE_ALWAYS_INLINE EnableIf< And< IsIntegral< T >, HasSize< T, 2UL > >, simd_int16_t >::Type loadu(const T *address)
Loads a vector of 2-byte integral values.
Definition: Loadu.h:74
Header file for the DiagonalProxy class.
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
void swap(CompressedMatrix< Type, SO > &a, CompressedMatrix< Type, SO > &b)
Swapping the contents of two compressed matrices.
Definition: CompressedMatrix.h:4998
bool isIntact(const CompressedMatrix< Type, SO > &m)
Returns whether the invariants of the given compressed matrix are intact.
Definition: CompressedMatrix.h:4980
const Element * ConstIterator
Iterator over constant elements.
Definition: CompressedMatrix.h:2592
#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
#define BLAZE_THROW_OUT_OF_RANGE(MESSAGE)
Macro for the emission of a std::out_of_range exceptionThis macro encapsulates the default way of Bla...
Definition: Exception.h:331
const DenseIterator< Type, AF > operator+(const DenseIterator< Type, AF > &it, ptrdiff_t inc)
Addition between a DenseIterator and an integral value.
Definition: DenseIterator.h:610
Header file for the DenseMatrix base class.
Header file for the Columns type trait.
Constraint on the data type.
const DenseIterator< Type, AF > operator-(const DenseIterator< Type, AF > &it, ptrdiff_t inc)
Subtraction between a DenseIterator and an integral value.
Definition: DenseIterator.h:642
CompressedMatrix< Type, false > TransposeType
Transpose type for expression template evaluations.
Definition: CompressedMatrix.h:2585
Constraints on the storage order of matrix types.
#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
BLAZE_ALWAYS_INLINE MT::Iterator begin(Matrix< MT, SO > &matrix, size_t i)
Returns an iterator to the first element of row/column i.
Definition: Matrix.h:187
BLAZE_ALWAYS_INLINE void resize(Matrix< MT, SO > &matrix, size_t rows, size_t columns, bool preserve=true)
Changing the size of the matrix.
Definition: Matrix.h:532
Type ElementType
Type of the sparse matrix elements.
Definition: CompressedMatrix.h:2586
const Type & ConstReference
Reference to a constant matrix value.
Definition: CompressedMatrix.h:2590
Header file for the EnableIf class template.
Header file for utility functions for dense matrices.
void clear(const DiagonalProxy< MT > &proxy)
Clearing the represented element.
Definition: DiagonalProxy.h:527
Header file for the IsNumeric type trait.
const bool spacing
Adding an additional spacing line between two log messages.This setting gives the opportunity to add ...
Definition: Logging.h:70
DisableIf< Or< IsComputation< MT >, IsTransExpr< MT > >, typename RowExprTrait< MT >::Type >::Type row(Matrix< MT, SO > &matrix, size_t index)
Creating a view on a specific row of the given matrix.
Definition: Row.h:107
BLAZE_ALWAYS_INLINE EnableIf< And< IsIntegral< T >, HasSize< T, 2UL > >, simd_int16_t >::Type loada(const T *address)
Loads a vector of 2-byte integral values.
Definition: Loada.h:77
#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
const Type & ReturnType
Return type for expression template evaluations.
Definition: CompressedMatrix.h:2587
Header file for run time assertion macros.
Constraint on the data type.
Constraint on the data type.
#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:2591
Header file for the isDefault shim.
Constraint on the data type.
Constraint on the data type.
#define BLAZE_CONSTRAINT_MUST_NOT_BE_RESIZABLE(T)
Constraint on the data type.In case the given data type T is resizable, i.e. has a 'resize' member fu...
Definition: Resizable.h:118
void swap(DiagonalMatrix< MT, SO, DF > &a, DiagonalMatrix< MT, SO, DF > &b)
Swapping the contents of two matrices.
Definition: DiagonalMatrix.h:256
Header file for all intrinsic functionality.
Header file for the move shim.
SubmatrixExprTrait< MT, unaligned >::Type submatrix(Matrix< MT, SO > &matrix, size_t row, size_t column, size_t m, size_t n)
Creating a view on a specific submatrix of the given matrix.
Definition: Submatrix.h:146
bool operator<(const NegativeAccuracy< A > &lhs, const T &rhs)
Less-than comparison between a NegativeAccuracy object and a floating point value.
Definition: Accuracy.h:328
#define BLAZE_CONSTRAINT_MUST_BE_RESIZABLE(T)
Constraint on the data type.In case the given data type T is not resizable, i.e. does not have a 'res...
Definition: Resizable.h:79
Header file for the IsComputation type trait class.
boost::false_type FalseType
Type/value traits base class.The FalseType class is used as base class for type traits and value trai...
Definition: FalseType.h:61
#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
This ResultType
Result type for expression template evaluations.
Definition: CompressedMatrix.h:2583
BLAZE_ALWAYS_INLINE size_t columns(const Matrix< MT, SO > &matrix)
Returns the current number of columns of the matrix.
Definition: Matrix.h:324
bool operator!=(const NegativeAccuracy< A > &lhs, const T &rhs)
Inequality comparison between a NegativeAccuracy object and a floating point value.
Definition: Accuracy.h:289
bool isIntact(const DiagonalMatrix< MT, SO, DF > &m)
Returns whether the invariants of the given diagonal matrix are intact.
Definition: DiagonalMatrix.h:237
MatrixAccessProxy< This > Reference
Reference to a non-constant matrix value.
Definition: CompressedMatrix.h:2589
#define BLAZE_CONSTRAINT_MUST_NOT_BE_HERMITIAN_MATRIX_TYPE(T)
Constraint on the data type.In case the given data type T is an Hermitian matrix type, a compilation error is created.
Definition: Hermitian.h:116
Header file for exception macros.
boost::true_type TrueType
Type traits base class.The TrueType class is used as base class for type traits and value traits that...
Definition: TrueType.h:61
#define BLAZE_STATIC_ASSERT(expr)
Compile time assertion macro.In case of an invalid compile time expression, a compilation error is cr...
Definition: StaticAssert.h:143
Header file for the IsResizable type trait.
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
Header file for the TrueType type/value trait base class.