-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA256 Hi Michael,
Thanks for the test script. It has been a while. My first version I sent performed very well on the simple rosenbrock function, outperforming SA by using much less function evaluations. I made a few adjustments which should make it easier to use. I added a test, a demo and did a bit cleanup. I attached the new version along with another very nasty test function (rastrigin.m). I also made a cpp version if someone is interested. I think de_min.m is ready to be included in the optim package. If there are people saying that they would benefit from a c++ implementation, I might do it. But for many real problems, the function evaluation itself is the problem. In order to make updates to this function, it might be a good idea if have an svn account. Comments and criticism welcome. Best wishes Christian On Tue, 2009-07-21 at 10:00 +0200, Michael Creel wrote: > Hi Christian, > This function looks like it could find a home in the optim package > (http://octave.sourceforge.net/optim/index.html). I have written > simulated annealing code that is already part of the package. > Following is a script that will use your code and the simulated > annealing code to minimize a higher dimensional Rosenbrock function > (also in optim). > Best, Michael > > dim = 10; > ctl.XVmin = -2*ones(1, dim); > ctl.XVmax = 2*ones(1, dim); > tic; > [x, obj_value, nfeval] = de_min (@rosenbrock, ctl); > toc > printf("solution: \n"); > disp(x); > > # SA controls > ub = 2*ones(dim,1); > lb = -ub; > nt = 20; > ns = 5; > rt = 0.75; # careful - this is too low for many problems > maxevals = 1e10; > neps = 5; > functol = 1e-7; > paramtol = 1e-5; > verbosity = 1; # only final results. Inc > minarg = 1; > control = { lb, ub, nt, ns, rt, maxevals, neps, functol, paramtol, > verbosity, 1}; > # do sa > x = zeros(dim,1); > tic; > [theta, obj_value, convergence] = samin("rosenbrock", {x}, control); > toc -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.9 (GNU/Linux) Comment: Use GnuPG with Firefox : http://getfiregpg.org (Version: 0.7.6) iQIcBAEBCAAGBQJKibs1AAoJEJghsQQMM0PTKBAP+wdg2IKRAncRGyQmqjyqxDd2 79SQSc+JmFo5R79j8jIEYuyjCOQYhkQ/6T4Hv1JhC9AbQanXTwE6XH/VvMAHNlJN bCGVHrtjIo57FATEkgqYZEX+02Jn3LZhes5ORSwkR+/g8PMiFc1KFd5WhuO5dOT8 B76DC1ovXLxyTx0LfPkSrdRNjp9szBJW4ekWkSXFosBLfuIZtjemiEwNFwhrR80X V8HMltakHNQAbrniR1FASLWMnwWaGXM7vn9WKo/wphDVl59KllPhNNxBVhFng9AI gOgs+mgsAPr4BgvIFjm2lu2zqCkkgBlulVGZtDP54+YHvTVcuenavZCjMeAdPDoG 8SYCw49Yo6ICMOh1LGa+y6vt60r8ZWVH1uM49YwoJ3yna+b27f3fbdwbAbyWXqxY NOzErY+uc4zJ12Q1ZajtQSjQA0iBKyIIoDMEaXWzs3db1Ry9KJl+errpNQ3rtgrg YGioRBdSiSkWiQFvinYkoatVlW8BTNnKBIWXZlNKWBcdGWiG/XGaDf0YN6/ZGKN8 rgJjq5zPa3+Sb+YWsPyQEQAE/tsoH7NtGRP2kyOh1UmREt7PGgQ8Mi32UotCspTz YfKZO/0FDeF1wLBe+CNsg72ADzSkFw9Tp6tKhaLp+m50M7q4rG4h0rm3+/yl7JRn iaILvZZHpXcCeo2upO+N =scNm -----END PGP SIGNATURE----- ______________________________________________________ GRATIS für alle WEB.DE-Nutzer: Die maxdome Movie-FLAT! Jetzt freischalten unter http://movieflat.web.de
de_min.m
Description: Binary data
rastrigin.m
Description: Binary data
rastrigin_oct.cpp
Description: Binary data
------------------------------------------------------------------------------ Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day trial. Simplify your report design, integration and deployment - and focus on what you do best, core application coding. Discover what's new with Crystal Reports now. http://p.sf.net/sfu/bobj-july
_______________________________________________ Octave-dev mailing list Octave-dev@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/octave-dev