All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
SMatTransposer.h
Go to the documentation of this file.
1 //=================================================================================================
33 //=================================================================================================
34 
35 #ifndef _BLAZE_MATH_EXPRESSIONS_SMATTRANSPOSER_H_
36 #define _BLAZE_MATH_EXPRESSIONS_SMATTRANSPOSER_H_
37 
38 
39 //*************************************************************************************************
40 // Includes
41 //*************************************************************************************************
42 
43 #include <vector>
49 #include <blaze/util/Assert.h>
50 #include <blaze/util/EnableIf.h>
51 #include <blaze/util/Types.h>
53 
54 
55 namespace blaze {
56 
57 //=================================================================================================
58 //
59 // CLASS SMATTRANSPOSER
60 //
61 //=================================================================================================
62 
63 //*************************************************************************************************
69 template< typename MT // Type of the sparse matrix
70  , bool SO > // Storage order
71 class SMatTransposer : public SparseMatrix< SMatTransposer<MT,SO>, SO >
72 {
73  public:
74  //**Type definitions****************************************************************************
76  typedef typename MT::TransposeType ResultType;
77  typedef MT OppositeType;
78  typedef typename MT::ResultType TransposeType;
79  typedef typename MT::ElementType ElementType;
80  typedef typename MT::ReturnType ReturnType;
81  typedef const This& CompositeType;
82  typedef typename MT::Reference Reference;
84  typedef typename MT::Iterator Iterator;
85  typedef typename MT::ConstIterator ConstIterator;
86  //**********************************************************************************************
87 
88  //**Compilation flags***************************************************************************
90 
93  enum { smpAssignable = MT::smpAssignable };
94  //**********************************************************************************************
95 
96  //**Constructor*********************************************************************************
101  explicit inline SMatTransposer( MT& sm )
102  : sm_( sm ) // The sparse matrix operand
103  {}
104  //**********************************************************************************************
105 
106  //**Access operator*****************************************************************************
113  inline ConstReference operator()( size_t i, size_t j ) const {
114  BLAZE_INTERNAL_ASSERT( i < sm_.columns(), "Invalid row access index" );
115  BLAZE_INTERNAL_ASSERT( j < sm_.row() , "Invalid column access index" );
116  return sm_(j,i);
117  }
118  //**********************************************************************************************
119 
120  //**Begin function******************************************************************************
131  inline Iterator begin( size_t i ) {
132  return sm_.begin(i);
133  }
134  //**********************************************************************************************
135 
136  //**Begin function******************************************************************************
147  inline ConstIterator begin( size_t i ) const {
148  return sm_.cbegin(i);
149  }
150  //**********************************************************************************************
151 
152  //**Cbegin function*****************************************************************************
163  inline ConstIterator cbegin( size_t i ) const {
164  return sm_.cbegin(i);
165  }
166  //**********************************************************************************************
167 
168  //**End function********************************************************************************
179  inline Iterator end( size_t i ) {
180  return sm_.end(i);
181  }
182  //**********************************************************************************************
183 
184  //**End function********************************************************************************
195  inline ConstIterator end( size_t i ) const {
196  return sm_.cend(i);
197  }
198  //**********************************************************************************************
199 
200  //**Cend function*******************************************************************************
211  inline ConstIterator cend( size_t i ) const {
212  return sm_.cend(i);
213  }
214  //**********************************************************************************************
215 
216  //**Multiplication assignment operator**********************************************************
223  template< typename Other > // Data type of the right-hand side scalar
224  inline typename EnableIf< IsNumeric<Other>, SMatTransposer >::Type& operator*=( Other rhs )
225  {
226  (~sm_) *= rhs;
227  return *this;
228  }
229  //**********************************************************************************************
230 
231  //**Division assignment operator****************************************************************
240  template< typename Other > // Data type of the right-hand side scalar
241  inline typename EnableIf< IsNumeric<Other>, SMatTransposer >::Type& operator/=( Other rhs )
242  {
243  BLAZE_USER_ASSERT( rhs != Other(0), "Division by zero detected" );
244 
245  (~sm_) /= rhs;
246  return *this;
247  }
248  //**********************************************************************************************
249 
250  //**Rows function*******************************************************************************
255  inline size_t rows() const {
256  return sm_.columns();
257  }
258  //**********************************************************************************************
259 
260  //**Columns function****************************************************************************
265  inline size_t columns() const {
266  return sm_.rows();
267  }
268  //**********************************************************************************************
269 
270  //**Reset function******************************************************************************
275  inline void reset() {
276  return sm_.reset();
277  }
278  //**********************************************************************************************
279 
280  //**Insert function*****************************************************************************
293  inline Iterator insert( size_t i, size_t j, const ElementType& value ) {
294  return sm_.insert( j, i, value );
295  }
296  //**********************************************************************************************
297 
298  //**Reserve function****************************************************************************
308  inline void reserve( size_t nonzeros ) {
309  sm_.reserve( nonzeros );
310  }
311  //**********************************************************************************************
312 
313  //**Reserve function****************************************************************************
327  inline void reserve( size_t i, size_t nonzeros ) {
328  sm_.reserve( i, nonzeros );
329  }
330  //**********************************************************************************************
331 
332  //**Append function*****************************************************************************
359  inline void append( size_t i, size_t j, const ElementType& value, bool check=false ) {
360  sm_.append( j, i, value, check );
361  }
362  //**********************************************************************************************
363 
364  //**Finalize function***************************************************************************
377  inline void finalize( size_t i ) {
378  sm_.finalize( i );
379  }
380  //**********************************************************************************************
381 
382  //**********************************************************************************************
388  template< typename Other > // Data type of the foreign expression
389  inline bool canAlias( const Other* alias ) const
390  {
391  return sm_.canAlias( alias );
392  }
393  //**********************************************************************************************
394 
395  //**********************************************************************************************
401  template< typename Other > // Data type of the foreign expression
402  inline bool isAliased( const Other* alias ) const
403  {
404  return sm_.isAliased( alias );
405  }
406  //**********************************************************************************************
407 
408  //**CanSMPAssign function***********************************************************************
413  inline bool canSMPAssign() const
414  {
415  return sm_.canSMPAssign();
416  }
417  //**********************************************************************************************
418 
419  //**Transpose assignment of row-major sparse matrices*******************************************
430  template< typename MT2 > // Type of the right-hand side sparse matrix
431  inline void assign( const SparseMatrix<MT2,false>& rhs )
432  {
434 
435  BLAZE_INTERNAL_ASSERT( sm_.columns() == (~rhs).rows() , "Invalid number of rows" );
436  BLAZE_INTERNAL_ASSERT( sm_.rows() == (~rhs).columns() , "Invalid number of columns" );
437  BLAZE_INTERNAL_ASSERT( sm_.capacity() >= (~rhs).nonZeros(), "Capacity not sufficient" );
438 
439  typedef typename MT2::ConstIterator RhsIterator;
440 
441  const size_t m( rows() );
442 
443  for( size_t i=0UL; i<m; ++i ) {
444  for( RhsIterator element=(~rhs).begin(i); element!=(~rhs).end(i); ++element )
445  sm_.append( element->index(), i, element->value() );
446  finalize( i );
447  }
448  }
449  //**********************************************************************************************
450 
451  //**Transpose assignment of column-major sparse matrices****************************************
462  template< typename MT2 > // Type of the right-hand side sparse matrix
463  inline void assign( const SparseMatrix<MT2,true>& rhs )
464  {
466 
467  BLAZE_INTERNAL_ASSERT( sm_.columns() == (~rhs).rows() , "Invalid number of rows" );
468  BLAZE_INTERNAL_ASSERT( sm_.rows() == (~rhs).columns() , "Invalid number of columns" );
469  BLAZE_INTERNAL_ASSERT( sm_.capacity() >= (~rhs).nonZeros(), "Capacity not sufficient" );
470 
471  typedef typename MT2::ConstIterator RhsIterator;
472 
473  const size_t m( rows() );
474  const size_t n( columns() );
475 
476  // Counting the number of elements per row
477  std::vector<size_t> rowLengths( m, 0UL );
478  for( size_t j=0UL; j<n; ++j ) {
479  for( RhsIterator element=(~rhs).begin(j); element!=(~rhs).end(j); ++element )
480  ++rowLengths[element->index()];
481  }
482 
483  // Resizing the sparse matrix
484  for( size_t i=0UL; i<m; ++i ) {
485  sm_.reserve( i, rowLengths[i] );
486  }
487 
488  // Appending the elements to the rows of the sparse matrix
489  for( size_t j=0UL; j<n; ++j ) {
490  for( RhsIterator element=(~rhs).begin(j); element!=(~rhs).end(j); ++element ) {
491  sm_.append( j, element->index(), element->value() );
492  }
493  }
494  }
495  //**********************************************************************************************
496 
497  private:
498  //**Member variables****************************************************************************
499  MT& sm_;
500  //**********************************************************************************************
501 
502  //**Compile time checks*************************************************************************
508  //**********************************************************************************************
509 };
510 //*************************************************************************************************
511 
512 
513 
514 
515 //=================================================================================================
516 //
517 // CLASS TEMPLATE SPECIALIZATION FOR ROW-MAJOR MATRICES
518 //
519 //=================================================================================================
520 
521 //*************************************************************************************************
529 template< typename MT > // Type of the sparse matrix
530 class SMatTransposer<MT,true> : public SparseMatrix< SMatTransposer<MT,true>, true >
531 {
532  public:
533  //**Type definitions****************************************************************************
534  typedef SMatTransposer<MT,true> This;
535  typedef typename MT::TransposeType ResultType;
536  typedef MT OppositeType;
537  typedef typename MT::ResultType TransposeType;
538  typedef typename MT::ElementType ElementType;
539  typedef typename MT::ReturnType ReturnType;
540  typedef const This& CompositeType;
541  typedef typename MT::Reference Reference;
542  typedef typename MT::ConstReference ConstReference;
543  typedef typename MT::Iterator Iterator;
544  typedef typename MT::ConstIterator ConstIterator;
545  //**********************************************************************************************
546 
547  //**Compilation flags***************************************************************************
549 
552  enum { smpAssignable = MT::smpAssignable };
553  //**********************************************************************************************
554 
555  //**Constructor*********************************************************************************
560  explicit inline SMatTransposer( MT& sm )
561  : sm_( sm ) // The sparse matrix operand
562  {}
563  //**********************************************************************************************
564 
565  //**Access operator*****************************************************************************
572  inline ConstReference operator()( size_t i, size_t j ) const {
573  BLAZE_INTERNAL_ASSERT( i < sm_.columns(), "Invalid row access index" );
574  BLAZE_INTERNAL_ASSERT( j < sm_.row() , "Invalid column access index" );
575  return sm_(j,i);
576  }
577  //**********************************************************************************************
578 
579  //**Begin function******************************************************************************
585  inline Iterator begin( size_t j ) {
586  return sm_.begin(j);
587  }
588  //**********************************************************************************************
589 
590  //**Begin function******************************************************************************
596  inline ConstIterator begin( size_t j ) const {
597  return sm_.cbegin(j);
598  }
599  //**********************************************************************************************
600 
601  //**Cbegin function*****************************************************************************
607  inline ConstIterator cbegin( size_t j ) const {
608  return sm_.cbegin(j);
609  }
610  //**********************************************************************************************
611 
612  //**End function********************************************************************************
618  inline Iterator end( size_t j ) {
619  return sm_.end(j);
620  }
621  //**********************************************************************************************
622 
623  //**End function********************************************************************************
629  inline ConstIterator end( size_t j ) const {
630  return sm_.cend(j);
631  }
632  //**********************************************************************************************
633 
634  //**Cend function*******************************************************************************
640  inline ConstIterator cend( size_t j ) const {
641  return sm_.cend(j);
642  }
643  //**********************************************************************************************
644 
645  //**Multiplication assignment operator**********************************************************
652  template< typename Other > // Data type of the right-hand side scalar
653  inline typename EnableIf< IsNumeric<Other>, SMatTransposer >::Type& operator*=( Other rhs )
654  {
655  (~sm_) *= rhs;
656  return *this;
657  }
658  //**********************************************************************************************
659 
660  //**Division assignment operator****************************************************************
669  template< typename Other > // Data type of the right-hand side scalar
670  inline typename EnableIf< IsNumeric<Other>, SMatTransposer >::Type& operator/=( Other rhs )
671  {
672  BLAZE_USER_ASSERT( rhs != Other(0), "Division by zero detected" );
673 
674  (~sm_) /= rhs;
675  return *this;
676  }
677  //**********************************************************************************************
678 
679  //**Rows function*******************************************************************************
684  inline size_t rows() const {
685  return sm_.columns();
686  }
687  //**********************************************************************************************
688 
689  //**Columns function****************************************************************************
694  inline size_t columns() const {
695  return sm_.rows();
696  }
697  //**********************************************************************************************
698 
699  //**Reset function******************************************************************************
704  inline void reset() {
705  return sm_.reset();
706  }
707  //**********************************************************************************************
708 
709  //**Insert function*****************************************************************************
722  inline Iterator insert( size_t i, size_t j, const ElementType& value ) {
723  return sm_.insert( j, i, value );
724  }
725  //**********************************************************************************************
726 
727  //**Reserve function****************************************************************************
737  inline void reserve( size_t nonzeros ) {
738  sm_.reserve( nonzeros );
739  }
740  //**********************************************************************************************
741 
742  //**Reserve function****************************************************************************
753  inline void reserve( size_t i, size_t nonzeros ) {
754  sm_.reserve( i, nonzeros );
755  }
756  //**********************************************************************************************
757 
758  //**Append function*****************************************************************************
785  void append( size_t i, size_t j, const ElementType& value, bool check=false ) {
786  sm_.append( j, i, value, check );
787  }
788  //**********************************************************************************************
789 
790  //**Finalize function***************************************************************************
803  inline void finalize( size_t j ) {
804  sm_.finalize( j );
805  }
806  //**********************************************************************************************
807 
808  //**********************************************************************************************
814  template< typename Other > // Data type of the foreign expression
815  inline bool canAlias( const Other* alias ) const
816  {
817  return sm_.canAlias( alias );
818  }
819  //**********************************************************************************************
820 
821  //**********************************************************************************************
827  template< typename Other > // Data type of the foreign expression
828  inline bool isAliased( const Other* alias ) const
829  {
830  return sm_.isAliased( alias );
831  }
832  //**********************************************************************************************
833 
834  //**CanSMPAssign function***********************************************************************
839  inline bool canSMPAssign() const
840  {
841  return sm_.canSMPAssign();
842  }
843  //**********************************************************************************************
844 
845  //**Transpose assignment of row-major sparse matrices*******************************************
856  template< typename MT2 > // Type of the right-hand side sparse matrix
857  inline void assign( const SparseMatrix<MT2,false>& rhs )
858  {
860 
861  BLAZE_INTERNAL_ASSERT( sm_.columns() == (~rhs).rows() , "Invalid number of rows" );
862  BLAZE_INTERNAL_ASSERT( sm_.rows() == (~rhs).columns() , "Invalid number of columns" );
863  BLAZE_INTERNAL_ASSERT( sm_.capacity() >= (~rhs).nonZeros(), "Capacity not sufficient" );
864 
865  typedef typename MT2::ConstIterator RhsIterator;
866 
867  const size_t m( rows() );
868  const size_t n( columns() );
869 
870  // Counting the number of elements per row
871  std::vector<size_t> columnLengths( n, 0UL );
872  for( size_t i=0UL; i<m; ++i ) {
873  for( RhsIterator element=(~rhs).begin(i); element!=(~rhs).end(i); ++element )
874  ++columnLengths[element->index()];
875  }
876 
877  // Resizing the sparse matrix
878  for( size_t j=0UL; j<n; ++j ) {
879  sm_.reserve( j, columnLengths[j] );
880  }
881 
882  // Appending the elements to the columns of the sparse matrix
883  for( size_t i=0UL; i<m; ++i ) {
884  for( RhsIterator element=(~rhs).begin(i); element!=(~rhs).end(i); ++element ) {
885  sm_.append( element->index(), i, element->value() );
886  }
887  }
888  }
889  //**********************************************************************************************
890 
891  //**Transpose assignment of column-major sparse matrices****************************************
902  template< typename MT2 > // Type of the right-hand side sparse matrix
903  inline void assign( const SparseMatrix<MT2,true>& rhs )
904  {
906 
907  BLAZE_INTERNAL_ASSERT( sm_.columns() == (~rhs).rows() , "Invalid number of rows" );
908  BLAZE_INTERNAL_ASSERT( sm_.rows() == (~rhs).columns() , "Invalid number of columns" );
909  BLAZE_INTERNAL_ASSERT( sm_.capacity() >= (~rhs).nonZeros(), "Capacity not sufficient" );
910 
911  typedef typename MT2::ConstIterator RhsIterator;
912 
913  const size_t n( columns() );
914 
915  for( size_t j=0UL; j<n; ++j ) {
916  for( RhsIterator element=(~rhs).begin(j); element!=(~rhs).end(j); ++element )
917  sm_.append( j, element->index(), element->value() );
918  finalize( j );
919  }
920  }
921  //**********************************************************************************************
922 
923  private:
924  //**Member variables****************************************************************************
925  MT& sm_;
926  //**********************************************************************************************
927 
928  //**Compile time checks*************************************************************************
934  //**********************************************************************************************
935 };
937 //*************************************************************************************************
938 
939 
940 
941 
942 //=================================================================================================
943 //
944 // GLOBAL OPERATORS
945 //
946 //=================================================================================================
947 
948 //*************************************************************************************************
956 template< typename MT // Type of the sparse matrix
957  , bool SO > // Storage order
958 inline void reset( SMatTransposer<MT,SO>& m )
959 {
960  m.reset();
961 }
963 //*************************************************************************************************
964 
965 
966 
967 
968 //=================================================================================================
969 //
970 // SUBMATRIXTRAIT SPECIALIZATIONS
971 //
972 //=================================================================================================
973 
974 //*************************************************************************************************
976 template< typename MT, bool SO >
977 struct SubmatrixTrait< SMatTransposer<MT,SO> >
978 {
980 };
982 //*************************************************************************************************
983 
984 } // namespace blaze
985 
986 #endif
MT OppositeType
Result type with opposite storage order for expression template evaluations.
Definition: SMatTransposer.h:77
MT::ConstReference ConstReference
Reference to a constant matrix value.
Definition: SMatTransposer.h:83
MT::ElementType ElementType
Resulting element type.
Definition: SMatTransposer.h:79
Constraint on the data type.
ConstIterator begin(size_t i) const
Returns an iterator to the first non-zero element of row/column i.
Definition: SMatTransposer.h:147
#define BLAZE_USER_ASSERT(expr, msg)
Run time assertion macro for user checks.In case of an invalid run time expression, the program execution is terminated. The BLAZE_USER_ASSERT macro can be disabled by setting the BLAZE_USER_ASSERT flag to zero or by defining NDEBUG during the compilation.
Definition: Assert.h:117
Iterator begin(size_t i)
Returns an iterator to the first non-zero element of row/column i.
Definition: SMatTransposer.h:131
Efficient implementation of a compressed matrix.The CompressedMatrix class template is the represent...
Definition: CompressedMatrix.h:205
#define BLAZE_CONSTRAINT_MUST_NOT_BE_COMPUTATION_TYPE(T)
Constraint on the data type.In case the given data type T is a computational expression (i...
Definition: Computation.h:118
MT::ReturnType ReturnType
Return type for expression template evaluations.
Definition: SMatTransposer.h:80
void reset()
Resets the matrix elements.
Definition: SMatTransposer.h:275
SMatTransposer< MT, SO > This
Type of this SMatTransposer instance.
Definition: SMatTransposer.h:75
bool canAlias(const Other *alias) const
Returns whether the matrix can alias with the given address alias.
Definition: SMatTransposer.h:389
BLAZE_ALWAYS_INLINE size_t nonZeros(const Matrix< MT, SO > &matrix)
Returns the total number of non-zero elements in the matrix.
Definition: Matrix.h:386
MT::ResultType TransposeType
Transpose type for expression template evaluations.
Definition: SMatTransposer.h:78
Iterator end(size_t i)
Returns an iterator just past the last non-zero element of row/column i.
Definition: SMatTransposer.h:179
EnableIf< IsNumeric< Other >, SMatTransposer >::Type & operator*=(Other rhs)
Multiplication assignment operator for the multiplication between a matrix and a scalar value ( )...
Definition: SMatTransposer.h:224
Iterator insert(size_t i, size_t j, const ElementType &value)
Inserting an element into the sparse matrix.
Definition: SMatTransposer.h:293
ConstIterator cend(size_t i) const
Returns an iterator just past the last non-zero element of row/column i.
Definition: SMatTransposer.h:211
Base class for sparse matrices.The SparseMatrix class is a base class for all sparse matrix classes...
Definition: Forward.h:107
Header file for the SparseMatrix base class.
Constraint on the data type.
MT::Iterator Iterator
Iterator over non-constant elements.
Definition: SMatTransposer.h:84
bool isAliased(const Other *alias) const
Returns whether the matrix is aliased with the given address alias.
Definition: SMatTransposer.h:402
void reserve(size_t i, size_t nonzeros)
Setting the minimum capacity of a specific row/column of the sparse matrix.
Definition: SMatTransposer.h:327
#define BLAZE_CONSTRAINT_MUST_BE_COLUMN_MAJOR_MATRIX_TYPE(T)
Constraint on the data type.In case the given data type T is not a column-major dense or sparse matri...
Definition: StorageOrder.h:161
const Element * ConstIterator
Iterator over constant elements.
Definition: CompressedMatrix.h:2482
void assign(const SparseMatrix< MT2, false > &rhs)
Implementation of the transpose assignment of a row-major sparse matrix.
Definition: SMatTransposer.h:431
MT::TransposeType ResultType
Result type for expression template evaluations.
Definition: SMatTransposer.h:76
ConstIterator end(size_t i) const
Returns an iterator just past the last non-zero element of row/column i.
Definition: SMatTransposer.h:195
CompressedMatrix< Type, false > TransposeType
Transpose type for expression template evaluations.
Definition: CompressedMatrix.h:2475
Constraints on the storage order of matrix types.
Type ElementType
Type of the sparse matrix elements.
Definition: CompressedMatrix.h:2476
void append(size_t i, size_t j, const ElementType &value, bool check=false)
Appending an element to the specified row/column of the sparse matrix.
Definition: SMatTransposer.h:359
const Type & ConstReference
Reference to a constant matrix value.
Definition: CompressedMatrix.h:2480
size_t rows() const
Returns the current number of rows of the matrix.
Definition: SMatTransposer.h:255
Header file for the EnableIf class template.
Header file for the IsNumeric type trait.
MT::ConstIterator ConstIterator
Iterator over constant elements.
Definition: SMatTransposer.h:85
void reserve(size_t nonzeros)
Setting the minimum capacity of the sparse matrix.
Definition: SMatTransposer.h:308
Expression object for the transposition of a sparse matrix.The SMatTransposer class is a wrapper obje...
Definition: Forward.h:103
#define BLAZE_CONSTRAINT_MUST_BE_ROW_MAJOR_MATRIX_TYPE(T)
Constraint on the data type.In case the given data type T is not a row-major dense or sparse matrix t...
Definition: StorageOrder.h:81
const Type & ReturnType
Return type for expression template evaluations.
Definition: CompressedMatrix.h:2477
Header file for run time assertion macros.
Header file for the submatrix trait.
SMatTransposer(MT &sm)
Constructor for the SMatTransposer class.
Definition: SMatTransposer.h:101
Substitution Failure Is Not An Error (SFINAE) class.The EnableIf class template is an auxiliary tool ...
Definition: EnableIf.h:184
MT & sm_
The sparse matrix operand.
Definition: SMatTransposer.h:499
Element * Iterator
Iterator over non-constant elements.
Definition: CompressedMatrix.h:2481
ConstReference operator()(size_t i, size_t j) const
2D-access to the matrix elements.
Definition: SMatTransposer.h:113
BLAZE_ALWAYS_INLINE void reset(const NonNumericProxy< MT > &proxy)
Resetting the represented element to the default initial values.
Definition: NonNumericProxy.h:833
ConstIterator cbegin(size_t i) const
Returns an iterator to the first non-zero element of row/column i.
Definition: SMatTransposer.h:163
const This & CompositeType
Data type for composite expression templates.
Definition: SMatTransposer.h:81
void assign(const SparseMatrix< MT2, true > &rhs)
Implementation of the transpose assignment of a column-major sparse matrix.
Definition: SMatTransposer.h:463
bool canSMPAssign() const
Returns whether the matrix can be used in SMP assignments.
Definition: SMatTransposer.h:413
void finalize(size_t i)
Finalizing the element insertion of a row/column.
Definition: SMatTransposer.h:377
EnableIf< IsNumeric< Other >, SMatTransposer >::Type & operator/=(Other rhs)
Division assignment operator for the division of a matrix by a scalar value ( ).
Definition: SMatTransposer.h:241
This ResultType
Result type for expression template evaluations.
Definition: CompressedMatrix.h:2473
Header file for basic type definitions.
MatrixAccessProxy< This > Reference
Reference to a non-constant matrix value.
Definition: CompressedMatrix.h:2479
MT::Reference Reference
Reference to a non-constant matrix value.
Definition: SMatTransposer.h:82
#define BLAZE_INTERNAL_ASSERT(expr, msg)
Run time assertion macro for internal checks.In case of an invalid run time expression, the program execution is terminated. The BLAZE_INTERNAL_ASSERT macro can be disabled by setting the BLAZE_USER_ASSERTION flag to zero or by defining NDEBUG during the compilation.
Definition: Assert.h:101
#define BLAZE_CONSTRAINT_MUST_BE_SPARSE_MATRIX_TYPE(T)
Constraint on the data type.In case the given data type T is not a sparse, N-dimensional matrix type...
Definition: SparseMatrix.h:79
size_t columns() const
Returns the current number of columns of the matrix.
Definition: SMatTransposer.h:265