From: stevenj Date: Mon, 27 Aug 2012 17:53:59 +0000 (-0400) Subject: cobyla should return ROUNDOFF_LIMITED if it "converges" to zero x tolerance, rather... X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~ianmdlvl/git?a=commitdiff_plain;h=79fa9f528e87b5e0845f8d7e5b8e13a9e4f34049;p=nlopt.git cobyla should return ROUNDOFF_LIMITED if it "converges" to zero x tolerance, rather than XTOL_REACHED; thanks to David Liu for the bug report Ignore-this: c5ac800405beb77a0b18a7ba8f20a4a4 darcs-hash:20120827175359-c8de0-1ee07387d0560bde56d8de9315c20b03e4fea186.gz --- diff --git a/cobyla/cobyla.c b/cobyla/cobyla.c index 763e01c..bb3066b 100644 --- a/cobyla/cobyla.c +++ b/cobyla/cobyla.c @@ -1193,8 +1193,8 @@ L550: } goto L140; } - else - rc = NLOPT_XTOL_REACHED; + else /* rho <= rhoend */ + rc = rhoend > 0 ? NLOPT_XTOL_REACHED : NLOPT_ROUNDOFF_LIMITED; /* Return the best calculated values of the variables. */