Blaze  3.6
HermitianMatrix.h
Go to the documentation of this file.
1 //=================================================================================================
33 //=================================================================================================
34 
35 #ifndef _BLAZE_MATH_ADAPTORS_HERMITIANMATRIX_H_
36 #define _BLAZE_MATH_ADAPTORS_HERMITIANMATRIX_H_
37 
38 
39 //*************************************************************************************************
40 // Includes
41 //*************************************************************************************************
42 
43 #include <blaze/math/Aliases.h>
49 #include <blaze/math/Exception.h>
50 #include <blaze/math/Forward.h>
97 #include <blaze/util/Assert.h>
98 #include <blaze/util/EnableIf.h>
100 #include <blaze/util/MaybeUnused.h>
104 
105 
106 namespace blaze {
107 
108 //=================================================================================================
109 //
110 // HERMITIANMATRIX OPERATORS
111 //
112 //=================================================================================================
113 
114 //*************************************************************************************************
117 template< typename MT, bool SO, bool DF >
118 void reset( HermitianMatrix<MT,SO,DF>& m );
119 
120 template< typename MT, bool SO, bool DF >
121 void reset( HermitianMatrix<MT,SO,DF>& m, size_t i );
122 
123 template< typename MT, bool SO, bool DF >
124 void clear( HermitianMatrix<MT,SO,DF>& m );
125 
126 template< bool RF, typename MT, bool SO, bool DF >
127 bool isDefault( const HermitianMatrix<MT,SO,DF>& m );
128 
129 template< typename MT, bool SO, bool DF >
130 bool isIntact( const HermitianMatrix<MT,SO,DF>& m );
131 
132 template< typename MT, bool SO, bool DF >
133 void swap( HermitianMatrix<MT,SO,DF>& a, HermitianMatrix<MT,SO,DF>& b ) noexcept;
135 //*************************************************************************************************
136 
137 
138 //*************************************************************************************************
145 template< typename MT // Type of the adapted matrix
146  , bool SO // Storage order of the adapted matrix
147  , bool DF > // Density flag
149 {
150  m.reset();
151 }
152 //*************************************************************************************************
153 
154 
155 //*************************************************************************************************
168 template< typename MT // Type of the adapted matrix
169  , bool SO // Storage order of the adapted matrix
170  , bool DF > // Density flag
171 inline void reset( HermitianMatrix<MT,SO,DF>& m, size_t i )
172 {
173  m.reset( i );
174 }
175 //*************************************************************************************************
176 
177 
178 //*************************************************************************************************
185 template< typename MT // Type of the adapted matrix
186  , bool SO // Storage order of the adapted matrix
187  , bool DF > // Density flag
189 {
190  m.clear();
191 }
192 //*************************************************************************************************
193 
194 
195 //*************************************************************************************************
220 template< bool RF // Relaxation flag
221  , typename MT // Type of the adapted matrix
222  , bool SO // Storage order of the adapted matrix
223  , bool DF > // Density flag
224 inline bool isDefault( const HermitianMatrix<MT,SO,DF>& m )
225 {
226  return isDefault<RF>( m.matrix_ );
227 }
228 //*************************************************************************************************
229 
230 
231 //*************************************************************************************************
252 template< typename MT // Type of the adapted matrix
253  , bool SO // Storage order of the adapted matrix
254  , bool DF > // Density flag
255 inline bool isIntact( const HermitianMatrix<MT,SO,DF>& m )
256 {
257  return m.isIntact();
258 }
259 //*************************************************************************************************
260 
261 
262 //*************************************************************************************************
270 template< typename MT // Type of the adapted matrix
271  , bool SO // Storage order of the adapted matrix
272  , bool DF > // Density flag
274 {
275  a.swap( b );
276 }
277 //*************************************************************************************************
278 
279 
280 //*************************************************************************************************
303 template< InversionFlag IF // Inversion algorithm
304  , typename MT // Type of the dense matrix
305  , bool SO > // Storage order of the dense matrix
306 inline void invert( HermitianMatrix<MT,SO,true>& m )
307 {
309 
310  if( IF == asUniLower || IF == asUniUpper ) {
311  BLAZE_INTERNAL_ASSERT( isIdentity( m ), "Violation of preconditions detected" );
312  return;
313  }
314 
315  constexpr InversionFlag flag( ( IF == byLU || IF == byLDLT || IF == byLDLH ||
316  IF == asGeneral || IF == asSymmetric || IF == asHermitian )
317  ? ( byLDLH )
318  : ( ( IF == byLLH )
319  ?( byLLH )
320  :( asDiagonal ) ) );
321 
322  MT tmp( m.matrix_ );
323  invert<flag>( tmp );
324  m.matrix_ = std::move( tmp );
325 
326  BLAZE_INTERNAL_ASSERT( isIntact( m ), "Broken invariant detected" );
327 }
329 //*************************************************************************************************
330 
331 
332 //*************************************************************************************************
348 template< typename MT // Type of the adapted matrix
349  , bool SO // Storage order of the adapted matrix
350  , bool DF // Density flag
351  , typename ET > // Type of the element
352 inline bool trySet( const HermitianMatrix<MT,SO,DF>& mat, size_t i, size_t j, const ET& value )
353 {
354  BLAZE_INTERNAL_ASSERT( i < (~mat).rows(), "Invalid row access index" );
355  BLAZE_INTERNAL_ASSERT( j < (~mat).columns(), "Invalid column access index" );
356 
357  MAYBE_UNUSED( mat );
358 
359  return ( i != j || isReal( value ) );
360 }
362 //*************************************************************************************************
363 
364 
365 //*************************************************************************************************
383 template< typename MT // Type of the adapted matrix
384  , bool SO // Storage order of the adapted matrix
385  , bool DF // Density flag
386  , typename ET > // Type of the element
388  trySet( const HermitianMatrix<MT,SO,DF>& mat, size_t row, size_t column, size_t m, size_t n, const ET& value )
389 {
390  BLAZE_INTERNAL_ASSERT( row <= (~mat).rows(), "Invalid row access index" );
391  BLAZE_INTERNAL_ASSERT( column <= (~mat).columns(), "Invalid column access index" );
392  BLAZE_INTERNAL_ASSERT( row + m <= (~mat).rows(), "Invalid number of rows" );
393  BLAZE_INTERNAL_ASSERT( column + n <= (~mat).columns(), "Invalid number of columns" );
394 
395  MAYBE_UNUSED( mat );
396 
397  return ( m == 0UL ) ||
398  ( n == 0UL ) ||
399  ( row >= column + n ) ||
400  ( column >= row + m ) ||
401  isReal( value );
402 }
404 //*************************************************************************************************
405 
406 
407 //*************************************************************************************************
423 template< typename MT // Type of the adapted matrix
424  , bool SO // Storage order of the adapted matrix
425  , bool DF // Density flag
426  , typename ET > // Type of the element
427 inline bool tryAdd( const HermitianMatrix<MT,SO,DF>& mat, size_t i, size_t j, const ET& value )
428 {
429  return trySet( mat, i, j, value );
430 }
432 //*************************************************************************************************
433 
434 
435 //*************************************************************************************************
453 template< typename MT // Type of the adapted matrix
454  , bool SO // Storage order of the adapted matrix
455  , bool DF // Density flag
456  , typename ET > // Type of the element
458  tryAdd( const HermitianMatrix<MT,SO,DF>& mat, size_t row, size_t column, size_t m, size_t n, const ET& value )
459 {
460  return trySet( mat, row, column, m, n, value );
461 }
463 //*************************************************************************************************
464 
465 
466 //*************************************************************************************************
482 template< typename MT // Type of the adapted matrix
483  , bool SO // Storage order of the adapted matrix
484  , bool DF // Density flag
485  , typename ET > // Type of the element
486 inline bool trySub( const HermitianMatrix<MT,SO,DF>& mat, size_t i, size_t j, const ET& value )
487 {
488  return trySet( mat, i, j, value );
489 }
491 //*************************************************************************************************
492 
493 
494 //*************************************************************************************************
512 template< typename MT // Type of the adapted matrix
513  , bool SO // Storage order of the adapted matrix
514  , bool DF // Density flag
515  , typename ET > // Type of the element
517  trySub( const HermitianMatrix<MT,SO,DF>& mat, size_t row, size_t column, size_t m, size_t n, const ET& value )
518 {
519  return trySet( mat, row, column, m, n, value );
520 }
522 //*************************************************************************************************
523 
524 
525 //*************************************************************************************************
541 template< typename MT // Type of the adapted matrix
542  , bool SO // Storage order of the adapted matrix
543  , bool DF // Density flag
544  , typename ET > // Type of the element
545 inline bool tryMult( const HermitianMatrix<MT,SO,DF>& mat, size_t i, size_t j, const ET& value )
546 {
547  return trySet( mat, i, j, value );
548 }
550 //*************************************************************************************************
551 
552 
553 //*************************************************************************************************
571 template< typename MT // Type of the adapted matrix
572  , bool SO // Storage order of the adapted matrix
573  , bool DF // Density flag
574  , typename ET > // Type of the element
576  tryMult( const HermitianMatrix<MT,SO,DF>& mat, size_t row, size_t column, size_t m, size_t n, const ET& value )
577 {
578  return trySet( mat, row, column, m, n, value );
579 }
581 //*************************************************************************************************
582 
583 
584 //*************************************************************************************************
600 template< typename MT // Type of the adapted matrix
601  , bool SO // Storage order of the adapted matrix
602  , bool DF // Density flag
603  , typename ET > // Type of the element
604 inline bool tryDiv( const HermitianMatrix<MT,SO,DF>& mat, size_t i, size_t j, const ET& value )
605 {
606  return trySet( mat, i, j, value );
607 }
609 //*************************************************************************************************
610 
611 
612 //*************************************************************************************************
630 template< typename MT // Type of the adapted matrix
631  , bool SO // Storage order of the adapted matrix
632  , bool DF // Density flag
633  , typename ET > // Type of the element
635  tryDiv( const HermitianMatrix<MT,SO,DF>& mat, size_t row, size_t column, size_t m, size_t n, const ET& value )
636 {
637  return trySet( mat, row, column, m, n, value );
638 }
640 //*************************************************************************************************
641 
642 
643 //*************************************************************************************************
659 template< typename MT // Type of the adapted matrix
660  , bool SO // Storage order of the adapted matrix
661  , bool DF // Density flag
662  , typename VT > // Type of the right-hand side vector
663 inline bool tryAssign( const HermitianMatrix<MT,SO,DF>& lhs,
664  const Vector<VT,false>& rhs, size_t row, size_t column )
665 {
667 
668  BLAZE_INTERNAL_ASSERT( row <= lhs.rows(), "Invalid row access index" );
669  BLAZE_INTERNAL_ASSERT( column <= lhs.columns(), "Invalid column access index" );
670  BLAZE_INTERNAL_ASSERT( row + (~rhs).size() <= lhs.rows(), "Invalid number of rows" );
671 
672  MAYBE_UNUSED( lhs );
673 
674  using ET = ElementType_t< HermitianMatrix<MT,SO,DF> >;
675 
676  return ( IsBuiltin_v<ET> ||
677  column < row ||
678  (~rhs).size() <= column - row ||
679  isReal( (~rhs)[column-row] ) );
680 
681  return true;
682 }
684 //*************************************************************************************************
685 
686 
687 //*************************************************************************************************
703 template< typename MT // Type of the adapted matrix
704  , bool SO // Storage order of the adapted matrix
705  , bool DF // Density flag
706  , typename VT > // Type of the right-hand side vector
707 inline bool tryAssign( const HermitianMatrix<MT,SO,DF>& lhs,
708  const Vector<VT,true>& rhs, size_t row, size_t column )
709 {
711 
712  BLAZE_INTERNAL_ASSERT( row <= lhs.rows(), "Invalid row access index" );
713  BLAZE_INTERNAL_ASSERT( column <= lhs.columns(), "Invalid column access index" );
714  BLAZE_INTERNAL_ASSERT( column + (~rhs).size() <= lhs.columns(), "Invalid number of columns" );
715 
716  MAYBE_UNUSED( lhs );
717 
718  using ET = ElementType_t< HermitianMatrix<MT,SO,DF> >;
719 
720  return ( IsBuiltin_v<ET> ||
721  row < column ||
722  (~rhs).size() <= row - column ||
723  isReal( (~rhs)[row-column] ) );
724 
725  return true;
726 }
728 //*************************************************************************************************
729 
730 
731 //*************************************************************************************************
749 template< typename MT // Type of the adapted matrix
750  , bool SO // Storage order of the adapted matrix
751  , bool DF // Density flag
752  , typename VT // Type of the right-hand side dense vector
753  , bool TF > // Transpose flag of the right-hand side dense vector
754 inline bool tryAssign( const HermitianMatrix<MT,SO,DF>& lhs, const DenseVector<VT,TF>& rhs,
755  ptrdiff_t band, size_t row, size_t column )
756 {
758 
759  BLAZE_INTERNAL_ASSERT( row <= lhs.rows(), "Invalid row access index" );
760  BLAZE_INTERNAL_ASSERT( column <= lhs.columns(), "Invalid column access index" );
761  BLAZE_INTERNAL_ASSERT( row + (~rhs).size() <= lhs.rows(), "Invalid number of rows" );
762  BLAZE_INTERNAL_ASSERT( column + (~rhs).size() <= lhs.columns(), "Invalid number of columns" );
763 
764  MAYBE_UNUSED( lhs, row, column );
765 
766  if( band == 0L ) {
767  for( size_t i=0UL; i<(~rhs).size(); ++i ) {
768  if( !isReal( (~rhs)[i] ) )
769  return false;
770  }
771  }
772 
773  return true;
774 }
776 //*************************************************************************************************
777 
778 
779 //*************************************************************************************************
797 template< typename MT // Type of the adapted matrix
798  , bool SO // Storage order of the adapted matrix
799  , bool DF // Density flag
800  , typename VT // Type of the right-hand side sparse vector
801  , bool TF > // Transpose flag of the right-hand side sparse vector
802 inline bool tryAssign( const HermitianMatrix<MT,SO,DF>& lhs, const SparseVector<VT,TF>& rhs,
803  ptrdiff_t band, size_t row, size_t column )
804 {
806 
807  BLAZE_INTERNAL_ASSERT( row <= lhs.rows(), "Invalid row access index" );
808  BLAZE_INTERNAL_ASSERT( column <= lhs.columns(), "Invalid column access index" );
809  BLAZE_INTERNAL_ASSERT( row + (~rhs).size() <= lhs.rows(), "Invalid number of rows" );
810  BLAZE_INTERNAL_ASSERT( column + (~rhs).size() <= lhs.columns(), "Invalid number of columns" );
811 
812  MAYBE_UNUSED( lhs, row, column );
813 
814  if( band == 0L ) {
815  for( const auto& element : ~rhs ) {
816  if( !isReal( element.value() ) )
817  return false;
818  }
819  }
820 
821  return true;
822 }
824 //*************************************************************************************************
825 
826 
827 //*************************************************************************************************
843 template< typename MT1 // Type of the adapted matrix
844  , bool SO1 // Storage order of the adapted matrix
845  , bool DF // Density flag
846  , typename MT2 // Type of the right-hand side matrix
847  , bool SO2 > // Storage order of the right-hand side matrix
848 inline bool tryAssign( const HermitianMatrix<MT1,SO1,DF>& lhs,
849  const Matrix<MT2,SO2>& rhs, size_t row, size_t column )
850 {
852 
853  BLAZE_INTERNAL_ASSERT( row <= lhs.rows(), "Invalid row access index" );
854  BLAZE_INTERNAL_ASSERT( column <= lhs.columns(), "Invalid column access index" );
855  BLAZE_INTERNAL_ASSERT( row + (~rhs).rows() <= lhs.rows(), "Invalid number of rows" );
856  BLAZE_INTERNAL_ASSERT( column + (~rhs).columns() <= lhs.columns(), "Invalid number of columns" );
857 
858  MAYBE_UNUSED( lhs );
859 
860  const size_t M( (~rhs).rows() );
861  const size_t N( (~rhs).columns() );
862 
863  if( ( row + M <= column ) || ( column + N <= row ) )
864  return true;
865 
866  const bool lower( row > column );
867  const size_t size ( min( row + M, column + N ) - ( lower ? row : column ) );
868 
869  if( size < 2UL )
870  return true;
871 
872  const size_t subrow( lower ? 0UL : column - row );
873  const size_t subcol( lower ? row - column : 0UL );
874 
875  return isHermitian( submatrix( ~rhs, subrow, subcol, size, size ) );
876 }
878 //*************************************************************************************************
879 
880 
881 //*************************************************************************************************
897 template< typename MT // Type of the adapted matrix
898  , bool SO // Storage order of the adapted matrix
899  , bool DF // Density flag
900  , typename VT // Type of the right-hand side vector
901  , bool TF > // Transpose flag of the right-hand side vector
902 inline bool tryAddAssign( const HermitianMatrix<MT,SO,DF>& lhs,
903  const Vector<VT,TF>& rhs, size_t row, size_t column )
904 {
905  return tryAssign( lhs, ~rhs, row, column );
906 }
908 //*************************************************************************************************
909 
910 
911 //*************************************************************************************************
929 template< typename MT // Type of the adapted matrix
930  , bool SO // Storage order of the adapted matrix
931  , bool DF // Density flag
932  , typename VT // Type of the right-hand side vector
933  , bool TF > // Transpose flag of the right-hand side vector
934 inline bool tryAddAssign( const HermitianMatrix<MT,SO,DF>& lhs, const Vector<VT,TF>& rhs,
935  ptrdiff_t band, size_t row, size_t column )
936 {
937  return tryAssign( lhs, ~rhs, band, row, column );
938 }
940 //*************************************************************************************************
941 
942 
943 //*************************************************************************************************
959 template< typename MT1 // Type of the adapted matrix
960  , bool SO1 // Storage order of the adapted matrix
961  , bool DF // Density flag
962  , typename MT2 // Type of the right-hand side matrix
963  , bool SO2 > // Storage order of the right-hand side matrix
964 inline bool tryAddAssign( const HermitianMatrix<MT1,SO1,DF>& lhs,
965  const Matrix<MT2,SO2>& rhs, size_t row, size_t column )
966 {
967  return tryAssign( lhs, ~rhs, row, column );
968 }
970 //*************************************************************************************************
971 
972 
973 //*************************************************************************************************
990 template< typename MT // Type of the adapted matrix
991  , bool SO // Storage order of the adapted matrix
992  , bool DF // Density flag
993  , typename VT // Type of the right-hand side vector
994  , bool TF > // Transpose flag of the right-hand side vector
995 inline bool trySubAssign( const HermitianMatrix<MT,SO,DF>& lhs,
996  const Vector<VT,TF>& rhs, size_t row, size_t column )
997 {
998  return tryAssign( lhs, ~rhs, row, column );
999 }
1001 //*************************************************************************************************
1002 
1003 
1004 //*************************************************************************************************
1022 template< typename MT // Type of the adapted matrix
1023  , bool SO // Storage order of the adapted matrix
1024  , bool DF // Density flag
1025  , typename VT // Type of the right-hand side vector
1026  , bool TF > // Transpose flag of the right-hand side vector
1027 inline bool trySubAssign( const HermitianMatrix<MT,SO,DF>& lhs, const Vector<VT,TF>& rhs,
1028  ptrdiff_t band, size_t row, size_t column )
1029 {
1030  return tryAssign( lhs, ~rhs, band, row, column );
1031 }
1033 //*************************************************************************************************
1034 
1035 
1036 //*************************************************************************************************
1053 template< typename MT1 // Type of the adapted matrix
1054  , bool SO1 // Storage order of the adapted matrix
1055  , bool DF // Density flag
1056  , typename MT2 // Type of the right-hand side matrix
1057  , bool SO2 > // Storage order of the right-hand side matrix
1058 inline bool trySubAssign( const HermitianMatrix<MT1,SO1,DF>& lhs,
1059  const Matrix<MT2,SO2>& rhs, size_t row, size_t column )
1060 {
1061  return tryAssign( lhs, ~rhs, row, column );
1062 }
1064 //*************************************************************************************************
1065 
1066 
1067 //*************************************************************************************************
1084 template< typename MT // Type of the adapted matrix
1085  , bool SO // Storage order of the adapted matrix
1086  , bool DF // Density flag
1087  , typename VT // Type of the right-hand side vector
1088  , bool TF > // Transpose flag of the right-hand side vector
1089 inline bool tryMultAssign( const HermitianMatrix<MT,SO,DF>& lhs,
1090  const Vector<VT,TF>& rhs, size_t row, size_t column )
1091 {
1092  return tryAssign( lhs, ~rhs, row, column );
1093 }
1095 //*************************************************************************************************
1096 
1097 
1098 //*************************************************************************************************
1116 template< typename MT // Type of the adapted matrix
1117  , bool SO // Storage order of the adapted matrix
1118  , bool DF // Density flag
1119  , typename VT // Type of the right-hand side vector
1120  , bool TF > // Transpose flag of the right-hand side vector
1121 inline bool tryMultAssign( const HermitianMatrix<MT,SO,DF>& lhs, const Vector<VT,TF>& rhs,
1122  ptrdiff_t band, size_t row, size_t column )
1123 {
1124  return tryAssign( lhs, ~rhs, band, row, column );
1125 }
1127 //*************************************************************************************************
1128 
1129 
1130 //*************************************************************************************************
1147 template< typename MT1 // Type of the adapted matrix
1148  , bool SO1 // Storage order of the adapted matrix
1149  , bool DF // Density flag
1150  , typename MT2 // Type of the right-hand side matrix
1151  , bool SO2 > // Storage order of the right-hand side matrix
1152 inline bool trySchurAssign( const HermitianMatrix<MT1,SO1,DF>& lhs,
1153  const Matrix<MT2,SO2>& rhs, size_t row, size_t column )
1154 {
1155  return tryAssign( lhs, ~rhs, row, column );
1156 }
1158 //*************************************************************************************************
1159 
1160 
1161 //*************************************************************************************************
1177 template< typename MT // Type of the adapted matrix
1178  , bool SO // Storage order of the adapted matrix
1179  , bool DF // Density flag
1180  , typename VT // Type of the right-hand side vector
1181  , bool TF > // Transpose flag of the right-hand side vector
1182 inline bool tryDivAssign( const HermitianMatrix<MT,SO,DF>& lhs,
1183  const Vector<VT,TF>& rhs, size_t row, size_t column )
1184 {
1185  return tryAssign( lhs, ~rhs, row, column );
1186 }
1188 //*************************************************************************************************
1189 
1190 
1191 //*************************************************************************************************
1209 template< typename MT // Type of the adapted matrix
1210  , bool SO // Storage order of the adapted matrix
1211  , bool DF // Density flag
1212  , typename VT // Type of the right-hand side vector
1213  , bool TF > // Transpose flag of the right-hand side vector
1214 inline bool tryDivAssign( const HermitianMatrix<MT,SO,DF>& lhs, const Vector<VT,TF>& rhs,
1215  ptrdiff_t band, size_t row, size_t column )
1216 {
1217  return tryAssign( lhs, ~rhs, band, row, column );
1218 }
1220 //*************************************************************************************************
1221 
1222 
1223 
1224 
1225 //=================================================================================================
1226 //
1227 // SIZE SPECIALIZATIONS
1228 //
1229 //=================================================================================================
1230 
1231 //*************************************************************************************************
1233 template< typename MT, bool SO, bool DF >
1234 struct Size< HermitianMatrix<MT,SO,DF>, 0UL >
1235  : public Size<MT,0UL>
1236 {};
1237 
1238 template< typename MT, bool SO, bool DF >
1239 struct Size< HermitianMatrix<MT,SO,DF>, 1UL >
1240  : public Size<MT,1UL>
1241 {};
1243 //*************************************************************************************************
1244 
1245 
1246 
1247 
1248 //=================================================================================================
1249 //
1250 // MAXSIZE SPECIALIZATIONS
1251 //
1252 //=================================================================================================
1253 
1254 //*************************************************************************************************
1256 template< typename MT, bool SO, bool DF >
1257 struct MaxSize< HermitianMatrix<MT,SO,DF>, 0UL >
1258  : public MaxSize<MT,0UL>
1259 {};
1260 
1261 template< typename MT, bool SO, bool DF >
1262 struct MaxSize< HermitianMatrix<MT,SO,DF>, 1UL >
1263  : public MaxSize<MT,1UL>
1264 {};
1266 //*************************************************************************************************
1267 
1268 
1269 
1270 
1271 //=================================================================================================
1272 //
1273 // ISSQUARE SPECIALIZATIONS
1274 //
1275 //=================================================================================================
1276 
1277 //*************************************************************************************************
1279 template< typename MT, bool SO, bool DF >
1280 struct IsSquare< HermitianMatrix<MT,SO,DF> >
1281  : public TrueType
1282 {};
1284 //*************************************************************************************************
1285 
1286 
1287 
1288 
1289 //=================================================================================================
1290 //
1291 // ISUNIFORM SPECIALIZATIONS
1292 //
1293 //=================================================================================================
1294 
1295 //*************************************************************************************************
1297 template< typename MT, bool SO, bool DF >
1298 struct IsUniform< HermitianMatrix<MT,SO,DF> >
1299  : public IsUniform<MT>
1300 {};
1302 //*************************************************************************************************
1303 
1304 
1305 
1306 
1307 //=================================================================================================
1308 //
1309 // ISSYMMETRIC SPECIALIZATIONS
1310 //
1311 //=================================================================================================
1312 
1313 //*************************************************************************************************
1315 template< typename MT, bool SO, bool DF >
1316 struct IsSymmetric< HermitianMatrix<MT,SO,DF> >
1317  : public IsBuiltin< ElementType_t<MT> >
1318 {};
1320 //*************************************************************************************************
1321 
1322 
1323 
1324 
1325 //=================================================================================================
1326 //
1327 // ISHERMITIAN SPECIALIZATIONS
1328 //
1329 //=================================================================================================
1330 
1331 //*************************************************************************************************
1333 template< typename MT, bool SO, bool DF >
1334 struct IsHermitian< HermitianMatrix<MT,SO,DF> >
1335  : public TrueType
1336 {};
1338 //*************************************************************************************************
1339 
1340 
1341 
1342 
1343 //=================================================================================================
1344 //
1345 // ISSTRICTLYLOWER SPECIALIZATIONS
1346 //
1347 //=================================================================================================
1348 
1349 //*************************************************************************************************
1351 template< typename MT, bool SO, bool DF >
1352 struct IsStrictlyLower< HermitianMatrix<MT,SO,DF> >
1353  : public IsZero<MT>
1354 {};
1356 //*************************************************************************************************
1357 
1358 
1359 
1360 
1361 //=================================================================================================
1362 //
1363 // ISSTRICTLYUPPER SPECIALIZATIONS
1364 //
1365 //=================================================================================================
1366 
1367 //*************************************************************************************************
1369 template< typename MT, bool SO, bool DF >
1370 struct IsStrictlyUpper< HermitianMatrix<MT,SO,DF> >
1371  : public IsZero<MT>
1372 {};
1374 //*************************************************************************************************
1375 
1376 
1377 
1378 
1379 //=================================================================================================
1380 //
1381 // ISADAPTOR SPECIALIZATIONS
1382 //
1383 //=================================================================================================
1384 
1385 //*************************************************************************************************
1387 template< typename MT, bool SO, bool DF >
1388 struct IsAdaptor< HermitianMatrix<MT,SO,DF> >
1389  : public TrueType
1390 {};
1392 //*************************************************************************************************
1393 
1394 
1395 
1396 
1397 //=================================================================================================
1398 //
1399 // ISRESTRICTED SPECIALIZATIONS
1400 //
1401 //=================================================================================================
1402 
1403 //*************************************************************************************************
1405 template< typename MT, bool SO, bool DF >
1406 struct IsRestricted< HermitianMatrix<MT,SO,DF> >
1407  : public TrueType
1408 {};
1410 //*************************************************************************************************
1411 
1412 
1413 
1414 
1415 //=================================================================================================
1416 //
1417 // HASCONSTDATAACCESS SPECIALIZATIONS
1418 //
1419 //=================================================================================================
1420 
1421 //*************************************************************************************************
1423 template< typename MT, bool SO >
1424 struct HasConstDataAccess< HermitianMatrix<MT,SO,true> >
1425  : public TrueType
1426 {};
1428 //*************************************************************************************************
1429 
1430 
1431 
1432 
1433 //=================================================================================================
1434 //
1435 // ISALIGNED SPECIALIZATIONS
1436 //
1437 //=================================================================================================
1438 
1439 //*************************************************************************************************
1441 template< typename MT, bool SO, bool DF >
1442 struct IsAligned< HermitianMatrix<MT,SO,DF> >
1443  : public IsAligned<MT>
1444 {};
1446 //*************************************************************************************************
1447 
1448 
1449 
1450 
1451 //=================================================================================================
1452 //
1453 // ISCONTIGUOUS SPECIALIZATIONS
1454 //
1455 //=================================================================================================
1456 
1457 //*************************************************************************************************
1459 template< typename MT, bool SO, bool DF >
1460 struct IsContiguous< HermitianMatrix<MT,SO,DF> >
1461  : public IsContiguous<MT>
1462 {};
1464 //*************************************************************************************************
1465 
1466 
1467 
1468 
1469 //=================================================================================================
1470 //
1471 // ISPADDED SPECIALIZATIONS
1472 //
1473 //=================================================================================================
1474 
1475 //*************************************************************************************************
1477 template< typename MT, bool SO, bool DF >
1478 struct IsPadded< HermitianMatrix<MT,SO,DF> >
1479  : public IsPadded<MT>
1480 {};
1482 //*************************************************************************************************
1483 
1484 
1485 
1486 
1487 //=================================================================================================
1488 //
1489 // ISRESIZABLE SPECIALIZATIONS
1490 //
1491 //=================================================================================================
1492 
1493 //*************************************************************************************************
1495 template< typename MT, bool SO, bool DF >
1496 struct IsResizable< HermitianMatrix<MT,SO,DF> >
1497  : public IsResizable<MT>
1498 {};
1500 //*************************************************************************************************
1501 
1502 
1503 
1504 
1505 //=================================================================================================
1506 //
1507 // ISSHRINKABLE SPECIALIZATIONS
1508 //
1509 //=================================================================================================
1510 
1511 //*************************************************************************************************
1513 template< typename MT, bool SO, bool DF >
1514 struct IsShrinkable< HermitianMatrix<MT,SO,DF> >
1515  : public IsShrinkable<MT>
1516 {};
1518 //*************************************************************************************************
1519 
1520 
1521 
1522 
1523 //=================================================================================================
1524 //
1525 // REMOVEADAPTOR SPECIALIZATIONS
1526 //
1527 //=================================================================================================
1528 
1529 //*************************************************************************************************
1531 template< typename MT, bool SO, bool DF >
1532 struct RemoveAdaptor< HermitianMatrix<MT,SO,DF> >
1533 {
1534  using Type = MT;
1535 };
1537 //*************************************************************************************************
1538 
1539 
1540 
1541 
1542 //=================================================================================================
1543 //
1544 // ADDTRAIT SPECIALIZATIONS
1545 //
1546 //=================================================================================================
1547 
1548 //*************************************************************************************************
1550 template< typename T1, typename T2 >
1551 struct AddTraitEval1< T1, T2
1552  , EnableIf_t< IsMatrix_v<T1> &&
1553  IsMatrix_v<T2> &&
1554  ( ( IsHermitian_v<T1> && !IsSymmetric_v<T1> &&
1555  IsHermitian_v<T2> && !IsSymmetric_v<T2> ) ||
1556  ( IsHermitian_v<T1> && !IsSymmetric_v<T1> &&
1557  IsSymmetric_v<T2> && !IsComplex_v< UnderlyingNumeric_t<T2> > ) ||
1558  ( IsSymmetric_v<T1> && !IsComplex_v< UnderlyingNumeric_t<T1> > &&
1559  IsHermitian_v<T2> && !IsSymmetric_v<T2> ) ) &&
1560  !( IsUniform_v<T1> && IsUniform_v<T2> ) &&
1561  !( IsZero_v<T1> || IsZero_v<T2> ) > >
1562 {
1563  using Type = HermitianMatrix< typename AddTraitEval2<T1,T2>::Type >;
1564 };
1566 //*************************************************************************************************
1567 
1568 
1569 
1570 
1571 //=================================================================================================
1572 //
1573 // SUBTRAIT SPECIALIZATIONS
1574 //
1575 //=================================================================================================
1576 
1577 //*************************************************************************************************
1579 template< typename T1, typename T2 >
1580 struct SubTraitEval1< T1, T2
1581  , EnableIf_t< IsMatrix_v<T1> &&
1582  IsMatrix_v<T2> &&
1583  ( ( IsHermitian_v<T1> && !IsSymmetric_v<T1> &&
1584  IsHermitian_v<T2> && !IsSymmetric_v<T2> ) ||
1585  ( IsHermitian_v<T1> && !IsSymmetric_v<T1> &&
1586  IsSymmetric_v<T2> && !IsComplex_v< UnderlyingNumeric_t<T2> > ) ||
1587  ( IsSymmetric_v<T1> && !IsComplex_v< UnderlyingNumeric_t<T1> > &&
1588  IsHermitian_v<T2> && !IsSymmetric_v<T2> ) ) &&
1589  !( IsZero_v<T1> || IsZero_v<T2> ) > >
1590 {
1591  using Type = HermitianMatrix< typename SubTraitEval2<T1,T2>::Type >;
1592 };
1594 //*************************************************************************************************
1595 
1596 
1597 
1598 
1599 //=================================================================================================
1600 //
1601 // SCHURTRAIT SPECIALIZATIONS
1602 //
1603 //=================================================================================================
1604 
1605 //*************************************************************************************************
1607 template< typename T1, typename T2 >
1608 struct SchurTraitEval1< T1, T2
1609  , EnableIf_t< IsMatrix_v<T1> &&
1610  IsMatrix_v<T2> &&
1611  ( IsHermitian_v<T1> && IsHermitian_v<T2> ) &&
1612  !( IsSymmetric_v<T1> && IsSymmetric_v<T2> ) &&
1613  !( IsDiagonal_v<T1> || IsZero_v<T1> ) &&
1614  !( IsDiagonal_v<T2> || IsZero_v<T2> ) > >
1615 {
1616  using Type = HermitianMatrix< typename SchurTraitEval2<T1,T2>::Type >;
1617 };
1619 //*************************************************************************************************
1620 
1621 
1622 
1623 
1624 //=================================================================================================
1625 //
1626 // MULTTRAIT SPECIALIZATIONS
1627 //
1628 //=================================================================================================
1629 
1630 //*************************************************************************************************
1632 template< typename T1, typename T2 >
1633 struct MultTraitEval1< T1, T2
1634  , EnableIf_t< IsMatrix_v<T1> &&
1635  IsNumeric_v<T2> &&
1636  ( IsHermitian_v<T1> && !IsSymmetric_v<T1> && !IsUniform_v<T1> ) > >
1637 {
1638  using Type = HermitianMatrix< typename MultTraitEval2<T1,T2>::Type >;
1639 };
1640 
1641 template< typename T1, typename T2 >
1642 struct MultTraitEval1< T1, T2
1643  , EnableIf_t< IsNumeric_v<T1> &&
1644  IsMatrix_v<T2> &&
1645  ( IsHermitian_v<T2> && !IsSymmetric_v<T2> && !IsUniform_v<T2> ) > >
1646 {
1647  using Type = HermitianMatrix< typename MultTraitEval2<T1,T2>::Type >;
1648 };
1650 //*************************************************************************************************
1651 
1652 
1653 
1654 
1655 //=================================================================================================
1656 //
1657 // KRONTRAIT SPECIALIZATIONS
1658 //
1659 //=================================================================================================
1660 
1661 //*************************************************************************************************
1663 template< typename T1, typename T2 >
1664 struct KronTraitEval1< T1, T2
1665  , EnableIf_t< IsMatrix_v<T1> &&
1666  IsMatrix_v<T2> &&
1667  ( IsHermitian_v<T1> && IsHermitian_v<T2> ) &&
1668  !( IsSymmetric_v<T1> && IsSymmetric_v<T2> ) &&
1669  !( IsZero_v<T1> || IsZero_v<T2> ) > >
1670 {
1671  using Type = HermitianMatrix< typename KronTraitEval2<T1,T2>::Type >;
1672 };
1674 //*************************************************************************************************
1675 
1676 
1677 
1678 
1679 //=================================================================================================
1680 //
1681 // DIVTRAIT SPECIALIZATIONS
1682 //
1683 //=================================================================================================
1684 
1685 //*************************************************************************************************
1687 template< typename T1, typename T2 >
1688 struct DivTraitEval1< T1, T2
1689  , EnableIf_t< IsHermitian_v<T1> && !IsSymmetric_v<T1> && IsNumeric_v<T2> > >
1690 {
1691  using Type = HermitianMatrix< typename DivTraitEval2<T1,T2>::Type >;
1692 };
1694 //*************************************************************************************************
1695 
1696 
1697 
1698 
1699 //=================================================================================================
1700 //
1701 // MAPTRAIT SPECIALIZATIONS
1702 //
1703 //=================================================================================================
1704 
1705 //*************************************************************************************************
1707 template< typename T, typename OP >
1708 struct UnaryMapTraitEval1< T, OP
1709  , EnableIf_t< YieldsHermitian_v<OP,T> &&
1710  !YieldsSymmetric_v<OP,T> &&
1711  !YieldsIdentity_v<OP,T> > >
1712 {
1713  using Type = HermitianMatrix< typename UnaryMapTraitEval2<T,OP>::Type, StorageOrder_v<T> >;
1714 };
1716 //*************************************************************************************************
1717 
1718 
1719 //*************************************************************************************************
1721 template< typename T1, typename T2, typename OP >
1722 struct BinaryMapTraitEval1< T1, T2, OP
1723  , EnableIf_t< YieldsHermitian_v<OP,T1,T2> &&
1724  !YieldsSymmetric_v<OP,T1,T2> &&
1725  !YieldsIdentity_v<OP,T1,T2> > >
1726 {
1727  using Type = HermitianMatrix< typename BinaryMapTraitEval2<T1,T2,OP>::Type >;
1728 };
1730 //*************************************************************************************************
1731 
1732 
1733 
1734 
1735 //=================================================================================================
1736 //
1737 // DECLSYMTRAIT SPECIALIZATIONS
1738 //
1739 //=================================================================================================
1740 
1741 //*************************************************************************************************
1743 template< typename MT, bool SO, bool DF >
1744 struct DeclSymTrait< HermitianMatrix<MT,SO,DF> >
1745 {
1746  using Type = SymmetricMatrix<MT,SO,DF>;
1747 };
1749 //*************************************************************************************************
1750 
1751 
1752 
1753 
1754 //=================================================================================================
1755 //
1756 // DECLHERMTRAIT SPECIALIZATIONS
1757 //
1758 //=================================================================================================
1759 
1760 //*************************************************************************************************
1762 template< typename MT, bool SO, bool DF >
1763 struct DeclHermTrait< HermitianMatrix<MT,SO,DF> >
1764 {
1765  using Type = HermitianMatrix<MT,SO,DF>;
1766 };
1768 //*************************************************************************************************
1769 
1770 
1771 
1772 
1773 //=================================================================================================
1774 //
1775 // DECLLOWTRAIT SPECIALIZATIONS
1776 //
1777 //=================================================================================================
1778 
1779 //*************************************************************************************************
1781 template< typename MT, bool SO, bool DF >
1782 struct DeclLowTrait< HermitianMatrix<MT,SO,DF> >
1783 {
1784  using Type = DiagonalMatrix<MT,SO,DF>;
1785 };
1787 //*************************************************************************************************
1788 
1789 
1790 
1791 
1792 //=================================================================================================
1793 //
1794 // DECLUPPTRAIT SPECIALIZATIONS
1795 //
1796 //=================================================================================================
1797 
1798 //*************************************************************************************************
1800 template< typename MT, bool SO, bool DF >
1801 struct DeclUppTrait< HermitianMatrix<MT,SO,DF> >
1802 {
1803  using Type = DiagonalMatrix<MT,SO,DF>;
1804 };
1806 //*************************************************************************************************
1807 
1808 
1809 
1810 
1811 //=================================================================================================
1812 //
1813 // DECLDIAGTRAIT SPECIALIZATIONS
1814 //
1815 //=================================================================================================
1816 
1817 //*************************************************************************************************
1819 template< typename MT, bool SO, bool DF >
1820 struct DeclDiagTrait< HermitianMatrix<MT,SO,DF> >
1821 {
1822  using Type = DiagonalMatrix<MT,SO,DF>;
1823 };
1825 //*************************************************************************************************
1826 
1827 
1828 
1829 
1830 //=================================================================================================
1831 //
1832 // HIGHTYPE SPECIALIZATIONS
1833 //
1834 //=================================================================================================
1835 
1836 //*************************************************************************************************
1838 template< typename MT1, bool SO1, bool DF1, typename MT2, bool SO2, bool DF2 >
1839 struct HighType< HermitianMatrix<MT1,SO1,DF1>, HermitianMatrix<MT2,SO2,DF2> >
1840 {
1841  using Type = HermitianMatrix< typename HighType<MT1,MT2>::Type >;
1842 };
1844 //*************************************************************************************************
1845 
1846 
1847 
1848 
1849 //=================================================================================================
1850 //
1851 // LOWTYPE SPECIALIZATIONS
1852 //
1853 //=================================================================================================
1854 
1855 //*************************************************************************************************
1857 template< typename MT1, bool SO1, bool DF1, typename MT2, bool SO2, bool DF2 >
1858 struct LowType< HermitianMatrix<MT1,SO1,DF1>, HermitianMatrix<MT2,SO2,DF2> >
1859 {
1860  using Type = HermitianMatrix< typename LowType<MT1,MT2>::Type >;
1861 };
1863 //*************************************************************************************************
1864 
1865 
1866 
1867 
1868 //=================================================================================================
1869 //
1870 // SUBMATRIXTRAIT SPECIALIZATIONS
1871 //
1872 //=================================================================================================
1873 
1874 //*************************************************************************************************
1876 template< typename MT, size_t I, size_t N >
1877 struct SubmatrixTraitEval1< MT, I, I, N, N
1878  , EnableIf_t< IsHermitian_v<MT> &&
1879  !IsSymmetric_v<MT> > >
1880 {
1881  using Type = HermitianMatrix< typename SubmatrixTraitEval2<MT,I,I,N,N>::Type >;
1882 };
1884 //*************************************************************************************************
1885 
1886 } // namespace blaze
1887 
1888 #endif
bool isReal(const DiagonalProxy< MT > &proxy)
Returns whether the matrix element represents a real number.
Definition: DiagonalProxy.h:657
Header file for the UnderlyingNumeric type trait.
Header file for auxiliary alias declarations.
decltype(auto) column(Matrix< MT, SO > &matrix, RCAs... args)
Creating a view on a specific column of the given matrix.
Definition: Column.h:133
Headerfile for the generic min algorithm.
Header file for the decldiag trait.
Header file for the Schur product trait.
constexpr bool IsComplex_v
Auxiliary variable template for the IsComplex type trait.The IsComplex_v variable template provides a...
Definition: IsComplex.h:139
constexpr bool IsMatrix_v
Auxiliary variable template for the IsMatrix type trait.The IsMatrix_v variable template provides a c...
Definition: IsMatrix.h:138
Header file for the subtraction trait.
Flag for the inversion of a diagonal matrix.
Definition: InversionFlag.h:115
decltype(auto) submatrix(Matrix< MT, SO > &, RSAs...)
Creating a view on a specific submatrix of the given matrix.
Definition: Submatrix.h:178
Flag for the inversion of a general matrix (same as byLU).
Definition: InversionFlag.h:108
Header file for the declherm trait.
Flag for the inversion of a upper unitriangular matrix.
Definition: InversionFlag.h:114
Flag for the inversion of a lower unitriangular matrix.
Definition: InversionFlag.h:112
Header file for the IsDiagonal type trait.
Header file for the dense matrix inversion flags.
Flag for the Bunch-Kaufman-based inversion for Hermitian matrices.
Definition: InversionFlag.h:105
void reset(const DiagonalProxy< MT > &proxy)
Resetting the represented element to the default initial values.
Definition: DiagonalProxy.h:595
Header file for the YieldsIdentity type trait.
Header file for the MAYBE_UNUSED function template.
BoolConstant< true > TrueType
Type traits base class.The TrueType class is used as base class for type traits and value traits that...
Definition: IntegralConstant.h:132
Header file for all forward declarations of the math module.
constexpr bool IsHermitian_v
Auxiliary variable template for the IsHermitian type trait.The IsHermitian_v variable template provid...
Definition: IsHermitian.h:172
Header file for the MaxSize type trait.
constexpr size_t columns(const Matrix< MT, SO > &matrix) noexcept
Returns the current number of columns of the matrix.
Definition: Matrix.h:514
bool isIdentity(const DenseMatrix< MT, SO > &dm)
Checks if the give dense matrix is an identity matrix.
Definition: DenseMatrix.h:2433
Header file for the IsMatrix type trait.
Header file for the IsSquare type trait.
typename EnableIf< Condition, T >::Type EnableIf_t
Auxiliary type for the EnableIf class template.The EnableIf_t alias declaration provides a convenient...
Definition: EnableIf.h:138
void invert(const HermitianProxy< MT > &proxy)
In-place inversion of the represented element.
Definition: HermitianProxy.h:779
Constraint on the data type.
Header file for the LowType type trait.
Header file for the IsUniform type trait.
Header file for the multiplication trait.
Header file for the IsStrictlyUpper type trait.
Header file for the IsSymmetric type trait.
Namespace of the Blaze C++ math library.
Definition: Blaze.h:58
#define BLAZE_ALWAYS_INLINE
Platform dependent setup of an enforced inline keyword.
Definition: Inline.h:85
Flag for the LU-based matrix inversion.
Definition: InversionFlag.h:103
Header file for the IsShrinkable type trait.
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:1162
Header file for the decllow trait.
constexpr bool IsNumeric_v
Auxiliary variable template for the IsNumeric type trait.The IsNumeric_v variable template provides a...
Definition: IsNumeric.h:143
Flag for the inversion of a Hermitian matrix (same as byLDLH).
Definition: InversionFlag.h:110
constexpr void MAYBE_UNUSED(const Args &...)
Suppression of unused parameter warnings.
Definition: MaybeUnused.h:81
Header file for the IsAligned type trait.
Flag for the Bunch-Kaufman-based inversion for symmetric matrices.
Definition: InversionFlag.h:104
HermitianMatrix specialization for sparse matrices.
Header file for the Kron product trait.
Header file for the exception macros of the math module.
Header file for the RemoveAdaptor type trait.
Header file for the implementation of the base template of the HeritianMatrix.
Constraint on the data type.
Header file for the EnableIf class template.
Header file for the IsStrictlyLower type trait.
void clear(const DiagonalProxy< MT > &proxy)
Clearing the represented element.
Definition: DiagonalProxy.h:615
Header file for the IsPadded type trait.
Header file for the IsAdaptor type trait.
decltype(auto) band(Matrix< MT, SO > &matrix, RBAs... args)
Creating a view on a specific band of the given matrix.
Definition: Band.h:137
Header file for the conjugate shim.
Header file for the IsNumeric type trait.
Header file for the HasConstDataAccess type trait.
Header file for the declupp trait.
Flag for the inversion of a symmetric matrix (same as byLDLT).
Definition: InversionFlag.h:109
Header file for run time assertion macros.
Header file for the YieldsSymmetric type trait.
Header file for the addition trait.
Header file for the division trait.
Header file for the submatrix trait.
Header file for the IsContiguous type trait.
decltype(auto) row(Matrix< MT, SO > &, RRAs...)
Creating a view on a specific row of the given matrix.
Definition: Row.h:133
Header file for the IsZero type trait.
Header file for the declsym trait.
bool isHermitian(const DenseMatrix< MT, SO > &dm)
Checks if the given dense matrix is Hermitian.
Definition: DenseMatrix.h:1406
Matrix adapter for Hermitian matrices.
Definition: BaseTemplate.h:611
Header file for the isDefault shim.
void swap(DiagonalMatrix< MT, SO, DF > &a, DiagonalMatrix< MT, SO, DF > &b) noexcept
Swapping the contents of two matrices.
Definition: DiagonalMatrix.h:282
constexpr size_t size(const Matrix< MT, SO > &matrix) noexcept
Returns the total number of elements of the matrix.
Definition: Matrix.h:530
#define BLAZE_CONSTRAINT_MUST_BE_BLAS_COMPATIBLE_TYPE(T)
Constraint on the data type.In case the given data type T is not a BLAS compatible data type (i....
Definition: BLASCompatible.h:61
Flag for the Cholesky-based inversion for positive-definite matrices.
Definition: InversionFlag.h:106
#define BLAZE_CONSTRAINT_MUST_NOT_REQUIRE_EVALUATION(T)
Constraint on the data type.In case the given data type T requires an intermediate evaluation within ...
Definition: RequiresEvaluation.h:81
constexpr size_t rows(const Matrix< MT, SO > &matrix) noexcept
Returns the current number of rows of the matrix.
Definition: Matrix.h:498
Header file for the IsBuiltin type trait.
Header file for the isDivisor shim.
Header file for the StorageOrder type trait.
Header file for the IntegralConstant class template.
Header file for the map trait.
bool isIntact(const DiagonalMatrix< MT, SO, DF > &m)
Returns whether the invariants of the given diagonal matrix are intact.
Definition: DiagonalMatrix.h:264
Header file for the IsComplex type trait.
bool isDefault(const DiagonalProxy< MT > &proxy)
Returns whether the represented element is in default state.
Definition: DiagonalProxy.h:635
constexpr bool YieldsHermitian_v
Auxiliary variable template for the YieldsHermitian type trait.The YieldsHermitian_v variable templat...
Definition: YieldsHermitian.h:124
Header file for the YieldsHermitian type trait.
Header file for the IsHermitian type trait.
Header file for the IsResizable type trait.
Header file for the IsRestricted type trait.
Header file for the Size type trait.
Header file for the isReal shim.
HermitianMatrix specialization for dense matrices.
InversionFlag
Inversion flag.The InversionFlag type enumeration represents the different types of matrix inversion ...
Definition: InversionFlag.h:101
#define BLAZE_INTERNAL_ASSERT(expr, msg)
Run time assertion macro for internal checks.In case of an invalid run time expression,...
Definition: Assert.h:101
Header file for the HighType type trait.