Dear Tommaso,

calling the method info() on your LLT object in this case should return
Eigen::ComputationInfo::NumericalIssue. It's not because the code didn't
crash that you can say the decomposition arrived at a result. Success is
conveyed by info() and there is no exception raised upon failure.
>From a quick look a the code, llt() stops prematurely if it encounters a
pivot that is <= 0. The part of the resulting L matrix up to this point
will be "correct", but all the rows after should simply be (part of) the
rows of your initial matrix.

Best regards,
Adrien

On Tue, Apr 14, 2020 at 7:35 PM Tommaso Ferrari <[email protected]>
wrote:

> Dear all,
> I was analyzing Cholesky's decomposition algorithm on a non positive
> definite matrix. It is a 3*3 matrix, whose eigenvalues are -29.5, 2, 30.5.
> I noticed that the llt() method produces a result even if, obviously, the
> reconstruction of the starting matrix is not correct (due to the fact that
> the input matrix is not positive definite).
> I would like to know if, in general, given a non positive definite matrix,
> the llt() method still arrives at a result or if there may be exceptions or
> errors.
> How does the decomposition proceed, having as input a non positive
> definite matrix? Are pseudo method (pseudo determinant, pseudo inverse)
> used?
> Thanks for your attention and response
>
> Tommaso
>

Reply via email to