28#ifndef SPARSELU_HEAP_RELAX_SNODE_H
29#define SPARSELU_HEAP_RELAX_SNODE_H
45template <
typename Scalar,
typename StorageIndex>
53 for (StorageIndex i = 0; i < n+1; ++i) inv_post(post(i)) = i;
58 for (
Index i = 0; i < n; ++i)
60 iwork(post(i)) = post(et(i));
69 for (j = 0; j < n; j++)
73 descendants(parent) += descendants(j) + 1;
83 while ( parent != n && descendants(parent) < relax_columns )
90 for (
Index i = snode_start; i <= j; ++i)
93 if ( (l - k) == (j - snode_start) )
100 for (
Index i = snode_start; i <= j; ++i)
103 if (descendants(i) == 0)
111 while (descendants(j) != 0 && j < n) j++;
EIGEN_DEVICE_FUNC Derived & setZero(Index size)
Resizes to the given size, and sets all coefficients in this expression to zero.
Definition: CwiseNullaryOp.h:562
EIGEN_DEVICE_FUNC Derived & setConstant(Index size, const Scalar &val)
Resizes to the given size, and sets all coefficients in this expression to the given value val.
Definition: CwiseNullaryOp.h:361
void heap_relax_snode(const Index n, IndexVector &et, const Index relax_columns, IndexVector &descendants, IndexVector &relax_end)
Identify the initial relaxed supernodes.
Definition: SparseLU_heap_relax_snode.h:46
constexpr common_t< T1, T2 > min(const T1 x, const T2 y) noexcept
Compile-time pairwise minimum function.
Definition: min.hpp:35
@ emptyIdxLU
Definition: SparseLU_Memory.h:38
void treePostorder(typename IndexVector::Scalar n, IndexVector &parent, IndexVector &post)
Post order a tree.
Definition: SparseColEtree.h:178
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