On Thu, Sep 08, 2011 at 09:36:47AM -0700, Ted Dunning wrote:
> Since the diagonal elements are heavily modified during the Cholesky
> decomposition, it isn't clear what these actually mean.
>
> With pivoting, the meaning of these is even less clear.
>
> Also, I thought that the test for non-positive definiteness was whether the
> diagonal element after reduction from previous rows and columns was
> negative. This is only a comparison between two elements in the case of the
> second diagonal element. For all subsequent elements, the question is more
> subtle.
>
> Perhaps the message should be more like:
>
> The matrix was detected to not be positive definite at diagonal element
> {3}.
>
> Care should be taken to make sure that this comparison uses appropriate fuzz
> so that cases that are simply rank-deficient get appropriate treatment.
Sorry, I don't understand much of the above.
However from reading the "{3}" I wonder whether there may be a
misunderstanding. In the message pattern, "{0}", "{1}", "{2}" are
placeholders:
"{0}" stands for the value being tested (i.e. "ltI[i]" in the code excerpt)
"{1}" stands for the row (and column) index (i.e. "i")
"{2}" stands for the threshold.
There is no "{3}" placeholder.
Regards,
Gilles
> On Thu, Sep 8, 2011 at 6:30 AM, Gilles Sadowski <
> [email protected]> wrote:
>
> > Hi.
> >
> > In revision 1166674, I've added an argument to that exception so that it
> > can
> > print the value that failed the test.
> > However, I also wonder whether the message should not be
> > ---CUT---
> > not positive definite matrix: diagonal element at ({1},{1}) is not
> > strictly larger than {2} ({0})"
> > ---CUT---
> > instead of the current
> > ---CUT---
> > not positive definite matrix: diagonal element at ({1},{1}) is smaller
> > than {2} ({0})
> > ---CUT---
> >
> > In a class where the exceptionmay be thrown ("CholeskyDecompositionImpl"),
> > the
> > test is (at line 128):
> > ---CUT---
> > ltI[i] < absolutePositivityThreshold
> > ---CUT---
> > Which will *not* fail if "absolutePositivityThreshold" is zero.
> >
> > Changing it to
> > ---CUT---
> > ltI[i] <= absolutePositivityThreshold
> > ---CUT---
> > would allow to set the threshold to "0" exactly, for those cases where one
> > wants to avoid raising an exception (like where the matrix assumed to be
> > positive definite), but nevertheless wants to retain a basic fool-proof
> > check.
> >
> >
> > Regards,
> > Gilles
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: [email protected]
> > For additional commands, e-mail: [email protected]
> >
> >
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]