fminunc with a one-variable function

Jaroslav Hajek highegg at gmail.com
Sat Jul 25 09:22:25 CDT 2009


On Thu, Jul 23, 2009 at 8:38 PM, Jaroslav Hajek<highegg at gmail.com> wrote:
> On Thu, Jul 23, 2009 at 5:32 PM, Jonathan Stickel<jjstickel at vcn.com> wrote:
>> I see the following when I use fminunc to minimize a function of just one
>> variable:
>>
>>  function F = theF(x)
>>   F = x.^2 + exp(x);
>>  endfunction
>>  x0 = 1;
>>  [xmin,fmin] = fminunc(@theF,x0)
>>
>> error: Invalid call to cholupdate.  Correct usage is:
>>
>>  -- Loadable Function: [R1, INFO] = cholupdate (R, U, OP)
>>
>>
>> I know that there are other minimization functions that can be used for
>> single-variable functions, but fminunc should work too.
>>
>> Thanks,
>> Jonathan
>>
>
> Please try
> http://hg.savannah.gnu.org/hgweb/octave/rev/5fcf008c7c41
>
Goes to 3.2.x as well.

RNDr. Jaroslav Hajek
computing expert & GNU Octave developer
Aeronautical Research and Test Institute (VZLU)
Prague, Czech Republic
url: www.highegg.matfyz.cz



More information about the Bug-octave mailing list