[
https://issues.apache.org/jira/browse/MATH-1137?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14059831#comment-14059831
]
Nigel Goodwin edited comment on MATH-1137 at 7/12/14 3:56 PM:
--------------------------------------------------------------
Nothing ever crashed, and I don't even know whether that bit of code is ever
exercised, but I will take up the challenge and see if I can make some tests
with difficult functions (e.g. Rosenbrook).
I met Prof Powell many decades ago (I am aged 60, which is probably 3x the age
of the average contributor to Apache) and he never claimed to be a good
programmer.
http://iridia.ulb.ac.be/IridiaTrSeries/link/IridiaTr2010-010.pdf
I have looked at the NLopt C version and have little confidence in
it....particularly the rescue code, which seems to not be there in the apache
java version (probably a good thing).
One other thing I noticed in Apache is line 1710 and 1744 where there is
{code}
final int ih = nfx * (nfx + 1) / 2 - 1;
{code}
so 1 is subtracted.
All I am doing in my suggested correction of
{code}
double curv = modelSecondDerivativesValues.getEntry ((j + 1 + (j +1) * (j+
1)) / 2 - 1);
{code}
is to do the same subtraction of 1 and adjust because j starts from 0.
How do I post to the "dev" ML?
was (Author: essence):
Nothing ever crashed, and I don't even know whether that bit of code is ever
exercised, but I will take up the challenge and see if I can make some tests
with difficult functions (e.g. Rosenbrook).
I met Prof Powell many decades ago (I am aged 60, which is probably 3x the age
of the average contributor to Apache) and he never claimed to be a good
programmer.
http://iridia.ulb.ac.be/IridiaTrSeries/link/IridiaTr2010-010.pdf
I have looked at the NLopt C version and have little confidence in
it....particularly the rescue code, which seems to not be there in the apache
java version (probably a good thing).
One other thing I noticed in Apache is line 1710 and 1744 where there is
{code}
final int ih = nfx * (nfx + 1) / 2 - 1;
{code}
so 1 is subtracted.
All I am doing in my suggested correction of
{code}
double curv = modelSecondDerivativesValues.getEntry ((j
+ 1 + (j +1) * (j+ 1)) / 2 - 1);
{code}
is to do the same subtraction of 1 and adjust because j starts from 0.
How do I post to the "dev" ML?
> BOBYQA incorrect indexing
> -------------------------
>
> Key: MATH-1137
> URL: https://issues.apache.org/jira/browse/MATH-1137
> Project: Commons Math
> Issue Type: Bug
> Affects Versions: 3.3
> Reporter: Nigel Goodwin
>
--
This message was sent by Atlassian JIRA
(v6.2#6252)