mirror of
https://gitlab.com/libeigen/eigen.git
synced 2026-04-10 11:34:33 +08:00
last round of changes, mainly to return derived types instead of base types, and fix various compilation issues
This commit is contained in:
@@ -124,13 +124,13 @@ template<typename _MatrixType> class LDLT
|
||||
* \sa solveInPlace(), MatrixBase::ldlt()
|
||||
*/
|
||||
template<typename Rhs>
|
||||
inline const ei_solve_return_value<LDLT, Rhs>
|
||||
inline const ei_solve_retval<LDLT, Rhs>
|
||||
solve(const MatrixBase<Rhs>& b) const
|
||||
{
|
||||
ei_assert(m_isInitialized && "LDLT is not initialized.");
|
||||
ei_assert(m_matrix.rows()==b.rows()
|
||||
&& "LDLT::solve(): invalid number of rows of the right hand side matrix b");
|
||||
return ei_solve_return_value<LDLT, Rhs>(*this, b.derived());
|
||||
return ei_solve_retval<LDLT, Rhs>(*this, b.derived());
|
||||
}
|
||||
|
||||
template<typename Derived>
|
||||
@@ -265,8 +265,8 @@ LDLT<MatrixType>& LDLT<MatrixType>::compute(const MatrixType& a)
|
||||
}
|
||||
|
||||
template<typename _MatrixType, typename Rhs>
|
||||
struct ei_solve_impl<LDLT<_MatrixType>, Rhs>
|
||||
: ei_solve_return_value<LDLT<_MatrixType>, Rhs>
|
||||
struct ei_solve_retval<LDLT<_MatrixType>, Rhs>
|
||||
: ei_solve_retval_base<LDLT<_MatrixType>, Rhs>
|
||||
{
|
||||
EIGEN_MAKE_SOLVE_HELPERS(LDLT<_MatrixType>,Rhs)
|
||||
|
||||
|
||||
@@ -109,13 +109,13 @@ template<typename _MatrixType, int _UpLo> class LLT
|
||||
* \sa solveInPlace(), MatrixBase::llt()
|
||||
*/
|
||||
template<typename Rhs>
|
||||
inline const ei_solve_return_value<LLT, Rhs>
|
||||
inline const ei_solve_retval<LLT, Rhs>
|
||||
solve(const MatrixBase<Rhs>& b) const
|
||||
{
|
||||
ei_assert(m_isInitialized && "LLT is not initialized.");
|
||||
ei_assert(m_matrix.rows()==b.rows()
|
||||
&& "LLT::solve(): invalid number of rows of the right hand side matrix b");
|
||||
return ei_solve_return_value<LLT, Rhs>(*this, b.derived());
|
||||
return ei_solve_retval<LLT, Rhs>(*this, b.derived());
|
||||
}
|
||||
|
||||
template<typename Derived>
|
||||
@@ -259,8 +259,8 @@ LLT<MatrixType,_UpLo>& LLT<MatrixType,_UpLo>::compute(const MatrixType& a)
|
||||
}
|
||||
|
||||
template<typename _MatrixType, int UpLo, typename Rhs>
|
||||
struct ei_solve_impl<LLT<_MatrixType, UpLo>, Rhs>
|
||||
: ei_solve_return_value<LLT<_MatrixType, UpLo>, Rhs>
|
||||
struct ei_solve_retval<LLT<_MatrixType, UpLo>, Rhs>
|
||||
: ei_solve_retval_base<LLT<_MatrixType, UpLo>, Rhs>
|
||||
{
|
||||
typedef LLT<_MatrixType,UpLo> LLTType;
|
||||
EIGEN_MAKE_SOLVE_HELPERS(LLTType,Rhs)
|
||||
|
||||
Reference in New Issue
Block a user