10 #ifndef EIGEN_SPARSELU_UTILS_H 11 #define EIGEN_SPARSELU_UTILS_H 14 #include "./InternalHeaderCheck.h" 22 template <
typename Scalar,
typename StorageIndex>
25 nnzU = (glu.xusub)(n);
26 Index nsuper = (glu.supno)(n);
31 for (i = 0; i <= nsuper; i++) {
33 jlen = glu.xlsub(fsupc + 1) - glu.xlsub(fsupc);
35 for (j = fsupc; j < glu.xsup(i + 1); j++) {
37 nnzU += j - fsupc + 1;
50 template <
typename Scalar,
typename StorageIndex>
52 Index fsupc, i, j, k, jstart;
54 StorageIndex nextl = 0;
55 Index nsuper = (glu.supno)(n);
58 for (i = 0; i <= nsuper; i++) {
60 jstart = glu.xlsub(fsupc);
61 glu.xlsub(fsupc) = nextl;
62 for (j = jstart; j < glu.xlsub(fsupc + 1); j++) {
63 glu.lsub(nextl) = perm_r(glu.lsub(j));
66 for (k = fsupc + 1; k < glu.xsup(i + 1); k++) glu.xlsub(k) = nextl;
75 #endif // EIGEN_SPARSELU_UTILS_H void fixupL(const Index n, const IndexVector &perm_r, GlobalLU_t &glu)
Fix up the data storage lsub for L-subscripts.
Definition: SparseLU_Utils.h:51
Namespace containing all symbols from the Eigen library.
Definition: B01_Experimental.dox:1
void countnz(const Index n, Index &nnzL, Index &nnzU, GlobalLU_t &glu)
Count Nonzero elements in the factors.
Definition: SparseLU_Utils.h:23
EIGEN_DEFAULT_DENSE_INDEX_TYPE Index
The Index type as used for the API.
Definition: Meta.h:82
The matrix class, also used for vectors and row-vectors.
Definition: Matrix.h:186