35 #ifndef _BLAZE_MATH_ADAPTORS_STRICTLYUPPERMATRIX_SPARSE_H_ 36 #define _BLAZE_MATH_ADAPTORS_STRICTLYUPPERMATRIX_SPARSE_H_ 101 class StrictlyUpperMatrix<MT,SO,false>
102 :
public SparseMatrix< StrictlyUpperMatrix<MT,SO,false>, SO >
106 using OT = OppositeType_<MT>;
107 using TT = TransposeType_<MT>;
108 using ET = ElementType_<MT>;
113 using This = StrictlyUpperMatrix<MT,SO,false>;
114 using BaseType = SparseMatrix<This,SO>;
121 using Reference = StrictlyUpperProxy<MT>;
130 template<
typename NewType >
133 using Other = StrictlyUpperMatrix< typename MT::template Rebind<NewType>::Other >;
140 template<
size_t NewM
144 using Other = StrictlyUpperMatrix< typename MT::template Resize<NewM,NewN>::Other >;
150 enum :
bool { smpAssignable =
false };
156 explicit inline StrictlyUpperMatrix();
157 explicit inline StrictlyUpperMatrix(
size_t n );
158 explicit inline StrictlyUpperMatrix(
size_t n,
size_t nonzeros );
159 explicit inline StrictlyUpperMatrix(
size_t n,
const std::vector<size_t>& nonzeros );
161 inline StrictlyUpperMatrix(
const StrictlyUpperMatrix& m );
162 inline StrictlyUpperMatrix( StrictlyUpperMatrix&& m ) noexcept;
164 template<
typename MT2,
bool SO2 >
165 inline StrictlyUpperMatrix(
const Matrix<MT2,SO2>& m );
176 inline Reference operator()(
size_t i,
size_t j );
178 inline Reference at(
size_t i,
size_t j );
192 inline StrictlyUpperMatrix& operator=(
const StrictlyUpperMatrix& rhs );
193 inline StrictlyUpperMatrix& operator=( StrictlyUpperMatrix&& rhs ) noexcept;
195 template<
typename MT2,
bool SO2 >
196 inline DisableIf_< IsComputation<MT2>, StrictlyUpperMatrix& >
197 operator=(
const Matrix<MT2,SO2>& rhs );
199 template<
typename MT2,
bool SO2 >
200 inline EnableIf_< IsComputation<MT2>, StrictlyUpperMatrix& >
201 operator=(
const Matrix<MT2,SO2>& rhs );
203 template<
typename MT2,
bool SO2 >
204 inline DisableIf_< IsComputation<MT2>, StrictlyUpperMatrix& >
207 template<
typename MT2,
bool SO2 >
208 inline EnableIf_< IsComputation<MT2>, StrictlyUpperMatrix& >
211 template<
typename MT2,
bool SO2 >
212 inline DisableIf_< IsComputation<MT2>, StrictlyUpperMatrix& >
215 template<
typename MT2,
bool SO2 >
216 inline EnableIf_< IsComputation<MT2>, StrictlyUpperMatrix& >
219 template<
typename MT2,
bool SO2 >
220 inline StrictlyUpperMatrix& operator%=(
const Matrix<MT2,SO2>& rhs );
222 template<
typename MT2,
bool SO2 >
223 inline StrictlyUpperMatrix&
operator*=(
const Matrix<MT2,SO2>& rhs );
225 template<
typename Other >
226 inline EnableIf_< IsNumeric<Other>, StrictlyUpperMatrix >&
operator*=( Other rhs );
228 template<
typename Other >
229 inline EnableIf_< IsNumeric<Other>, StrictlyUpperMatrix >&
operator/=( Other rhs );
236 inline size_t rows() const noexcept;
237 inline
size_t columns() const noexcept;
238 inline
size_t capacity() const noexcept;
239 inline
size_t capacity(
size_t i ) const noexcept;
241 inline
size_t nonZeros(
size_t i ) const;
243 inline
void reset(
size_t i );
245 inline
void resize (
size_t n,
bool preserve=true );
246 inline
void reserve(
size_t nonzeros );
247 inline
void reserve(
size_t i,
size_t nonzeros );
249 inline
void trim(
size_t i );
251 inline
void swap( StrictlyUpperMatrix& m ) noexcept;
253 static inline constexpr
size_t maxNonZeros() noexcept;
254 static inline constexpr
size_t maxNonZeros(
size_t n ) noexcept;
263 inline
void append (
size_t i,
size_t j, const
ElementType& value,
bool check=false );
264 inline
void finalize(
size_t i );
271 inline
void erase(
size_t i,
size_t j );
275 template< typename Pred >
276 inline
void erase( Pred predicate );
278 template< typename Pred >
279 inline
void erase(
size_t i,
Iterator first,
Iterator last, Pred predicate );
286 inline
Iterator find (
size_t i,
size_t j );
288 inline
Iterator lowerBound(
size_t i,
size_t j );
290 inline
Iterator upperBound(
size_t i,
size_t j );
298 template< typename Other > inline StrictlyUpperMatrix& scale( const Other& scalar );
299 template< typename Other > inline StrictlyUpperMatrix& scaleDiagonal( const Other& scale );
306 inline
bool isIntact() const noexcept;
313 template< typename Other > inline
bool canAlias ( const Other* alias ) const noexcept;
314 template< typename Other > inline
bool isAliased( const Other* alias ) const noexcept;
316 inline
bool canSMPAssign() const noexcept;
324 inline
void resetLower();
336 template< typename MT2,
bool SO2,
bool DF2 >
337 friend MT2& derestrict( StrictlyUpperMatrix<MT2,SO2,DF2>& m );
372 template< typename MT
374 inline StrictlyUpperMatrix<MT,SO,false>::StrictlyUpperMatrix()
391 template<
typename MT
393 inline StrictlyUpperMatrix<MT,SO,false>::StrictlyUpperMatrix(
size_t n )
414 template<
typename MT
416 inline StrictlyUpperMatrix<MT,SO,false>::StrictlyUpperMatrix(
size_t n,
size_t nonzeros )
417 : matrix_( n, n,
max( nonzeros, n ) )
441 template<
typename MT
443 inline StrictlyUpperMatrix<MT,SO,false>::StrictlyUpperMatrix(
size_t n,
const std::vector<size_t>& nonzeros )
444 : matrix_( n, n, nonzeros )
460 template<
typename MT
462 inline StrictlyUpperMatrix<MT,SO,false>::StrictlyUpperMatrix(
const StrictlyUpperMatrix& m )
463 : matrix_( m.matrix_ )
478 template<
typename MT
480 inline StrictlyUpperMatrix<MT,SO,false>::StrictlyUpperMatrix( StrictlyUpperMatrix&& m ) noexcept
481 : matrix_( std::move( m.matrix_ ) )
501 template<
typename MT
503 template<
typename MT2
505 inline StrictlyUpperMatrix<MT,SO,false>::StrictlyUpperMatrix(
const Matrix<MT2,SO2>& m )
508 if( IsUniTriangular<MT2>::value ||
513 if( !IsStrictlyUpper<MT2>::value )
547 template<
typename MT
550 StrictlyUpperMatrix<MT,SO,false>::operator()(
size_t i,
size_t j )
577 template<
typename MT
580 StrictlyUpperMatrix<MT,SO,false>::operator()(
size_t i,
size_t j )
const 608 template<
typename MT
611 StrictlyUpperMatrix<MT,SO,false>::at(
size_t i,
size_t j )
642 template<
typename MT
645 StrictlyUpperMatrix<MT,SO,false>::at(
size_t i,
size_t j )
const 671 template<
typename MT
676 return matrix_.begin(i);
694 template<
typename MT
699 return matrix_.begin(i);
717 template<
typename MT
722 return matrix_.cbegin(i);
740 template<
typename MT
745 return matrix_.end(i);
763 template<
typename MT
768 return matrix_.end(i);
786 template<
typename MT
791 return matrix_.cend(i);
815 template<
typename MT
817 inline StrictlyUpperMatrix<MT,SO,false>&
818 StrictlyUpperMatrix<MT,SO,false>::operator=(
const StrictlyUpperMatrix& rhs )
820 matrix_ = rhs.matrix_;
838 template<
typename MT
840 inline StrictlyUpperMatrix<MT,SO,false>&
841 StrictlyUpperMatrix<MT,SO,false>::operator=( StrictlyUpperMatrix&& rhs ) noexcept
843 matrix_ = std::move( rhs.matrix_ );
867 template<
typename MT
869 template<
typename MT2
871 inline DisableIf_< IsComputation<MT2>, StrictlyUpperMatrix<MT,SO,false>& >
872 StrictlyUpperMatrix<MT,SO,false>::operator=(
const Matrix<MT2,SO2>& rhs )
874 if( IsUniTriangular<MT2>::value ||
881 if( !IsStrictlyUpper<MT2>::value )
906 template<
typename MT
908 template<
typename MT2
910 inline EnableIf_< IsComputation<MT2>, StrictlyUpperMatrix<MT,SO,false>& >
911 StrictlyUpperMatrix<MT,SO,false>::operator=(
const Matrix<MT2,SO2>& rhs )
913 if( IsUniTriangular<MT2>::value || ( !IsSquare<MT2>::value && !
isSquare( ~rhs ) ) ) {
917 if( IsStrictlyUpper<MT2>::value ) {
927 matrix_ = std::move( tmp );
930 if( !IsStrictlyUpper<MT2>::value )
955 template<
typename MT
957 template<
typename MT2
959 inline DisableIf_< IsComputation<MT2>, StrictlyUpperMatrix<MT,SO,false>& >
962 if( IsUniTriangular<MT2>::value ||
969 if( !IsStrictlyUpper<MT2>::value )
994 template<
typename MT
996 template<
typename MT2
998 inline EnableIf_< IsComputation<MT2>, StrictlyUpperMatrix<MT,SO,false>& >
1001 if( IsUniTriangular<MT2>::value || ( IsSquare<MT2>::value && !
isSquare( ~rhs ) ) ) {
1005 if( IsStrictlyUpper<MT2>::value ) {
1009 const ResultType_<MT2> tmp( ~rhs );
1018 if( !IsStrictlyUpper<MT2>::value )
1043 template<
typename MT
1045 template<
typename MT2
1047 inline DisableIf_< IsComputation<MT2>, StrictlyUpperMatrix<MT,SO,false>& >
1050 if( IsUniTriangular<MT2>::value ||
1057 if( !IsStrictlyUpper<MT2>::value )
1082 template<
typename MT
1084 template<
typename MT2
1086 inline EnableIf_< IsComputation<MT2>, StrictlyUpperMatrix<MT,SO,false>& >
1089 if( IsUniTriangular<MT2>::value || ( !IsSquare<MT2>::value && !
isSquare( ~rhs ) ) ) {
1093 if( IsStrictlyUpper<MT2>::value ) {
1097 const ResultType_<MT2> tmp( ~rhs );
1106 if( !IsStrictlyUpper<MT2>::value )
1129 template<
typename MT
1131 template<
typename MT2
1133 inline StrictlyUpperMatrix<MT,SO,false>&
1134 StrictlyUpperMatrix<MT,SO,false>::operator%=(
const Matrix<MT2,SO2>& rhs )
1136 if( !IsSquare<MT2>::value && !
isSquare( ~rhs ) ) {
1142 if( !IsStrictlyUpper<MT2>::value )
1166 template<
typename MT
1168 template<
typename MT2
1170 inline StrictlyUpperMatrix<MT,SO,false>&
1173 if( matrix_.rows() != (~rhs).
columns() ) {
1177 MT tmp( matrix_ * ~rhs );
1183 matrix_ = std::move( tmp );
1185 if( !IsStrictlyUpper<MT2>::value )
1205 template<
typename MT
1207 template<
typename Other >
1208 inline EnableIf_< IsNumeric<Other>, StrictlyUpperMatrix<MT,SO,false> >&
1225 template<
typename MT
1227 template<
typename Other >
1228 inline EnableIf_< IsNumeric<Other>, StrictlyUpperMatrix<MT,SO,false> >&
1254 template<
typename MT
1258 return matrix_.rows();
1270 template<
typename MT
1274 return matrix_.columns();
1286 template<
typename MT
1290 return matrix_.capacity();
1308 template<
typename MT
1312 return matrix_.capacity(i);
1324 template<
typename MT
1328 return matrix_.nonZeros();
1346 template<
typename MT
1350 return matrix_.nonZeros(i);
1362 template<
typename MT
1367 for(
size_t j=1UL; j<
columns(); ++j ) {
1368 matrix_.erase( j, matrix_.begin(j), matrix_.lowerBound(j,j) );
1372 for(
size_t i=0UL; i<
rows(); ++i ) {
1373 matrix_.erase( i, matrix_.lowerBound(i,i+1UL), matrix_.end(i) );
1394 template<
typename MT
1399 matrix_.erase( i, matrix_.begin(i), matrix_.lowerBound(i,i) );
1402 matrix_.erase( i, matrix_.lowerBound(i,i+1UL), matrix_.end(i) );
1417 template<
typename MT
1423 if( IsResizable<MT>::value ) {
1449 template<
typename MT
1457 matrix_.resize( n, n, preserve );
1474 template<
typename MT
1476 inline void StrictlyUpperMatrix<MT,SO,false>::reserve(
size_t nonzeros )
1478 matrix_.reserve( nonzeros );
1499 template<
typename MT
1501 inline void StrictlyUpperMatrix<MT,SO,false>::reserve(
size_t i,
size_t nonzeros )
1503 matrix_.reserve( i, nonzeros );
1520 template<
typename MT
1522 inline void StrictlyUpperMatrix<MT,SO,false>::trim()
1542 template<
typename MT
1544 inline void StrictlyUpperMatrix<MT,SO,false>::trim(
size_t i )
1562 template<
typename MT
1566 matrix_.shrinkToFit();
1579 template<
typename MT
1585 swap( matrix_, m.matrix_ );
1603 template<
typename MT
1605 inline constexpr
size_t StrictlyUpperMatrix<MT,SO,false>::maxNonZeros() noexcept
1609 return maxNonZeros( Rows<MT>::value );
1625 template<
typename MT
1627 inline constexpr
size_t StrictlyUpperMatrix<MT,SO,false>::maxNonZeros(
size_t n ) noexcept
1629 return ( ( n - 1UL ) * n ) / 2UL;
1641 template<
typename MT
1643 inline void StrictlyUpperMatrix<MT,SO,false>::resetLower()
1646 for(
size_t j=0UL; j<
columns(); ++j )
1647 matrix_.erase( j, matrix_.upperBound( j, j ), matrix_.end( j ) );
1650 for(
size_t i=1UL; i<
rows(); ++i )
1651 matrix_.erase( i, matrix_.begin( i ), matrix_.lowerBound( i, i ) );
1682 template<
typename MT
1691 return matrix_.set( i, j, value );
1714 template<
typename MT
1717 StrictlyUpperMatrix<MT,SO,false>::insert(
size_t i,
size_t j,
const ElementType& value )
1723 return matrix_.insert( i, j, value );
1779 template<
typename MT
1781 inline void StrictlyUpperMatrix<MT,SO,false>::append(
size_t i,
size_t j,
const ElementType& value,
bool check )
1787 matrix_.append( i, j, value, check );
1807 template<
typename MT
1809 inline void StrictlyUpperMatrix<MT,SO,false>::finalize(
size_t i )
1811 matrix_.finalize( i );
1835 template<
typename MT
1837 inline void StrictlyUpperMatrix<MT,SO,false>::erase(
size_t i,
size_t j )
1839 matrix_.erase( i, j );
1857 template<
typename MT
1860 StrictlyUpperMatrix<MT,SO,false>::erase(
size_t i,
Iterator pos )
1862 return matrix_.erase( i, pos );
1882 template<
typename MT
1885 StrictlyUpperMatrix<MT,SO,false>::erase(
size_t i,
Iterator first,
Iterator last )
1887 return matrix_.erase( i, first, last );
1915 template<
typename MT
1917 template<
typename Pred >
1918 inline void StrictlyUpperMatrix<MT,SO,false>::erase( Pred predicate )
1920 matrix_.erase( predicate );
1956 template<
typename MT
1958 template<
typename Pred >
1959 inline void StrictlyUpperMatrix<MT,SO,false>::erase(
size_t i,
Iterator first,
Iterator last, Pred predicate )
1961 matrix_.erase( i, first, last, predicate );
1993 template<
typename MT
1996 StrictlyUpperMatrix<MT,SO,false>::find(
size_t i,
size_t j )
1998 return matrix_.find( i, j );
2020 template<
typename MT
2023 StrictlyUpperMatrix<MT,SO,false>::find(
size_t i,
size_t j )
const 2025 return matrix_.find( i, j );
2047 template<
typename MT
2050 StrictlyUpperMatrix<MT,SO,false>::lowerBound(
size_t i,
size_t j )
2052 return matrix_.lowerBound( i, j );
2074 template<
typename MT
2077 StrictlyUpperMatrix<MT,SO,false>::lowerBound(
size_t i,
size_t j )
const 2079 return matrix_.lowerBound( i, j );
2101 template<
typename MT
2104 StrictlyUpperMatrix<MT,SO,false>::upperBound(
size_t i,
size_t j )
2106 return matrix_.upperBound( i, j );
2128 template<
typename MT
2131 StrictlyUpperMatrix<MT,SO,false>::upperBound(
size_t i,
size_t j )
const 2133 return matrix_.upperBound( i, j );
2165 template<
typename MT
2167 template<
typename Other >
2168 inline StrictlyUpperMatrix<MT,SO,false>&
2169 StrictlyUpperMatrix<MT,SO,false>::scale(
const Other& scalar )
2171 matrix_.scale( scalar );
2188 template<
typename MT
2190 template<
typename Other >
2191 inline StrictlyUpperMatrix<MT,SO,false>&
2192 StrictlyUpperMatrix<MT,SO,false>::scaleDiagonal(
const Other& scalar )
2194 matrix_.scaleDiagonal( scalar );
2219 template<
typename MT
2250 template<
typename MT
2252 template<
typename Other >
2253 inline bool StrictlyUpperMatrix<MT,SO,false>::canAlias(
const Other* alias )
const noexcept
2255 return matrix_.canAlias( alias );
2272 template<
typename MT
2274 template<
typename Other >
2275 inline bool StrictlyUpperMatrix<MT,SO,false>::isAliased(
const Other* alias )
const noexcept
2277 return matrix_.isAliased( alias );
2294 template<
typename MT
2296 inline bool StrictlyUpperMatrix<MT,SO,false>::canSMPAssign() const noexcept
2298 return matrix_.canSMPAssign();
Header file for the StrictlyUpperProxy class.
#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:79
#define BLAZE_THROW_INVALID_ARGUMENT(MESSAGE)
Macro for the emission of a std::invalid_argument exception.This macro encapsulates the default way o...
Definition: Exception.h:235
Header file for auxiliary alias declarations.
CompressedMatrix< Type, false > OppositeType
Result type with opposite storage order for expression template evaluations.
Definition: CompressedMatrix.h:3079
#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
Header file for the Rows type trait.
BLAZE_ALWAYS_INLINE size_t capacity(const Matrix< MT, SO > &matrix) noexcept
Returns the maximum capacity of the matrix.
Definition: Matrix.h:356
Header file for basic type definitions.
#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:63
BLAZE_ALWAYS_INLINE T1 & operator/=(SIMDPack< T1 > &lhs, const SIMDPack< T2 > &rhs)
Division assignment operator for the division of two SIMD packs.
Definition: BasicTypes.h:1411
Constraint on the data type.
This ResultType
Result type for expression template evaluations.
Definition: CompressedMatrix.h:3078
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:198
CompressedMatrix< Type, true > This
Type of this CompressedMatrix instance.
Definition: CompressedMatrix.h:3076
Constraint on the data type.
void reset(const DiagonalProxy< MT > &proxy)
Resetting the represented element to the default initial values.
Definition: DiagonalProxy.h:560
BLAZE_ALWAYS_INLINE void shrinkToFit(Matrix< MT, SO > &matrix)
Requesting the removal of unused capacity.
Definition: Matrix.h:609
void clear(CompressedMatrix< Type, SO > &m)
Clearing the given compressed matrix.
Definition: CompressedMatrix.h:5845
CompressedMatrix< Type, false > TransposeType
Transpose type for expression template evaluations.
Definition: CompressedMatrix.h:3080
const Type & ConstReference
Reference to a constant matrix value.
Definition: CompressedMatrix.h:3085
decltype(auto) declupp(const DenseMatrix< MT, SO > &dm)
Declares the given dense matrix expression dm as upper.
Definition: DMatDeclUppExpr.h:1027
#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:79
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:394
Element * Iterator
Iterator over non-constant elements.
Definition: CompressedMatrix.h:3086
BLAZE_ALWAYS_INLINE T1 & operator*=(SIMDPack< T1 > &lhs, const SIMDPack< T2 > &rhs)
Multiplication assignment operator for the multiplication of two SIMD packs.
Definition: BasicTypes.h:1393
Constraint on the data type.
const ElementType_< MT > max(const DenseMatrix< MT, SO > &dm)
Returns the largest element of the dense matrix.
Definition: DenseMatrix.h:1809
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:308
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:242
Constraint on the data type.
Constraint on the data type.
Constraint on the data type.
Header file for the SparseMatrix base class.
Header file for utility functions for sparse matrices.
Header file for the IsSquare type trait.
Constraint on the data type.
Headerfile for the generic max algorithm.
Header file for the DisableIf class template.
Header file for the IsStrictlyUpper type trait.
MatrixAccessProxy< This > Reference
Reference to a non-constant matrix value.
Definition: CompressedMatrix.h:3084
Header file for the clear shim.
Namespace of the Blaze C++ math library.
Definition: Blaze.h:57
#define BLAZE_CONSTRAINT_MUST_BE_STATIC_TYPE(T)
Constraint on the data type.In case the given data type T is not a static data type, i.e. a vector or matrix with dimensions fixed at compile time, a compilation error is created.
Definition: Static.h:61
void swap(CompressedMatrix< Type, SO > &a, CompressedMatrix< Type, SO > &b) noexcept
Swapping the contents of two compressed matrices.
Definition: CompressedMatrix.h:5924
bool isIntact(const CompressedMatrix< Type, SO > &m)
Returns whether the invariants of the given compressed matrix are intact.
Definition: CompressedMatrix.h:5907
SparseMatrix< This, true > BaseType
Base type of this CompressedMatrix instance.
Definition: CompressedMatrix.h:3077
#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:79
Type ElementType
Type of the compressed matrix elements.
Definition: CompressedMatrix.h:3081
#define BLAZE_THROW_OUT_OF_RANGE(MESSAGE)
Macro for the emission of a std::out_of_range exception.This macro encapsulates the default way of Bl...
Definition: Exception.h:331
Header file for the Columns type trait.
const Element * ConstIterator
Iterator over constant elements.
Definition: CompressedMatrix.h:3087
Constraint on the data type.
BLAZE_ALWAYS_INLINE size_t columns(const Matrix< MT, SO > &matrix) noexcept
Returns the current number of columns of the matrix.
Definition: Matrix.h:340
Header file for the IsUniTriangular type trait.
Constraints on the storage order of matrix types.
Header file for the exception macros of the math module.
#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:81
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:548
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:264
Header file for the EnableIf class template.
void clear(const DiagonalProxy< MT > &proxy)
Clearing the represented element.
Definition: DiagonalProxy.h:580
Header file for the implementation of the base template of the StrictlyUpperMatrix.
Header file for the IsNumeric type trait.
BLAZE_ALWAYS_INLINE const EnableIf_< And< IsIntegral< T >, HasSize< T, 1UL > >, If_< IsSigned< T >, SIMDint8, SIMDuint8 > > set(T value) noexcept
Sets all values in the vector to the given 1-byte integral value.
Definition: Set.h:76
Header file for all adaptor forward declarations.
#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:79
bool isStrictlyUpper(const DenseMatrix< MT, SO > &dm)
Checks if the given dense matrix is a strictly upper triangular matrix.
Definition: DenseMatrix.h:1500
BLAZE_ALWAYS_INLINE T1 & operator+=(SIMDPack< T1 > &lhs, const SIMDPack< T2 > &rhs)
Addition assignment operator for the addition of two SIMD packs.
Definition: BasicTypes.h:1357
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:81
#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:79
Header file for the isDefault shim.
void swap(DiagonalMatrix< MT, SO, DF > &a, DiagonalMatrix< MT, SO, DF > &b) noexcept
Swapping the contents of two matrices.
Definition: DiagonalMatrix.h:270
Constraint on the data type.
Constraint on the data type.
BLAZE_ALWAYS_INLINE size_t rows(const Matrix< MT, SO > &matrix) noexcept
Returns the current number of rows of the matrix.
Definition: Matrix.h:324
const Type & ReturnType
Return type for expression template evaluations.
Definition: CompressedMatrix.h:3082
#define BLAZE_CONSTRAINT_MUST_BE_RESIZABLE_TYPE(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:61
Header file for the IsComputation type trait class.
const This & CompositeType
Data type for composite expression templates.
Definition: CompressedMatrix.h:3083
#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:81
bool isIntact(const DiagonalMatrix< MT, SO, DF > &m)
Returns whether the invariants of the given diagonal matrix are intact.
Definition: DiagonalMatrix.h:252
#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:79
BLAZE_ALWAYS_INLINE T1 & operator-=(SIMDPack< T1 > &lhs, const SIMDPack< T2 > &rhs)
Subtraction assignment operator for the subtraction of two SIMD packs.
Definition: BasicTypes.h:1375
#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:112
BLAZE_ALWAYS_INLINE bool isSquare(const Matrix< MT, SO > &matrix) noexcept
Checks if the given matrix is a square matrix.
Definition: Matrix.h:742
Header file for the IsResizable type trait.
#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:61