Row.h
Go to the documentation of this file.
1 //=================================================================================================
33 //=================================================================================================
34 
35 #ifndef _BLAZE_MATH_VIEWS_ROW_H_
36 #define _BLAZE_MATH_VIEWS_ROW_H_
37 
38 
39 //*************************************************************************************************
40 // Includes
41 //*************************************************************************************************
42 
76 #include <blaze/util/mpl/And.h>
77 #include <blaze/util/mpl/Or.h>
78 #include <blaze/util/TrueType.h>
79 #include <blaze/util/Types.h>
80 
81 
82 namespace blaze {
83 
84 //=================================================================================================
85 //
86 // GLOBAL FUNCTIONS
87 //
88 //=================================================================================================
89 
90 //*************************************************************************************************
122 template< typename MT // Type of the matrix
123  , bool SO > // Storage order
124 inline Row<MT> row( Matrix<MT,SO>& matrix, size_t index )
125 {
127 
128  return Row<MT>( ~matrix, index );
129 }
130 //*************************************************************************************************
131 
132 
133 //*************************************************************************************************
165 template< typename MT // Type of the matrix
166  , bool SO > // Storage order
167 inline const Row<const MT> row( const Matrix<MT,SO>& matrix, size_t index )
168 {
170 
171  return Row<const MT>( ~matrix, index );
172 }
173 //*************************************************************************************************
174 
175 
176 //*************************************************************************************************
190 template< typename MT // Type of the matrix
191  , bool SO > // Storage order
192 inline Row<MT> row( Matrix<MT,SO>&& matrix, size_t index )
193 {
195 
196  return Row<MT>( ~matrix, index );
197 }
198 //*************************************************************************************************
199 
200 
201 
202 
203 //=================================================================================================
204 //
205 // GLOBAL RESTRUCTURING FUNCTIONS
206 //
207 //=================================================================================================
208 
209 //*************************************************************************************************
221 template< typename MT > // Matrix base type of the expression
222 inline decltype(auto) row( const MatMatAddExpr<MT>& matrix, size_t index )
223 {
225 
226  return row( (~matrix).leftOperand(), index ) + row( (~matrix).rightOperand(), index );
227 }
229 //*************************************************************************************************
230 
231 
232 //*************************************************************************************************
244 template< typename MT > // Matrix base type of the expression
245 inline decltype(auto) row( const MatMatSubExpr<MT>& matrix, size_t index )
246 {
248 
249  return row( (~matrix).leftOperand(), index ) - row( (~matrix).rightOperand(), index );
250 }
252 //*************************************************************************************************
253 
254 
255 //*************************************************************************************************
266 template< typename MT > // Matrix base type of the expression
267 inline decltype(auto) row( const SchurExpr<MT>& matrix, size_t index )
268 {
270 
271  return row( (~matrix).leftOperand(), index ) * row( (~matrix).rightOperand(), index );
272 }
274 //*************************************************************************************************
275 
276 
277 //*************************************************************************************************
289 template< typename MT > // Matrix base type of the expression
290 inline decltype(auto) row( const MatMatMultExpr<MT>& matrix, size_t index )
291 {
293 
294  return row( (~matrix).leftOperand(), index ) * (~matrix).rightOperand();
295 }
297 //*************************************************************************************************
298 
299 
300 //*************************************************************************************************
311 template< typename MT > // Matrix base type of the expression
312 inline decltype(auto) row( const VecTVecMultExpr<MT>& matrix, size_t index )
313 {
315 
316  return (~matrix).leftOperand()[index] * (~matrix).rightOperand();
317 }
319 //*************************************************************************************************
320 
321 
322 //*************************************************************************************************
334 template< typename MT > // Matrix base type of the expression
335 inline decltype(auto) row( const MatScalarMultExpr<MT>& matrix, size_t index )
336 {
338 
339  return row( (~matrix).leftOperand(), index ) * (~matrix).rightOperand();
340 }
342 //*************************************************************************************************
343 
344 
345 //*************************************************************************************************
357 template< typename MT > // Matrix base type of the expression
358 inline decltype(auto) row( const MatScalarDivExpr<MT>& matrix, size_t index )
359 {
361 
362  return row( (~matrix).leftOperand(), index ) / (~matrix).rightOperand();
363 }
365 //*************************************************************************************************
366 
367 
368 //*************************************************************************************************
380 template< typename MT > // Matrix base type of the expression
381 inline decltype(auto) row( const MatMapExpr<MT>& matrix, size_t index )
382 {
384 
385  return map( row( (~matrix).operand(), index ), (~matrix).operation() );
386 }
388 //*************************************************************************************************
389 
390 
391 //*************************************************************************************************
403 template< typename MT > // Matrix base type of the expression
404 inline decltype(auto) row( const MatMatMapExpr<MT>& matrix, size_t index )
405 {
407 
408  return map( row( (~matrix).leftOperand() , index ),
409  row( (~matrix).rightOperand(), index ),
410  (~matrix).operation() );
411 }
413 //*************************************************************************************************
414 
415 
416 //*************************************************************************************************
428 template< typename MT > // Matrix base type of the expression
429 inline decltype(auto) row( const MatEvalExpr<MT>& matrix, size_t index )
430 {
432 
433  return eval( row( (~matrix).operand(), index ) );
434 }
436 //*************************************************************************************************
437 
438 
439 //*************************************************************************************************
451 template< typename MT > // Matrix base type of the expression
452 inline decltype(auto) row( const MatSerialExpr<MT>& matrix, size_t index )
453 {
455 
456  return serial( row( (~matrix).operand(), index ) );
457 }
459 //*************************************************************************************************
460 
461 
462 //*************************************************************************************************
474 template< typename MT > // Matrix base type of the expression
475 inline decltype(auto) row( const DeclExpr<MT>& matrix, size_t index )
476 {
478 
479  return row( (~matrix).operand(), index );
480 }
482 //*************************************************************************************************
483 
484 
485 //*************************************************************************************************
497 template< typename MT > // Matrix base type of the expression
498 inline decltype(auto) row( const MatTransExpr<MT>& matrix, size_t index )
499 {
501 
502  return trans( column( (~matrix).operand(), index ) );
503 }
505 //*************************************************************************************************
506 
507 
508 
509 
510 //=================================================================================================
511 //
512 // ROW OPERATORS
513 //
514 //=================================================================================================
515 
516 //*************************************************************************************************
519 template< typename MT, bool SO, bool DF, bool SF >
520 inline void reset( Row<MT,SO,DF,SF>& row );
521 
522 template< typename MT, bool SO, bool DF, bool SF >
523 inline void reset( Row<MT,SO,DF,SF>&& row );
524 
525 template< typename MT, bool SO, bool DF, bool SF >
526 inline void clear( Row<MT,SO,DF,SF>& row );
527 
528 template< typename MT, bool SO, bool DF, bool SF >
529 inline void clear( Row<MT,SO,DF,SF>&& row );
530 
531 template< bool RF, typename MT, bool SO, bool DF, bool SF >
532 inline bool isDefault( const Row<MT,SO,DF,SF>& row );
533 
534 template< typename MT, bool SO, bool DF, bool SF >
535 inline bool isIntact( const Row<MT,SO,DF,SF>& row ) noexcept;
536 
537 template< typename MT, bool SO, bool DF, bool SF >
538 inline bool isSame( const Row<MT,SO,DF,SF>& a, const Row<MT,SO,DF,SF>& b ) noexcept;
540 //*************************************************************************************************
541 
542 
543 //*************************************************************************************************
550 template< typename MT // Type of the matrix
551  , bool SO // Storage order
552  , bool DF // Density flag
553  , bool SF > // Symmetry flag
554 inline void reset( Row<MT,SO,DF,SF>& row )
555 {
556  row.reset();
557 }
558 //*************************************************************************************************
559 
560 
561 //*************************************************************************************************
568 template< typename MT // Type of the matrix
569  , bool SO // Storage order
570  , bool DF // Density flag
571  , bool SF > // Symmetry flag
572 inline void reset( Row<MT,SO,DF,SF>&& row )
573 {
574  row.reset();
575 }
576 //*************************************************************************************************
577 
578 
579 //*************************************************************************************************
588 template< typename MT // Type of the matrix
589  , bool SO // Storage order
590  , bool DF // Density flag
591  , bool SF > // Symmetry flag
592 inline void clear( Row<MT,SO,DF,SF>& row )
593 {
594  row.reset();
595 }
596 //*************************************************************************************************
597 
598 
599 //*************************************************************************************************
608 template< typename MT // Type of the matrix
609  , bool SO // Storage order
610  , bool DF // Density flag
611  , bool SF > // Symmetry flag
612 inline void clear( Row<MT,SO,DF,SF>&& row )
613 {
614  row.reset();
615 }
616 //*************************************************************************************************
617 
618 
619 //*************************************************************************************************
644 template< bool RF // Relaxation flag
645  , typename MT // Type of the matrix
646  , bool SO // Storage order
647  , bool DF // Density flag
648  , bool SF > // Symmetry flag
649 inline bool isDefault( const Row<MT,SO,DF,SF>& row )
650 {
651  using blaze::isDefault;
652 
653  for( size_t i=0UL; i<row.size(); ++i )
654  if( !isDefault<RF>( row[i] ) ) return false;
655  return true;
656 }
657 //*************************************************************************************************
658 
659 
660 //*************************************************************************************************
679 template< bool RF // Relaxation flag
680  , typename MT // Type of the sparse matrix
681  , bool SO // Storage order
682  , bool SF > // Symmetry flag
683 inline bool isDefault( const Row<MT,SO,false,SF>& row )
684 {
685  using blaze::isDefault;
686 
688 
689  const ConstIterator end( row.end() );
690  for( ConstIterator element=row.begin(); element!=end; ++element )
691  if( !isDefault<RF>( element->value() ) ) return false;
692  return true;
693 }
695 //*************************************************************************************************
696 
697 
698 //*************************************************************************************************
715 template< typename MT // Type of the matrix
716  , bool SO // Storage order
717  , bool DF // Density flag
718  , bool SF > // Symmetry flag
719 inline bool isIntact( const Row<MT,SO,DF,SF>& row ) noexcept
720 {
721  return ( row.row() < row.operand().rows() &&
722  isIntact( row.operand() ) );
723 }
724 //*************************************************************************************************
725 
726 
727 //*************************************************************************************************
739 template< typename MT // Type of the matrix
740  , bool SO // Storage order
741  , bool DF // Density flag
742  , bool SF > // Symmetry flag
743 inline bool isSame( const Row<MT,SO,DF,SF>& a, const Row<MT,SO,DF,SF>& b ) noexcept
744 {
745  return ( isSame( a.operand(), b.operand() ) && ( a.row() == b.row() ) );
746 }
747 //*************************************************************************************************
748 
749 
750 //*************************************************************************************************
765 template< typename MT // Type of the matrix
766  , bool SO // Storage order
767  , bool DF // Density flag
768  , bool SF // Symmetry flag
769  , typename VT > // Type of the right-hand side vector
770 inline bool tryAssign( const Row<MT,SO,DF,SF>& lhs, const Vector<VT,true>& rhs, size_t index )
771 {
772  BLAZE_INTERNAL_ASSERT( index <= lhs.size(), "Invalid vector access index" );
773  BLAZE_INTERNAL_ASSERT( (~rhs).size() <= lhs.size() - index, "Invalid vector size" );
774 
775  return tryAssign( lhs.operand(), ~rhs, lhs.row(), index );
776 }
778 //*************************************************************************************************
779 
780 
781 //*************************************************************************************************
796 template< typename MT // Type of the matrix
797  , bool SO // Storage order
798  , bool DF // Density flag
799  , bool SF // Symmetry flag
800  , typename VT > // Type of the right-hand side vector
801 inline bool tryAddAssign( const Row<MT,SO,DF,SF>& lhs, const Vector<VT,true>& rhs, size_t index )
802 {
803  BLAZE_INTERNAL_ASSERT( index <= lhs.size(), "Invalid vector access index" );
804  BLAZE_INTERNAL_ASSERT( (~rhs).size() <= lhs.size() - index, "Invalid vector size" );
805 
806  return tryAddAssign( lhs.operand(), ~rhs, lhs.row(), index );
807 }
809 //*************************************************************************************************
810 
811 
812 //*************************************************************************************************
827 template< typename MT // Type of the matrix
828  , bool SO // Storage order
829  , bool DF // Density flag
830  , bool SF // Symmetry flag
831  , typename VT > // Type of the right-hand side vector
832 inline bool trySubAssign( const Row<MT,SO,DF,SF>& lhs, const Vector<VT,true>& rhs, size_t index )
833 {
834  BLAZE_INTERNAL_ASSERT( index <= lhs.size(), "Invalid vector access index" );
835  BLAZE_INTERNAL_ASSERT( (~rhs).size() <= lhs.size() - index, "Invalid vector size" );
836 
837  return trySubAssign( lhs.operand(), ~rhs, lhs.row(), index );
838 }
840 //*************************************************************************************************
841 
842 
843 //*************************************************************************************************
858 template< typename MT // Type of the matrix
859  , bool SO // Storage order
860  , bool DF // Density flag
861  , bool SF // Symmetry flag
862  , typename VT > // Type of the right-hand side vector
863 inline bool tryMultAssign( const Row<MT,SO,DF,SF>& lhs, const Vector<VT,true>& rhs, size_t index )
864 {
865  BLAZE_INTERNAL_ASSERT( index <= lhs.size(), "Invalid vector access index" );
866  BLAZE_INTERNAL_ASSERT( (~rhs).size() <= lhs.size() - index, "Invalid vector size" );
867 
868  return tryMultAssign( lhs.operand(), ~rhs, lhs.row(), index );
869 }
871 //*************************************************************************************************
872 
873 
874 //*************************************************************************************************
889 template< typename MT // Type of the matrix
890  , bool SO // Storage order
891  , bool DF // Density flag
892  , bool SF // Symmetry flag
893  , typename VT > // Type of the right-hand side vector
894 inline bool tryDivAssign( const Row<MT,SO,DF,SF>& lhs, const Vector<VT,true>& rhs, size_t index )
895 {
896  BLAZE_INTERNAL_ASSERT( index <= lhs.size(), "Invalid vector access index" );
897  BLAZE_INTERNAL_ASSERT( (~rhs).size() <= lhs.size() - index, "Invalid vector size" );
898 
899  return tryDivAssign( lhs.operand(), ~rhs, lhs.row(), index );
900 }
902 //*************************************************************************************************
903 
904 
905 //*************************************************************************************************
920 template< typename MT // Type of the matrix
921  , bool SO // Storage order
922  , bool DF // Density flag
923  , bool SF > // Symmetry flag
924 inline decltype(auto) derestrict( Row<MT,SO,DF,SF>& r )
925 {
926  return row( derestrict( r.operand() ), r.row() );
927 }
929 //*************************************************************************************************
930 
931 
932 //*************************************************************************************************
947 template< typename MT // Type of the matrix
948  , bool SO // Storage order
949  , bool DF // Density flag
950  , bool SF > // Symmetry flag
951 inline decltype(auto) derestrict( Row<MT,SO,DF,SF>&& r )
952 {
953  return row( derestrict( r.operand() ), r.row() );
954 }
956 //*************************************************************************************************
957 
958 
959 
960 
961 //=================================================================================================
962 //
963 // ISRESTRICTED SPECIALIZATIONS
964 //
965 //=================================================================================================
966 
967 //*************************************************************************************************
969 template< typename MT, bool SO, bool DF, bool SF >
970 struct IsRestricted< Row<MT,SO,DF,SF> >
971  : public BoolConstant< IsRestricted<MT>::value >
972 {};
974 //*************************************************************************************************
975 
976 
977 
978 
979 //=================================================================================================
980 //
981 // HASCONSTDATAACCESS SPECIALIZATIONS
982 //
983 //=================================================================================================
984 
985 //*************************************************************************************************
987 template< typename MT, bool SO, bool SF >
988 struct HasConstDataAccess< Row<MT,SO,true,SF> >
989  : public BoolConstant< HasConstDataAccess<MT>::value >
990 {};
992 //*************************************************************************************************
993 
994 
995 
996 
997 //=================================================================================================
998 //
999 // HASMUTABLEDATAACCESS SPECIALIZATIONS
1000 //
1001 //=================================================================================================
1002 
1003 //*************************************************************************************************
1005 template< typename MT, bool SO, bool SF >
1006 struct HasMutableDataAccess< Row<MT,SO,true,SF> >
1007  : public BoolConstant< HasMutableDataAccess<MT>::value >
1008 {};
1010 //*************************************************************************************************
1011 
1012 
1013 
1014 
1015 //=================================================================================================
1016 //
1017 // ISALIGNED SPECIALIZATIONS
1018 //
1019 //=================================================================================================
1020 
1021 //*************************************************************************************************
1023 template< typename MT, bool SO, bool SF >
1024 struct IsAligned< Row<MT,SO,true,SF> >
1025  : public BoolConstant< And< IsAligned<MT>, Or< IsRowMajorMatrix<MT>, IsSymmetric<MT> > >::value >
1026 {};
1028 //*************************************************************************************************
1029 
1030 
1031 
1032 
1033 //=================================================================================================
1034 //
1035 // ISPADDED SPECIALIZATIONS
1036 //
1037 //=================================================================================================
1038 
1039 //*************************************************************************************************
1041 template< typename MT, bool SO, bool SF >
1042 struct IsPadded< Row<MT,SO,true,SF> >
1043  : public BoolConstant< And< IsPadded<MT>, Or< IsRowMajorMatrix<MT>, IsSymmetric<MT> > >::value >
1044 {};
1046 //*************************************************************************************************
1047 
1048 
1049 
1050 
1051 //=================================================================================================
1052 //
1053 // ISOPPOSEDVIEW SPECIALIZATIONS
1054 //
1055 //=================================================================================================
1056 
1057 //*************************************************************************************************
1059 template< typename MT, bool DF >
1060 struct IsOpposedView< Row<MT,false,DF,false> >
1061  : public TrueType
1062 {};
1064 //*************************************************************************************************
1065 
1066 
1067 
1068 
1069 //=================================================================================================
1070 //
1071 // ADDTRAIT SPECIALIZATIONS
1072 //
1073 //=================================================================================================
1074 
1075 //*************************************************************************************************
1077 template< typename MT, bool SO, bool DF, bool SF, typename T >
1078 struct AddTrait< Row<MT,SO,DF,SF>, T >
1079 {
1080  using Type = AddTrait_< RowTrait_<MT>, T >;
1081 };
1082 
1083 template< typename T, typename MT, bool SO, bool DF, bool SF >
1084 struct AddTrait< T, Row<MT,SO,DF,SF> >
1085 {
1086  using Type = AddTrait_< T, RowTrait_<MT> >;
1087 };
1089 //*************************************************************************************************
1090 
1091 
1092 
1093 
1094 //=================================================================================================
1095 //
1096 // SUBTRAIT SPECIALIZATIONS
1097 //
1098 //=================================================================================================
1099 
1100 //*************************************************************************************************
1102 template< typename MT, bool SO, bool DF, bool SF, typename T >
1103 struct SubTrait< Row<MT,SO,DF,SF>, T >
1104 {
1105  using Type = SubTrait_< RowTrait_<MT>, T >;
1106 };
1107 
1108 template< typename T, typename MT, bool SO, bool DF, bool SF >
1109 struct SubTrait< T, Row<MT,SO,DF,SF> >
1110 {
1111  using Type = SubTrait_< T, RowTrait_<MT> >;
1112 };
1114 //*************************************************************************************************
1115 
1116 
1117 
1118 
1119 //=================================================================================================
1120 //
1121 // MULTTRAIT SPECIALIZATIONS
1122 //
1123 //=================================================================================================
1124 
1125 //*************************************************************************************************
1127 template< typename MT, bool SO, bool DF, bool SF, typename T >
1128 struct MultTrait< Row<MT,SO,DF,SF>, T >
1129 {
1130  using Type = MultTrait_< RowTrait_<MT>, T >;
1131 };
1132 
1133 template< typename T, typename MT, bool SO, bool DF, bool SF >
1134 struct MultTrait< T, Row<MT,SO,DF,SF> >
1135 {
1136  using Type = MultTrait_< T, RowTrait_<MT> >;
1137 };
1139 //*************************************************************************************************
1140 
1141 
1142 
1143 
1144 //=================================================================================================
1145 //
1146 // DIVTRAIT SPECIALIZATIONS
1147 //
1148 //=================================================================================================
1149 
1150 //*************************************************************************************************
1152 template< typename MT, bool SO, bool DF, bool SF, typename T >
1153 struct DivTrait< Row<MT,SO,DF,SF>, T >
1154 {
1155  using Type = DivTrait_< RowTrait_<MT>, T >;
1156 };
1157 
1158 template< typename T, typename MT, bool SO, bool DF, bool SF >
1159 struct DivTrait< T, Row<MT,SO,DF,SF> >
1160 {
1161  using Type = DivTrait_< T, RowTrait_<MT> >;
1162 };
1164 //*************************************************************************************************
1165 
1166 
1167 
1168 
1169 //=================================================================================================
1170 //
1171 // CROSSTRAIT SPECIALIZATIONS
1172 //
1173 //=================================================================================================
1174 
1175 //*************************************************************************************************
1177 template< typename MT, bool SO, bool DF, bool SF, typename T >
1178 struct CrossTrait< Row<MT,SO,DF,SF>, T >
1179 {
1180  using Type = CrossTrait_< RowTrait_<MT>, T >;
1181 };
1182 
1183 template< typename T, typename MT, bool SO, bool DF, bool SF >
1184 struct CrossTrait< T, Row<MT,SO,DF,SF> >
1185 {
1186  using Type = CrossTrait_< T, RowTrait_<MT> >;
1187 };
1189 //*************************************************************************************************
1190 
1191 
1192 
1193 
1194 //=================================================================================================
1195 //
1196 // SUBVECTORTRAIT SPECIALIZATIONS
1197 //
1198 //=================================================================================================
1199 
1200 //*************************************************************************************************
1202 template< typename MT, bool SO, bool DF, bool SF >
1203 struct SubvectorTrait< Row<MT,SO,DF,SF> >
1204 {
1206 };
1208 //*************************************************************************************************
1209 
1210 } // namespace blaze
1211 
1212 #endif
Base class for all binary matrix map expression templates.The MatMatMapExpr class serves as a tag for...
Definition: MatMatMapExpr.h:66
Compile time check for low-level access to constant data.This type trait tests whether the given data...
Definition: HasConstDataAccess.h:75
Header file for the subtraction trait.
BLAZE_ALWAYS_INLINE bool isSame(const Matrix< MT1, SO1 > &a, const Matrix< MT2, SO2 > &b) noexcept
Returns whether the two given matrices represent the same observable state.
Definition: Matrix.h:786
Header file for basic type definitions.
Base class for all matrix serial evaluation expression templates.The MatSerialExpr class serves as a ...
Definition: MatSerialExpr.h:67
Header file for the row trait.
Base class for all matrix/scalar division expression templates.The MatScalarDivExpr class serves as a...
Definition: MatScalarDivExpr.h:66
BLAZE_ALWAYS_INLINE size_t size(const Vector< VT, TF > &vector) noexcept
Returns the current size/dimension of the vector.
Definition: Vector.h:265
Generic wrapper for a compile time constant integral value.The IntegralConstant class template repres...
Definition: IntegralConstant.h:71
Header file for the MatTransExpr base class.
Compile time check for resizable data types.This type trait tests whether the given data type is an o...
Definition: IsOpposedView.h:81
void reset(const DiagonalProxy< MT > &proxy)
Resetting the represented element to the default initial values.
Definition: DiagonalProxy.h:560
Row specialization for dense matrices.
Base class for all matrix/scalar multiplication expression templates.The MatScalarMultExpr class serv...
Definition: MatScalarMultExpr.h:67
Header file for the And class template.
Header file for the MatEvalExpr base class.
typename MultTrait< T1, T2 >::Type MultTrait_
Auxiliary alias declaration for the MultTrait class template.The MultTrait_ alias declaration provide...
Definition: MultTrait.h:250
Column< MT > column(Matrix< MT, SO > &matrix, size_t index)
Creating a view on a specific column of the given matrix.
Definition: Column.h:124
Header file for the MatMatMultExpr base class.
Row specialization for sparse matrices.
Base template for the CrossTrait class.
Definition: CrossTrait.h:116
Compile time check for data types with restricted data access.This type trait tests whether the given...
Definition: IsRestricted.h:82
Base template for the SubvectorTrait class.
Definition: SubvectorTrait.h:120
Compile time check for low-level access to mutable data.This type trait tests whether the given data ...
Definition: HasMutableDataAccess.h:75
Row< MT > row(Matrix< MT, SO > &matrix, size_t index)
Creating a view on a specific row of the given matrix.
Definition: Row.h:124
Compile time check for the alignment of data types.This type trait tests whether the given data type ...
Definition: IsAligned.h:87
Header file for the MatMapExpr base class.
Header file for the implementation of the Row base template.
Header file for the multiplication trait.
Header file for the IsSymmetric type trait.
Base class for all matrix/matrix subtraction expression templates.The MatMatSubExpr class serves as a...
Definition: MatMatSubExpr.h:67
Namespace of the Blaze C++ math library.
Definition: Blaze.h:57
Compile time check for data types with padding.This type trait tests whether the given data type empl...
Definition: IsPadded.h:76
Header file for the Or class template.
typename SubvectorTrait< VT >::Type SubvectorTrait_
Auxiliary alias declaration for the SubvectorTrait type trait.The SubvectorTrait_ alias declaration p...
Definition: SubvectorTrait.h:155
const Element * ConstIterator
Iterator over constant elements.
Definition: CompressedMatrix.h:3087
Header file for the subvector trait.
Base class for all matrix/matrix addition expression templates.The MatMatAddExpr class serves as a ta...
Definition: MatMatAddExpr.h:66
Header file for the MatMatSubExpr base class.
Header file for the IsAligned type trait.
Base class for all unary matrix map expression templates.The MatMapExpr class serves as a tag for all...
Definition: MatMapExpr.h:66
Header file for the IsOpposedView type trait.
decltype(auto) eval(const DenseMatrix< MT, SO > &dm)
Forces the evaluation of the given dense matrix expression dm.
Definition: DMatEvalExpr.h:797
typename CrossTrait< T1, T2 >::Type CrossTrait_
Auxiliary alias declaration for the CrossTrait class template.The CrossTrait_ alias declaration provi...
Definition: CrossTrait.h:159
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 MatSerialExpr base class.
Header file for the VecTVecMultExpr base class.
void clear(const DiagonalProxy< MT > &proxy)
Clearing the represented element.
Definition: DiagonalProxy.h:580
typename DivTrait< T1, T2 >::Type DivTrait_
Auxiliary alias declaration for the DivTrait class template.The DivTrait_ alias declaration provides ...
Definition: DivTrait.h:250
Reference to a specific row of a dense or sparse matrix.The Row template represents a reference to a ...
Definition: BaseTemplate.h:355
Header file for the HasConstDataAccess type trait.
Header file for the DeclExpr base class.
Base class for all matrix/matrix multiplication expression templates.The MatMatMultExpr class serves ...
Definition: MatMatMultExpr.h:67
Header file for the Matrix base class.
Header file for the MatScalarMultExpr base class.
Base class for all Schur product expression templates.The SchurExpr class serves as a tag for all exp...
Definition: SchurExpr.h:66
Base template for the AddTrait class.
Definition: AddTrait.h:139
Base template for the MultTrait class.
Definition: MultTrait.h:139
Header file for the addition trait.
Header file for the cross product trait.
Header file for the division trait.
Header file for the SchurExpr base class.
Base class for all matrix evaluation expression templates.The MatEvalExpr class serves as a tag for a...
Definition: MatEvalExpr.h:66
#define BLAZE_FUNCTION_TRACE
Function trace macro.This macro can be used to reliably trace function calls. In case function tracin...
Definition: FunctionTrace.h:94
Header file for the isDefault shim.
Base class for matrices.The Matrix class is a base class for all dense and sparse matrix classes with...
Definition: Forward.h:101
decltype(auto) serial(const DenseMatrix< MT, SO > &dm)
Forces the serial evaluation of the given dense matrix expression dm.
Definition: DMatSerialExpr.h:819
Base class for all matrix transposition expression templates.The MatTransExpr class serves as a tag f...
Definition: MatTransExpr.h:66
Header file for the HasMutableDataAccess type trait.
Header file for the MatMatAddExpr base class.
Base class for all outer product expression templates.The VecTVecMultExpr class serves as a tag for a...
Definition: VecTVecMultExpr.h:67
Base template for the DivTrait class.
Definition: DivTrait.h:139
typename T::ConstIterator ConstIterator_
Alias declaration for nested ConstIterator type definitions.The ConstIterator_ alias declaration prov...
Definition: Aliases.h:103
decltype(auto) trans(const DenseMatrix< MT, SO > &dm)
Calculation of the transpose of the given dense matrix.
Definition: DMatTransExpr.h:790
Header file for the IsRowMajorMatrix type trait.
Base class for N-dimensional vectors.The Vector class is a base class for all arbitrarily sized (N-di...
Definition: Forward.h:177
Header file for the MatMatMapExpr base class.
typename SubTrait< T1, T2 >::Type SubTrait_
Auxiliary alias declaration for the SubTrait class template.The SubTrait_ alias declaration provides ...
Definition: SubTrait.h:250
Header file for the IntegralConstant class template.
bool isIntact(const DiagonalMatrix< MT, SO, DF > &m)
Returns whether the invariants of the given diagonal matrix are intact.
Definition: DiagonalMatrix.h:252
bool isDefault(const DiagonalProxy< MT > &proxy)
Returns whether the represented element is in default state.
Definition: DiagonalProxy.h:600
Base template for the SubTrait class.
Definition: SubTrait.h:139
Header file for the MatScalarDivExpr base class.
typename AddTrait< T1, T2 >::Type AddTrait_
Auxiliary alias declaration for the AddTrait class template.The AddTrait_ alias declaration provides ...
Definition: AddTrait.h:250
#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.
Header file for the function trace functionality.
decltype(auto) map(const DenseMatrix< MT1, SO > &lhs, const DenseMatrix< MT2, SO > &rhs, OP op)
Evaluates the given binary operation on each single element of the dense matrices lhs and rhs...
Definition: DMatDMatMapExpr.h:1133