View License

Download apps, toolboxes, and other File Exchange content using Add-On Explorer in MATLAB.

» Watch video

Highlights from

4.0 | 5 ratings Rate this file 7 Downloads (last 30 days) File Size: 230 KB File ID: #13115 Version: 1.2
image thumbnail




25 Nov 2006 (Updated )

nonSmoothSolve (similar to fsolve), non-smooth & noisy local + some global solvers; works in Octave

| Watch this File

File Information

OpenOpt is a free MATLAB Toolbox, which is also run in Octave

Particularly, it contains non-smooth solvers
ralg (medium-scale, for nVars=1...1000)
ShorEllipsoid (small-scale, for nVars=1...10)
(both can handle lb, ub, Ax<=b, Aeq*x=beq, c(x)<=0, h(x)=0; providing gradients/sub gradients df, dc, dh is appreciated)

nonSmoothSolve - fsolve analog for nonsmooth & noisy funcs (try benchmarking in nonSmoothSolveEx.m).

Graphics output is also enabled (for Octave users still there are some problems).

2 lines are enough to solve your problem -
prob = ooAssign (ObjFun, x0, <optional params>)
r = ooRun (prob, solver)
Example of output structure r:
xf: [10x1 double] % x final
             ff: -0.0719 % fval final
            alg: 'Kennedy J., Eberhart R.C. (1995): Particle swarm optimization. In: Proc.'
         author: 'Alexandros Leontitsis,, University of Ioannina, Greece'
(+some other fields)

Regrads, Dmitrey. 15.02.2007,
Cherkassy, Ukraine.

P.S. You are welcome to our homepage, where we have provided some more free numerical optimization software (however, non-MATLAB language).


This file inspired Exhaustive Search Method.

MATLAB release MATLAB 7.3 (R2006b)
Other requirements for Octave users - Octave v 2.9.9+ or preferable 2.9.10
Tags for This File   Please login to tag files.
Please login to add a comment or rating.
Comments and Ratings (12)
26 Apr 2016 Mark Matusevich

Very good. Works out of the box (on R2009b on Win7).

I recommend to start with the following steps:
1) Download and unzip (let's denote the directory <Dir>)
2) execute:
>> addpath(genpath('<Dir>\OpenOpt'))
>> ooexample1
If you see stuff being printed and a constantly changing plot, then installation was sucessfull and OpenOpt works on your PC.
3) Look at the examples to see how to use the toolbox:
>> open ooexample
>> open ooexample1
>> open ooexample2
>> open ooexample3
>> open ooexample4
4) Read documentation in the directory <Dir>\OpenOpt\doc

24 Jan 2012 Yaco Yann

It's very hard to understand. Too many files and no comment

Comment only
16 Mar 2009 Dmitrey Kroshko

No, documentation is available for Python version only,

Comment only
04 Jul 2008 E W

Is there further documentation available?

Comment only
06 Dec 2007 Dmitrey Kroshko

hi all,
I should inform you: some months ago OpenOpt had migrated to Python programming language, and no support and further development for MATLAB/Octave version will be provided.
Thanks all for your comments.
Regards, D.

Comment only
22 Nov 2007 Emmanuel FARHI

Works like a charm. However, I have a few remarks to improve the package. All suggested methods are available on Matlab Central:
1-a simplex method equivalent to fminsearch would be appreciated, suggesting the State Machine Simplex Minimizer.
2-a Levenberg Marquardt method would also be appreciated, e.g. LMFsolve.
3- a Genetic Algorithm method without constrains would also be nice, especially as GA is provided with the GAconstrain method. The gaevolv could also be good.
4- the powell method seems quite efficient and could be in OpenOpt
5- There are other swam optimizers, such as 'swarm' and 'PSO'. Are they slower/less efficient that the hPSO ?
Finally, thanks for this package. Probably a better documentation would be nice, e.g. regarding the many options in ooAssign, which depend on packages.

08 Aug 2007 Luke Rosenberg

doesn't work at all - everything i tried returned errors! Not enough documentation to work out what was going on. nonSmoothSolve() does not work exactly the same as fsolve.

29 May 2007 Paul Strefling

I have been using OpenOpt to solve both smooth and non smooth optimization problems with excellent success. It has outperformed all commertial solvers that I have tried, in both convergence time and optimal solution. It's perfromace is second to none, thank you Dmitery.

16 Feb 2007 Dmitrey

OpenOpt 0.35 is reliesed (download- from here, now will contain only pathces & previous OpenOpt versions. If you'll obtain a error "you must pass (size prob.n x 1) vector x to the iterfcn" please download and replace ooIter.m from the URL).

new functions: nonSmoothSolve() & ominsearch(), with same syntax as MATLAB fsolve & fminsearch;

now solver ralg() (non-smooth optimizer, fminsearch() analog, can handle ill-conditioned problems) can handle all types of linear & non-linear constraints:

lb<=x<=ub, A*x<=b, Aeq*x=beq, c(x)<=0, h(x)=0
(and ShorEllipsoid() too)

user-provided gradients/subgradients to constraints prob.dc(), prob.dh() also can be used in ralg;
prob.parallel.f=1 turnes on parallel calculation of objFun (sub)gradient via dfeval() (MDCE, jobmanagers, workers must be properly started). Octave users must provide func with similar to dfeval syntax in
prob.parallel.c & prob.parallel.h will be (I hope) in future OpenOpt version.

+LOTS of minor changes;


-new marker (right-pointing triangle), reporting that MaxTime, MaxCPUTime, MaxIter, MaxFunEvals or etc is exeeded;

-graphic output speed is increased.
(some problems in Octave graphics still remain, but it's because of temporary Octave incompabilities & problems with connecting to gnuplot)

Comment only
30 Jan 2007 Nas Maleki

OpenOpt is a fantastic Toolbox. Thanks Dmitrey for sharing it.

30 Nov 2006 Dmitrey Kroshko

According to Mathworks rules, we can't update OpenOpt more than once per 2 monthes here. CVS/subversion is also under development.
So currently you can check for latest versions from
now (11/30/06) v 0.16 is available
+/- sign in ooAssign;
bugfix in the end of ooexample.m
new param prob.fEnough is available (solvers will stop if fEnough is reached)
prob.assert() implemented

Comment only
28 Nov 2006 Dmitrey

If any bugs will be obtained, contact via icq 275976670

Comment only

bugfix (`Feb2007' undefined near line 4 column 5) while using graphics on

16 Feb 2007

new funcs nonSmoothSolve & ominsearch
ralg (non-smooth,fminsearch analog) can handle: lb<=x<=ub, A*x<=b, Aeq*x=beq, c(x)<=0, h(x)=0
+user (sub)gradients can be used
graphic output speed is increased
+LOTS of minor changes

18 Jul 2009 1.1

change license from GPL to BSD

21 Jul 2009 1.2

license changed to BSD

Contact us