59 template<
typename _MatrixType> 
class FullPivLU    69       MaxRowsAtCompileTime = MatrixType::MaxRowsAtCompileTime,
    70       MaxColsAtCompileTime = MatrixType::MaxColsAtCompileTime
    99     template<
typename InputType>
   108     template<
typename InputType>
   118     template<
typename InputType>
   133       eigen_assert(m_isInitialized && 
"LU is not initialized.");
   146       eigen_assert(m_isInitialized && 
"LU is not initialized.");
   147       return m_nonzero_pivots;
   161       eigen_assert(m_isInitialized && 
"LU is not initialized.");
   171       eigen_assert(m_isInitialized && 
"LU is not initialized.");
   191       eigen_assert(m_isInitialized && 
"LU is not initialized.");
   215       image(
const MatrixType& originalMatrix)
 const   217       eigen_assert(m_isInitialized && 
"LU is not initialized.");
   241     template<
typename Rhs>
   245       eigen_assert(m_isInitialized && 
"LU is not initialized.");
   254       eigen_assert(m_isInitialized && 
"PartialPivLU is not initialized.");
   294       m_usePrescribedThreshold = 
true;
   295       m_prescribedThreshold = threshold;
   309       m_usePrescribedThreshold = 
false;
   319       eigen_assert(m_isInitialized || m_usePrescribedThreshold);
   320       return m_usePrescribedThreshold ? m_prescribedThreshold
   335       eigen_assert(m_isInitialized && 
"LU is not initialized.");
   336       RealScalar premultiplied_threshold = 
abs(m_maxpivot) * threshold();
   338       for(
Index i = 0; i < m_nonzero_pivots; ++i)
   339         result += (
abs(m_lu.coeff(i,i)) > premultiplied_threshold);
   351       eigen_assert(m_isInitialized && 
"LU is not initialized.");
   352       return cols() - rank();
   364       eigen_assert(m_isInitialized && 
"LU is not initialized.");
   365       return rank() == cols();
   377       eigen_assert(m_isInitialized && 
"LU is not initialized.");
   378       return rank() == rows();
   389       eigen_assert(m_isInitialized && 
"LU is not initialized.");
   390       return isInjective() && (m_lu.rows() == m_lu.cols());
   402       eigen_assert(m_isInitialized && 
"LU is not initialized.");
   403       eigen_assert(m_lu.rows() == m_lu.cols() && 
"You can't take the inverse of a non-square matrix!");
   407     MatrixType reconstructedMatrix() 
const;
   409     EIGEN_DEVICE_FUNC 
inline Index rows()
 const { 
return m_lu.rows(); }
   410     EIGEN_DEVICE_FUNC 
inline Index cols()
 const { 
return m_lu.cols(); }
   412     #ifndef EIGEN_PARSED_BY_DOXYGEN   413     template<
typename RhsType, 
typename DstType>
   415     void _solve_impl(
const RhsType &rhs, DstType &dst) 
const;
   417     template<
bool Conjugate, 
typename RhsType, 
typename DstType>
   419     void _solve_impl_transposed(
const RhsType &rhs, DstType &dst) 
const;
   429     void computeInPlace();
   443 template<
typename MatrixType>
   445   : m_isInitialized(false), m_usePrescribedThreshold(false)
   449 template<
typename MatrixType>
   461 template<
typename MatrixType>
   462 template<
typename InputType>
   475 template<
typename MatrixType>
   476 template<
typename InputType>
   489 template<
typename MatrixType>
   507   Index number_of_transpositions = 0; 
   517     Index row_of_biggest_in_corner, col_of_biggest_in_corner;
   519     typedef typename Scoring::result_type Score;
   520     Score biggest_in_corner;
   521     biggest_in_corner = 
m_lu.bottomRightCorner(rows-k, cols-k)
   522                         .unaryExpr(Scoring())
   523                         .maxCoeff(&row_of_biggest_in_corner, &col_of_biggest_in_corner);
   524     row_of_biggest_in_corner += k; 
   525     col_of_biggest_in_corner += k; 
   527     if(biggest_in_corner==Score(0))
   548     if(k != row_of_biggest_in_corner) {
   549       m_lu.row(k).swap(
m_lu.row(row_of_biggest_in_corner));
   550       ++number_of_transpositions;
   552     if(k != col_of_biggest_in_corner) {
   553       m_lu.col(k).swap(
m_lu.col(col_of_biggest_in_corner));
   554       ++number_of_transpositions;
   561       m_lu.col(k).tail(rows-k-1) /= 
m_lu.coeff(k,k);
   563       m_lu.block(k+1,k+1,rows-k-1,cols-k-1).noalias() -= 
m_lu.col(k).tail(rows-k-1) * 
m_lu.row(k).tail(cols-k-1);
   570   for(
Index k = size-1; k >= 0; --k)
   577   m_det_pq = (number_of_transpositions%2) ? -1 : 1;
   582 template<
typename MatrixType>
   586   eigen_assert(
m_lu.rows() == 
m_lu.cols() && 
"You can't take the determinant of a non-square matrix!");
   593 template<
typename MatrixType>
   601   res = 
m_lu.leftCols(smalldim)
   602             .template triangularView<UnitLower>().toDenseMatrix()
   603       * 
m_lu.topRows(smalldim)
   604             .template triangularView<Upper>().toDenseMatrix();
   618 template<
typename _MatrixType>
   625             MatrixType::MaxColsAtCompileTime,
   626             MatrixType::MaxRowsAtCompileTime)
   629   template<
typename Dest> 
void evalTo(Dest& dst)
 const   632     const Index cols = dec().matrixLU().cols(), dimker = cols - 
rank();
   659     RealScalar premultiplied_threshold = dec().maxPivot() * dec().threshold();
   661     for(
Index i = 0; i < dec().nonzeroPivots(); ++i)
   662       if(
abs(dec().
matrixLU().coeff(i,i)) > premultiplied_threshold)
   671            MaxSmallDimAtCompileTime, MatrixType::MaxColsAtCompileTime>
   675       if(i) m.row(i).head(i).setZero();
   676       m.row(i).tail(cols-i) = dec().matrixLU().row(pivots.
coeff(i)).
tail(cols-i);
   679     m.block(0, 0, 
rank(), 
rank()).template triangularView<StrictlyLower>().setZero();
   681       m.col(i).swap(m.col(pivots.
coeff(i)));
   687      .template triangularView<Upper>().solveInPlace(
   688         m.topRightCorner(rank(), dimker)
   693       m.col(i).swap(m.col(pivots.
coeff(i)));
   696     for(
Index i = 0; i < 
rank(); ++i) dst.row(dec().
permutationQ().indices().coeff(i)) = -m.row(i).tail(dimker);
   704 template<
typename _MatrixType>
   711             MatrixType::MaxColsAtCompileTime,
   712             MatrixType::MaxRowsAtCompileTime)
   715   template<
typename Dest> 
void evalTo(Dest& dst)
 const   728     RealScalar premultiplied_threshold = dec().maxPivot() * dec().threshold();
   730     for(
Index i = 0; i < dec().nonzeroPivots(); ++i)
   731       if(
abs(dec().
matrixLU().coeff(i,i)) > premultiplied_threshold)
   736       dst.col(i) = originalMatrix().col(dec().
permutationQ().indices().coeff(pivots.
coeff(i)));
   744 #ifndef EIGEN_PARSED_BY_DOXYGEN   745 template<
typename _MatrixType>
   746 template<
typename RhsType, 
typename DstType>
   759               nonzero_pivots = this->
rank();
   763   if(nonzero_pivots == 0)
   769   typename RhsType::PlainObject c(rhs.rows(), rhs.cols());
   775   m_lu.topLeftCorner(smalldim,smalldim)
   776       .template triangularView<UnitLower>()
   777       .solveInPlace(c.topRows(smalldim));
   782   m_lu.topLeftCorner(nonzero_pivots, nonzero_pivots)
   783       .template triangularView<Upper>()
   784       .solveInPlace(c.topRows(nonzero_pivots));
   787   for(
Index i = 0; i < nonzero_pivots; ++i)
   789   for(
Index i = nonzero_pivots; i < 
m_lu.cols(); ++i)
   793 template<
typename _MatrixType>
   794 template<
bool Conjugate, 
typename RhsType, 
typename DstType>
   809     nonzero_pivots = this->
rank();
   813   if(nonzero_pivots == 0)
   819   typename RhsType::PlainObject c(rhs.rows(), rhs.cols());
   826     m_lu.topLeftCorner(nonzero_pivots, nonzero_pivots)
   827         .template triangularView<Upper>()
   829         .solveInPlace(c.topRows(nonzero_pivots));
   831     m_lu.topLeftCorner(smalldim, smalldim)
   832         .template triangularView<UnitLower>()
   834         .solveInPlace(c.topRows(smalldim));
   837     m_lu.topLeftCorner(nonzero_pivots, nonzero_pivots)
   838         .template triangularView<Upper>()
   840         .solveInPlace(c.topRows(nonzero_pivots));
   842     m_lu.topLeftCorner(smalldim, smalldim)
   843         .template triangularView<UnitLower>()
   845         .solveInPlace(c.topRows(smalldim));
   850   for(
Index i = 0; i < smalldim; ++i)
   862 template<
typename DstXprType, 
typename MatrixType>
   882 template<
typename Derived>
 internal::plain_row_type< MatrixType, StorageIndex >::type IntRowVectorType
PermutationMatrix< ColsAtCompileTime, MaxColsAtCompileTime > PermutationQType
void evalTo(Dest &dst) const
bool m_usePrescribedThreshold
#define EIGEN_GENERIC_PUBLIC_INTERFACE(Derived)
EIGEN_DEVICE_FUNC void _solve_impl(const RhsType &rhs, DstType &dst) const
const internal::image_retval< FullPivLU > image(const MatrixType &originalMatrix) const
SolverBase< FullPivLU > Base
FullPivLU< MatrixType > LuType
internal::traits< FullPivLU< _MatrixType > >::Scalar Scalar
FullPivLU & setThreshold(const RealScalar &threshold)
RealScalar m_prescribedThreshold
InverseReturnType inverse() const
FullPivLU & compute(const EigenBase< InputType > &matrix)
const PermutationQType & permutationQ() const
Derived & applyTranspositionOnTheRight(Index i, Index j)
Holds information about the various numeric (i.e. scalar) types allowed by Eigen. ...
Decomposition::RealScalar rcond_estimate_helper(typename Decomposition::RealScalar matrix_norm, const Decomposition &dec)
Reciprocal condition number estimator. 
Eigen::Index Index
The interface type of indices. 
const FullPivLU< PlainObject > fullPivLu() const
#define EIGEN_SIZE_MIN_PREFER_FIXED(a, b)
Index nonzeroPivots() const
EIGEN_DEVICE_FUNC Index cols() const
EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE Scalar & coeffRef(Index rowId, Index colId)
Expression of the inverse of another expression. 
EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE const AbsReturnType abs() const
RealScalar threshold() const
internal::traits< MatrixType >::Scalar determinant() const
const MatrixType & matrixLU() const
EIGEN_DEVICE_FUNC Index cols() const
const IndicesType & indices() const
IntRowVectorType m_colsTranspositions
ConstTransposeReturnType transpose() const
FullPivLU & setThreshold(Default_t)
void evalTo(Dest &dst) const
EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE const Scalar & coeff(Index rowId, Index colId) const
EIGEN_DEFAULT_DENSE_INDEX_TYPE Index
The Index type as used for the API. 
const Inverse< FullPivLU > inverse() const
EIGEN_DEVICE_FUNC Index rows() const
static void run(DstXprType &dst, const SrcXprType &src, const internal::assign_op< typename DstXprType::Scalar, typename MatrixType::Scalar > &)
static void check_template_parameters()
#define EIGEN_STATIC_ASSERT_NON_INTEGER(TYPE)
bool isSurjective() const
MatrixType reconstructedMatrix() const
PermutationMatrix< RowsAtCompileTime, MaxRowsAtCompileTime > PermutationPType
bool isInvertible() const
SolverStorage StorageKind
EIGEN_DEVICE_FUNC Index rows() const
EIGEN_DOC_BLOCK_ADDONS_NOT_INNER_PANEL EIGEN_DEVICE_FUNC BlockXpr block(Index startRow, Index startCol, Index blockRows, Index blockCols)
This is the const version of block(Index,Index,Index,Index). */. 
EIGEN_DEVICE_FUNC void _solve_impl_transposed(const RhsType &rhs, DstType &dst) const
internal::plain_col_type< MatrixType, StorageIndex >::type IntColVectorType
#define EIGEN_MAKE_KERNEL_HELPERS(DecompositionType)
const internal::kernel_retval< FullPivLU > kernel() const
const Solve< FullPivLU, Rhs > solve(const MatrixBase< Rhs > &b) const
EIGEN_DEVICE_FUNC SegmentReturnType tail(Index n)
This is the const version of tail(Index). 
LU decomposition of a matrix with complete pivoting, and related features. 
FullPivLU()
Default Constructor. 
IntColVectorType m_rowsTranspositions
#define EIGEN_MAKE_IMAGE_HELPERS(DecompositionType)
EIGEN_DEVICE_FUNC const PermutationPType & permutationP() const
Inverse< LuType > SrcXprType
Pseudo expression representing a solving operation. 
Index dimensionOfKernel() const
#define eigen_internal_assert(x)
MatrixType::PlainObject PlainObject
The matrix class, also used for vectors and row-vectors. 
AdjointReturnType adjoint() const
EIGEN_DEVICE_FUNC Index size() const
A base class for matrix decomposition and solvers. 
EIGEN_DEVICE_FUNC Derived & derived()
Base class for all dense matrices, vectors, and expressions. 
RealScalar maxPivot() const
EIGEN_DEVICE_FUNC const XprTypeNestedCleaned & nestedExpression() const