cisst-saw
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
vctDynamicMatrix.h
Go to the documentation of this file.
1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 /* ex: set filetype=cpp softtabstop=4 shiftwidth=4 tabstop=4 cindent expandtab: */
3 
4 /*
5 
6  Author(s): Ofri Sadowsky, Anton Deguet
7  Created on: 2004-07-01
8 
9  (C) Copyright 2004-2007 Johns Hopkins University (JHU), All Rights
10  Reserved.
11 
12 --- begin cisst license - do not edit ---
13 
14 This software is provided "as is" under an open source license, with
15 no warranty. The complete license can be found in license.txt and
16 http://www.cisst.org/cisst/license.txt.
17 
18 --- end cisst license ---
19 */
20 
21 #pragma once
22 #ifndef _vctDynamicMatrix_h
23 #define _vctDynamicMatrix_h
24 
34 
135 template <class _elementType>
136 class vctDynamicMatrix : public vctDynamicMatrixBase<vctDynamicMatrixOwner<_elementType>, _elementType>
137 {
138 
139  friend class vctReturnDynamicMatrix<_elementType>;
140 
141 public:
142  VCT_CONTAINER_TRAITS_TYPEDEFS(_elementType);
143  enum {DIMENSION = 2};
145 
148 
149 
152  // The default initialization of vctDynamicMatrixOwner is empty.
153  {}
154 
155 
156  /* Constructor: Create a matrix of the specified size. Elements
157  initialized with default constructor. The storage order can be
158  either #VCT_ROW_MAJOR or #VCT_COL_MAJOR. */
161  this->SetSize(rows, cols, storageOrder);
162  }
163 
164  vctDynamicMatrix(const nsize_type & matrixSize, bool storageOrder = VCT_DEFAULT_STORAGE) {
165  this->SetSize(matrixSize, storageOrder);
166  }
168 
173  vctDynamicMatrix(size_type rows, size_type cols, value_type value, bool storageOrder = VCT_DEFAULT_STORAGE) {
174  this->SetSize(rows, cols, storageOrder);
175  this->SetAll(value);
176  }
177 
178  vctDynamicMatrix(const nsize_type & matrixSize, value_type value, bool storageOrder = VCT_DEFAULT_STORAGE) {
179  this->SetSize(matrixSize, storageOrder);
180  this->SetAll(value);
181  }
183 
189 
190 
195  vctDynamicMatrix(const ThisType & otherMatrix):
196  BaseType()
197  {
198  this->SetSize(otherMatrix.rows(), otherMatrix.cols(), otherMatrix.StorageOrder());
199  this->Assign(otherMatrix);
200  }
201 
202 
206  template <class __matrixOwnerType, typename __otherMatrixElementType>
208  this->SetSize(otherMatrix.rows(), otherMatrix.cols(), storageOrder);
209  this->Assign(otherMatrix);
210  }
211 
212 
217  template <class __matrixOwnerType>
219  this->SetSize(otherMatrix.rows(), otherMatrix.cols(), otherMatrix.StorageOrder());
220  this->Assign(otherMatrix);
221  }
222 
223 
229  template <class __matrixOwnerType, typename __otherMatrixElementType>
231  this->SetSize(otherMatrix.rows(), otherMatrix.cols(), otherMatrix.StorageOrder());
232  this->Assign(otherMatrix);
233  }
234 
235 
237  template <size_type __rows, size_type __cols,
238  stride_type __rowStride, stride_type __colStride,
239  class __elementType, class __dataPtrType>
240  explicit vctDynamicMatrix(const vctFixedSizeConstMatrixBase<__rows, __cols,
241  __rowStride, __colStride,
242  __elementType, __dataPtrType> & other) {
243  this->ForceAssign(other);
244  }
245 
246 
254  template <class __matrixOwnerType, typename __elementType>
256  this->SetSize(otherMatrix.rows(), otherMatrix.cols());
257  this->Assign(otherMatrix);
258  return *this;
259  }
260 
261 
267  ThisType & operator = (const ThisType & otherMatrix) {
268  this->SetSize(otherMatrix.rows(), otherMatrix.cols(), otherMatrix.StorageOrder());
269  this->Assign(otherMatrix);
270  return *this;
271  }
272 
276  template <size_type __rows, size_type __cols,
277  stride_type __rowStride, stride_type __colStride,
278  class __elementType, class __dataPtrType>
280  __rowStride, __colStride,
281  __elementType, __dataPtrType> & other) {
282  this->ForceAssign(other);
283  return *this;
284  }
285 
286 
297 
299  inline ThisType & operator = (const value_type & value) {
300  this->SetAll(value);
301  return *this;
302  }
303 
304  // documented in base class
305  template <class __matrixOwnerType, typename __elementType>
307  this->SetSize(other.sizes(), other.StorageOrder());
308  this->Assign(other);
309  return *this;
310  }
311 
312  // documented in base class
313  template <size_type __rows, size_type __cols,
314  stride_type __rowStride, stride_type __colStride,
315  class __elementType, class __dataPtrType>
316  inline ThisType & ForceAssign(const vctFixedSizeConstMatrixBase<__rows, __cols,
317  __rowStride, __colStride,
318  __elementType, __dataPtrType> & other) {
319  this->SetSize(other.sizes(), other.StorageOrder());
320  this->Assign(other);
321  return *this;
322  }
323 
339  this->resize(nsize_type(rows, cols));
340  }
341 
342  void resize(const nsize_type & newSizes) {
343  if (newSizes == this->sizes())
344  return;
345 
346  const bool isRowMajor = this->IsRowMajor();
347  ThisType newData(newSizes, isRowMajor);
348  const nsize_type corner(0);
349  nsize_type minSizes;
350  minSizes.ElementwiseMinOf(this->sizes(), newSizes);
351  vctDynamicConstMatrixRef<value_type> myDataMinSpaceRef(*this, corner, minSizes);
352  vctDynamicMatrixRef<value_type> newDataMinSpaceRef(newData, corner, minSizes);
353  newDataMinSpaceRef.Assign(myDataMinSpaceRef);
354  this->Matrix.Disown();
355  this->Matrix.Own(newSizes, isRowMajor, newData.Matrix.Release());
356  }
358 
364  void SetSize(size_type rows, size_type cols, bool storageOrder) {
365  this->Matrix.SetSize(rows, cols, storageOrder);
366  }
367 
368  void SetSize(const nsize_type & matrixSize, bool storageOrder) {
369  this->Matrix.SetSize(matrixSize, storageOrder);
370  }
371 
373  this->Matrix.SetSize(rows, cols, this->StorageOrder());
374  }
375 
376  void SetSize(const nsize_type & matrixSize) {
377  this->Matrix.SetSize(matrixSize, this->StorageOrder());
378  }
380 
382  void DeSerializeRaw(std::istream & inputStream)
383  {
384  // get and set size
385  size_type myRows = 0;
386  size_type myCols = 0;
387  cmnDeSerializeSizeRaw(inputStream, myRows);
388  cmnDeSerializeSizeRaw(inputStream, myCols);
389  this->SetSize(myRows, myCols);
390 
391  // get data
392  size_type indexRow, indexCol;
393  for (indexRow = 0; indexRow < myRows; ++indexRow) {
394  for (indexCol = 0; indexCol < myCols; ++indexCol) {
395  cmnDeSerializeRaw(inputStream, this->Element(indexRow, indexCol));
396  }
397  }
398  }
399 
400 };
401 
402 
418 template <class _elementType>
419 class vctReturnDynamicMatrix : public vctDynamicMatrix<_elementType> {
420 public:
423 
424  VCT_CONTAINER_TRAITS_TYPEDEFS(_elementType);
425 
426  explicit vctReturnDynamicMatrix(const BaseType & other)
427  {
428  BaseType & nonConstOther = const_cast<BaseType &>(other);
429  // if we don't save it in a variable, it will be destroyed in the Release operation
430  const size_type rows = other.rows();
431  const size_type cols = other.cols();
432  const bool storageOrder = other.StorageOrder();
433  this->Matrix.Own(rows, cols, storageOrder, nonConstOther.Matrix.Release());
434  }
435 };
436 
437 
438 // implementation of the special copy constuctor of vctDynamicMatrix
439 template <class _elementType>
441  vctReturnDynamicMatrix<_elementType> & nonConstOther =
442  const_cast< vctReturnDynamicMatrix<_elementType> & >(other);
443  // if we don't save it in a variable, it will be destroyed in the Release operation
444  const size_type rows = other.rows();
445  const size_type cols = other.cols();
446  const bool storageOrder = other.StorageOrder();
447  this->Matrix.Own(rows, cols, storageOrder, nonConstOther.Matrix.Release());
448 }
449 
450 
451 // implementation of the special assignment operator from vctReturnDynamicMatrix to vctDynamicMatrix
452 template <class _elementType>
455  vctReturnDynamicMatrix<_elementType> & nonConstOther =
456  const_cast< vctReturnDynamicMatrix<_elementType> & >(other);
457  // if we don't save it in a variable, it will be destroyed in the Release operation
458  const size_type rows = other.rows();
459  const size_type cols = other.cols();
460  const bool storageOrder = other.StorageOrder();
461  this->Matrix.Disown();
462  this->Matrix.Own(rows, cols, storageOrder, nonConstOther.Matrix.Release());
463  return *this;
464 }
465 
466 
474 template <class _matrixOwnerType1, class _matrixOwnerType2, class _elementType>
478  typedef _elementType value_type;
479  vctDynamicMatrix<value_type> resultStorage(inputMatrix1);
480  resultStorage.Add(inputMatrix2);
481  return vctReturnDynamicMatrix<value_type>(resultStorage);
482 }
483 
484 /* documented above */
485 template <class _matrixOwnerType1, class _matrixOwnerType2, class _elementType>
489  typedef _elementType value_type;
490  vctDynamicMatrix<value_type> resultStorage(inputMatrix1);
491  resultStorage.Subtract(inputMatrix2);
492  return vctReturnDynamicMatrix<value_type>(resultStorage);
493 }
495 
496 
497 
506 template <class _matrixOwnerType, class _elementType>
509  const _elementType & inputScalar) {
510  typedef _elementType value_type;
511  vctDynamicMatrix<value_type> resultStorage(inputMatrix);
512  resultStorage.Add(inputScalar);
513  return vctReturnDynamicMatrix<value_type>(resultStorage);
514 }
515 
516 /* documented above */
517 template <class _matrixOwnerType, class _elementType>
520  const _elementType & inputScalar) {
521  typedef _elementType value_type;
522  vctDynamicMatrix<value_type> resultStorage(inputMatrix);
523  resultStorage.Subtract(inputScalar);
524  return vctReturnDynamicMatrix<value_type>(resultStorage);
525 }
526 
527 /* documented above */
528 template <class _matrixOwnerType, class _elementType>
531  const _elementType & inputScalar) {
532  typedef _elementType value_type;
533  vctDynamicMatrix<value_type> resultStorage(inputMatrix);
534  resultStorage.Multiply(inputScalar);
535  return vctReturnDynamicMatrix<value_type>(resultStorage);
536 }
537 
538 /* documented above */
539 template <class _matrixOwnerType, class _elementType>
542  const _elementType & inputScalar) {
543  typedef _elementType value_type;
544  vctDynamicMatrix<value_type> resultStorage(inputMatrix);
545  resultStorage.Divide(inputScalar);
546  return vctReturnDynamicMatrix<value_type>(resultStorage);
547 }
549 
550 
551 
560 template <class _matrixOwnerType, class _elementType>
562 operator + (const _elementType & inputScalar,
564  typedef _elementType value_type;
565  vctDynamicMatrix<value_type> resultStorage(inputMatrix.rows(), inputMatrix.cols());
566  resultStorage.SumOf(inputScalar, inputMatrix);
567  return vctReturnDynamicMatrix<value_type>(resultStorage);
568 }
569 
570 /* documented above */
571 template <class _matrixOwnerType, class _elementType>
573 operator - (const _elementType & inputScalar,
575  typedef _elementType value_type;
576  vctDynamicMatrix<value_type> resultStorage(inputMatrix.rows(), inputMatrix.cols());
577  resultStorage.DifferenceOf(inputScalar, inputMatrix);
578  return vctReturnDynamicMatrix<value_type>(resultStorage);
579 }
580 
581 /* documented above */
582 template <class _matrixOwnerType, class _elementType>
584 operator * (const _elementType & inputScalar,
586  typedef _elementType value_type;
587  vctDynamicMatrix<value_type> resultStorage(inputMatrix.rows(), inputMatrix.cols());
588  resultStorage.ProductOf(inputScalar, inputMatrix);
589  return vctReturnDynamicMatrix<value_type>(resultStorage);
590 }
591 
592 /* documented above */
593 template <class _matrixOwnerType, class _elementType>
595 operator / (const _elementType & inputScalar,
597  typedef _elementType value_type;
598  vctDynamicMatrix<value_type> resultStorage(inputMatrix.rows(), inputMatrix.cols());
599  resultStorage.RatioOf(inputScalar, inputMatrix);
600  return vctReturnDynamicMatrix<value_type>(resultStorage);
601 }
603 
604 
611 template <class _matrixOwnerType, class _elementType>
614  typedef _elementType value_type;
615  vctDynamicMatrix<value_type> resultStorage(inputMatrix.rows(), inputMatrix.cols());
616  resultStorage.NegationOf(inputMatrix);
617  return vctReturnDynamicMatrix<value_type>(resultStorage);
618 }
620 
621 
622 
623 #ifndef DOXYGEN
624 template <class _matrixOwnerType1, class _matrixOwnerType2, class _elementType>
628  typedef _elementType value_type;
629  vctDynamicMatrix<value_type> resultStorage(inputMatrix1.rows(), inputMatrix2.cols());
630  resultStorage.ProductOf(inputMatrix1, inputMatrix2);
631  return vctReturnDynamicMatrix<value_type>(resultStorage);
632 }
633 
634 
635 template <class _matrixOwnerType, class _vectorOwnerType, class _elementType>
639  typedef _elementType value_type;
640  vctDynamicVector<value_type> resultStorage(inputMatrix.rows());
641  resultStorage.ProductOf(inputMatrix, inputVector);
642  return vctReturnDynamicVector<value_type>(resultStorage);
643 }
644 
645 
646 template <class _vectorOwnerType, class _matrixOwnerType, class _elementType>
650  typedef _elementType value_type;
651  vctDynamicVector<value_type> resultStorage(inputMatrix.cols());
652  resultStorage.ProductOf(inputVector, inputMatrix);
653  return vctReturnDynamicVector<value_type>(resultStorage);
654 }
655 
656 
657 
658 /*
659  Methods declared previously and implemented here because they require vctReturnDynamicMatrix
660 */
661 
662 
663 /* documented in class vctDynamicConstMatrixBase */
664 template <class _matrixOwnerType, class _elementType>
667  typedef _elementType value_type;
668  vctDynamicMatrix<value_type> resultStorage(this->rows(), this->cols());
671  Run(resultStorage, *this);
672  return vctReturnDynamicMatrix<value_type>(resultStorage);
673 }
674 
675 /* documented in class vctDynamicConstMatrixBase */
676 template <class _matrixOwnerType, class _elementType>
679  typedef _elementType value_type;
680  vctDynamicMatrix<value_type> resultStorage(this->rows(), this->cols());
683  Run(resultStorage, *this);
684  return vctReturnDynamicMatrix<value_type>(resultStorage);
685 }
686 
687 /* documented in class vctDynamicConstMatrixBase */
688 template <class _matrixOwnerType, class _elementType>
691  typedef _elementType value_type;
692  vctDynamicMatrix<value_type> resultStorage(this->rows(), this->cols());
695  Run(resultStorage, *this);
696  return vctReturnDynamicMatrix<value_type>(resultStorage);
697 }
698 
699 /* documented in class vctDynamicConstMatrixBase */
700 template <class _matrixOwnerType, class _elementType>
703  typedef _elementType value_type;
704  vctDynamicMatrix<value_type> resultStorage(this->rows(), this->cols());
707  Run(resultStorage, *this);
708  return vctReturnDynamicMatrix<value_type>(resultStorage);
709 }
710 
711 /* documented in class vctDynamicConstMatrixBase */
712 template <class _matrixOwnerType, class _elementType>
715  vctDynamicMatrix<value_type> resultStorage(size, size);
716  resultStorage.SetAll(_elementType(0));
717  resultStorage.Diagonal().SetAll(_elementType(1));
718  return vctReturnDynamicMatrix<value_type>(resultStorage);
719 }
720 
721 /* Documented in class vctDynamicConstMatrixBase */
722 template <class _matrixOwnerType, class __matrixOwnerType, class _elementType,
723  class _elementOperationType>
727  vctDynamicMatrix<bool> result(matrix1.rows(), matrix1.cols());
729  MoMiMi<_elementOperationType>::Run(result, matrix1, matrix2);
730  return vctReturnDynamicMatrix<bool>(result);
731 }
732 
733 /* documented in class vctDynamicConstMatrixBase */
734 template <class _matrixOwnerType, class _elementType,
735  class _elementOperationType>
738  const _elementType & scalar) {
739  vctDynamicMatrix<bool> result(matrix.rows(), matrix.cols());
741  MoMiSi<_elementOperationType>::Run(result, matrix, scalar);
742  return vctReturnDynamicMatrix<bool>(result);
743 }
744 
745 #endif // DOXYGEN
746 
747 
748 #endif // _vctDynamicMatrix_h
749 
A template for a fixed size matrix with fixed spacing in memory.
Definition: vctFixedSizeConstMatrixBase.h:103
vctDynamicMatrix< _elementType > BaseType
Definition: vctDynamicMatrix.h:422
ThisType & Subtract(const vctDynamicConstMatrixBase< __matrixOwnerType, _elementType > &otherMatrix)
Definition: vctDynamicMatrixBase.h:878
Definition: vctDynamicMatrixBase.h:42
vctDynamicMatrix(const vctDynamicConstMatrixBase< __matrixOwnerType, __otherMatrixElementType > &otherMatrix)
Definition: vctDynamicMatrix.h:230
vctDynamicMatrix(const vctDynamicConstMatrixBase< __matrixOwnerType, __otherMatrixElementType > &otherMatrix, bool storageOrder)
Definition: vctDynamicMatrix.h:207
pointer Release()
Definition: vctDynamicMatrixOwner.h:192
vctReturnDynamicMatrix< _elementType > operator+(const vctDynamicConstMatrixBase< _matrixOwnerType1, _elementType > &inputMatrix1, const vctDynamicConstMatrixBase< _matrixOwnerType2, _elementType > &inputMatrix2)
Definition: vctDynamicMatrix.h:476
vctReturnDynamicMatrix< bool > vctDynamicMatrixElementwiseCompareScalar(const vctDynamicConstMatrixBase< _matrixOwnerType, _elementType > &matrix, const _elementType &scalar)
Definition: vctDynamicMatrix.h:737
Definition: vctDynamicMatrixLoopEngines.h:168
static void Run(_outputMatrixType &outputMatrix, const _inputMatrixType &inputMatrix, const _inputScalarType inputScalar)
Definition: vctDynamicMatrixLoopEngines.h:343
MatrixReturnType Negation(void) const
Definition: vctDynamicMatrix.h:678
void cmnDeSerializeSizeRaw(std::istream &inputStream, size_t &data)
Definition: cmnDeSerializer.h:96
vctDynamicMatrix(const vctDynamicConstMatrixBase< __matrixOwnerType, value_type > &otherMatrix)
Definition: vctDynamicMatrix.h:218
vctDynamicMatrixBase< vctDynamicMatrixOwner< _elementType >, _elementType > BaseType
Definition: vctDynamicMatrix.h:146
A matrix object of dynamic size.
Definition: vctDynamicMatrix.h:136
ThisType & Add(const vctDynamicConstMatrixBase< __matrixOwnerType, _elementType > &otherMatrix)
Definition: vctDynamicMatrixBase.h:869
OwnerType Matrix
Definition: vctDynamicConstMatrixBase.h:167
vctDynamicMatrix< _elementType > ThisType
Definition: vctDynamicMatrix.h:147
size_t size_type
Definition: vctContainerTraits.h:35
ThisType & ForceAssign(const vctDynamicConstMatrixBase< __matrixOwnerType, __elementType > &other)
Definition: vctDynamicMatrix.h:306
bool StorageOrder(void) const
Definition: vctDynamicConstMatrixBase.h:656
const bool VCT_DEFAULT_STORAGE
Definition: vctForwardDeclarations.h:49
vctReturnDynamicMatrix< _elementType > operator-(const vctDynamicConstMatrixBase< _matrixOwnerType1, _elementType > &inputMatrix1, const vctDynamicConstMatrixBase< _matrixOwnerType2, _elementType > &inputMatrix2)
Definition: vctDynamicMatrix.h:487
void SetSize(const nsize_type &matrixSize)
Definition: vctDynamicMatrix.h:376
vctDynamicMatrix()
Definition: vctDynamicMatrix.h:151
Dynamic matrix referencing existing memory.
Definition: vctDynamicMatrixRef.h:74
MatrixReturnType Ceil(void) const
Definition: vctDynamicMatrix.h:702
vctDynamicMatrix(const nsize_type &matrixSize, value_type value, bool storageOrder=VCT_DEFAULT_STORAGE)
Definition: vctDynamicMatrix.h:178
void resize(size_type rows, size_type cols)
Definition: vctDynamicMatrix.h:338
ThisType & ProductOf(const vctDynamicConstMatrixBase< __matrixOwnerType, _elementType > &matrix, const value_type scalar)
Definition: vctDynamicMatrixBase.h:971
Definition: vctDynamicConstMatrixBase.h:77
void DeSerializeRaw(std::istream &inputStream)
Definition: vctDynamicMatrix.h:382
vctReturnDynamicMatrix(const BaseType &other)
Definition: vctDynamicMatrix.h:426
Declaration of vctDynamicVector.
Definition: vctDynamicMatrix.h:419
void SetSize(const nsize_type &matrixSize, bool storageOrder)
Definition: vctDynamicMatrix.h:368
VCT_CONTAINER_TRAITS_TYPEDEFS(_elementType)
ThisType & SumOf(const vctDynamicConstMatrixBase< __matrixOwnerType1, _elementType > &matrix1, const vctDynamicConstMatrixBase< __matrixOwnerType2, _elementType > &matrix2)
Definition: vctDynamicMatrixBase.h:791
Dynamic matrix referencing existing memory (const)
Definition: vctDynamicConstMatrixRef.h:79
value_type SetAll(const value_type value)
Definition: vctDynamicMatrixBase.h:452
Definition: vctDynamicVector.h:392
Declaration of vctDynamicMatrixOwner.
void cmnDeSerializeRaw(std::istream &inputStream, _elementType &data)
Definition: cmnDeSerializer.h:82
size_type rows() const
Definition: vctDynamicConstMatrixBase.h:238
vctReturnDynamicMatrix< _elementType > operator/(const vctDynamicConstMatrixBase< _matrixOwnerType, _elementType > &inputMatrix, const _elementType &inputScalar)
Definition: vctDynamicMatrix.h:541
size_type cols() const
Definition: vctDynamicConstMatrixBase.h:243
static void Run(_outputMatrixType &outputMatrix, const _input1MatrixType &input1Matrix, const _input2MatrixType &input2Matrix)
Definition: vctDynamicMatrixLoopEngines.h:92
Declaration of vctDynamicMatrixBase.
VCT_CONTAINER_TRAITS_TYPEDEFS(_elementType)
vctDynamicMatrix(size_type rows, size_type cols, value_type value, bool storageOrder=VCT_DEFAULT_STORAGE)
Definition: vctDynamicMatrix.h:173
vctReturnDynamicMatrix< bool > vctDynamicMatrixElementwiseCompareMatrix(const vctDynamicConstMatrixBase< _matrixOwnerType, _elementType > &matrix1, const vctDynamicConstMatrixBase< _matrixOwnerType, _elementType > &matrix2)
Definition: vctDynamicMatrix.h:725
bool IsRowMajor(void) const
Definition: vctDynamicConstMatrixBase.h:635
Declaration of vctDynamicMatrixRef.
void resize(const nsize_type &newSizes)
Definition: vctDynamicMatrix.h:342
ThisType & DifferenceOf(const vctDynamicConstMatrixBase< __matrixOwnerType1, _elementType > &matrix1, const vctDynamicConstMatrixBase< __matrixOwnerType2, _elementType > &matrix2)
Definition: vctDynamicMatrixBase.h:801
void SetSize(size_type rows, size_type cols, bool storageOrder)
Definition: vctDynamicMatrix.h:364
VCT_NARRAY_TRAITS_TYPEDEFS(DIMENSION)
ThisType & Divide(const value_type scalar)
Definition: vctDynamicMatrixBase.h:1128
vctDynamicMatrix(const nsize_type &matrixSize, bool storageOrder=VCT_DEFAULT_STORAGE)
Definition: vctDynamicMatrix.h:164
reference Element(size_type rowIndex, size_type colIndex)
Definition: vctDynamicMatrixBase.h:214
MatrixReturnType Floor(void) const
Definition: vctDynamicMatrix.h:690
vctReturnDynamicMatrix< _elementType > operator*(const vctDynamicConstMatrixBase< _matrixOwnerType, _elementType > &inputMatrix, const _elementType &inputScalar)
Definition: vctDynamicMatrix.h:530
value_type SetAll(const value_type value)
Definition: vctDynamicVectorBase.h:209
ThisType & Assign(const vctDynamicConstMatrixBase< __matrixOwnerType, value_type > &other)
Definition: vctDynamicMatrixBase.h:509
Definition: vctDynamicMatrix.h:143
ThisType & RatioOf(const vctDynamicConstMatrixBase< __matrixOwnerType, _elementType > &matrix, const value_type scalar)
Definition: vctDynamicMatrixBase.h:981
static MatrixReturnType Eye(size_type size)
Definition: vctDynamicMatrix.h:714
ptrdiff_t stride_type
Definition: vctContainerTraits.h:37
ThisType & ForceAssign(const vctFixedSizeConstMatrixBase< __rows, __cols, __rowStride, __colStride, __elementType, __dataPtrType > &other)
Definition: vctDynamicMatrix.h:316
Definition: vctDynamicConstVectorBase.h:77
vctDynamicMatrix(size_type rows, size_type cols, bool storageOrder=VCT_DEFAULT_STORAGE)
Definition: vctDynamicMatrix.h:160
MatrixReturnType Abs(void) const
Definition: vctDynamicMatrix.h:666
vctDynamicMatrix(const vctFixedSizeConstMatrixBase< __rows, __cols, __rowStride, __colStride, __elementType, __dataPtrType > &other)
Definition: vctDynamicMatrix.h:240
DiagonalRefType Diagonal(void)
Definition: vctDynamicMatrixBase.h:239
ThisType & Multiply(const value_type scalar)
Definition: vctDynamicMatrixBase.h:1120
vctDynamicMatrix(const ThisType &otherMatrix)
Definition: vctDynamicMatrix.h:195
const nsize_type & sizes(void) const
Definition: vctDynamicConstMatrixBase.h:233
ThisType & operator=(const vctDynamicConstMatrixBase< __matrixOwnerType, __elementType > &otherMatrix)
Definition: vctDynamicMatrix.h:255
ThisType & ProductOf(const vctDynamicConstVectorBase< __vectorOwnerType, _elementType > &vector, const value_type scalar)
Definition: vctDynamicVectorBase.h:941
ThisType & NegationOf(const vctDynamicConstMatrixBase< __matrixOwnerType, _elementType > &otherMatrix)
Definition: vctDynamicMatrixBase.h:1222
void SetSize(size_type rows, size_type cols)
Definition: vctDynamicMatrix.h:372