File matrix_c_contiguous_numeric.hpp

namespace boosting
template<typename T>
class NumericCContiguousMatrix : public DenseMatrixDecorator<AllocatedCContiguousView<T>>
#include <matrix_c_contiguous_numeric.hpp>

A two-dimensional matrix that provides random access to a fixed number of values stored in a C-contiguous array.

Template Parameters:

T – The type of the values that are stored in the matrix

Public Functions

NumericCContiguousMatrix(uint32 numRows, uint32 numCols, bool init = false)
Parameters:
  • numRows – The number of rows in the matrix

  • numCols – The number of columns in the matrix

  • init – True, if all elements in the matrix should be value-initialized, false otherwise

void addToRowFromSubset(uint32 row, typename View<T>::const_iterator begin, typename View<T>::const_iterator end, CompleteIndexVector::const_iterator indicesBegin, CompleteIndexVector::const_iterator indicesEnd)

Adds all values in another vector to certain elements, whose positions are given as a CompleteIndexVector, at a specific row of this matrix.

Parameters:
  • row – The row

  • begin – An iterator to the beginning of the vector

  • end – An iterator to the end of the vector

  • indicesBegin – An iterator to the beginning of the indices

  • indicesEnd – An iterator to the end of the indices

void addToRowFromSubset(uint32 row, typename View<T>::const_iterator begin, typename View<T>::const_iterator end, PartialIndexVector::const_iterator indicesBegin, PartialIndexVector::const_iterator indicesEnd)

Adds all values in another vector to certain elements, whose positions are given as a PartialIndexVector, at a specific row of this matrix.

Parameters:
  • row – The row

  • begin – An iterator to the beginning of the vector

  • end – An iterator to the end of the vector

  • indicesBegin – An iterator to the beginning of the indices

  • indicesEnd – An iterator to the end of the indices

void removeFromRowFromSubset(uint32 row, typename View<T>::const_iterator begin, typename View<T>::const_iterator end, CompleteIndexVector::const_iterator indicesBegin, CompleteIndexVector::const_iterator indicesEnd)

Subtracts all values in another vector from certain elements, whose positions are given as a CompleteIndexVector, at a specific row of this matrix.

Parameters:
  • row – The row

  • begin – An iterator to the beginning of the vector

  • end – An iterator to the end of the vector

  • indicesBegin – An iterator to the beginning of the indices

  • indicesEnd – An iterator to the end of the indices

void removeFromRowFromSubset(uint32 row, typename View<T>::const_iterator begin, typename View<T>::const_iterator end, PartialIndexVector::const_iterator indicesBegin, PartialIndexVector::const_iterator indicesEnd)

Subtracts all values in another vector from certain elements, whose positions are given as a PartialIndexVector, at a specific row of this matrix.

Parameters:
  • row – The row

  • begin – An iterator to the beginning of the vector

  • end – An iterator to the end of the vector

  • indicesBegin – An iterator to the beginning of the indices

  • indicesEnd – An iterator to the end of the indices