octave-bug-tracker
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Octave-bug-tracker] [bug #35534] fminunc: FunValCheck buggy


From: Rik
Subject: [Octave-bug-tracker] [bug #35534] fminunc: FunValCheck buggy
Date: Wed, 15 Feb 2012 19:07:23 +0000
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:5.0) Gecko/20100101 Firefox/5.0

Update of bug #35534 (project octave):

                  Status:                    None => Confirmed              

    _______________________________________________________

Follow-up Comment #2:

The bug is confirmed, as well as your patch that fixes it.

Looking at the documentation for fminunc
(http://www.mathworks.com/help/toolbox/optim/ug/fminunc.html) I see the
following for the FunValCheck option.


Check whether objective function values are valid. 'on' displays an error when
the objective function returns a value that is complex, Inf, or NaN. The
default 'off' displays no error.


Could you expand your patch to also detect Inf values?  The isinf() function
should be all that is required.

Also, could you add a %!test or %!assert block that exercises the new code?

Something like 


%% Test for bug #35534
%!assert (fminunc (@(x) x^2, 1, optimset ("FunValCheck", "on"), 0, eps)
%!error <non-real value> fminunc (@(x) x + i, 1, optimset ("FunValCheck",
"on"))




    _______________________________________________________

Reply to this item at:

  <http://savannah.gnu.org/bugs/?35534>

_______________________________________________
  Message sent via/by Savannah
  http://savannah.gnu.org/




reply via email to

[Prev in Thread] Current Thread [Next in Thread]