Go to the documentation of this file.
11 #ifndef EIGEN_ORDERING_H
12 #define EIGEN_ORDERING_H
26 template<
typename MatrixType>
31 for (
int i = 0; i < C.rows(); i++)
33 for (
typename MatrixType::InnerIterator it(C, i); it; ++it)
41 #ifndef EIGEN_MPL2_ONLY
51 template <
typename StorageIndex>
60 template <
typename MatrixType>
73 template <
typename SrcType,
unsigned int SrcUpLo>
84 #endif // EIGEN_MPL2_ONLY
94 template <
typename StorageIndex>
101 template <
typename MatrixType>
117 template<
typename StorageIndex>
127 template <
typename MatrixType>
130 eigen_assert(
mat.isCompressed() &&
"COLAMDOrdering requires a sparse matrix in compressed mode. Call .makeCompressed() before passing it to COLAMDOrdering");
132 StorageIndex m = StorageIndex(
mat.rows());
133 StorageIndex
n = StorageIndex(
mat.cols());
134 StorageIndex nnz = StorageIndex(
mat.nonZeros());
143 for(StorageIndex i=0; i <=
n; i++) p(i) =
mat.outerIndexPtr()[i];
144 for(StorageIndex i=0; i < nnz; i++)
A(i) =
mat.innerIndexPtr()[i];
151 for (StorageIndex i = 0; i <
n; i++) perm.
indices()(p(i)) = i;
A versatible sparse matrix representation.
Map< Matrix< Scalar, Dynamic, Dynamic, ColMajor >, 0, OuterStride<> > MatrixType
const IndicesType & indices() const
PermutationMatrix< Dynamic, Dynamic, StorageIndex > PermutationType
int EIGEN_BLAS_FUNC() symm(const char *side, const char *uplo, const int *m, const int *n, const RealScalar *palpha, const RealScalar *pa, const int *lda, const RealScalar *pb, const int *ldb, const RealScalar *pbeta, RealScalar *pc, const int *ldc)
void operator()(const MatrixType &mat, PermutationType &perm)
PermutationMatrix< Dynamic, Dynamic, StorageIndex > PermutationType
void resize(Index newSize)
void operator()(const MatrixType &, PermutationType &perm)
void operator()(const SparseSelfAdjointView< SrcType, SrcUpLo > &mat, PermutationType &perm)
void operator()(const MatrixType &mat, PermutationType &perm)
void ordering_helper_at_plus_a(const MatrixType &A, MatrixType &symmat)
#define EIGEN_UNUSED_VARIABLE(var)
Matrix< StorageIndex, Dynamic, 1 > IndexVector
static bool colamd(IndexType n_row, IndexType n_col, IndexType Alen, IndexType *A, IndexType *p, double knobs[COLAMD_KNOBS], IndexType stats[COLAMD_STATS])
Computes a column ordering using the column approximate minimum degree ordering.
void minimum_degree_ordering(SparseMatrix< Scalar, ColMajor, StorageIndex > &C, PermutationMatrix< Dynamic, Dynamic, StorageIndex > &perm)
IndexType colamd_recommended(IndexType nnz, IndexType n_row, IndexType n_col)
Returns the recommended value of Alen.
static void colamd_set_defaults(double knobs[COLAMD_KNOBS])
set default parameters The use of this routine is optional.
Pseudo expression to manipulate a triangular sparse matrix as a selfadjoint matrix.
MatrixType A(a, *n, *n, *lda)
PermutationMatrix< Dynamic, Dynamic, StorageIndex > PermutationType
control_box_rst
Author(s): Christoph Rösmann
autogenerated on Wed Mar 2 2022 00:05:58