$treeview $search $mathjax
Eigen
3.2.5
$projectbrief
|
$projectbrief
|
$searchbox |
Permutation matrix. More...
Public Member Functions | |
PermutationMatrix < SizeAtCompileTime, MaxSizeAtCompileTime, IndexType > & | applyTranspositionOnTheLeft (Index i, Index j) |
PermutationMatrix < SizeAtCompileTime, MaxSizeAtCompileTime, IndexType > & | applyTranspositionOnTheRight (Index i, Index j) |
Index | cols () const |
const PermutationMatrix < SizeAtCompileTime, MaxSizeAtCompileTime, IndexType > & | derived () const |
PermutationMatrix < SizeAtCompileTime, MaxSizeAtCompileTime, IndexType > & | derived () |
Index | determinant () const |
IndicesType & | indices () |
const IndicesType & | indices () const |
Transpose< PermutationBase > | inverse () const |
PlainPermutationType | operator* (const Transpose< PermutationBase< Other > > &other) const |
PlainPermutationType | operator* (const PermutationBase< Other > &other) const |
template<typename Other > | |
PermutationMatrix & | operator= (const TranspositionsBase< Other > &tr) |
template<typename Other > | |
PermutationMatrix & | operator= (const PermutationBase< Other > &other) |
template<typename Other > | |
PermutationMatrix (const TranspositionsBase< Other > &tr) | |
template<typename Other > | |
PermutationMatrix (const MatrixBase< Other > &a_indices) | |
template<typename OtherDerived > | |
PermutationMatrix (const PermutationBase< OtherDerived > &other) | |
PermutationMatrix (int size) | |
void | resize (Index newSize) |
Index | rows () const |
void | setIdentity (Index newSize) |
void | setIdentity () |
Index | size () const |
DenseMatrixType | toDenseMatrix () const |
Transpose< PermutationBase > | transpose () const |
Friends | |
PlainPermutationType | operator* (const Transpose< PermutationBase< Other > > &other, const PermutationBase &perm) |
Permutation matrix.
SizeAtCompileTime | the number of rows/cols, or Dynamic | |
MaxSizeAtCompileTime | the maximum number of rows/cols, or Dynamic. This optional parameter defaults to SizeAtCompileTime. Most of the time, you should not have to specify it. | |
IndexType | the interger type of the indices |
This class represents a permutation matrix, internally stored as a vector of integers.
PermutationMatrix | ( | int | size | ) | [inline] |
Constructs an uninitialized permutation matrix of given size.
PermutationMatrix | ( | const PermutationBase< OtherDerived > & | other | ) | [inline] |
Copy constructor.
PermutationMatrix | ( | const MatrixBase< Other > & | a_indices | ) | [inline, explicit] |
Generic constructor from expression of the indices. The indices array has the meaning that the permutations sends each integer i to indices[i].
PermutationMatrix | ( | const TranspositionsBase< Other > & | tr | ) | [inline, explicit] |
Convert the Transpositions tr to a permutation matrix
PermutationMatrix< SizeAtCompileTime, MaxSizeAtCompileTime, IndexType > & applyTranspositionOnTheLeft | ( | Index | i, | |
Index | j | |||
) | [inline, inherited] |
Multiplies *this by the transposition on the left.
PermutationMatrix< SizeAtCompileTime, MaxSizeAtCompileTime, IndexType > & applyTranspositionOnTheRight | ( | Index | i, | |
Index | j | |||
) | [inline, inherited] |
Multiplies *this by the transposition on the right.
This is a fast operation, it only consists in swapping two indices.
Index cols | ( | void | ) | const [inline, inherited] |
Reimplemented from EigenBase< PermutationMatrix< SizeAtCompileTime, MaxSizeAtCompileTime, IndexType > >.
const PermutationMatrix< SizeAtCompileTime, MaxSizeAtCompileTime, IndexType > & derived | ( | ) | const [inline, inherited] |
PermutationMatrix< SizeAtCompileTime, MaxSizeAtCompileTime, IndexType > & derived | ( | ) | [inline, inherited] |
Index determinant | ( | ) | const [inline, inherited] |
This function is O(n
) procedure allocating a buffer of n
booleans.
IndicesType& indices | ( | ) | [inline] |
Reimplemented from PermutationBase< PermutationMatrix< SizeAtCompileTime, MaxSizeAtCompileTime, IndexType > >.
const IndicesType& indices | ( | ) | const [inline] |
const version of indices().
Reimplemented from PermutationBase< PermutationMatrix< SizeAtCompileTime, MaxSizeAtCompileTime, IndexType > >.
Referenced by SparseQR< _MatrixType, _OrderingType >::analyzePattern(), SparseLU< _MatrixType, _OrderingType >::analyzePattern(), SPQR< _MatrixType >::colsPermutation(), SparseQR< _MatrixType, _OrderingType >::factorize(), and SparseLU< _MatrixType, _OrderingType >::factorize().
Transpose<PermutationBase> inverse | ( | ) | const [inline, inherited] |
PlainPermutationType operator* | ( | const Transpose< PermutationBase< Other > > & | other | ) | const [inline, inherited] |
PlainPermutationType operator* | ( | const PermutationBase< Other > & | other | ) | const [inline, inherited] |
PermutationMatrix& operator= | ( | const TranspositionsBase< Other > & | tr | ) | [inline] |
Assignment from the Transpositions tr
PermutationMatrix& operator= | ( | const PermutationBase< Other > & | other | ) | [inline] |
Copies the other permutation into *this
void resize | ( | Index | newSize | ) | [inline, inherited] |
Resizes to given size.
Index rows | ( | void | ) | const [inline, inherited] |
Reimplemented from EigenBase< PermutationMatrix< SizeAtCompileTime, MaxSizeAtCompileTime, IndexType > >.
void setIdentity | ( | Index | newSize | ) | [inline, inherited] |
Sets *this to be the identity permutation matrix of given size.
void setIdentity | ( | ) | [inline, inherited] |
Sets *this to be the identity permutation matrix
Index size | ( | ) | const [inline, inherited] |
Reimplemented from EigenBase< PermutationMatrix< SizeAtCompileTime, MaxSizeAtCompileTime, IndexType > >.
DenseMatrixType toDenseMatrix | ( | ) | const [inline, inherited] |
Transpose<PermutationBase> transpose | ( | ) | const [inline, inherited] |
PlainPermutationType operator* | ( | const Transpose< PermutationBase< Other > > & | other, | |
const PermutationBase< PermutationMatrix< SizeAtCompileTime, MaxSizeAtCompileTime, IndexType > > & | perm | |||
) | [friend, inherited] |