mirror of
https://gitlab.com/libeigen/eigen.git
synced 2026-04-10 11:34:33 +08:00
* Merge Extract and Part to the Part expression.
Renamed "MatrixBase::extract() const" to "MatrixBase::part() const" * Renamed static functions identity, zero, ones, random with an upper case first letter: Identity, Zero, Ones and Random.
This commit is contained in:
@@ -58,7 +58,7 @@ template<typename MatrixType> class Cholesky
|
||||
compute(matrix);
|
||||
}
|
||||
|
||||
Extract<MatrixType, Lower> matrixL(void) const
|
||||
Part<MatrixType, Lower> matrixL(void) const
|
||||
{
|
||||
return m_matrix;
|
||||
}
|
||||
@@ -79,7 +79,7 @@ template<typename MatrixType> class Cholesky
|
||||
bool m_isPositiveDefinite;
|
||||
};
|
||||
|
||||
/** Compute / recompute the Cholesky decomposition A = LL^* = U^*U of \a matrix
|
||||
/** Computes / recomputes the Cholesky decomposition A = LL^* = U^*U of \a matrix
|
||||
*/
|
||||
template<typename MatrixType>
|
||||
void Cholesky<MatrixType>::compute(const MatrixType& a)
|
||||
@@ -124,7 +124,7 @@ typename Derived::Eval Cholesky<MatrixType>::solve(const MatrixBase<Derived> &b)
|
||||
const int size = m_matrix.rows();
|
||||
ei_assert(size==b.rows());
|
||||
|
||||
return m_matrix.adjoint().template extract<Upper>().inverseProduct(matrixL().inverseProduct(b));
|
||||
return m_matrix.adjoint().template part<Upper>().inverseProduct(matrixL().inverseProduct(b));
|
||||
}
|
||||
|
||||
/** \cholesky_module
|
||||
|
||||
@@ -58,7 +58,7 @@ template<typename MatrixType> class CholeskyWithoutSquareRoot
|
||||
}
|
||||
|
||||
/** \returns the lower triangular matrix L */
|
||||
Extract<MatrixType, UnitLower> matrixL(void) const
|
||||
Part<MatrixType, UnitLower> matrixL(void) const
|
||||
{
|
||||
return m_matrix;
|
||||
}
|
||||
@@ -136,7 +136,7 @@ typename Derived::Eval CholeskyWithoutSquareRoot<MatrixType>::solve(const Matrix
|
||||
const int size = m_matrix.rows();
|
||||
ei_assert(size==b.rows());
|
||||
|
||||
return m_matrix.adjoint().template extract<UnitUpper>()
|
||||
return m_matrix.adjoint().template part<UnitUpper>()
|
||||
.inverseProduct(
|
||||
(matrixL()
|
||||
.inverseProduct(b))
|
||||
|
||||
Reference in New Issue
Block a user