Dense row-major matrix stored in a flat buffer.
Definition matrix.hpp:136
One-dimensional array of doubles with element-wise arithmetic.
Definition matrix.hpp:34
Dense row-major vectors and matrices.
Analytic Network Process computational library.
Definition eigen.hpp:14
Matrix calculus_limit(const Matrix &mat, const LimitMatrixOptions &options={})
SuperDecisions / pyanp calculus limit matrix.
Matrix compute_limit_matrix(const Matrix &mat, const LimitMatrixOptions &options={})
Dispatch to the algorithm selected by options.method.
Matrix hierarchy_formula(const Matrix &mat)
Hierarchy limit formula: normalize(sum of W^k for k=1..n-1).
Matrix limit_newhierarchy(const Matrix &mat, const LimitMatrixOptions &options={})
New Hierarchy limit calculation (pyanp limit_newhierarchy).
std::vector< std::size_t > hierarchy_nodes(const Matrix &mat)
Indices of hierarchical nodes (zero columns of W^n); pyanp hierarchy_nodes.
Matrix limit_sinks(const Matrix &mat, const LimitMatrixOptions &options={})
Limit-with-sinks calculation (pyanp limit_sinks).
void column_normalize_inplace(Matrix &mat)
In-place column_normalize.
LimitMatrixMethod
SuperDecisions / pyanp limit-matrix algorithm.
Definition limit_matrix.hpp:18
@ Calculus
Calculus Type (default SuperDecisions / pyanp).
@ NewHierarchy
New Hierarchy decomposition (pyanp limit_newhierarchy).
@ Sinks
Limit with sinks decomposition (pyanp limit_sinks).
Vector priority_from_limit(const Matrix &limit_matrix)
Row sums of the limit matrix, L1-normalized (pyanp priority_from_limit).
Matrix column_normalize(const Matrix &mat)
Column-normalizes each column by its sum (pyanp normalize).
Options for limit-matrix calculation.
Definition limit_matrix.hpp:30
std::size_t start_pow
Starting power; 0 means auto-detect (pyanp default).
Definition limit_matrix.hpp:40
bool straight_normalizer
Sinks only: if true, column-normalize the assembled result; if false, normalize the nonsink block onl...
Definition limit_matrix.hpp:52
double error
Convergence tolerance for calculus / new-hierarchy iteration.
Definition limit_matrix.hpp:34
LimitMatrixMethod method
Which limit-matrix algorithm to use.
Definition limit_matrix.hpp:32
bool use_hierarchy_formula
Use hierarchy shortcut when the matrix is a strict hierarchy.
Definition limit_matrix.hpp:38
bool with_limit
New Hierarchy only: if true, replace the lower-left corner with A·limit(B) + limit(C)·A (pyanp with_l...
Definition limit_matrix.hpp:45
std::size_t max_iters
Maximum calculus iterations.
Definition limit_matrix.hpp:36
std::size_t max_count
New Hierarchy only: max iterations for the with_limit refinement.
Definition limit_matrix.hpp:47