10 #ifndef EIGEN_SPARSESOLVERBASE_H
11 #define EIGEN_SPARSESOLVERBASE_H
23 template<
typename Decomposition,
typename Rhs,
typename Dest>
24 std::enable_if_t<Rhs::ColsAtCompileTime!=1 && Dest::ColsAtCompileTime!=1>
28 typedef typename Dest::Scalar DestScalar;
30 static const Index NbColsAtOnce = 4;
31 Index rhsCols = rhs.cols();
37 for(
Index k=0; k<rhsCols; k+=NbColsAtOnce)
39 Index actualCols = std::min<Index>(rhsCols-k, NbColsAtOnce);
40 tmp.leftCols(actualCols) = rhs.middleCols(k,actualCols);
41 tmpX.leftCols(actualCols) = dec.solve(tmp.leftCols(actualCols));
42 dest.middleCols(k,actualCols) = tmpX.leftCols(actualCols).
sparseView();
47 template<
typename Decomposition,
typename Rhs,
typename Dest>
48 std::enable_if_t<Rhs::ColsAtCompileTime==1 || Dest::ColsAtCompileTime==1>
51 typedef typename Dest::Scalar DestScalar;
55 dest_dense = dec.solve(rhs_dense);
68 template<
typename Derived>
83 Derived&
derived() {
return *
static_cast<Derived*
>(
this); }
84 const Derived&
derived()
const {
return *
static_cast<const Derived*
>(
this); }
90 template<
typename Rhs>
103 template<
typename Rhs>
112 #ifndef EIGEN_PARSED_BY_DOXYGEN
114 template<
typename Rhs,
typename Dest>
#define EIGEN_STATIC_ASSERT(X, MSG)
Base class for all dense matrices, vectors, and expressions.
The matrix class, also used for vectors and row-vectors.
Pseudo expression representing a solving operation.
Base class of any sparse matrices or sparse expressions.
A base class for sparse solvers.
SparseSolverBase(SparseSolverBase &&other)
const Solve< Derived, Rhs > solve(const MatrixBase< Rhs > &b) const
const Derived & derived() const
const SparseView< Derived > sparseView(const Scalar &m_reference=Scalar(0), const typename NumTraits< Scalar >::Real &m_epsilon=NumTraits< Scalar >::dummy_precision()) const
const unsigned int RowMajorBit
bfloat16() min(const bfloat16 &a, const bfloat16 &b)
std::enable_if_t< Rhs::ColsAtCompileTime!=1 &&Dest::ColsAtCompileTime!=1 > solve_sparse_through_dense_panels(const Decomposition &dec, const Rhs &rhs, Dest &dest)
EIGEN_DEFAULT_DENSE_INDEX_TYPE Index
The Index type as used for the API.