commons-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Nigel Goodwin (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (MATH-1137) BOBYQA incorrect indexing
Date Fri, 11 Jul 2014 11:53:06 GMT

    [ https://issues.apache.org/jira/browse/MATH-1137?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14058688#comment-14058688
] 

Nigel Goodwin commented on MATH-1137:
-------------------------------------

I don't know my way around here...

I commented in Math-621 about what I think is incorrect indexing, and it seems to still be
incorrect.

Line 530 of BOBYQA has

  double curv = modelSecondDerivativesValues.getEntry((j + j * j) / 2);

but I think it should be

  double curv = modelSecondDerivativesValues.getEntry((j + 1 +  (j+1)*(j+1)) / 2-1);

The original Fortran is

              CURV=HQ((J+J*J)/2)

So a change from 1 to 0 indexing should translate into the above.

> 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)

Mime
View raw message