Blaze 3.9
StrictlyUpperMatrix.h
Go to the documentation of this file.
1//=================================================================================================
33//=================================================================================================
34
35#ifndef _BLAZE_MATH_ADAPTORS_STRICTLYUPPERMATRIX_H_
36#define _BLAZE_MATH_ADAPTORS_STRICTLYUPPERMATRIX_H_
37
38
39//*************************************************************************************************
40// Includes
41//*************************************************************************************************
42
47#include <blaze/math/Forward.h>
95#include <blaze/util/Assert.h>
96#include <blaze/util/EnableIf.h>
100
101
102namespace blaze {
103
104//=================================================================================================
105//
106// STRICTLYUPPERMATRIX OPERATORS
107//
108//=================================================================================================
109
110//*************************************************************************************************
113template< RelaxationFlag RF, typename MT, bool SO, bool DF >
114bool isDefault( const StrictlyUpperMatrix<MT,SO,DF>& m );
115
116template< typename MT, bool SO, bool DF >
117bool isIntact( const StrictlyUpperMatrix<MT,SO,DF>& m );
118
119template< typename MT, bool SO, bool DF >
120void swap( StrictlyUpperMatrix<MT,SO,DF>& a, StrictlyUpperMatrix<MT,SO,DF>& b ) noexcept;
122//*************************************************************************************************
123
124
125//*************************************************************************************************
152template< RelaxationFlag RF // Relaxation flag
153 , typename MT // Type of the adapted matrix
154 , bool SO // Storage order of the adapted matrix
155 , bool DF > // Density flag
156inline bool isDefault( const StrictlyUpperMatrix<MT,SO,DF>& m )
157{
158 if( Size_v<MT,0UL> == DefaultSize_v )
159 return m.rows() == 0UL;
160 else return isLower<RF>( m );
161}
162//*************************************************************************************************
163
164
165//*************************************************************************************************
186template< typename MT // Type of the adapted matrix
187 , bool SO // Storage order of the adapted matrix
188 , bool DF > // Density flag
189inline bool isIntact( const StrictlyUpperMatrix<MT,SO,DF>& m )
190{
191 return m.isIntact();
192}
193//*************************************************************************************************
194
195
196//*************************************************************************************************
204template< typename MT // Type of the adapted matrix
205 , bool SO // Storage order of the adapted matrix
206 , bool DF > // Density flag
207inline void swap( StrictlyUpperMatrix<MT,SO,DF>& a, StrictlyUpperMatrix<MT,SO,DF>& b ) noexcept
208{
209 a.swap( b );
210}
211//*************************************************************************************************
212
213
214//*************************************************************************************************
230template< typename MT // Type of the adapted matrix
231 , bool SO // Storage order of the adapted matrix
232 , bool DF // Density flag
233 , typename ET > // Type of the element
234inline bool trySet( const StrictlyUpperMatrix<MT,SO,DF>& mat, size_t i, size_t j, const ET& value )
235{
236 BLAZE_INTERNAL_ASSERT( i < (*mat).rows(), "Invalid row access index" );
237 BLAZE_INTERNAL_ASSERT( j < (*mat).columns(), "Invalid column access index" );
238
239 MAYBE_UNUSED( mat );
240
241 return ( i < j || isDefault( value ) );
242}
244//*************************************************************************************************
245
246
247//*************************************************************************************************
265template< typename MT // Type of the adapted matrix
266 , bool SO // Storage order of the adapted matrix
267 , bool DF // Density flag
268 , typename ET > // Type of the element
270 trySet( const StrictlyUpperMatrix<MT,SO,DF>& mat, size_t row, size_t column, size_t m, size_t n, const ET& value )
271{
272 BLAZE_INTERNAL_ASSERT( row <= (*mat).rows(), "Invalid row access index" );
273 BLAZE_INTERNAL_ASSERT( column <= (*mat).columns(), "Invalid column access index" );
274 BLAZE_INTERNAL_ASSERT( row + m <= (*mat).rows(), "Invalid number of rows" );
275 BLAZE_INTERNAL_ASSERT( column + n <= (*mat).columns(), "Invalid number of columns" );
276
277 MAYBE_UNUSED( mat );
278
279 return ( m == 0UL ) ||
280 ( n == 0UL ) ||
281 ( column >= row + m ) ||
282 isDefault( value );
283}
285//*************************************************************************************************
286
287
288//*************************************************************************************************
304template< typename MT // Type of the adapted matrix
305 , bool SO // Storage order of the adapted matrix
306 , bool DF // Density flag
307 , typename ET > // Type of the element
308inline bool tryAdd( const StrictlyUpperMatrix<MT,SO,DF>& mat, size_t i, size_t j, const ET& value )
309{
310 return trySet( mat, i, j, value );
311}
313//*************************************************************************************************
314
315
316//*************************************************************************************************
334template< typename MT // Type of the adapted matrix
335 , bool SO // Storage order of the adapted matrix
336 , bool DF // Density flag
337 , typename ET > // Type of the element
339 tryAdd( const StrictlyUpperMatrix<MT,SO,DF>& mat, size_t row, size_t column, size_t m, size_t n, const ET& value )
340{
341 return trySet( mat, row, column, m, n, value );
342}
344//*************************************************************************************************
345
346
347//*************************************************************************************************
364template< typename MT // Type of the adapted matrix
365 , bool SO // Storage order of the adapted matrix
366 , bool DF // Density flag
367 , typename ET > // Type of the element
368inline bool trySub( const StrictlyUpperMatrix<MT,SO,DF>& mat, size_t i, size_t j, const ET& value )
369{
370 return trySet( mat, i, j, value );
371}
373//*************************************************************************************************
374
375
376//*************************************************************************************************
395template< typename MT // Type of the adapted matrix
396 , bool SO // Storage order of the adapted matrix
397 , bool DF // Density flag
398 , typename ET > // Type of the element
400 trySub( const StrictlyUpperMatrix<MT,SO,DF>& mat, size_t row, size_t column, size_t m, size_t n, const ET& value )
401{
402 return trySet( mat, row, column, m, n, value );
403}
405//*************************************************************************************************
406
407
408//*************************************************************************************************
424template< typename MT // Type of the adapted matrix
425 , bool SO // Storage order of the adapted matrix
426 , bool DF // Density flag
427 , typename ET > // Type of the element
428inline bool tryBitor( const StrictlyUpperMatrix<MT,SO,DF>& mat, size_t i, size_t j, const ET& value )
429{
430 return trySet( mat, i, j, value );
431}
433//*************************************************************************************************
434
435
436//*************************************************************************************************
455template< typename MT // Type of the adapted matrix
456 , bool SO // Storage order of the adapted matrix
457 , bool DF // Density flag
458 , typename ET > // Type of the element
460 tryBitor( const StrictlyUpperMatrix<MT,SO,DF>& mat, size_t row, size_t column, size_t m, size_t n, const ET& value )
461{
462 return trySet( mat, row, column, m, n, value );
463}
465//*************************************************************************************************
466
467
468//*************************************************************************************************
484template< typename MT // Type of the adapted matrix
485 , bool SO // Storage order of the adapted matrix
486 , bool DF // Density flag
487 , typename ET > // Type of the element
488inline bool tryBitxor( const StrictlyUpperMatrix<MT,SO,DF>& mat, size_t i, size_t j, const ET& value )
489{
490 return tryAdd( mat, i, j, value );
491}
493//*************************************************************************************************
494
495
496//*************************************************************************************************
515template< typename MT // Type of the adapted matrix
516 , bool SO // Storage order of the adapted matrix
517 , bool DF // Density flag
518 , typename ET > // Type of the element
520 tryBitxor( const StrictlyUpperMatrix<MT,SO,DF>& mat, size_t row, size_t column, size_t m, size_t n, const ET& value )
521{
522 return tryAdd( mat, row, column, m, n, value );
523}
525//*************************************************************************************************
526
527
528//*************************************************************************************************
545template< typename MT // Type of the adapted matrix
546 , bool SO // Storage order of the adapted matrix
547 , bool DF // Density flag
548 , typename VT > // Type of the right-hand side dense vector
549inline bool tryAssign( const StrictlyUpperMatrix<MT,SO,DF>& lhs,
550 const DenseVector<VT,false>& rhs, size_t row, size_t column )
551{
553
554 BLAZE_INTERNAL_ASSERT( row <= lhs.rows(), "Invalid row access index" );
555 BLAZE_INTERNAL_ASSERT( column <= lhs.columns(), "Invalid column access index" );
556 BLAZE_INTERNAL_ASSERT( row + (*rhs).size() <= lhs.rows(), "Invalid number of rows" );
557
558 MAYBE_UNUSED( lhs );
559
560 const size_t ibegin( ( column <= row )?( 0UL ):( column - row ) );
561
562 for( size_t i=ibegin; i<(*rhs).size(); ++i ) {
563 if( !isDefault( (*rhs)[i] ) )
564 return false;
565 }
566
567 return true;
568}
570//*************************************************************************************************
571
572
573//*************************************************************************************************
590template< typename MT // Type of the adapted matrix
591 , bool SO // Storage order of the adapted matrix
592 , bool DF // Density flag
593 , typename VT > // Type of the right-hand side dense vector
594inline bool tryAssign( const StrictlyUpperMatrix<MT,SO,DF>& lhs,
595 const DenseVector<VT,true>& rhs, size_t row, size_t column )
596{
598
599 BLAZE_INTERNAL_ASSERT( row <= lhs.rows(), "Invalid row access index" );
600 BLAZE_INTERNAL_ASSERT( column <= lhs.columns(), "Invalid column access index" );
601 BLAZE_INTERNAL_ASSERT( column + (*rhs).size() <= lhs.columns(), "Invalid number of columns" );
602
603 MAYBE_UNUSED( lhs );
604
605 if( row < column )
606 return true;
607
608 const size_t iend( min( row - column + 1UL, (*rhs).size() ) );
609
610 for( size_t i=0UL; i<iend; ++i ) {
611 if( !isDefault( (*rhs)[i] ) )
612 return false;
613 }
614
615 return true;
616}
618//*************************************************************************************************
619
620
621//*************************************************************************************************
639template< typename MT // Type of the adapted matrix
640 , bool SO // Storage order of the adapted matrix
641 , bool DF // Density flag
642 , typename VT // Type of the right-hand side dense vector
643 , bool TF > // Transpose flag of the right-hand side dense vector
644inline bool tryAssign( const StrictlyUpperMatrix<MT,SO,DF>& lhs, const DenseVector<VT,TF>& rhs,
645 ptrdiff_t band, size_t row, size_t column )
646{
648
649 BLAZE_INTERNAL_ASSERT( row <= lhs.rows(), "Invalid row access index" );
650 BLAZE_INTERNAL_ASSERT( column <= lhs.columns(), "Invalid column access index" );
651 BLAZE_INTERNAL_ASSERT( row + (*rhs).size() <= lhs.rows(), "Invalid number of rows" );
652 BLAZE_INTERNAL_ASSERT( column + (*rhs).size() <= lhs.columns(), "Invalid number of columns" );
653
654 MAYBE_UNUSED( lhs, row, column );
655
656 if( band <= 0L ) {
657 for( size_t i=0UL; i<(*rhs).size(); ++i ) {
658 if( !isDefault( (*rhs)[i] ) )
659 return false;
660 }
661 }
662
663 return true;
664}
666//*************************************************************************************************
667
668
669//*************************************************************************************************
686template< typename MT // Type of the adapted matrix
687 , bool SO // Storage order of the adapted matrix
688 , bool DF // Density flag
689 , typename VT > // Type of the right-hand side sparse vector
690inline bool tryAssign( const StrictlyUpperMatrix<MT,SO,DF>& lhs,
691 const SparseVector<VT,false>& rhs, size_t row, size_t column )
692{
694
695 BLAZE_INTERNAL_ASSERT( row <= lhs.rows(), "Invalid row access index" );
696 BLAZE_INTERNAL_ASSERT( column <= lhs.columns(), "Invalid column access index" );
697 BLAZE_INTERNAL_ASSERT( row + (*rhs).size() <= lhs.rows(), "Invalid number of rows" );
698
699 MAYBE_UNUSED( lhs );
700
701 const auto last( (*rhs).end() );
702 auto element( (*rhs).lowerBound( ( column <= row )?( 0UL ):( column - row ) ) );
703
704 for( ; element!=last; ++element ) {
705 if( !isDefault( element->value() ) )
706 return false;
707 }
708
709 return true;
710}
712//*************************************************************************************************
713
714
715//*************************************************************************************************
732template< typename MT // Type of the adapted matrix
733 , bool SO // Storage order of the adapted matrix
734 , bool DF // Density flag
735 , typename VT > // Type of the right-hand side sparse vector
736inline bool tryAssign( const StrictlyUpperMatrix<MT,SO,DF>& lhs,
737 const SparseVector<VT,true>& rhs, size_t row, size_t column )
738{
740
741 BLAZE_INTERNAL_ASSERT( row <= lhs.rows(), "Invalid row access index" );
742 BLAZE_INTERNAL_ASSERT( column <= lhs.columns(), "Invalid column access index" );
743 BLAZE_INTERNAL_ASSERT( column + (*rhs).size() <= lhs.columns(), "Invalid number of columns" );
744
745 MAYBE_UNUSED( lhs );
746
747 if( row < column )
748 return true;
749
750 const auto last( (*rhs).lowerBound( row - column + 1UL ) );
751
752 for( auto element=(*rhs).begin(); element!=last; ++element ) {
753 if( !isDefault( element->value() ) )
754 return false;
755 }
756
757 return true;
758}
760//*************************************************************************************************
761
762
763//*************************************************************************************************
781template< typename MT // Type of the adapted matrix
782 , bool SO // Storage order of the adapted matrix
783 , bool DF // Density flag
784 , typename VT // Type of the right-hand side sparse vector
785 , bool TF > // Transpose flag of the right-hand side sparse vector
786inline bool tryAssign( const StrictlyUpperMatrix<MT,SO,DF>& lhs, const SparseVector<VT,TF>& rhs,
787 ptrdiff_t band, size_t row, size_t column )
788{
790
791 BLAZE_INTERNAL_ASSERT( row <= lhs.rows(), "Invalid row access index" );
792 BLAZE_INTERNAL_ASSERT( column <= lhs.columns(), "Invalid column access index" );
793 BLAZE_INTERNAL_ASSERT( row + (*rhs).size() <= lhs.rows(), "Invalid number of rows" );
794 BLAZE_INTERNAL_ASSERT( column + (*rhs).size() <= lhs.columns(), "Invalid number of columns" );
795
796 MAYBE_UNUSED( lhs, row, column );
797
798 if( band <= 0L ) {
799 for( const auto& element : *rhs ) {
800 if( !isDefault( element.value() ) )
801 return false;
802 }
803 }
804
805 return true;
806}
808//*************************************************************************************************
809
810
811//*************************************************************************************************
828template< typename MT1 // Type of the adapted matrix
829 , bool SO // Storage order of the adapted matrix
830 , bool DF // Density flag
831 , typename MT2 > // Type of the right-hand side dense matrix
832inline bool tryAssign( const StrictlyUpperMatrix<MT1,SO,DF>& lhs,
833 const DenseMatrix<MT2,false>& rhs, size_t row, size_t column )
834{
836
837 BLAZE_INTERNAL_ASSERT( row <= lhs.rows(), "Invalid row access index" );
838 BLAZE_INTERNAL_ASSERT( column <= lhs.columns(), "Invalid column access index" );
839 BLAZE_INTERNAL_ASSERT( row + (*rhs).rows() <= lhs.rows(), "Invalid number of rows" );
840 BLAZE_INTERNAL_ASSERT( column + (*rhs).columns() <= lhs.columns(), "Invalid number of columns" );
841
842 MAYBE_UNUSED( lhs );
843
844 const size_t M( (*rhs).rows() );
845 const size_t N( (*rhs).columns() );
846
847 if( column >= row + M )
848 return true;
849
850 const size_t ibegin( ( column <= row )?( 0UL ):( column - row ) );
851
852 for( size_t i=ibegin; i<M; ++i )
853 {
854 const size_t jend( min( row + i - column + 1UL, N ) );
855
856 for( size_t j=0UL; j<jend; ++j ) {
857 if( !isDefault( (*rhs)(i,j) ) )
858 return false;
859 }
860 }
861
862 return true;
863}
865//*************************************************************************************************
866
867
868//*************************************************************************************************
885template< typename MT1 // Type of the adapted matrix
886 , bool SO // Storage order of the adapted matrix
887 , bool DF // Density flag
888 , typename MT2 > // Type of the right-hand side dense matrix
889inline bool tryAssign( const StrictlyUpperMatrix<MT1,SO,DF>& lhs,
890 const DenseMatrix<MT2,true>& rhs, size_t row, size_t column )
891{
893
894 BLAZE_INTERNAL_ASSERT( row <= lhs.rows(), "Invalid row access index" );
895 BLAZE_INTERNAL_ASSERT( column <= lhs.columns(), "Invalid column access index" );
896 BLAZE_INTERNAL_ASSERT( row + (*rhs).rows() <= lhs.rows(), "Invalid number of rows" );
897 BLAZE_INTERNAL_ASSERT( column + (*rhs).columns() <= lhs.columns(), "Invalid number of columns" );
898
899 MAYBE_UNUSED( lhs );
900
901 const size_t M( (*rhs).rows() );
902 const size_t N( (*rhs).columns() );
903
904 if( column >= row + M )
905 return true;
906
907 const size_t jend( min( row + M - column, N ) );
908
909 for( size_t j=0UL; j<jend; ++j )
910 {
911 const bool containsDiagonal( column + j >= row );
912 const size_t ibegin( ( containsDiagonal )?( column + j - row ):( 0UL ) );
913
914 for( size_t i=ibegin; i<M; ++i ) {
915 if( !isDefault( (*rhs)(i,j) ) )
916 return false;
917 }
918 }
919
920 return true;
921}
923//*************************************************************************************************
924
925
926//*************************************************************************************************
943template< typename MT1 // Type of the adapted matrix
944 , bool SO // Storage order of the adapted matrix
945 , bool DF // Density flag
946 , typename MT2 > // Type of the right-hand side sparse matrix
947inline bool tryAssign( const StrictlyUpperMatrix<MT1,SO,DF>& lhs,
948 const SparseMatrix<MT2,false>& rhs, size_t row, size_t column )
949{
951
952 BLAZE_INTERNAL_ASSERT( row <= lhs.rows(), "Invalid row access index" );
953 BLAZE_INTERNAL_ASSERT( column <= lhs.columns(), "Invalid column access index" );
954 BLAZE_INTERNAL_ASSERT( row + (*rhs).rows() <= lhs.rows(), "Invalid number of rows" );
955 BLAZE_INTERNAL_ASSERT( column + (*rhs).columns() <= lhs.columns(), "Invalid number of columns" );
956
957 MAYBE_UNUSED( lhs );
958
959 const size_t M( (*rhs).rows() );
960 const size_t N( (*rhs).columns() );
961
962 if( column >= row + M )
963 return true;
964
965 const size_t ibegin( ( column < row )?( 0UL ):( column - row ) );
966
967 for( size_t i=ibegin; i<M; ++i )
968 {
969 const size_t index( row + i - column + 1UL );
970 const auto last( (*rhs).lowerBound( i, min( index, N ) ) );
971
972 for( auto element=(*rhs).begin(i); element!=last; ++element ) {
973 if( !isDefault( element->value() ) )
974 return false;
975 }
976 }
977
978 return true;
979}
981//*************************************************************************************************
982
983
984//*************************************************************************************************
1001template< typename MT1 // Type of the adapted matrix
1002 , bool SO // Storage order of the adapted matrix
1003 , bool DF // Density flag
1004 , typename MT2 > // Type of the right-hand side sparse matrix
1005inline bool tryAssign( const StrictlyUpperMatrix<MT1,SO,DF>& lhs,
1006 const SparseMatrix<MT2,true>& rhs, size_t row, size_t column )
1007{
1009
1010 BLAZE_INTERNAL_ASSERT( row <= lhs.rows(), "Invalid row access index" );
1011 BLAZE_INTERNAL_ASSERT( column <= lhs.columns(), "Invalid column access index" );
1012 BLAZE_INTERNAL_ASSERT( row + (*rhs).rows() <= lhs.rows(), "Invalid number of rows" );
1013 BLAZE_INTERNAL_ASSERT( column + (*rhs).columns() <= lhs.columns(), "Invalid number of columns" );
1014
1015 MAYBE_UNUSED( lhs );
1016
1017 const size_t M( (*rhs).rows() );
1018 const size_t N( (*rhs).columns() );
1019
1020 if( column >= row + M )
1021 return true;
1022
1023 const size_t jend( min( row + M - column, N ) );
1024
1025 for( size_t j=0UL; j<jend; ++j )
1026 {
1027 const bool containsDiagonal( column + j >= row );
1028 const size_t index( ( containsDiagonal )?( column + j - row ):( 0UL ) );
1029
1030 const auto last( (*rhs).end(j) );
1031 auto element( (*rhs).lowerBound( index, j ) );
1032
1033 for( ; element!=last; ++element ) {
1034 if( !isDefault( element->value() ) )
1035 return false;
1036 }
1037 }
1038
1039 return true;
1040}
1042//*************************************************************************************************
1043
1044
1045//*************************************************************************************************
1062template< typename MT // Type of the adapted matrix
1063 , bool SO // Storage order of the adapted matrix
1064 , bool DF // Density flag
1065 , typename VT // Type of the right-hand side vector
1066 , bool TF > // Transpose flag of the right-hand side vector
1067inline bool tryAddAssign( const StrictlyUpperMatrix<MT,SO,DF>& lhs,
1068 const Vector<VT,TF>& rhs, size_t row, size_t column )
1069{
1070 return tryAssign( lhs, *rhs, row, column );
1071}
1073//*************************************************************************************************
1074
1075
1076//*************************************************************************************************
1094template< typename MT // Type of the adapted matrix
1095 , bool SO // Storage order of the adapted matrix
1096 , bool DF // Density flag
1097 , typename VT // Type of the right-hand side vector
1098 , bool TF > // Transpose flag of the right-hand side vector
1099inline bool tryAddAssign( const StrictlyUpperMatrix<MT,SO,DF>& lhs, const Vector<VT,TF>& rhs,
1100 ptrdiff_t band, size_t row, size_t column )
1101{
1102 return tryAssign( lhs, *rhs, band, row, column );
1103}
1105//*************************************************************************************************
1106
1107
1108//*************************************************************************************************
1125template< typename MT1 // Type of the adapted matrix
1126 , bool SO1 // Storage order of the adapted matrix
1127 , bool DF // Density flag
1128 , typename MT2 // Type of the right-hand side matrix
1129 , bool SO2 > // Storage order of the right-hand side matrix
1130inline bool tryAddAssign( const StrictlyUpperMatrix<MT1,SO1,DF>& lhs,
1131 const Matrix<MT2,SO2>& rhs, size_t row, size_t column )
1132{
1133 return tryAssign( lhs, *rhs, row, column );
1134}
1136//*************************************************************************************************
1137
1138
1139//*************************************************************************************************
1156template< typename MT // Type of the adapted matrix
1157 , bool SO // Storage order of the adapted matrix
1158 , bool DF // Density flag
1159 , typename VT // Type of the right-hand side vector
1160 , bool TF > // Transpose flag of the right-hand side vector
1161inline bool trySubAssign( const StrictlyUpperMatrix<MT,SO,DF>& lhs,
1162 const Vector<VT,TF>& rhs, size_t row, size_t column )
1163{
1164 return tryAssign( lhs, *rhs, row, column );
1165}
1167//*************************************************************************************************
1168
1169
1170//*************************************************************************************************
1188template< typename MT // Type of the adapted matrix
1189 , bool SO // Storage order of the adapted matrix
1190 , bool DF // Density flag
1191 , typename VT // Type of the right-hand side vector
1192 , bool TF > // Transpose flag of the right-hand side vector
1193inline bool trySubAssign( const StrictlyUpperMatrix<MT,SO,DF>& lhs, const Vector<VT,TF>& rhs,
1194 ptrdiff_t band, size_t row, size_t column )
1195{
1196 return tryAssign( lhs, *rhs, band, row, column );
1197}
1199//*************************************************************************************************
1200
1201
1202//*************************************************************************************************
1219template< typename MT1 // Type of the adapted matrix
1220 , bool SO1 // Storage order of the adapted matrix
1221 , bool DF // Density flag
1222 , typename MT2 // Type of the right-hand side matrix
1223 , bool SO2 > // Storage order of the right-hand side matrix
1224inline bool trySubAssign( const StrictlyUpperMatrix<MT1,SO1,DF>& lhs,
1225 const Matrix<MT2,SO2>& rhs, size_t row, size_t column )
1226{
1227 return tryAssign( lhs, *rhs, row, column );
1228}
1230//*************************************************************************************************
1231
1232
1233//*************************************************************************************************
1250template< typename MT // Type of the adapted matrix
1251 , bool SO // Storage order of the adapted matrix
1252 , bool DF // Density flag
1253 , typename VT // Type of the right-hand side vector
1254 , bool TF > // Transpose flag of the right-hand side vector
1255inline bool tryBitorAssign( const StrictlyUpperMatrix<MT,SO,DF>& lhs,
1256 const Vector<VT,TF>& rhs, size_t row, size_t column )
1257{
1258 return tryAssign( lhs, *rhs, row, column );
1259}
1261//*************************************************************************************************
1262
1263
1264//*************************************************************************************************
1281template< typename MT // Type of the adapted matrix
1282 , bool SO // Storage order of the adapted matrix
1283 , bool DF // Density flag
1284 , typename VT // Type of the right-hand side vector
1285 , bool TF > // Transpose flag of the right-hand side vector
1286inline bool tryBitorAssign( const StrictlyUpperMatrix<MT,SO,DF>& lhs, const Vector<VT,TF>& rhs,
1287 ptrdiff_t band, size_t row, size_t column )
1288{
1289 return tryAssign( lhs, *rhs, band, row, column );
1290}
1292//*************************************************************************************************
1293
1294
1295//*************************************************************************************************
1312template< typename MT1 // Type of the adapted matrix
1313 , bool SO1 // Storage order of the adapted matrix
1314 , bool DF // Density flag
1315 , typename MT2 // Type of the right-hand side matrix
1316 , bool SO2 > // Storage order of the right-hand side matrix
1317inline bool tryBitorAssign( const StrictlyUpperMatrix<MT1,SO1,DF>& lhs,
1318 const Matrix<MT2,SO2>& rhs, size_t row, size_t column )
1319{
1320 return tryAssign( lhs, *rhs, row, column );
1321}
1323//*************************************************************************************************
1324
1325
1326//*************************************************************************************************
1343template< typename MT // Type of the adapted matrix
1344 , bool SO // Storage order of the adapted matrix
1345 , bool DF // Density flag
1346 , typename VT // Type of the right-hand side vector
1347 , bool TF > // Transpose flag of the right-hand side vector
1348inline bool tryBitxorAssign( const StrictlyUpperMatrix<MT,SO,DF>& lhs,
1349 const Vector<VT,TF>& rhs, size_t row, size_t column )
1350{
1351 return tryAssign( lhs, *rhs, row, column );
1352}
1354//*************************************************************************************************
1355
1356
1357//*************************************************************************************************
1374template< typename MT // Type of the adapted matrix
1375 , bool SO // Storage order of the adapted matrix
1376 , bool DF // Density flag
1377 , typename VT // Type of the right-hand side vector
1378 , bool TF > // Transpose flag of the right-hand side vector
1379inline bool tryBitxorAssign( const StrictlyUpperMatrix<MT,SO,DF>& lhs, const Vector<VT,TF>& rhs,
1380 ptrdiff_t band, size_t row, size_t column )
1381{
1382 return tryAssign( lhs, *rhs, band, row, column );
1383}
1385//*************************************************************************************************
1386
1387
1388//*************************************************************************************************
1405template< typename MT1 // Type of the adapted matrix
1406 , bool SO1 // Storage order of the adapted matrix
1407 , bool DF // Density flag
1408 , typename MT2 // Type of the right-hand side matrix
1409 , bool SO2 > // Storage order of the right-hand side matrix
1410inline bool tryBitxorAssign( const StrictlyUpperMatrix<MT1,SO1,DF>& lhs,
1411 const Matrix<MT2,SO2>& rhs, size_t row, size_t column )
1412{
1413 return tryAssign( lhs, *rhs, row, column );
1414}
1416//*************************************************************************************************
1417
1418
1419//*************************************************************************************************
1433template< typename MT // Type of the adapted matrix
1434 , bool SO // Storage order of the adapted matrix
1435 , bool DF > // Density flag
1436inline MT& derestrict( StrictlyUpperMatrix<MT,SO,DF>& m )
1437{
1438 return m.matrix_;
1439}
1441//*************************************************************************************************
1442
1443
1444
1445
1446//=================================================================================================
1447//
1448// SIZE SPECIALIZATIONS
1449//
1450//=================================================================================================
1451
1452//*************************************************************************************************
1454template< typename MT, bool SO, bool DF >
1455struct Size< StrictlyUpperMatrix<MT,SO,DF>, 0UL >
1456 : public Size<MT,0UL>
1457{};
1458
1459template< typename MT, bool SO, bool DF >
1460struct Size< StrictlyUpperMatrix<MT,SO,DF>, 1UL >
1461 : public Size<MT,1UL>
1462{};
1464//*************************************************************************************************
1465
1466
1467
1468
1469//=================================================================================================
1470//
1471// MAXSIZE SPECIALIZATIONS
1472//
1473//=================================================================================================
1474
1475//*************************************************************************************************
1477template< typename MT, bool SO, bool DF >
1478struct MaxSize< StrictlyUpperMatrix<MT,SO,DF>, 0UL >
1479 : public MaxSize<MT,0UL>
1480{};
1481
1482template< typename MT, bool SO, bool DF >
1483struct MaxSize< StrictlyUpperMatrix<MT,SO,DF>, 1UL >
1484 : public MaxSize<MT,1UL>
1485{};
1487//*************************************************************************************************
1488
1489
1490
1491
1492//=================================================================================================
1493//
1494// ISSQUARE SPECIALIZATIONS
1495//
1496//=================================================================================================
1497
1498//*************************************************************************************************
1500template< typename MT, bool SO, bool DF >
1501struct IsSquare< StrictlyUpperMatrix<MT,SO,DF> >
1502 : public TrueType
1503{};
1505//*************************************************************************************************
1506
1507
1508
1509
1510//=================================================================================================
1511//
1512// ISUNIFORM SPECIALIZATIONS
1513//
1514//=================================================================================================
1515
1516//*************************************************************************************************
1518template< typename MT, bool SO, bool DF >
1519struct IsUniform< StrictlyUpperMatrix<MT,SO,DF> >
1520 : public IsUniform<MT>
1521{};
1523//*************************************************************************************************
1524
1525
1526
1527
1528//=================================================================================================
1529//
1530// ISSYMMETRIC SPECIALIZATIONS
1531//
1532//=================================================================================================
1533
1534//*************************************************************************************************
1536template< typename MT, bool SO, bool DF >
1537struct IsSymmetric< StrictlyUpperMatrix<MT,SO,DF> >
1538 : public IsUniform<MT>
1539{};
1541//*************************************************************************************************
1542
1543
1544
1545
1546//=================================================================================================
1547//
1548// ISHERMITIAN SPECIALIZATIONS
1549//
1550//=================================================================================================
1551
1552//*************************************************************************************************
1554template< typename MT, bool SO, bool DF >
1555struct IsHermitian< StrictlyUpperMatrix<MT,SO,DF> >
1556 : public IsUniform<MT>
1557{};
1559//*************************************************************************************************
1560
1561
1562
1563
1564//=================================================================================================
1565//
1566// ISSTRICTLYLOWER SPECIALIZATIONS
1567//
1568//=================================================================================================
1569
1570//*************************************************************************************************
1572template< typename MT, bool SO, bool DF >
1573struct IsStrictlyLower< StrictlyUpperMatrix<MT,SO,DF> >
1574 : public IsUniform<MT>
1575{};
1577//*************************************************************************************************
1578
1579
1580
1581
1582//=================================================================================================
1583//
1584// ISSTRICTLYUPPER SPECIALIZATIONS
1585//
1586//=================================================================================================
1587
1588//*************************************************************************************************
1590template< typename MT, bool SO, bool DF >
1591struct IsStrictlyUpper< StrictlyUpperMatrix<MT,SO,DF> >
1592 : public TrueType
1593{};
1595//*************************************************************************************************
1596
1597
1598
1599
1600//=================================================================================================
1601//
1602// ISADAPTOR SPECIALIZATIONS
1603//
1604//=================================================================================================
1605
1606//*************************************************************************************************
1608template< typename MT, bool SO, bool DF >
1609struct IsAdaptor< StrictlyUpperMatrix<MT,SO,DF> >
1610 : public TrueType
1611{};
1613//*************************************************************************************************
1614
1615
1616
1617
1618//=================================================================================================
1619//
1620// ISRESTRICTED SPECIALIZATIONS
1621//
1622//=================================================================================================
1623
1624//*************************************************************************************************
1626template< typename MT, bool SO, bool DF >
1627struct IsRestricted< StrictlyUpperMatrix<MT,SO,DF> >
1628 : public TrueType
1629{};
1631//*************************************************************************************************
1632
1633
1634
1635
1636//=================================================================================================
1637//
1638// HASCONSTDATAACCESS SPECIALIZATIONS
1639//
1640//=================================================================================================
1641
1642//*************************************************************************************************
1644template< typename MT, bool SO >
1645struct HasConstDataAccess< StrictlyUpperMatrix<MT,SO,true> >
1646 : public TrueType
1647{};
1649//*************************************************************************************************
1650
1651
1652
1653
1654//=================================================================================================
1655//
1656// ISALIGNED SPECIALIZATIONS
1657//
1658//=================================================================================================
1659
1660//*************************************************************************************************
1662template< typename MT, bool SO, bool DF >
1663struct IsAligned< StrictlyUpperMatrix<MT,SO,DF> >
1664 : public IsAligned<MT>
1665{};
1667//*************************************************************************************************
1668
1669
1670
1671
1672//=================================================================================================
1673//
1674// ISCONTIGUOUS SPECIALIZATIONS
1675//
1676//=================================================================================================
1677
1678//*************************************************************************************************
1680template< typename MT, bool SO, bool DF >
1681struct IsContiguous< StrictlyUpperMatrix<MT,SO,DF> >
1682 : public IsContiguous<MT>
1683{};
1685//*************************************************************************************************
1686
1687
1688
1689
1690//=================================================================================================
1691//
1692// ISPADDED SPECIALIZATIONS
1693//
1694//=================================================================================================
1695
1696//*************************************************************************************************
1698template< typename MT, bool SO, bool DF >
1699struct IsPadded< StrictlyUpperMatrix<MT,SO,DF> >
1700 : public IsPadded<MT>
1701{};
1703//*************************************************************************************************
1704
1705
1706
1707
1708//=================================================================================================
1709//
1710// REMOVEADAPTOR SPECIALIZATIONS
1711//
1712//=================================================================================================
1713
1714//*************************************************************************************************
1716template< typename MT, bool SO, bool DF >
1717struct RemoveAdaptor< StrictlyUpperMatrix<MT,SO,DF> >
1718{
1719 using Type = MT;
1720};
1722//*************************************************************************************************
1723
1724
1725
1726
1727//=================================================================================================
1728//
1729// ADDTRAIT SPECIALIZATIONS
1730//
1731//=================================================================================================
1732
1733//*************************************************************************************************
1735template< typename T1, typename T2 >
1736struct AddTraitEval1< T1, T2
1737 , EnableIf_t< IsMatrix_v<T1> &&
1738 IsMatrix_v<T2> &&
1739 ( IsStrictlyUpper_v<T1> && IsStrictlyUpper_v<T2> ) &&
1740 !( IsZero_v<T1> || IsZero_v<T2> ) > >
1741{
1742 using Type = StrictlyUpperMatrix< typename AddTraitEval2<T1,T2>::Type >;
1743};
1745//*************************************************************************************************
1746
1747
1748
1749
1750//=================================================================================================
1751//
1752// SUBTRAIT SPECIALIZATIONS
1753//
1754//=================================================================================================
1755
1756//*************************************************************************************************
1758template< typename T1, typename T2 >
1759struct SubTraitEval1< T1, T2
1760 , EnableIf_t< IsMatrix_v<T1> &&
1761 IsMatrix_v<T2> &&
1762 ( ( IsUniUpper_v<T1> && IsUniUpper_v<T2> ) ||
1763 ( IsStrictlyUpper_v<T1> && IsStrictlyUpper_v<T2> ) ) &&
1764 !( IsIdentity_v<T1> && IsIdentity_v<T2> ) &&
1765 !( IsZero_v<T1> || IsZero_v<T2> ) > >
1766{
1767 using Type = StrictlyUpperMatrix< typename SubTraitEval2<T1,T2>::Type >;
1768};
1770//*************************************************************************************************
1771
1772
1773
1774
1775//=================================================================================================
1776//
1777// SCHURTRAIT SPECIALIZATIONS
1778//
1779//=================================================================================================
1780
1781//*************************************************************************************************
1783template< typename T1, typename T2 >
1784struct SchurTraitEval1< T1, T2
1785 , EnableIf_t< IsMatrix_v<T1> &&
1786 IsMatrix_v<T2> &&
1787 ( ( IsStrictlyUpper_v<T1> && !IsLower_v<T2> ) ||
1788 ( !IsLower_v<T1> && IsStrictlyUpper_v<T2> ) ) &&
1789 !( IsZero_v<T1> || IsZero_v<T2> ) > >
1790{
1791 using Type = StrictlyUpperMatrix< typename SchurTraitEval2<T1,T2>::Type >;
1792};
1794//*************************************************************************************************
1795
1796
1797
1798
1799//=================================================================================================
1800//
1801// MULTTRAIT SPECIALIZATIONS
1802//
1803//=================================================================================================
1804
1805//*************************************************************************************************
1807template< typename T1, typename T2 >
1808struct MultTraitEval1< T1, T2
1809 , EnableIf_t< IsMatrix_v<T1> &&
1810 IsScalar_v<T2> &&
1811 ( IsStrictlyUpper_v<T1> && !IsUniform_v<T1> ) > >
1812{
1813 using Type = StrictlyUpperMatrix< typename MultTraitEval2<T1,T2>::Type >;
1814};
1815
1816template< typename T1, typename T2 >
1817struct MultTraitEval1< T1, T2
1818 , EnableIf_t< IsScalar_v<T1> &&
1819 IsMatrix_v<T2> &&
1820 ( IsStrictlyUpper_v<T2> && !IsUniform_v<T2> ) > >
1821{
1822 using Type = StrictlyUpperMatrix< typename MultTraitEval2<T1,T2>::Type >;
1823};
1824
1825template< typename T1, typename T2 >
1826struct MultTraitEval1< T1, T2
1827 , EnableIf_t< IsMatrix_v<T1> &&
1828 IsMatrix_v<T2> &&
1829 ( ( IsStrictlyUpper_v<T1> && IsUpper_v<T2> ) ||
1830 ( IsUpper_v<T1> && IsStrictlyUpper_v<T2> ) ) &&
1831 !( IsIdentity_v<T1> || IsIdentity_v<T2> ) &&
1832 !( IsZero_v<T1> || IsZero_v<T2> ) > >
1833{
1834 using Type = StrictlyUpperMatrix< typename MultTraitEval2<T1,T2>::Type >;
1835};
1837//*************************************************************************************************
1838
1839
1840
1841
1842//=================================================================================================
1843//
1844// KRONTRAIT SPECIALIZATIONS
1845//
1846//=================================================================================================
1847
1848//*************************************************************************************************
1850template< typename T1, typename T2 >
1851struct KronTraitEval1< T1, T2
1852 , EnableIf_t< IsMatrix_v<T1> &&
1853 IsMatrix_v<T2> &&
1854 ( ( IsStrictlyUpper_v<T1> ) ||
1855 ( IsUpper_v<T1> && IsStrictlyUpper_v<T2> ) ) &&
1856 !( IsZero_v<T1> || IsZero_v<T2> ) > >
1857{
1858 using Type = StrictlyUpperMatrix< typename KronTraitEval2<T1,T2>::Type >;
1859};
1861//*************************************************************************************************
1862
1863
1864
1865
1866//=================================================================================================
1867//
1868// DIVTRAIT SPECIALIZATIONS
1869//
1870//=================================================================================================
1871
1872//*************************************************************************************************
1874template< typename T1, typename T2 >
1875struct DivTraitEval1< T1, T2
1876 , EnableIf_t< IsStrictlyUpper_v<T1> && IsScalar_v<T2> > >
1877{
1878 using Type = StrictlyUpperMatrix< typename DivTraitEval2<T1,T2>::Type >;
1879};
1881//*************************************************************************************************
1882
1883
1884
1885
1886//=================================================================================================
1887//
1888// MAPTRAIT SPECIALIZATIONS
1889//
1890//=================================================================================================
1891
1892//*************************************************************************************************
1894template< typename T, typename OP >
1895struct UnaryMapTraitEval1< T, OP
1897 !YieldsDiagonal_v<OP,T> > >
1898{
1899 using Type = StrictlyUpperMatrix< typename UnaryMapTraitEval2<T,OP>::Type, StorageOrder_v<T> >;
1900};
1902//*************************************************************************************************
1903
1904
1905//*************************************************************************************************
1907template< typename T1, typename T2, typename OP >
1908struct BinaryMapTraitEval1< T1, T2, OP
1909 , EnableIf_t< YieldsStrictlyUpper_v<OP,T1,T2> &&
1910 !YieldsDiagonal_v<OP,T1,T2> > >
1911{
1912 using Type = StrictlyUpperMatrix< typename BinaryMapTraitEval2<T1,T2,OP>::Type >;
1913};
1915//*************************************************************************************************
1916
1917
1918
1919
1920//=================================================================================================
1921//
1922// DECLSYMTRAIT SPECIALIZATIONS
1923//
1924//=================================================================================================
1925
1926//*************************************************************************************************
1928template< typename MT, bool SO, bool DF >
1929struct DeclSymTrait< StrictlyUpperMatrix<MT,SO,DF> >
1930{
1931 using Type = ZeroMatrix< typename MT::ElementType, SO >;
1932};
1934//*************************************************************************************************
1935
1936
1937
1938
1939//=================================================================================================
1940//
1941// DECLHERMTRAIT SPECIALIZATIONS
1942//
1943//=================================================================================================
1944
1945//*************************************************************************************************
1947template< typename MT, bool SO, bool DF >
1948struct DeclHermTrait< StrictlyUpperMatrix<MT,SO,DF> >
1949{
1950 using Type = ZeroMatrix< typename MT::ElementType, SO >;
1951};
1953//*************************************************************************************************
1954
1955
1956
1957
1958//=================================================================================================
1959//
1960// DECLLOWTRAIT SPECIALIZATIONS
1961//
1962//=================================================================================================
1963
1964//*************************************************************************************************
1966template< typename MT, bool SO, bool DF >
1967struct DeclLowTrait< StrictlyUpperMatrix<MT,SO,DF> >
1968{
1969 using Type = ZeroMatrix< typename MT::ElementType, SO >;
1970};
1972//*************************************************************************************************
1973
1974
1975
1976
1977//=================================================================================================
1978//
1979// DECLUNILOWTRAIT SPECIALIZATIONS
1980//
1981//=================================================================================================
1982
1983//*************************************************************************************************
1985template< typename MT, bool SO, bool DF >
1986struct DeclUniLowTrait< StrictlyUpperMatrix<MT,SO,DF> >
1987{
1988 using Type = INVALID_TYPE;
1989};
1991//*************************************************************************************************
1992
1993
1994
1995
1996//=================================================================================================
1997//
1998// DECLSTRLOWTRAIT SPECIALIZATIONS
1999//
2000//=================================================================================================
2001
2002//*************************************************************************************************
2004template< typename MT, bool SO, bool DF >
2005struct DeclStrLowTrait< StrictlyUpperMatrix<MT,SO,DF> >
2006{
2007 using Type = ZeroMatrix< typename MT::ElementType, SO >;
2008};
2010//*************************************************************************************************
2011
2012
2013
2014
2015//=================================================================================================
2016//
2017// DECLUPPTRAIT SPECIALIZATIONS
2018//
2019//=================================================================================================
2020
2021//*************************************************************************************************
2023template< typename MT, bool SO, bool DF >
2024struct DeclUppTrait< StrictlyUpperMatrix<MT,SO,DF> >
2025{
2026 using Type = StrictlyUpperMatrix<MT,SO,DF>;
2027};
2029//*************************************************************************************************
2030
2031
2032
2033
2034//=================================================================================================
2035//
2036// DECLUNIUPPTRAIT SPECIALIZATIONS
2037//
2038//=================================================================================================
2039
2040//*************************************************************************************************
2042template< typename MT, bool SO, bool DF >
2043struct DeclUniUppTrait< StrictlyUpperMatrix<MT,SO,DF> >
2044{
2045 using Type = INVALID_TYPE;
2046};
2048//*************************************************************************************************
2049
2050
2051
2052
2053//=================================================================================================
2054//
2055// DECLSTRUPPTRAIT SPECIALIZATIONS
2056//
2057//=================================================================================================
2058
2059//*************************************************************************************************
2061template< typename MT, bool SO, bool DF >
2062struct DeclStrUppTrait< StrictlyUpperMatrix<MT,SO,DF> >
2063{
2064 using Type = StrictlyUpperMatrix<MT,SO,DF>;
2065};
2067//*************************************************************************************************
2068
2069
2070
2071
2072//=================================================================================================
2073//
2074// DECLDIAGTRAIT SPECIALIZATIONS
2075//
2076//=================================================================================================
2077
2078//*************************************************************************************************
2080template< typename MT, bool SO, bool DF >
2081struct DeclDiagTrait< StrictlyUpperMatrix<MT,SO,DF> >
2082{
2083 using Type = ZeroMatrix< typename MT::ElementType, SO >;
2084};
2086//*************************************************************************************************
2087
2088
2089
2090
2091//=================================================================================================
2092//
2093// HIGHTYPE SPECIALIZATIONS
2094//
2095//=================================================================================================
2096
2097//*************************************************************************************************
2099template< typename MT1, bool SO1, bool DF1, typename MT2, bool SO2, bool DF2 >
2100struct HighType< StrictlyUpperMatrix<MT1,SO1,DF1>, StrictlyUpperMatrix<MT2,SO2,DF2> >
2101{
2102 using Type = StrictlyUpperMatrix< typename HighType<MT1,MT2>::Type >;
2103};
2105//*************************************************************************************************
2106
2107
2108
2109
2110//=================================================================================================
2111//
2112// LOWTYPE SPECIALIZATIONS
2113//
2114//=================================================================================================
2115
2116//*************************************************************************************************
2118template< typename MT1, bool SO1, bool DF1, typename MT2, bool SO2, bool DF2 >
2119struct LowType< StrictlyUpperMatrix<MT1,SO1,DF1>, StrictlyUpperMatrix<MT2,SO2,DF2> >
2120{
2121 using Type = StrictlyUpperMatrix< typename LowType<MT1,MT2>::Type >;
2122};
2124//*************************************************************************************************
2125
2126
2127
2128
2129//=================================================================================================
2130//
2131// SUBMATRIXTRAIT SPECIALIZATIONS
2132//
2133//=================================================================================================
2134
2135//*************************************************************************************************
2137template< typename MT, size_t I, size_t N >
2138struct SubmatrixTraitEval1< MT, I, I, N, N
2139 , EnableIf_t< I != inf && N != inf &&
2140 IsStrictlyUpper_v<MT> &&
2141 !IsZero_v<MT> > >
2142{
2143 using Type = StrictlyUpperMatrix< typename SubmatrixTraitEval2<MT,I,I,N,N>::Type >;
2144};
2146//*************************************************************************************************
2147
2148} // namespace blaze
2149
2150#endif
Header file for the addition trait.
Header file for run time assertion macros.
Header file for the decldiag trait.
Header file for the declherm trait.
Header file for the decllow trait.
Header file for the declstrlow trait.
Header file for the declstrupp trait.
Header file for the declsym trait.
Header file for the declunilow trait.
Header file for the decluniupp trait.
Header file for the declupp trait.
Header file for the division trait.
Header file for the EnableIf class template.
Header file for the HasConstDataAccess type trait.
Header file for the HighType type trait.
Header file for the IntegralConstant class template.
Utility type for generic codes.
Header file for the IsAdaptor type trait.
Header file for the IsAligned type trait.
Header file for the IsContiguous type trait.
Header file for the isDefault shim.
Header file for the IsHermitian type trait.
Header file for the IsIdentity type trait.
Header file for the IsLower type trait.
Header file for the IsMatrix type trait.
Header file for the IsPadded type trait.
Header file for the IsRestricted type trait.
Header file for the IsScalar type trait.
Header file for the IsSquare type trait.
Header file for the IsStrictlyLower type trait.
Header file for the IsStrictlyUpper type trait.
Header file for the IsSymmetric type trait.
Header file for the IsUniUpper type trait.
Header file for the IsUniform type trait.
Header file for the IsUpper type trait.
Header file for the Kron product trait.
Header file for the LowType type trait.
Header file for the map trait.
Header file for the MAYBE_UNUSED function template.
Header file for the multiplication trait.
Header file for the relaxation flag enumeration.
Header file for the RemoveAdaptor type trait.
Header file for the Schur product trait.
Header file for the subtraction trait.
Header file for the submatrix trait.
Header file for the YieldsDiagonal type trait.
Header file for the YieldsStrictlyUpper type trait.
Header file for the implementation of the base template of the StrictlyUpperMatrix.
StrictlyUpperMatrix specialization for dense matrices.
StrictlyUpperMatrix specialization for sparse matrices.
Pointer difference type of the Blaze library.
Constraint on the data type.
decltype(auto) band(Matrix< MT, SO > &matrix, RBAs... args)
Creating a view on a specific band of the given matrix.
Definition: Band.h:140
decltype(auto) column(Matrix< MT, SO > &matrix, RCAs... args)
Creating a view on a specific column of the given matrix.
Definition: Column.h:137
decltype(auto) min(const DenseMatrix< MT1, SO1 > &lhs, const DenseMatrix< MT2, SO2 > &rhs)
Computes the componentwise minimum of the dense matrices lhs and rhs.
Definition: DMatDMatMapExpr.h:1339
bool isIntact(const DiagonalMatrix< MT, SO, DF > &m)
Returns whether the invariants of the given diagonal matrix are intact.
Definition: DiagonalMatrix.h:207
void swap(DiagonalMatrix< MT, SO, DF > &a, DiagonalMatrix< MT, SO, DF > &b) noexcept
Swapping the contents of two matrices.
Definition: DiagonalMatrix.h:225
bool isDefault(const DiagonalMatrix< MT, SO, DF > &m)
Returns whether the given diagonal matrix is in default state.
Definition: DiagonalMatrix.h:169
#define BLAZE_CONSTRAINT_MUST_NOT_REQUIRE_EVALUATION(T)
Constraint on the data type.
Definition: RequiresEvaluation.h:81
constexpr bool IsStrictlyUpper_v
Auxiliary variable template for the IsStrictlyUpper type trait.
Definition: IsStrictlyUpper.h:173
constexpr bool IsScalar_v
Auxiliary variable template for the IsScalar type trait.
Definition: IsScalar.h:104
constexpr ptrdiff_t DefaultSize_v
Default size of the Size type trait.
Definition: Size.h:72
constexpr bool IsMatrix_v
Auxiliary variable template for the IsMatrix type trait.
Definition: IsMatrix.h:124
constexpr bool YieldsStrictlyUpper_v
Auxiliary variable template for the YieldsStrictlyUpper type trait.
Definition: YieldsStrictlyUpper.h:124
RelaxationFlag
Relaxation flag for strict or relaxed semantics.
Definition: RelaxationFlag.h:66
constexpr Infinity inf
Global Infinity instance.
Definition: Infinity.h:1080
decltype(auto) row(Matrix< MT, SO > &, RRAs...)
Creating a view on a specific row of the given matrix.
Definition: Row.h:137
#define BLAZE_INTERNAL_ASSERT(expr, msg)
Run time assertion macro for internal checks.
Definition: Assert.h:101
#define BLAZE_ALWAYS_INLINE
Platform dependent setup of an enforced inline keyword.
Definition: Inline.h:85
BoolConstant< true > TrueType
Type traits base class.
Definition: IntegralConstant.h:132
typename EnableIf< Condition, T >::Type EnableIf_t
Auxiliary type for the EnableIf class template.
Definition: EnableIf.h:138
constexpr void MAYBE_UNUSED(const Args &...)
Suppression of unused parameter warnings.
Definition: MaybeUnused.h:81
Header file for all forward declarations of the math module.
Header file for the Size type trait.
Header file for the StorageOrder type trait.
Header file for the IsZero type trait.
Header file for the generic min algorithm.