11#ifndef EIGEN_SPARSELU_UTILS_H
12#define EIGEN_SPARSELU_UTILS_H
20template <
typename Scalar,
typename StorageIndex>
24 nnzU = (glu.
xusub)(n);
30 for (i = 0; i <= nsuper; i++)
35 for (j = fsupc; j < glu.
xsup(i+1); j++)
38 nnzU += j - fsupc + 1;
51template <
typename Scalar,
typename StorageIndex>
54 Index fsupc, i, j, k, jstart;
56 StorageIndex nextl = 0;
60 for (i = 0; i <= nsuper; i++)
63 jstart = glu.
xlsub(fsupc);
64 glu.
xlsub(fsupc) = nextl;
65 for (j = jstart; j < glu.
xlsub(fsupc + 1); j++)
67 glu.
lsub(nextl) = perm_r(glu.
lsub(j));
70 for (k = fsupc+1; k < glu.
xsup(i+1); k++)
void countnz(const Index n, Index &nnzL, Index &nnzU, GlobalLU_t &glu)
Count Nonzero elements in the factors.
Definition: SparseLU_Utils.h:21
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:52
Namespace containing all symbols from the Eigen library.
Definition: Core:141
EIGEN_DEFAULT_DENSE_INDEX_TYPE Index
The Index type as used for the API.
Definition: Meta.h:74
Definition: Eigen_Colamd.h:50
Definition: SparseLU_Structs.h:77
IndexVector xsup
Definition: SparseLU_Structs.h:79
IndexVector supno
Definition: SparseLU_Structs.h:80
IndexVector lsub
Definition: SparseLU_Structs.h:82
IndexVector xusub
Definition: SparseLU_Structs.h:89
IndexVector xlsub
Definition: SparseLU_Structs.h:84