help-octave
[Top][All Lists]
Advanced

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

Re: Need help with nelder_mead_min.m


From: etienne
Subject: Re: Need help with nelder_mead_min.m
Date: Mon, 23 Nov 2009 18:07:12 -0800
User-agent: Internet Messaging Program (IMP) H3 (4.3)



  Hello,

something like

octave:408> function val = foo (xyz), val = sum (xyz .^ 2); endfunction
octave:409> help nelder_mead_min
[snip]
### Start nelder_mead_min() from a random point
octave:410> [xyz0, val0, nev] = nelder_mead_min ("foo", randn(1,3))
xyz0 =

   2.1237e-08   1.0243e-08  -4.4610e-09

val0 =  5.7582e-16
nev =  201
### Start nelder_mead_min() from the minimum
octave:411> [xyz0, val0, nev] = nelder_mead_min ("foo", [0 0 0])
xyz0 =

   0   0   0

val0 = 0
nev =  236

  Hth,

  Etienne

Quoting ???????? ???????
<address@hidden> (Mon, 23 Nov 2009 21:43:57 +0300):

Hi all!

I can't figure out how to work with this function. I will be very
glad if one could explain the subject.


For an example lets see the problem.


function y = foo (x, y, z)
    y = x**2 + y**2 + z**2;
endfunction


I need to find a minima of the foo in [-1;1]*[-1;1]*[-1;1] region.
I know the answer, but how I must set up an options and arguments
for nelder_mead_min.m?


Best regards,
Grigory 

--
http://www.isr.ist.utl.pt/~etienne

----------------------------------------------------------------
This message was sent using IMP, the Internet Messaging Program.



reply via email to

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