|
Medial Code Documentation
|
Represents a sequence of transpositions (row/column interchange) More...
#include <Transpositions.h>
Public Types | |
| typedef TranspositionsBase< Transpositions > | Base |
| typedef Traits::IndicesType | IndicesType |
| typedef IndicesType::Scalar | StorageIndex |
Public Types inherited from Eigen::TranspositionsBase< Transpositions< SizeAtCompileTime, MaxSizeAtCompileTime, _StorageIndex > > | |
| typedef Traits::IndicesType | IndicesType |
| typedef IndicesType::Scalar | StorageIndex |
| typedef Eigen::Index | Index |
Public Member Functions | |
| template<typename OtherDerived > | |
| Transpositions (const TranspositionsBase< OtherDerived > &other) | |
| Copy constructor. | |
| template<typename Other > | |
| Transpositions (const MatrixBase< Other > &indices) | |
| Generic constructor from expression of the transposition indices. | |
| template<typename OtherDerived > | |
| Transpositions & | operator= (const TranspositionsBase< OtherDerived > &other) |
Copies the other transpositions into *this. | |
| Transpositions (Index size) | |
| Constructs an uninitialized permutation matrix of given size. | |
| EIGEN_DEVICE_FUNC const IndicesType & | indices () const |
| const version of indices(). | |
| EIGEN_DEVICE_FUNC IndicesType & | indices () |
Public Member Functions inherited from Eigen::TranspositionsBase< Transpositions< SizeAtCompileTime, MaxSizeAtCompileTime, _StorageIndex > > | |
| EIGEN_DEVICE_FUNC Transpositions< SizeAtCompileTime, MaxSizeAtCompileTime, _StorageIndex > & | derived () |
| EIGEN_DEVICE_FUNC const Transpositions< SizeAtCompileTime, MaxSizeAtCompileTime, _StorageIndex > & | derived () const |
| Transpositions< SizeAtCompileTime, MaxSizeAtCompileTime, _StorageIndex > & | operator= (const TranspositionsBase< OtherDerived > &other) |
Copies the other transpositions into *this. | |
| EIGEN_DEVICE_FUNC Index | size () const |
| EIGEN_DEVICE_FUNC Index | rows () const |
| EIGEN_DEVICE_FUNC Index | cols () const |
| EIGEN_DEVICE_FUNC const StorageIndex & | coeff (Index i) const |
| Direct access to the underlying index vector. | |
| StorageIndex & | coeffRef (Index i) |
| Direct access to the underlying index vector. | |
| const StorageIndex & | operator() (Index i) const |
| Direct access to the underlying index vector. | |
| StorageIndex & | operator() (Index i) |
| Direct access to the underlying index vector. | |
| const StorageIndex & | operator[] (Index i) const |
| Direct access to the underlying index vector. | |
| StorageIndex & | operator[] (Index i) |
| Direct access to the underlying index vector. | |
| EIGEN_DEVICE_FUNC const IndicesType & | indices () const |
| const version of indices(). | |
| EIGEN_DEVICE_FUNC IndicesType & | indices () |
| void | resize (Index newSize) |
| Resizes to given size. | |
| void | setIdentity () |
Sets *this to represents an identity transformation. | |
| Transpose< TranspositionsBase > | inverse () const |
| Transpose< TranspositionsBase > | transpose () const |
Protected Attributes | |
| IndicesType | m_indices |
Represents a sequence of transpositions (row/column interchange)
| SizeAtCompileTime | the number of transpositions, or Dynamic |
| MaxSizeAtCompileTime | the maximum number of transpositions, or Dynamic. This optional parameter defaults to SizeAtCompileTime. Most of the time, you should not have to specify it. |
This class represents a permutation transformation as a sequence of n transpositions ![$[T_{n-1} \ldots T_{i} \ldots T_{0}]$](form_32.png)
indices. Each transposition 

i and indices[i] of the matrix M. A transposition applied on the right (e.g., 
Compared to the class PermutationMatrix, such a sequence of transpositions is what is computed during a decomposition with pivoting, and it is faster when applying the permutation in-place.
To apply a sequence of transpositions to a matrix, simply use the operator * as in the following example:
In this example, we detect that the matrix appears on both side, and so the transpositions are applied in-place without any temporary or extra copy.
|
inline |