iRoCS Toolbox
1.1.0
|
The TriangularMatrix class is an upper triangular matrix without diagonal elements. More...
#include <TriangularMatrix.hh>
Public Types | |
typedef std::vector< T >::const_iterator | const_iterator |
typedef std::vector< T >::const_reference | const_reference |
typedef std::vector< T >::iterator | iterator |
typedef std::vector< T >::reference | reference |
typedef std::vector< T >::size_type | size_type |
typedef T | value_type |
Public Member Functions | |
TriangularMatrix () | |
TriangularMatrix (size_type width, const T &defaultVal=T()) | |
const_iterator | begin () const |
iterator | begin () |
const_iterator | end () const |
iterator | end () |
size_type | nElements () const |
reference | operator() (size_type row, size_type col) |
2dim element access. More... | |
const_reference | operator() (size_type row, size_type col) const |
const 2dim element access. More... | |
reference | operator[] (size_type index) |
1dim element access, accessing data in lexicographical order (e.g. More... | |
const_reference | operator[] (size_type index) const |
void | resizeWidth (size_type width, const T &defaultVal=T()) |
resize triangular matrix to new width. More... | |
size_type | size () const |
to be compatible with other standard containers More... | |
size_type | width () const |
The TriangularMatrix class is an upper triangular matrix without diagonal elements.
Definition at line 90 of file TriangularMatrix.hh.
typedef T svt::TriangularMatrix< T >::value_type |
Definition at line 93 of file TriangularMatrix.hh.
typedef std::vector<T>::size_type svt::TriangularMatrix< T >::size_type |
Definition at line 94 of file TriangularMatrix.hh.
typedef std::vector<T>::reference svt::TriangularMatrix< T >::reference |
Definition at line 95 of file TriangularMatrix.hh.
typedef std::vector<T>::const_reference svt::TriangularMatrix< T >::const_reference |
Definition at line 96 of file TriangularMatrix.hh.
typedef std::vector<T>::iterator svt::TriangularMatrix< T >::iterator |
Definition at line 97 of file TriangularMatrix.hh.
typedef std::vector<T>::const_iterator svt::TriangularMatrix< T >::const_iterator |
Definition at line 98 of file TriangularMatrix.hh.
|
inline |
Definition at line 100 of file TriangularMatrix.hh.
|
inline |
Definition at line 105 of file TriangularMatrix.hh.
|
inline |
resize triangular matrix to new width.
Number of resulting elements will be width*(width-1)/2
width | new width |
defaultVal | default value |
Definition at line 118 of file TriangularMatrix.hh.
Referenced by svt::Model_MC_OneVsOne< TCModel >::resizeTriangularMatrix(), and svt::TriangularMatrix< TCModel >::TriangularMatrix().
|
inline |
Definition at line 141 of file TriangularMatrix.hh.
Referenced by svt::Model_MC_OneVsOne< TCModel >::nClasses(), svt::TriangularMatrix< TCModel >::resizeWidth(), and svt::Model_MC_OneVsOne< TCModel >::saveTCTrainingInfos().
|
inline |
Definition at line 147 of file TriangularMatrix.hh.
Referenced by svt::Model_MC_OneVsOne< TCModel >::nTwoClassModels().
|
inline |
to be compatible with other standard containers
Definition at line 159 of file TriangularMatrix.hh.
|
inline |
2dim element access.
Ensure that (row < col < width), because it is an upper triangular matrix without diagonal elements
row | Matrix row (0 ... width-2) |
col | Matrix col (row+1 ... width-1) |
Definition at line 176 of file TriangularMatrix.hh.
|
inline |
const 2dim element access.
Ensure that (row < col < width), because it is an upper triangular matrix without diagonal elements
row | Matrix row (0 ... width-2) |
col | Matrix col (row+1 ... width-1) |
Definition at line 192 of file TriangularMatrix.hh.
|
inline |
1dim element access, accessing data in lexicographical order (e.g.
for a matrix with width of 4 this results in:
m[0] == m(0,1) m[1] == m(0,2) m[2] == m(0,3) m[3] == m(1,2) m[4] == m(1,3) m[5] == m(2,3)
index | index (0 ... size()-1) |
Definition at line 214 of file TriangularMatrix.hh.
|
inline |
Definition at line 219 of file TriangularMatrix.hh.
|
inline |
Definition at line 225 of file TriangularMatrix.hh.
Referenced by svt::Model_MC_OneVsOne< TCModel >::collectSupportVectorsFromTCModels(), and svt::Model_MC_OneVsOne< TCModel >::saveTrainingInfoStatistics().
|
inline |
Definition at line 226 of file TriangularMatrix.hh.
|
inline |
Definition at line 227 of file TriangularMatrix.hh.
Referenced by svt::Model_MC_OneVsOne< TCModel >::collectSupportVectorsFromTCModels(), and svt::Model_MC_OneVsOne< TCModel >::saveTrainingInfoStatistics().
|
inline |
Definition at line 228 of file TriangularMatrix.hh.